← 返回 Skills 市场
weistiger

PTRADE量化策略生成器

作者 weistiger · GitHub ↗ · v1.0.2 · MIT-0
cross-platform ⚠ suspicious
158
总下载
0
收藏
0
当前安装
3
版本数
在 OpenClaw 中安装
/install ptrade-strategy
功能描述
国金 PTRADE 量化平台策略生成技能。根据用户需求, 生成可在 PTRADE 平台运行�?Python 量化交易策略代码�? 触发关键词:PTRADE、ptrade、量化策略、量化交易、生成策略、写策略代码�?
安全使用建议
This skill contains ready-made PTRADE strategy templates and claims to use a knowledge base in IMA. Before installing or using: 1) Confirm how the skill will access the IMA knowledge base — if external IMA credentials are required (ima-openapi-clientid / ima-openapi-apikey), provide them only after verifying trust and necessity. 2) Review and test the provided templates in a sandbox/backtest environment — these templates call trade.open_long/close_long and will place orders when run on a live account. 3) Note API mismatches: SKILL.md says get_price() is the core API but templates use security.get_bars(); verify which API your PTRADE runtime expects and update templates accordingly. 4) The skill expects common Python libs (numpy/pandas) and platform helpers (get_json('context')) but does not declare them; ensure your runtime supplies them. 5) If you will run strategies against a real brokerage account, restrict credentials, run with minimal permissions, and test thoroughly in paper mode first. If you need greater assurance, ask the publisher for clarification about IMA access, declared dependencies, and which PTRADE API surface the templates target.
功能分析
Type: OpenClaw Skill Name: ptrade-strategy Version: 1.0.2 The skill bundle is designed to generate quantitative trading strategies for the Guojin PTRADE platform. It provides standard trading templates (Moving Average, Financial Factors) and comprehensive API documentation in SKILL.md and README.md. The code logic is consistent with the stated purpose of financial modeling, and no indicators of data exfiltration, unauthorized network access, or malicious prompt injection were found. While there are minor discrepancies between the templates and the instructions regarding specific API usage (e.g., get_bars vs get_price), these are functional bugs rather than security risks.
能力评估
Purpose & Capability
The skill claims to read the IMA knowledge base (国金量化) to generate PTRADE strategies, and the repo includes PTRADE templates — that matches the described purpose. However, the kb_ref.md documents indicate IMA access requires ima-openapi-clientid / ima-openapi-apikey, yet the skill declares no required env vars or credentials. Also README and SKILL.md disagree on core APIs (SKILL.md warns that get_price() is the core API; README and most templates use security.get_bars()). These mismatches suggest the skill's declared capabilities and its actual runtime assumptions are not fully aligned.
Instruction Scope
SKILL.md states the skill will read the IMA knowledge base; it does not instruct the agent to read arbitrary local files or exfiltrate data, and the included templates are purely strategy code. But the instructions/documentation inconsistently reference different PTRADE APIs (get_price vs security.get_bars). Templates call platform functions (security.get_bars, trade.open_long/close_long, get_json('context')) which assume specific platform-provided objects and helper functions; SKILL.md does not declare or justify these runtime assumptions. This leaves ambiguous what credentials or environment the agent needs and what data access will actually occur at runtime.
Install Mechanism
No install spec; skill is instruction-only with templates included. Nothing is downloaded or written by an installer, which is the lowest-risk install mechanism.
Credentials
The skill declares no required env vars or credentials, yet kb_ref.md documents show an IMA API that requires ima-openapi-clientid and ima-openapi-apikey. The templates also assume common Python libraries (numpy, pandas) and platform-provided functions/objects (security, trade, get_json), but the skill does not declare those as required dependencies. Missing dependency/credential declarations are a proportionality/information gap — it may require secrets or libraries not disclosed.
Persistence & Privilege
The skill does not request always:true, does not modify other skills, and does not request system-wide config or persistent privileges. Autonomous invocation is allowed (platform default) but is not combined with other high-risk flags here.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install ptrade-strategy
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /ptrade-strategy 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.2
- Clarified that the skill can now “生成或修改” (generate or modify) PTRADE 策略代码 in the overview section. - Standardized and corrected section titles such as “定时或周期 API”, “交易API”, “计算/指标 API”, and “其他工具API” for improved clarity. - Improved some description texts for accuracy and readability. - Aligned and cleaned up code and comments formatting. - Fixed some Chinese display issues and typos in layout and comments.
v1.0.1
- Major documentation update: SKILL.md fully rewritten to match PTRADE新版API和平台架构规范。 - API使用方式大幅调整为 get_price() 及 order() 等官方接口,修正所有策略模板与调用说明。 - 新增所有 PTRADE 平台支持的策略生命周期函数与扩展回调说明。 - 完整补充行情、证券、委托、查询、指标等常用API参考列表。 - 详细说明 context/g/position/order 数据结构,方便快速上手。 - 移除旧版 PTRADE 量化接口(如 security.get_bars),统一为新接口标准。
v1.0.0
- Initial release of the PTRADE 量化策略生成 skill. - Generates Python trading strategy code compatible with 国金 PTRADE platform based on user input. - Includes detailed API references, data sources, and common code templates for strategies such as dual moving averages, financial factor stock selection, and intraday trading. - Lists supported data science and machine learning libraries for advanced strategy development. - Provides workflow guidance for generating strategies and practical notes for PTRADE platform usage.
元数据
Slug ptrade-strategy
版本 1.0.2
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 3
常见问题

PTRADE量化策略生成器 是什么?

国金 PTRADE 量化平台策略生成技能。根据用户需求, 生成可在 PTRADE 平台运行�?Python 量化交易策略代码�? 触发关键词:PTRADE、ptrade、量化策略、量化交易、生成策略、写策略代码�?. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 158 次。

如何安装 PTRADE量化策略生成器?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install ptrade-strategy」即可一键安装,无需额外配置。

PTRADE量化策略生成器 是免费的吗?

是的,PTRADE量化策略生成器 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

PTRADE量化策略生成器 支持哪些平台?

PTRADE量化策略生成器 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 PTRADE量化策略生成器?

由 weistiger(@weistiger)开发并维护,当前版本 v1.0.2。

💬 留言讨论