with one click
quant-trading-cn
量化交易专家 - 基于印度股市实战经验,支持策略生成、回测、实盘交易(Zerodha/A股适配)
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
量化交易专家 - 基于印度股市实战经验,支持策略生成、回测、实盘交易(Zerodha/A股适配)
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
获取中国经济资讯。仅从官方权威媒体(中国政府网、新华网、人民网、国家统计局、央视财经、中国经济网)抓取高质量经济新闻,自动过滤广告和低质量内容。触发词:中国经济、经济资讯、经济新闻、财经新闻、经济政策、宏观经济、GDP、CPI、PMI、货币政策、财政政策、今日财经。
AI Agent 設定同優化助手 - Prompt Engineering、Task Decomposition、Agent Loop設計
The philosophical layer for AI agents. Maps behavior to Spinoza's 48 affects, calculates persistence scores, and generates geometric self-reports. Give your agent a soul.
Agents can sign plugins, rotate credentials without losing identity, and publicly attest to behavior.
Scaffold MCP server projects and baseline tool contract checks. Use for defining tool schemas, generating starter server layouts, and validating MCP-ready structure.
Generate reusable multi-step agent workflow blueprints. Use for trigger/action orchestration, deterministic workflow definitions, and automation handoff artifacts.
| name | quant-trading-cn |
| description | 量化交易专家 - 基于印度股市实战经验,支持策略生成、回测、实盘交易(Zerodha/A股适配) |
| metadata | {"openclaw":{"emoji":"📈","category":"finance","tags":["trading","quant","algotrading","india","zerodha","backtest"],"requires":{"bins":["python3"]}}} |
基于 1780 行印度股市实战经验的量化交易系统。
# 启动向导
./scripts/wizard.sh
# 选择:
# 1. 从头生成交易机器人
# 2. 增强现有代码(修复问题、优化)
# 3. 从实时指数数据创建股票池
# 4. 运行回测对比
# 5. 分析表现
🔥 关键:Tick Size 四舍五入
错误:kite.place_order(price=1847.35, ...)
报错:"Tick size for this script is 5.00"
修复:price = round(price / tick_size) * tick_size # 1847.35 → 1850.00
影响:90% 订单拒绝是 tick size 错误
🔥 关键:VWAP 必须每日重置
错误:跨天累计 VWAP
症状:回测 65% 胜率,实盘 40%
修复:开盘时重置(9:15)
影响:回测-实盘不一致的第一大原因
./scripts/wizard.sh
向导会问:
# 从 NSE 获取最新成分股
./scripts/universe-fetch.sh --indices nifty50,nifty100,midcap150
./scripts/check-code.sh ./my_trading_bot.py
# 输出:
⚠️ 发现 3 个问题:
1. Tick size 未四舍五入(第 45 行)- 会导致订单拒绝
2. VWAP 未每日重置(第 89 行)- 回测实盘不一致
3. 无股票冷却期(第 120 行)- 报复交易风险
| 优化 | 之前 | 之后 | 提升 |
|---|---|---|---|
| Parquet 缓存 | 2.3s | 0.08s | 28.7x |
| Polars 向量化 | 450ms | 12ms | 37.5x |
| API 批量请求 | 15 次 | 1 次 | 15x |
| 预计算指标 | 180ms | 90ms | 2x |
| 总回测时间 | 5 min | 12 sec | 25x |
quant-trading-cn/
├── SKILL.md # 本文件
├── KNOWLEDGE.md # 16 个领域(1780 行)
├── NUANCES.md # 30+ 陷阱
├── scripts/
│ ├── wizard.sh # 交互式向导
│ ├── universe-fetch.sh # 股票池获取
│ └── check-code.sh # 代码检查
└── references/
├── KNOWLEDGE_en.md # 原始英文版
└── NUANCES_en.md # 原始英文版
本项目基于印度市场,但可适配 A 股:
| 印度 | A 股 |
|---|---|
| Zerodha | 雪球/同花顺 |
| Nifty 50 | 沪深 300 |
| Nifty Midcap | 中证 500 |
| T+1 结算 | T+1 结算 |
| 9:15-15:30 | 9:30-15:00 |
⚠️ 本 skill 提供教育性指导,不保证盈利。交易有风险,仅用可承受资金。
版本: 1.0.0 来源: skill-algotrader