@howlil/ez-agents 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (183) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +845 -0
  3. package/README.zh-CN.md +702 -0
  4. package/agents/ez-codebase-mapper.md +770 -0
  5. package/agents/ez-debugger.md +1255 -0
  6. package/agents/ez-executor.md +487 -0
  7. package/agents/ez-integration-checker.md +443 -0
  8. package/agents/ez-nyquist-auditor.md +176 -0
  9. package/agents/ez-phase-researcher.md +553 -0
  10. package/agents/ez-plan-checker.md +706 -0
  11. package/agents/ez-planner.md +1307 -0
  12. package/agents/ez-project-researcher.md +629 -0
  13. package/agents/ez-research-synthesizer.md +247 -0
  14. package/agents/ez-roadmapper.md +650 -0
  15. package/agents/ez-ui-auditor.md +441 -0
  16. package/agents/ez-ui-checker.md +302 -0
  17. package/agents/ez-ui-researcher.md +355 -0
  18. package/agents/ez-verifier.md +579 -0
  19. package/bin/install.js +2862 -0
  20. package/bin/update.js +214 -0
  21. package/commands/ez/add-phase.md +43 -0
  22. package/commands/ez/add-tests.md +41 -0
  23. package/commands/ez/add-todo.md +47 -0
  24. package/commands/ez/audit-milestone.md +36 -0
  25. package/commands/ez/autonomous.md +41 -0
  26. package/commands/ez/check-todos.md +45 -0
  27. package/commands/ez/cleanup.md +18 -0
  28. package/commands/ez/complete-milestone.md +136 -0
  29. package/commands/ez/debug.md +168 -0
  30. package/commands/ez/discuss-phase.md +90 -0
  31. package/commands/ez/execute-phase.md +41 -0
  32. package/commands/ez/health.md +22 -0
  33. package/commands/ez/help.md +22 -0
  34. package/commands/ez/insert-phase.md +32 -0
  35. package/commands/ez/join-discord.md +18 -0
  36. package/commands/ez/list-phase-assumptions.md +46 -0
  37. package/commands/ez/map-codebase.md +71 -0
  38. package/commands/ez/new-milestone.md +44 -0
  39. package/commands/ez/new-project.md +42 -0
  40. package/commands/ez/pause-work.md +38 -0
  41. package/commands/ez/plan-milestone-gaps.md +34 -0
  42. package/commands/ez/plan-phase.md +45 -0
  43. package/commands/ez/progress.md +24 -0
  44. package/commands/ez/quick.md +45 -0
  45. package/commands/ez/reapply-patches.md +124 -0
  46. package/commands/ez/remove-phase.md +31 -0
  47. package/commands/ez/research-phase.md +190 -0
  48. package/commands/ez/resume-work.md +40 -0
  49. package/commands/ez/set-profile.md +34 -0
  50. package/commands/ez/settings.md +36 -0
  51. package/commands/ez/stats.md +18 -0
  52. package/commands/ez/ui-phase.md +34 -0
  53. package/commands/ez/ui-review.md +32 -0
  54. package/commands/ez/update.md +37 -0
  55. package/commands/ez/validate-phase.md +35 -0
  56. package/commands/ez/verify-work.md +38 -0
  57. package/get-shit-done/bin/ez-tools.cjs +598 -0
  58. package/get-shit-done/bin/lib/assistant-adapter.cjs +205 -0
  59. package/get-shit-done/bin/lib/audit-exec.cjs +150 -0
  60. package/get-shit-done/bin/lib/auth.cjs +175 -0
  61. package/get-shit-done/bin/lib/circuit-breaker.cjs +118 -0
  62. package/get-shit-done/bin/lib/commands.cjs +666 -0
  63. package/get-shit-done/bin/lib/config.cjs +183 -0
  64. package/get-shit-done/bin/lib/core.cjs +495 -0
  65. package/get-shit-done/bin/lib/file-lock.cjs +236 -0
  66. package/get-shit-done/bin/lib/frontmatter.cjs +299 -0
  67. package/get-shit-done/bin/lib/fs-utils.cjs +153 -0
  68. package/get-shit-done/bin/lib/git-utils.cjs +203 -0
  69. package/get-shit-done/bin/lib/health-check.cjs +163 -0
  70. package/get-shit-done/bin/lib/index.cjs +113 -0
  71. package/get-shit-done/bin/lib/init.cjs +710 -0
  72. package/get-shit-done/bin/lib/logger.cjs +117 -0
  73. package/get-shit-done/bin/lib/milestone.cjs +241 -0
  74. package/get-shit-done/bin/lib/model-provider.cjs +146 -0
  75. package/get-shit-done/bin/lib/phase.cjs +908 -0
  76. package/get-shit-done/bin/lib/retry.cjs +119 -0
  77. package/get-shit-done/bin/lib/roadmap.cjs +305 -0
  78. package/get-shit-done/bin/lib/safe-exec.cjs +128 -0
  79. package/get-shit-done/bin/lib/safe-path.cjs +130 -0
  80. package/get-shit-done/bin/lib/state.cjs +721 -0
  81. package/get-shit-done/bin/lib/temp-file.cjs +239 -0
  82. package/get-shit-done/bin/lib/template.cjs +222 -0
  83. package/get-shit-done/bin/lib/test-file-lock.cjs +112 -0
  84. package/get-shit-done/bin/lib/test-graceful.cjs +93 -0
  85. package/get-shit-done/bin/lib/test-logger.cjs +60 -0
  86. package/get-shit-done/bin/lib/test-safe-exec.cjs +38 -0
  87. package/get-shit-done/bin/lib/test-safe-path.cjs +33 -0
  88. package/get-shit-done/bin/lib/test-temp-file.cjs +125 -0
  89. package/get-shit-done/bin/lib/timeout-exec.cjs +62 -0
  90. package/get-shit-done/bin/lib/verify.cjs +820 -0
  91. package/get-shit-done/references/checkpoints.md +776 -0
  92. package/get-shit-done/references/continuation-format.md +249 -0
  93. package/get-shit-done/references/decimal-phase-calculation.md +65 -0
  94. package/get-shit-done/references/git-integration.md +248 -0
  95. package/get-shit-done/references/git-planning-commit.md +38 -0
  96. package/get-shit-done/references/model-profile-resolution.md +34 -0
  97. package/get-shit-done/references/model-profiles.md +93 -0
  98. package/get-shit-done/references/phase-argument-parsing.md +61 -0
  99. package/get-shit-done/references/planning-config.md +200 -0
  100. package/get-shit-done/references/questioning.md +162 -0
  101. package/get-shit-done/references/tdd.md +263 -0
  102. package/get-shit-done/references/ui-brand.md +160 -0
  103. package/get-shit-done/references/verification-patterns.md +612 -0
  104. package/get-shit-done/templates/DEBUG.md +164 -0
  105. package/get-shit-done/templates/UAT.md +247 -0
  106. package/get-shit-done/templates/UI-SPEC.md +100 -0
  107. package/get-shit-done/templates/VALIDATION.md +76 -0
  108. package/get-shit-done/templates/codebase/architecture.md +255 -0
  109. package/get-shit-done/templates/codebase/concerns.md +310 -0
  110. package/get-shit-done/templates/codebase/conventions.md +307 -0
  111. package/get-shit-done/templates/codebase/integrations.md +280 -0
  112. package/get-shit-done/templates/codebase/stack.md +186 -0
  113. package/get-shit-done/templates/codebase/structure.md +285 -0
  114. package/get-shit-done/templates/codebase/testing.md +480 -0
  115. package/get-shit-done/templates/config.json +37 -0
  116. package/get-shit-done/templates/context.md +352 -0
  117. package/get-shit-done/templates/continue-here.md +78 -0
  118. package/get-shit-done/templates/copilot-instructions.md +7 -0
  119. package/get-shit-done/templates/debug-subagent-prompt.md +91 -0
  120. package/get-shit-done/templates/discovery.md +146 -0
  121. package/get-shit-done/templates/milestone-archive.md +123 -0
  122. package/get-shit-done/templates/milestone.md +115 -0
  123. package/get-shit-done/templates/phase-prompt.md +610 -0
  124. package/get-shit-done/templates/planner-subagent-prompt.md +117 -0
  125. package/get-shit-done/templates/project.md +184 -0
  126. package/get-shit-done/templates/requirements.md +231 -0
  127. package/get-shit-done/templates/research-project/ARCHITECTURE.md +204 -0
  128. package/get-shit-done/templates/research-project/FEATURES.md +147 -0
  129. package/get-shit-done/templates/research-project/PITFALLS.md +200 -0
  130. package/get-shit-done/templates/research-project/STACK.md +120 -0
  131. package/get-shit-done/templates/research-project/SUMMARY.md +170 -0
  132. package/get-shit-done/templates/research.md +552 -0
  133. package/get-shit-done/templates/retrospective.md +54 -0
  134. package/get-shit-done/templates/roadmap.md +202 -0
  135. package/get-shit-done/templates/state.md +176 -0
  136. package/get-shit-done/templates/summary-complex.md +59 -0
  137. package/get-shit-done/templates/summary-minimal.md +41 -0
  138. package/get-shit-done/templates/summary-standard.md +48 -0
  139. package/get-shit-done/templates/summary.md +248 -0
  140. package/get-shit-done/templates/user-setup.md +311 -0
  141. package/get-shit-done/templates/verification-report.md +322 -0
  142. package/get-shit-done/workflows/add-phase.md +112 -0
  143. package/get-shit-done/workflows/add-tests.md +351 -0
  144. package/get-shit-done/workflows/add-todo.md +158 -0
  145. package/get-shit-done/workflows/audit-milestone.md +332 -0
  146. package/get-shit-done/workflows/autonomous.md +743 -0
  147. package/get-shit-done/workflows/check-todos.md +177 -0
  148. package/get-shit-done/workflows/cleanup.md +152 -0
  149. package/get-shit-done/workflows/complete-milestone.md +766 -0
  150. package/get-shit-done/workflows/diagnose-issues.md +219 -0
  151. package/get-shit-done/workflows/discovery-phase.md +289 -0
  152. package/get-shit-done/workflows/discuss-phase.md +762 -0
  153. package/get-shit-done/workflows/execute-phase.md +468 -0
  154. package/get-shit-done/workflows/execute-plan.md +483 -0
  155. package/get-shit-done/workflows/health.md +159 -0
  156. package/get-shit-done/workflows/help.md +492 -0
  157. package/get-shit-done/workflows/insert-phase.md +130 -0
  158. package/get-shit-done/workflows/list-phase-assumptions.md +178 -0
  159. package/get-shit-done/workflows/map-codebase.md +316 -0
  160. package/get-shit-done/workflows/new-milestone.md +384 -0
  161. package/get-shit-done/workflows/new-project.md +1111 -0
  162. package/get-shit-done/workflows/node-repair.md +92 -0
  163. package/get-shit-done/workflows/pause-work.md +122 -0
  164. package/get-shit-done/workflows/plan-milestone-gaps.md +274 -0
  165. package/get-shit-done/workflows/plan-phase.md +651 -0
  166. package/get-shit-done/workflows/progress.md +382 -0
  167. package/get-shit-done/workflows/quick.md +610 -0
  168. package/get-shit-done/workflows/remove-phase.md +155 -0
  169. package/get-shit-done/workflows/research-phase.md +74 -0
  170. package/get-shit-done/workflows/resume-project.md +307 -0
  171. package/get-shit-done/workflows/set-profile.md +81 -0
  172. package/get-shit-done/workflows/settings.md +242 -0
  173. package/get-shit-done/workflows/stats.md +57 -0
  174. package/get-shit-done/workflows/transition.md +544 -0
  175. package/get-shit-done/workflows/ui-phase.md +290 -0
  176. package/get-shit-done/workflows/ui-review.md +157 -0
  177. package/get-shit-done/workflows/update.md +320 -0
  178. package/get-shit-done/workflows/validate-phase.md +167 -0
  179. package/get-shit-done/workflows/verify-phase.md +243 -0
  180. package/get-shit-done/workflows/verify-work.md +584 -0
  181. package/package.json +55 -0
  182. package/scripts/build-hooks.js +43 -0
  183. package/scripts/run-tests.cjs +29 -0
@@ -0,0 +1,702 @@
1
+ <div align="center">
2
+
3
+ # EZ Agents
4
+
5
+ [English](README.md) · **简体中文**
6
+
7
+ **一个轻量但强大的元提示、上下文工程与规格驱动开发系统,适用于 Claude Code、OpenCode、Gemini CLI 和 Codex。**
8
+
9
+ **它解决的是 context rot:随着 Claude 的上下文窗口被填满,输出质量逐步劣化的问题。**
10
+
11
+ [![GitHub forks](https://img.shields.io/github/forks/howlil/ez-agents?style=for-the-badge&logo=github&color=blue)](https://github.com/howlil/ez-agents/network)
12
+ [![GitHub stars](https://img.shields.io/github/stars/howlil/ez-agents?style=for-the-badge&logo=github&color=yellow)](https://github.com/howlil/ez-agents/stargazers)
13
+ [![License](https://img.shields.io/badge/license-MIT-blue?style=for-the-badge)](LICENSE)
14
+
15
+ <br>
16
+
17
+ ```bash
18
+ npx github:howlil/ez-agents
19
+ ```
20
+
21
+ **支持 Mac、Windows 和 Linux。**
22
+
23
+ <br>
24
+
25
+ **Original GSD by** [TÂCHES](https://github.com/glittercowboy/get-shit-done) | **EZ Agents Fork by** [@howlil](https://github.com/howlil)
26
+
27
+ <br>
28
+
29
+ *"只要你清楚自己想要什么,它就真的能给你做出来。不扯淡。"*
30
+
31
+ *"我试过 SpecKit、OpenSpec 和 Taskmaster,这套东西目前给我的结果最好。"*
32
+
33
+ *"这是我给 Claude Code 加过最强的增强。没有过度设计,是真的把事做完。"*
34
+
35
+ <br>
36
+
37
+ [我为什么做这个](#我为什么做这个) · [它是怎么工作的](#它是怎么工作的) · [命令](#命令) · [为什么它有效](#为什么它有效) · [用户指南](docs/USER-GUIDE.md)
38
+
39
+ </div>
40
+
41
+ ---
42
+
43
+ ## 我为什么做这个
44
+
45
+ 我是独立开发者。我不写代码,Claude Code 写。
46
+
47
+ 市面上已经有其他规格驱动开发工具,比如 BMAD、Speckit……但它们要么把事情搞得比必要的复杂得多了些(冲刺仪式、故事点、利益相关方同步、复盘、Jira 流程),要么根本缺少对你到底在构建什么的整体理解。我不是一家 50 人的软件公司。我不想演企业流程。我只是个想把好东西真正做出来的创作者。
48
+
49
+ 所以我做了 GSD。复杂性在系统内部,不在你的工作流里。幕后是上下文工程、XML 提示格式、子代理编排、状态管理;你看到的是几个真能工作的命令。
50
+
51
+ 这套系统会把 Claude 完成工作 *以及* 验证结果所需的一切上下文都准备好。我信任这个工作流,因为它确实能把事情做好。
52
+
53
+ 这就是它。没有企业角色扮演式的废话,只有一套非常有效、能让你持续用 Claude Code 构建酷东西的系统。
54
+
55
+ — **TÂCHES**
56
+
57
+ ---
58
+
59
+ Vibecoding 的名声不算好。你描述需求,AI 生成代码,结果往往是质量不稳定、规模一上来就散架的垃圾。
60
+
61
+ EZ Agents 解决的就是这个问题。它是让 Claude Code 变得可靠的上下文工程层。你只要描述想法,系统会自动提取它需要知道的一切,然后让 Claude Code 去干活。
62
+
63
+ ---
64
+
65
+ ## 适合谁用
66
+
67
+ 适合那些想把自己的需求说明白,然后让系统正确构建出来的人,而不是假装自己在运营一个 50 人工程组织的人。
68
+
69
+ ---
70
+
71
+ ## 快速开始
72
+
73
+ ```bash
74
+ npx ez-agents
75
+ ```
76
+
77
+ 安装器会提示你选择:
78
+ 1. **运行时**:Claude Code、OpenCode、Gemini、Codex,或全部
79
+ 2. **安装位置**:全局(所有项目)或本地(仅当前项目)
80
+
81
+ 安装后可这样验证:
82
+ - Claude Code / Gemini:`/ez:help`
83
+ - OpenCode:`/ez-help`
84
+ - Codex:`$ez-help`
85
+
86
+ > [!NOTE]
87
+ > Codex 安装走的是 skill 机制(`skills/ez-*/SKILL.md`),不是自定义 prompt。
88
+
89
+ ### 保持更新
90
+
91
+ EZ Agents 迭代很快,建议定期更新:
92
+
93
+ ```bash
94
+ ez-agents-update
95
+ ```
96
+
97
+ <details>
98
+ <summary><strong>非交互式安装(Docker、CI、脚本)</strong></summary>
99
+
100
+ ```bash
101
+ # Claude Code
102
+ ez-agents --claude --global # 安装到 ~/.claude/
103
+ ez-agents --claude --local # 安装到 ./.claude/
104
+
105
+ # OpenCode(开源,可用免费模型)
106
+ ez-agents --opencode --global # 安装到 ~/.config/opencode/
107
+
108
+ # Gemini CLI
109
+ ez-agents --gemini --global # 安装到 ~/.gemini/
110
+
111
+ # Codex(以 skills 为主)
112
+ ez-agents --codex --global # 安装到 ~/.codex/
113
+ ez-agents --codex --local # 安装到 ./.codex/
114
+
115
+ # 所有运行时
116
+ ez-agents --all --global # 安装到所有目录
117
+ ```
118
+
119
+ 使用 `--global`(`-g`)或 `--local`(`-l`)可以跳过安装位置提示。
120
+ 使用 `--claude`、`--opencode`、`--gemini`、`--codex` 或 `--all` 可以跳过运行时提示。
121
+
122
+ </details>
123
+
124
+ <details>
125
+ <summary><strong>开发安装</strong></summary>
126
+
127
+ 克隆仓库并在本地运行安装器:
128
+
129
+ ```bash
130
+ git clone https://github.com/howlil/ez-agents.git
131
+ cd ez-agents
132
+ node bin/install.js --claude --local
133
+ ```
134
+
135
+ 这样会安装到 `./.claude/`,方便你在贡献代码前测试自己的改动。
136
+
137
+ </details>
138
+
139
+ ### 推荐:跳过权限确认模式
140
+
141
+ EZ Agents 的设计目标是无摩擦自动化。运行 Claude Code 时建议使用:
142
+
143
+ ```bash
144
+ claude --dangerously-skip-permissions
145
+ ```
146
+
147
+ > [!TIP]
148
+ > 这才是 EZ Agents 的预期用法。连 `date` 和 `git commit` 都要来回确认 50 次,整个体验就废了。
149
+
150
+ <details>
151
+ <summary><strong>替代方案:细粒度权限</strong></summary>
152
+
153
+ 如果你不想使用这个 flag,可以在项目的 `.claude/settings.json` 中加入:
154
+
155
+ ```json
156
+ {
157
+ "permissions": {
158
+ "allow": [
159
+ "Bash(date:*)",
160
+ "Bash(echo:*)",
161
+ "Bash(cat:*)",
162
+ "Bash(ls:*)",
163
+ "Bash(mkdir:*)",
164
+ "Bash(wc:*)",
165
+ "Bash(head:*)",
166
+ "Bash(tail:*)",
167
+ "Bash(sort:*)",
168
+ "Bash(grep:*)",
169
+ "Bash(tr:*)",
170
+ "Bash(git add:*)",
171
+ "Bash(git commit:*)",
172
+ "Bash(git status:*)",
173
+ "Bash(git log:*)",
174
+ "Bash(git diff:*)",
175
+ "Bash(git tag:*)"
176
+ ]
177
+ }
178
+ }
179
+ ```
180
+
181
+ </details>
182
+
183
+ ---
184
+
185
+ ## 它是怎么工作的
186
+
187
+ > **已经有现成代码库?** 先运行 `/gsd:map-codebase`。它会并行拉起多个代理分析你的技术栈、架构、约定和风险点。之后 `/gsd:new-project` 就会真正“理解”你的代码库,提问会聚焦在你打算新增的部分,规划时也会自动加载你的现有模式。
188
+
189
+ ### 1. 初始化项目
190
+
191
+ ```
192
+ /gsd:new-project
193
+ ```
194
+
195
+ 一个命令,一条完整流程。系统会:
196
+
197
+ 1. **提问**:一直问到它彻底理解你的想法(目标、约束、技术偏好、边界情况)
198
+ 2. **研究**:并行拉起代理调研领域知识(可选,但强烈建议)
199
+ 3. **需求梳理**:提取哪些属于 v1、v2,哪些不在范围内
200
+ 4. **路线图**:创建与需求映射的阶段规划
201
+
202
+ 你审核并批准路线图后,就可以开始构建。
203
+
204
+ **生成:** `PROJECT.md`、`REQUIREMENTS.md`、`ROADMAP.md`、`STATE.md`、`.planning/research/`
205
+
206
+ ---
207
+
208
+ ### 2. 讨论阶段
209
+
210
+ ```
211
+ /gsd:discuss-phase 1
212
+ ```
213
+
214
+ **这是你塑造实现方式的地方。**
215
+
216
+ 你的路线图里,每个阶段通常只有一两句话。这点信息不足以让系统按 *你脑中的样子* 把东西做出来。这一步的作用,就是在研究和规划之前,把你的偏好先收进去。
217
+
218
+ 系统会分析该阶段,并根据要构建的内容识别灰区:
219
+
220
+ - **视觉功能**:布局、信息密度、交互、空状态
221
+ - **API / CLI**:返回格式、flags、错误处理、详细程度
222
+ - **内容系统**:结构、语气、深度、流转方式
223
+ - **组织型任务**:分组标准、命名、去重、例外情况
224
+
225
+ 对每个你选择的区域,系统都会持续追问,直到你满意为止。最终产物 `CONTEXT.md` 会直接喂给后续两个步骤:
226
+
227
+ 1. **研究代理会读取它**:知道该研究哪些模式(例如“用户想要卡片布局” → 去研究卡片组件库)
228
+ 2. **规划代理会读取它**:知道哪些决策已经锁定(例如“已决定使用无限滚动” → 计划里就会包含滚动处理)
229
+
230
+ 你在这里给出的信息越具体,系统越能构建出你真正想要的东西。跳过它,你拿到的是合理默认值;用好它,你拿到的是 *你的* 方案。
231
+
232
+ **生成:** `{phase_num}-CONTEXT.md`
233
+
234
+ ---
235
+
236
+ ### 3. 规划阶段
237
+
238
+ ```
239
+ /gsd:plan-phase 1
240
+ ```
241
+
242
+ 系统会:
243
+
244
+ 1. **研究**:结合你的 `CONTEXT.md` 决策,调研这一阶段该怎么实现
245
+ 2. **制定计划**:创建 2-3 份原子化任务计划,使用 XML 结构
246
+ 3. **验证**:将计划与需求对照检查,直到通过为止
247
+
248
+ 每份计划都足够小,可以在一个全新的上下文窗口里执行。没有质量衰减,也不会出现“我接下来会更简洁一些”的退化状态。
249
+
250
+ **生成:** `{phase_num}-RESEARCH.md`、`{phase_num}-{N}-PLAN.md`
251
+
252
+ ---
253
+
254
+ ### 4. 执行阶段
255
+
256
+ ```
257
+ /gsd:execute-phase 1
258
+ ```
259
+
260
+ 系统会:
261
+
262
+ 1. **按 wave 执行计划**:能并行的并行,有依赖的顺序执行
263
+ 2. **每个计划使用新上下文**:20 万 token 纯用于实现,零历史垃圾
264
+ 3. **每个任务单独提交**:每项任务都有自己的原子提交
265
+ 4. **对照目标验证**:检查代码库是否真的交付了该阶段承诺的内容
266
+
267
+ 你可以离开,回来时看到的是已经完成的工作和干净的 git 历史。
268
+
269
+ **Wave 执行方式:**
270
+
271
+ 计划会根据依赖关系被分组为不同的 “wave”。同一 wave 内并行执行,不同 wave 之间顺序推进。
272
+
273
+ ```
274
+ ┌─────────────────────────────────────────────────────────────────────┐
275
+ │ PHASE EXECUTION │
276
+ ├─────────────────────────────────────────────────────────────────────┤
277
+ │ │
278
+ │ WAVE 1 (parallel) WAVE 2 (parallel) WAVE 3 │
279
+ │ ┌─────────┐ ┌─────────┐ ┌─────────┐ ┌─────────┐ ┌─────────┐ │
280
+ │ │ Plan 01 │ │ Plan 02 │ → │ Plan 03 │ │ Plan 04 │ → │ Plan 05 │ │
281
+ │ │ │ │ │ │ │ │ │ │ │ │
282
+ │ │ User │ │ Product │ │ Orders │ │ Cart │ │ Checkout│ │
283
+ │ │ Model │ │ Model │ │ API │ │ API │ │ UI │ │
284
+ │ └─────────┘ └─────────┘ └─────────┘ └─────────┘ └─────────┘ │
285
+ │ │ │ ↑ ↑ ↑ │
286
+ │ └───────────┴──────────────┴───────────┘ │ │
287
+ │ Dependencies: Plan 03 needs Plan 01 │ │
288
+ │ Plan 04 needs Plan 02 │ │
289
+ │ Plan 05 needs Plans 03 + 04 │ │
290
+ │ │
291
+ └─────────────────────────────────────────────────────────────────────┘
292
+ ```
293
+
294
+ **为什么 wave 很重要:**
295
+ - 独立计划 → 同一 wave → 并行执行
296
+ - 依赖计划 → 更晚的 wave → 等依赖完成
297
+ - 文件冲突 → 顺序执行,或合并到同一个计划里
298
+
299
+ 这也是为什么“垂直切片”(Plan 01:端到端完成用户功能)比“水平分层”(Plan 01:所有 model,Plan 02:所有 API)更容易并行化。
300
+
301
+ **生成:** `{phase_num}-{N}-SUMMARY.md`、`{phase_num}-VERIFICATION.md`
302
+
303
+ ---
304
+
305
+ ### 5. 验证工作
306
+
307
+ ```
308
+ /gsd:verify-work 1
309
+ ```
310
+
311
+ **这是你确认它是否真的可用的地方。**
312
+
313
+ 自动化验证能检查代码存在、测试通过。但这个功能是否真的按你的预期工作?这一步就是让你亲自用。
314
+
315
+ 系统会:
316
+
317
+ 1. **提取可测试的交付项**:你现在应该能做到什么
318
+ 2. **逐项带你验证**:“能否用邮箱登录?” 可以 / 不可以,或者描述哪里不对
319
+ 3. **自动诊断失败**:拉起 debug 代理定位根因
320
+ 4. **创建验证过的修复计划**:可立刻重新执行
321
+
322
+ 如果一切通过,就进入下一步;如果哪里坏了,你不需要手动 debug,只要重新运行 `/gsd:execute-phase`,执行它自动生成的修复计划即可。
323
+
324
+ **生成:** `{phase_num}-UAT.md`,以及发现问题时的修复计划
325
+
326
+ ---
327
+
328
+ ### 6. 重复 → 完成 → 下一个里程碑
329
+
330
+ ```
331
+ /gsd:discuss-phase 2
332
+ /gsd:plan-phase 2
333
+ /gsd:execute-phase 2
334
+ /gsd:verify-work 2
335
+ ...
336
+ /gsd:complete-milestone
337
+ /gsd:new-milestone
338
+ ```
339
+
340
+ 循环执行 **讨论 → 规划 → 执行 → 验证**,直到整个里程碑完成。
341
+
342
+ 如果你希望在讨论阶段更快收集信息,可以用 `/gsd:discuss-phase <n> --batch`,一次回答一小组问题,而不是逐个问答。
343
+
344
+ 每个阶段都会得到你的输入(discuss)、充分研究(plan)、干净执行(execute)和人工验证(verify)。上下文始终保持新鲜,质量也能持续稳定。
345
+
346
+ 当所有阶段完成后,`/gsd:complete-milestone` 会归档当前里程碑并打 release tag。
347
+
348
+ 接着用 `/gsd:new-milestone` 开启下一个版本。它和 `new-project` 流程相同,只是面向你现有的代码库。你描述下一步想构建什么,系统研究领域、梳理需求,再产出新的路线图。每个里程碑都是一个干净周期:定义 → 构建 → 发布。
349
+
350
+ ---
351
+
352
+ ### 快速模式
353
+
354
+ ```
355
+ /gsd:quick
356
+ ```
357
+
358
+ **适用于不需要完整规划的临时任务。**
359
+
360
+ 快速模式保留 GSD 的核心保障(原子提交、状态跟踪),但路径更短:
361
+
362
+ - **相同的代理体系**:同样是 planner + executor,质量不降
363
+ - **跳过可选步骤**:没有 research、plan checker、verifier
364
+ - **独立跟踪**:数据存放在 `.planning/quick/`,不和 phase 混在一起
365
+
366
+ 适用场景:修 bug、小功能、配置改动、一次性任务。
367
+
368
+ ```
369
+ /gsd:quick
370
+ > What do you want to do? "Add dark mode toggle to settings"
371
+ ```
372
+
373
+ **生成:** `.planning/quick/001-add-dark-mode-toggle/PLAN.md`、`SUMMARY.md`
374
+
375
+ ---
376
+
377
+ ## 为什么它有效
378
+
379
+ ### 上下文工程
380
+
381
+ Claude Code 非常强大,前提是你把它需要的上下文给对。大多数人做不到。
382
+
383
+ GSD 会替你处理:
384
+
385
+ | 文件 | 作用 |
386
+ |------|------|
387
+ | `PROJECT.md` | 项目愿景,始终加载 |
388
+ | `research/` | 生态知识(技术栈、功能、架构、坑点) |
389
+ | `REQUIREMENTS.md` | 带 phase 可追踪性的 v1/v2 范围定义 |
390
+ | `ROADMAP.md` | 你要去哪里、哪些已经完成 |
391
+ | `STATE.md` | 决策、阻塞、当前位置,跨会话记忆 |
392
+ | `PLAN.md` | 带 XML 结构和验证步骤的原子任务 |
393
+ | `SUMMARY.md` | 做了什么、改了什么、已写入历史 |
394
+ | `todos/` | 留待后续处理的想法和任务 |
395
+
396
+ 这些尺寸限制都是基于 Claude 在何处开始质量退化得出的。控制在阈值内,输出才能持续稳定。
397
+
398
+ ### XML 提示格式
399
+
400
+ 每个计划都会使用为 Claude 优化过的结构化 XML:
401
+
402
+ ```xml
403
+ <task type="auto">
404
+ <name>Create login endpoint</name>
405
+ <files>src/app/api/auth/login/route.ts</files>
406
+ <action>
407
+ Use jose for JWT (not jsonwebtoken - CommonJS issues).
408
+ Validate credentials against users table.
409
+ Return httpOnly cookie on success.
410
+ </action>
411
+ <verify>curl -X POST localhost:3000/api/auth/login returns 200 + Set-Cookie</verify>
412
+ <done>Valid credentials return cookie, invalid return 401</done>
413
+ </task>
414
+ ```
415
+
416
+ 指令足够精确,不需要猜。验证也内建在计划里。
417
+
418
+ ### 多代理编排
419
+
420
+ 每个阶段都遵循同一种模式:一个轻量 orchestrator 拉起专用代理、汇总结果,再路由到下一步。
421
+
422
+ | 阶段 | Orchestrator 做什么 | Agents 做什么 |
423
+ |------|---------------------|---------------|
424
+ | 研究 | 协调与展示研究结果 | 4 个并行研究代理分别调查技术栈、功能、架构、坑点 |
425
+ | 规划 | 校验并管理迭代 | Planner 生成计划,checker 验证,循环直到通过 |
426
+ | 执行 | 按 wave 分组并跟踪进度 | Executors 并行实现,每个都有全新的 20 万上下文 |
427
+ | 验证 | 呈现结果并决定下一步 | Verifier 对照目标检查代码库,debuggers 诊断失败 |
428
+
429
+ Orchestrator 本身不做重活,只负责拉代理、等待、整合结果。
430
+
431
+ **最终效果:** 你可以在一个阶段里完成深度研究、生成并验证多个计划、让多个执行代理并行写下成千上万行代码,再自动对照目标验证,而主上下文窗口依然能维持在 30-40% 左右。真正的工作都发生在新鲜的子代理上下文里,所以你的主会话始终保持快速、响应稳定。
432
+
433
+ ### 原子 Git 提交
434
+
435
+ 每个任务完成后都会立刻生成独立提交:
436
+
437
+ ```bash
438
+ abc123f docs(08-02): complete user registration plan
439
+ def456g feat(08-02): add email confirmation flow
440
+ hij789k feat(08-02): implement password hashing
441
+ lmn012o feat(08-02): create registration endpoint
442
+ ```
443
+
444
+ > [!NOTE]
445
+ > **好处:** `git bisect` 能精准定位是哪项任务引入故障;每个任务都可单独回滚;未来 Claude 读取历史时也更清晰;整个 AI 自动化工作流的可观测性更好。
446
+
447
+ 每个 commit 都是外科手术式的:精确、可追踪、有意义。
448
+
449
+ ### 模块化设计
450
+
451
+ - 给当前里程碑追加 phase
452
+ - 在 phase 之间插入紧急工作
453
+ - 完成当前里程碑后开启新的周期
454
+ - 在不推倒重来的前提下调整计划
455
+
456
+ 你不会被这套系统绑死,它会随着项目变化而调整。
457
+
458
+ ---
459
+
460
+ ## 命令
461
+
462
+ ### 核心工作流
463
+
464
+ | 命令 | 作用 |
465
+ |------|------|
466
+ | `/gsd:new-project [--auto]` | 完整初始化:提问 → 研究 → 需求 → 路线图 |
467
+ | `/gsd:discuss-phase [N] [--auto]` | 在规划前收集实现决策 |
468
+ | `/gsd:plan-phase [N] [--auto]` | 为某个阶段执行研究 + 规划 + 验证 |
469
+ | `/gsd:execute-phase <N>` | 以并行 wave 执行全部计划,完成后验证 |
470
+ | `/gsd:verify-work [N]` | 人工用户验收测试 ¹ |
471
+ | `/gsd:audit-milestone` | 验证里程碑是否达到完成定义 |
472
+ | `/gsd:complete-milestone` | 归档里程碑并打 release tag |
473
+ | `/gsd:new-milestone [name]` | 开始下一个版本:提问 → 研究 → 需求 → 路线图 |
474
+
475
+ ### 导航
476
+
477
+ | 命令 | 作用 |
478
+ |------|------|
479
+ | `/gsd:progress` | 我现在在哪?下一步是什么? |
480
+ | `/gsd:help` | 显示全部命令和使用指南 |
481
+ | `/gsd:update` | 更新 GSD,并预览变更日志 |
482
+ | `/gsd:join-discord` | 加入 GSD Discord 社区 |
483
+
484
+ ### Brownfield
485
+
486
+ | 命令 | 作用 |
487
+ |------|------|
488
+ | `/gsd:map-codebase` | 在 `new-project` 前分析现有代码库 |
489
+
490
+ ### 阶段管理
491
+
492
+ | 命令 | 作用 |
493
+ |------|------|
494
+ | `/gsd:add-phase` | 在路线图末尾追加 phase |
495
+ | `/gsd:insert-phase [N]` | 在 phase 之间插入紧急工作 |
496
+ | `/gsd:remove-phase [N]` | 删除未来 phase,并重编号 |
497
+ | `/gsd:list-phase-assumptions [N]` | 在规划前查看 Claude 打算采用的方案 |
498
+ | `/gsd:plan-milestone-gaps` | 为 audit 发现的缺口创建 phase |
499
+
500
+ ### 会话
501
+
502
+ | 命令 | 作用 |
503
+ |------|------|
504
+ | `/gsd:pause-work` | 在中途暂停时创建交接上下文 |
505
+ | `/gsd:resume-work` | 从上一次会话恢复 |
506
+
507
+ ### 工具
508
+
509
+ | 命令 | 作用 |
510
+ |------|------|
511
+ | `/gsd:settings` | 配置模型 profile 和工作流代理 |
512
+ | `/gsd:set-profile <profile>` | 切换模型 profile(quality / balanced / budget) |
513
+ | `/gsd:add-todo [desc]` | 记录一个待办想法 |
514
+ | `/gsd:check-todos` | 查看待办列表 |
515
+ | `/gsd:debug [desc]` | 使用持久状态进行系统化调试 |
516
+ | `/gsd:quick [--full] [--discuss]` | 以 GSD 保障执行临时任务(`--full` 增加计划检查和验证,`--discuss` 先补上下文) |
517
+ | `/gsd:health [--repair]` | 校验 `.planning/` 目录完整性,带 `--repair` 时自动修复 |
518
+
519
+ <sup>¹ 由 reddit 用户 OracleGreyBeard 贡献</sup>
520
+
521
+ ---
522
+
523
+ ## 配置
524
+
525
+ GSD 将项目设置保存在 `.planning/config.json`。你可以在 `/gsd:new-project` 时配置,也可以稍后通过 `/gsd:settings` 修改。完整的配置 schema、工作流开关、git branching 选项以及各代理的模型分配,请查看[用户指南](docs/USER-GUIDE.md#configuration-reference)。
526
+
527
+ ### 核心设置
528
+
529
+ | Setting | Options | Default | 作用 |
530
+ |---------|---------|---------|------|
531
+ | `mode` | `yolo`, `interactive` | `interactive` | 自动批准,还是每一步确认 |
532
+ | `granularity` | `coarse`, `standard`, `fine` | `standard` | phase 粒度,也就是范围切分得多细 |
533
+
534
+ ### 模型 Profile
535
+
536
+ 控制各代理使用哪种 Claude 模型,在质量和 token 成本之间平衡。
537
+
538
+ | Profile | Planning | Execution | Verification |
539
+ |---------|----------|-----------|--------------|
540
+ | `quality` | Opus | Opus | Sonnet |
541
+ | `balanced`(默认) | Opus | Sonnet | Sonnet |
542
+ | `budget` | Sonnet | Sonnet | Haiku |
543
+
544
+ 切换方式:
545
+ ```
546
+ /gsd:set-profile budget
547
+ ```
548
+
549
+ 也可以通过 `/gsd:settings` 配置。
550
+
551
+ ### 工作流代理
552
+
553
+ 这些设置会在规划或执行时拉起额外代理。它们能提升质量,但也会增加 token 消耗和耗时。
554
+
555
+ | Setting | Default | 作用 |
556
+ |---------|---------|------|
557
+ | `workflow.research` | `true` | 每个 phase 规划前先调研领域知识 |
558
+ | `workflow.plan_check` | `true` | 执行前验证计划是否真能达成阶段目标 |
559
+ | `workflow.verifier` | `true` | 执行后确认“必须交付项”是否已经落地 |
560
+ | `workflow.auto_advance` | `false` | 自动串联 discuss → plan → execute,不中途停下 |
561
+
562
+ 可以用 `/gsd:settings` 开关这些项,也可以在单次命令里覆盖:
563
+ - `/gsd:plan-phase --skip-research`
564
+ - `/gsd:plan-phase --skip-verify`
565
+
566
+ ### 执行
567
+
568
+ | Setting | Default | 作用 |
569
+ |---------|---------|------|
570
+ | `parallelization.enabled` | `true` | 是否并行执行独立计划 |
571
+ | `planning.commit_docs` | `true` | 是否将 `.planning/` 纳入 git 跟踪 |
572
+
573
+ ### Git 分支策略
574
+
575
+ 控制 GSD 在执行过程中如何处理分支。
576
+
577
+ | Setting | Options | Default | 作用 |
578
+ |---------|---------|---------|------|
579
+ | `git.branching_strategy` | `none`, `phase`, `milestone` | `none` | 分支创建策略 |
580
+ | `git.phase_branch_template` | string | `gsd/phase-{phase}-{slug}` | phase 分支模板 |
581
+ | `git.milestone_branch_template` | string | `gsd/{milestone}-{slug}` | milestone 分支模板 |
582
+
583
+ **策略说明:**
584
+ - **`none`**:直接提交到当前分支(GSD 默认行为)
585
+ - **`phase`**:每个 phase 创建一个分支,在 phase 完成时合并
586
+ - **`milestone`**:整个里程碑只用一个分支,在里程碑完成时合并
587
+
588
+ 在里程碑完成时,GSD 会提供 squash merge(推荐)或保留历史的 merge 选项。
589
+
590
+ ---
591
+
592
+ ## 安全
593
+
594
+ ### 保护敏感文件
595
+
596
+ GSD 的代码库映射和分析命令会读取文件来理解你的项目。**包含机密信息的文件应当加入 Claude Code 的 deny list**:
597
+
598
+ 1. 打开 Claude Code 设置(项目级 `.claude/settings.json` 或全局设置)
599
+ 2. 把敏感文件模式加入 deny list:
600
+
601
+ ```json
602
+ {
603
+ "permissions": {
604
+ "deny": [
605
+ "Read(.env)",
606
+ "Read(.env.*)",
607
+ "Read(**/secrets/*)",
608
+ "Read(**/*credential*)",
609
+ "Read(**/*.pem)",
610
+ "Read(**/*.key)"
611
+ ]
612
+ }
613
+ }
614
+ ```
615
+
616
+ 这样无论你运行什么命令,Claude 都无法读取这些文件。
617
+
618
+ > [!IMPORTANT]
619
+ > GSD 内建了防止提交 secrets 的保护,但纵深防御依然是最佳实践。第一道防线应该是直接禁止读取敏感文件。
620
+
621
+ ---
622
+
623
+ ## 故障排查
624
+
625
+ **安装后找不到命令?**
626
+ - 重启你的运行时,让命令或 skills 重新加载
627
+ - 检查文件是否存在于 `~/.claude/commands/gsd/`(全局)或 `./.claude/commands/gsd/`(本地)
628
+ - 对 Codex,检查 skills 是否存在于 `~/.codex/skills/gsd-*/SKILL.md`(全局)或 `./.codex/skills/gsd-*/SKILL.md`(本地)
629
+
630
+ **命令行为不符合预期?**
631
+ - 运行 `/gsd:help` 确认安装成功
632
+ - 重新执行 `npx get-shit-done-cc` 进行重装
633
+
634
+ **想更新到最新版本?**
635
+ ```bash
636
+ npx get-shit-done-cc@latest
637
+ ```
638
+
639
+ **在 Docker 或容器环境中使用?**
640
+
641
+ 如果使用波浪线路径(`~/.claude/...`)时读取失败,请在安装前设置 `CLAUDE_CONFIG_DIR`:
642
+ ```bash
643
+ CLAUDE_CONFIG_DIR=/home/youruser/.claude npx get-shit-done-cc --global
644
+ ```
645
+ 这样可以确保使用绝对路径,而不是在容器里可能无法正确展开的 `~`。
646
+
647
+ ### 卸载
648
+
649
+ 如果你想彻底移除 GSD:
650
+
651
+ ```bash
652
+ # 全局安装
653
+ npx get-shit-done-cc --claude --global --uninstall
654
+ npx get-shit-done-cc --opencode --global --uninstall
655
+ npx get-shit-done-cc --codex --global --uninstall
656
+
657
+ # 本地安装(当前项目)
658
+ npx get-shit-done-cc --claude --local --uninstall
659
+ npx get-shit-done-cc --opencode --local --uninstall
660
+ npx get-shit-done-cc --codex --local --uninstall
661
+ ```
662
+
663
+ 这会移除所有 GSD 命令、代理、hooks 和设置,但会保留你其他配置。
664
+
665
+ ---
666
+
667
+ ## 社区移植版本
668
+
669
+ OpenCode、Gemini CLI 和 Codex 现在都已经通过 `npx get-shit-done-cc` 获得原生支持。
670
+
671
+ 这些社区移植版本曾率先探索多运行时支持:
672
+
673
+ | Project | Platform | Description |
674
+ |---------|----------|-------------|
675
+ | [gsd-opencode](https://github.com/rokicool/gsd-opencode) | OpenCode | 最初的 OpenCode 适配版本 |
676
+ | gsd-gemini (archived) | Gemini CLI | uberfuzzy 制作的最初 Gemini 适配版本 |
677
+
678
+ ---
679
+
680
+ ## Star History
681
+
682
+ <a href="https://star-history.com/#glittercowboy/get-shit-done&Date">
683
+ <picture>
684
+ <source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=glittercowboy/get-shit-done&type=Date&theme=dark" />
685
+ <source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=glittercowboy/get-shit-done&type=Date" />
686
+ <img alt="Star History Chart" src="https://api.star-history.com/svg?repos=glittercowboy/get-shit-done&type=Date" />
687
+ </picture>
688
+ </a>
689
+
690
+ ---
691
+
692
+ ## License
693
+
694
+ MIT License。详情见 [LICENSE](LICENSE)。
695
+
696
+ ---
697
+
698
+ <div align="center">
699
+
700
+ **Claude Code 很强,GSD 让它变得可靠。**
701
+
702
+ </div>