gsdd-cli 0.18.4 → 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (100) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +625 -607
  3. package/agents/DISTILLATION.md +421 -421
  4. package/agents/README.md +62 -62
  5. package/agents/approach-explorer.md +361 -361
  6. package/agents/debugger.md +82 -82
  7. package/agents/executor.md +394 -394
  8. package/agents/integration-checker.md +318 -318
  9. package/agents/mapper.md +103 -103
  10. package/agents/planner.md +313 -313
  11. package/agents/researcher.md +84 -84
  12. package/agents/roadmapper.md +296 -296
  13. package/agents/synthesizer.md +236 -236
  14. package/agents/verifier.md +337 -337
  15. package/bin/adapters/agents.mjs +34 -34
  16. package/bin/adapters/claude.mjs +191 -191
  17. package/bin/adapters/codex.mjs +85 -85
  18. package/bin/adapters/index.mjs +20 -20
  19. package/bin/adapters/opencode.mjs +278 -278
  20. package/bin/gsdd.mjs +123 -116
  21. package/bin/lib/cli-utils.mjs +28 -28
  22. package/bin/lib/evidence-contract.mjs +112 -112
  23. package/bin/lib/file-ops.mjs +209 -161
  24. package/bin/lib/health-truth.mjs +181 -178
  25. package/bin/lib/health.mjs +265 -235
  26. package/bin/lib/init-flow.mjs +252 -236
  27. package/bin/lib/init-prompts.mjs +248 -247
  28. package/bin/lib/init-runtime.mjs +225 -212
  29. package/bin/lib/init.mjs +17 -17
  30. package/bin/lib/lifecycle-preflight.mjs +360 -333
  31. package/bin/lib/lifecycle-state.mjs +351 -267
  32. package/bin/lib/manifest.mjs +116 -114
  33. package/bin/lib/models.mjs +411 -411
  34. package/bin/lib/phase.mjs +397 -378
  35. package/bin/lib/plan-constants.mjs +30 -30
  36. package/bin/lib/provenance.mjs +109 -106
  37. package/bin/lib/rendering.mjs +178 -130
  38. package/bin/lib/runtime-freshness.mjs +221 -219
  39. package/bin/lib/templates.mjs +225 -224
  40. package/bin/lib/workspace-root.mjs +132 -0
  41. package/distilled/DESIGN.md +2347 -2327
  42. package/distilled/EVIDENCE-INDEX.md +397 -394
  43. package/distilled/README.md +196 -193
  44. package/distilled/SKILL.md +86 -85
  45. package/distilled/templates/agents.block.md +21 -21
  46. package/distilled/templates/agents.md +6 -6
  47. package/distilled/templates/approach.md +232 -232
  48. package/distilled/templates/auth-matrix.md +78 -78
  49. package/distilled/templates/brownfield-change/CHANGE.md +99 -0
  50. package/distilled/templates/brownfield-change/HANDOFF.md +38 -0
  51. package/distilled/templates/brownfield-change/VERIFICATION.md +56 -0
  52. package/distilled/templates/codebase/architecture.md +110 -110
  53. package/distilled/templates/codebase/concerns.md +95 -95
  54. package/distilled/templates/codebase/conventions.md +193 -193
  55. package/distilled/templates/codebase/stack.md +96 -96
  56. package/distilled/templates/delegates/approach-explorer.md +25 -25
  57. package/distilled/templates/delegates/mapper-arch.md +26 -26
  58. package/distilled/templates/delegates/mapper-concerns.md +27 -27
  59. package/distilled/templates/delegates/mapper-quality.md +28 -28
  60. package/distilled/templates/delegates/mapper-tech.md +25 -25
  61. package/distilled/templates/delegates/plan-checker.md +68 -68
  62. package/distilled/templates/delegates/researcher-architecture.md +30 -30
  63. package/distilled/templates/delegates/researcher-features.md +30 -30
  64. package/distilled/templates/delegates/researcher-pitfalls.md +30 -30
  65. package/distilled/templates/delegates/researcher-stack.md +30 -30
  66. package/distilled/templates/delegates/researcher-synthesizer.md +31 -31
  67. package/distilled/templates/research/architecture.md +57 -57
  68. package/distilled/templates/research/features.md +23 -23
  69. package/distilled/templates/research/pitfalls.md +46 -46
  70. package/distilled/templates/research/stack.md +45 -45
  71. package/distilled/templates/research/summary.md +67 -67
  72. package/distilled/templates/roadmap.md +74 -62
  73. package/distilled/templates/spec.md +110 -110
  74. package/distilled/workflows/audit-milestone.md +275 -271
  75. package/distilled/workflows/complete-milestone.md +336 -332
  76. package/distilled/workflows/execute.md +454 -449
  77. package/distilled/workflows/map-codebase.md +253 -253
  78. package/distilled/workflows/new-milestone.md +242 -238
  79. package/distilled/workflows/new-project.md +398 -398
  80. package/distilled/workflows/pause.md +160 -156
  81. package/distilled/workflows/plan-milestone-gaps.md +183 -183
  82. package/distilled/workflows/plan.md +451 -447
  83. package/distilled/workflows/progress.md +227 -223
  84. package/distilled/workflows/quick.md +351 -347
  85. package/distilled/workflows/resume.md +220 -212
  86. package/distilled/workflows/verify-work.md +260 -260
  87. package/distilled/workflows/verify.md +431 -429
  88. package/docs/BROWNFIELD-PROOF.md +95 -95
  89. package/docs/RUNTIME-SUPPORT.md +93 -75
  90. package/docs/USER-GUIDE.md +440 -399
  91. package/docs/VERIFICATION-DISCIPLINE.md +59 -59
  92. package/docs/claude/context-monitor.md +98 -98
  93. package/docs/proof/consumer-node-cli/README.md +37 -37
  94. package/docs/proof/consumer-node-cli/ROADMAP.md +14 -14
  95. package/docs/proof/consumer-node-cli/SPEC.md +17 -17
  96. package/docs/proof/consumer-node-cli/brief.md +9 -9
  97. package/docs/proof/consumer-node-cli/phases/01-foundation/01-01-PLAN.md +34 -34
  98. package/docs/proof/consumer-node-cli/phases/01-foundation/01-01-SUMMARY.md +10 -10
  99. package/docs/proof/consumer-node-cli/phases/01-foundation/01-VERIFICATION.md +30 -30
  100. package/package.json +62 -61
@@ -1,26 +1,26 @@
1
- **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- Map the architecture and structure of this codebase. Read key source files to understand component boundaries, data flow, and patterns.
4
-
5
- Write ARCHITECTURE.md to `.planning/codebase/` using the template at `.planning/templates/codebase/architecture.md`.
6
-
7
- Include:
8
- - Major components and their responsibilities (what belongs in each, what doesn't)
9
- - Data flow direction (not just "they communicate" — which way does data move)
10
- - "Change Routing" table: where to add new code by change type (new endpoint? new model? new UI component?)
11
- - Key architectural patterns used (e.g., event-driven, layered, modular monolith)
12
- - Golden files per layer: for each major layer, the single most-imported file (highest inbound import count = most stable, most understood); use import frequency as the signal, not judgment
13
-
14
- **Anti-staleness:** Do NOT include static directory trees or full file inventories. DO include file paths for key components, entry points, and architectural boundaries (e.g., `src/services/user.ts`) -- downstream agents navigate directly to files.
15
-
16
- <quality_gate>
17
- - [ ] Components have clear responsibility boundaries
18
- - [ ] Data flow direction is explicit
19
- - [ ] Change Routing table is populated (where to add new code by type)
20
- - [ ] Hard-to-reverse architectural decisions flagged
21
- - [ ] Golden files table populated with at least one file per major layer
22
- </quality_gate>
23
-
24
- Write to: `.planning/codebase/ARCHITECTURE.md`
25
- Return: 3-5 sentence summary to the Orchestrator when done.
26
- Guardrails: Max Agent Hops = 3. No static directory dumps.
1
+ **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ Map the architecture and structure of this codebase. Read key source files to understand component boundaries, data flow, and patterns.
4
+
5
+ Write ARCHITECTURE.md to `.planning/codebase/` using the template at `.planning/templates/codebase/architecture.md`.
6
+
7
+ Include:
8
+ - Major components and their responsibilities (what belongs in each, what doesn't)
9
+ - Data flow direction (not just "they communicate" — which way does data move)
10
+ - "Change Routing" table: where to add new code by change type (new endpoint? new model? new UI component?)
11
+ - Key architectural patterns used (e.g., event-driven, layered, modular monolith)
12
+ - Golden files per layer: for each major layer, the single most-imported file (highest inbound import count = most stable, most understood); use import frequency as the signal, not judgment
13
+
14
+ **Anti-staleness:** Do NOT include static directory trees or full file inventories. DO include file paths for key components, entry points, and architectural boundaries (e.g., `src/services/user.ts`) -- downstream agents navigate directly to files.
15
+
16
+ <quality_gate>
17
+ - [ ] Components have clear responsibility boundaries
18
+ - [ ] Data flow direction is explicit
19
+ - [ ] Change Routing table is populated (where to add new code by type)
20
+ - [ ] Hard-to-reverse architectural decisions flagged
21
+ - [ ] Golden files table populated with at least one file per major layer
22
+ </quality_gate>
23
+
24
+ Write to: `.planning/codebase/ARCHITECTURE.md`
25
+ Return: 3-5 sentence summary to the Orchestrator when done.
26
+ Guardrails: Max Agent Hops = 3. No static directory dumps.
@@ -1,27 +1,27 @@
1
- **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- Map the technical debt, security concerns, and risks in this codebase.
4
-
5
- **Security check first (hard stop):** Follow the Hard stop directive in `.planning/templates/roles/mapper.md` — grep for secrets before writing anything. If found: STOP and report to Orchestrator immediately.
6
-
7
- If no secrets found, write CONCERNS.md to `.planning/codebase/` using the template at `.planning/templates/codebase/concerns.md`.
8
-
9
- Include:
10
- - Known bugs or fragile areas (with file references where possible)
11
- - Security vulnerabilities or missing validations
12
- - Performance bottlenecks
13
- - Missing test coverage for critical paths
14
- - Deprecated or end-of-life dependencies
15
- - Downstream impact ranking: top 3 concerns ranked by how much future work they block (concerns blocking multiple change-routing rows from ARCHITECTURE.md rank highest, not just by severity)
16
-
17
- <quality_gate>
18
- - [ ] Secret scan completed and result reported
19
- - [ ] Concerns are specific (file references, not vague "some places")
20
- - [ ] Severity assigned per concern: critical / moderate / minor
21
- - [ ] Deprecated dependencies listed with EOL dates if known
22
- - [ ] Downstream impact table ranks at least top 3 concerns with Blocks column populated
23
- </quality_gate>
24
-
25
- Write to: `.planning/codebase/CONCERNS.md`
26
- Return: 3-5 sentence summary to the Orchestrator when done. If secrets found, STOP and report immediately.
27
- Guardrails: Max Agent Hops = 3. Hard stop on secrets.
1
+ **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ Map the technical debt, security concerns, and risks in this codebase.
4
+
5
+ **Security check first (hard stop):** Follow the Hard stop directive in `.planning/templates/roles/mapper.md` — grep for secrets before writing anything. If found: STOP and report to Orchestrator immediately.
6
+
7
+ If no secrets found, write CONCERNS.md to `.planning/codebase/` using the template at `.planning/templates/codebase/concerns.md`.
8
+
9
+ Include:
10
+ - Known bugs or fragile areas (with file references where possible)
11
+ - Security vulnerabilities or missing validations
12
+ - Performance bottlenecks
13
+ - Missing test coverage for critical paths
14
+ - Deprecated or end-of-life dependencies
15
+ - Downstream impact ranking: top 3 concerns ranked by how much future work they block (concerns blocking multiple change-routing rows from ARCHITECTURE.md rank highest, not just by severity)
16
+
17
+ <quality_gate>
18
+ - [ ] Secret scan completed and result reported
19
+ - [ ] Concerns are specific (file references, not vague "some places")
20
+ - [ ] Severity assigned per concern: critical / moderate / minor
21
+ - [ ] Deprecated dependencies listed with EOL dates if known
22
+ - [ ] Downstream impact table ranks at least top 3 concerns with Blocks column populated
23
+ </quality_gate>
24
+
25
+ Write to: `.planning/codebase/CONCERNS.md`
26
+ Return: 3-5 sentence summary to the Orchestrator when done. If secrets found, STOP and report immediately.
27
+ Guardrails: Max Agent Hops = 3. Hard stop on secrets.
@@ -1,28 +1,28 @@
1
- **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- Map the conventions and quality patterns of this codebase. Read existing tests, lint config, and code samples.
4
-
5
- Write CONVENTIONS.md to `.planning/codebase/` using the template at `.planning/templates/codebase/conventions.md`.
6
-
7
- Include:
8
- - Naming patterns (files, functions, variables, exports)
9
- - Code style rules enforced by lint/format config
10
- - Testing and mocking boundaries — explicit "Do mock" / "Do NOT mock" rules with examples
11
- - External integration patterns: webhook signature verification, auth session management, environment config
12
- - CI reliability rules (what must pass before merge)
13
- - Convention adoption rates: for each major convention, estimate `~N% (stable|rising|declining)` using grep-counting (≥5 occurrences required; below that write "prevalence unknown — seen in multiple files")
14
- - Golden files: 2–3 production files with the highest density of documented conventions (not scaffolding, not generated, not tests); format: `file path — which conventions it demonstrates`
15
-
16
- **Anti-staleness:** Do NOT enumerate test files or list every convention observed. Document rules and patterns: the invariants, not the inventory.
17
-
18
- <quality_gate>
19
- - [ ] Mocking boundaries are explicit ("Do mock: X" / "Do NOT mock: Y")
20
- - [ ] External integration security rules included (webhook, auth, env config)
21
- - [ ] Rules are actionable ("always do X"), not descriptive ("the codebase uses X")
22
- - [ ] At least one convention has a quantified adoption rate (e.g., `~N% (stable|rising|declining)`)
23
- - [ ] Golden files section lists at least 2 files with rationale
24
- </quality_gate>
25
-
26
- Write to: `.planning/codebase/CONVENTIONS.md`
27
- Return: 3-5 sentence summary to the Orchestrator when done.
28
- Guardrails: Max Agent Hops = 3. Rules not inventories.
1
+ **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ Map the conventions and quality patterns of this codebase. Read existing tests, lint config, and code samples.
4
+
5
+ Write CONVENTIONS.md to `.planning/codebase/` using the template at `.planning/templates/codebase/conventions.md`.
6
+
7
+ Include:
8
+ - Naming patterns (files, functions, variables, exports)
9
+ - Code style rules enforced by lint/format config
10
+ - Testing and mocking boundaries — explicit "Do mock" / "Do NOT mock" rules with examples
11
+ - External integration patterns: webhook signature verification, auth session management, environment config
12
+ - CI reliability rules (what must pass before merge)
13
+ - Convention adoption rates: for each major convention, estimate `~N% (stable|rising|declining)` using grep-counting (≥5 occurrences required; below that write "prevalence unknown — seen in multiple files")
14
+ - Golden files: 2–3 production files with the highest density of documented conventions (not scaffolding, not generated, not tests); format: `file path — which conventions it demonstrates`
15
+
16
+ **Anti-staleness:** Do NOT enumerate test files or list every convention observed. Document rules and patterns: the invariants, not the inventory.
17
+
18
+ <quality_gate>
19
+ - [ ] Mocking boundaries are explicit ("Do mock: X" / "Do NOT mock: Y")
20
+ - [ ] External integration security rules included (webhook, auth, env config)
21
+ - [ ] Rules are actionable ("always do X"), not descriptive ("the codebase uses X")
22
+ - [ ] At least one convention has a quantified adoption rate (e.g., `~N% (stable|rising|declining)`)
23
+ - [ ] Golden files section lists at least 2 files with rationale
24
+ </quality_gate>
25
+
26
+ Write to: `.planning/codebase/CONVENTIONS.md`
27
+ Return: 3-5 sentence summary to the Orchestrator when done.
28
+ Guardrails: Max Agent Hops = 3. Rules not inventories.
@@ -1,25 +1,25 @@
1
- **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- Map the technology stack of this codebase. Read package manifests, lockfiles, and entry points.
4
-
5
- Write STACK.md to `.planning/codebase/` using the template at `.planning/templates/codebase/stack.md`.
6
-
7
- Include:
8
- - Languages and runtimes (with versions)
9
- - Frameworks and key libraries (10-20 most important, not the full lockfile)
10
- - Infrastructure and deployment tooling
11
- - For each package: why it matters to this project (not just what it is)
12
- - Must-know packages: 3–5 packages where misuse causes the hardest-to-debug problems; include risk index (low/medium/high) and the common mistake to avoid
13
-
14
- **Anti-staleness:** Do NOT dump the full lockfile or dependency tree. Include only packages with architectural significance and note why they matter.
15
-
16
- <quality_gate>
17
- - [ ] 10-20 packages listed with version + rationale (not a lockfile dump)
18
- - [ ] Build/deploy tooling included
19
- - [ ] Any deprecated or risky dependencies flagged
20
- - [ ] Must-know packages section identifies at least 3 packages with risk index (low/medium/high)
21
- </quality_gate>
22
-
23
- Write to: `.planning/codebase/STACK.md`
24
- Return: 3-5 sentence summary to the Orchestrator when done.
25
- Guardrails: Max Agent Hops = 3. No static dependency dumps.
1
+ **Role contract:** Read `.planning/templates/roles/mapper.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ Map the technology stack of this codebase. Read package manifests, lockfiles, and entry points.
4
+
5
+ Write STACK.md to `.planning/codebase/` using the template at `.planning/templates/codebase/stack.md`.
6
+
7
+ Include:
8
+ - Languages and runtimes (with versions)
9
+ - Frameworks and key libraries (10-20 most important, not the full lockfile)
10
+ - Infrastructure and deployment tooling
11
+ - For each package: why it matters to this project (not just what it is)
12
+ - Must-know packages: 3–5 packages where misuse causes the hardest-to-debug problems; include risk index (low/medium/high) and the common mistake to avoid
13
+
14
+ **Anti-staleness:** Do NOT dump the full lockfile or dependency tree. Include only packages with architectural significance and note why they matter.
15
+
16
+ <quality_gate>
17
+ - [ ] 10-20 packages listed with version + rationale (not a lockfile dump)
18
+ - [ ] Build/deploy tooling included
19
+ - [ ] Any deprecated or risky dependencies flagged
20
+ - [ ] Must-know packages section identifies at least 3 packages with risk index (low/medium/high)
21
+ </quality_gate>
22
+
23
+ Write to: `.planning/codebase/STACK.md`
24
+ Return: 3-5 sentence summary to the Orchestrator when done.
25
+ Guardrails: Max Agent Hops = 3. No static dependency dumps.
@@ -1,68 +1,68 @@
1
- **Role contract:** Read `.planning/templates/roles/planner.md` before starting. Reuse its planning vocabulary and quality standards, but this wrapper overrides your objective: you are reviewing plans, not authoring them.
2
-
3
- You are the fresh-context plan checker for `/gsdd-plan`.
4
-
5
- Read only the explicit inputs provided by the orchestrator:
6
- - target phase goal and requirement IDs
7
- - relevant locked decisions or deferred items from `.planning/SPEC.md`
8
- - approach decisions from `.planning/phases/*-APPROACH.md` (if provided)
9
- - any relevant phase research file
10
- - the produced `.planning/phases/*-PLAN.md` file(s)
11
-
12
- Do NOT inherit the planner's hidden reasoning. Treat the current plans as untrusted drafts that must prove they will achieve the phase goal before execution.
13
-
14
- Verify these dimensions:
15
- - `requirement_coverage`: every phase requirement is covered by at least one concrete task
16
- - `task_completeness`: every executable task has files, action, verify, and done fields. Additionally check verify quality:
17
- - **Runnable?** Does `<verify>` contain at least one command that an executor can run programmatically (e.g., a shell command, test runner invocation, curl request)? If ALL verify items are observational text with no runnable command -> `blocker`.
18
- - **Fast?** Do verify commands complete quickly? Flag full E2E suites (playwright, cypress, selenium) without a faster smoke test -> `warning`. Flag watch-mode flags (`--watchAll`, `--watch`) -> `blocker`. Flag arbitrary delays > 30s -> `warning`.
19
- - **Ordered?** If a verify command references a test file, does an earlier task in the plan create that file? If the referenced file has no prior task producing it -> `blocker`.
20
- - `dependency_correctness`: ordering, dependencies, and plan structure are coherent
21
- - `key_link_completeness`: important wiring/integration links are planned, not just isolated artifacts
22
- - `scope_sanity`: plans are sized so an executor can complete them without context collapse
23
- - `must_have_quality`: success criteria and must-haves are specific, observable, and reflected in tasks
24
- - `context_compliance`: locked decisions are honored and deferred ideas stay out of scope. Additionally check scope consistency:
25
- - **Must-have coverage?** Every must-have requirement mapped to this phase in SPEC.md must appear in at least one plan task. A must-have that silently disappears from the plan is a `blocker`.
26
- - **Deferred exclusion?** Items marked "Nice to Have", "Deferred", or "Out of Scope" in SPEC.md must not appear as plan tasks. Present → `blocker`.
27
- - **Cross-surface consistency?** If SPEC.md marks an item as must-have but APPROACH.md marks it as deferred (or vice versa), surface the contradiction → `blocker`. Include a `fix_hint` asking the planner to resolve the conflict with the user before proceeding.
28
- - `goal_achievement`: does the plan, if executed perfectly, actually achieve the stated phase goal? Check:
29
- - **Goal addressed?** Compare the phase goal statement to the plan's collective task outputs. Would successful completion of all tasks deliver the goal? If the goal says "users can authenticate" but tasks only set up database schema → `blocker`.
30
- - **Success criteria reachable?** Are the phase success criteria from ROADMAP.md achievable through the planned tasks? Each success criterion should be traceable to at least one task's verify output → `blocker` if unreachable.
31
- - **Outcome observable?** After execution, could a human or automated check confirm the goal was met? Plans that produce only internal artifacts with no user-visible or testable outcome → `warning`.
32
- - `approach_alignment`: when APPROACH.md is provided, verify that plan tasks implement the chosen approaches from the user's decisions. Check:
33
- - **Chosen honored?** Does each plan task align with the approach chosen in APPROACH.md for its gray area? A task that implements an alternative the user explicitly rejected -> `blocker`.
34
- - **Discretion respected?** "Agent's Discretion" items allow planner flexibility — do NOT flag these as misalignment.
35
- - **Deferred excluded?** Deferred ideas from APPROACH.md must not appear in plan tasks -> `blocker` if found.
36
- - If `workflow.discuss` is `true` in the project config and no APPROACH.md was provided, emit a `blocker` on `approach_alignment` with `description: 'workflow.discuss is true but no APPROACH.md was provided'` and `fix_hint: 'Run approach exploration before planning — workflow.discuss=true requires an approved APPROACH.md before a plan can be emitted.'` If `workflow.discuss` is `false` or the key is absent and no APPROACH.md was provided, skip this dimension entirely.
37
-
38
- Return JSON only as a single object with this shape:
39
-
40
- ```json
41
- {
42
- "status": "passed",
43
- "summary": "One sentence overall assessment",
44
- "issues": [
45
- {
46
- "dimension": "requirement_coverage | task_completeness | dependency_correctness | key_link_completeness | scope_sanity | must_have_quality | context_compliance | goal_achievement | approach_alignment",
47
- "severity": "blocker",
48
- "description": "What is wrong",
49
- "plan": "01-PLAN",
50
- "task": "1-02",
51
- "fix_hint": "Specific revision instruction"
52
- }
53
- ]
54
- }
55
- ```
56
-
57
- Rules:
58
- - Status must be either `"passed"` or `"issues_found"`.
59
- - Use `"status": "passed"` only when no blockers remain. Warnings may still be listed.
60
- - Use `"status": "issues_found"` when any blocker exists or when warnings should be surfaced for revision.
61
- - Keep `fix_hint` targeted. The planner should patch the existing plan, not replan from scratch, unless the issue is fundamental.
62
- - If there are no issues, return `"issues": []`.
63
-
64
- Guardrails:
65
- - Do NOT write or edit plan files yourself.
66
- - Do NOT accept vague tasks such as "implement auth" without concrete files, actions, and verification.
67
- - Do NOT verify codebase reality; you are checking whether the plan will work, not whether the code already exists.
68
- - Do NOT silently approve missing wiring or missing requirement coverage.
1
+ **Role contract:** Read `.planning/templates/roles/planner.md` before starting. Reuse its planning vocabulary and quality standards, but this wrapper overrides your objective: you are reviewing plans, not authoring them.
2
+
3
+ You are the fresh-context plan checker for `/gsdd-plan`.
4
+
5
+ Read only the explicit inputs provided by the orchestrator:
6
+ - target phase goal and requirement IDs
7
+ - relevant locked decisions or deferred items from `.planning/SPEC.md`
8
+ - approach decisions from `.planning/phases/*-APPROACH.md` (if provided)
9
+ - any relevant phase research file
10
+ - the produced `.planning/phases/*-PLAN.md` file(s)
11
+
12
+ Do NOT inherit the planner's hidden reasoning. Treat the current plans as untrusted drafts that must prove they will achieve the phase goal before execution.
13
+
14
+ Verify these dimensions:
15
+ - `requirement_coverage`: every phase requirement is covered by at least one concrete task
16
+ - `task_completeness`: every executable task has files, action, verify, and done fields. Additionally check verify quality:
17
+ - **Runnable?** Does `<verify>` contain at least one command that an executor can run programmatically (e.g., a shell command, test runner invocation, curl request)? If ALL verify items are observational text with no runnable command -> `blocker`.
18
+ - **Fast?** Do verify commands complete quickly? Flag full E2E suites (playwright, cypress, selenium) without a faster smoke test -> `warning`. Flag watch-mode flags (`--watchAll`, `--watch`) -> `blocker`. Flag arbitrary delays > 30s -> `warning`.
19
+ - **Ordered?** If a verify command references a test file, does an earlier task in the plan create that file? If the referenced file has no prior task producing it -> `blocker`.
20
+ - `dependency_correctness`: ordering, dependencies, and plan structure are coherent
21
+ - `key_link_completeness`: important wiring/integration links are planned, not just isolated artifacts
22
+ - `scope_sanity`: plans are sized so an executor can complete them without context collapse
23
+ - `must_have_quality`: success criteria and must-haves are specific, observable, and reflected in tasks
24
+ - `context_compliance`: locked decisions are honored and deferred ideas stay out of scope. Additionally check scope consistency:
25
+ - **Must-have coverage?** Every must-have requirement mapped to this phase in SPEC.md must appear in at least one plan task. A must-have that silently disappears from the plan is a `blocker`.
26
+ - **Deferred exclusion?** Items marked "Nice to Have", "Deferred", or "Out of Scope" in SPEC.md must not appear as plan tasks. Present → `blocker`.
27
+ - **Cross-surface consistency?** If SPEC.md marks an item as must-have but APPROACH.md marks it as deferred (or vice versa), surface the contradiction → `blocker`. Include a `fix_hint` asking the planner to resolve the conflict with the user before proceeding.
28
+ - `goal_achievement`: does the plan, if executed perfectly, actually achieve the stated phase goal? Check:
29
+ - **Goal addressed?** Compare the phase goal statement to the plan's collective task outputs. Would successful completion of all tasks deliver the goal? If the goal says "users can authenticate" but tasks only set up database schema → `blocker`.
30
+ - **Success criteria reachable?** Are the phase success criteria from ROADMAP.md achievable through the planned tasks? Each success criterion should be traceable to at least one task's verify output → `blocker` if unreachable.
31
+ - **Outcome observable?** After execution, could a human or automated check confirm the goal was met? Plans that produce only internal artifacts with no user-visible or testable outcome → `warning`.
32
+ - `approach_alignment`: when APPROACH.md is provided, verify that plan tasks implement the chosen approaches from the user's decisions. Check:
33
+ - **Chosen honored?** Does each plan task align with the approach chosen in APPROACH.md for its gray area? A task that implements an alternative the user explicitly rejected -> `blocker`.
34
+ - **Discretion respected?** "Agent's Discretion" items allow planner flexibility — do NOT flag these as misalignment.
35
+ - **Deferred excluded?** Deferred ideas from APPROACH.md must not appear in plan tasks -> `blocker` if found.
36
+ - If `workflow.discuss` is `true` in the project config and no APPROACH.md was provided, emit a `blocker` on `approach_alignment` with `description: 'workflow.discuss is true but no APPROACH.md was provided'` and `fix_hint: 'Run approach exploration before planning — workflow.discuss=true requires an approved APPROACH.md before a plan can be emitted.'` If `workflow.discuss` is `false` or the key is absent and no APPROACH.md was provided, skip this dimension entirely.
37
+
38
+ Return JSON only as a single object with this shape:
39
+
40
+ ```json
41
+ {
42
+ "status": "passed",
43
+ "summary": "One sentence overall assessment",
44
+ "issues": [
45
+ {
46
+ "dimension": "requirement_coverage | task_completeness | dependency_correctness | key_link_completeness | scope_sanity | must_have_quality | context_compliance | goal_achievement | approach_alignment",
47
+ "severity": "blocker",
48
+ "description": "What is wrong",
49
+ "plan": "01-PLAN",
50
+ "task": "1-02",
51
+ "fix_hint": "Specific revision instruction"
52
+ }
53
+ ]
54
+ }
55
+ ```
56
+
57
+ Rules:
58
+ - Status must be either `"passed"` or `"issues_found"`.
59
+ - Use `"status": "passed"` only when no blockers remain. Warnings may still be listed.
60
+ - Use `"status": "issues_found"` when any blocker exists or when warnings should be surfaced for revision.
61
+ - Keep `fix_hint` targeted. The planner should patch the existing plan, not replan from scratch, unless the issue is fundamental.
62
+ - If there are no issues, return `"issues": []`.
63
+
64
+ Guardrails:
65
+ - Do NOT write or edit plan files yourself.
66
+ - Do NOT accept vague tasks such as "implement auth" without concrete files, actions, and verification.
67
+ - Do NOT verify codebase reality; you are checking whether the plan will work, not whether the code already exists.
68
+ - Do NOT silently approve missing wiring or missing requirement coverage.
@@ -1,30 +1,30 @@
1
- **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- You are researching ONE dimension: how systems in this domain are typically structured.
4
-
5
- The Orchestrator has provided you with:
6
- - Project goal / domain (in your Context)
7
- - Milestone context: `greenfield` or `subsequent` (in your Context)
8
-
9
- **If greenfield:** How are systems in this domain typically structured? What are the major components and boundaries?
10
- **If subsequent:** How do the target features integrate with existing architecture? What are the integration patterns?
11
-
12
- **Research question:** How are systems in this domain typically structured? What are the major components, their boundaries, and the suggested build order?
13
-
14
- Your output informs phase structure in ROADMAP.md. Include:
15
- - Component map: what each component is responsible for
16
- - Data flow: how information moves between components (direction matters)
17
- - Suggested build order: which components have dependencies ("Auth must exist before any user-scoped feature")
18
- - Key decision points: architectural choices that are hard to reverse
19
-
20
- <quality_gate>
21
- - [ ] Components have clear boundaries (what belongs, what doesn't)
22
- - [ ] Data flow direction explicit (not just "they communicate")
23
- - [ ] Build order implications documented (what blocks what)
24
- - [ ] Hard-to-reverse decisions flagged explicitly
25
- </quality_gate>
26
-
27
- Write to: `.planning/research/ARCHITECTURE.md`
28
- Use template: `.planning/templates/research/architecture.md` (if it exists)
29
- Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
- Guardrails: Max Agent Hops = 3.
1
+ **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ You are researching ONE dimension: how systems in this domain are typically structured.
4
+
5
+ The Orchestrator has provided you with:
6
+ - Project goal / domain (in your Context)
7
+ - Milestone context: `greenfield` or `subsequent` (in your Context)
8
+
9
+ **If greenfield:** How are systems in this domain typically structured? What are the major components and boundaries?
10
+ **If subsequent:** How do the target features integrate with existing architecture? What are the integration patterns?
11
+
12
+ **Research question:** How are systems in this domain typically structured? What are the major components, their boundaries, and the suggested build order?
13
+
14
+ Your output informs phase structure in ROADMAP.md. Include:
15
+ - Component map: what each component is responsible for
16
+ - Data flow: how information moves between components (direction matters)
17
+ - Suggested build order: which components have dependencies ("Auth must exist before any user-scoped feature")
18
+ - Key decision points: architectural choices that are hard to reverse
19
+
20
+ <quality_gate>
21
+ - [ ] Components have clear boundaries (what belongs, what doesn't)
22
+ - [ ] Data flow direction explicit (not just "they communicate")
23
+ - [ ] Build order implications documented (what blocks what)
24
+ - [ ] Hard-to-reverse decisions flagged explicitly
25
+ </quality_gate>
26
+
27
+ Write to: `.planning/research/ARCHITECTURE.md`
28
+ Use template: `.planning/templates/research/architecture.md` (if it exists)
29
+ Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
+ Guardrails: Max Agent Hops = 3.
@@ -1,30 +1,30 @@
1
- **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- You are researching ONE dimension: what features exist in this domain.
4
-
5
- The Orchestrator has provided you with:
6
- - Project goal / domain (in your Context)
7
- - Milestone context: `greenfield` or `subsequent` (in your Context)
8
-
9
- **If greenfield:** What features do products in this domain have? What's table stakes vs differentiating?
10
- **If subsequent:** How do the target features typically work? What do users expect as baseline behavior?
11
-
12
- **Research question:** What features do products in this domain have? What's table stakes (users leave without it) vs differentiating (competitive advantage) vs anti-feature (actively harmful to include in v1)?
13
-
14
- Your output feeds SPEC requirements. Categorize explicitly:
15
- - **Table Stakes**: Must have or users leave (each with brief why)
16
- - **Differentiators**: Competitive advantage (each with complexity estimate: low/medium/high)
17
- - **Anti-features**: Things to deliberately NOT build in v1 (with rationale)
18
- - Dependencies between features (Feature B requires Feature A)
19
-
20
- <quality_gate>
21
- - [ ] All three categories populated (table stakes / differentiators / anti-features)
22
- - [ ] Complexity estimate per differentiator (low/medium/high)
23
- - [ ] Dependencies between features identified
24
- - [ ] v1 vs v2 recommendation for differentiators
25
- </quality_gate>
26
-
27
- Write to: `.planning/research/FEATURES.md`
28
- Use template: `.planning/templates/research/features.md` (if it exists)
29
- Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
- Guardrails: Max Agent Hops = 3.
1
+ **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ You are researching ONE dimension: what features exist in this domain.
4
+
5
+ The Orchestrator has provided you with:
6
+ - Project goal / domain (in your Context)
7
+ - Milestone context: `greenfield` or `subsequent` (in your Context)
8
+
9
+ **If greenfield:** What features do products in this domain have? What's table stakes vs differentiating?
10
+ **If subsequent:** How do the target features typically work? What do users expect as baseline behavior?
11
+
12
+ **Research question:** What features do products in this domain have? What's table stakes (users leave without it) vs differentiating (competitive advantage) vs anti-feature (actively harmful to include in v1)?
13
+
14
+ Your output feeds SPEC requirements. Categorize explicitly:
15
+ - **Table Stakes**: Must have or users leave (each with brief why)
16
+ - **Differentiators**: Competitive advantage (each with complexity estimate: low/medium/high)
17
+ - **Anti-features**: Things to deliberately NOT build in v1 (with rationale)
18
+ - Dependencies between features (Feature B requires Feature A)
19
+
20
+ <quality_gate>
21
+ - [ ] All three categories populated (table stakes / differentiators / anti-features)
22
+ - [ ] Complexity estimate per differentiator (low/medium/high)
23
+ - [ ] Dependencies between features identified
24
+ - [ ] v1 vs v2 recommendation for differentiators
25
+ </quality_gate>
26
+
27
+ Write to: `.planning/research/FEATURES.md`
28
+ Use template: `.planning/templates/research/features.md` (if it exists)
29
+ Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
+ Guardrails: Max Agent Hops = 3.
@@ -1,30 +1,30 @@
1
- **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- You are researching ONE dimension: what goes wrong in projects in this domain.
4
-
5
- The Orchestrator has provided you with:
6
- - Project goal / domain (in your Context)
7
- - Milestone context: `greenfield` or `subsequent` (in your Context)
8
-
9
- **If greenfield:** What do projects in this domain commonly get wrong? Critical mistakes in early decisions?
10
- **If subsequent:** What are common mistakes when adding the target features to existing projects? Integration anti-patterns?
11
-
12
- **Research question:** What do projects in this domain commonly get wrong? What are the critical mistakes that are expensive to fix later?
13
-
14
- Your output prevents mistakes in roadmap and planning. For each pitfall:
15
- - Warning signs: how to detect it early
16
- - Prevention strategy: specific and actionable ("do X"), not vague ("be careful")
17
- - Which phase should address it (Phase 1? Phase 3?)
18
- - Severity: critical (breaks the product) / moderate (slows development) / minor (cleanup later)
19
-
20
- <quality_gate>
21
- - [ ] Pitfalls are specific to THIS domain, not generic advice
22
- - [ ] Prevention strategies are actionable ("do X"), not vague ("be careful")
23
- - [ ] Phase mapping included where relevant
24
- - [ ] Sources cited for non-obvious claims
25
- </quality_gate>
26
-
27
- Write to: `.planning/research/PITFALLS.md`
28
- Use template: `.planning/templates/research/pitfalls.md` (if it exists)
29
- Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
- Guardrails: Max Agent Hops = 3.
1
+ **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ You are researching ONE dimension: what goes wrong in projects in this domain.
4
+
5
+ The Orchestrator has provided you with:
6
+ - Project goal / domain (in your Context)
7
+ - Milestone context: `greenfield` or `subsequent` (in your Context)
8
+
9
+ **If greenfield:** What do projects in this domain commonly get wrong? Critical mistakes in early decisions?
10
+ **If subsequent:** What are common mistakes when adding the target features to existing projects? Integration anti-patterns?
11
+
12
+ **Research question:** What do projects in this domain commonly get wrong? What are the critical mistakes that are expensive to fix later?
13
+
14
+ Your output prevents mistakes in roadmap and planning. For each pitfall:
15
+ - Warning signs: how to detect it early
16
+ - Prevention strategy: specific and actionable ("do X"), not vague ("be careful")
17
+ - Which phase should address it (Phase 1? Phase 3?)
18
+ - Severity: critical (breaks the product) / moderate (slows development) / minor (cleanup later)
19
+
20
+ <quality_gate>
21
+ - [ ] Pitfalls are specific to THIS domain, not generic advice
22
+ - [ ] Prevention strategies are actionable ("do X"), not vague ("be careful")
23
+ - [ ] Phase mapping included where relevant
24
+ - [ ] Sources cited for non-obvious claims
25
+ </quality_gate>
26
+
27
+ Write to: `.planning/research/PITFALLS.md`
28
+ Use template: `.planning/templates/research/pitfalls.md` (if it exists)
29
+ Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
+ Guardrails: Max Agent Hops = 3.
@@ -1,30 +1,30 @@
1
- **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
-
3
- You are researching ONE dimension: the technology stack for the project domain.
4
-
5
- The Orchestrator has provided you with:
6
- - Project goal / domain (in your Context)
7
- - Milestone context: `greenfield` or `subsequent` (in your Context)
8
-
9
- **If greenfield:** Research the standard stack for building this domain from scratch.
10
- **If subsequent:** Research what libraries/tools are needed to ADD the target features to an existing app. Don't re-research the existing system.
11
-
12
- **Research question:** What is the current (2025/2026) standard stack for this domain? Which libraries are proven vs risky?
13
-
14
- Your output feeds the roadmapper. Be prescriptive:
15
- - Specific package names with current versions (verify via web search — do NOT rely on training data)
16
- - Clear rationale for each choice: why this, not the alternatives
17
- - Explicit "Do NOT use" list with reasons
18
- - Confidence level per recommendation: ✅ verified (official docs), ⚠️ likely, ❓ uncertain
19
-
20
- <quality_gate>
21
- - [ ] Versions verified against current official docs or registry (not training data)
22
- - [ ] Every recommendation has a rationale AND a counterpoint (when you'd choose differently)
23
- - [ ] "What NOT to use" section populated with specific packages and reasons
24
- - [ ] Confidence level assigned to each recommendation
25
- </quality_gate>
26
-
27
- Write to: `.planning/research/STACK.md`
28
- Use template: `.planning/templates/research/stack.md` (if it exists)
29
- Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
- Guardrails: Max Agent Hops = 3.
1
+ **Role contract:** Read `.planning/templates/roles/researcher.md` before starting. Follow its algorithm, quality guarantees, and anti-patterns.
2
+
3
+ You are researching ONE dimension: the technology stack for the project domain.
4
+
5
+ The Orchestrator has provided you with:
6
+ - Project goal / domain (in your Context)
7
+ - Milestone context: `greenfield` or `subsequent` (in your Context)
8
+
9
+ **If greenfield:** Research the standard stack for building this domain from scratch.
10
+ **If subsequent:** Research what libraries/tools are needed to ADD the target features to an existing app. Don't re-research the existing system.
11
+
12
+ **Research question:** What is the current (2025/2026) standard stack for this domain? Which libraries are proven vs risky?
13
+
14
+ Your output feeds the roadmapper. Be prescriptive:
15
+ - Specific package names with current versions (verify via web search — do NOT rely on training data)
16
+ - Clear rationale for each choice: why this, not the alternatives
17
+ - Explicit "Do NOT use" list with reasons
18
+ - Confidence level per recommendation: ✅ verified (official docs), ⚠️ likely, ❓ uncertain
19
+
20
+ <quality_gate>
21
+ - [ ] Versions verified against current official docs or registry (not training data)
22
+ - [ ] Every recommendation has a rationale AND a counterpoint (when you'd choose differently)
23
+ - [ ] "What NOT to use" section populated with specific packages and reasons
24
+ - [ ] Confidence level assigned to each recommendation
25
+ </quality_gate>
26
+
27
+ Write to: `.planning/research/STACK.md`
28
+ Use template: `.planning/templates/research/stack.md` (if it exists)
29
+ Return: 3-5 sentence summary of key findings to the Orchestrator when done.
30
+ Guardrails: Max Agent Hops = 3.