Quant oral to code
把口述或抽象策略想法转换成可回测代码骨架、回测入口和结果报告,并在生成前做 DSL 提炼与风险护栏审查。Invoke when 用户希望把量化思路直接写成策略代码。From its SKILL.md
npx -y skills add 2033121/quant-oral-to-code --skill quant-oral-to-codeAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
- runs commandsInstructs the agent to run 1 command, including `python "skills/quant-oral-to-code/scripts/validate_quant_oral_to_code.py"`.
SKILL.md
2.0 KB, 619 tokens by cl100k_base, as published. Nobody here has run it
quant-oral-to-code
这个 skill 的目标是把自然语言策略描述整理成一条清晰链路:
intake收集策略口述、数据条件和输出预期。dsl把口述压缩成结构化策略规格。guardrails审查前视、过拟合、样本外缺失和乐观成交假设。codegen生成策略代码骨架与回测入口。report输出交付说明、限制和下一步建议。
当前阶段只提供最小可运行骨架,重点是把模块边界和验证入口搭起来,供后续任务继续填充脚本、模板、schema 和例子。
固定口径
- 标准数据归一化目标固定为 DuckDB;后续导入 CSV/Parquet/JSON/SQLite 时,也要先落到 DuckDB 再进入统一回测路径。
- claim level 的基础枚举至少包含
demo_only、portable_backtest、research_grade_local。 - 缺少真实数据、字段映射或关键定义时,必须进入 cutoff /
DATA_REQUIRED路径,而不是伪装成正式回测完成。
使用顺序
默认按以下顺序读取模块:
modules/preflight.mdmodules/intake.mdmodules/dsl.mdmodules/guardrails.mdmodules/data.mdmodules/codegen.mdmodules/onboarding.mdmodules/report.md
当前交付约束
- 只承诺生成骨架,不承诺已经具备完整回测能力。
- 没有真实数据时,必须明确说明不能伪装成研究级回测结论。
- 输出中要显式标记假设、缺口和需要用户补充的数据。
- 当前默认链路已经接入 Task 2 的权威模块:preflight、DuckDB 数据契约、claim gate 和 onboarding 文案。
验证
结构验证脚本:
python "skills/quant-oral-to-code/scripts/validate_quant_oral_to_code.py"
What ships with it: 84 files
211.6 KB alongside SKILL.md, 43 of them executable
examples/
modules/
- codegen.md815 B
- data.md1.2 KB
- dsl.md1.1 KB
- guardrails.md950 B
- intake.md1.1 KB
- onboarding.md902 B
- preflight.md1.2 KB
- report.md677 B
references/
- a_share_provider_notes.md1.8 KB
- data_access_matrix.json2.6 KB
- domain_ontology.json1.5 KB
- example_registry.json585 B
- guardrail_rules.json1.6 KB
schemas/
- claim_report.schema.json1.6 KB
- data_contract.schema.json2.5 KB
- data_profile.schema.json898 B
- experiment_protocol.schema.json472 B
- generated_artifact_manifest.schema.json1.8 KB
- guardrail_review.schema.json1.1 KB
- preflight_report.schema.json1.7 KB
- strategy_spec.schema.json1.6 KB
- translation_trace.schema.json1.3 KB
scripts/
- backtest_kernel.pyruns2.3 KB
- build_claim_report.pyruns7.9 KB
- build_data_contract.pyruns2.3 KB
- build_demo_dataset.pyruns981 B
- build_strategy_spec.pyruns6.0 KB
- check_runtime_capabilities.pyruns1.8 KB
- detect_data_profile.pyruns1.9 KB
- emit_artifact_manifest.pyruns3.1 KB
- emit_translation_trace.pyruns4.1 KB
- generate_backtest_runner.pyruns2.8 KB
- generate_data_fetcher.pyruns4.3 KB
- generate_strategy_code.pyruns2.5 KB
44 more files not listed here. See all 84 in the repository.