mcpField
P
prediction-markets-research

prediction-markets-research

github.com/crawlora-org其他139 次安装2 天前更新
代码仓库

关于 prediction-markets-research

用于通过 Crawlora 获取 Polymarket、Kalshi、Metaculus 和 DraftKings Predictions 的标准化预测市场数据,涵盖实时与历史信息。适合预测研究和跨平台比较,仅提供公开只读数据。

主要功能

  1. 01实时与历史赔率
  2. 02订单簿、价差和价格历史
  3. 03Metaculus 社区预测
  4. 04DraftKings 分类与公开规则
  5. 05通过 Crawlora 提供标准化 JSON

适用场景

  1. 01比较不同平台的事件赔率
  2. 02追踪市场价格变化
  3. 03对照社区预测与市场价格
  4. 04查看 DraftKings 公开规则和区域信息

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/crawlora-org/crawlora-skills --skill prediction-markets-research

安装后在 Claude Code 中输入/prediction-markets-research确认已加载。

附带文件reference/endpoints.mdscripts/crawlora.sh

详细介绍

预测市场研究

以标准化 JSON 格式获取 Polymarket、Kalshi 和 Metaculus 的实时及历史赔率、订单簿和预测问题——无需抓取做市商网站或解析原始订单簿数据块。

适用场景

  • “市场认为 会如何发展?”/“……目前的赔率是多少?”
  • “展示这个市场的订单簿/价差/价格历史。”
  • “目前最热门的预测市场有哪些?”
  • “社区对 的预测(Metaculus)是什么?”
  • 选举、宏观经济、体育或加密货币结果预测研究。
  • DraftKings Predictions 的公开类别、区域可用性地图条目或结算规则链接。

设置(一次性)

  • 在 https://crawlora.net 获取免费的 Crawlora API 密钥(每月 2,000 个积分,无需信用卡)。
  • 运行辅助程序前,在环境中设置 CRAWLORA_API_KEY。
  • 辅助程序会从环境中读取 CRAWLORA_API_KEY,并向 https://api.crawlora.net/api/v1 发送请求。密钥缺失或无效时返回 401。

工作原理

  1. Polymarket — 使用 /polymarket/search 或 /polymarket/events 查找事件;使用 /polymarket/event/{slug} 获取详情(包含嵌套市场);使用 /polymarket/market/{id} 获取单个市场;然后通过 /polymarket/token/{token_id}/price|midpoint|orderbook|spread|price-history 获取代币级别的定价(或使用批量接口,例如 POST /polymarket/tokens/prices,一次最多查询 25 个代币)。/polymarket/leaderboard 和 /polymarket/dashboards/macro 涵盖交易者和宏观事件。
  2. Kalshi — 使用 /kalshi/events//kalshi/markets 浏览;使用 /kalshi/event/{event_ticker} 或 /kalshi/market/{ticker} 获取详情;使用 /kalshi/market/{ticker}/history 获取 K 线,使用 /kalshi/market/{ticker}/orderbook 获取深度,使用 /kalshi/trades 获取近期成交。/kalshi/historical/* 涵盖已结算(已关闭)的市场。
  3. Metaculus — 使用 /metaculus/questions 浏览;使用 /metaculus/question/{id} 获取详情;使用 /metaculus/question/{id}/forecasts 获取当前社区汇总预测,使用 /forecast-history 查看其随时间的变化。
  4. DraftKings Predictions — /draftkings/predictions/categories 和 /draftkings/predictions/availability 提供公开类别菜单和来源报告的区域状态地图;/draftkings/predictions/rules 列出公开的规则手册和结算来源链接。这些接口不包含报价、用户位置、交易单或账户数据。

完整接口列表、方法和参数:reference/endpoints.md。

调用 API

# Polymarket:
scripts/crawlora.sh /polymarket/search q="fed rate cut" | jq '.'
scripts/crawlora.sh /polymarket/event/will-the-fed-cut-rates | jq '.'

# Kalshi:
scripts/crawlora.sh /kalshi/markets | jq '.data'
scripts/crawlora.sh /kalshi/market/INXD-24DEC31-T5000/history | jq '.'

# Metaculus:
scripts/crawlora.sh /metaculus/questions | jq '.data'
scripts/crawlora.sh /metaculus/question/12345/forecasts | jq '.'
# DraftKings Predictions (navigation and rules only):
scripts/crawlora.sh /draftkings/predictions/availability
scripts/crawlora.sh /draftkings/predictions/categories

所有请求都使用 scripts/crawlora.sh;它会避免将 API 密钥暴露在命令行参数中。

接口参考

此技能使用的所有 Polymarket、Kalshi 和 Metaculus 接口,请参阅 reference/endpoints.md。

示例

  • 跨平台赔率对比: 对同一现实事件使用 /polymarket/search 和 /kalshi/markets,比较隐含概率。
  • 市场动能: 将 /kalshi/market/{ticker}/history 或 /polymarket/token/{token_id}/price-history 随时间绘制成图,观察市场情绪如何变化。
  • 预测与市场对比: 将 /metaculus/question/{id}/forecasts(社区汇总预测)与对应的 Polymarket/Kalshi 市场价格并列比较。

注意事项和限制

  • **额度/成功后付费:**仅对 2xx 响应计费;免费套餐每月含 2,000 个额度。 在 https://crawlora.net 获取密钥。
  • 仅限公开且无需凭据的数据——不进行交易或下单; 仅提供只读市场数据。这不是财务建议。
  • DraftKings 的区域地图是来源快照,不构成法律判定, 也不能证明用户具备资格。此处的公开路由不含实时市场价格。
  • **安全:**密钥仅保存在 CRAWLORA_API_KEY 中——切勿硬编码、放入查询参数或提交。
  • 批量端点(/polymarket/tokens/*)每次调用最多接受 25 个 ID—— 较长列表需分批处理。

评论

支持 Markdown