gsd-opencode 1.22.1 → 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 (156) hide show
  1. package/agents/gsd-advisor-researcher.md +112 -0
  2. package/agents/gsd-assumptions-analyzer.md +110 -0
  3. package/agents/gsd-codebase-mapper.md +0 -2
  4. package/agents/gsd-debugger.md +118 -2
  5. package/agents/gsd-executor.md +24 -4
  6. package/agents/gsd-integration-checker.md +0 -2
  7. package/agents/gsd-nyquist-auditor.md +0 -2
  8. package/agents/gsd-phase-researcher.md +150 -5
  9. package/agents/gsd-plan-checker.md +70 -5
  10. package/agents/gsd-planner.md +49 -4
  11. package/agents/gsd-project-researcher.md +28 -3
  12. package/agents/gsd-research-synthesizer.md +0 -2
  13. package/agents/gsd-roadmapper.md +29 -2
  14. package/agents/gsd-ui-auditor.md +445 -0
  15. package/agents/gsd-ui-checker.md +305 -0
  16. package/agents/gsd-ui-researcher.md +368 -0
  17. package/agents/gsd-user-profiler.md +173 -0
  18. package/agents/gsd-verifier.md +123 -4
  19. package/commands/gsd/gsd-add-backlog.md +76 -0
  20. package/commands/gsd/gsd-audit-uat.md +24 -0
  21. package/commands/gsd/gsd-autonomous.md +41 -0
  22. package/commands/gsd/gsd-debug.md +5 -0
  23. package/commands/gsd/gsd-discuss-phase.md +10 -36
  24. package/commands/gsd/gsd-do.md +30 -0
  25. package/commands/gsd/gsd-execute-phase.md +20 -2
  26. package/commands/gsd/gsd-fast.md +30 -0
  27. package/commands/gsd/gsd-forensics.md +56 -0
  28. package/commands/gsd/gsd-list-workspaces.md +19 -0
  29. package/commands/gsd/gsd-manager.md +39 -0
  30. package/commands/gsd/gsd-milestone-summary.md +51 -0
  31. package/commands/gsd/gsd-new-workspace.md +44 -0
  32. package/commands/gsd/gsd-next.md +24 -0
  33. package/commands/gsd/gsd-note.md +34 -0
  34. package/commands/gsd/gsd-plan-phase.md +3 -1
  35. package/commands/gsd/gsd-plant-seed.md +28 -0
  36. package/commands/gsd/gsd-pr-branch.md +25 -0
  37. package/commands/gsd/gsd-profile-user.md +46 -0
  38. package/commands/gsd/gsd-quick.md +4 -2
  39. package/commands/gsd/gsd-reapply-patches.md +9 -8
  40. package/commands/gsd/gsd-remove-workspace.md +26 -0
  41. package/commands/gsd/gsd-research-phase.md +5 -0
  42. package/commands/gsd/gsd-review-backlog.md +61 -0
  43. package/commands/gsd/gsd-review.md +37 -0
  44. package/commands/gsd/gsd-session-report.md +19 -0
  45. package/commands/gsd/gsd-set-profile.md +24 -23
  46. package/commands/gsd/gsd-ship.md +23 -0
  47. package/commands/gsd/gsd-stats.md +18 -0
  48. package/commands/gsd/gsd-thread.md +127 -0
  49. package/commands/gsd/gsd-ui-phase.md +34 -0
  50. package/commands/gsd/gsd-ui-review.md +32 -0
  51. package/commands/gsd/gsd-workstreams.md +66 -0
  52. package/get-shit-done/bin/gsd-tools.cjs +410 -84
  53. package/get-shit-done/bin/lib/commands.cjs +429 -18
  54. package/get-shit-done/bin/lib/config.cjs +318 -45
  55. package/get-shit-done/bin/lib/core.cjs +822 -84
  56. package/get-shit-done/bin/lib/frontmatter.cjs +78 -41
  57. package/get-shit-done/bin/lib/init.cjs +836 -104
  58. package/get-shit-done/bin/lib/milestone.cjs +44 -33
  59. package/get-shit-done/bin/lib/model-profiles.cjs +68 -0
  60. package/get-shit-done/bin/lib/phase.cjs +293 -306
  61. package/get-shit-done/bin/lib/profile-output.cjs +952 -0
  62. package/get-shit-done/bin/lib/profile-pipeline.cjs +539 -0
  63. package/get-shit-done/bin/lib/roadmap.cjs +55 -24
  64. package/get-shit-done/bin/lib/security.cjs +382 -0
  65. package/get-shit-done/bin/lib/state.cjs +363 -53
  66. package/get-shit-done/bin/lib/template.cjs +2 -2
  67. package/get-shit-done/bin/lib/uat.cjs +282 -0
  68. package/get-shit-done/bin/lib/verify.cjs +104 -36
  69. package/get-shit-done/bin/lib/workstream.cjs +491 -0
  70. package/get-shit-done/references/checkpoints.md +12 -10
  71. package/get-shit-done/references/decimal-phase-calculation.md +2 -3
  72. package/get-shit-done/references/git-integration.md +47 -0
  73. package/get-shit-done/references/model-profile-resolution.md +2 -0
  74. package/get-shit-done/references/model-profiles.md +62 -16
  75. package/get-shit-done/references/phase-argument-parsing.md +2 -2
  76. package/get-shit-done/references/planning-config.md +3 -1
  77. package/get-shit-done/references/user-profiling.md +681 -0
  78. package/get-shit-done/references/workstream-flag.md +58 -0
  79. package/get-shit-done/templates/UAT.md +21 -3
  80. package/get-shit-done/templates/UI-SPEC.md +100 -0
  81. package/get-shit-done/templates/claude-md.md +122 -0
  82. package/get-shit-done/templates/config.json +10 -3
  83. package/get-shit-done/templates/context.md +61 -6
  84. package/get-shit-done/templates/dev-preferences.md +21 -0
  85. package/get-shit-done/templates/discussion-log.md +63 -0
  86. package/get-shit-done/templates/phase-prompt.md +46 -5
  87. package/get-shit-done/templates/project.md +2 -0
  88. package/get-shit-done/templates/state.md +2 -2
  89. package/get-shit-done/templates/user-profile.md +146 -0
  90. package/get-shit-done/workflows/add-phase.md +2 -2
  91. package/get-shit-done/workflows/add-tests.md +4 -4
  92. package/get-shit-done/workflows/add-todo.md +3 -3
  93. package/get-shit-done/workflows/audit-milestone.md +13 -5
  94. package/get-shit-done/workflows/audit-uat.md +109 -0
  95. package/get-shit-done/workflows/autonomous.md +891 -0
  96. package/get-shit-done/workflows/check-todos.md +2 -2
  97. package/get-shit-done/workflows/cleanup.md +4 -4
  98. package/get-shit-done/workflows/complete-milestone.md +9 -6
  99. package/get-shit-done/workflows/diagnose-issues.md +15 -3
  100. package/get-shit-done/workflows/discovery-phase.md +3 -3
  101. package/get-shit-done/workflows/discuss-phase-assumptions.md +653 -0
  102. package/get-shit-done/workflows/discuss-phase.md +411 -38
  103. package/get-shit-done/workflows/do.md +104 -0
  104. package/get-shit-done/workflows/execute-phase.md +405 -18
  105. package/get-shit-done/workflows/execute-plan.md +77 -12
  106. package/get-shit-done/workflows/fast.md +105 -0
  107. package/get-shit-done/workflows/forensics.md +265 -0
  108. package/get-shit-done/workflows/health.md +28 -6
  109. package/get-shit-done/workflows/help.md +124 -7
  110. package/get-shit-done/workflows/insert-phase.md +2 -2
  111. package/get-shit-done/workflows/list-phase-assumptions.md +2 -2
  112. package/get-shit-done/workflows/list-workspaces.md +56 -0
  113. package/get-shit-done/workflows/manager.md +362 -0
  114. package/get-shit-done/workflows/map-codebase.md +74 -13
  115. package/get-shit-done/workflows/milestone-summary.md +223 -0
  116. package/get-shit-done/workflows/new-milestone.md +120 -18
  117. package/get-shit-done/workflows/new-project.md +178 -39
  118. package/get-shit-done/workflows/new-workspace.md +237 -0
  119. package/get-shit-done/workflows/next.md +97 -0
  120. package/get-shit-done/workflows/node-repair.md +92 -0
  121. package/get-shit-done/workflows/note.md +156 -0
  122. package/get-shit-done/workflows/pause-work.md +62 -8
  123. package/get-shit-done/workflows/plan-milestone-gaps.md +4 -5
  124. package/get-shit-done/workflows/plan-phase.md +332 -33
  125. package/get-shit-done/workflows/plant-seed.md +169 -0
  126. package/get-shit-done/workflows/pr-branch.md +129 -0
  127. package/get-shit-done/workflows/profile-user.md +450 -0
  128. package/get-shit-done/workflows/progress.md +145 -20
  129. package/get-shit-done/workflows/quick.md +205 -49
  130. package/get-shit-done/workflows/remove-phase.md +2 -2
  131. package/get-shit-done/workflows/remove-workspace.md +90 -0
  132. package/get-shit-done/workflows/research-phase.md +11 -3
  133. package/get-shit-done/workflows/resume-project.md +35 -16
  134. package/get-shit-done/workflows/review.md +228 -0
  135. package/get-shit-done/workflows/session-report.md +146 -0
  136. package/get-shit-done/workflows/set-profile.md +2 -2
  137. package/get-shit-done/workflows/settings.md +79 -10
  138. package/get-shit-done/workflows/ship.md +228 -0
  139. package/get-shit-done/workflows/stats.md +60 -0
  140. package/get-shit-done/workflows/transition.md +147 -20
  141. package/get-shit-done/workflows/ui-phase.md +302 -0
  142. package/get-shit-done/workflows/ui-review.md +165 -0
  143. package/get-shit-done/workflows/update.md +108 -25
  144. package/get-shit-done/workflows/validate-phase.md +15 -8
  145. package/get-shit-done/workflows/verify-phase.md +16 -5
  146. package/get-shit-done/workflows/verify-work.md +72 -18
  147. package/package.json +1 -1
  148. package/skills/gsd-audit-milestone/SKILL.md +29 -0
  149. package/skills/gsd-cleanup/SKILL.md +19 -0
  150. package/skills/gsd-complete-milestone/SKILL.md +131 -0
  151. package/skills/gsd-discuss-phase/SKILL.md +54 -0
  152. package/skills/gsd-execute-phase/SKILL.md +49 -0
  153. package/skills/gsd-plan-phase/SKILL.md +37 -0
  154. package/skills/gsd-ui-phase/SKILL.md +24 -0
  155. package/skills/gsd-ui-review/SKILL.md +24 -0
  156. package/skills/gsd-verify-work/SKILL.md +30 -0
@@ -1,23 +1,35 @@
1
- <purpose>
1
+ <objective>
2
2
  Execute small, ad-hoc tasks with GSD guarantees (atomic commits, STATE.md tracking). Quick mode spawns gsd-planner (quick mode) + gsd-executor(s), tracks tasks in `.planning/quick/`, and updates STATE.md's "Quick Tasks Completed" table.
3
3
 
4
4
  With `--discuss` flag: lightweight discussion phase before planning. Surfaces assumptions, clarifies gray areas, captures decisions in CONTEXT.md so the planner treats them as locked.
5
5
 
6
6
  With `--full` flag: enables plan-checking (max 2 iterations) and post-execution verification for quality guarantees without full milestone ceremony.
7
7
 
8
- Flags are composable: `--discuss --full` gives discussion + plan-checking + verification.
9
- </purpose>
8
+ With `--research` flag: spawns a focused research agent before planning. Investigates implementation approaches, library options, and pitfalls. Use when you're unsure how to approach a task.
9
+
10
+ Flags are composable: `--discuss --research --full` gives discussion + research + plan-checking + verification.
11
+ </objective>
10
12
 
11
13
  <required_reading>
12
14
  read all files referenced by the invoking prompt's execution_context before starting.
13
15
  </required_reading>
14
16
 
17
+ <available_agent_types>
18
+ Valid GSD subagent types (use exact names — do not fall back to 'general'):
19
+ - gsd-phase-researcher — Researches technical approaches for a phase
20
+ - gsd-planner — Creates detailed plans from phase scope
21
+ - gsd-plan-checker — Reviews plan quality before execution
22
+ - gsd-executor — Executes plan tasks, commits, creates SUMMARY.md
23
+ - gsd-verifier — Verifies phase completion, checks quality gates
24
+ </available_agent_types>
25
+
15
26
  <process>
16
27
  **Step 1: Parse arguments and get task description**
17
28
 
18
29
  Parse `$ARGUMENTS` for:
19
30
  - `--full` flag → store as `$FULL_MODE` (true/false)
20
31
  - `--discuss` flag → store as `$DISCUSS_MODE` (true/false)
32
+ - `--research` flag → store as `$RESEARCH_MODE` (true/false)
21
33
  - Remaining text → use as `$DESCRIPTION` if non-empty
22
34
 
23
35
  If `$DESCRIPTION` is empty after parsing, prompt user interactively:
@@ -36,7 +48,16 @@ If still empty, re-prompt: "Please provide a task description."
36
48
 
37
49
  Display banner based on active flags:
38
50
 
39
- If `$DISCUSS_MODE` and `$FULL_MODE`:
51
+ If `$DISCUSS_MODE` and `$RESEARCH_MODE` and `$FULL_MODE`:
52
+ ```
53
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
54
+ GSD ► QUICK TASK (DISCUSS + RESEARCH + FULL)
55
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
56
+
57
+ ◆ Discussion + research + plan checking + verification enabled
58
+ ```
59
+
60
+ If `$DISCUSS_MODE` and `$FULL_MODE` (no research):
40
61
  ```
41
62
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
42
63
  GSD ► QUICK TASK (DISCUSS + FULL)
@@ -45,6 +66,24 @@ If `$DISCUSS_MODE` and `$FULL_MODE`:
45
66
  ◆ Discussion + plan checking + verification enabled
46
67
  ```
47
68
 
69
+ If `$DISCUSS_MODE` and `$RESEARCH_MODE` (no full):
70
+ ```
71
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
72
+ GSD ► QUICK TASK (DISCUSS + RESEARCH)
73
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
74
+
75
+ ◆ Discussion + research enabled
76
+ ```
77
+
78
+ If `$RESEARCH_MODE` and `$FULL_MODE` (no discuss):
79
+ ```
80
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
81
+ GSD ► QUICK TASK (RESEARCH + FULL)
82
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
83
+
84
+ ◆ Research + plan checking + verification enabled
85
+ ```
86
+
48
87
  If `$DISCUSS_MODE` only:
49
88
  ```
50
89
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
@@ -54,6 +93,15 @@ If `$DISCUSS_MODE` only:
54
93
  ◆ Discussion phase enabled — surfacing gray areas before planning
55
94
  ```
56
95
 
96
+ If `$RESEARCH_MODE` only:
97
+ ```
98
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
99
+ GSD ► QUICK TASK (RESEARCH)
100
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
101
+
102
+ ◆ Research phase enabled — investigating approaches before planning
103
+ ```
104
+
57
105
  If `$FULL_MODE` only:
58
106
  ```
59
107
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
@@ -70,9 +118,13 @@ If `$FULL_MODE` only:
70
118
  ```bash
71
119
  INIT=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" init quick "$DESCRIPTION")
72
120
  if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
121
+ AGENT_SKILLS_PLANNER=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" agent-skills gsd-planner 2>/dev/null)
122
+ AGENT_SKILLS_EXECUTOR=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" agent-skills gsd-executor 2>/dev/null)
123
+ AGENT_SKILLS_CHECKER=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" agent-skills gsd-checker 2>/dev/null)
124
+ AGENT_SKILLS_VERIFIER=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" agent-skills gsd-verifier 2>/dev/null)
73
125
  ```
74
126
 
75
- Parse JSON for: `planner_model`, `executor_model`, `checker_model`, `verifier_model`, `commit_docs`, `next_num`, `slug`, `date`, `timestamp`, `quick_dir`, `task_dir`, `roadmap_exists`, `planning_exists`.
127
+ Parse JSON for: `planner_model`, `executor_model`, `checker_model`, `verifier_model`, `commit_docs`, `branch_name`, `quick_id`, `slug`, `date`, `timestamp`, `quick_dir`, `task_dir`, `roadmap_exists`, `planning_exists`.
76
128
 
77
129
  **If `roadmap_exists` is false:** Error — Quick mode requires an active project with ROADMAP.md. Run `/gsd-new-project` first.
78
130
 
@@ -80,6 +132,20 @@ Quick tasks can run mid-phase - validation only checks ROADMAP.md exists, not ph
80
132
 
81
133
  ---
82
134
 
135
+ **Step 2.5: Handle quick-task branching**
136
+
137
+ **If `branch_name` is empty/null:** Skip and continue on the current branch.
138
+
139
+ **If `branch_name` is set:** Check out the quick-task branch before any planning commits:
140
+
141
+ ```bash
142
+ git checkout -b "$branch_name" 2>/dev/null || git checkout "$branch_name"
143
+ ```
144
+
145
+ All quick-task commits for this run stay on that branch. User handles merge/rebase afterward.
146
+
147
+ ---
148
+
83
149
  **Step 3: Create task directory**
84
150
 
85
151
  ```bash
@@ -93,13 +159,13 @@ mkdir -p "${task_dir}"
93
159
  Create the directory for this quick task:
94
160
 
95
161
  ```bash
96
- QUICK_DIR=".planning/quick/${next_num}-${slug}"
162
+ QUICK_DIR=".planning/quick/${quick_id}-${slug}"
97
163
  mkdir -p "$QUICK_DIR"
98
164
  ```
99
165
 
100
166
  Report to user:
101
167
  ```
102
- Creating quick task ${next_num}: ${DESCRIPTION}
168
+ Creating quick task ${quick_id}: ${DESCRIPTION}
103
169
  Directory: ${QUICK_DIR}
104
170
  ```
105
171
 
@@ -180,10 +246,10 @@ Collect all decisions into `$DECISIONS`.
180
246
 
181
247
  **4.5d. write CONTEXT.md**
182
248
 
183
- write `${QUICK_DIR}/${next_num}-CONTEXT.md` using the standard context template structure:
249
+ write `${QUICK_DIR}/${quick_id}-CONTEXT.md` using the standard context template structure:
184
250
 
185
251
  ```markdown
186
- # Quick task ${next_num}: ${DESCRIPTION} - Context
252
+ # Quick task ${quick_id}: ${DESCRIPTION} - Context
187
253
 
188
254
  **Gathered:** ${date}
189
255
  **Status:** Ready for planning
@@ -217,11 +283,85 @@ ${any_specific_references_or_examples_from_discussion}
217
283
  [If none: "No specific requirements — open to standard approaches"]
218
284
 
219
285
  </specifics>
286
+
287
+ <canonical_refs>
288
+ ## Canonical References
289
+
290
+ ${any_specs_adrs_or_docs_referenced_during_discussion}
291
+
292
+ [If none: "No external specs — requirements fully captured in decisions above"]
293
+
294
+ </canonical_refs>
220
295
  ```
221
296
 
222
- Note: Quick task CONTEXT.md omits `<code_context>` and `<deferred>` sections (no codebase scouting, no phase scope to defer to). Keep it lean.
297
+ Note: Quick task CONTEXT.md omits `<code_context>` and `<deferred>` sections (no codebase scouting, no phase scope to defer to). Keep it lean. The `<canonical_refs>` section is included when external docs were referenced — omit it only if no external docs apply.
223
298
 
224
- Report: `Context captured: ${QUICK_DIR}/${next_num}-CONTEXT.md`
299
+ Report: `Context captured: ${QUICK_DIR}/${quick_id}-CONTEXT.md`
300
+
301
+ ---
302
+
303
+ **Step 4.75: Research phase (only when `$RESEARCH_MODE`)**
304
+
305
+ Skip this step entirely if NOT `$RESEARCH_MODE`.
306
+
307
+ Display banner:
308
+ ```
309
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
310
+ GSD ► RESEARCHING QUICK TASK
311
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
312
+
313
+ ◆ Investigating approaches for: ${DESCRIPTION}
314
+ ```
315
+
316
+ Spawn a single focused researcher (not 4 parallel researchers like full phases — quick tasks need targeted research, not broad domain surveys):
317
+
318
+ ```
319
+ task(
320
+ prompt="
321
+ <research_context>
322
+
323
+ **Mode:** quick-task
324
+ **task:** ${DESCRIPTION}
325
+ **Output:** ${QUICK_DIR}/${quick_id}-RESEARCH.md
326
+
327
+ <files_to_read>
328
+ - .planning/STATE.md (Project state — what's already built)
329
+ - .planning/PROJECT.md (Project context)
330
+ - ./AGENTS.md (if exists — project-specific guidelines)
331
+ ${DISCUSS_MODE ? '- ' + QUICK_DIR + '/' + quick_id + '-CONTEXT.md (User decisions — research should align with these)' : ''}
332
+ </files_to_read>
333
+
334
+ ${AGENT_SKILLS_PLANNER}
335
+
336
+ </research_context>
337
+
338
+ <focus>
339
+ This is a quick task, not a full phase. Research should be concise and targeted:
340
+ 1. Best libraries/patterns for this specific task
341
+ 2. Common pitfalls and how to avoid them
342
+ 3. Integration points with existing codebase
343
+ 4. Any constraints or gotchas worth knowing before planning
344
+
345
+ Do NOT produce a full domain survey. Target 1-2 pages of actionable findings.
346
+ </focus>
347
+
348
+ <output>
349
+ write research to: ${QUICK_DIR}/${quick_id}-RESEARCH.md
350
+ Use standard research format but keep it lean — skip sections that don't apply.
351
+ Return: ## RESEARCH COMPLETE with file path
352
+ </output>
353
+ ",
354
+ subagent_type="gsd-phase-researcher",
355
+ model="{planner_model}",
356
+ description="Research: ${DESCRIPTION}"
357
+ )
358
+ ```
359
+
360
+ After researcher returns:
361
+ 1. Verify research exists at `${QUICK_DIR}/${quick_id}-RESEARCH.md`
362
+ 2. Report: "Research complete: ${QUICK_DIR}/${quick_id}-RESEARCH.md"
363
+
364
+ If research file not found, warn but continue: "Research agent did not produce output — proceeding to planning without research."
225
365
 
226
366
  ---
227
367
 
@@ -243,9 +383,12 @@ task(
243
383
  <files_to_read>
244
384
  - .planning/STATE.md (Project State)
245
385
  - ./AGENTS.md (if exists — follow project-specific guidelines)
246
- ${DISCUSS_MODE ? '- ' + QUICK_DIR + '/' + next_num + '-CONTEXT.md (User decisions — locked, do not revisit)' : ''}
386
+ ${DISCUSS_MODE ? '- ' + QUICK_DIR + '/' + quick_id + '-CONTEXT.md (User decisions — locked, do not revisit)' : ''}
387
+ ${RESEARCH_MODE ? '- ' + QUICK_DIR + '/' + quick_id + '-RESEARCH.md (Research findings — use to inform implementation choices)' : ''}
247
388
  </files_to_read>
248
389
 
390
+ ${AGENT_SKILLS_PLANNER}
391
+
249
392
  **Project skills:** Check .OpenCode/skills/ or .agents/skills/ directory (if either exists) — read SKILL.md files, plans should account for project skill rules
250
393
 
251
394
  </planning_context>
@@ -253,14 +396,14 @@ ${DISCUSS_MODE ? '- ' + QUICK_DIR + '/' + next_num + '-CONTEXT.md (User decision
253
396
  <constraints>
254
397
  - Create a SINGLE plan with 1-3 focused tasks
255
398
  - Quick tasks should be atomic and self-contained
256
- - No research phase
399
+ ${RESEARCH_MODE ? '- Research findings are available — use them to inform library/pattern choices' : '- No research phase'}
257
400
  ${FULL_MODE ? '- Target ~40% context usage (structured for verification)' : '- Target ~30% context usage (simple, focused)'}
258
401
  ${FULL_MODE ? '- MUST generate `must_haves` in plan frontmatter (truths, artifacts, key_links)' : ''}
259
402
  ${FULL_MODE ? '- Each task MUST have `files`, `action`, `verify`, `done` fields' : ''}
260
403
  </constraints>
261
404
 
262
405
  <output>
263
- write plan to: ${QUICK_DIR}/${next_num}-PLAN.md
406
+ write plan to: ${QUICK_DIR}/${quick_id}-PLAN.md
264
407
  Return: ## PLANNING COMPLETE with plan path
265
408
  </output>
266
409
  ",
@@ -271,11 +414,11 @@ Return: ## PLANNING COMPLETE with plan path
271
414
  ```
272
415
 
273
416
  After planner returns:
274
- 1. Verify plan exists at `${QUICK_DIR}/${next_num}-PLAN.md`
417
+ 1. Verify plan exists at `${QUICK_DIR}/${quick_id}-PLAN.md`
275
418
  2. Extract plan count (typically 1 for quick tasks)
276
- 3. Report: "Plan created: ${QUICK_DIR}/${next_num}-PLAN.md"
419
+ 3. Report: "Plan created: ${QUICK_DIR}/${quick_id}-PLAN.md"
277
420
 
278
- If plan not found, error: "Planner failed to create ${next_num}-PLAN.md"
421
+ If plan not found, error: "Planner failed to create ${quick_id}-PLAN.md"
279
422
 
280
423
  ---
281
424
 
@@ -300,9 +443,11 @@ Checker prompt:
300
443
  **task Description:** ${DESCRIPTION}
301
444
 
302
445
  <files_to_read>
303
- - ${QUICK_DIR}/${next_num}-PLAN.md (Plan to verify)
446
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Plan to verify)
304
447
  </files_to_read>
305
448
 
449
+ ${AGENT_SKILLS_CHECKER}
450
+
306
451
  **Scope:** This is a quick task, not a full phase. Skip checks that require a ROADMAP phase goal.
307
452
  </verification_context>
308
453
 
@@ -352,9 +497,11 @@ Revision prompt:
352
497
  **Mode:** quick-full (revision)
353
498
 
354
499
  <files_to_read>
355
- - ${QUICK_DIR}/${next_num}-PLAN.md (Existing plan)
500
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Existing plan)
356
501
  </files_to_read>
357
502
 
503
+ ${AGENT_SKILLS_PLANNER}
504
+
358
505
  **Checker issues:** ${structured_issues_from_checker}
359
506
 
360
507
  </revision_context>
@@ -392,36 +539,39 @@ Spawn gsd-executor with plan reference:
392
539
  ```
393
540
  task(
394
541
  prompt="
395
- Execute quick task ${next_num}.
542
+ Execute quick task ${quick_id}.
396
543
 
397
544
  <files_to_read>
398
- - ${QUICK_DIR}/${next_num}-PLAN.md (Plan)
545
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Plan)
399
546
  - .planning/STATE.md (Project state)
400
547
  - ./AGENTS.md (Project instructions, if exists)
401
548
  - .OpenCode/skills/ or .agents/skills/ (Project skills, if either exists — list skills, read SKILL.md for each, follow relevant rules during implementation)
402
549
  </files_to_read>
403
550
 
551
+ ${AGENT_SKILLS_EXECUTOR}
552
+
404
553
  <constraints>
405
554
  - Execute all tasks in the plan
406
555
  - Commit each task atomically
407
- - Create summary at: ${QUICK_DIR}/${next_num}-SUMMARY.md
556
+ - Create summary at: ${QUICK_DIR}/${quick_id}-SUMMARY.md
408
557
  - Do NOT update ROADMAP.md (quick tasks are separate from planned phases)
409
558
  </constraints>
410
559
  ",
411
560
  subagent_type="gsd-executor",
412
561
  model="{executor_model}",
562
+ isolation="worktree",
413
563
  description="Execute: ${DESCRIPTION}"
414
564
  )
415
565
  ```
416
566
 
417
567
  After executor returns:
418
- 1. Verify summary exists at `${QUICK_DIR}/${next_num}-SUMMARY.md`
568
+ 1. Verify summary exists at `${QUICK_DIR}/${quick_id}-SUMMARY.md`
419
569
  2. Extract commit hash from executor output
420
570
  3. Report completion status
421
571
 
422
572
  **Known OpenCode bug (classifyHandoffIfNeeded):** If executor reports "failed" with error `classifyHandoffIfNeeded is not defined`, this is a OpenCode runtime bug — not a real failure. Check if summary file exists and git log shows commits. If so, treat as successful.
423
573
 
424
- If summary not found, error: "Executor failed to create ${next_num}-SUMMARY.md"
574
+ If summary not found, error: "Executor failed to create ${quick_id}-SUMMARY.md"
425
575
 
426
576
  Note: For quick tasks producing multiple plans (rare), spawn executors in parallel waves per execute-phase patterns.
427
577
 
@@ -447,10 +597,12 @@ task directory: ${QUICK_DIR}
447
597
  task goal: ${DESCRIPTION}
448
598
 
449
599
  <files_to_read>
450
- - ${QUICK_DIR}/${next_num}-PLAN.md (Plan)
600
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Plan)
451
601
  </files_to_read>
452
602
 
453
- Check must_haves against actual codebase. Create VERIFICATION.md at ${QUICK_DIR}/${next_num}-VERIFICATION.md.",
603
+ ${AGENT_SKILLS_VERIFIER}
604
+
605
+ Check must_haves against actual codebase. Create VERIFICATION.md at ${QUICK_DIR}/${quick_id}-VERIFICATION.md.",
454
606
  subagent_type="gsd-verifier",
455
607
  model="{verifier_model}",
456
608
  description="Verify: ${DESCRIPTION}"
@@ -459,7 +611,7 @@ Check must_haves against actual codebase. Create VERIFICATION.md at ${QUICK_DIR}
459
611
 
460
612
  read verification status:
461
613
  ```bash
462
- grep "^status:" "${QUICK_DIR}/${next_num}-VERIFICATION.md" | cut -d: -f2 | tr -d ' '
614
+ grep "^status:" "${QUICK_DIR}/${quick_id}-VERIFICATION.md" | cut -d: -f2 | tr -d ' '
463
615
  ```
464
616
 
465
617
  Store as `$VERIFICATION_STATUS`.
@@ -508,19 +660,19 @@ Use `date` from init:
508
660
 
509
661
  **If `$FULL_MODE` (or table has Status column):**
510
662
  ```markdown
511
- | ${next_num} | ${DESCRIPTION} | ${date} | ${commit_hash} | ${VERIFICATION_STATUS} | [${next_num}-${slug}](./quick/${next_num}-${slug}/) |
663
+ | ${quick_id} | ${DESCRIPTION} | ${date} | ${commit_hash} | ${VERIFICATION_STATUS} | [${quick_id}-${slug}](./quick/${quick_id}-${slug}/) |
512
664
  ```
513
665
 
514
666
  **If NOT `$FULL_MODE` (and table has no Status column):**
515
667
  ```markdown
516
- | ${next_num} | ${DESCRIPTION} | ${date} | ${commit_hash} | [${next_num}-${slug}](./quick/${next_num}-${slug}/) |
668
+ | ${quick_id} | ${DESCRIPTION} | ${date} | ${commit_hash} | [${quick_id}-${slug}](./quick/${quick_id}-${slug}/) |
517
669
  ```
518
670
 
519
671
  **7d. Update "Last activity" line:**
520
672
 
521
673
  Use `date` from init:
522
674
  ```
523
- Last activity: ${date} - Completed quick task ${next_num}: ${DESCRIPTION}
675
+ Last activity: ${date} - Completed quick task ${quick_id}: ${DESCRIPTION}
524
676
  ```
525
677
 
526
678
  Use edit tool to make these changes atomically
@@ -532,14 +684,15 @@ Use edit tool to make these changes atomically
532
684
  Stage and commit quick task artifacts:
533
685
 
534
686
  Build file list:
535
- - `${QUICK_DIR}/${next_num}-PLAN.md`
536
- - `${QUICK_DIR}/${next_num}-SUMMARY.md`
687
+ - `${QUICK_DIR}/${quick_id}-PLAN.md`
688
+ - `${QUICK_DIR}/${quick_id}-SUMMARY.md`
537
689
  - `.planning/STATE.md`
538
- - If `$DISCUSS_MODE` and context file exists: `${QUICK_DIR}/${next_num}-CONTEXT.md`
539
- - If `$FULL_MODE` and verification file exists: `${QUICK_DIR}/${next_num}-VERIFICATION.md`
690
+ - If `$DISCUSS_MODE` and context file exists: `${QUICK_DIR}/${quick_id}-CONTEXT.md`
691
+ - If `$RESEARCH_MODE` and research file exists: `${QUICK_DIR}/${quick_id}-RESEARCH.md`
692
+ - If `$FULL_MODE` and verification file exists: `${QUICK_DIR}/${quick_id}-VERIFICATION.md`
540
693
 
541
694
  ```bash
542
- node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" commit "docs(quick-${next_num}): ${DESCRIPTION}" --files ${file_list}
695
+ node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" commit "docs(quick-${quick_id}): ${DESCRIPTION}" --files ${file_list}
543
696
  ```
544
697
 
545
698
  Get final commit hash:
@@ -555,15 +708,16 @@ Display completion output:
555
708
 
556
709
  GSD > QUICK TASK COMPLETE (FULL MODE)
557
710
 
558
- Quick task ${next_num}: ${DESCRIPTION}
711
+ Quick task ${quick_id}: ${DESCRIPTION}
559
712
 
560
- Summary: ${QUICK_DIR}/${next_num}-SUMMARY.md
561
- Verification: ${QUICK_DIR}/${next_num}-VERIFICATION.md (${VERIFICATION_STATUS})
713
+ ${RESEARCH_MODE ? 'Research: ' + QUICK_DIR + '/' + quick_id + '-RESEARCH.md' : ''}
714
+ Summary: ${QUICK_DIR}/${quick_id}-SUMMARY.md
715
+ Verification: ${QUICK_DIR}/${quick_id}-VERIFICATION.md (${VERIFICATION_STATUS})
562
716
  Commit: ${commit_hash}
563
717
 
564
718
  ---
565
719
 
566
- Ready for next task: /gsd-quick
720
+ Ready for next task: /gsd-quick ${GSD_WS}
567
721
  ```
568
722
 
569
723
  **If NOT `$FULL_MODE`:**
@@ -572,14 +726,15 @@ Ready for next task: /gsd-quick
572
726
 
573
727
  GSD > QUICK TASK COMPLETE
574
728
 
575
- Quick task ${next_num}: ${DESCRIPTION}
729
+ Quick task ${quick_id}: ${DESCRIPTION}
576
730
 
577
- Summary: ${QUICK_DIR}/${next_num}-SUMMARY.md
731
+ ${RESEARCH_MODE ? 'Research: ' + QUICK_DIR + '/' + quick_id + '-RESEARCH.md' : ''}
732
+ Summary: ${QUICK_DIR}/${quick_id}-SUMMARY.md
578
733
  Commit: ${commit_hash}
579
734
 
580
735
  ---
581
736
 
582
- Ready for next task: /gsd-quick
737
+ Ready for next task: /gsd-quick ${GSD_WS}
583
738
  ```
584
739
 
585
740
  </process>
@@ -587,15 +742,16 @@ Ready for next task: /gsd-quick
587
742
  <success_criteria>
588
743
  - [ ] ROADMAP.md validation passes
589
744
  - [ ] User provides task description
590
- - [ ] `--full` and `--discuss` flags parsed from arguments when present
745
+ - [ ] `--full`, `--discuss`, and `--research` flags parsed from arguments when present
591
746
  - [ ] Slug generated (lowercase, hyphens, max 40 chars)
592
- - [ ] Next number calculated (001, 002, 003...)
593
- - [ ] Directory created at `.planning/quick/NNN-slug/`
594
- - [ ] (--discuss) Gray areas identified and presented, decisions captured in `${next_num}-CONTEXT.md`
595
- - [ ] `${next_num}-PLAN.md` created by planner (honors CONTEXT.md decisions when --discuss)
747
+ - [ ] Quick ID generated (YYMMDD-xxx format, 2s Base36 precision)
748
+ - [ ] Directory created at `.planning/quick/YYMMDD-xxx-slug/`
749
+ - [ ] (--discuss) Gray areas identified and presented, decisions captured in `${quick_id}-CONTEXT.md`
750
+ - [ ] (--research) Research agent spawned, `${quick_id}-RESEARCH.md` created
751
+ - [ ] `${quick_id}-PLAN.md` created by planner (honors CONTEXT.md decisions when --discuss, uses RESEARCH.md findings when --research)
596
752
  - [ ] (--full) Plan checker validates plan, revision loop capped at 2
597
- - [ ] `${next_num}-SUMMARY.md` created by executor
598
- - [ ] (--full) `${next_num}-VERIFICATION.md` created by verifier
753
+ - [ ] `${quick_id}-SUMMARY.md` created by executor
754
+ - [ ] (--full) `${quick_id}-VERIFICATION.md` created by verifier
599
755
  - [ ] STATE.md updated with quick task row (Status column when --full)
600
756
  - [ ] Artifacts committed
601
757
  </success_criteria>
@@ -1,6 +1,6 @@
1
- <purpose>
1
+ <objective>
2
2
  Remove an unstarted future phase from the project roadmap, delete its directory, renumber all subsequent phases to maintain a clean linear sequence, and commit the change. The git commit serves as the historical record of removal.
3
- </purpose>
3
+ </objective>
4
4
 
5
5
  <required_reading>
6
6
  read all files referenced by the invoking prompt's execution_context before starting.
@@ -0,0 +1,90 @@
1
+ <objective>
2
+ Remove a GSD workspace, cleaning up git worktrees and deleting the workspace directory.
3
+ </objective>
4
+
5
+ <required_reading>
6
+ read all files referenced by the invoking prompt's execution_context before starting.
7
+ </required_reading>
8
+
9
+ <process>
10
+
11
+ ## 1. Setup
12
+
13
+ Extract workspace name from $ARGUMENTS.
14
+
15
+ ```bash
16
+ INIT=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" init remove-workspace "$WORKSPACE_NAME")
17
+ if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
18
+ ```
19
+
20
+ Parse JSON for: `workspace_name`, `workspace_path`, `has_manifest`, `strategy`, `repos`, `repo_count`, `dirty_repos`, `has_dirty_repos`.
21
+
22
+ **If no workspace name provided:**
23
+
24
+ First run `/gsd-list-workspaces` to show available workspaces, then ask:
25
+
26
+ Use question:
27
+ - header: "Remove Workspace"
28
+ - question: "Which workspace do you want to remove?"
29
+ - requireAnswer: true
30
+
31
+ Re-run init with the provided name.
32
+
33
+ ## 2. Safety Checks
34
+
35
+ **If `has_dirty_repos` is true:**
36
+
37
+ ```
38
+ Cannot remove workspace "$WORKSPACE_NAME" — the following repos have uncommitted changes:
39
+
40
+ - repo1
41
+ - repo2
42
+
43
+ Commit or stash changes in these repos before removing the workspace:
44
+ cd $WORKSPACE_PATH/repo1
45
+ git stash # or git commit
46
+ ```
47
+
48
+ Exit. Do NOT proceed.
49
+
50
+ ## 3. Confirm Removal
51
+
52
+ Use question:
53
+ - header: "Confirm Removal"
54
+ - question: "Remove workspace '$WORKSPACE_NAME' at $WORKSPACE_PATH? This will delete all files in the workspace directory. Type the workspace name to confirm:"
55
+ - requireAnswer: true
56
+
57
+ **If answer does not match `$WORKSPACE_NAME`:** Exit with "Removal cancelled."
58
+
59
+ ## 4. Clean Up Worktrees
60
+
61
+ **If strategy is `worktree`:**
62
+
63
+ For each repo in the workspace:
64
+
65
+ ```bash
66
+ cd "$SOURCE_REPO_PATH"
67
+ git worktree remove "$WORKSPACE_PATH/$REPO_NAME" 2>&1 || true
68
+ ```
69
+
70
+ If `git worktree remove` fails, warn but continue:
71
+ ```
72
+ Warning: Could not remove worktree for $REPO_NAME — source repo may have been moved or deleted.
73
+ ```
74
+
75
+ ## 5. Delete Workspace Directory
76
+
77
+ ```bash
78
+ rm -rf "$WORKSPACE_PATH"
79
+ ```
80
+
81
+ ## 6. Report
82
+
83
+ ```
84
+ Workspace "$WORKSPACE_NAME" removed.
85
+
86
+ Path: $WORKSPACE_PATH (deleted)
87
+ Repos: $REPO_COUNT worktrees cleaned up
88
+ ```
89
+
90
+ </process>
@@ -1,8 +1,13 @@
1
- <purpose>
1
+ <objective>
2
2
  Research how to implement a phase. Spawns gsd-phase-researcher with phase context.
3
3
 
4
4
  Standalone research command. For most workflows, use `/gsd-plan-phase` which integrates research automatically.
5
- </purpose>
5
+ </objective>
6
+
7
+ <available_agent_types>
8
+ Valid GSD subagent types (use exact names — do not fall back to 'general'):
9
+ - gsd-phase-researcher — Researches technical approaches for a phase
10
+ </available_agent_types>
6
11
 
7
12
  <process>
8
13
 
@@ -26,7 +31,7 @@ If `found` is false: Error and exit.
26
31
  ## Step 2: Check Existing Research
27
32
 
28
33
  ```bash
29
- ls .planning/phases/${PHASE}-*/RESEARCH.md 2>/dev/null
34
+ ls .planning/phases/${PHASE}-*/RESEARCH.md 2>/dev/null || true
30
35
  ```
31
36
 
32
37
  If exists: Offer update/view/skip options.
@@ -37,6 +42,7 @@ If exists: Offer update/view/skip options.
37
42
  INIT=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" init phase-op "${PHASE}")
38
43
  if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
39
44
  # Extract: phase_dir, padded_phase, phase_number, state_path, requirements_path, context_path
45
+ AGENT_SKILLS_RESEARCHER=$(node "$HOME/.config/opencode/get-shit-done/bin/gsd-tools.cjs" agent-skills gsd-researcher 2>/dev/null)
40
46
  ```
41
47
 
42
48
  ## Step 4: Spawn Researcher
@@ -53,6 +59,8 @@ Research implementation approach for Phase {phase}: {name}
53
59
  - {state_path} (Project decisions and history)
54
60
  </files_to_read>
55
61
 
62
+ ${AGENT_SKILLS_RESEARCHER}
63
+
56
64
  <additional_context>
57
65
  Phase description: {description}
58
66
  </additional_context>