← 返回 Skills 市场
Ai Quant Trader
作者
yuhuijiang2025-cell
· GitHub ↗
· v1.0.0
510
总下载
2
收藏
6
当前安装
1
版本数
在 OpenClaw 中安装
/install ai-quant-trader
功能描述
基于AKShare的AI量化交易助手,实现策略生成、参数优化、自动交易、止盈止损及实时选股模拟。
使用说明 (SKILL.md)
AI量化交易助手技能
技能概述
基于AKShare的AI驱动量化交易模拟系统,支持AI策略生成、自动交易、风险控制和实时选股。
核心功能
- 模拟实时交易(支持蜻蜓点金手续费规则)
- AI大模型生成交易策略
- AI优化策略参数
- 自动策略执行
- 止盈止损管理
- 策略胜率统计
- AI实时选股
安装依赖
pip install akshare pandas numpy
简化版使用(无需安装依赖)
如果Python环境有问题,可以使用简化对话版:
- 直接通过OpenClaw对话使用所有功能
- AI会模拟执行筛选、分析、策略生成
- 查看
SIMPLIFIED_SKILL.md了解详情
命令列表
交易命令
/交易 设置本金 [金额]- 设置初始资金(默认100000)/交易 买入 [股票代码] [数量]- 买入股票/交易 卖出 [股票代码] [数量]- 卖出股票/持仓- 查看当前持仓
策略命令
/策略 生成 [描述]- AI生成交易策略/策略 优化 [策略名]- 优化策略参数/策略 列表- 查看所有策略/策略 回测 [策略名]- 回测策略表现
自动交易
/自动 启用 [策略名] [股票代码]- 启用自动交易/自动 暂停 [股票代码]- 暂停自动交易/自动 列表- 查看自动交易状态
风控命令
/风控 设置止损 [股票代码] [百分比]- 设置止损(如5%)/风控 设置止盈 [股票代码] [百分比]- 设置止盈(如10%)/风控 移动止盈 [股票代码] [回撤百分比]- 设置移动止盈
选股统计
/选股 今日推荐- AI推荐今日股票/选股 筛选 [条件]- 按条件筛选股票/统计 [策略名]- 查看策略统计
文件结构
ai-quant-trader/
├── SKILL.md # 技能文档
├── main.py # 主程序
├── broker.py # 模拟交易引擎
├── strategy_gen.py # AI策略生成器
├── auto_trader.py # 自动交易执行
├── risk_manager.py # 风控管理
├── stock_screener.py # 选股引擎
└── data_provider.py # 数据提供
使用示例
用户:/交易 设置本金 100000
AI:✅ 已设置初始资金:100,000元
用户:/选股 今日推荐
AI:📈 今日AI推荐:
1. 600519 贵州茅台 (MACD金叉,趋势向上)
2. 000858 五粮液 (RSI超卖反弹)
用户:/策略 生成 "一个基于MACD金叉的短线策略"
AI:🤖 已生成策略"MACD短线策略",代码已保存
用户:/自动 启用 MACD短线策略 600519
AI:✅ 已为600519启用MACD短线策略,开始自动监控
注意事项
- 所有交易均为模拟,不涉及真实资金
- AI策略仅供参考,投资有风险
- 数据来自AKShare,可能有延迟
- 建议先小额测试,熟悉系统后再增加资金
安全使用建议
What to consider before installing or running this skill:
- Functional fit: The code and docs align with an AKShare-based simulated quant-trader; akshare/pandas/numpy are reasonable dependencies for that purpose.
- Review the register script before running: register_with_openclaw.py copies files into a hard-coded Windows Administrator OpenClaw path (C:/Users/Administrator/.openclaw/...). If you run it it will create/overwrite skill files and write an enabled skill_config.json. Edit the script to point to the correct OpenClaw workspace for your account (use environment variables like %USERPROFILE% or HOME) or avoid running it and install manually.
- Backup first: If you plan to use the register script, back up your existing OpenClaw skills directory. The script can move/overwrite existing skill directories (it does a move to a backup name but that can still change state).
- Run in a sandbox/test account: Because the package creates files and caches under the skill directory (user_data, data_cache, etc.), test it in an isolated environment or throwaway VM/container before running on your main workstation.
- Inspect outputs of check_env.py: It prints Python executable, working dir, and sys.path — useful for debugging but avoid sharing its output publicly as it reveals environment details.
- Network behavior: The skill uses AKShare to fetch market data (expected). If you must avoid external network calls, do not run modules that call akshare.
- No secrets requested: The skill does not request API keys or other credentials, which is coherent for a simulated system. However, if you later link a real broker, that would change the risk profile — treat broker integrations as sensitive.
- If you are unsure: Ask the skill author for a non-admin installation method or an OpenClaw-market-style packaging option. If you want, I can point out the exact lines in register_with_openclaw.py to change to make it safer (use relative paths, use current user profile, avoid auto-enabling).
功能分析
Type: OpenClaw Skill
Name: ai-quant-trader
Version: 1.0.0
The bundle provides a comprehensive AI-driven stock trading simulation using the akshare library, but it includes several high-risk administrative scripts that modify the host environment. Specifically, 'simple_fix.py' uses subprocess to execute 'pip install' and 'exec()' to run code, while 'register_with_openclaw.py' performs file system manipulations on a hardcoded sensitive path ('C:/Users/Administrator/.openclaw/workspace/skills'). Additionally, 'auto_trader.py' and 'risk_manager.py' implement background monitoring threads; while these align with the stated purpose of real-time trading, the combination of environment-modifying installers and persistent background execution represents a significant attack surface without clear necessity for a standard AI agent skill.
能力评估
Purpose & Capability
The skill's name, description, SKILL.md, and Python modules (data_provider, strategy_gen, broker, auto_trader, risk_manager, stock_screener) are consistent with an AKShare-based simulated quant trading assistant and require akshare/pandas/numpy as declared. However, the presence of register_with_openclaw.py (which copies files into a user's OpenClaw workspace) implies installer-like behavior beyond a pure 'instruction-only' skill; that is plausible for an OpenClaw integration but is more intrusive than the simple description suggests.
Instruction Scope
SKILL.md instructions are focused on simulation, strategy generation, and using AKShare; it asks the user to pip install akshare/pandas/numpy. The runtime code will create and read files under a user_data directory and caches. check_env.py prints system paths and working directory (revealing environment info) — harmless if run locally but not needed for core functionality. SKILL.md does not explicitly instruct running the register script, but that script exists and would alter user skill directories if executed.
Install Mechanism
There is no declared automated install spec, but the repository includes register_with_openclaw.py which, if run, copies files into a hard-coded Windows path (C:/Users/Administrator/.openclaw/workspace/skills). This is an ad-hoc install mechanism that will write files to the host, create/overwrite skill directories, and create an enabled skill_config.json. The copy/backup behavior is potentially destructive if paths are wrong or if you run it as an administrator.
Credentials
The registry metadata declares no required env vars or credentials (appropriate for a simulated trader). The code uses AKShare which performs external network requests for market data (expected). check_env.py prints environment details (python path, working dir, sys.path) which is not required for normal operation and could leak environment information if you share its output.
Persistence & Privilege
always is false, and the skill requires no cloud credentials — good. But register_with_openclaw.py will create files inside the user's OpenClaw skills directory and write an enabled skill_config.json (registered_at, dependencies, enabled=true). Running that script grants the skill persistent presence in the user's OpenClaw installation and may overwrite or move existing skill directories (it moves existing target to a backup name). This file-system-level persistence is significant and should be executed only after review.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install ai-quant-trader - 安装完成后,直接呼叫该 Skill 的名称或使用
/ai-quant-trader触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
AI量化交易助手技能 v1.0.0 初始发布:
- 提供基于AKShare的数据驱动的AI量化交易模拟,包括策略生成、参数优化、自动化交易和风控功能。
- 支持模拟买卖、AI选股、止盈止损、策略胜率统计等完整量化流程。
- 提供简化版对话模式,免依赖安装,直接对话式操控所有核心功能。
- 覆盖丰富的命令体系,便于用户快速操作持仓、策略、自动化及风控管理。
- 明确说明所有交易为模拟,策略建议仅供参考。
元数据
常见问题
Ai Quant Trader 是什么?
基于AKShare的AI量化交易助手,实现策略生成、参数优化、自动交易、止盈止损及实时选股模拟。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 510 次。
如何安装 Ai Quant Trader?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install ai-quant-trader」即可一键安装,无需额外配置。
Ai Quant Trader 是免费的吗?
是的,Ai Quant Trader 完全免费(开源免费),可自由下载、安装和使用。
Ai Quant Trader 支持哪些平台?
Ai Quant Trader 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Ai Quant Trader?
由 yuhuijiang2025-cell(@yuhuijiang2025-cell)开发并维护,当前版本 v1.0.0。
推荐 Skills