issue-to-plan
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseIssue to Plan
Issue 转计划
Overview
概述
Turn a finalized issue into a draft PR plus a single marked plan comment, then stop. The draft PR and its plan comment are the durable boundary between planning and execution.
Core principle: planning and execution happen in separate contexts. This skill never runs SDD or dispatches Task 1.
The plan lives in a PR comment, never the description. The description stays a concise, reviewer-facing summary ( + change summary + test plan): the simplest merge path — squash-merging from the GitHub web UI, which prefills the commit message from the PR body — then produces a clean commit message instead of a multi-kilobyte plan.
Closes #N将已最终确定的issue转化为一个draft PR外加一条带标记的计划评论,然后停止。draft PR及其计划评论是规划与执行之间的持久边界。
核心原则: 规划和执行在不同的上下文中进行。本技能绝不会运行SDD或派发任务1。
计划存放在PR评论中,绝不会放在描述里。PR描述保持为面向评审者的简洁摘要( + 变更摘要 + 测试计划):最简单的合并路径——通过GitHub网页界面进行squash合并(会自动用PR正文预填提交信息)——这样会生成干净的提交信息,而不是几千字的计划。
Closes #NEntry Gate (all 5 steps, in order)
准入门槛(共5步,按顺序执行)
- Run .
gh issue view <N> --json number,title,body,state - If the title starts with , stop and route to
[DRAFT].brainstorming-to-issue - If the entire change is one file, one behavior, and one red-green-commit review pass, use directly. Uncertainty means it is not trivial.
superpowers:test-driven-development - Claim the issue per repository rules: assign it and add the label.
in-progress - Retain for the PR description.
Closes #<N>
- 运行 。
gh issue view <N> --json number,title,body,state - 如果标题以 开头,停止并转至
[DRAFT]。brainstorming-to-issue - 如果整个变更仅涉及单个文件、单个行为,且只需一次红-绿提交评审流程,请直接使用 。存在不确定性就说明它不是简单变更。
superpowers:test-driven-development - 按照仓库规则认领issue:分配给自己并添加 标签。
in-progress - 在PR描述中保留 。
Closes #<N>
Generate the Plan (all 3 steps, in order)
生成计划(共3步,按顺序执行)
- REQUIRED SUB-SKILL: — create the execution worktree and branch first, before any plan is written. Declared worktree preference — never ask: always isolate. This is the user's standing answer to that skill's Step 0 consent question; prefer the native worktree tool (
superpowers:using-git-worktreesor equivalent), elseEnterWorktreeundergit worktree add. If its Step 3 baseline tests fail, do not ask whether to proceed — stop and report the failures; never plan or implement on a red baseline..worktrees/<branch> - REQUIRED SUB-SKILL: — including its Self-Review, File Structure, Global Constraints, per-task Interfaces, and bite-sized TDD steps.
superpowers:writing-plans - Override inside — its persistence and handoff only:
writing-plans- Write the plan to in the execution worktree, protected by the nested scratch
.superpowers/sdd/plan.mdconvention..gitignore - Never write it under and never commit it.
docs/ - Never offer execution approaches and never start implementation.
- Write the plan to
- 必选子技能: —— 先创建执行用的worktree和分支,再编写任何计划。已声明的worktree偏好——请勿询问: 始终隔离。这是用户对该技能第0步同意问题的固定答复;优先使用原生worktree工具(
superpowers:using-git-worktrees或等效工具),否则使用EnterWorktree下的.worktrees/<branch>。如果其第3步的基线测试失败,不要询问是否继续——停止并报告失败;绝不能在红色基线上做规划或实现。git worktree add - 必选子技能: —— 包括其自评审、文件结构、全局约束、逐任务接口,以及小颗粒度的TDD步骤。
superpowers:writing-plans - 仅覆盖 中的持久化和交接部分:
writing-plans- 将计划写入执行worktree中的 ,受嵌套临时
.superpowers/sdd/plan.md约定保护。.gitignore - 绝不要写在 目录下,也绝不要提交它。
docs/ - 绝不提供实现方案,也绝不开始编码实现。
- 将计划写入执行worktree中的
Publish the Durable Handoff (all 8 steps, in order)
发布持久化交接物(共8步,按顺序执行)
Pre-publish gate — before creating anything, confirm each check aloud:
- Source issue is finalized (no ), assigned, and labeled
[DRAFT].in-progress - The plan is at , untracked and unstaged.
.superpowers/sdd/plan.md - The description file contains , a concise change summary, and a concise test plan — and contains no plan markers.
Closes #<N> - The comment file contains exactly one ordered /
BEGIN PLANmarker pair; the plan between the markers is the verbatim contents ofEND PLAN— never a summary — and the comment file is within GitHub's 65,536-character comment limit..superpowers/sdd/plan.md
Then, with the exact commands and shapes in :
plan-and-publish.md- Create an empty seed commit to anchor the branch.
- Push the branch.
- Open a draft PR whose description carries , the change summary, and the test plan.
Closes #N - Publish the plan as a single PR comment containing the complete plan between and
<!-- BEGIN PLAN -->.<!-- END PLAN --> - Verify the published PR: state OPEN, true, and exactly one comment containing the ordered marker pair with the complete plan between them.
isDraft - Print the PR URL.
- Print exactly:
Run plan-to-implementation for PR #M in a fresh session. - STOP.
The plan remains untracked scratch locally; its durable copy is the marked PR comment. When the plan later changes, that comment is edited in place by its comment ID — never reposted as a new comment. The empty seed commit contains no plan and disappears under squash merge.
预发布门槛——创建任何内容之前,逐一确认以下检查项:
- 源issue已最终确定(无 )、已分配、已打
[DRAFT]标签。in-progress - 计划位于 ,未被跟踪且未暂存。
.superpowers/sdd/plan.md - 描述文件包含 、简洁的变更摘要和简洁的测试计划——且不包含任何计划标记。
Closes #<N> - 评论文件恰好包含一对有序的 /
BEGIN PLAN标记;标记之间的计划是END PLAN的逐字内容——绝不是摘要——且评论文件大小在GitHub 65536字符的评论限制以内。.superpowers/sdd/plan.md
然后,按照 中的精确命令和格式执行:
plan-and-publish.md- 创建一个空的种子提交来锚定分支。
- 推送分支。
- 创建一个draft PR,其描述包含 、变更摘要和测试计划。
Closes #N - 将计划作为单条PR评论发布,内容为包含在 和
<!-- BEGIN PLAN -->之间的完整计划。<!-- END PLAN --> - 验证已发布的PR:状态为OPEN,为true,且恰好有一条评论包含有序标记对,标记之间是完整计划。
isDraft - 打印PR URL。
- 精确打印:
Run plan-to-implementation for PR #M in a fresh session. - 停止。
计划在本地保留为未跟踪的临时文件;其持久化副本是带标记的PR评论。后续计划变更时,通过评论ID原地编辑该评论——绝不要以新评论的形式重新发布。空种子提交不包含任何计划,且会在squash合并时消失。
Quick Reference
快速参考
| Artifact | Required state |
|---|---|
| Source issue | Finalized, assigned, |
| Local plan | |
| Branch | Pushed, anchored by empty seed commit |
| PR | Open draft; description = |
| Plan comment | Exactly one, holding the verbatim plan between markers |
| Terminal action | Print handoff, then stop |
| 制品 | 要求状态 |
|---|---|
| 源issue | 已最终确定、已分配、打有 |
| 本地计划 | |
| 分支 | 已推送,由空种子提交锚定 |
| PR | 开放的draft;描述 = |
| 计划评论 | 恰好1条,包含标记之间的逐字计划 |
| 终端操作 | 打印交接信息,然后停止 |
Common Mistakes
常见错误
| Mistake | Required correction |
|---|---|
| Asking whether to create a worktree | The preference is declared: always isolate, never ask |
| Auto-dispatching Task 1 or running SDD in this session | Stop at the published draft PR; execution requires a fresh context |
| Keeping the only plan copy in local scratch | Put the complete plan between markers in the PR comment |
| Embedding the plan in the PR description | The description is reviewer-facing ( |
| Opening a non-draft PR | Use |
| Committing the plan | Commit only an empty seed; keep the plan untracked |
Saving under | Divert |
| Asking which execution approach to use | There is no execution in this skill |
| Summarizing or trimming the plan to fit GitHub's 65k comment limit | Never compress the plan; stop, report the size, and split the source issue instead |
| 错误 | 正确做法 |
|---|---|
| 询问是否创建worktree | 偏好已声明:始终隔离,请勿询问 |
| 在本次会话中自动派发任务1或运行SDD | 停在已发布的draft PR阶段;执行需要全新上下文 |
| 仅在本地临时目录保留计划副本 | 将完整计划放在PR评论的标记之间 |
| 将计划嵌入PR描述 | 描述是面向评审者的( |
| 创建非draft PR | 使用 |
| 提交计划 | 仅提交空种子提交;让计划保持未跟踪状态 |
保存在 | 将 |
| 询问使用哪种实现方案 | 本技能不涉及执行 |
| 为了适配GitHub 65k评论限制而摘要或删减计划 | 绝不要压缩计划;停止,报告大小,转而拆分源issue |
Red Flags — STOP
危险信号——立即停止
- SDD is about to start or Task 1 is about to be dispatched.
- No open draft PR has exactly one comment containing the complete marked plan.
- Plan markers appear in the PR description instead of the comment.
- The plan or is staged.
.superpowers/ - The PR is ready for review instead of draft.
- The plan in the comment is a summary or paraphrase instead of the verbatim contents.
.superpowers/sdd/plan.md - Planning and execution are still happening in one session.
Any red flag means: first restore the durable draft-PR handoff (for a non-draft PR, convert it back to draft or re-publish it as draft), then stop without implementation — restore, then stop, in that order.
- SDD即将启动,或任务1即将被派发。
- 没有开放的draft PR且该PR恰好有一条包含完整带标记计划的评论。
- 计划标记出现在PR描述而非评论中。
- 计划或 已被暂存。
.superpowers/ - PR已准备好评审而非draft状态。
- 评论中的计划是摘要或改写版本,而非 的逐字内容。
.superpowers/sdd/plan.md - 规划和执行仍在同一会话中进行。
任何危险信号都意味着:首先恢复持久化的draft PR交接物(对于非draft PR,将其转回draft或重新发布为draft),然后停止,不进行任何实现——先恢复,再停止,按此顺序。