← 返回 Skills 市场
shawn92

Skills of A-share futures data released by ft.tech.

作者 Shawn92 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ 安全检测通过
290
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install ftshare-futures-data
功能描述
非凸科技期货数据技能集(market.ft.tech)。覆盖指定交易日合约列表、期货合约基础信息(交易单位、保证金、交割等)、期货 K 线(分钟/日及周月季年聚合)。用户询问期货合约列表、某合约基础信息、期货 K 线或历史行情时使用。用户只给中文名/品种时,先用 futures-lists 做名称到 symbol...
使用说明 (SKILL.md)

FT 期货数据 Skills

本 skill 是 FTShare-futures-data统一路由入口

根据用户问题,从下方「能力总览」或「子 skill 与用户问法示例」匹配子 skill,通过 run.py 执行并解析响应。

所有接口均以 https://market.ft.tech 为基础域名,路径前缀为 /data/api/v1/market/data/futures,使用 HTTP GET;无需 X-Client-Name 等额外请求头(脚本不设置自定义头)。


调用方式(唯一规则)

run.py 与本文件(SKILL.md)位于同一目录。执行时:

  1. 取本文件的绝对路径,将末尾 /SKILL.md 替换为 /run.py,得到 \x3CRUN_PY>
  2. 调用:python \x3CRUN_PY> \x3C子skill名> [参数...]
# 示例(\x3CRUN_PY> 为实际绝对路径)
python \x3CRUN_PY> futures-lists --trade-date 20260331
python \x3CRUN_PY> futures-base-data --trade-date 20260331 --symbol A2605.DCE
python \x3CRUN_PY> futures-kline --symbol A2605.DCE --interval 30min --limit 50
python \x3CRUN_PY> futures-kline --symbol A2605.DCE --interval daily --start 1772294400000 --end 1774972799999 --limit 100

run.py 内部通过 __file__ 自定位,无论安装在何处都能正确找到各子 skill 的脚本。


典型调用顺序

  1. 先要合约代码(名称→代码映射):用户只说中文名/品种(如“豆一2605”“螺纹2505”)时,先 futures-lists --trade-date \x3CYYYYMMDD>,在 items 里按 symbol_cn_name / product 匹配,得到 symbol(WIND 全码,如 A2605.DCE)。
  2. 基础信息futures-base-data --trade-date \x3C可选> --symbol \x3CWIND全码>
  3. K 线futures-kline --symbol \x3CWIND全码> [--interval] [--start --end] [--limit]--start--end 必须成对传入。

毫秒时间戳:若需交易日边界转 start/end,可使用 FTShare-kline-data(或本仓库其他包)中的 get-nth-trade-date 得到日期后再换算为东八区毫秒时间戳。


能力总览

  • futures-lists:查询指定交易日期货合约列表。可选:--trade-date(YYYYMMDD);不传默认前一交易日(CST)。GET /data/api/v1/market/data/futures/futures-lists
  • futures-base-data:查询期货基础信息。可选:--trade-date--symbol;不传 --symbol 则该日全部合约。GET /data/api/v1/market/data/futures/futures-base-data
  • futures-kline:查询期货 K 线。必填:--symbol;可选:--interval--start--end--limitGET /data/api/v1/market/data/futures/kline

使用流程

  1. 记录本文件绝对路径,将 /SKILL.md 替换为 /run.py 得到 \x3CRUN_PY>
  2. 理解用户意图,从「能力总览」匹配子 skill。
  3. 若用户给的是中文名/品种而非 symbol:先调 futures-lists 做名称映射,拿到 symbol 后再查 futures-base-datafutures-kline
  4. (可选)读取 sub-skills/\x3C子skill名>/SKILL.md 了解参数与响应字段。
  5. 执行python \x3CRUN_PY> \x3C子skill名> [参数...]
  6. 解析并输出:以表格或要点形式展示。

子 skill 与用户问法示例

用户问法示例 子 skill 名
「期货列表」「某日全部期货合约」「合约代码清单」 futures-lists
「豆一2605 对应代码是什么」「按中文名找期货代码」 futures-lists(按 symbol_cn_name/product 匹配)
「A2605 基础信息」「保证金/交割/乘数/交易单位」 futures-base-data
「期货 K 线」「分钟线/日线/周线」「某合约历史行情」 futures-kline
安全使用建议
This skill appears coherent and limited to fetching futures data from market.ft.tech and requires no credentials. Before installing, review the included Python files (run.py and sub-skill handlers) because the agent will execute that code locally — if you don't trust the skill source, don't install. Note the minor risk: the code validates the initial request host but not downstream HTTP redirects, so a malicious upstream redirect could expose responses from other hosts; if you need stronger safety, run in a restricted environment or add redirect checks/timeout policies. Otherwise, the footprint matches the described purpose.
功能分析
Type: OpenClaw Skill Name: ftshare-futures-data Version: 1.0.0 The skill bundle is a well-structured tool for retrieving futures market data from 'market.ft.tech'. It implements several security best practices, including a whitelist-based dispatcher in 'run.py' to prevent path traversal and a 'safe_urlopen' function in each handler (e.g., sub-skills/futures-kline/scripts/handler.py) that restricts network requests to the authorized domain. The code uses standard libraries, lacks obfuscation, and contains no evidence of data exfiltration or malicious prompt injection.
能力评估
Purpose & Capability
Name/description describe querying futures data from market.ft.tech; the code and SKILL.md only call endpoints under https://market.ft.tech and require no unrelated binaries, env vars, or config paths. The requested capabilities match the stated purpose.
Instruction Scope
Runtime instructions are narrow: execute run.py which dispatches to local sub-skill handlers that build GET requests to market.ft.tech and print JSON. Handlers validate the URL's scheme and netloc before opening. They do not read other files, environment variables, or external endpoints. Note: the skill executes provided local Python handler code (runpy.run_path), so the package's code runs with the agent's permissions — review included scripts before installing. Also, safe_urlopen validates only the initial URL; urllib opener may follow redirects from the server to other hosts, which is a subtle risk if the upstream service issues redirects.
Install Mechanism
No install spec (instruction-only with bundled Python scripts). Nothing is downloaded or written during install; all code is included in the skill bundle.
Credentials
The skill declares no environment variables, credentials, or config paths and the code does not access secrets — proportional to its function of public-data HTTP GETs.
Persistence & Privilege
always:false and user-invocable:true (defaults). The skill does not request persistent/system-wide privileges or modify other skills; it simply executes bundled handlers when invoked.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install ftshare-futures-data
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /ftshare-futures-data 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release of FTShare-futures-data skill. - Provides unified access to FT futures data via sub-skills: contract list, base info, and K line/history. - Supports contract code lookup by Chinese name or product via futures-lists. - Simple CLI-based usage: calls run.py with sub-skill and parameters. - All APIs are HTTP GET to market.ft.tech, with required/optional parameters clearly described. - Typical workflow and usage examples included in documentation.
元数据
Slug ftshare-futures-data
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Skills of A-share futures data released by ft.tech. 是什么?

非凸科技期货数据技能集(market.ft.tech)。覆盖指定交易日合约列表、期货合约基础信息(交易单位、保证金、交割等)、期货 K 线(分钟/日及周月季年聚合)。用户询问期货合约列表、某合约基础信息、期货 K 线或历史行情时使用。用户只给中文名/品种时,先用 futures-lists 做名称到 symbol... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 290 次。

如何安装 Skills of A-share futures data released by ft.tech.?

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

Skills of A-share futures data released by ft.tech. 是免费的吗?

是的,Skills of A-share futures data released by ft.tech. 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Skills of A-share futures data released by ft.tech. 支持哪些平台?

Skills of A-share futures data released by ft.tech. 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Skills of A-share futures data released by ft.tech.?

由 Shawn92(@shawn92)开发并维护,当前版本 v1.0.0。

💬 留言讨论