@ktpartners/dgs-platform 2.6.2

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 (256) hide show
  1. package/LICENSE +38 -0
  2. package/README.md +851 -0
  3. package/agents/dgs-codebase-cross-analyzer.md +183 -0
  4. package/agents/dgs-codebase-mapper.md +782 -0
  5. package/agents/dgs-codebase-synthesizer.md +156 -0
  6. package/agents/dgs-debugger.md +1256 -0
  7. package/agents/dgs-executor.md +550 -0
  8. package/agents/dgs-integration-checker.md +481 -0
  9. package/agents/dgs-nyquist-auditor.md +178 -0
  10. package/agents/dgs-phase-researcher.md +563 -0
  11. package/agents/dgs-phase-verifier.md +450 -0
  12. package/agents/dgs-plan-checker.md +708 -0
  13. package/agents/dgs-planner.md +1324 -0
  14. package/agents/dgs-project-researcher.md +631 -0
  15. package/agents/dgs-research-synthesizer.md +249 -0
  16. package/agents/dgs-roadmapper.md +652 -0
  17. package/agents/dgs-verifier.md +607 -0
  18. package/bin/install.js +2073 -0
  19. package/commands/dgs/add-doc.md +45 -0
  20. package/commands/dgs/add-idea.md +38 -0
  21. package/commands/dgs/add-phase.md +43 -0
  22. package/commands/dgs/add-repo.md +54 -0
  23. package/commands/dgs/add-tests.md +41 -0
  24. package/commands/dgs/add-todo.md +47 -0
  25. package/commands/dgs/approve-spec.md +38 -0
  26. package/commands/dgs/audit-milestone.md +36 -0
  27. package/commands/dgs/audit-phase.md +37 -0
  28. package/commands/dgs/cancel-job.md +23 -0
  29. package/commands/dgs/capture-principle.md +143 -0
  30. package/commands/dgs/check-todos.md +45 -0
  31. package/commands/dgs/cleanup.md +18 -0
  32. package/commands/dgs/complete-milestone.md +136 -0
  33. package/commands/dgs/complete-project.md +70 -0
  34. package/commands/dgs/consolidate-ideas.md +50 -0
  35. package/commands/dgs/create-milestone-job.md +37 -0
  36. package/commands/dgs/debug.md +164 -0
  37. package/commands/dgs/develop-idea.md +53 -0
  38. package/commands/dgs/discuss-idea.md +41 -0
  39. package/commands/dgs/discuss-phase.md +83 -0
  40. package/commands/dgs/execute-phase.md +41 -0
  41. package/commands/dgs/fast.md +38 -0
  42. package/commands/dgs/find-related-ideas.md +43 -0
  43. package/commands/dgs/health.md +28 -0
  44. package/commands/dgs/help.md +22 -0
  45. package/commands/dgs/import-spec.md +36 -0
  46. package/commands/dgs/init-product.md +28 -0
  47. package/commands/dgs/insert-phase.md +32 -0
  48. package/commands/dgs/join-discord.md +18 -0
  49. package/commands/dgs/list-docs.md +40 -0
  50. package/commands/dgs/list-ideas.md +42 -0
  51. package/commands/dgs/list-jobs.md +22 -0
  52. package/commands/dgs/list-phase-assumptions.md +46 -0
  53. package/commands/dgs/list-projects.md +57 -0
  54. package/commands/dgs/list-specs.md +40 -0
  55. package/commands/dgs/map-codebase.md +92 -0
  56. package/commands/dgs/new-milestone.md +44 -0
  57. package/commands/dgs/new-project.md +42 -0
  58. package/commands/dgs/node-repair.md +26 -0
  59. package/commands/dgs/overlap-check.md +20 -0
  60. package/commands/dgs/pause-work.md +38 -0
  61. package/commands/dgs/plan-milestone-gaps.md +34 -0
  62. package/commands/dgs/plan-phase.md +44 -0
  63. package/commands/dgs/progress.md +24 -0
  64. package/commands/dgs/quick.md +41 -0
  65. package/commands/dgs/reactivate-project.md +70 -0
  66. package/commands/dgs/reapply-patches.md +110 -0
  67. package/commands/dgs/refine-spec.md +38 -0
  68. package/commands/dgs/reject-idea.md +43 -0
  69. package/commands/dgs/remove-doc.md +44 -0
  70. package/commands/dgs/remove-phase.md +31 -0
  71. package/commands/dgs/remove-repo.md +69 -0
  72. package/commands/dgs/research-idea.md +43 -0
  73. package/commands/dgs/research-phase.md +189 -0
  74. package/commands/dgs/restore-idea.md +45 -0
  75. package/commands/dgs/resume-work.md +40 -0
  76. package/commands/dgs/rollback-job.md +24 -0
  77. package/commands/dgs/run-job.md +35 -0
  78. package/commands/dgs/search.md +40 -0
  79. package/commands/dgs/set-profile.md +34 -0
  80. package/commands/dgs/settings.md +38 -0
  81. package/commands/dgs/switch-project.md +58 -0
  82. package/commands/dgs/undo-consolidation.md +42 -0
  83. package/commands/dgs/update-idea.md +44 -0
  84. package/commands/dgs/update.md +37 -0
  85. package/commands/dgs/validate-phase.md +35 -0
  86. package/commands/dgs/verify-work.md +39 -0
  87. package/commands/dgs/write-spec.md +49 -0
  88. package/deliver-great-systems/.planning/phases/09-backend-wiring-and-error-handling/09-01-SUMMARY.md +84 -0
  89. package/deliver-great-systems/.planning/phases/09-backend-wiring-and-error-handling/09-02-SUMMARY.md +86 -0
  90. package/deliver-great-systems/.planning/phases/10-v1-to-v2-migration-flow/10-01-SUMMARY.md +85 -0
  91. package/deliver-great-systems/bin/dgs-tools.cjs +1444 -0
  92. package/deliver-great-systems/bin/lib/auto-test.cjs +1365 -0
  93. package/deliver-great-systems/bin/lib/commands.cjs +570 -0
  94. package/deliver-great-systems/bin/lib/config.cjs +417 -0
  95. package/deliver-great-systems/bin/lib/conflict-agent.cjs +1063 -0
  96. package/deliver-great-systems/bin/lib/conflict-agent.test.cjs +554 -0
  97. package/deliver-great-systems/bin/lib/context.cjs +929 -0
  98. package/deliver-great-systems/bin/lib/context.test.cjs +693 -0
  99. package/deliver-great-systems/bin/lib/core.cjs +744 -0
  100. package/deliver-great-systems/bin/lib/core.test.cjs +822 -0
  101. package/deliver-great-systems/bin/lib/docs.cjs +919 -0
  102. package/deliver-great-systems/bin/lib/docs.test.cjs +211 -0
  103. package/deliver-great-systems/bin/lib/execution.cjs +705 -0
  104. package/deliver-great-systems/bin/lib/execution.test.cjs +1472 -0
  105. package/deliver-great-systems/bin/lib/frontmatter.cjs +324 -0
  106. package/deliver-great-systems/bin/lib/ideas.cjs +1406 -0
  107. package/deliver-great-systems/bin/lib/ideas.test.cjs +1417 -0
  108. package/deliver-great-systems/bin/lib/identity.cjs +125 -0
  109. package/deliver-great-systems/bin/lib/init.cjs +1114 -0
  110. package/deliver-great-systems/bin/lib/init.test.cjs +1271 -0
  111. package/deliver-great-systems/bin/lib/jobs.cjs +2015 -0
  112. package/deliver-great-systems/bin/lib/jobs.test.cjs +2619 -0
  113. package/deliver-great-systems/bin/lib/merge-conflicts.cjs +654 -0
  114. package/deliver-great-systems/bin/lib/merge-conflicts.test.cjs +370 -0
  115. package/deliver-great-systems/bin/lib/migration.cjs +352 -0
  116. package/deliver-great-systems/bin/lib/migration.test.cjs +582 -0
  117. package/deliver-great-systems/bin/lib/milestone.cjs +243 -0
  118. package/deliver-great-systems/bin/lib/overlap.cjs +437 -0
  119. package/deliver-great-systems/bin/lib/overlap.test.cjs +747 -0
  120. package/deliver-great-systems/bin/lib/path-audit.test.cjs +384 -0
  121. package/deliver-great-systems/bin/lib/paths.cjs +144 -0
  122. package/deliver-great-systems/bin/lib/paths.test.cjs +486 -0
  123. package/deliver-great-systems/bin/lib/phase.cjs +910 -0
  124. package/deliver-great-systems/bin/lib/projects.cjs +691 -0
  125. package/deliver-great-systems/bin/lib/projects.test.cjs +871 -0
  126. package/deliver-great-systems/bin/lib/repos.cjs +1432 -0
  127. package/deliver-great-systems/bin/lib/repos.test.cjs +1882 -0
  128. package/deliver-great-systems/bin/lib/roadmap.cjs +305 -0
  129. package/deliver-great-systems/bin/lib/search.cjs +570 -0
  130. package/deliver-great-systems/bin/lib/specs.cjs +1303 -0
  131. package/deliver-great-systems/bin/lib/state.cjs +893 -0
  132. package/deliver-great-systems/bin/lib/template.cjs +228 -0
  133. package/deliver-great-systems/bin/lib/test-helpers.cjs +291 -0
  134. package/deliver-great-systems/bin/lib/verify.cjs +796 -0
  135. package/deliver-great-systems/references/checkpoints.md +776 -0
  136. package/deliver-great-systems/references/conflict-resolution.md +66 -0
  137. package/deliver-great-systems/references/context-tiers.md +166 -0
  138. package/deliver-great-systems/references/continuation-format.md +249 -0
  139. package/deliver-great-systems/references/decimal-phase-calculation.md +67 -0
  140. package/deliver-great-systems/references/git-integration.md +250 -0
  141. package/deliver-great-systems/references/git-planning-commit.md +40 -0
  142. package/deliver-great-systems/references/model-profile-resolution.md +36 -0
  143. package/deliver-great-systems/references/model-profiles.md +95 -0
  144. package/deliver-great-systems/references/phase-argument-parsing.md +61 -0
  145. package/deliver-great-systems/references/planning-config.md +224 -0
  146. package/deliver-great-systems/references/questioning.md +162 -0
  147. package/deliver-great-systems/references/spec-review-loop.md +177 -0
  148. package/deliver-great-systems/references/tdd.md +265 -0
  149. package/deliver-great-systems/references/ui-brand.md +160 -0
  150. package/deliver-great-systems/references/verification-patterns.md +612 -0
  151. package/deliver-great-systems/templates/DEBUG.md +166 -0
  152. package/deliver-great-systems/templates/UAT.md +251 -0
  153. package/deliver-great-systems/templates/VALIDATION.md +95 -0
  154. package/deliver-great-systems/templates/claude-md.md +74 -0
  155. package/deliver-great-systems/templates/codebase/architecture.md +257 -0
  156. package/deliver-great-systems/templates/codebase/concerns.md +312 -0
  157. package/deliver-great-systems/templates/codebase/conventions.md +309 -0
  158. package/deliver-great-systems/templates/codebase/integrations.md +282 -0
  159. package/deliver-great-systems/templates/codebase/stack.md +188 -0
  160. package/deliver-great-systems/templates/codebase/structure.md +287 -0
  161. package/deliver-great-systems/templates/codebase/testing.md +482 -0
  162. package/deliver-great-systems/templates/config.json +38 -0
  163. package/deliver-great-systems/templates/context.md +354 -0
  164. package/deliver-great-systems/templates/continue-here.md +80 -0
  165. package/deliver-great-systems/templates/debug-subagent-prompt.md +93 -0
  166. package/deliver-great-systems/templates/discovery.md +148 -0
  167. package/deliver-great-systems/templates/milestone-archive.md +125 -0
  168. package/deliver-great-systems/templates/milestone.md +117 -0
  169. package/deliver-great-systems/templates/phase-prompt.md +615 -0
  170. package/deliver-great-systems/templates/planner-subagent-prompt.md +119 -0
  171. package/deliver-great-systems/templates/project.md +186 -0
  172. package/deliver-great-systems/templates/requirements.md +233 -0
  173. package/deliver-great-systems/templates/research-project/ARCHITECTURE.md +206 -0
  174. package/deliver-great-systems/templates/research-project/FEATURES.md +149 -0
  175. package/deliver-great-systems/templates/research-project/PITFALLS.md +202 -0
  176. package/deliver-great-systems/templates/research-project/STACK.md +122 -0
  177. package/deliver-great-systems/templates/research-project/SUMMARY.md +172 -0
  178. package/deliver-great-systems/templates/research.md +554 -0
  179. package/deliver-great-systems/templates/retrospective.md +54 -0
  180. package/deliver-great-systems/templates/roadmap.md +204 -0
  181. package/deliver-great-systems/templates/state.md +178 -0
  182. package/deliver-great-systems/templates/summary-complex.md +59 -0
  183. package/deliver-great-systems/templates/summary-minimal.md +41 -0
  184. package/deliver-great-systems/templates/summary-standard.md +48 -0
  185. package/deliver-great-systems/templates/summary.md +253 -0
  186. package/deliver-great-systems/templates/user-setup.md +313 -0
  187. package/deliver-great-systems/templates/verification-report.md +324 -0
  188. package/deliver-great-systems/workflows/add-doc.md +151 -0
  189. package/deliver-great-systems/workflows/add-idea.md +96 -0
  190. package/deliver-great-systems/workflows/add-phase.md +120 -0
  191. package/deliver-great-systems/workflows/add-tests.md +359 -0
  192. package/deliver-great-systems/workflows/add-todo.md +162 -0
  193. package/deliver-great-systems/workflows/approve-spec.md +194 -0
  194. package/deliver-great-systems/workflows/audit-milestone.md +364 -0
  195. package/deliver-great-systems/workflows/audit-phase.md +462 -0
  196. package/deliver-great-systems/workflows/cancel-job.md +108 -0
  197. package/deliver-great-systems/workflows/check-todos.md +181 -0
  198. package/deliver-great-systems/workflows/cleanup.md +247 -0
  199. package/deliver-great-systems/workflows/codereview.md +526 -0
  200. package/deliver-great-systems/workflows/complete-milestone.md +1298 -0
  201. package/deliver-great-systems/workflows/consolidate-ideas.md +365 -0
  202. package/deliver-great-systems/workflows/create-milestone-job.md +177 -0
  203. package/deliver-great-systems/workflows/develop-idea.md +544 -0
  204. package/deliver-great-systems/workflows/diagnose-issues.md +231 -0
  205. package/deliver-great-systems/workflows/discovery-phase.md +301 -0
  206. package/deliver-great-systems/workflows/discuss-idea.md +263 -0
  207. package/deliver-great-systems/workflows/discuss-phase.md +733 -0
  208. package/deliver-great-systems/workflows/execute-phase.md +571 -0
  209. package/deliver-great-systems/workflows/execute-plan.md +592 -0
  210. package/deliver-great-systems/workflows/find-related-ideas.md +271 -0
  211. package/deliver-great-systems/workflows/health.md +173 -0
  212. package/deliver-great-systems/workflows/help.md +997 -0
  213. package/deliver-great-systems/workflows/import-spec.md +381 -0
  214. package/deliver-great-systems/workflows/init-product.md +767 -0
  215. package/deliver-great-systems/workflows/insert-phase.md +138 -0
  216. package/deliver-great-systems/workflows/list-docs.md +119 -0
  217. package/deliver-great-systems/workflows/list-ideas.md +154 -0
  218. package/deliver-great-systems/workflows/list-jobs.md +89 -0
  219. package/deliver-great-systems/workflows/list-phase-assumptions.md +192 -0
  220. package/deliver-great-systems/workflows/list-specs.md +101 -0
  221. package/deliver-great-systems/workflows/map-codebase.md +621 -0
  222. package/deliver-great-systems/workflows/new-milestone.md +591 -0
  223. package/deliver-great-systems/workflows/new-project.md +1113 -0
  224. package/deliver-great-systems/workflows/node-repair.md +94 -0
  225. package/deliver-great-systems/workflows/overlap-check.md +86 -0
  226. package/deliver-great-systems/workflows/pause-work.md +134 -0
  227. package/deliver-great-systems/workflows/plan-milestone-gaps.md +306 -0
  228. package/deliver-great-systems/workflows/plan-phase.md +698 -0
  229. package/deliver-great-systems/workflows/progress.md +386 -0
  230. package/deliver-great-systems/workflows/quick.md +845 -0
  231. package/deliver-great-systems/workflows/refine-spec.md +275 -0
  232. package/deliver-great-systems/workflows/reject-idea.md +109 -0
  233. package/deliver-great-systems/workflows/remove-doc.md +117 -0
  234. package/deliver-great-systems/workflows/remove-phase.md +163 -0
  235. package/deliver-great-systems/workflows/research-idea.md +325 -0
  236. package/deliver-great-systems/workflows/research-phase.md +81 -0
  237. package/deliver-great-systems/workflows/restore-idea.md +101 -0
  238. package/deliver-great-systems/workflows/resume-project.md +311 -0
  239. package/deliver-great-systems/workflows/rollback-job.md +130 -0
  240. package/deliver-great-systems/workflows/run-job.md +498 -0
  241. package/deliver-great-systems/workflows/search.md +130 -0
  242. package/deliver-great-systems/workflows/set-profile.md +83 -0
  243. package/deliver-great-systems/workflows/settings.md +470 -0
  244. package/deliver-great-systems/workflows/transition.md +563 -0
  245. package/deliver-great-systems/workflows/undo-consolidation.md +155 -0
  246. package/deliver-great-systems/workflows/update-idea.md +157 -0
  247. package/deliver-great-systems/workflows/update.md +242 -0
  248. package/deliver-great-systems/workflows/validate-phase.md +177 -0
  249. package/deliver-great-systems/workflows/verify-phase.md +253 -0
  250. package/deliver-great-systems/workflows/verify-work.md +671 -0
  251. package/deliver-great-systems/workflows/write-spec.md +450 -0
  252. package/hooks/dist/dgs-check-update.js +62 -0
  253. package/hooks/dist/dgs-context-monitor.js +141 -0
  254. package/hooks/dist/dgs-statusline.js +115 -0
  255. package/package.json +60 -0
  256. package/scripts/build-hooks.js +43 -0
@@ -0,0 +1,845 @@
1
+ <purpose>
2
+ Execute small, ad-hoc tasks with DGS guarantees (atomic commits, STATE.md tracking). Quick mode spawns dgs-planner (quick mode) + dgs-executor(s), tracks tasks in `${quick_dir}/`, and updates STATE.md's "Quick Tasks Completed" table.
3
+
4
+ With `--fast` flag: the lightest DGS path. No subagents — the orchestrator makes edits directly, infers a conventional commit message, and commits atomically. Skips planner/executor entirely. Shares the same ID counter as regular quick tasks.
5
+
6
+ With `--fast --dry-run`: shows proposed changes as a diff before committing. User can apply or discard.
7
+
8
+ 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.
9
+
10
+ With `--full` flag: enables plan-checking (max 2 iterations) and post-execution verification for quality guarantees without full milestone ceremony.
11
+
12
+ Flags are composable: `--discuss --full` gives discussion + plan-checking + verification. `--fast` is exclusive — it cannot be combined with `--discuss` or `--full`.
13
+ </purpose>
14
+
15
+ <context_tier>planning</context_tier>
16
+
17
+ <required_reading>
18
+ Read all files referenced by the invoking prompt's execution_context before starting.
19
+ </required_reading>
20
+
21
+ <process>
22
+ **Step 1: Parse arguments and get task description**
23
+
24
+ Parse `$ARGUMENTS` for:
25
+ - `--fast` flag → store as `$FAST_MODE` (true/false)
26
+ - `--dry-run` flag → store as `$DRY_RUN` (true/false)
27
+ - `--full` flag → store as `$FULL_MODE` (true/false)
28
+ - `--discuss` flag → store as `$DISCUSS_MODE` (true/false)
29
+ - Remaining text (after stripping all flags) → use as `$DESCRIPTION` if non-empty
30
+
31
+ If `$DESCRIPTION` is empty after parsing, prompt user interactively:
32
+
33
+ ```
34
+ AskUserQuestion(
35
+ header: "Quick Task",
36
+ question: "What do you want to do?",
37
+ followUp: null
38
+ )
39
+ ```
40
+
41
+ Store response as `$DESCRIPTION`.
42
+
43
+ If still empty, re-prompt: "Please provide a task description."
44
+
45
+ Display banner based on active flags:
46
+
47
+ If `$FAST_MODE`:
48
+ ```
49
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
50
+ DGS > FAST
51
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
52
+
53
+ ◆ ${DESCRIPTION}
54
+ ```
55
+
56
+ If `$DISCUSS_MODE` and `$FULL_MODE`:
57
+ ```
58
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
59
+ DGS ► QUICK TASK (DISCUSS + FULL)
60
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
61
+
62
+ ◆ Discussion + plan checking + verification enabled
63
+ ```
64
+
65
+ If `$DISCUSS_MODE` only:
66
+ ```
67
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
68
+ DGS ► QUICK TASK (DISCUSS)
69
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
70
+
71
+ ◆ Discussion phase enabled — surfacing gray areas before planning
72
+ ```
73
+
74
+ If `$FULL_MODE` only:
75
+ ```
76
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
77
+ DGS ► QUICK TASK (FULL MODE)
78
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
79
+
80
+ ◆ Plan checking + verification enabled
81
+ ```
82
+
83
+ ---
84
+
85
+ **Step 2: Initialize**
86
+
87
+ ```bash
88
+ INIT=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" init quick "$DESCRIPTION")
89
+ if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
90
+ ```
91
+
92
+ Parse JSON for: `planner_model`, `executor_model`, `checker_model`, `verifier_model`, `commit_docs`, `quick_id`, `slug`, `date`, `timestamp`, `quick_dir`, `task_dir`, `roadmap_exists`, `planning_exists`, `author`.
93
+
94
+ Load planning-tier context files:
95
+
96
+ ```bash
97
+ TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier planning --raw 2>/dev/null)
98
+ ```
99
+
100
+ **If `roadmap_exists` is false:**
101
+ - **If `$FAST_MODE`:** Do NOT error. Set `$TRACKING_SKIPPED = true`. Display: `(tracking skipped — no STATE.md)`
102
+ - **If NOT `$FAST_MODE`:** Error — Quick mode requires an active project with ROADMAP.md. Run `/dgs:new-project` first.
103
+
104
+ Quick tasks can run mid-phase - validation only checks ROADMAP.md exists, not phase status.
105
+
106
+ ---
107
+
108
+ **Fast Path (when `$FAST_MODE` is true):**
109
+
110
+ If `$FAST_MODE` is false, skip this entire block and continue to Step 3.
111
+
112
+ When `$FAST_MODE` is true, execute this entire block and then end the workflow. Do NOT execute Steps 3 through 8.
113
+
114
+ **F1. Scope pre-check**
115
+
116
+ Analyze `$DESCRIPTION` to estimate how many files and lines will be affected. Consider:
117
+ - Does the description mention multiple files? ("update all config files", "change imports across...")
118
+ - Does it suggest large structural changes? ("refactor the module", "rewrite the handler")
119
+ - Is it clearly trivial? ("fix typo", "update port number", "add missing import")
120
+
121
+ If the estimate suggests >3 files or >30 lines of changes:
122
+ ```
123
+ AskUserQuestion(
124
+ header: "Scope Warning",
125
+ question: "This looks like it might affect more than 3 files or 30 lines. Continue as fast, or switch to /dgs:quick for more control?",
126
+ options: [
127
+ { label: "Continue as fast", description: "Proceed with direct edits" },
128
+ { label: "Switch to /dgs:quick", description: "Re-invoke with planner + executor for this description" }
129
+ ]
130
+ )
131
+ ```
132
+
133
+ If user chooses "Switch to /dgs:quick": re-invoke the quick workflow from Step 1 with `$FAST_MODE = false` and `$DESCRIPTION` preserved. Display:
134
+ ```
135
+ Switching to /dgs:quick...
136
+ ```
137
+ Then continue from Step 3 as normal quick mode (skip the rest of the fast path).
138
+
139
+ **F2. Make edits**
140
+
141
+ Read the relevant file(s) based on `$DESCRIPTION`, make the requested changes directly using Read/Edit/Write tools. No planner, no executor — the orchestrator acts as the implementer.
142
+
143
+ If `$DRY_RUN`:
144
+ After making edits but BEFORE committing, show the diff:
145
+ ```bash
146
+ git diff
147
+ ```
148
+ Then ask:
149
+ ```
150
+ AskUserQuestion(
151
+ header: "Dry Run — Proposed Changes",
152
+ question: "Apply these changes?",
153
+ options: [
154
+ { label: "Yes, apply and commit", description: "Commit these changes" },
155
+ { label: "No, discard", description: "Revert all changes" }
156
+ ]
157
+ )
158
+ ```
159
+ If user chooses "No, discard":
160
+ ```bash
161
+ git checkout -- .
162
+ ```
163
+ Display: "Changes discarded."
164
+ Skip to completion output with message: "Dry run complete — no changes applied."
165
+ End workflow.
166
+
167
+ **F3. Post-edit scope check**
168
+
169
+ After edits are made, check actual scope:
170
+ ```bash
171
+ git diff --stat
172
+ ```
173
+
174
+ Parse the output to count:
175
+ - Number of files changed
176
+ - Total lines added + deleted
177
+
178
+ If files > 3 OR lines > 30:
179
+ ```
180
+ AskUserQuestion(
181
+ header: "Scope Warning",
182
+ question: "Changes affect ${N} files and ${M} lines — exceeds fast threshold (3 files / 30 lines). Continue committing, or switch to /dgs:quick?",
183
+ options: [
184
+ { label: "Continue and commit", description: "Commit these changes as-is" },
185
+ { label: "Switch to /dgs:quick", description: "Stage changes and continue with planner review" }
186
+ ]
187
+ )
188
+ ```
189
+
190
+ If user chooses "Switch to /dgs:quick": Leave changes staged, re-invoke quick workflow from Step 5 (planner) with the edits already in place. The planner should account for changes already made.
191
+
192
+ **F4. Infer commit message**
193
+
194
+ Analyze the description and the actual changes (`git diff`) to infer a conventional commit message:
195
+ - Prefix: infer from description keywords and file types:
196
+ - "fix", "bug", "broken", "wrong" -> `fix:`
197
+ - "add", "create", "new", "implement" -> `feat:`
198
+ - "doc", "readme", "comment", "jsdoc" -> `docs:`
199
+ - "refactor", "clean", "reorganize" -> `refactor:`
200
+ - "test", "spec", "assert" -> `test:`
201
+ - "style", "format", "indent", "whitespace" -> `style:`
202
+ - Default/ambiguous -> `chore:`
203
+ - Scope field (optional): infer from filename or directory if it adds clarity. E.g., `fix(config):` for changes to config files.
204
+ - Message body: concise description of the change (not the user's raw description, but a clean conventional commit message).
205
+
206
+ Commit message is NOT shown to user before committing — just commit silently.
207
+
208
+ **F5. Commit**
209
+
210
+ ```bash
211
+ git add -A
212
+ git commit -m "${commit_message}"
213
+ ```
214
+
215
+ Get the short hash:
216
+ ```bash
217
+ git rev-parse --short HEAD
218
+ ```
219
+
220
+ Store as `$COMMIT_HASH`.
221
+
222
+ **F6. Update STATE.md (skip if `$TRACKING_SKIPPED`)**
223
+
224
+ If `$TRACKING_SKIPPED` is true, skip this step.
225
+
226
+ Otherwise, update STATE.md with the fast task row. Use the SAME format as regular quick tasks (shared table):
227
+
228
+ Read STATE.md. Check for `### Quick Tasks Completed` section.
229
+
230
+ If section doesn't exist, create it after `### Blockers/Concerns`:
231
+ ```markdown
232
+ ### Quick Tasks Completed
233
+
234
+ | # | Description | Date | Commit | Directory |
235
+ |---|-------------|------|--------|-----------|
236
+ ```
237
+
238
+ Append row:
239
+ ```markdown
240
+ | ${quick_id} | ${DESCRIPTION} | ${date} | ${COMMIT_HASH} | fast |
241
+ ```
242
+
243
+ Note: For fast tasks, the Directory column shows `fast` instead of a directory link (since fast tasks don't create planning directories).
244
+
245
+ Update "Last activity" line:
246
+ ```
247
+ Last activity: ${date} - Completed fast task ${quick_id}: ${DESCRIPTION}
248
+ ```
249
+
250
+ Use Edit tool to make these changes atomically.
251
+
252
+ **F6b. Archive excess rows (skip if `$TRACKING_SKIPPED`)**
253
+
254
+ After adding the row, trigger archival to keep the table within 20 rows:
255
+
256
+ ```bash
257
+ ARCHIVE_RESULT=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" state archive-quick-tasks --raw 2>/dev/null)
258
+ ```
259
+
260
+ If archival occurred (result contains `"archived": true`), `.planning/quick/HISTORY.md` was created or updated. Both STATE.md and HISTORY.md will be committed together in the next step.
261
+
262
+ **F6c. Commit tracking (fast path only)**
263
+
264
+ Commit STATE.md and HISTORY.md together so archival data is persisted:
265
+
266
+ ```bash
267
+ git add "${state_path}"
268
+ if [ -f "${project_root}/quick/HISTORY.md" ]; then
269
+ git add "${project_root}/quick/HISTORY.md"
270
+ fi
271
+ git commit -m "docs(quick-${quick_id}): track fast task" 2>/dev/null || true
272
+ ```
273
+
274
+ The `|| true` handles the case where nothing changed (e.g., STATE.md wasn't modified).
275
+
276
+ **F7. Output**
277
+
278
+ Display minimal one-liner:
279
+ ```
280
+ Done: ${commit_message} [${COMMIT_HASH}]
281
+ ```
282
+
283
+ If `$TRACKING_SKIPPED`:
284
+ ```
285
+ Done: ${commit_message} [${COMMIT_HASH}]
286
+ (tracking skipped — no STATE.md)
287
+ ```
288
+
289
+ End workflow. Do NOT proceed to Steps 3-8 of regular quick path.
290
+
291
+ ---
292
+
293
+ **Step 3: Create task directory**
294
+
295
+ If `$FAST_MODE`: skip — already handled by fast path above.
296
+
297
+ ```bash
298
+ mkdir -p "${task_dir}"
299
+ ```
300
+
301
+ ---
302
+
303
+ **Step 4: Create quick task directory**
304
+
305
+ Create the directory for this quick task:
306
+
307
+ ```bash
308
+ QUICK_DIR="${project_root}/quick/${quick_id}-${slug}"
309
+ mkdir -p "$QUICK_DIR"
310
+ ```
311
+
312
+ Report to user:
313
+ ```
314
+ Creating quick task ${quick_id}: ${DESCRIPTION}
315
+ Directory: ${QUICK_DIR}
316
+ ```
317
+
318
+ Store `$QUICK_DIR` for use in orchestration.
319
+
320
+ ---
321
+
322
+ **Step 4.5: Discussion phase (only when `$DISCUSS_MODE`)**
323
+
324
+ Skip this step entirely if NOT `$DISCUSS_MODE`.
325
+
326
+ Display banner:
327
+ ```
328
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
329
+ DGS ► DISCUSSING QUICK TASK
330
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
331
+
332
+ ◆ Surfacing gray areas for: ${DESCRIPTION}
333
+ ```
334
+
335
+ **4.5a. Identify gray areas**
336
+
337
+ Analyze `$DESCRIPTION` to identify 2-4 gray areas — implementation decisions that would change the outcome and that the user should weigh in on.
338
+
339
+ Use the domain-aware heuristic to generate phase-specific (not generic) gray areas:
340
+ - Something users **SEE** → layout, density, interactions, states
341
+ - Something users **CALL** → responses, errors, auth, versioning
342
+ - Something users **RUN** → output format, flags, modes, error handling
343
+ - Something users **READ** → structure, tone, depth, flow
344
+ - Something being **ORGANIZED** → criteria, grouping, naming, exceptions
345
+
346
+ Each gray area should be a concrete decision point, not a vague category. Example: "Loading behavior" not "UX".
347
+
348
+ **4.5b. Present gray areas**
349
+
350
+ ```
351
+ AskUserQuestion(
352
+ header: "Gray Areas",
353
+ question: "Which areas need clarification before planning?",
354
+ options: [
355
+ { label: "${area_1}", description: "${why_it_matters_1}" },
356
+ { label: "${area_2}", description: "${why_it_matters_2}" },
357
+ { label: "${area_3}", description: "${why_it_matters_3}" },
358
+ { label: "All clear", description: "Skip discussion — I know what I want" }
359
+ ],
360
+ multiSelect: true
361
+ )
362
+ ```
363
+
364
+ If user selects "All clear" → skip to Step 5 (no CONTEXT.md written).
365
+
366
+ **4.5c. Discuss selected areas**
367
+
368
+ For each selected area, ask 1-2 focused questions via AskUserQuestion:
369
+
370
+ ```
371
+ AskUserQuestion(
372
+ header: "${area_name}",
373
+ question: "${specific_question_about_this_area}",
374
+ options: [
375
+ { label: "${concrete_choice_1}", description: "${what_this_means}" },
376
+ { label: "${concrete_choice_2}", description: "${what_this_means}" },
377
+ { label: "${concrete_choice_3}", description: "${what_this_means}" },
378
+ { label: "You decide", description: "Claude's discretion" }
379
+ ],
380
+ multiSelect: false
381
+ )
382
+ ```
383
+
384
+ Rules:
385
+ - Options must be concrete choices, not abstract categories
386
+ - Highlight recommended choice where you have a clear opinion
387
+ - If user selects "Other" with freeform text, switch to plain text follow-up (per questioning.md freeform rule)
388
+ - If user selects "You decide", capture as Claude's Discretion in CONTEXT.md
389
+ - Max 2 questions per area — this is lightweight, not a deep dive
390
+
391
+ Collect all decisions into `$DECISIONS`.
392
+
393
+ **4.5d. Write CONTEXT.md**
394
+
395
+ Write `${QUICK_DIR}/${quick_id}-CONTEXT.md` using the standard context template structure:
396
+
397
+ ```markdown
398
+ # Quick Task ${quick_id}: ${DESCRIPTION} - Context
399
+
400
+ **Gathered:** ${date}
401
+ **Status:** Ready for planning
402
+
403
+ <domain>
404
+ ## Task Boundary
405
+
406
+ ${DESCRIPTION}
407
+
408
+ </domain>
409
+
410
+ <decisions>
411
+ ## Implementation Decisions
412
+
413
+ ### ${area_1_name}
414
+ - ${decision_from_discussion}
415
+
416
+ ### ${area_2_name}
417
+ - ${decision_from_discussion}
418
+
419
+ ### Claude's Discretion
420
+ ${areas_where_user_said_you_decide_or_areas_not_discussed}
421
+
422
+ </decisions>
423
+
424
+ <specifics>
425
+ ## Specific Ideas
426
+
427
+ ${any_specific_references_or_examples_from_discussion}
428
+
429
+ [If none: "No specific requirements — open to standard approaches"]
430
+
431
+ </specifics>
432
+
433
+ <canonical_refs>
434
+ ## Canonical References
435
+
436
+ ${any_specs_adrs_or_docs_referenced_during_discussion}
437
+
438
+ [If none: "No external specs — requirements fully captured in decisions above"]
439
+
440
+ </canonical_refs>
441
+ ```
442
+
443
+ 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.
444
+
445
+ Report: `Context captured: ${QUICK_DIR}/${quick_id}-CONTEXT.md`
446
+
447
+ ---
448
+
449
+ **Step 5: Spawn planner (quick mode)**
450
+
451
+ **If `$FULL_MODE`:** Use `quick-full` mode with stricter constraints.
452
+
453
+ **If NOT `$FULL_MODE`:** Use standard `quick` mode.
454
+
455
+ ```
456
+ Task(
457
+ prompt="
458
+ <planning_context>
459
+
460
+ **Mode:** ${FULL_MODE ? 'quick-full' : 'quick'}
461
+ **Directory:** ${QUICK_DIR}
462
+ **Description:** ${DESCRIPTION}
463
+
464
+ <files_to_read>
465
+ - ${state_path} (Project State)
466
+ - ./CLAUDE.md (if exists — follow project-specific guidelines)
467
+ ${DISCUSS_MODE ? '- ' + QUICK_DIR + '/' + quick_id + '-CONTEXT.md (User decisions — locked, do not revisit)' : ''}
468
+ </files_to_read>
469
+
470
+ **Project skills:** Check .claude/skills/ or .agents/skills/ directory (if either exists) — read SKILL.md files, plans should account for project skill rules
471
+
472
+ **Author:** ${author}
473
+
474
+ </planning_context>
475
+
476
+ <constraints>
477
+ - Create a SINGLE plan with 1-3 focused tasks
478
+ - Quick tasks should be atomic and self-contained
479
+ - No research phase
480
+ ${FULL_MODE ? '- Target ~40% context usage (structured for verification)' : '- Target ~30% context usage (simple, focused)'}
481
+ ${FULL_MODE ? '- MUST generate `must_haves` in plan frontmatter (truths, artifacts, key_links)' : ''}
482
+ ${FULL_MODE ? '- Each task MUST have `files`, `action`, `verify`, `done` fields' : ''}
483
+ </constraints>
484
+
485
+ <output>
486
+ Write plan to: ${QUICK_DIR}/${quick_id}-PLAN.md
487
+ Return: ## PLANNING COMPLETE with plan path
488
+ </output>
489
+ ",
490
+ subagent_type="dgs-planner",
491
+ model="{planner_model}",
492
+ description="Quick plan: ${DESCRIPTION}"
493
+ )
494
+ ```
495
+
496
+ After planner returns:
497
+ 1. Verify plan exists at `${QUICK_DIR}/${quick_id}-PLAN.md`
498
+ 2. Extract plan count (typically 1 for quick tasks)
499
+ 3. Report: "Plan created: ${QUICK_DIR}/${quick_id}-PLAN.md"
500
+
501
+ If plan not found, error: "Planner failed to create ${quick_id}-PLAN.md"
502
+
503
+ ---
504
+
505
+ **Step 5.5: Plan-checker loop (only when `$FULL_MODE`)**
506
+
507
+ Skip this step entirely if NOT `$FULL_MODE`.
508
+
509
+ Display banner:
510
+ ```
511
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
512
+ DGS ► CHECKING PLAN
513
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
514
+
515
+ ◆ Spawning plan checker...
516
+ ```
517
+
518
+ Checker prompt:
519
+
520
+ ```markdown
521
+ <verification_context>
522
+ **Mode:** quick-full
523
+ **Task Description:** ${DESCRIPTION}
524
+
525
+ <files_to_read>
526
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Plan to verify)
527
+ </files_to_read>
528
+
529
+ **Scope:** This is a quick task, not a full phase. Skip checks that require a ROADMAP phase goal.
530
+ </verification_context>
531
+
532
+ <check_dimensions>
533
+ - Requirement coverage: Does the plan address the task description?
534
+ - Task completeness: Do tasks have files, action, verify, done fields?
535
+ - Key links: Are referenced files real?
536
+ - Scope sanity: Is this appropriately sized for a quick task (1-3 tasks)?
537
+ - must_haves derivation: Are must_haves traceable to the task description?
538
+
539
+ Skip: cross-plan deps (single plan), ROADMAP alignment
540
+ ${DISCUSS_MODE ? '- Context compliance: Does the plan honor locked decisions from CONTEXT.md?' : '- Skip: context compliance (no CONTEXT.md)'}
541
+ </check_dimensions>
542
+
543
+ <expected_output>
544
+ - ## VERIFICATION PASSED — all checks pass
545
+ - ## ISSUES FOUND — structured issue list
546
+ </expected_output>
547
+ ```
548
+
549
+ ```
550
+ Task(
551
+ prompt=checker_prompt,
552
+ subagent_type="dgs-plan-checker",
553
+ model="{checker_model}",
554
+ description="Check quick plan: ${DESCRIPTION}"
555
+ )
556
+ ```
557
+
558
+ **Handle checker return:**
559
+
560
+ - **`## VERIFICATION PASSED`:** Display confirmation, proceed to step 6.
561
+ - **`## ISSUES FOUND`:** Display issues, check iteration count, enter revision loop.
562
+
563
+ **Revision loop (max 2 iterations):**
564
+
565
+ Track `iteration_count` (starts at 1 after initial plan + check).
566
+
567
+ **If iteration_count < 2:**
568
+
569
+ Display: `Sending back to planner for revision... (iteration ${N}/2)`
570
+
571
+ Revision prompt:
572
+
573
+ ```markdown
574
+ <revision_context>
575
+ **Mode:** quick-full (revision)
576
+
577
+ <files_to_read>
578
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Existing plan)
579
+ </files_to_read>
580
+
581
+ **Checker issues:** ${structured_issues_from_checker}
582
+
583
+ </revision_context>
584
+
585
+ <instructions>
586
+ Make targeted updates to address checker issues.
587
+ Do NOT replan from scratch unless issues are fundamental.
588
+ Return what changed.
589
+ </instructions>
590
+ ```
591
+
592
+ ```
593
+ Task(
594
+ prompt=revision_prompt,
595
+ subagent_type="dgs-planner",
596
+ model="{planner_model}",
597
+ description="Revise quick plan: ${DESCRIPTION}"
598
+ )
599
+ ```
600
+
601
+ After planner returns → spawn checker again, increment iteration_count.
602
+
603
+ **If iteration_count >= 2:**
604
+
605
+ Display: `Max iterations reached. ${N} issues remain:` + issue list
606
+
607
+ Offer: 1) Force proceed, 2) Abort
608
+
609
+ ---
610
+
611
+ **Step 6: Spawn executor**
612
+
613
+ Spawn dgs-executor with plan reference:
614
+
615
+ ```
616
+ Task(
617
+ prompt="
618
+ Execute quick task ${quick_id}.
619
+
620
+ <files_to_read>
621
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Plan)
622
+ - ${state_path} (Project state)
623
+ - ./CLAUDE.md (Project instructions, if exists)
624
+ - .claude/skills/ or .agents/skills/ (Project skills, if either exists — list skills, read SKILL.md for each, follow relevant rules during implementation)
625
+ </files_to_read>
626
+
627
+ <constraints>
628
+ - Execute all tasks in the plan
629
+ - Commit each task atomically
630
+ - Create summary at: ${QUICK_DIR}/${quick_id}-SUMMARY.md
631
+ - Do NOT update ROADMAP.md (quick tasks are separate from planned phases)
632
+ - Include executed_by: "${author}" in SUMMARY.md frontmatter
633
+ </constraints>
634
+ ",
635
+ subagent_type="dgs-executor",
636
+ model="{executor_model}",
637
+ description="Execute: ${DESCRIPTION}"
638
+ )
639
+ ```
640
+
641
+ After executor returns:
642
+ 1. Verify summary exists at `${QUICK_DIR}/${quick_id}-SUMMARY.md`
643
+ 2. Extract commit hash from executor output
644
+ 3. Report completion status
645
+
646
+ **Known Claude Code bug (classifyHandoffIfNeeded):** If executor reports "failed" with error `classifyHandoffIfNeeded is not defined`, this is a Claude Code runtime bug — not a real failure. Check if summary file exists and git log shows commits. If so, treat as successful.
647
+
648
+ If summary not found, error: "Executor failed to create ${quick_id}-SUMMARY.md"
649
+
650
+ Note: For quick tasks producing multiple plans (rare), spawn executors in parallel waves per execute-phase patterns.
651
+
652
+ ---
653
+
654
+ **Step 6.5: Verification (only when `$FULL_MODE`)**
655
+
656
+ Skip this step entirely if NOT `$FULL_MODE`.
657
+
658
+ Display banner:
659
+ ```
660
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
661
+ DGS ► VERIFYING RESULTS
662
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
663
+
664
+ ◆ Spawning verifier...
665
+ ```
666
+
667
+ ```
668
+ Task(
669
+ prompt="Verify quick task goal achievement.
670
+ Task directory: ${QUICK_DIR}
671
+ Task goal: ${DESCRIPTION}
672
+
673
+ <files_to_read>
674
+ - ${QUICK_DIR}/${quick_id}-PLAN.md (Plan)
675
+ </files_to_read>
676
+
677
+ Check must_haves against actual codebase. Create VERIFICATION.md at ${QUICK_DIR}/${quick_id}-VERIFICATION.md.",
678
+ subagent_type="dgs-verifier",
679
+ model="{verifier_model}",
680
+ description="Verify: ${DESCRIPTION}"
681
+ )
682
+ ```
683
+
684
+ Read verification status:
685
+ ```bash
686
+ grep "^status:" "${QUICK_DIR}/${quick_id}-VERIFICATION.md" | cut -d: -f2 | tr -d ' '
687
+ ```
688
+
689
+ Store as `$VERIFICATION_STATUS`.
690
+
691
+ | Status | Action |
692
+ |--------|--------|
693
+ | `passed` | Store `$VERIFICATION_STATUS = "Verified"`, continue to step 7 |
694
+ | `human_needed` | Display items needing manual check, store `$VERIFICATION_STATUS = "Needs Review"`, continue |
695
+ | `gaps_found` | Display gap summary, offer: 1) Re-run executor to fix gaps, 2) Accept as-is. Store `$VERIFICATION_STATUS = "Gaps"` |
696
+
697
+ ---
698
+
699
+ **Step 7: Update STATE.md**
700
+
701
+ If `$FAST_MODE`: skip — fast path handles its own STATE.md update in step F6 above.
702
+
703
+ Update STATE.md with quick task completion record.
704
+
705
+ **7a. Check if "Quick Tasks Completed" section exists:**
706
+
707
+ Read STATE.md and check for `### Quick Tasks Completed` section.
708
+
709
+ **7b. If section doesn't exist, create it:**
710
+
711
+ Insert after `### Blockers/Concerns` section:
712
+
713
+ **If `$FULL_MODE`:**
714
+ ```markdown
715
+ ### Quick Tasks Completed
716
+
717
+ | # | Description | Date | Commit | Status | Directory |
718
+ |---|-------------|------|--------|--------|-----------|
719
+ ```
720
+
721
+ **If NOT `$FULL_MODE`:**
722
+ ```markdown
723
+ ### Quick Tasks Completed
724
+
725
+ | # | Description | Date | Commit | Directory |
726
+ |---|-------------|------|--------|-----------|
727
+ ```
728
+
729
+ **Note:** If the table already exists, match its existing column format. If adding `--full` to a project that already has quick tasks without a Status column, add the Status column to the header and separator rows, and leave Status empty for the new row's predecessors.
730
+
731
+ **7c. Append new row to table:**
732
+
733
+ Use `date` from init:
734
+
735
+ **If `$FULL_MODE` (or table has Status column):**
736
+ ```markdown
737
+ | ${quick_id} | ${DESCRIPTION} | ${date} | ${commit_hash} | ${VERIFICATION_STATUS} | [${quick_id}-${slug}](./quick/${quick_id}-${slug}/) |
738
+ ```
739
+
740
+ **If NOT `$FULL_MODE` (and table has no Status column):**
741
+ ```markdown
742
+ | ${quick_id} | ${DESCRIPTION} | ${date} | ${commit_hash} | [${quick_id}-${slug}](./quick/${quick_id}-${slug}/) |
743
+ ```
744
+
745
+ **7c2. Archive excess rows**
746
+
747
+ After adding the row, trigger archival to keep the table within 20 rows:
748
+
749
+ ```bash
750
+ node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" state archive-quick-tasks 2>/dev/null
751
+ ```
752
+
753
+ If archival occurred, `.planning/quick/HISTORY.md` was created or updated. Include it in Step 8's commit file list.
754
+
755
+ **7d. Update "Last activity" line:**
756
+
757
+ Use `date` from init:
758
+ ```
759
+ Last activity: ${date} - Completed quick task ${quick_id}: ${DESCRIPTION}
760
+ ```
761
+
762
+ Use Edit tool to make these changes atomically
763
+
764
+ ---
765
+
766
+ **Step 8: Final commit and completion**
767
+
768
+ Stage and commit quick task artifacts:
769
+
770
+ Build file list:
771
+ - `${QUICK_DIR}/${quick_id}-PLAN.md`
772
+ - `${QUICK_DIR}/${quick_id}-SUMMARY.md`
773
+ - `${state_path}`
774
+ - `${project_root}/quick/HISTORY.md` (if it exists — may have been created by archival)
775
+ - If `$DISCUSS_MODE` and context file exists: `${QUICK_DIR}/${quick_id}-CONTEXT.md`
776
+ - If `$FULL_MODE` and verification file exists: `${QUICK_DIR}/${quick_id}-VERIFICATION.md`
777
+
778
+ ```bash
779
+ node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" commit "docs(quick-${quick_id}): ${DESCRIPTION}" --files ${file_list}
780
+ ```
781
+
782
+ Get final commit hash:
783
+ ```bash
784
+ commit_hash=$(git rev-parse --short HEAD)
785
+ ```
786
+
787
+ Display completion output:
788
+
789
+ **If `$FULL_MODE`:**
790
+ ```
791
+ ---
792
+
793
+ DGS > QUICK TASK COMPLETE (FULL MODE)
794
+
795
+ Quick Task ${quick_id}: ${DESCRIPTION}
796
+
797
+ Summary: ${QUICK_DIR}/${quick_id}-SUMMARY.md
798
+ Verification: ${QUICK_DIR}/${quick_id}-VERIFICATION.md (${VERIFICATION_STATUS})
799
+ Commit: ${commit_hash}
800
+
801
+ ---
802
+
803
+ Ready for next task: /dgs:quick
804
+ ```
805
+
806
+ **If NOT `$FULL_MODE`:**
807
+ ```
808
+ ---
809
+
810
+ DGS > QUICK TASK COMPLETE
811
+
812
+ Quick Task ${quick_id}: ${DESCRIPTION}
813
+
814
+ Summary: ${QUICK_DIR}/${quick_id}-SUMMARY.md
815
+ Commit: ${commit_hash}
816
+
817
+ ---
818
+
819
+ Ready for next task: /dgs:quick
820
+ ```
821
+
822
+ </process>
823
+
824
+ <success_criteria>
825
+ - [ ] ROADMAP.md validation passes
826
+ - [ ] User provides task description
827
+ - [ ] `--full`, `--discuss`, `--fast`, and `--dry-run` flags parsed from arguments when present
828
+ - [ ] Slug generated (lowercase, hyphens, max 40 chars)
829
+ - [ ] Quick ID generated (YYMMDD-xxx format, 2s Base36 precision)
830
+ - [ ] Directory created at `${quick_dir}/YYMMDD-xxx-slug/`
831
+ - [ ] (--discuss) Gray areas identified and presented, decisions captured in `${quick_id}-CONTEXT.md`
832
+ - [ ] `${quick_id}-PLAN.md` created by planner (honors CONTEXT.md decisions when --discuss)
833
+ - [ ] (--full) Plan checker validates plan, revision loop capped at 2
834
+ - [ ] `${quick_id}-SUMMARY.md` created by executor
835
+ - [ ] (--full) `${quick_id}-VERIFICATION.md` created by verifier
836
+ - [ ] STATE.md updated with quick task row (Status column when --full)
837
+ - [ ] Artifacts committed
838
+ - [ ] (--fast) `--fast` and `--dry-run` flags parsed from arguments
839
+ - [ ] (--fast) No subagents spawned — orchestrator makes edits directly
840
+ - [ ] (--fast) Conventional commit message inferred and committed
841
+ - [ ] (--fast) STATE.md updated with fast task row (or skipped if no STATE.md)
842
+ - [ ] (--fast) Scope warning shown when >3 files or >30 lines affected
843
+ - [ ] (--fast) (--dry-run) Changes shown as diff, user asked to apply or discard
844
+ - [ ] (--fast) Minimal output: "Done: {message} [{hash}]"
845
+ </success_criteria>