@bhargavvc/sdd-cc 1.30.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 (227) hide show
  1. package/LICENSE +21 -0
  2. package/README.ja-JP.md +834 -0
  3. package/README.ko-KR.md +823 -0
  4. package/README.md +846 -0
  5. package/README.pt-BR.md +452 -0
  6. package/README.zh-CN.md +800 -0
  7. package/agents/sdd-advisor-researcher.md +104 -0
  8. package/agents/sdd-assumptions-analyzer.md +105 -0
  9. package/agents/sdd-codebase-mapper.md +770 -0
  10. package/agents/sdd-debugger.md +1373 -0
  11. package/agents/sdd-executor.md +509 -0
  12. package/agents/sdd-integration-checker.md +443 -0
  13. package/agents/sdd-nyquist-auditor.md +176 -0
  14. package/agents/sdd-phase-researcher.md +698 -0
  15. package/agents/sdd-plan-checker.md +773 -0
  16. package/agents/sdd-planner.md +1354 -0
  17. package/agents/sdd-project-researcher.md +654 -0
  18. package/agents/sdd-research-synthesizer.md +247 -0
  19. package/agents/sdd-roadmapper.md +679 -0
  20. package/agents/sdd-ui-auditor.md +439 -0
  21. package/agents/sdd-ui-checker.md +300 -0
  22. package/agents/sdd-ui-researcher.md +357 -0
  23. package/agents/sdd-user-profiler.md +171 -0
  24. package/agents/sdd-verifier.md +700 -0
  25. package/bin/install.js +5009 -0
  26. package/commands/sdd/add-backlog.md +76 -0
  27. package/commands/sdd/add-phase.md +43 -0
  28. package/commands/sdd/add-tests.md +41 -0
  29. package/commands/sdd/add-todo.md +47 -0
  30. package/commands/sdd/audit-milestone.md +36 -0
  31. package/commands/sdd/audit-uat.md +24 -0
  32. package/commands/sdd/autonomous.md +41 -0
  33. package/commands/sdd/check-todos.md +45 -0
  34. package/commands/sdd/cleanup.md +18 -0
  35. package/commands/sdd/complete-milestone.md +136 -0
  36. package/commands/sdd/debug.md +173 -0
  37. package/commands/sdd/discuss-phase.md +64 -0
  38. package/commands/sdd/do.md +30 -0
  39. package/commands/sdd/execute-phase.md +59 -0
  40. package/commands/sdd/fast.md +30 -0
  41. package/commands/sdd/forensics.md +56 -0
  42. package/commands/sdd/health.md +22 -0
  43. package/commands/sdd/help.md +22 -0
  44. package/commands/sdd/insert-phase.md +32 -0
  45. package/commands/sdd/join-discord.md +18 -0
  46. package/commands/sdd/list-phase-assumptions.md +46 -0
  47. package/commands/sdd/list-workspaces.md +19 -0
  48. package/commands/sdd/manager.md +39 -0
  49. package/commands/sdd/map-codebase.md +71 -0
  50. package/commands/sdd/milestone-summary.md +51 -0
  51. package/commands/sdd/new-milestone.md +44 -0
  52. package/commands/sdd/new-project.md +42 -0
  53. package/commands/sdd/new-workspace.md +44 -0
  54. package/commands/sdd/next.md +24 -0
  55. package/commands/sdd/note.md +34 -0
  56. package/commands/sdd/pause-work.md +38 -0
  57. package/commands/sdd/plan-milestone-gaps.md +34 -0
  58. package/commands/sdd/plan-phase.md +47 -0
  59. package/commands/sdd/plant-seed.md +28 -0
  60. package/commands/sdd/pr-branch.md +25 -0
  61. package/commands/sdd/profile-user.md +46 -0
  62. package/commands/sdd/progress.md +24 -0
  63. package/commands/sdd/quick.md +47 -0
  64. package/commands/sdd/reapply-patches.md +123 -0
  65. package/commands/sdd/remove-phase.md +31 -0
  66. package/commands/sdd/remove-workspace.md +26 -0
  67. package/commands/sdd/research-phase.md +195 -0
  68. package/commands/sdd/resume-work.md +40 -0
  69. package/commands/sdd/review-backlog.md +61 -0
  70. package/commands/sdd/review.md +37 -0
  71. package/commands/sdd/session-report.md +19 -0
  72. package/commands/sdd/set-profile.md +12 -0
  73. package/commands/sdd/settings.md +36 -0
  74. package/commands/sdd/ship.md +23 -0
  75. package/commands/sdd/stats.md +18 -0
  76. package/commands/sdd/thread.md +127 -0
  77. package/commands/sdd/ui-phase.md +34 -0
  78. package/commands/sdd/ui-review.md +32 -0
  79. package/commands/sdd/update.md +37 -0
  80. package/commands/sdd/validate-phase.md +35 -0
  81. package/commands/sdd/verify-work.md +38 -0
  82. package/commands/sdd/workstreams.md +63 -0
  83. package/hooks/dist/sdd-check-update.js +114 -0
  84. package/hooks/dist/sdd-context-monitor.js +156 -0
  85. package/hooks/dist/sdd-prompt-guard.js +96 -0
  86. package/hooks/dist/sdd-statusline.js +119 -0
  87. package/hooks/dist/sdd-workflow-guard.js +94 -0
  88. package/package.json +55 -0
  89. package/scripts/base64-scan.sh +262 -0
  90. package/scripts/build-hooks.js +82 -0
  91. package/scripts/prompt-injection-scan.sh +198 -0
  92. package/scripts/rebrand-gsd-to-sdd.sh +220 -0
  93. package/scripts/run-tests.cjs +29 -0
  94. package/scripts/secret-scan.sh +227 -0
  95. package/scripts/sync-upstream.sh +56 -0
  96. package/sdd/bin/lib/commands.cjs +959 -0
  97. package/sdd/bin/lib/config.cjs +442 -0
  98. package/sdd/bin/lib/core.cjs +1230 -0
  99. package/sdd/bin/lib/frontmatter.cjs +336 -0
  100. package/sdd/bin/lib/init.cjs +1442 -0
  101. package/sdd/bin/lib/milestone.cjs +252 -0
  102. package/sdd/bin/lib/model-profiles.cjs +68 -0
  103. package/sdd/bin/lib/phase.cjs +888 -0
  104. package/sdd/bin/lib/profile-output.cjs +952 -0
  105. package/sdd/bin/lib/profile-pipeline.cjs +539 -0
  106. package/sdd/bin/lib/roadmap.cjs +329 -0
  107. package/sdd/bin/lib/security.cjs +382 -0
  108. package/sdd/bin/lib/state.cjs +1031 -0
  109. package/sdd/bin/lib/template.cjs +222 -0
  110. package/sdd/bin/lib/uat.cjs +282 -0
  111. package/sdd/bin/lib/verify.cjs +888 -0
  112. package/sdd/bin/lib/workstream.cjs +491 -0
  113. package/sdd/bin/sdd-tools.cjs +918 -0
  114. package/sdd/commands/sdd/workstreams.md +63 -0
  115. package/sdd/references/checkpoints.md +778 -0
  116. package/sdd/references/continuation-format.md +249 -0
  117. package/sdd/references/decimal-phase-calculation.md +64 -0
  118. package/sdd/references/git-integration.md +295 -0
  119. package/sdd/references/git-planning-commit.md +38 -0
  120. package/sdd/references/model-profile-resolution.md +36 -0
  121. package/sdd/references/model-profiles.md +139 -0
  122. package/sdd/references/phase-argument-parsing.md +61 -0
  123. package/sdd/references/planning-config.md +202 -0
  124. package/sdd/references/questioning.md +162 -0
  125. package/sdd/references/tdd.md +263 -0
  126. package/sdd/references/ui-brand.md +160 -0
  127. package/sdd/references/user-profiling.md +681 -0
  128. package/sdd/references/verification-patterns.md +612 -0
  129. package/sdd/references/workstream-flag.md +58 -0
  130. package/sdd/templates/DEBUG.md +164 -0
  131. package/sdd/templates/UAT.md +265 -0
  132. package/sdd/templates/UI-SPEC.md +100 -0
  133. package/sdd/templates/VALIDATION.md +76 -0
  134. package/sdd/templates/claude-md.md +122 -0
  135. package/sdd/templates/codebase/architecture.md +255 -0
  136. package/sdd/templates/codebase/concerns.md +310 -0
  137. package/sdd/templates/codebase/conventions.md +307 -0
  138. package/sdd/templates/codebase/integrations.md +280 -0
  139. package/sdd/templates/codebase/stack.md +186 -0
  140. package/sdd/templates/codebase/structure.md +285 -0
  141. package/sdd/templates/codebase/testing.md +480 -0
  142. package/sdd/templates/config.json +44 -0
  143. package/sdd/templates/context.md +352 -0
  144. package/sdd/templates/continue-here.md +78 -0
  145. package/sdd/templates/copilot-instructions.md +7 -0
  146. package/sdd/templates/debug-subagent-prompt.md +91 -0
  147. package/sdd/templates/dev-preferences.md +21 -0
  148. package/sdd/templates/discovery.md +146 -0
  149. package/sdd/templates/discussion-log.md +63 -0
  150. package/sdd/templates/milestone-archive.md +123 -0
  151. package/sdd/templates/milestone.md +115 -0
  152. package/sdd/templates/phase-prompt.md +610 -0
  153. package/sdd/templates/planner-subagent-prompt.md +117 -0
  154. package/sdd/templates/project.md +186 -0
  155. package/sdd/templates/requirements.md +231 -0
  156. package/sdd/templates/research-project/ARCHITECTURE.md +204 -0
  157. package/sdd/templates/research-project/FEATURES.md +147 -0
  158. package/sdd/templates/research-project/PITFALLS.md +200 -0
  159. package/sdd/templates/research-project/STACK.md +120 -0
  160. package/sdd/templates/research-project/SUMMARY.md +170 -0
  161. package/sdd/templates/research.md +552 -0
  162. package/sdd/templates/retrospective.md +54 -0
  163. package/sdd/templates/roadmap.md +202 -0
  164. package/sdd/templates/state.md +176 -0
  165. package/sdd/templates/summary-complex.md +59 -0
  166. package/sdd/templates/summary-minimal.md +41 -0
  167. package/sdd/templates/summary-standard.md +48 -0
  168. package/sdd/templates/summary.md +248 -0
  169. package/sdd/templates/user-profile.md +146 -0
  170. package/sdd/templates/user-setup.md +311 -0
  171. package/sdd/templates/verification-report.md +322 -0
  172. package/sdd/workflows/add-phase.md +112 -0
  173. package/sdd/workflows/add-tests.md +351 -0
  174. package/sdd/workflows/add-todo.md +158 -0
  175. package/sdd/workflows/audit-milestone.md +340 -0
  176. package/sdd/workflows/audit-uat.md +109 -0
  177. package/sdd/workflows/autonomous.md +891 -0
  178. package/sdd/workflows/check-todos.md +177 -0
  179. package/sdd/workflows/cleanup.md +152 -0
  180. package/sdd/workflows/complete-milestone.md +767 -0
  181. package/sdd/workflows/diagnose-issues.md +231 -0
  182. package/sdd/workflows/discovery-phase.md +289 -0
  183. package/sdd/workflows/discuss-phase-assumptions.md +653 -0
  184. package/sdd/workflows/discuss-phase.md +1049 -0
  185. package/sdd/workflows/do.md +104 -0
  186. package/sdd/workflows/execute-phase.md +846 -0
  187. package/sdd/workflows/execute-plan.md +514 -0
  188. package/sdd/workflows/fast.md +105 -0
  189. package/sdd/workflows/forensics.md +265 -0
  190. package/sdd/workflows/health.md +181 -0
  191. package/sdd/workflows/help.md +606 -0
  192. package/sdd/workflows/insert-phase.md +130 -0
  193. package/sdd/workflows/list-phase-assumptions.md +178 -0
  194. package/sdd/workflows/list-workspaces.md +56 -0
  195. package/sdd/workflows/manager.md +362 -0
  196. package/sdd/workflows/map-codebase.md +377 -0
  197. package/sdd/workflows/milestone-summary.md +223 -0
  198. package/sdd/workflows/new-milestone.md +486 -0
  199. package/sdd/workflows/new-project.md +1250 -0
  200. package/sdd/workflows/new-workspace.md +237 -0
  201. package/sdd/workflows/next.md +97 -0
  202. package/sdd/workflows/node-repair.md +92 -0
  203. package/sdd/workflows/note.md +156 -0
  204. package/sdd/workflows/pause-work.md +176 -0
  205. package/sdd/workflows/plan-milestone-gaps.md +273 -0
  206. package/sdd/workflows/plan-phase.md +859 -0
  207. package/sdd/workflows/plant-seed.md +169 -0
  208. package/sdd/workflows/pr-branch.md +129 -0
  209. package/sdd/workflows/profile-user.md +450 -0
  210. package/sdd/workflows/progress.md +507 -0
  211. package/sdd/workflows/quick.md +757 -0
  212. package/sdd/workflows/remove-phase.md +155 -0
  213. package/sdd/workflows/remove-workspace.md +90 -0
  214. package/sdd/workflows/research-phase.md +82 -0
  215. package/sdd/workflows/resume-project.md +326 -0
  216. package/sdd/workflows/review.md +228 -0
  217. package/sdd/workflows/session-report.md +146 -0
  218. package/sdd/workflows/settings.md +283 -0
  219. package/sdd/workflows/ship.md +228 -0
  220. package/sdd/workflows/stats.md +60 -0
  221. package/sdd/workflows/transition.md +671 -0
  222. package/sdd/workflows/ui-phase.md +302 -0
  223. package/sdd/workflows/ui-review.md +165 -0
  224. package/sdd/workflows/update.md +323 -0
  225. package/sdd/workflows/validate-phase.md +174 -0
  226. package/sdd/workflows/verify-phase.md +254 -0
  227. package/sdd/workflows/verify-work.md +637 -0
@@ -0,0 +1,195 @@
1
+ ---
2
+ name: sdd:research-phase
3
+ description: Research how to implement a phase (standalone - usually use /sdd:plan-phase instead)
4
+ argument-hint: "[phase]"
5
+ allowed-tools:
6
+ - Read
7
+ - Bash
8
+ - Task
9
+ ---
10
+
11
+ <objective>
12
+ Research how to implement a phase. Spawns sdd-phase-researcher agent with phase context.
13
+
14
+ **Note:** This is a standalone research command. For most workflows, use `/sdd:plan-phase` which integrates research automatically.
15
+
16
+ **Use this command when:**
17
+ - You want to research without planning yet
18
+ - You want to re-research after planning is complete
19
+ - You need to investigate before deciding if a phase is feasible
20
+
21
+ **Orchestrator role:** Parse phase, validate against roadmap, check existing research, gather context, spawn researcher agent, present results.
22
+
23
+ **Why subagent:** Research burns context fast (WebSearch, Context7 queries, source verification). Fresh 200k context for investigation. Main context stays lean for user interaction.
24
+ </objective>
25
+
26
+ <available_agent_types>
27
+ Valid SDD subagent types (use exact names โ€” do not fall back to 'general-purpose'):
28
+ - sdd-phase-researcher โ€” Researches technical approaches for a phase
29
+ </available_agent_types>
30
+
31
+ <context>
32
+ Phase number: $ARGUMENTS (required)
33
+
34
+ Normalize phase input in step 1 before any directory lookups.
35
+ </context>
36
+
37
+ <process>
38
+
39
+ ## 0. Initialize Context
40
+
41
+ ```bash
42
+ INIT=$(node "$HOME/.claude/sdd/bin/sdd-tools.cjs" init phase-op "$ARGUMENTS")
43
+ if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
44
+ ```
45
+
46
+ Extract from init JSON: `phase_dir`, `phase_number`, `phase_name`, `phase_found`, `commit_docs`, `has_research`, `state_path`, `requirements_path`, `context_path`, `research_path`.
47
+
48
+ Resolve researcher model:
49
+ ```bash
50
+ RESEARCHER_MODEL=$(node "$HOME/.claude/sdd/bin/sdd-tools.cjs" resolve-model sdd-phase-researcher --raw)
51
+ ```
52
+
53
+ ## 1. Validate Phase
54
+
55
+ ```bash
56
+ PHASE_INFO=$(node "$HOME/.claude/sdd/bin/sdd-tools.cjs" roadmap get-phase "${phase_number}")
57
+ ```
58
+
59
+ **If `found` is false:** Error and exit. **If `found` is true:** Extract `phase_number`, `phase_name`, `goal` from JSON.
60
+
61
+ ## 2. Check Existing Research
62
+
63
+ ```bash
64
+ ls .planning/phases/${PHASE}-*/RESEARCH.md 2>/dev/null
65
+ ```
66
+
67
+ **If exists:** Offer: 1) Update research, 2) View existing, 3) Skip. Wait for response.
68
+
69
+ **If doesn't exist:** Continue.
70
+
71
+ ## 3. Gather Phase Context
72
+
73
+ Use paths from INIT (do not inline file contents in orchestrator context):
74
+ - `requirements_path`
75
+ - `context_path`
76
+ - `state_path`
77
+
78
+ Present summary with phase description and what files the researcher will load.
79
+
80
+ ## 4. Spawn sdd-phase-researcher Agent
81
+
82
+ Research modes: ecosystem (default), feasibility, implementation, comparison.
83
+
84
+ ```markdown
85
+ <research_type>
86
+ Phase Research โ€” investigating HOW to implement a specific phase well.
87
+ </research_type>
88
+
89
+ <key_insight>
90
+ The question is NOT "which library should I use?"
91
+
92
+ The question is: "What do I not know that I don't know?"
93
+
94
+ For this phase, discover:
95
+ - What's the established architecture pattern?
96
+ - What libraries form the standard stack?
97
+ - What problems do people commonly hit?
98
+ - What's SOTA vs what Claude's training thinks is SOTA?
99
+ - What should NOT be hand-rolled?
100
+ </key_insight>
101
+
102
+ <objective>
103
+ Research implementation approach for Phase {phase_number}: {phase_name}
104
+ Mode: ecosystem
105
+ </objective>
106
+
107
+ <files_to_read>
108
+ - {requirements_path} (Requirements)
109
+ - {context_path} (Phase context from discuss-phase, if exists)
110
+ - {state_path} (Prior project decisions and blockers)
111
+ </files_to_read>
112
+
113
+ <additional_context>
114
+ **Phase description:** {phase_description}
115
+ </additional_context>
116
+
117
+ <downstream_consumer>
118
+ Your RESEARCH.md will be loaded by `/sdd:plan-phase` which uses specific sections:
119
+ - `## Standard Stack` โ†’ Plans use these libraries
120
+ - `## Architecture Patterns` โ†’ Task structure follows these
121
+ - `## Don't Hand-Roll` โ†’ Tasks NEVER build custom solutions for listed problems
122
+ - `## Common Pitfalls` โ†’ Verification steps check for these
123
+ - `## Code Examples` โ†’ Task actions reference these patterns
124
+
125
+ Be prescriptive, not exploratory. "Use X" not "Consider X or Y."
126
+ </downstream_consumer>
127
+
128
+ <quality_gate>
129
+ Before declaring complete, verify:
130
+ - [ ] All domains investigated (not just some)
131
+ - [ ] Negative claims verified with official docs
132
+ - [ ] Multiple sources for critical claims
133
+ - [ ] Confidence levels assigned honestly
134
+ - [ ] Section names match what plan-phase expects
135
+ </quality_gate>
136
+
137
+ <output>
138
+ Write to: .planning/phases/${PHASE}-{slug}/${PHASE}-RESEARCH.md
139
+ </output>
140
+ ```
141
+
142
+ ```
143
+ Task(
144
+ prompt=filled_prompt,
145
+ subagent_type="sdd-phase-researcher",
146
+ model="{researcher_model}",
147
+ description="Research Phase {phase}"
148
+ )
149
+ ```
150
+
151
+ ## 5. Handle Agent Return
152
+
153
+ **`## RESEARCH COMPLETE`:** Display summary, offer: Plan phase, Dig deeper, Review full, Done.
154
+
155
+ **`## CHECKPOINT REACHED`:** Present to user, get response, spawn continuation.
156
+
157
+ **`## RESEARCH INCONCLUSIVE`:** Show what was attempted, offer: Add context, Try different mode, Manual.
158
+
159
+ ## 6. Spawn Continuation Agent
160
+
161
+ ```markdown
162
+ <objective>
163
+ Continue research for Phase {phase_number}: {phase_name}
164
+ </objective>
165
+
166
+ <prior_state>
167
+ <files_to_read>
168
+ - .planning/phases/${PHASE}-{slug}/${PHASE}-RESEARCH.md (Existing research)
169
+ </files_to_read>
170
+ </prior_state>
171
+
172
+ <checkpoint_response>
173
+ **Type:** {checkpoint_type}
174
+ **Response:** {user_response}
175
+ </checkpoint_response>
176
+ ```
177
+
178
+ ```
179
+ Task(
180
+ prompt=continuation_prompt,
181
+ subagent_type="sdd-phase-researcher",
182
+ model="{researcher_model}",
183
+ description="Continue research Phase {phase}"
184
+ )
185
+ ```
186
+
187
+ </process>
188
+
189
+ <success_criteria>
190
+ - [ ] Phase validated against roadmap
191
+ - [ ] Existing research checked
192
+ - [ ] sdd-phase-researcher spawned with context
193
+ - [ ] Checkpoints handled correctly
194
+ - [ ] User knows next steps
195
+ </success_criteria>
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: sdd:resume-work
3
+ description: Resume work from previous session with full context restoration
4
+ allowed-tools:
5
+ - Read
6
+ - Bash
7
+ - Write
8
+ - AskUserQuestion
9
+ - SlashCommand
10
+ ---
11
+
12
+ <objective>
13
+ Restore complete project context and resume work seamlessly from previous session.
14
+
15
+ Routes to the resume-project workflow which handles:
16
+
17
+ - STATE.md loading (or reconstruction if missing)
18
+ - Checkpoint detection (.continue-here files)
19
+ - Incomplete work detection (PLAN without SUMMARY)
20
+ - Status presentation
21
+ - Context-aware next action routing
22
+ </objective>
23
+
24
+ <execution_context>
25
+ @~/.claude/sdd/workflows/resume-project.md
26
+ </execution_context>
27
+
28
+ <process>
29
+ **Follow the resume-project workflow** from `@~/.claude/sdd/workflows/resume-project.md`.
30
+
31
+ The workflow handles all resumption logic including:
32
+
33
+ 1. Project existence verification
34
+ 2. STATE.md loading or reconstruction
35
+ 3. Checkpoint and incomplete work detection
36
+ 4. Visual status presentation
37
+ 5. Context-aware option offering (checks CONTEXT.md before suggesting plan vs discuss)
38
+ 6. Routing to appropriate next command
39
+ 7. Session continuity updates
40
+ </process>
@@ -0,0 +1,61 @@
1
+ ---
2
+ name: sdd:review-backlog
3
+ description: Review and promote backlog items to active milestone
4
+ allowed-tools:
5
+ - Read
6
+ - Write
7
+ - Bash
8
+ ---
9
+
10
+ <objective>
11
+ Review all 999.x backlog items and optionally promote them into the active
12
+ milestone sequence or remove stale entries.
13
+ </objective>
14
+
15
+ <process>
16
+
17
+ 1. **List backlog items:**
18
+ ```bash
19
+ ls -d .planning/phases/999* 2>/dev/null || echo "No backlog items found"
20
+ ```
21
+
22
+ 2. **Read ROADMAP.md** and extract all 999.x phase entries:
23
+ ```bash
24
+ cat .planning/ROADMAP.md
25
+ ```
26
+ Show each backlog item with its description, any accumulated context (CONTEXT.md, RESEARCH.md), and creation date.
27
+
28
+ 3. **Present the list to the user** via AskUserQuestion:
29
+ - For each backlog item, show: phase number, description, accumulated artifacts
30
+ - Options per item: **Promote** (move to active), **Keep** (leave in backlog), **Remove** (delete)
31
+
32
+ 4. **For items to PROMOTE:**
33
+ - Find the next sequential phase number in the active milestone
34
+ - Rename the directory from `999.x-slug` to `{new_num}-slug`:
35
+ ```bash
36
+ NEW_NUM=$(node "$HOME/.claude/sdd/bin/sdd-tools.cjs" phase add "${DESCRIPTION}" --raw)
37
+ ```
38
+ - Move accumulated artifacts to the new phase directory
39
+ - Update ROADMAP.md: move the entry from `## Backlog` section to the active phase list
40
+ - Remove `(BACKLOG)` marker
41
+ - Add appropriate `**Depends on:**` field
42
+
43
+ 5. **For items to REMOVE:**
44
+ - Delete the phase directory
45
+ - Remove the entry from ROADMAP.md `## Backlog` section
46
+
47
+ 6. **Commit changes:**
48
+ ```bash
49
+ node "$HOME/.claude/sdd/bin/sdd-tools.cjs" commit "docs: review backlog โ€” promoted N, removed M" --files .planning/ROADMAP.md
50
+ ```
51
+
52
+ 7. **Report summary:**
53
+ ```
54
+ ## ๐Ÿ“‹ Backlog Review Complete
55
+
56
+ Promoted: {list of promoted items with new phase numbers}
57
+ Kept: {list of items remaining in backlog}
58
+ Removed: {list of deleted items}
59
+ ```
60
+
61
+ </process>
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: sdd:review
3
+ description: Request cross-AI peer review of phase plans from external AI CLIs
4
+ argument-hint: "--phase N [--gemini] [--claude] [--codex] [--all]"
5
+ allowed-tools:
6
+ - Read
7
+ - Write
8
+ - Bash
9
+ - Glob
10
+ - Grep
11
+ ---
12
+
13
+ <objective>
14
+ Invoke external AI CLIs (Gemini, Claude, Codex) to independently review phase plans.
15
+ Produces a structured REVIEWS.md with per-reviewer feedback that can be fed back into
16
+ planning via /sdd:plan-phase --reviews.
17
+
18
+ **Flow:** Detect CLIs โ†’ Build review prompt โ†’ Invoke each CLI โ†’ Collect responses โ†’ Write REVIEWS.md
19
+ </objective>
20
+
21
+ <execution_context>
22
+ @~/.claude/sdd/workflows/review.md
23
+ </execution_context>
24
+
25
+ <context>
26
+ Phase number: extracted from $ARGUMENTS (required)
27
+
28
+ **Flags:**
29
+ - `--gemini` โ€” Include Gemini CLI review
30
+ - `--claude` โ€” Include Claude CLI review (uses separate session)
31
+ - `--codex` โ€” Include Codex CLI review
32
+ - `--all` โ€” Include all available CLIs
33
+ </context>
34
+
35
+ <process>
36
+ Execute the review workflow from @~/.claude/sdd/workflows/review.md end-to-end.
37
+ </process>
@@ -0,0 +1,19 @@
1
+ ---
2
+ name: sdd:session-report
3
+ description: Generate a session report with token usage estimates, work summary, and outcomes
4
+ allowed-tools:
5
+ - Read
6
+ - Bash
7
+ - Write
8
+ ---
9
+ <objective>
10
+ Generate a structured SESSION_REPORT.md document capturing session outcomes, work performed, and estimated resource usage. Provides a shareable artifact for post-session review.
11
+ </objective>
12
+
13
+ <execution_context>
14
+ @~/.claude/sdd/workflows/session-report.md
15
+ </execution_context>
16
+
17
+ <process>
18
+ Execute the session-report workflow from @~/.claude/sdd/workflows/session-report.md end-to-end.
19
+ </process>
@@ -0,0 +1,12 @@
1
+ ---
2
+ name: sdd:set-profile
3
+ description: Switch model profile for SDD agents (quality/balanced/budget/inherit)
4
+ argument-hint: <profile (quality|balanced|budget|inherit)>
5
+ model: haiku
6
+ allowed-tools:
7
+ - Bash
8
+ ---
9
+
10
+ Show the following output to the user verbatim, with no extra commentary:
11
+
12
+ !`node "$HOME/.claude/sdd/bin/sdd-tools.cjs" config-set-model-profile $ARGUMENTS --raw`
@@ -0,0 +1,36 @@
1
+ ---
2
+ name: sdd:settings
3
+ description: Configure SDD workflow toggles and model profile
4
+ allowed-tools:
5
+ - Read
6
+ - Write
7
+ - Bash
8
+ - AskUserQuestion
9
+ ---
10
+
11
+ <objective>
12
+ Interactive configuration of SDD workflow agents and model profile via multi-question prompt.
13
+
14
+ Routes to the settings workflow which handles:
15
+ - Config existence ensuring
16
+ - Current settings reading and parsing
17
+ - Interactive 5-question prompt (model, research, plan_check, verifier, branching)
18
+ - Config merging and writing
19
+ - Confirmation display with quick command references
20
+ </objective>
21
+
22
+ <execution_context>
23
+ @~/.claude/sdd/workflows/settings.md
24
+ </execution_context>
25
+
26
+ <process>
27
+ **Follow the settings workflow** from `@~/.claude/sdd/workflows/settings.md`.
28
+
29
+ The workflow handles all logic including:
30
+ 1. Config file creation with defaults if missing
31
+ 2. Current config reading
32
+ 3. Interactive settings presentation with pre-selection
33
+ 4. Answer parsing and config merging
34
+ 5. File writing
35
+ 6. Confirmation display
36
+ </process>
@@ -0,0 +1,23 @@
1
+ ---
2
+ name: sdd:ship
3
+ description: Create PR, run review, and prepare for merge after verification passes
4
+ argument-hint: "[phase number or milestone, e.g., '4' or 'v1.0']"
5
+ allowed-tools:
6
+ - Read
7
+ - Bash
8
+ - Grep
9
+ - Glob
10
+ - Write
11
+ - AskUserQuestion
12
+ ---
13
+ <objective>
14
+ Bridge local completion โ†’ merged PR. After /sdd:verify-work passes, ship the work: push branch, create PR with auto-generated body, optionally trigger review, and track the merge.
15
+
16
+ Closes the plan โ†’ execute โ†’ verify โ†’ ship loop.
17
+ </objective>
18
+
19
+ <execution_context>
20
+ @~/.claude/sdd/workflows/ship.md
21
+ </execution_context>
22
+
23
+ Execute the ship workflow from @~/.claude/sdd/workflows/ship.md end-to-end.
@@ -0,0 +1,18 @@
1
+ ---
2
+ name: sdd:stats
3
+ description: Display project statistics โ€” phases, plans, requirements, git metrics, and timeline
4
+ allowed-tools:
5
+ - Read
6
+ - Bash
7
+ ---
8
+ <objective>
9
+ Display comprehensive project statistics including phase progress, plan execution metrics, requirements completion, git history stats, and project timeline.
10
+ </objective>
11
+
12
+ <execution_context>
13
+ @~/.claude/sdd/workflows/stats.md
14
+ </execution_context>
15
+
16
+ <process>
17
+ Execute the stats workflow from @~/.claude/sdd/workflows/stats.md end-to-end.
18
+ </process>
@@ -0,0 +1,127 @@
1
+ ---
2
+ name: sdd:thread
3
+ description: Manage persistent context threads for cross-session work
4
+ argument-hint: [name | description]
5
+ allowed-tools:
6
+ - Read
7
+ - Write
8
+ - Bash
9
+ ---
10
+
11
+ <objective>
12
+ Create, list, or resume persistent context threads. Threads are lightweight
13
+ cross-session knowledge stores for work that spans multiple sessions but
14
+ doesn't belong to any specific phase.
15
+ </objective>
16
+
17
+ <process>
18
+
19
+ **Parse $ARGUMENTS to determine mode:**
20
+
21
+ <mode_list>
22
+ **If no arguments or $ARGUMENTS is empty:**
23
+
24
+ List all threads:
25
+ ```bash
26
+ ls .planning/threads/*.md 2>/dev/null
27
+ ```
28
+
29
+ For each thread, read the first few lines to show title and status:
30
+ ```
31
+ ## Active Threads
32
+
33
+ | Thread | Status | Last Updated |
34
+ |--------|--------|-------------|
35
+ | fix-deploy-key-auth | OPEN | 2026-03-15 |
36
+ | pasta-tcp-timeout | RESOLVED | 2026-03-12 |
37
+ | perf-investigation | IN PROGRESS | 2026-03-17 |
38
+ ```
39
+
40
+ If no threads exist, show:
41
+ ```
42
+ No threads found. Create one with: /sdd:thread <description>
43
+ ```
44
+ </mode_list>
45
+
46
+ <mode_resume>
47
+ **If $ARGUMENTS matches an existing thread name (file exists):**
48
+
49
+ Resume the thread โ€” load its context into the current session:
50
+ ```bash
51
+ cat ".planning/threads/${THREAD_NAME}.md"
52
+ ```
53
+
54
+ Display the thread content and ask what the user wants to work on next.
55
+ Update the thread's status to `IN PROGRESS` if it was `OPEN`.
56
+ </mode_resume>
57
+
58
+ <mode_create>
59
+ **If $ARGUMENTS is a new description (no matching thread file):**
60
+
61
+ Create a new thread:
62
+
63
+ 1. Generate slug from description:
64
+ ```bash
65
+ SLUG=$(node "$HOME/.claude/sdd/bin/sdd-tools.cjs" generate-slug "$ARGUMENTS")
66
+ ```
67
+
68
+ 2. Create the threads directory if needed:
69
+ ```bash
70
+ mkdir -p .planning/threads
71
+ ```
72
+
73
+ 3. Write the thread file:
74
+ ```bash
75
+ cat > ".planning/threads/${SLUG}.md" << 'EOF'
76
+ # Thread: {description}
77
+
78
+ ## Status: OPEN
79
+
80
+ ## Goal
81
+
82
+ {description}
83
+
84
+ ## Context
85
+
86
+ *Created from conversation on {today's date}.*
87
+
88
+ ## References
89
+
90
+ - *(add links, file paths, or issue numbers)*
91
+
92
+ ## Next Steps
93
+
94
+ - *(what the next session should do first)*
95
+ EOF
96
+ ```
97
+
98
+ 4. If there's relevant context in the current conversation (code snippets,
99
+ error messages, investigation results), extract and add it to the Context
100
+ section.
101
+
102
+ 5. Commit:
103
+ ```bash
104
+ node "$HOME/.claude/sdd/bin/sdd-tools.cjs" commit "docs: create thread โ€” ${ARGUMENTS}" --files ".planning/threads/${SLUG}.md"
105
+ ```
106
+
107
+ 6. Report:
108
+ ```
109
+ ## ๐Ÿงต Thread Created
110
+
111
+ Thread: {slug}
112
+ File: .planning/threads/{slug}.md
113
+
114
+ Resume anytime with: /sdd:thread {slug}
115
+ ```
116
+ </mode_create>
117
+
118
+ </process>
119
+
120
+ <notes>
121
+ - Threads are NOT phase-scoped โ€” they exist independently of the roadmap
122
+ - Lighter weight than /sdd:pause-work โ€” no phase state, no plan context
123
+ - The value is in Context and Next Steps โ€” a cold-start session can pick up immediately
124
+ - Threads can be promoted to phases or backlog items when they mature:
125
+ /sdd:add-phase or /sdd:add-backlog with context from the thread
126
+ - Thread files live in .planning/threads/ โ€” no collision with phases or other SDD structures
127
+ </notes>
@@ -0,0 +1,34 @@
1
+ ---
2
+ name: sdd:ui-phase
3
+ description: Generate UI design contract (UI-SPEC.md) for frontend phases
4
+ argument-hint: "[phase]"
5
+ allowed-tools:
6
+ - Read
7
+ - Write
8
+ - Bash
9
+ - Glob
10
+ - Grep
11
+ - Task
12
+ - WebFetch
13
+ - AskUserQuestion
14
+ - mcp__context7__*
15
+ ---
16
+ <objective>
17
+ Create a UI design contract (UI-SPEC.md) for a frontend phase.
18
+ Orchestrates sdd-ui-researcher and sdd-ui-checker.
19
+ Flow: Validate โ†’ Research UI โ†’ Verify UI-SPEC โ†’ Done
20
+ </objective>
21
+
22
+ <execution_context>
23
+ @~/.claude/sdd/workflows/ui-phase.md
24
+ @~/.claude/sdd/references/ui-brand.md
25
+ </execution_context>
26
+
27
+ <context>
28
+ Phase number: $ARGUMENTS โ€” optional, auto-detects next unplanned phase if omitted.
29
+ </context>
30
+
31
+ <process>
32
+ Execute @~/.claude/sdd/workflows/ui-phase.md end-to-end.
33
+ Preserve all workflow gates.
34
+ </process>
@@ -0,0 +1,32 @@
1
+ ---
2
+ name: sdd:ui-review
3
+ description: Retroactive 6-pillar visual audit of implemented frontend code
4
+ argument-hint: "[phase]"
5
+ allowed-tools:
6
+ - Read
7
+ - Write
8
+ - Bash
9
+ - Glob
10
+ - Grep
11
+ - Task
12
+ - AskUserQuestion
13
+ ---
14
+ <objective>
15
+ Conduct a retroactive 6-pillar visual audit. Produces UI-REVIEW.md with
16
+ graded assessment (1-4 per pillar). Works on any project.
17
+ Output: {phase_num}-UI-REVIEW.md
18
+ </objective>
19
+
20
+ <execution_context>
21
+ @~/.claude/sdd/workflows/ui-review.md
22
+ @~/.claude/sdd/references/ui-brand.md
23
+ </execution_context>
24
+
25
+ <context>
26
+ Phase: $ARGUMENTS โ€” optional, defaults to last completed phase.
27
+ </context>
28
+
29
+ <process>
30
+ Execute @~/.claude/sdd/workflows/ui-review.md end-to-end.
31
+ Preserve all workflow gates.
32
+ </process>
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: sdd:update
3
+ description: Update SDD to latest version with changelog display
4
+ allowed-tools:
5
+ - Bash
6
+ - AskUserQuestion
7
+ ---
8
+
9
+ <objective>
10
+ Check for SDD updates, install if available, and display what changed.
11
+
12
+ Routes to the update workflow which handles:
13
+ - Version detection (local vs global installation)
14
+ - npm version checking
15
+ - Changelog fetching and display
16
+ - User confirmation with clean install warning
17
+ - Update execution and cache clearing
18
+ - Restart reminder
19
+ </objective>
20
+
21
+ <execution_context>
22
+ @~/.claude/sdd/workflows/update.md
23
+ </execution_context>
24
+
25
+ <process>
26
+ **Follow the update workflow** from `@~/.claude/sdd/workflows/update.md`.
27
+
28
+ The workflow handles all logic including:
29
+ 1. Installed version detection (local/global)
30
+ 2. Latest version checking via npm
31
+ 3. Version comparison
32
+ 4. Changelog fetching and extraction
33
+ 5. Clean install warning display
34
+ 6. User confirmation
35
+ 7. Update execution
36
+ 8. Cache clearing
37
+ </process>