MCP Predictive Market
Query and analyze prediction markets through Claude
= 3.11">
Quick Start | Tools | Platforms | Configuration | Plugin Marketplace
______________________________________________________________________
这是什么?
一个MCP(模型上下文协议)服务器,从以下位置聚合预测市场数据 5大平台.搜索市场,比较赔率,发现套利机会,并通过自然语言跟踪预测。
适用于Claude Desktop、Claude Code、Cursor和任何兼容MCP的客户端。
部分 克劳德代码插件市场.
______________________________________________________________________
快速开始
# Clone and install
git clone https://github.com/EricGrill/mcp-predictive-market.git
cd mcp-predictive-market
uv sync
# Run the server
uv run python -m mcp_predictive_market.server添加到您的Claude配置并开始查询市场:
“寻找人工智能监管的预测市场”
______________________________________________________________________
为什么使用这个?
| 特性 | 描述 |
|---|---|
| 多平台搜索 | 同时查询5个预测市场 |
| 套利检测 | 查找不同平台的价格差异 |
| 市场跟踪 | 建立观察名单并监控赔率变化 |
| 平台比较 | 类似问题的并列赔率 |
| 统一数据模型 | 跨所有平台的一致市场模式 |
______________________________________________________________________
可用工具
搜索与发现
| 工具 | 说明 |
|---|---|
search_markets | 按关键字搜索所有平台上的市场 |
list_categories | 获取可用的市场类别 |
browse_category | 浏览特定类别的市场 |
市场数据
| 工具 | 说明 |
|---|---|
get_market_odds | 获取特定市场的当前赔率 |
compare_platforms | 类似市场的并排比较 |
追踪
| 工具 | 说明 |
|---|---|
track_market | 将市场添加到您的观察名单中 |
get_tracked_markets | 查看所有跟踪的市场和当前价格 |
分析
| 工具 | 说明 |
|---|---|
find_arbitrage | 检测平台之间的价格差异 |
______________________________________________________________________
支持的平台
| 平台 | URL | 专业化 |
|---|---|---|
| 多种市场 | 歧管市场 | 玩钱,品种繁多 |
| 多市场 | polymarket.com | 加密货币,高流动性 |
| Metaulus | metaculus.com | 科学,长期预测 |
| 预测 | predictit.org | 美国政治 |
| 卡尔希 | kalshi.com | CFTC监管的真实货币 |
______________________________________________________________________
配置
Claude桌面设置
添加到您的Claude Desktop配置中:
| 平台 | 配置路径 |
|---|---|
| macOS | ~/Library/Application Support/Claude/claude_desktop_config.json |
| 窗户 | %APPDATA%\Claude\claude_desktop_config.json |
| Linux | ~/.config/Claude/claude_desktop_config.json |
{
"mcpServers": {
"prediction-market": {
"command": "uv",
"args": ["run", "--directory", "/path/to/mcp-predictive-market", "python", "-m", "mcp_predictive_market.server"]
}
}
}Claude代码设置
添加到您的项目 .mcp.json 或 ~/.config/claude-code/mcp.json:
{
"mcpServers": {
"prediction-market": {
"command": "uv",
"args": ["run", "--directory", "/path/to/mcp-predictive-market", "python", "-m", "mcp_predictive_market.server"]
}
}
}______________________________________________________________________
例子
Search & Discovery
"Find prediction markets about AI"
"What categories of markets are available?"
"Show me crypto markets on Polymarket"
"Browse politics markets"Market Analysis
"Get current odds for Manifold market abc123"
"Compare odds for 'Will Bitcoin hit $100k?' across all platforms"
"Show me the probability of a 2024 recession on different platforms"Arbitrage Detection
"Find arbitrage opportunities with at least 10% spread"
"Are there any markets with significantly different odds across platforms?"
"Show me the biggest price discrepancies right now"Market Tracking
"Track the Polymarket election market"
"Show all my tracked markets"
"What are the current prices on my watchlist?"______________________________________________________________________
发展
# Clone
git clone https://github.com/EricGrill/mcp-predictive-market.git
cd mcp-predictive-market
# Install with dev dependencies
uv sync --extra dev
# Run tests
uv run pytest -v
# Run specific test file
uv run pytest tests/test_integration.py -v项目结构
src/mcp_predictive_market/
├── server.py # MCP server entry point
├── tools.py # Tool handler implementations
├── schema.py # Unified market data models
├── errors.py # Custom exceptions
├── rate_limiter.py # Per-platform rate limiting
├── adapters/ # Platform-specific adapters
│ ├── base.py # Adapter protocol
│ ├── manifold.py
│ ├── polymarket.py
│ ├── metaculus.py
│ ├── predictit.py
│ └── kalshi.py
├── analysis/ # Market analysis modules
│ ├── matching.py # Cross-platform market matching
│ └── arbitrage.py # Arbitrage detection
└── state/ # State management
└── memvid_client.py______________________________________________________________________
故障排除
No results from a platform
- 平台API可能有费率限制-等待并重试
- 检查平台是否在线:直接访问网站
- 一些平台过滤某些市场类型
Arbitrage opportunities not found
- 降低
min_spread参数(默认值为5%) - 尝试更广泛的搜索词
- 有效市场中的机会更少
Market not found
- 验证市场ID格式(因平台而异)
- 确保市场尚未解决/关闭
- 检查您是否使用了正确的平台名称
______________________________________________________________________
相关项目
- 克劳德代码插件市场 -发现更多MCP插件
- MCP Proxmox管理员 -通过Claude管理Proxmox VE
- MCP Memvid国家服务 -MCP服务器的持久状态
______________________________________________________________________
贡献
欢迎投稿!
- 分叉存储库
- 创建要素分支:
git checkout -b feature/my-feature - 进行更改和测试:
uv run pytest - 承诺:
git commit -m 'Add my feature' - 推:
git push origin feature/my-feature - 打开拉取请求
______________________________________________________________________
许可证
麻省理工学院
