@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,206 @@
1
+ # Architecture Research Template
2
+
3
+ Template for `research/ARCHITECTURE.md` (in planning root) — system structure patterns for the project domain.
4
+
5
+ > **Layout-agnostic:** The research directory lives at `research/` within the planning root. Workflows resolve the path via init output.
6
+
7
+ <template>
8
+
9
+ ```markdown
10
+ # Architecture Research
11
+
12
+ **Domain:** [domain type]
13
+ **Researched:** [date]
14
+ **Confidence:** [HIGH/MEDIUM/LOW]
15
+
16
+ ## Standard Architecture
17
+
18
+ ### System Overview
19
+
20
+ ```
21
+ ┌─────────────────────────────────────────────────────────────┐
22
+ │ [Layer Name] │
23
+ ├─────────────────────────────────────────────────────────────┤
24
+ │ ┌─────────┐ ┌─────────┐ ┌─────────┐ ┌─────────┐ │
25
+ │ │ [Comp] │ │ [Comp] │ │ [Comp] │ │ [Comp] │ │
26
+ │ └────┬────┘ └────┬────┘ └────┬────┘ └────┬────┘ │
27
+ │ │ │ │ │ │
28
+ ├───────┴────────────┴────────────┴────────────┴──────────────┤
29
+ │ [Layer Name] │
30
+ ├─────────────────────────────────────────────────────────────┤
31
+ │ ┌─────────────────────────────────────────────────────┐ │
32
+ │ │ [Component] │ │
33
+ │ └─────────────────────────────────────────────────────┘ │
34
+ ├─────────────────────────────────────────────────────────────┤
35
+ │ [Layer Name] │
36
+ │ ┌──────────┐ ┌──────────┐ ┌──────────┐ │
37
+ │ │ [Store] │ │ [Store] │ │ [Store] │ │
38
+ │ └──────────┘ └──────────┘ └──────────┘ │
39
+ └─────────────────────────────────────────────────────────────┘
40
+ ```
41
+
42
+ ### Component Responsibilities
43
+
44
+ | Component | Responsibility | Typical Implementation |
45
+ |-----------|----------------|------------------------|
46
+ | [name] | [what it owns] | [how it's usually built] |
47
+ | [name] | [what it owns] | [how it's usually built] |
48
+ | [name] | [what it owns] | [how it's usually built] |
49
+
50
+ ## Recommended Project Structure
51
+
52
+ ```
53
+ src/
54
+ ├── [folder]/ # [purpose]
55
+ │ ├── [subfolder]/ # [purpose]
56
+ │ └── [file].ts # [purpose]
57
+ ├── [folder]/ # [purpose]
58
+ │ ├── [subfolder]/ # [purpose]
59
+ │ └── [file].ts # [purpose]
60
+ ├── [folder]/ # [purpose]
61
+ └── [folder]/ # [purpose]
62
+ ```
63
+
64
+ ### Structure Rationale
65
+
66
+ - **[folder]/:** [why organized this way]
67
+ - **[folder]/:** [why organized this way]
68
+
69
+ ## Architectural Patterns
70
+
71
+ ### Pattern 1: [Pattern Name]
72
+
73
+ **What:** [description]
74
+ **When to use:** [conditions]
75
+ **Trade-offs:** [pros and cons]
76
+
77
+ **Example:**
78
+ ```typescript
79
+ // [Brief code example showing the pattern]
80
+ ```
81
+
82
+ ### Pattern 2: [Pattern Name]
83
+
84
+ **What:** [description]
85
+ **When to use:** [conditions]
86
+ **Trade-offs:** [pros and cons]
87
+
88
+ **Example:**
89
+ ```typescript
90
+ // [Brief code example showing the pattern]
91
+ ```
92
+
93
+ ### Pattern 3: [Pattern Name]
94
+
95
+ **What:** [description]
96
+ **When to use:** [conditions]
97
+ **Trade-offs:** [pros and cons]
98
+
99
+ ## Data Flow
100
+
101
+ ### Request Flow
102
+
103
+ ```
104
+ [User Action]
105
+
106
+ [Component] → [Handler] → [Service] → [Data Store]
107
+ ↓ ↓ ↓ ↓
108
+ [Response] ← [Transform] ← [Query] ← [Database]
109
+ ```
110
+
111
+ ### State Management
112
+
113
+ ```
114
+ [State Store]
115
+ ↓ (subscribe)
116
+ [Components] ←→ [Actions] → [Reducers/Mutations] → [State Store]
117
+ ```
118
+
119
+ ### Key Data Flows
120
+
121
+ 1. **[Flow name]:** [description of how data moves]
122
+ 2. **[Flow name]:** [description of how data moves]
123
+
124
+ ## Scaling Considerations
125
+
126
+ | Scale | Architecture Adjustments |
127
+ |-------|--------------------------|
128
+ | 0-1k users | [approach — usually monolith is fine] |
129
+ | 1k-100k users | [approach — what to optimize first] |
130
+ | 100k+ users | [approach — when to consider splitting] |
131
+
132
+ ### Scaling Priorities
133
+
134
+ 1. **First bottleneck:** [what breaks first, how to fix]
135
+ 2. **Second bottleneck:** [what breaks next, how to fix]
136
+
137
+ ## Anti-Patterns
138
+
139
+ ### Anti-Pattern 1: [Name]
140
+
141
+ **What people do:** [the mistake]
142
+ **Why it's wrong:** [the problem it causes]
143
+ **Do this instead:** [the correct approach]
144
+
145
+ ### Anti-Pattern 2: [Name]
146
+
147
+ **What people do:** [the mistake]
148
+ **Why it's wrong:** [the problem it causes]
149
+ **Do this instead:** [the correct approach]
150
+
151
+ ## Integration Points
152
+
153
+ ### External Services
154
+
155
+ | Service | Integration Pattern | Notes |
156
+ |---------|---------------------|-------|
157
+ | [service] | [how to connect] | [gotchas] |
158
+ | [service] | [how to connect] | [gotchas] |
159
+
160
+ ### Internal Boundaries
161
+
162
+ | Boundary | Communication | Notes |
163
+ |----------|---------------|-------|
164
+ | [module A ↔ module B] | [API/events/direct] | [considerations] |
165
+
166
+ ## Sources
167
+
168
+ - [Architecture references]
169
+ - [Official documentation]
170
+ - [Case studies]
171
+
172
+ ---
173
+ *Architecture research for: [domain]*
174
+ *Researched: [date]*
175
+ ```
176
+
177
+ </template>
178
+
179
+ <guidelines>
180
+
181
+ **System Overview:**
182
+ - Use ASCII box-drawing diagrams for clarity (├── └── │ ─ for structure visualization only)
183
+ - Show major components and their relationships
184
+ - Don't over-detail — this is conceptual, not implementation
185
+
186
+ **Project Structure:**
187
+ - Be specific about folder organization
188
+ - Explain the rationale for grouping
189
+ - Match conventions of the chosen stack
190
+
191
+ **Patterns:**
192
+ - Include code examples where helpful
193
+ - Explain trade-offs honestly
194
+ - Note when patterns are overkill for small projects
195
+
196
+ **Scaling Considerations:**
197
+ - Be realistic — most projects don't need to scale to millions
198
+ - Focus on "what breaks first" not theoretical limits
199
+ - Avoid premature optimization recommendations
200
+
201
+ **Anti-Patterns:**
202
+ - Specific to this domain
203
+ - Include what to do instead
204
+ - Helps prevent common mistakes during implementation
205
+
206
+ </guidelines>
@@ -0,0 +1,149 @@
1
+ # Features Research Template
2
+
3
+ Template for `research/FEATURES.md` (in planning root) — feature landscape for the project domain.
4
+
5
+ > **Layout-agnostic:** The research directory lives at `research/` within the planning root. Workflows resolve the path via init output.
6
+
7
+ <template>
8
+
9
+ ```markdown
10
+ # Feature Research
11
+
12
+ **Domain:** [domain type]
13
+ **Researched:** [date]
14
+ **Confidence:** [HIGH/MEDIUM/LOW]
15
+
16
+ ## Feature Landscape
17
+
18
+ ### Table Stakes (Users Expect These)
19
+
20
+ Features users assume exist. Missing these = product feels incomplete.
21
+
22
+ | Feature | Why Expected | Complexity | Notes |
23
+ |---------|--------------|------------|-------|
24
+ | [feature] | [user expectation] | LOW/MEDIUM/HIGH | [implementation notes] |
25
+ | [feature] | [user expectation] | LOW/MEDIUM/HIGH | [implementation notes] |
26
+ | [feature] | [user expectation] | LOW/MEDIUM/HIGH | [implementation notes] |
27
+
28
+ ### Differentiators (Competitive Advantage)
29
+
30
+ Features that set the product apart. Not required, but valuable.
31
+
32
+ | Feature | Value Proposition | Complexity | Notes |
33
+ |---------|-------------------|------------|-------|
34
+ | [feature] | [why it matters] | LOW/MEDIUM/HIGH | [implementation notes] |
35
+ | [feature] | [why it matters] | LOW/MEDIUM/HIGH | [implementation notes] |
36
+ | [feature] | [why it matters] | LOW/MEDIUM/HIGH | [implementation notes] |
37
+
38
+ ### Anti-Features (Commonly Requested, Often Problematic)
39
+
40
+ Features that seem good but create problems.
41
+
42
+ | Feature | Why Requested | Why Problematic | Alternative |
43
+ |---------|---------------|-----------------|-------------|
44
+ | [feature] | [surface appeal] | [actual problems] | [better approach] |
45
+ | [feature] | [surface appeal] | [actual problems] | [better approach] |
46
+
47
+ ## Feature Dependencies
48
+
49
+ ```
50
+ [Feature A]
51
+ └──requires──> [Feature B]
52
+ └──requires──> [Feature C]
53
+
54
+ [Feature D] ──enhances──> [Feature A]
55
+
56
+ [Feature E] ──conflicts──> [Feature F]
57
+ ```
58
+
59
+ ### Dependency Notes
60
+
61
+ - **[Feature A] requires [Feature B]:** [why the dependency exists]
62
+ - **[Feature D] enhances [Feature A]:** [how they work together]
63
+ - **[Feature E] conflicts with [Feature F]:** [why they're incompatible]
64
+
65
+ ## MVP Definition
66
+
67
+ ### Launch With (v1)
68
+
69
+ Minimum viable product — what's needed to validate the concept.
70
+
71
+ - [ ] [Feature] — [why essential]
72
+ - [ ] [Feature] — [why essential]
73
+ - [ ] [Feature] — [why essential]
74
+
75
+ ### Add After Validation (v1.x)
76
+
77
+ Features to add once core is working.
78
+
79
+ - [ ] [Feature] — [trigger for adding]
80
+ - [ ] [Feature] — [trigger for adding]
81
+
82
+ ### Future Consideration (v2+)
83
+
84
+ Features to defer until product-market fit is established.
85
+
86
+ - [ ] [Feature] — [why defer]
87
+ - [ ] [Feature] — [why defer]
88
+
89
+ ## Feature Prioritization Matrix
90
+
91
+ | Feature | User Value | Implementation Cost | Priority |
92
+ |---------|------------|---------------------|----------|
93
+ | [feature] | HIGH/MEDIUM/LOW | HIGH/MEDIUM/LOW | P1/P2/P3 |
94
+ | [feature] | HIGH/MEDIUM/LOW | HIGH/MEDIUM/LOW | P1/P2/P3 |
95
+ | [feature] | HIGH/MEDIUM/LOW | HIGH/MEDIUM/LOW | P1/P2/P3 |
96
+
97
+ **Priority key:**
98
+ - P1: Must have for launch
99
+ - P2: Should have, add when possible
100
+ - P3: Nice to have, future consideration
101
+
102
+ ## Competitor Feature Analysis
103
+
104
+ | Feature | Competitor A | Competitor B | Our Approach |
105
+ |---------|--------------|--------------|--------------|
106
+ | [feature] | [how they do it] | [how they do it] | [our plan] |
107
+ | [feature] | [how they do it] | [how they do it] | [our plan] |
108
+
109
+ ## Sources
110
+
111
+ - [Competitor products analyzed]
112
+ - [User research or feedback sources]
113
+ - [Industry standards referenced]
114
+
115
+ ---
116
+ *Feature research for: [domain]*
117
+ *Researched: [date]*
118
+ ```
119
+
120
+ </template>
121
+
122
+ <guidelines>
123
+
124
+ **Table Stakes:**
125
+ - These are non-negotiable for launch
126
+ - Users don't give credit for having them, but penalize for missing them
127
+ - Example: A community platform without user profiles is broken
128
+
129
+ **Differentiators:**
130
+ - These are where you compete
131
+ - Should align with the Core Value from PROJECT.md
132
+ - Don't try to differentiate on everything
133
+
134
+ **Anti-Features:**
135
+ - Prevent scope creep by documenting what seems good but isn't
136
+ - Include the alternative approach
137
+ - Example: "Real-time everything" often creates complexity without value
138
+
139
+ **Feature Dependencies:**
140
+ - Critical for roadmap phase ordering
141
+ - If A requires B, B must be in an earlier phase
142
+ - Conflicts inform what NOT to combine in same phase
143
+
144
+ **MVP Definition:**
145
+ - Be ruthless about what's truly minimum
146
+ - "Nice to have" is not MVP
147
+ - Launch with less, validate, then expand
148
+
149
+ </guidelines>
@@ -0,0 +1,202 @@
1
+ # Pitfalls Research Template
2
+
3
+ Template for `research/PITFALLS.md` (in planning root) — common mistakes to avoid in the project domain.
4
+
5
+ > **Layout-agnostic:** The research directory lives at `research/` within the planning root. Workflows resolve the path via init output.
6
+
7
+ <template>
8
+
9
+ ```markdown
10
+ # Pitfalls Research
11
+
12
+ **Domain:** [domain type]
13
+ **Researched:** [date]
14
+ **Confidence:** [HIGH/MEDIUM/LOW]
15
+
16
+ ## Critical Pitfalls
17
+
18
+ ### Pitfall 1: [Name]
19
+
20
+ **What goes wrong:**
21
+ [Description of the failure mode]
22
+
23
+ **Why it happens:**
24
+ [Root cause — why developers make this mistake]
25
+
26
+ **How to avoid:**
27
+ [Specific prevention strategy]
28
+
29
+ **Warning signs:**
30
+ [How to detect this early before it becomes a problem]
31
+
32
+ **Phase to address:**
33
+ [Which roadmap phase should prevent this]
34
+
35
+ ---
36
+
37
+ ### Pitfall 2: [Name]
38
+
39
+ **What goes wrong:**
40
+ [Description of the failure mode]
41
+
42
+ **Why it happens:**
43
+ [Root cause — why developers make this mistake]
44
+
45
+ **How to avoid:**
46
+ [Specific prevention strategy]
47
+
48
+ **Warning signs:**
49
+ [How to detect this early before it becomes a problem]
50
+
51
+ **Phase to address:**
52
+ [Which roadmap phase should prevent this]
53
+
54
+ ---
55
+
56
+ ### Pitfall 3: [Name]
57
+
58
+ **What goes wrong:**
59
+ [Description of the failure mode]
60
+
61
+ **Why it happens:**
62
+ [Root cause — why developers make this mistake]
63
+
64
+ **How to avoid:**
65
+ [Specific prevention strategy]
66
+
67
+ **Warning signs:**
68
+ [How to detect this early before it becomes a problem]
69
+
70
+ **Phase to address:**
71
+ [Which roadmap phase should prevent this]
72
+
73
+ ---
74
+
75
+ [Continue for all critical pitfalls...]
76
+
77
+ ## Technical Debt Patterns
78
+
79
+ Shortcuts that seem reasonable but create long-term problems.
80
+
81
+ | Shortcut | Immediate Benefit | Long-term Cost | When Acceptable |
82
+ |----------|-------------------|----------------|-----------------|
83
+ | [shortcut] | [benefit] | [cost] | [conditions, or "never"] |
84
+ | [shortcut] | [benefit] | [cost] | [conditions, or "never"] |
85
+ | [shortcut] | [benefit] | [cost] | [conditions, or "never"] |
86
+
87
+ ## Integration Gotchas
88
+
89
+ Common mistakes when connecting to external services.
90
+
91
+ | Integration | Common Mistake | Correct Approach |
92
+ |-------------|----------------|------------------|
93
+ | [service] | [what people do wrong] | [what to do instead] |
94
+ | [service] | [what people do wrong] | [what to do instead] |
95
+ | [service] | [what people do wrong] | [what to do instead] |
96
+
97
+ ## Performance Traps
98
+
99
+ Patterns that work at small scale but fail as usage grows.
100
+
101
+ | Trap | Symptoms | Prevention | When It Breaks |
102
+ |------|----------|------------|----------------|
103
+ | [trap] | [how you notice] | [how to avoid] | [scale threshold] |
104
+ | [trap] | [how you notice] | [how to avoid] | [scale threshold] |
105
+ | [trap] | [how you notice] | [how to avoid] | [scale threshold] |
106
+
107
+ ## Security Mistakes
108
+
109
+ Domain-specific security issues beyond general web security.
110
+
111
+ | Mistake | Risk | Prevention |
112
+ |---------|------|------------|
113
+ | [mistake] | [what could happen] | [how to avoid] |
114
+ | [mistake] | [what could happen] | [how to avoid] |
115
+ | [mistake] | [what could happen] | [how to avoid] |
116
+
117
+ ## UX Pitfalls
118
+
119
+ Common user experience mistakes in this domain.
120
+
121
+ | Pitfall | User Impact | Better Approach |
122
+ |---------|-------------|-----------------|
123
+ | [pitfall] | [how users suffer] | [what to do instead] |
124
+ | [pitfall] | [how users suffer] | [what to do instead] |
125
+ | [pitfall] | [how users suffer] | [what to do instead] |
126
+
127
+ ## "Looks Done But Isn't" Checklist
128
+
129
+ Things that appear complete but are missing critical pieces.
130
+
131
+ - [ ] **[Feature]:** Often missing [thing] — verify [check]
132
+ - [ ] **[Feature]:** Often missing [thing] — verify [check]
133
+ - [ ] **[Feature]:** Often missing [thing] — verify [check]
134
+ - [ ] **[Feature]:** Often missing [thing] — verify [check]
135
+
136
+ ## Recovery Strategies
137
+
138
+ When pitfalls occur despite prevention, how to recover.
139
+
140
+ | Pitfall | Recovery Cost | Recovery Steps |
141
+ |---------|---------------|----------------|
142
+ | [pitfall] | LOW/MEDIUM/HIGH | [what to do] |
143
+ | [pitfall] | LOW/MEDIUM/HIGH | [what to do] |
144
+ | [pitfall] | LOW/MEDIUM/HIGH | [what to do] |
145
+
146
+ ## Pitfall-to-Phase Mapping
147
+
148
+ How roadmap phases should address these pitfalls.
149
+
150
+ | Pitfall | Prevention Phase | Verification |
151
+ |---------|------------------|--------------|
152
+ | [pitfall] | Phase [X] | [how to verify prevention worked] |
153
+ | [pitfall] | Phase [X] | [how to verify prevention worked] |
154
+ | [pitfall] | Phase [X] | [how to verify prevention worked] |
155
+
156
+ ## Sources
157
+
158
+ - [Post-mortems referenced]
159
+ - [Community discussions]
160
+ - [Official "gotchas" documentation]
161
+ - [Personal experience / known issues]
162
+
163
+ ---
164
+ *Pitfalls research for: [domain]*
165
+ *Researched: [date]*
166
+ ```
167
+
168
+ </template>
169
+
170
+ <guidelines>
171
+
172
+ **Critical Pitfalls:**
173
+ - Focus on domain-specific issues, not generic mistakes
174
+ - Include warning signs — early detection prevents disasters
175
+ - Link to specific phases — makes pitfalls actionable
176
+
177
+ **Technical Debt:**
178
+ - Be realistic — some shortcuts are acceptable
179
+ - Note when shortcuts are "never acceptable" vs. "only in MVP"
180
+ - Include the long-term cost to inform tradeoff decisions
181
+
182
+ **Performance Traps:**
183
+ - Include scale thresholds ("breaks at 10k users")
184
+ - Focus on what's relevant for this project's expected scale
185
+ - Don't over-engineer for hypothetical scale
186
+
187
+ **Security Mistakes:**
188
+ - Beyond OWASP basics — domain-specific issues
189
+ - Example: Community platforms have different security concerns than e-commerce
190
+ - Include risk level to prioritize
191
+
192
+ **"Looks Done But Isn't":**
193
+ - Checklist format for verification during execution
194
+ - Common in demos vs. production
195
+ - Prevents "it works on my machine" issues
196
+
197
+ **Pitfall-to-Phase Mapping:**
198
+ - Critical for roadmap creation
199
+ - Each pitfall should map to a phase that prevents it
200
+ - Informs phase ordering and success criteria
201
+
202
+ </guidelines>
@@ -0,0 +1,122 @@
1
+ # Stack Research Template
2
+
3
+ Template for `research/STACK.md` (in planning root) — recommended technologies for the project domain.
4
+
5
+ > **Layout-agnostic:** The research directory lives at `research/` within the planning root. Workflows resolve the path via init output.
6
+
7
+ <template>
8
+
9
+ ```markdown
10
+ # Stack Research
11
+
12
+ **Domain:** [domain type]
13
+ **Researched:** [date]
14
+ **Confidence:** [HIGH/MEDIUM/LOW]
15
+
16
+ ## Recommended Stack
17
+
18
+ ### Core Technologies
19
+
20
+ | Technology | Version | Purpose | Why Recommended |
21
+ |------------|---------|---------|-----------------|
22
+ | [name] | [version] | [what it does] | [why experts use it for this domain] |
23
+ | [name] | [version] | [what it does] | [why experts use it for this domain] |
24
+ | [name] | [version] | [what it does] | [why experts use it for this domain] |
25
+
26
+ ### Supporting Libraries
27
+
28
+ | Library | Version | Purpose | When to Use |
29
+ |---------|---------|---------|-------------|
30
+ | [name] | [version] | [what it does] | [specific use case] |
31
+ | [name] | [version] | [what it does] | [specific use case] |
32
+ | [name] | [version] | [what it does] | [specific use case] |
33
+
34
+ ### Development Tools
35
+
36
+ | Tool | Purpose | Notes |
37
+ |------|---------|-------|
38
+ | [name] | [what it does] | [configuration tips] |
39
+ | [name] | [what it does] | [configuration tips] |
40
+
41
+ ## Installation
42
+
43
+ ```bash
44
+ # Core
45
+ npm install [packages]
46
+
47
+ # Supporting
48
+ npm install [packages]
49
+
50
+ # Dev dependencies
51
+ npm install -D [packages]
52
+ ```
53
+
54
+ ## Alternatives Considered
55
+
56
+ | Recommended | Alternative | When to Use Alternative |
57
+ |-------------|-------------|-------------------------|
58
+ | [our choice] | [other option] | [conditions where alternative is better] |
59
+ | [our choice] | [other option] | [conditions where alternative is better] |
60
+
61
+ ## What NOT to Use
62
+
63
+ | Avoid | Why | Use Instead |
64
+ |-------|-----|-------------|
65
+ | [technology] | [specific problem] | [recommended alternative] |
66
+ | [technology] | [specific problem] | [recommended alternative] |
67
+
68
+ ## Stack Patterns by Variant
69
+
70
+ **If [condition]:**
71
+ - Use [variation]
72
+ - Because [reason]
73
+
74
+ **If [condition]:**
75
+ - Use [variation]
76
+ - Because [reason]
77
+
78
+ ## Version Compatibility
79
+
80
+ | Package A | Compatible With | Notes |
81
+ |-----------|-----------------|-------|
82
+ | [package@version] | [package@version] | [compatibility notes] |
83
+
84
+ ## Sources
85
+
86
+ - [Context7 library ID] — [topics fetched]
87
+ - [Official docs URL] — [what was verified]
88
+ - [Other source] — [confidence level]
89
+
90
+ ---
91
+ *Stack research for: [domain]*
92
+ *Researched: [date]*
93
+ ```
94
+
95
+ </template>
96
+
97
+ <guidelines>
98
+
99
+ **Core Technologies:**
100
+ - Include specific version numbers
101
+ - Explain why this is the standard choice, not just what it does
102
+ - Focus on technologies that affect architecture decisions
103
+
104
+ **Supporting Libraries:**
105
+ - Include libraries commonly needed for this domain
106
+ - Note when each is needed (not all projects need all libraries)
107
+
108
+ **Alternatives:**
109
+ - Don't just dismiss alternatives
110
+ - Explain when alternatives make sense
111
+ - Helps user make informed decisions if they disagree
112
+
113
+ **What NOT to Use:**
114
+ - Actively warn against outdated or problematic choices
115
+ - Explain the specific problem, not just "it's old"
116
+ - Provide the recommended alternative
117
+
118
+ **Version Compatibility:**
119
+ - Note any known compatibility issues
120
+ - Critical for avoiding debugging time later
121
+
122
+ </guidelines>