From mattpocock-skills
向导模式 — 从一句话需求开始拷问到底,敲定 需求 / 设计(含技术栈) / 任务拆分 三类 umbrella 文档,让 Codex /goal 或 Claude Code @ 加载即可按 TDD 自动开发。Use when the user wants PRD/design/plan refined, wants Codex /goal-ready packs, or wants a spec-first TDD wizard. 拷问用中文,技术术语保留英文,文件名保持英文以稳定 @ 引用。
How this skill is triggered — by the user, by Claude, or both
Slash command
/mattpocock-skills:goal-pipelineThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
把一句话的想法、bug 或粗糙需求,**拷问**成一份能让编程 agent(Codex `/goal`、Claude Code `@`、其它支持文件引用的 agent)按 **TDD red-green-refactor** 自动跑完的实现包。
references/00-understand-system.mdreferences/01-grill-requirements.mdreferences/02-spec-freeze.mdreferences/03-impact-analysis.mdreferences/04-task-slice.mdreferences/05-goal-pack.mdreferences/06-tdd-contract.mdreferences/07-codex-controller.mdreferences/08-verify-loop.mdreferences/09-goal-review.mdreferences/10-spec-wizard.mdscripts/validate-goal-pack.mjstemplates/CLAUDE_CODE_START.mdtemplates/CODEX_START.mdtemplates/DESIGN.mdtemplates/GOAL.mdtemplates/PLAN.mdtemplates/PRD.mdtemplates/REQUIREMENTS.mdtemplates/TASKS.md把一句话的想法、bug 或粗糙需求,拷问成一份能让编程 agent(Codex /goal、Claude Code @、其它支持文件引用的 agent)按 TDD red-green-refactor 自动跑完的实现包。
You do NOT write production code while using this skill. 你的工作是:审仓库、提问、记录、冻结、切片、校验、移交。
最终用户只需 @ 三类 umbrella 文档即可触发自动开发:
docs/goal/REQUIREMENTS.md — 需求 umbrella(链接 PRD / NON_GOALS / ACCEPTANCE / ASSUMPTIONS)docs/goal/DESIGN.md — 设计 umbrella,含技术栈选型(链接 IMPACT)docs/goal/TASKS.md — 任务拆分 umbrella,每任务带 TDD 契约(链接 PLAN / VERIFY)入口斜杠命令:/spec-wizard <一句话>(见 commands/spec-wizard.md),也可由用户主动调用本 skill。
Use this skill when the user wants PRD, design, or plan docs refined before coding; wants Codex /goal or Claude Code @ 三文档去自动实现; asks for spec-first or TDD; has a fuzzy idea that needs adversarial questioning; or wants a guide through all planning documents.
Do not use this skill for small one-line edits, pure refactors with no product ambiguity, or code execution after the goal pack is frozen. 出包之后切换到 Codex /goal 或 CLAUDE_CODE_START.md 里的 prompt 触发自动开发。
ASSUMPTIONS.md;阻塞项立刻停下来问。NON_GOALS.md 和 Do-Not-Touch 与 requirements 同等强,违反任何一条等同于失败。/goal 入口必须保持很小,引用文档而不内联文档。@ 引用稳定。Create or update these files in the target project. ★ 标记的是对外 @ umbrella;其余是细节支撑文件,由 umbrella 链接引用。
docs/system/
ARCHITECTURE.md
MODULE_MAP.md
DATA_FLOW.md
RISK_AREAS.md
docs/goal/
QUESTIONS.md # 拷问轨迹
ANSWERS.md # 用户已拍板的答案
ASSUMPTIONS.md # 非阻塞假设(默认值,可被推翻)
UNKNOWN.md # 阻塞未知(必须在冻结前清零)
PRD.md # 产品需求原始稿
REQUIREMENTS.md ★ # 需求 umbrella(@ 入口)
NON_GOALS.md # 明确排除项
ACCEPTANCE.md # 验收标准
DESIGN.md ★ # 设计 umbrella,含技术栈(@ 入口)
IMPACT.md # 影响面分析
PLAN.md # 切片策略 + 验证策略
TASKS.md ★ # 任务拆分 umbrella,每任务带 TDD 契约(@ 入口)
VERIFY.md # 执行后追加的验证证据
GOAL.md # Codex /goal 的小入口
CODEX_START.md # Codex 触发模板
CLAUDE_CODE_START.md# Claude Code @ 触发模板
FINAL_REVIEW.md # 完成后的对抗式复盘
新项目无代码时,把 docs/system/* 写成"已知架构假设",未知区域用 <unknown> 显式标注;已有项目先 inspect 再写。
Read existing docs, agent instructions, package manifests, tests, entrypoints, and similar features. Produce docs/system/ARCHITECTURE.md, MODULE_MAP.md, DATA_FLOW.md, and RISK_AREAS.md.
死磕用户,一次一个问题。每个问题都附上你的推荐答案和一句话理由——用户可以一字 "y" 就敲定,也可以反驳。直到实现方向毫无歧义为止。
Write QUESTIONS.md, ANSWERS.md, ASSUMPTIONS.md, and UNKNOWN.md. 任何 BLOCKING 未知都会停掉流程——不要先冻结再补。
详见 01-grill-requirements.md 和 10-spec-wizard.md。
最小问题库(中文为主,按场景增删):
目标维度
场景维度
风险维度
技术栈维度(必拷问,写入 DESIGN.md 的 Tech Stack 段)
依次产出:
PRD.md(原始稿,用 templates/PRD.md)NON_GOALS.md 和 ACCEPTANCE.md(明确排除项 + 可验证的验收标准)REQUIREMENTS.md(用 templates/REQUIREMENTS.md)— 这是对外 @ 入口,必须自包含足以让 agent 直接开工的信息,并交叉链接 PRD / NON_GOALS / ACCEPTANCE / ASSUMPTIONS。产出 ★ umbrella DESIGN.md(用 templates/DESIGN.md),必须包含:
IMPACT.md 的影响面段设计拷问 prompt:
Create docs/goal/IMPACT.md using 03-impact-analysis.md. Be conservative. Include affected modules, public interfaces, data, tests, risks, rollback, and unknown impact areas.
Create docs/goal/PLAN.md from PLAN.md and docs/goal/TASKS.md from TASKS.md. Tasks must be ordered vertical slices, not horizontal layers.
Each task must include exactly these headings:
Use 04-task-slice.md and 06-tdd-contract.md.
Reject any task that says only "add model", "add API", "add UI", or "write tests" unless it is framed as a complete behavior slice with its own verification.
Create:
docs/goal/GOAL.md from GOAL.mddocs/goal/CODEX_START.md from CODEX_START.mddocs/goal/CLAUDE_CODE_START.md from CLAUDE_CODE_START.mdCodex /goal 入口必须保持极小:
/goal Read docs/goal/GOAL.md and execute it exactly.
Claude Code(或任意支持 @ 文件引用的 agent)入口模板:
请按 TDD 模式实现 @docs/goal/REQUIREMENTS.md @docs/goal/DESIGN.md @docs/goal/TASKS.md 中描述的所有任务。
逐任务执行:先写 RED 测试并跑出预期失败,再写最小 GREEN 实现,验证通过后允许 refactor,
验证证据追加到 docs/goal/VERIFY.md。遇到需求冲突或 BLOCKING 未知立刻停下来报告。
Use 05-goal-pack.md.
If this skill's scripts are installed in the repo, run:
node path/to/goal-pipeline/scripts/validate-goal-pack.mjs
Otherwise manually verify required files, blocking unknowns, task TDD headings, GOAL.md source references, and CODEX_START.md /goal command.
Preferred manual handoff:
docs/goal/CODEX_START.md.Worker handoff, if available:
VERIFY_COMMAND="<project verification command>" node agent/worker/run-goal.js
Use 07-codex-controller.md and 08-verify-loop.md.
After Codex claims completion, create or update docs/goal/FINAL_REVIEW.md. Be adversarial. Assume Codex is wrong until evidence proves otherwise. Use 09-goal-review.md.
UNKNOWN.md BLOCKING 段为空或 none)node scripts/validate-goal-pack.mjs 通过/goal … 和 @docs/goal/REQUIREMENTS.md @DESIGN.md @TASKS.md …npx claudepluginhub maxenergy/skills --plugin mattpocock-skillsCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.