@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,138 @@
1
+ <purpose>
2
+ Insert a decimal phase for urgent work discovered mid-milestone between existing integer phases. Uses decimal numbering (72.1, 72.2, etc.) to preserve the logical sequence of planned phases while accommodating urgent insertions without renumbering the entire roadmap.
3
+ </purpose>
4
+
5
+ <context_tier>planning</context_tier>
6
+
7
+ <required_reading>
8
+ Read all files referenced by the invoking prompt's execution_context before starting.
9
+ </required_reading>
10
+
11
+ <process>
12
+
13
+ <step name="parse_arguments">
14
+ Parse the command arguments:
15
+ - First argument: integer phase number to insert after
16
+ - Remaining arguments: phase description
17
+
18
+ Example: `/dgs:insert-phase 72 Fix critical auth bug`
19
+ -> after = 72
20
+ -> description = "Fix critical auth bug"
21
+
22
+ If arguments missing:
23
+
24
+ ```
25
+ ERROR: Both phase number and description required
26
+ Usage: /dgs:insert-phase <after> <description>
27
+ Example: /dgs:insert-phase 72 Fix critical auth bug
28
+ ```
29
+
30
+ Exit.
31
+
32
+ Validate first argument is an integer.
33
+ </step>
34
+
35
+ <step name="init_context">
36
+ Load phase operation context:
37
+
38
+ ```bash
39
+ INIT=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" init phase-op "${after_phase}")
40
+ if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
41
+ ```
42
+
43
+ Load planning-tier context files:
44
+
45
+ ```bash
46
+ TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier planning --raw 2>/dev/null)
47
+ ```
48
+
49
+ Check `roadmap_exists` from init JSON. If false:
50
+ ```
51
+ ERROR: No roadmap found (${roadmap_path})
52
+ ```
53
+ Exit.
54
+ </step>
55
+
56
+ <step name="insert_phase">
57
+ **Delegate the phase insertion to dgs-tools:**
58
+
59
+ ```bash
60
+ RESULT=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" phase insert "${after_phase}" "${description}")
61
+ ```
62
+
63
+ The CLI handles:
64
+ - Verifying target phase exists in ROADMAP.md
65
+ - Calculating next decimal phase number (checking existing decimals on disk)
66
+ - Generating slug from description
67
+ - Creating the phase directory (`${phases_dir}/{N.M}-{slug}/`)
68
+ - Inserting the phase entry into ROADMAP.md after the target phase with (INSERTED) marker
69
+
70
+ Extract from result: `phase_number`, `after_phase`, `name`, `slug`, `directory`.
71
+ </step>
72
+
73
+ <step name="update_project_state">
74
+ Update STATE.md to reflect the inserted phase:
75
+
76
+ 1. Read STATE.md (via `${state_path}` from init)
77
+ 2. Under "## Accumulated Context" → "### Roadmap Evolution" add entry:
78
+ ```
79
+ - Phase {decimal_phase} inserted after Phase {after_phase}: {description} (URGENT)
80
+ ```
81
+
82
+ If "Roadmap Evolution" section doesn't exist, create it.
83
+ </step>
84
+
85
+ <step name="completion">
86
+ Present completion summary:
87
+
88
+ ```
89
+ Phase {decimal_phase} inserted after Phase {after_phase}:
90
+ - Description: {description}
91
+ - Directory: ${phases_dir}/{decimal-phase}-{slug}/
92
+ - Status: Not planned yet
93
+ - Marker: (INSERTED) - indicates urgent work
94
+
95
+ Roadmap updated: ${roadmap_path}
96
+ Project state updated: ${state_path}
97
+
98
+ ---
99
+
100
+ ## Next Up
101
+
102
+ **Phase {decimal_phase}: {description}** -- urgent insertion
103
+
104
+ `/dgs:plan-phase {decimal_phase}`
105
+
106
+ <sub>`/clear` first -> fresh context window</sub>
107
+
108
+ ---
109
+
110
+ **Also available:**
111
+ - Review insertion impact: Check if Phase {next_integer} dependencies still make sense
112
+ - Review roadmap
113
+
114
+ ---
115
+ ```
116
+ </step>
117
+
118
+ </process>
119
+
120
+ <anti_patterns>
121
+
122
+ - Don't use this for planned work at end of milestone (use /dgs:add-phase)
123
+ - Don't insert before Phase 1 (decimal 0.1 makes no sense)
124
+ - Don't renumber existing phases
125
+ - Don't modify the target phase content
126
+ - Don't create plans yet (that's /dgs:plan-phase)
127
+ - Don't commit changes (user decides when to commit)
128
+ </anti_patterns>
129
+
130
+ <success_criteria>
131
+ Phase insertion is complete when:
132
+
133
+ - [ ] `dgs-tools phase insert` executed successfully
134
+ - [ ] Phase directory created
135
+ - [ ] Roadmap updated with new phase entry (includes "(INSERTED)" marker)
136
+ - [ ] STATE.md updated with roadmap evolution note
137
+ - [ ] User informed of next steps and dependency implications
138
+ </success_criteria>
@@ -0,0 +1,119 @@
1
+ <purpose>
2
+ List all supporting documents grouped by scope (product first, then ideas, then specs) with metadata tables. Supports --scope filtering to show documents for a specific scope only. This is the primary dashboard for browsing the document inventory.
3
+ </purpose>
4
+
5
+ <context_tier>lite</context_tier>
6
+
7
+ <required_reading>
8
+ Read all files referenced by the invoking prompt's execution_context before starting.
9
+ </required_reading>
10
+
11
+ <process>
12
+
13
+ <step name="load_context" priority="first">
14
+ Load project context via tier system:
15
+
16
+ ```bash
17
+ TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier lite --raw 2>/dev/null)
18
+ ```
19
+
20
+ Use `TIER_FILES` JSON `files` array for project context (PROJECT.md, STATE.md, config.json).
21
+ </step>
22
+
23
+ <step name="parse_arguments">
24
+ Parse filter flags from `$ARGUMENTS`.
25
+
26
+ - Check for `--scope <filter>` flag
27
+ - Filter values: `product`, `idea:<slug>`, `spec:<slug>`, or empty (show all)
28
+
29
+ Examples:
30
+ - `/dgs:list-docs` -> no filter (show all scopes)
31
+ - `/dgs:list-docs --scope product` -> show only product-level documents
32
+ - `/dgs:list-docs --scope idea:auto-review-prs` -> show only documents for that idea
33
+ - `/dgs:list-docs --scope spec:auth-system` -> show only documents for that spec
34
+ </step>
35
+
36
+ <step name="fetch_docs">
37
+ Fetch document inventory with scope grouping:
38
+
39
+ ```bash
40
+ node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs docs list --scope "$scopeFilter"
41
+ ```
42
+
43
+ If no filter, omit the `--scope` flag to get all documents:
44
+
45
+ ```bash
46
+ node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs docs list
47
+ ```
48
+
49
+ Parse the JSON result:
50
+ - `scopes`: array of scope objects, each with `scope`, `scope_id`, and `docs` array
51
+ - Each doc has: `name` (original), `slug`, `type` (file extension), `size` (formatted), `added` (date), `extraction` (success/failed/skipped)
52
+ - `total_count`: total number of documents across all scopes
53
+ - `scope_count`: number of scopes with documents
54
+ </step>
55
+
56
+ <step name="display">
57
+ **If no documents exist (total_count === 0 and no filter applied):**
58
+
59
+ Display:
60
+ ```
61
+ No documents found. Run /dgs:add-doc to add one.
62
+ ```
63
+ Exit.
64
+
65
+ **If scope filter returns empty:**
66
+
67
+ Display:
68
+ ```
69
+ No documents found in {scope}.
70
+ ```
71
+ Exit.
72
+
73
+ **Otherwise, display grouped sections:**
74
+
75
+ Group documents by scope. Order: **Product Documents** first, then **Idea: {name}** for each idea, then **Spec: {name}** for each spec.
76
+
77
+ For each scope that has documents, display a section:
78
+
79
+ ```
80
+ ## Product Documents
81
+
82
+ | Name | Type | Size | Added | Extraction |
83
+ |------|------|------|-------|------------|
84
+ | q4-budget.pdf | PDF | 2.4 MB | 2026-02-25 | success |
85
+ | architecture-diagram.png | PNG | 540 KB | 2026-02-25 | skipped |
86
+ ```
87
+
88
+ For idea/spec scopes:
89
+
90
+ ```
91
+ ## Idea: Auto Review PRs
92
+
93
+ | Name | Type | Size | Added | Extraction |
94
+ |------|------|------|-------|------------|
95
+ | review-process.docx | DOCX | 89 KB | 2026-02-25 | success |
96
+ ```
97
+
98
+ **Summary line at bottom:**
99
+
100
+ ```
101
+ {N} document(s) across {M} scope(s)
102
+ ```
103
+
104
+ If filtering by scope, note the filter:
105
+
106
+ ```
107
+ Showing: {scope} | {N} document(s)
108
+ ```
109
+ </step>
110
+
111
+ </process>
112
+
113
+ <success_criteria>
114
+ - [ ] Documents displayed grouped by scope with headers
115
+ - [ ] Each document shows name, type, size, added date, and extraction status
116
+ - [ ] --scope filter works for product, idea, and spec scopes
117
+ - [ ] Empty state shows helpful hint
118
+ - [ ] Summary count displayed at bottom
119
+ </success_criteria>
@@ -0,0 +1,154 @@
1
+ <purpose>
2
+ List all ideas grouped by state (Pending, Done, Rejected, and optionally Consolidated) with optional tag and state filtering, orphan detection for done ideas, and a helpful empty-state message. This is the primary dashboard for viewing idea status.
3
+
4
+ By default, consolidated ideas are hidden. Use `--consolidated` to show only consolidated ideas, or `--all` to include consolidated ideas alongside all other states.
5
+ </purpose>
6
+
7
+ <context_tier>lite</context_tier>
8
+
9
+ <required_reading>
10
+ Read all files referenced by the invoking prompt's execution_context before starting.
11
+ </required_reading>
12
+
13
+ <process>
14
+
15
+ <step name="load_context" priority="first">
16
+ Load project context via tier system:
17
+
18
+ ```bash
19
+ TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier lite --raw 2>/dev/null)
20
+ ```
21
+
22
+ Use `TIER_FILES` JSON `files` array for project context (PROJECT.md, STATE.md, config.json).
23
+ </step>
24
+
25
+ <step name="parse_arguments">
26
+ Parse filter flags from arguments:
27
+
28
+ - Check for `--tag TAG` filter (e.g., `--tag api`)
29
+ - Check for state filter flags: `--pending`, `--done`, `--rejected`
30
+ - Check for `--consolidated` flag (show only consolidated ideas)
31
+ - Check for `--all` flag (include consolidated ideas alongside all other states)
32
+ - Map state flags to the `--state` parameter value
33
+ - `--consolidated` and `--all` are mutually exclusive with each other and with state filters (`--pending`/`--done`/`--rejected`)
34
+
35
+ Examples:
36
+ - `/dgs:list-ideas` -> no filters (show pending, done, rejected; consolidated hidden)
37
+ - `/dgs:list-ideas --tag api` -> filter by tag "api" (consolidated still hidden)
38
+ - `/dgs:list-ideas --pending` -> show only pending ideas
39
+ - `/dgs:list-ideas --done --tag ux` -> show only done ideas with tag "ux"
40
+ - `/dgs:list-ideas --consolidated` -> show only consolidated ideas
41
+ - `/dgs:list-ideas --all` -> show all ideas including consolidated
42
+
43
+ Only one state filter allowed at a time. If multiple provided, use the first one.
44
+ </step>
45
+
46
+ <step name="fetch_ideas">
47
+ Fetch ideas data with orphan detection:
48
+
49
+ ```bash
50
+ node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs ideas list [--state STATE] [--tag TAG] [--consolidated] [--all] --orphan-check --raw
51
+ ```
52
+
53
+ Build the command with applicable flags from step 1. Pass `--consolidated` or `--all` when those flags are present.
54
+
55
+ Parse the JSON result with fields:
56
+ - `ideas`: array of idea objects (id, title, tags, created, state, orphaned, discussed, researched, consolidated_into)
57
+ - `counts`: object with pending, done, rejected, consolidated, total counts
58
+ - `orphaned_ids`: array of IDs for done ideas with no spec reference
59
+
60
+ The `discussed` and `researched` fields are booleans indicating whether the idea has a Discussion Log or Research Log section with content.
61
+ </step>
62
+
63
+ <step name="format_output">
64
+ **If no ideas exist (counts.total === 0):**
65
+
66
+ Display:
67
+ ```
68
+ No ideas yet. Run /dgs:add-idea to capture one.
69
+ ```
70
+ Exit.
71
+
72
+ **Otherwise, display grouped sections:**
73
+
74
+ Group ideas by state. For each state that has ideas, display a section with header and table.
75
+
76
+ Order: Pending first, then Done, then Rejected, then Consolidated (if included).
77
+
78
+ For each state group (Pending, Done, Rejected):
79
+
80
+ ```
81
+ ## Pending (N)
82
+
83
+ | ID | Title | Dev | Tags | Created |
84
+ |----|-------|-----|------|---------|
85
+ | 042 | Auto review reminders | D+R | api, automation | 2026-02-25 |
86
+ | 043 | Better error messages | - | ux | 2026-02-25 |
87
+ ```
88
+
89
+ For the Consolidated state group (shown with `--consolidated` or `--all`):
90
+
91
+ ```
92
+ ## Consolidated (N)
93
+
94
+ | ID | Title | Consolidated Into | Tags | Created |
95
+ |----|-------|-------------------|------|---------|
96
+ | 001 | Add retry logic | -> #005 | api | 2026-02-25 |
97
+ ```
98
+
99
+ The "Consolidated Into" column replaces "Dev" for consolidated ideas, showing `-> #ID` where the ID comes from the `consolidated_into` field.
100
+
101
+ Formatting rules:
102
+ - **ID:** Zero-padded 3-digit (e.g., 042)
103
+ - **Title:** As stored. For done ideas whose ID appears in `orphaned_ids`, append ` [orphaned]` to the title (inline marker per CONTEXT.md)
104
+ - **Dev:** Development status indicator based on `discussed` and `researched` fields:
105
+ - `D+R` — both discussed AND researched
106
+ - `D` — discussed only
107
+ - `R` — researched only
108
+ - `-` — neither discussed nor researched
109
+ - **Consolidated Into:** For consolidated ideas only, display `-> #ID` from the `consolidated_into` field
110
+ - **Tags:** Comma-separated, or empty cell if none
111
+ - **Created:** Date portion only (YYYY-MM-DD), extracted from ISO timestamp
112
+
113
+ If filtering by state (--pending/--done/--rejected), only show that one section.
114
+ If using `--consolidated`, only show the Consolidated section.
115
+ If using `--all`, show all sections including Consolidated.
116
+ If filtering by tag, only show ideas matching the tag (across all displayed states).
117
+
118
+ **Summary line at bottom:**
119
+
120
+ When consolidated ideas are visible (via `--consolidated` or `--all`), include the consolidated count:
121
+
122
+ ```
123
+ Total: N ideas (P pending, D done, R rejected, C consolidated)
124
+ ```
125
+
126
+ Only show the consolidated count when it is non-zero and the view includes consolidated.
127
+
128
+ Use the counts from the JSON result. If filtering by state, still show the full count line but note the filter:
129
+
130
+ ```
131
+ Showing: pending only | Total: N ideas (P pending, D done, R rejected)
132
+ ```
133
+
134
+ For `--consolidated`:
135
+
136
+ ```
137
+ Showing: consolidated only | Total: N ideas (P pending, D done, R rejected, C consolidated)
138
+ ```
139
+ </step>
140
+
141
+ </process>
142
+
143
+ <success_criteria>
144
+ - [ ] Ideas displayed grouped by state with headers
145
+ - [ ] Each idea shows ID, title, Dev status, tags, and created date
146
+ - [ ] Dev column shows D (discussed), R (researched), D+R (both), or - (neither)
147
+ - [ ] Orphaned done ideas marked with inline [orphaned] marker
148
+ - [ ] Tag and state filters work
149
+ - [ ] Empty state shows helpful hint
150
+ - [ ] Consolidated ideas hidden by default
151
+ - [ ] `--consolidated` flag shows only consolidated ideas with "Consolidated Into" column
152
+ - [ ] `--all` flag shows all ideas including consolidated
153
+ - [ ] Summary line includes consolidated count when consolidated ideas are visible
154
+ </success_criteria>
@@ -0,0 +1,89 @@
1
+ <purpose>
2
+ Display all milestone jobs grouped by status with progress fractions. Provides a quick overview of all jobs in the system.
3
+ </purpose>
4
+
5
+ <context_tier>lite</context_tier>
6
+
7
+ <required_reading>
8
+ Read all files referenced by the invoking prompt's execution_context before starting.
9
+ </required_reading>
10
+
11
+ <process>
12
+
13
+ <step name="load_context" priority="first">
14
+ Load project context via tier system:
15
+
16
+ ```bash
17
+ TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier lite --raw 2>/dev/null)
18
+ ```
19
+
20
+ Use `TIER_FILES` JSON `files` array for project context (PROJECT.md, STATE.md, config.json).
21
+ </step>
22
+
23
+ <step name="fetch_jobs">
24
+ Run the list-jobs CLI command to get all jobs:
25
+
26
+ ```bash
27
+ RESULT=$(node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs jobs list-jobs)
28
+ ```
29
+
30
+ Parse the JSON result. The response contains three arrays at the top level:
31
+ ```json
32
+ {
33
+ "in_progress": [...],
34
+ "pending": [...],
35
+ "completed": [...]
36
+ }
37
+ ```
38
+
39
+ Each job object contains:
40
+ - `version`: The milestone version (e.g., "v6.0")
41
+ - `progress`: Progress fraction string (e.g., "4/12")
42
+ - `check`: Whether audit/complete steps are included
43
+ - `status`: Current status
44
+ </step>
45
+
46
+ <step name="display_results">
47
+ Format and display the results grouped by status.
48
+
49
+ **Display order:** In Progress first, then Pending, then Completed. Within each group, most recent first.
50
+
51
+ **If no jobs at all (total is 0):**
52
+ ```
53
+ No jobs found. Create one with /dgs:create-milestone-job
54
+ ```
55
+
56
+ **Otherwise, display each group:**
57
+
58
+ ```
59
+ ### In Progress
60
+
61
+ - **v6.0** -- 4/12 steps completed
62
+ - **v5.1** -- 2/8 steps completed (no-check)
63
+
64
+ ### Pending
65
+
66
+ - **v7.0** -- 0/15 steps completed
67
+
68
+ ### Completed
69
+
70
+ - **v5.0** -- 10/10 steps completed
71
+ ```
72
+
73
+ **Format rules:**
74
+ - Section headers: `### In Progress`, `### Pending`, `### Completed`
75
+ - Each job line: `- **{version}** -- {progress} steps completed`
76
+ - If `check` is false, append ` (no-check)` annotation
77
+ - If no jobs in a group, show: `(none)`
78
+ - No timing info in list view
79
+ </step>
80
+
81
+ </process>
82
+
83
+ <success_criteria>
84
+ - [ ] Jobs fetched via `dgs-tools.cjs jobs list-jobs` CLI call
85
+ - [ ] Results grouped by status: In Progress, Pending, Completed
86
+ - [ ] Each job shows version and progress fraction
87
+ - [ ] No-check jobs annotated
88
+ - [ ] Empty state shows helpful message with create command
89
+ </success_criteria>
@@ -0,0 +1,192 @@
1
+ <purpose>
2
+ Surface Claude's assumptions about a phase before planning, enabling users to correct misconceptions early.
3
+
4
+ Key difference from discuss-phase: This is ANALYSIS of what Claude thinks, not INTAKE of what user knows. No file output - purely conversational to prompt discussion.
5
+ </purpose>
6
+
7
+ <context_tier>planning</context_tier>
8
+
9
+ <process>
10
+
11
+ <step name="validate_phase" priority="first">
12
+ Phase number: $ARGUMENTS (required)
13
+
14
+ ```bash
15
+ INIT=$(node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs init phase-op "${PHASE}")
16
+ ```
17
+
18
+ Parse JSON for: `roadmap_path`, `phase_dir`, `phase_number`, `phase_name`.
19
+
20
+ Load planning-tier context files:
21
+
22
+ ```bash
23
+ TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier planning --raw 2>/dev/null)
24
+ ```
25
+
26
+ **If argument missing:**
27
+
28
+ ```
29
+ Error: Phase number required.
30
+
31
+ Usage: /dgs:list-phase-assumptions [phase-number]
32
+ Example: /dgs:list-phase-assumptions 3
33
+ ```
34
+
35
+ Exit workflow.
36
+
37
+ **If argument provided:**
38
+ Validate phase exists in roadmap:
39
+
40
+ ```bash
41
+ cat ${roadmap_path} | grep -i "Phase ${PHASE}"
42
+ ```
43
+
44
+ **If phase not found:**
45
+
46
+ ```
47
+ Error: Phase ${PHASE} not found in roadmap.
48
+
49
+ Available phases:
50
+ [list phases from roadmap]
51
+ ```
52
+
53
+ Exit workflow.
54
+
55
+ **If phase found:**
56
+ Parse phase details from roadmap:
57
+
58
+ - Phase number
59
+ - Phase name
60
+ - Phase description/goal
61
+ - Any scope details mentioned
62
+
63
+ Continue to analyze_phase.
64
+ </step>
65
+
66
+ <step name="analyze_phase">
67
+ Based on roadmap description and project context, identify assumptions across five areas:
68
+
69
+ **1. Technical Approach:**
70
+ What libraries, frameworks, patterns, or tools would Claude use?
71
+ - "I'd use X library because..."
72
+ - "I'd follow Y pattern because..."
73
+ - "I'd structure this as Z because..."
74
+
75
+ **2. Implementation Order:**
76
+ What would Claude build first, second, third?
77
+ - "I'd start with X because it's foundational"
78
+ - "Then Y because it depends on X"
79
+ - "Finally Z because..."
80
+
81
+ **3. Scope Boundaries:**
82
+ What's included vs excluded in Claude's interpretation?
83
+ - "This phase includes: A, B, C"
84
+ - "This phase does NOT include: D, E, F"
85
+ - "Boundary ambiguities: G could go either way"
86
+
87
+ **4. Risk Areas:**
88
+ Where does Claude expect complexity or challenges?
89
+ - "The tricky part is X because..."
90
+ - "Potential issues: Y, Z"
91
+ - "I'd watch out for..."
92
+
93
+ **5. Dependencies:**
94
+ What does Claude assume exists or needs to be in place?
95
+ - "This assumes X from previous phases"
96
+ - "External dependencies: Y, Z"
97
+ - "This will be consumed by..."
98
+
99
+ Be honest about uncertainty. Mark assumptions with confidence levels:
100
+ - "Fairly confident: ..." (clear from roadmap)
101
+ - "Assuming: ..." (reasonable inference)
102
+ - "Unclear: ..." (could go multiple ways)
103
+ </step>
104
+
105
+ <step name="present_assumptions">
106
+ Present assumptions in a clear, scannable format:
107
+
108
+ ```
109
+ ## My Assumptions for Phase ${PHASE}: ${PHASE_NAME}
110
+
111
+ ### Technical Approach
112
+ [List assumptions about how to implement]
113
+
114
+ ### Implementation Order
115
+ [List assumptions about sequencing]
116
+
117
+ ### Scope Boundaries
118
+ **In scope:** [what's included]
119
+ **Out of scope:** [what's excluded]
120
+ **Ambiguous:** [what could go either way]
121
+
122
+ ### Risk Areas
123
+ [List anticipated challenges]
124
+
125
+ ### Dependencies
126
+ **From prior phases:** [what's needed]
127
+ **External:** [third-party needs]
128
+ **Feeds into:** [what future phases need from this]
129
+
130
+ ---
131
+
132
+ **What do you think?**
133
+
134
+ Are these assumptions accurate? Let me know:
135
+ - What I got right
136
+ - What I got wrong
137
+ - What I'm missing
138
+ ```
139
+
140
+ Wait for user response.
141
+ </step>
142
+
143
+ <step name="gather_feedback">
144
+ **If user provides corrections:**
145
+
146
+ Acknowledge the corrections:
147
+
148
+ ```
149
+ Key corrections:
150
+ - [correction 1]
151
+ - [correction 2]
152
+
153
+ This changes my understanding significantly. [Summarize new understanding]
154
+ ```
155
+
156
+ **If user confirms assumptions:**
157
+
158
+ ```
159
+ Assumptions validated.
160
+ ```
161
+
162
+ Continue to offer_next.
163
+ </step>
164
+
165
+ <step name="offer_next">
166
+ Present next steps:
167
+
168
+ ```
169
+ What's next?
170
+ 1. Discuss context (/dgs:discuss-phase ${PHASE}) - Let me ask you questions to build comprehensive context
171
+ 2. Plan this phase (/dgs:plan-phase ${PHASE}) - Create detailed execution plans
172
+ 3. Re-examine assumptions - I'll analyze again with your corrections
173
+ 4. Done for now
174
+ ```
175
+
176
+ Wait for user selection.
177
+
178
+ If "Discuss context": Note that CONTEXT.md will incorporate any corrections discussed here
179
+ If "Plan this phase": Proceed knowing assumptions are understood
180
+ If "Re-examine": Return to analyze_phase with updated understanding
181
+ </step>
182
+
183
+ </process>
184
+
185
+ <success_criteria>
186
+ - Phase number validated against roadmap
187
+ - Assumptions surfaced across five areas: technical approach, implementation order, scope, risks, dependencies
188
+ - Confidence levels marked where appropriate
189
+ - "What do you think?" prompt presented
190
+ - User feedback acknowledged
191
+ - Clear next steps offered
192
+ </success_criteria>