Polymarket Smart Money Discovery & Analysis
Discover profitable Polymarket traders, filter out market makers and HFT bots, and assess copy-trading reliability.
Project Location
CODEBLOCK0
Activate the virtualenv before running any script:
CODEBLOCK1
Quick Commands
Analyze a single wallet
CODEBLOCK2
The report includes:
- - PnL, ROI, win rate
- Entry timing analysis
- Copy trading score (0-100)
- MM/HFT detection (MM Score, ismarketmaker, is_hft)
- Copy reliability label (🟢 高可靠 / 🟡 中可靠 / 🔴 低可靠 / ❌ 不可跟单)
Discover smart money (batch)
CODEBLOCK3
Discovery pipeline:
- 1. Fetch from Polymarket v1 Leaderboard API (7 strategies)
- Deduplicate across dimensions
- Stage 1 pre-filter: PnL/Vol < 3% → exclude (likely market maker)
- Fetch activity data for remaining addresses
- Stage 2 deep analysis: MM Score + HFT detection
- Exclude "❌ 不可跟单" addresses
- Rank by copy trading score
Cache management
CODEBLOCK4
Filtering Pipeline
Stage 1: Pre-filter (from leaderboard data, zero cost)
| Rule | Threshold | Rationale |
|---|
| PnL/Vol ratio | < 3% → exclude | Market makers earn tiny spreads on huge volume |
| VOL-only listing |
exclude | Only on volume leaderboard, not on any PNL leaderboard |
Stage 2: Deep analysis (from activity data)
MM Score (0-100, weighted)
| Indicator | Weight | Market Maker Signal |
|---|
| PnL/Vol ratio | 30% | < 1% |
| Decision frequency (positions/day) |
25% | > 50/day |
| Buy/sell balance | 20% | > 0.7 (near 1:1) |
| Avg holding time | 15% | < 1 hour |
| Trade amount uniformity (CV) | 10% | < 0.3 |
MM Score > 50 → flagged as market maker.
Important: Decision frequency uses positions per day, not trades per day. A directional trader may place hundreds of trades to build one position (dollar-cost averaging). What matters is how many independent position decisions they make.
HFT Detection (2 of 3 conditions)
| Condition | Threshold |
|---|
| Decision frequency | > 10 positions/day |
| Median holding time |
< 4 hours |
| Median position size | < $50 |
Copy Reliability Labels
| Label | Conditions |
|---|
| 🟢 高可靠 | Holding > 24h, < 2 positions/day, PnL/Vol > 10% |
| 🟡 中可靠 |
Holding 4-24h, < 5 positions/day |
| 🔴 低可靠 | Holding < 4h or > 5 positions/day |
| ❌ 不可跟单 | MM Score > 50 or HFT detected |
Data Sources
| API | Base URL | Auth | Use |
|---|
| Gamma API | gamma-api.polymarket.com | None | Markets, events, search |
| Data API v1 |
data-api.polymarket.com/v1 | None | Leaderboard, positions, trades, PnL |
| CLOB API | clob.polymarket.com | For trading | Orderbook, prices |
Key endpoints
CODEBLOCK5
On-Chain Data (Phase 2)
Alchemy RPC configured in .env:
CODEBLOCK6
CTF Exchange contract: INLINECODE1
Key event: OrderFilled — extract maker/taker addresses and trade amounts from on-chain logs.
Free tier limit: 10 blocks per eth_getLogs call.
Architecture
CODEBLOCK7
Interpreting Results
When presenting results to users:
- - Always show the copy reliability label prominently
- For ❌ addresses, explain why (MM Score, HFT indicators)
- For 🟢 addresses, highlight key strengths (holding time, PnL/Vol efficiency)
- Compare addresses using the copy trading score (0-100, A/B/C/D grades)
- Use Chinese for user-facing output (the user prefers Chinese)
Polymarket 聪明钱发现与分析
发现盈利的Polymarket交易者,过滤做市商和高频交易机器人,评估跟单可靠性。
项目位置
{baseDir}/../../agents/polymarket-bot/PolyAnalysis/
运行任何脚本前请激活虚拟环境:
bash
cd {baseDir}/../../agents/polymarket-bot/PolyAnalysis
source .venv/bin/activate
快速命令
分析单个钱包
bash
python analyze.py <地址>
python analyze.py <地址> --force # 强制完全刷新
python analyze.py <地址> --json # JSON格式输出
报告包含:
- - 盈亏、投资回报率、胜率
- 入场时机分析
- 跟单评分(0-100)
- 做市商/高频交易检测(做市商评分、是否为做市商、是否为高频交易)
- 跟单可靠性标签(🟢 高可靠 / 🟡 中可靠 / 🔴 低可靠 / ❌ 不可跟单)
批量发现聪明钱
bash
python analyze.py discover --top-n 10
python analyze.py discover --top-n 20 --min-profit 100000 --min-volume 500000
python analyze.py discover --top-n 10 --output-json --output-file smart_money.json
发现流程:
- 1. 从Polymarket v1排行榜API获取数据(7种策略)
- 跨维度去重
- 第一阶段预过滤:盈亏/交易量 < 3% → 排除(可能是做市商)
- 获取剩余地址的活动数据
- 第二阶段深度分析:做市商评分 + 高频交易检测
- 排除❌ 不可跟单地址
- 按跟单评分排序
缓存管理
bash
python analyze.py cache list
python analyze.py cache stats
python analyze.py cache clear <地址>
python analyze.py cache clear --all
过滤流程
第一阶段:预过滤(基于排行榜数据,零成本)
| 规则 | 阈值 | 理由 |
|---|
| 盈亏/交易量比率 | < 3% → 排除 | 做市商通过巨额交易量赚取微小价差 |
| 仅交易量上榜 |
排除 | 仅出现在交易量排行榜,未出现在任何盈亏排行榜 |
第二阶段:深度分析(基于活动数据)
做市商评分(0-100,加权)
| 指标 | 权重 | 做市商信号 |
|---|
| 盈亏/交易量比率 | 30% | < 1% |
| 决策频率(仓位/天) |
25% | > 50/天 |
| 买卖平衡度 | 20% | > 0.7(接近1:1) |
| 平均持仓时间 | 15% | < 1小时 |
| 交易金额一致性(变异系数) | 10% | < 0.3 |
做市商评分 > 50 → 标记为做市商。
重要提示:决策频率使用每日仓位数,而非每日交易数。方向性交易者可能通过数百笔交易来建立单一仓位(定投策略)。关键在于他们做出了多少个独立的仓位决策。
高频交易检测(满足3个条件中的2个)
< 4小时 |
| 中位仓位规模 | < $50 |
跟单可靠性标签
| 标签 | 条件 |
|---|
| 🟢 高可靠 | 持仓 > 24小时,< 2个仓位/天,盈亏/交易量 > 10% |
| 🟡 中可靠 |
持仓4-24小时,< 5个仓位/天 |
| 🔴 低可靠 | 持仓 < 4小时或 > 5个仓位/天 |
| ❌ 不可跟单 | 做市商评分 > 50或检测到高频交易 |
数据源
| API | 基础URL | 认证 | 用途 |
|---|
| Gamma API | gamma-api.polymarket.com | 无 | 市场、事件、搜索 |
| Data API v1 |
data-api.polymarket.com/v1 | 无 | 排行榜、仓位、交易、盈亏 |
| CLOB API | clob.polymarket.com | 用于交易 | 订单簿、价格 |
关键端点
GET /v1/leaderboard?category=OVERALL&timePeriod=ALL&orderBy=PNL&limit=50&offset=0
GET /positions?user={地址}
GET /closed-positions?user={地址}
GET /activity?user={地址}
GET /profit-loss?user={地址}
链上数据(第二阶段)
Alchemy RPC配置在.env文件中:
POLYGONRPCURL=https://polygon-mainnet.g.alchemy.com/v2/<密钥>
CTF Exchange合约:0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E
关键事件:OrderFilled — 从链上日志中提取maker/taker地址和交易金额。
免费层限制:每次eth_getLogs调用最多10个区块。
架构
polycopilot/
├── fetcher.py # 数据获取(增量+全量)
├── processor.py # 交易处理,市场报告生成
├── analyzer.py # 评分,做市商/高频交易检测,跟单可靠性
├── discovery.py # 多源钱包发现+过滤
└── cache.py # 增量更新的磁盘缓存
结果解读
向用户展示结果时:
- - 始终突出显示跟单可靠性标签
- 对于❌地址,解释原因(做市商评分、高频交易指标)
- 对于🟢地址,突出关键优势(持仓时间、盈亏/交易量效率)
- 使用跟单评分(0-100,A/B/C/D等级)比较地址
- 面向用户的输出使用中文(用户偏好中文)