maestro-flow 0.4.11 → 0.4.13

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 (253) hide show
  1. package/.agents/agents/cli-explore-agent.md +1 -3
  2. package/.agents/agents/cross-role-reviewer.md +173 -0
  3. package/.agents/agents/role-design-author.md +220 -0
  4. package/.agents/agents/ui-design-agent.md +1 -18
  5. package/.agents/agents/workflow-analyzer.md +1 -1
  6. package/.agents/agents/workflow-external-researcher.md +1 -1
  7. package/.agents/skills/learn-decompose/SKILL.md +6 -6
  8. package/.agents/skills/learn-follow/SKILL.md +4 -4
  9. package/.agents/skills/learn-investigate/SKILL.md +6 -6
  10. package/.agents/skills/learn-retro/SKILL.md +7 -7
  11. package/.agents/skills/learn-second-opinion/SKILL.md +4 -4
  12. package/.agents/skills/maestro/SKILL.md +61 -27
  13. package/.agents/skills/maestro-amend/SKILL.md +1 -0
  14. package/.agents/skills/maestro-analyze/SKILL.md +37 -4
  15. package/.agents/skills/maestro-blueprint/SKILL.md +133 -0
  16. package/.agents/skills/maestro-brainstorm/SKILL.md +120 -103
  17. package/.agents/skills/maestro-fork/SKILL.md +1 -1
  18. package/.agents/skills/maestro-guard/SKILL.md +3 -2
  19. package/.agents/skills/maestro-help/SKILL.md +48 -14
  20. package/.agents/skills/maestro-help/index/catalog.json +29 -11
  21. package/.agents/skills/maestro-help/phases/01-parse-intent.md +1 -1
  22. package/.agents/skills/maestro-help/phases/02-search-present.md +6 -4
  23. package/.agents/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  24. package/.agents/skills/maestro-impeccable/SKILL.md +13 -11
  25. package/.agents/skills/maestro-init/SKILL.md +3 -3
  26. package/.agents/skills/maestro-milestone-audit/SKILL.md +5 -3
  27. package/.agents/skills/maestro-milestone-complete/SKILL.md +7 -5
  28. package/.agents/skills/maestro-milestone-release/SKILL.md +1 -1
  29. package/.agents/skills/maestro-plan/SKILL.md +16 -4
  30. package/.agents/skills/maestro-ralph/SKILL.md +297 -226
  31. package/.agents/skills/maestro-ralph-execute/SKILL.md +82 -67
  32. package/.agents/skills/maestro-roadmap/SKILL.md +43 -81
  33. package/.agents/skills/manage-harvest/SKILL.md +1 -0
  34. package/.agents/skills/manage-issue-discover/SKILL.md +1 -1
  35. package/.agents/skills/manage-knowhow/SKILL.md +1 -1
  36. package/.agents/skills/manage-learn/SKILL.md +4 -4
  37. package/.agents/skills/quality-auto-test/SKILL.md +6 -6
  38. package/.agents/skills/quality-refactor/SKILL.md +1 -1
  39. package/.agents/skills/quality-retrospective/SKILL.md +2 -2
  40. package/.agents/skills/security-audit/SKILL.md +24 -0
  41. package/.agents/skills/spec-remove/SKILL.md +6 -2
  42. package/.agents/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  43. package/.agents/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  44. package/.agents/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  45. package/.agents/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  46. package/.agents/skills/team-lifecycle-v4/templates/epics.md +2 -2
  47. package/.agents/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  48. package/.agents/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  49. package/.agy/agents/cli-explore-agent.md +1 -3
  50. package/.agy/agents/cross-role-reviewer.md +170 -0
  51. package/.agy/agents/role-design-author.md +217 -0
  52. package/.agy/agents/ui-design-agent.md +1 -18
  53. package/.agy/agents/workflow-analyzer.md +1 -1
  54. package/.agy/agents/workflow-external-researcher.md +1 -1
  55. package/.agy/skills/learn-decompose/SKILL.md +6 -6
  56. package/.agy/skills/learn-follow/SKILL.md +4 -4
  57. package/.agy/skills/learn-investigate/SKILL.md +6 -6
  58. package/.agy/skills/learn-retro/SKILL.md +7 -7
  59. package/.agy/skills/learn-second-opinion/SKILL.md +4 -4
  60. package/.agy/skills/maestro/SKILL.md +61 -27
  61. package/.agy/skills/maestro-amend/SKILL.md +1 -0
  62. package/.agy/skills/maestro-analyze/SKILL.md +37 -4
  63. package/.agy/skills/maestro-blueprint/SKILL.md +133 -0
  64. package/.agy/skills/maestro-brainstorm/SKILL.md +120 -103
  65. package/.agy/skills/maestro-fork/SKILL.md +1 -1
  66. package/.agy/skills/maestro-guard/SKILL.md +3 -2
  67. package/.agy/skills/maestro-help/SKILL.md +48 -14
  68. package/.agy/skills/maestro-help/index/catalog.json +29 -11
  69. package/.agy/skills/maestro-help/phases/01-parse-intent.md +1 -1
  70. package/.agy/skills/maestro-help/phases/02-search-present.md +6 -4
  71. package/.agy/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  72. package/.agy/skills/maestro-impeccable/SKILL.md +13 -11
  73. package/.agy/skills/maestro-init/SKILL.md +3 -3
  74. package/.agy/skills/maestro-milestone-audit/SKILL.md +5 -3
  75. package/.agy/skills/maestro-milestone-complete/SKILL.md +7 -5
  76. package/.agy/skills/maestro-milestone-release/SKILL.md +1 -1
  77. package/.agy/skills/maestro-plan/SKILL.md +16 -4
  78. package/.agy/skills/maestro-ralph/SKILL.md +297 -226
  79. package/.agy/skills/maestro-ralph-execute/SKILL.md +82 -67
  80. package/.agy/skills/maestro-roadmap/SKILL.md +43 -81
  81. package/.agy/skills/manage-harvest/SKILL.md +1 -0
  82. package/.agy/skills/manage-issue-discover/SKILL.md +1 -1
  83. package/.agy/skills/manage-knowhow/SKILL.md +1 -1
  84. package/.agy/skills/manage-learn/SKILL.md +4 -4
  85. package/.agy/skills/quality-auto-test/SKILL.md +6 -6
  86. package/.agy/skills/quality-refactor/SKILL.md +1 -1
  87. package/.agy/skills/quality-retrospective/SKILL.md +2 -2
  88. package/.agy/skills/security-audit/SKILL.md +24 -0
  89. package/.agy/skills/spec-remove/SKILL.md +6 -2
  90. package/.agy/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  91. package/.agy/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  92. package/.agy/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  93. package/.agy/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  94. package/.agy/skills/team-lifecycle-v4/templates/epics.md +2 -2
  95. package/.agy/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  96. package/.agy/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  97. package/.claude/agents/cli-explore-agent.md +1 -3
  98. package/.claude/agents/cross-role-reviewer.md +171 -0
  99. package/.claude/agents/role-design-author.md +218 -0
  100. package/.claude/agents/ui-design-agent.md +1 -18
  101. package/.claude/agents/workflow-analyzer.md +1 -1
  102. package/.claude/agents/workflow-external-researcher.md +1 -1
  103. package/.claude/commands/learn-decompose.md +6 -6
  104. package/.claude/commands/learn-follow.md +4 -4
  105. package/.claude/commands/learn-investigate.md +6 -6
  106. package/.claude/commands/learn-retro.md +7 -7
  107. package/.claude/commands/learn-second-opinion.md +4 -4
  108. package/.claude/commands/maestro-amend.md +1 -0
  109. package/.claude/commands/maestro-analyze.md +37 -4
  110. package/.claude/commands/maestro-blueprint.md +131 -0
  111. package/.claude/commands/maestro-brainstorm.md +133 -116
  112. package/.claude/commands/maestro-fork.md +1 -1
  113. package/.claude/commands/maestro-guard.md +3 -2
  114. package/.claude/commands/maestro-impeccable.md +13 -11
  115. package/.claude/commands/maestro-init.md +3 -3
  116. package/.claude/commands/maestro-milestone-audit.md +5 -3
  117. package/.claude/commands/maestro-milestone-complete.md +7 -5
  118. package/.claude/commands/maestro-milestone-release.md +1 -1
  119. package/.claude/commands/maestro-plan.md +16 -4
  120. package/.claude/commands/maestro-ralph-execute.md +82 -67
  121. package/.claude/commands/maestro-ralph.md +297 -226
  122. package/.claude/commands/maestro-roadmap.md +43 -81
  123. package/.claude/commands/maestro.md +61 -27
  124. package/.claude/commands/manage-harvest.md +1 -0
  125. package/.claude/commands/manage-issue-discover.md +1 -1
  126. package/.claude/commands/manage-knowhow.md +1 -1
  127. package/.claude/commands/manage-learn.md +4 -4
  128. package/.claude/commands/quality-auto-test.md +6 -6
  129. package/.claude/commands/quality-refactor.md +1 -1
  130. package/.claude/commands/quality-retrospective.md +2 -2
  131. package/.claude/commands/security-audit.md +24 -0
  132. package/.claude/commands/spec-remove.md +6 -2
  133. package/.claude/skills/maestro-help/SKILL.md +48 -14
  134. package/.claude/skills/maestro-help/index/catalog.json +29 -11
  135. package/.claude/skills/maestro-help/phases/01-parse-intent.md +1 -1
  136. package/.claude/skills/maestro-help/phases/02-search-present.md +6 -4
  137. package/.claude/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  138. package/.claude/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  139. package/.claude/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  140. package/.claude/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  141. package/.claude/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  142. package/.claude/skills/team-lifecycle-v4/templates/epics.md +2 -2
  143. package/.claude/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  144. package/.claude/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  145. package/.codex/skills/learn-decompose/SKILL.md +4 -4
  146. package/.codex/skills/learn-follow/SKILL.md +3 -3
  147. package/.codex/skills/learn-investigate/SKILL.md +3 -3
  148. package/.codex/skills/learn-retro/SKILL.md +3 -3
  149. package/.codex/skills/learn-second-opinion/SKILL.md +3 -3
  150. package/.codex/skills/maestro/SKILL.md +75 -38
  151. package/.codex/skills/maestro-amend/SKILL.md +157 -0
  152. package/.codex/skills/maestro-analyze/SKILL.md +72 -23
  153. package/.codex/skills/maestro-blueprint/SKILL.md +123 -0
  154. package/.codex/skills/maestro-brainstorm/SKILL.md +277 -46
  155. package/.codex/skills/maestro-composer/SKILL.md +1 -1
  156. package/.codex/skills/maestro-execute/SKILL.md +13 -4
  157. package/.codex/skills/maestro-fork/SKILL.md +2 -0
  158. package/.codex/skills/maestro-guard/SKILL.md +3 -2
  159. package/.codex/skills/maestro-help/SKILL.md +28 -18
  160. package/.codex/skills/maestro-help/catalog.json +29 -11
  161. package/.codex/skills/maestro-impeccable/SKILL.md +13 -11
  162. package/.codex/skills/maestro-init/SKILL.md +7 -7
  163. package/.codex/skills/maestro-plan/SKILL.md +27 -9
  164. package/.codex/skills/maestro-ralph/SKILL.md +740 -601
  165. package/.codex/skills/maestro-roadmap/SKILL.md +56 -72
  166. package/.codex/skills/maestro-update/SKILL.md +169 -0
  167. package/.codex/skills/maestro-verify/SKILL.md +11 -2
  168. package/.codex/skills/manage-codebase-rebuild/SKILL.md +9 -5
  169. package/.codex/skills/manage-harvest/SKILL.md +11 -3
  170. package/.codex/skills/manage-issue-discover/SKILL.md +1 -1
  171. package/.codex/skills/manage-knowhow/SKILL.md +1 -1
  172. package/.codex/skills/manage-learn/SKILL.md +3 -3
  173. package/.codex/skills/quality-refactor/SKILL.md +2 -2
  174. package/.codex/skills/quality-retrospective/SKILL.md +12 -5
  175. package/.codex/skills/security-audit/SKILL.md +24 -0
  176. package/.codex/skills/spec-remove/SKILL.md +8 -2
  177. package/.codex/skills/team-lifecycle-v4/roles/analyst/role.md +2 -2
  178. package/.codex/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  179. package/.codex/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  180. package/.codex/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  181. package/.codex/skills/team-lifecycle-v4/templates/epics.md +2 -2
  182. package/.codex/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  183. package/.codex/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  184. package/README.md +8 -8
  185. package/README.zh-CN.md +8 -8
  186. package/dashboard/dist-server/dashboard/src/server/routes/settings.js +3 -3
  187. package/dashboard/dist-server/dashboard/src/server/routes/settings.js.map +1 -1
  188. package/dist/src/agents/cli-agent-runner.d.ts.map +1 -1
  189. package/dist/src/agents/cli-agent-runner.js +13 -7
  190. package/dist/src/agents/cli-agent-runner.js.map +1 -1
  191. package/dist/src/commands/spec.d.ts.map +1 -1
  192. package/dist/src/commands/spec.js +8 -1
  193. package/dist/src/commands/spec.js.map +1 -1
  194. package/dist/src/tools/spec-init.d.ts +16 -2
  195. package/dist/src/tools/spec-init.d.ts.map +1 -1
  196. package/dist/src/tools/spec-init.js +58 -187
  197. package/dist/src/tools/spec-init.js.map +1 -1
  198. package/dist/src/tools/spec-loader.d.ts.map +1 -1
  199. package/dist/src/tools/spec-loader.js +16 -16
  200. package/dist/src/tools/spec-loader.js.map +1 -1
  201. package/dist/src/tools/spec-seeds.d.ts +33 -0
  202. package/dist/src/tools/spec-seeds.d.ts.map +1 -0
  203. package/dist/src/tools/spec-seeds.js +200 -0
  204. package/dist/src/tools/spec-seeds.js.map +1 -0
  205. package/dist/src/tools/spec-writer.d.ts.map +1 -1
  206. package/dist/src/tools/spec-writer.js +7 -9
  207. package/dist/src/tools/spec-writer.js.map +1 -1
  208. package/dist/src/utils/update-notices.js +12 -0
  209. package/dist/src/utils/update-notices.js.map +1 -1
  210. package/package.json +1 -1
  211. package/templates/business-test-report.json +1 -1
  212. package/templates/index.json +1 -1
  213. package/templates/roadmap.md +15 -9
  214. package/templates/state.json +18 -17
  215. package/workflows/agy-instructions.md +2 -0
  216. package/workflows/analyze.md +79 -11
  217. package/workflows/auto-test.md +12 -7
  218. package/workflows/blueprint.md +431 -0
  219. package/workflows/brainstorm.md +617 -496
  220. package/workflows/business-test.md +7 -7
  221. package/workflows/claude-instructions.md +2 -0
  222. package/workflows/codebase-rebuild.md +4 -4
  223. package/workflows/codex-instructions.md +16 -83
  224. package/workflows/debug.md +1 -1
  225. package/workflows/harvest.md +184 -10
  226. package/workflows/impeccable.md +2 -0
  227. package/workflows/init.md +9 -8
  228. package/workflows/issue-analyze.md +14 -100
  229. package/workflows/issue-discover.md +2 -3
  230. package/workflows/issue-execute.md +1 -1
  231. package/workflows/issue-gaps-analyze.md +2 -0
  232. package/workflows/learn.md +1 -1
  233. package/workflows/maestro-chain-execute.md +10 -228
  234. package/workflows/maestro.md +2 -1
  235. package/workflows/milestone-audit.md +12 -4
  236. package/workflows/milestone-complete.md +14 -9
  237. package/workflows/milestone-release.md +82 -0
  238. package/workflows/plan.md +91 -25
  239. package/workflows/retrospective.md +1 -1
  240. package/workflows/roadmap-common.md +1 -1
  241. package/workflows/roadmap.md +14 -4
  242. package/workflows/spec-generate.md +26 -13
  243. package/workflows/specs-add.md +6 -1
  244. package/workflows/specs-load.md +6 -1
  245. package/workflows/specs-setup.md +6 -1
  246. package/workflows/sync.md +13 -0
  247. package/workflows/tools-spec.md +4 -0
  248. package/workflows/ui-design.md +5 -5
  249. package/workflows/ui-style.md +1 -1
  250. package/workflows/wiki-manage.md +2 -0
  251. package/.agents/agents/conceptual-planning-agent.md +0 -247
  252. package/.agy/agents/conceptual-planning-agent.md +0 -244
  253. package/.claude/agents/conceptual-planning-agent.md +0 -245
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: maestro-roadmap
3
- description: Generate roadmap from requirements (light or full mode)
4
- argument-hint: "<requirement> [--mode light|full] [-y] [-c] [-m progressive|direct|auto] [--from-brainstorm SESSION-ID] [--revise [instructions]] [--review]"
3
+ description: Generate roadmap with milestone/phase structure from requirements or upstream context
4
+ argument-hint: "<requirement> [-y] [-c] [-m progressive|direct|auto] [--from <source>] [--revise [instructions]] [--review]"
5
5
  allowed-tools:
6
6
  - Read
7
7
  - Write
@@ -13,16 +13,14 @@ allowed-tools:
13
13
  - AskUserQuestion
14
14
  ---
15
15
  <purpose>
16
- Unified roadmap generation with two execution paths:
16
+ Generate a milestone/phase roadmap from requirements or upstream context. Produces `.workflow/roadmap.md` with Milestone > Phase hierarchy ready for maestro-analyze and maestro-plan.
17
17
 
18
- - **Light mode** (default): Directly from requirements to roadmap. No specification documents.
19
- - **Full mode** (`--mode full`): 7-phase document chain (Product Brief PRD → Architecture → Epics → Roadmap) producing a complete specification package in `.workflow/.spec/` plus `.workflow/roadmap.md`.
20
-
21
- Additional operation modes (light mode only):
18
+ Operation modes:
19
+ - **Create** (default): Build roadmap from requirements or upstream context
22
20
  - **Revise** (`--revise`): Modify existing roadmap while preserving completed phase progress
23
21
  - **Review** (`--review`): Health assessment of current roadmap (read-only)
24
22
 
25
- Both modes produce `.workflow/roadmap.md` with milestone/phase structure ready for maestro-plan.
23
+ For formal specification documents (Product Brief, PRD, Architecture, Epics), use `/maestro-blueprint` instead.
26
24
  </purpose>
27
25
 
28
26
  <required_reading>
@@ -31,73 +29,68 @@ Both modes produce `.workflow/roadmap.md` with milestone/phase structure ready f
31
29
  </required_reading>
32
30
 
33
31
  <deferred_reading>
34
- - [roadmap.md](~/.maestro/workflows/roadmap.md) — read when mode is light (default)
35
- - [spec-generate.md](~/.maestro/workflows/spec-generate.md) — read when mode is full
36
- - [spec-config.json](~/.maestro/templates/spec-config.json) — read when initializing spec configuration (full mode)
32
+ - [roadmap.md](~/.maestro/workflows/roadmap.md) — read for roadmap generation workflow
37
33
  </deferred_reading>
38
34
 
39
35
  <context>
40
- $ARGUMENTS -- requirement text, @file reference, or brainstorm session reference.
36
+ $ARGUMENTS -- requirement text, @file reference, or upstream context source.
41
37
 
42
- **Flags (shared):**
43
- - `--mode light|full`: Execution path (default: light)
38
+ **Flags:**
44
39
  - `-y` / `--yes`: Auto mode — skip interactive questions, use recommended defaults
45
40
  - `-c` / `--continue`: Resume from last checkpoint
46
- - `--from-brainstorm SESSION-ID`: Import guidance-specification.md from a brainstorm session as seed
47
-
48
- **Flags (light mode only):**
49
41
  - `-m progressive|direct|auto`: Decomposition strategy (default: auto)
42
+ - `--from <source>`: Load upstream context package (brainstorm:ID, blueprint:BLP-xxx, analyze:ANL-xxx, @file, or path). Consumes context-package.json
43
+ - `--from-brainstorm SESSION-ID`: (backward compat alias for `--from brainstorm:ID`)
50
44
  - `--revise [instructions]`: Revise existing roadmap. If instructions provided, apply directly. If omitted, ask user. Preserves completed phase progress.
51
45
  - `--review`: Roadmap health assessment (read-only)
52
46
 
53
47
  **Input types:**
54
48
  - Direct text: `"Implement user authentication system with OAuth and 2FA"`
55
49
  - File reference: `@requirements.md`
56
- - Brainstorm import: `--from-brainstorm WFS-xxx`
50
+ - Context import: `--from brainstorm:BRN-001` or `--from analyze:ANL-xxx` or `--from blueprint:BLP-xxx`
57
51
  - No args + `--revise` / `--review`: Operate on existing `.workflow/roadmap.md`
58
52
 
59
53
  **Pipeline position:**
60
54
  ```
61
- maestro-brainstorm (optional upstream)
62
- guidance-specification.md
63
- maestro-init (project setup)
64
- project.md, state.json, config.json
65
- maestro-roadmap [--mode light] → roadmap.md directly
66
- maestro-roadmap --mode full → spec package + roadmap.md
55
+ maestro-brainstorm ─┐
56
+ maestro-blueprint ─┤ (optional upstream, parallel)
57
+ maestro-analyze ─┘ context-package.json
58
+
59
+ maestro-roadmap → .workflow/roadmap.md (Milestone > Phase hierarchy)
67
60
 
68
- maestro-plan → maestro-execute → maestro-verify
61
+ maestro-analyze {phase} → maestro-plan → maestro-execute → maestro-verify
69
62
  ```
70
63
 
71
- **Note (full mode):** `maestro-init` MUST run before `--mode full`. It creates the `.workflow/` directory and project context.
72
-
73
64
  ### Pre-load specs
74
65
  1. **Architecture specs**: Run `maestro spec load --category arch` to load architecture constraints. Use as context for phase decomposition — ensures roadmap respects documented decisions and boundaries.
75
66
  2. Optional — proceed without if unavailable.
76
67
  </context>
77
68
 
78
- <execution>
69
+ <interview_protocol>
70
+ Interview the user relentlessly until shared understanding is reached. Active only in interactive mode; skip when `-y/--yes`, `--revise`, `--review`, `-c/--continue`, or input is already specific (clear requirement + mode).
79
71
 
80
- ### Mode routing
72
+ - One decision per turn via AskUserQuestion with 2–4 options + a (Recommended) default. The user controls termination — keep interviewing until convergence; they can interrupt naturally or via `Other` at any time.
73
+ - Search-first when uncertain: before asking, resolve via `state.json`, existing `roadmap.md`, `project.md`, `maestro spec load`, `maestro wiki search`, Glob/Grep/Read, or — for open-ended multi-file scans — spawn `Agent(subagent_type: Explore)` / `maestro delegate ... --role explore`. Never ask what code or memory can verify; never bounce your own ambiguity back to the user — search first, then ask only what truly needs human judgment.
74
+ - Writeback cadence: each settled decision is immediately appended/updated in the `Roadmap Decisions` section at the top of `.workflow/roadmap.md` (create the section if absent). Do NOT batch writeback to the end — partial decisions must already be on disk before the next question.
75
+ - Walk the decision dependency tree strictly: mode → requirement scope → decomposition strategy → phase dependencies/order. Do not open the next branch until the current one is settled.
76
+ - Scope guard: only decide the shape of the roadmap. Do not pre-resolve intra-phase task breakdown — that belongs to `plan`.
81
77
 
82
- 1. Read `@~/.maestro/workflows/roadmap-common.md` (always shared logic)
83
- 2. Parse `--mode` flag:
84
- - `light` or omitted → read `@~/.maestro/workflows/roadmap.md`, follow its process
85
- - `full` → read `@~/.maestro/workflows/spec-generate.md`, follow its process
86
- 3. If `--revise` or `--review` present → force light mode (these are light-mode-only operations)
78
+ Decision points: scope (MVP / complete / phased) → strategy (progressive / direct / auto) → milestone boundaries → phase dependencies and order.
87
79
 
88
- ### Light mode (default)
80
+ Exit: on consensus or explicit user signal to proceed, finalize the `Roadmap Decisions` section (rows already populated incrementally). Schema:
81
+ `| # | Decision | Choice | Source (user / code / default) |`
82
+ </interview_protocol>
89
83
 
90
- Follow `~/.maestro/workflows/roadmap.md` completely.
84
+ <execution>
85
+
86
+ 1. Read `@~/.maestro/workflows/roadmap-common.md` (always — shared logic)
87
+ 2. Read `@~/.maestro/workflows/roadmap.md`, follow its process
91
88
 
92
89
  Sub-modes:
93
- - **Create** (default): Build roadmap from requirements
90
+ - **Create** (default): Build roadmap from requirements or upstream context
94
91
  - **Revise** (`--revise`): Follow workflow roadmap.md "Mode: Revise" section
95
92
  - **Review** (`--review`): Follow workflow roadmap.md "Mode: Review" section
96
93
 
97
- ### Full mode (`--mode full`)
98
-
99
- Follow `~/.maestro/workflows/spec-generate.md` completely.
100
-
101
94
  ### Next-step routing on completion
102
95
 
103
96
  | Condition | Suggestion |
@@ -106,63 +99,32 @@ Follow `~/.maestro/workflows/spec-generate.md` completely.
106
99
  | Simple project, ready to plan | /maestro-plan 1 |
107
100
  | Need UI design first | /maestro-impeccable build |
108
101
  | View project dashboard | /manage-status |
109
- | Need project setup (full mode) | /maestro-init |
102
+ | Need formal spec documents | /maestro-blueprint |
110
103
  </execution>
111
104
 
112
105
  <error_codes>
113
-
114
- **Shared:**
115
106
  | Code | Severity | Condition | Recovery |
116
107
  |------|----------|-----------|----------|
117
108
  | E001 | error | Requirement/idea text or @file required | Prompt user for input |
118
- | E002 | error | Brainstorm session not found (--from-brainstorm) | Show available sessions |
119
- | W001 | warning | CLI analysis failed, using fallback | Continue with available data |
120
- | W005 | warning | External research agent failed | Continue without apiResearchContext |
121
-
122
- **Light mode:**
123
- | Code | Severity | Condition | Recovery |
124
- |------|----------|-----------|----------|
109
+ | E002 | error | Context source not found (--from / --from-brainstorm) | Show available sessions/sources |
125
110
  | E003 | error | Circular dependency detected in phases | Prompt user to re-decompose |
126
111
  | E004 | error | roadmap.md not found (--revise/--review) | Run maestro-roadmap first |
127
112
  | E005 | error | Revision invalidates completed phase work | Warn user, ask to confirm or adjust |
113
+ | W001 | warning | CLI analysis failed, using fallback | Continue with available data |
128
114
  | W002 | warning | Max refinement rounds (5) reached | Force proceed with current roadmap |
129
-
130
- **Full mode:**
131
- | Code | Severity | Condition | Recovery |
132
- |------|----------|-----------|----------|
133
- | E006 | error | `.workflow/` not initialized | Run maestro-init first |
134
- | E007 | error | Phase 6 readiness Fail after 2 auto-fix iterations | Present manual fix options |
135
- | W002 | warning | Codebase exploration failed | Continue without codebase context |
136
- | W003 | warning | Glossary has < 5 terms | Note in readiness check |
137
- | W004 | warning | Review-level readiness score (60-79%) | Proceed with caveats |
115
+ | W005 | warning | External research agent failed | Continue without apiResearchContext |
138
116
  </error_codes>
139
117
 
140
118
  <success_criteria>
141
-
142
- **Light mode:**
119
+ - [ ] Interactive mode: interview decision table appended to `.workflow/roadmap.md` "Roadmap Decisions" section
143
120
  - [ ] Requirement parsed with goal, constraints, stakeholders
121
+ - [ ] Milestones defined with deliverable targets and version tags
144
122
  - [ ] Decomposition strategy selected (progressive or direct)
145
- - [ ] Phases defined with success criteria, dependencies, and requirement mappings
123
+ - [ ] Phases defined within milestones with success criteria, dependencies, and requirement mappings
146
124
  - [ ] Every Active requirement from project.md mapped to exactly one phase
147
125
  - [ ] No circular dependencies in phase ordering
148
126
  - [ ] User approved roadmap (or auto-approved with -y)
149
- - [ ] `.workflow/roadmap.md` written with phase details, scope decisions, and progress table
127
+ - [ ] `.workflow/roadmap.md` written with Milestone > Phase hierarchy, scope decisions, and progress table
150
128
  - [ ] No phase directories created (phases are labels in roadmap, not directories)
151
-
152
- **Full mode (in addition to light mode criteria for roadmap):**
153
- - [ ] `spec-config.json` created with session metadata and phase tracking
154
- - [ ] `product-brief.md` with vision, goals, scope, multi-perspective synthesis
155
- - [ ] `glossary.json` with 5+ core terms for cross-document consistency
156
- - [ ] `requirements/` directory with `_index.md` + individual `REQ-*.md` + `NFR-*.md` files
157
- - [ ] All requirements have RFC 2119 keywords and acceptance criteria
158
- - [ ] `architecture/` directory with `_index.md` + individual `ADR-*.md` files
159
- - [ ] Architecture includes state machine, config model, error handling, observability (service type)
160
- - [ ] `epics/` directory with `_index.md` + individual `EPIC-*.md` files
161
- - [ ] Cross-Epic dependency map (Mermaid) and MVP subset tagged
162
- - [ ] `readiness-report.md` with 4-dimension quality scores and traceability matrix
163
- - [ ] `spec-summary.md` with one-page executive summary
164
- - [ ] All documents have valid YAML frontmatter with session_id
165
- - [ ] Glossary terms used consistently across all documents
166
- - [ ] Readiness gate: Pass (>=80%) or Review (>=60%) with documented caveats
167
- - [ ] `.workflow/roadmap.md` written
129
+ - [ ] Artifact registered in state.json with milestone entries
168
130
  </success_criteria>
@@ -49,8 +49,13 @@ $ARGUMENTS — user intent text, or special keywords.
49
49
  1. **All chains dispatch via maestro-ralph-execute** — maestro never executes steps directly
50
50
  2. **Session before execution** — status.json created before any step runs
51
51
  3. **Auto flags only to supporting commands** — unlisted commands execute as-is
52
- 4. **Decomposition contract shared with maestro-ralph** — broad/lifecycle intents run S_DECOMPOSE producing the SAME additive block (`boundary_contract`, `execution_criteria`, `task_decomposition`, `goal_checklist_path`) + `goal-checklist.md`, then EMIT the `/goal` bind prompt. Reference maestro-ralph `A_DECOMPOSE_TASKS` for the full spec; do not duplicate logic
53
- 5. **Status JSON: schema-additive + step-dynamic** decomposition fields OPTIONAL (absent → old flat-chain behavior); `steps[]` is a living array grown at runtime by ralph-execute's `post-goal-audit`. Never remove/rename existing fields
52
+ 4. **Decomposition contract shared with maestro-ralph** — broad/lifecycle intents run S_DECOMPOSE producing the SAME additive block (`boundary_contract`, `execution_criteria`, `task_decomposition`)Reference maestro-ralph `A_DECOMPOSE_TASKS`
53
+ 5. **status.json 唯一真源**不生成 `goal-checklist.md` 或外部清单
54
+ 6. **Default step type = internal** — chain 内每个 step 解析 `command_scope`/`command_path`(全局优先 `~/.claude/commands/{name}.md`,fallback 项目)
55
+ 7. **Topology awareness** — chain catalog 含 brainstorm / blueprint / analyze-macro(text) / analyze(numeric phase) / roadmap / plan(三路径) / execute / verify / ...;scope_verdict 路由由 ralph 在 `post-analyze-scope` 决定
56
+ 8. **D-007 milestone 反查** — 数字 phase 步骤的 `milestone_id` 由 `state.json.milestones[].phase_slugs` 反查得出
57
+ 9. **每个 step 必须 `completion_confirmed: true`** — 基于 `--- COMPLETION STATUS ---` 的 `STATUS: DONE`
58
+ 10. **schema 向后兼容** — 新增字段全部可选;既有字段名不删不改
54
59
  </invariants>
55
60
 
56
61
  <state_machine>
@@ -127,9 +132,16 @@ S_FALLBACK:
127
132
  ### A_CLASSIFY_INTENT
128
133
 
129
134
  1. Read `~/.maestro/workflows/maestro.md` from deferred_reading
130
- 2. Match intent to best task_type via chain catalog (semantic, AI-driven)
131
- 3. Select chain from chainMap
132
- 4. Determine per-step type: `internal` (Skill) or `external` (delegate)
135
+ 2. Match intent to task_type via chain catalog (semantic)
136
+ 3. Select chain from chainMap,遵循拓扑约束:
137
+ - 头脑风暴/探索 `brainstorm`
138
+ - 正式规格/spec-generate/7-phase → `blueprint`
139
+ - 项目初始化 → `init`
140
+ - 宽/中等意图 + 无数字 phase → `analyze-macro`(产 scope_verdict,由 ralph 在 `post-analyze-scope` 决定是否插入 roadmap+analyze 或直跳 plan --from analyze)
141
+ - 数字 phase 上下文 → `analyze {phase}` → `plan {phase}` → `execute {phase}` → `verify {phase}` → quality pipeline
142
+ - 已有 analyze artifact 想直达执行 → `plan --from analyze:{ANL_ID}` → execute → verify
143
+ - 已有 blueprint artifact → `plan --from blueprint:{BLP_ID}` → execute → verify
144
+ 4. 每个 step 默认 `type: "internal"`;解析 `command_scope` + `command_path`(全局优先 fallback 项目);写入 `step.stage` / `step.scope` / `step.source_artifact_ref`(如 `--from` 注入时)
133
145
 
134
146
  ### A_CLARIFY
135
147
 
@@ -138,36 +150,52 @@ S_FALLBACK:
138
150
 
139
151
  ### A_DECOMPOSE_TASKS
140
152
 
141
- 与 maestro-ralph `A_DECOMPOSE_TASKS` 共享分解契约 —— 引用该规范,不重复表格。Condensed:
153
+ 与 maestro-ralph `A_DECOMPOSE_TASKS` 共享分解契约。Condensed:
142
154
 
143
- 1. 分类意图广度(broad: 重构/全面/重写/迁移/overhaul/migrate/rewrite;narrow: 单文件/函数/bug)。narrow / 单步 / `{status,init,quick}` 链直接跳过
144
- 2. broad/medium → `AskUserQuestion` ≤3 轮:Scope(in/out)| Constraints(兼容/API/perf/test)| Definition of Done
145
- 3. 派生 `execution_criteria`(3-6 条命令式规则)+ `task_decomposition`(outcome 子目标,`done_when` 客观可校验,绑定到 ralph 产物:verification.json / review.json / uat.md / test path)
146
- 4. **status.json 为唯一真源**:写入 `boundary_contract` / `execution_criteria` / `task_decomposition` / `goal_checklist_path`;从 status.json 投影渲染 `{session_dir}/goal-checklist.md`(同 maestro-ralph 的 Sync Rule,含 Resume 区块指向 `/maestro-ralph continue`)
147
- 5. 在链路末尾(evidence 产出步骤之后、milestone-complete/close-out 之前)追加 `{ type: "decision", decision: "post-goal-audit", retry_count: 0, max_retries: 2 }`。ralph-execute 在该节点动态生长 `steps[]` 以收敛未达成子目标
148
- 6. **输出 `/goal` 绑定提示词(参考文档 + 内嵌 ralph 调用):**
155
+ 1. 分类意图广度。narrow / 单步 / `{status,init,quick}` 链跳过
156
+ 2. broad/medium → `AskUserQuestion` ≤3 轮:Scope / Constraints / Definition of Done
157
+ 3. 派生 `execution_criteria` + `task_decomposition`(每个 sub-goal 含 `done_when` + `evidence` + `lifecycle` + `completion_confirmed: false`)
158
+ 4. **status.json 唯一真源**:写入 `boundary_contract` / `execution_criteria` / `task_decomposition`;不生成 markdown 清单
159
+ 5. 在最后一个 evidence-producing stage(verify/review/test)之后、`milestone-complete` 之前追加 `decision:post-goal-audit`。ralph-execute 在该节点按需动态生长 `steps[]`
160
+ 6. **输出 `/goal` 绑定提示词:**
149
161
  ```
150
162
  📋 任务分解完成。复制下面一行设定目标,会话在子目标全部达成前不停:
151
163
 
152
- /goal 目标达成条件: {session_dir}/status.json 中 task_decomposition[*].status 全部为 "done"(等价: {session_dir}/goal-checklist.md 末尾含 ALL_GOALS_DONE)。未达成时: 阅读 {session_dir}/goal-checklist.md 取得"执行准则/边界契约/子目标"作为行动手册, 然后调用 /maestro-ralph continue 推进下一步; 严禁手动执行 skill 或越界。
164
+ /goal 目标达成条件: {session_dir}/status.json 中 task_decomposition[*].status == "done" 且 task_decomposition[*].completion_confirmed == true steps[*].completion_confirmed == true。未达成时:阅读 {session_dir}/status.json 取得 execution_criteria / boundary_contract / task_decomposition / steps 作为行动手册,调用 /maestro-ralph continue 推进;严禁手动执行 skill 或越界修改 status.json.boundary_contract.out_of_scope。
153
165
  ```
154
- `/goal` 仅用户可输入;判据以 status.json 为权威,哨兵为等价信号。
155
166
 
156
167
  ### A_CREATE_SESSION
157
168
 
158
- 1. Read `.workflow/state.json` for project context (phase, milestone)
159
- 2. Create `.workflow/.maestro/maestro-{YYYYMMDD-HHMMSS}/status.json`:
169
+ 1. Read `.workflow/state.json` 获取 phase / milestone(含 D-007 反查 `phase_slugs`);读最新 macro analyze artifact 注入 `scope_verdict` + `analyze_macro_id`(如存在);读最新 blueprint artifact 注入 `blueprint_id`
170
+ 2. Create `.workflow/.maestro/maestro-{YYYYMMDD-HHMMSS}/status.json`(与 ralph 共用 schema):
160
171
  ```json
161
- { "session_id", "source": "maestro", "intent", "task_type", "chain_name",
162
- "phase", "milestone", "auto_mode", "exec_mode", "cli_tool",
163
- "context": { ... }, "steps": [{ "index", "skill", "args", "type", "status": "pending", "goal_ref": null }],
172
+ {
173
+ "session_id", "source": "maestro", "intent", "task_type", "chain_name",
174
+ "phase", "phase_is_new": false, "milestone": "",
175
+ "scope_verdict": null, "analyze_macro_id": null, "blueprint_id": null,
176
+ "auto_mode": false, "exec_mode": "auto", "cli_tool": "claude",
177
+ "context": { "scratch_dir": null, "plan_dir": null, "analysis_dir": null,
178
+ "brainstorm_dir": null, "blueprint_dir": null, "issue_id": null },
179
+ "steps": [{
180
+ "index": 0, "type": "internal|external|decision",
181
+ "skill": "", "args": "",
182
+ "stage": "", "scope": null,
183
+ "command_scope": "global|project|missing|null",
184
+ "command_path": "~/.claude/commands/{name}.md | .claude/commands/{name}.md | null",
185
+ "milestone_id": null, "source_artifact_ref": null,
186
+ "status": "pending", "goal_ref": null,
187
+ "completion_confirmed": false, "completion_status": null,
188
+ "completion_evidence": null, "completed_at": null
189
+ }],
164
190
  "waves": [], "current_step": 0, "status": "running",
165
- "_comment": " OPTIONAL additive block — present only if S_DECOMPOSE ran; absent → old flat-chain behavior",
166
- "boundary_contract": {}, "execution_criteria": [], "task_decomposition": [], "goal_checklist_path": "" }
191
+ "boundary_contract": {}, "execution_criteria": [],
192
+ "task_decomposition": [], "task_decomposition_all_done": false
193
+ }
167
194
  ```
168
- Decomposition fields written ONLY if A_DECOMPOSE_TASKS produced them (additive; never break flat-chain readers)
169
- 3. Initialize tracking via `TodoWrite`. The decomposition goal is bound by the user via the emitted `/goal` prompt
170
- 4. If `--super`: read `maestro-super.md`, follow it completely
195
+ Decomposition 字段仅在 A_DECOMPOSE_TASKS 产出时写入(additive
196
+ 3. Validate: 所有 step `command_scope != "missing"`;否则 raise E005 列出缺失 skill
197
+ 4. Initialize tracking via `TodoWrite`
198
+ 5. If `--super`: read `maestro-super.md`, follow it completely
171
199
 
172
200
  </actions>
173
201
 
@@ -182,6 +210,7 @@ S_FALLBACK:
182
210
  | maestro-init | `-y` | Skip interactive questioning |
183
211
  | maestro-analyze | `-y` | Skip scoping, auto-deepen |
184
212
  | maestro-brainstorm | `-y` | Skip questions, use defaults |
213
+ | maestro-blueprint | `-y` | Skip interview, use recommended defaults |
185
214
  | maestro-roadmap | `-y` | Skip questions (create/revise/review) |
186
215
  | maestro-impeccable | `-y` | Auto-select design variant + skip confirmations |
187
216
  | maestro-plan | `-y` | Skip confirmations and clarification |
@@ -201,6 +230,7 @@ Unlisted commands have no auto flags.
201
230
  | E002 | error | Clarity too low after 2 rounds | Show parsed intent, ask rephrase |
202
231
  | E003 | error | Chain step failed + user abort | Record partial, suggest -c resume |
203
232
  | E004 | error | Resume session not found | Show available sessions |
233
+ | E005 | error | command_scope == "missing" for one or more steps | List missing skills, abort build |
204
234
  | W001 | warning | Ambiguous intent, multiple chains | Present options |
205
235
  | W002 | warning | Step completed with warnings | Log and continue |
206
236
  | W003 | warning | State suggests different chain | Show discrepancy |
@@ -208,11 +238,15 @@ Unlisted commands have no auto flags.
208
238
  ### Success Criteria
209
239
 
210
240
  - [ ] Intent classified with task_type, complexity, clarity_score
211
- - [ ] Broad lifecycle intents decomposed (S_DECOMPOSE, ≤3 boundary questions) sharing maestro-ralph contract; narrow/single-step skip
212
- - [ ] status.json 为唯一真源;goal-checklist.md 为投影视图(Resume 区块内嵌 `/maestro-ralph continue`);post-goal-audit 节点追加;/goal 提示词内含"读 checklist + 调 /maestro-ralph continue"双重指引
241
+ - [ ] Chain catalog 覆盖 brainstorm / blueprint / analyze-macro / analyze / roadmap / plan(三路径) / execute / verify / quality pipeline
242
+ - [ ] D-007: 数字 phase 步骤的 `milestone_id` 通过 `state.json.milestones[].phase_slugs` 反查
243
+ - [ ] macro analyze 后跟 `decision:post-analyze-scope`(由 ralph 评估 scope_verdict 决定下游链路)
244
+ - [ ] plan 支持 `{phase}` / `--from analyze:{ANL_ID}` / `--from blueprint:{BLP_ID}` 三路径;`source_artifact_ref` 写入 step
245
+ - [ ] Broad lifecycle intents decomposed (≤3 boundary questions); narrow/single-step skip
246
+ - [ ] status.json 唯一真源;无 markdown 清单;post-goal-audit 节点在 decomposed 时追加;/goal 提示词以 status.json 为判据
213
247
  - [ ] Chain selected and confirmed (or auto-confirmed)
214
248
  - [ ] Session dir created with status.json before execution; decomposition fields additive-only
215
- - [ ] Tracking via TodoWrite (Claude); status.json steps[] grown dynamically by ralph-execute post-goal-audit
249
+ - [ ] 每个 step `command_scope` + `command_path` + `completion_confirmed` 字段
216
250
  - [ ] Auto flags propagated to supporting commands only
217
251
  - [ ] All chains dispatched via maestro-ralph-execute
218
252
  - [ ] Low-complexity intents routed to maestro-quick
@@ -47,6 +47,7 @@ Follow '~/.maestro/workflows/harvest.md' Stages 1-8 in order.
47
47
  1. **Read-only until Stage 6** — extraction and classification happen in-memory.
48
48
  2. **Dedup before write** — check harvest-log.jsonl and existing stores before each write.
49
49
  3. **Never modify source artifacts** — harvest is purely extractive.
50
+ 4. **Dedup contract with parallel writers** — when appending to `issues.jsonl`, set `source: "harvest"` on each row so concurrent writers (e.g. `manage-issue-discover` with `source: "discover"`) can be distinguished and deduplicated.
50
51
 
51
52
  Extraction patterns, classification rules, routing infrastructure, and fragment ID scheme defined in workflow harvest.md.
52
53
 
@@ -46,7 +46,7 @@ $ARGUMENTS -- optional. Parse first token to determine mode.
46
46
  - `--depth=standard|deep` -- exploration depth (by-prompt only, default: `standard`)
47
47
 
48
48
  **State files:**
49
- - `.workflow/issues/issues.jsonl` -- issues appended here
49
+ - `.workflow/issues/issues.jsonl` -- issues appended here (set `source: "discover"` on each row so concurrent writers like `manage-harvest` with `source: "harvest"` can be distinguished and deduplicated)
50
50
  - `.workflow/issues/discoveries/{SESSION_ID}/` -- session artifacts
51
51
 
52
52
  ### Pre-load specs
@@ -53,7 +53,7 @@ Follow '~/.maestro/workflows/knowhow.md' Part A (KnowHow Management) completely.
53
53
  <error_codes>
54
54
  | Code | Severity | Description | Stage |
55
55
  |------|----------|-------------|-------|
56
- | E001 | error | No memory stores found — run `/manage-knowhow-capture` or create MEMORY.md | resolve_paths |
56
+ | E001 | error | No memory stores found — for workflow store run `/manage-knowhow-capture`; for system store create `~/.claude/projects/{project}/memory/MEMORY.md` manually | resolve_paths |
57
57
  | E002 | error | Entry ID or filename not found | execute_view, execute_delete |
58
58
  | E003 | error | Prune requires at least one filter (--tag, --type, --before, --after) | execute_prune |
59
59
  | E004 | error | Cannot delete MEMORY.md — use `edit` subcommand instead | execute_delete |
@@ -30,7 +30,7 @@ Arguments: $ARGUMENTS
30
30
  - `"<insight text>"` (or any non-keyword text) → insight capture mode
31
31
  - `tip <text>` → tip capture mode (quick contextual note, auto-tagged `tip`)
32
32
  - `list` → list recent entries (default 20)
33
- - `search <query>` → `maestro spec load --category learning` or text search across `specs/learnings.md`
33
+ - `search <query>` → `maestro spec load --category learning` or text search across `.workflow/specs/learnings.md`
34
34
  - `show <INS-id>` → full detail with phase context
35
35
  - empty → AskUserQuestion to prompt for text
36
36
 
@@ -47,19 +47,19 @@ Follow `~/.maestro/workflows/learn.md` Stages 1–5 in order.
47
47
  | E001 | error | `.workflow/` not initialized — run `/maestro-init` first | parse_input |
48
48
  | E002 | error | Unknown `--category` value (allowed: pattern, antipattern, decision, tool, gotcha, technique, tip) | parse_input |
49
49
  | E003 | error | `show` mode requires an INS-id argument | show |
50
- | E004 | error | Insight id not found in `specs/learnings.md` | show |
50
+ | E004 | error | Insight id not found in `.workflow/specs/learnings.md` | show |
51
51
  | W001 | warning | Auto-phase detection found a current_phase but no matching artifact in registry; phase set to null | capture |
52
52
  </error_codes>
53
53
 
54
54
  <success_criteria>
55
55
  - [ ] Mode correctly routed (capture / list / search / show)
56
- - [ ] Capture: `<spec-entry>` block appended to `specs/learnings.md` with all required fields
56
+ - [ ] Capture: `<spec-entry>` block appended to `.workflow/specs/learnings.md` with all required fields
57
57
  - [ ] Capture: phase auto-link resolves correctly via artifact registry when `state.json` has `current_phase`
58
58
  - [ ] Capture: category inference produces a sensible default when `--category` absent
59
59
  - [ ] List: filters apply, output sorted newest-first, default limit 20
60
60
  - [ ] Search: results ranked by title (3) > tags (2) > summary (1) match
61
61
  - [ ] Show: full insight displayed with phase context and routed-artifact link if any
62
- - [ ] No file modifications outside `.workflow/knowhow/`
62
+ - [ ] No file modifications outside `.workflow/specs/learnings.md` and `.workflow/knowhow/`
63
63
  - [ ] Confirmation banner displayed with INS-id and next-step hints
64
64
  - [ ] Next step: `/manage-learn list` to browse, or `/manage-learn search <query>` to find related insights
65
65
  </success_criteria>
@@ -15,7 +15,7 @@ allowed-tools:
15
15
  Run unified automated testing via CSV layer pipeline. Reads project state to auto-select the optimal scenario source — PRD specs (when spec package exists), coverage gaps (when Nyquist audit found gaps), or code exploration (default). All sources converge into a CSV pipeline: discover infrastructure → plan → build scenarios.csv → write tests per layer (spawn_agents_on_csv parallel) → execute → diagnose failures (spawn_agents_on_csv parallel) → iterate → report.
16
16
 
17
17
  Key mechanisms:
18
- - **Intelligent routing**: Reads `.tests/`, `.workflow/.spec/`, `verification.json` to auto-select source — no mode flag needed
18
+ - **Intelligent routing**: Reads `.tests/`, `.workflow/blueprint/`, `verification.json` to auto-select source — no mode flag needed
19
19
  - **CSV parallel test writing**: Per-layer `spawn_agents_on_csv` — each agent writes one test file independently
20
20
  - **CSV parallel failure diagnosis**: Failed scenarios dispatched via `spawn_agents_on_csv` for classification + fix
21
21
  - **Unified iteration engine**: Nested inner loop (fix test_defects via diagnosis CSV, max 3/layer) + outer loop (adaptive strategy, max N iterations)
@@ -40,13 +40,13 @@ Phase or task: $ARGUMENTS (required — phase number)
40
40
 
41
41
  **Intelligent routing** (auto-detected from project state):
42
42
 
43
- | Priority | Condition | Route | Equivalent to |
44
- |----------|-----------|-------|---------------|
43
+ | Priority | Condition | Route | Reference skill |
44
+ |----------|-----------|-------|-----------------|
45
45
  | 1 | Active session exists (state.json status=running) | Resume | — |
46
46
  | 2 | --re-run flag + previous failures | Re-run | — |
47
- | 3 | Spec package exists (REQ-*.md) | spec | quality-business-test |
48
- | 4 | Nyquist gaps exist (verification.json) | gap | quality-test-gen |
49
- | 5 | Default | code | quality-integration-test |
47
+ | 3 | Spec package exists (REQ-*.md) | spec | quality-business-test (separate skill) |
48
+ | 4 | Nyquist gaps exist (verification.json) | gap | quality-test-gen (separate skill) |
49
+ | 5 | Default | code | quality-integration-test (separate skill) |
50
50
 
51
51
  Flags, artifact context resolution, and output formats defined in workflow auto-test.md.
52
52
 
@@ -46,7 +46,7 @@ After successful refactoring, ask user once: "Record refactoring pattern as codi
46
46
 
47
47
  **Next-step routing on completion:**
48
48
  - All tests pass → `/quality-sync` (update codebase docs)
49
- - Test failures after refactor → `/quality-debug {scope}`
49
+ - Test failures after refactor → `/quality-debug "test failures after refactor in {scope}"`
50
50
  - No test suite available → `/quality-auto-test {phase}`
51
51
  </execution>
52
52
 
@@ -13,7 +13,7 @@ allowed-tools:
13
13
  - AskUserQuestion
14
14
  ---
15
15
  <purpose>
16
- Post-execution multi-perspective retrospective (复盘) for completed phases. Consumes existing execution artifacts (verification.json, review.json, issues.jsonl, plan.json, .summaries/, uat.md, state.json) and runs four parallel lenses — technical, process, quality, decision — to distill reusable insights. Routes each insight into the appropriate store: spec stub for reusable patterns, memory tip for process notes, issue for recurring gaps. Auto-scans for unreviewed completed phases and reports the backlog. Every insight is also persisted to `.workflow/knowhow/specs/learnings.md` as `<spec-entry>` blocks for cross-phase queryability.
16
+ Post-execution multi-perspective retrospective (复盘) for completed phases. Consumes existing execution artifacts (verification.json, review.json, issues.jsonl, plan.json, .summaries/, uat.md, state.json) and runs four parallel lenses — technical, process, quality, decision — to distill reusable insights. Routes each insight into the appropriate store: spec stub for reusable patterns, memory tip for process notes, issue for recurring gaps. Auto-scans for unreviewed completed phases and reports the backlog. Every insight is also persisted to `.workflow/specs/learnings.md` as `<spec-entry>` blocks for cross-phase queryability.
17
17
  </purpose>
18
18
 
19
19
  <required_reading>
@@ -70,7 +70,7 @@ Follow `~/.maestro/workflows/retrospective.md` Stages 1–8 in order. Key invari
70
70
  - [ ] Spec entries (if any) appended as `<spec-entry>` to matching `.workflow/specs/{category-file}.md`
71
71
  - [ ] Issue rows (if any) match canonical issues.jsonl schema (status "open", full issue_history, all required fields)
72
72
  - [ ] Note tips (if any) created via `Skill({ skill: "manage-learn", args: "tip ..." })`
73
- - [ ] `specs/learnings.md` appended with one `<spec-entry>` per insight regardless of routing target
73
+ - [ ] `.workflow/specs/learnings.md` appended with one `<spec-entry>` per insight regardless of routing target
74
74
  - [ ] No existing phase artifacts modified (verification.json, review.json, plan.json untouched)
75
75
  - [ ] Confirmation banner displays routing counts and next-step suggestions
76
76
  - [ ] Next step: `/manage-status` to review state, or `/manage-issue list --source retrospective` to triage created issues, or `/manage-learn list` to browse the knowhow library
@@ -16,6 +16,10 @@ Systematic security audit covering OWASP Top 10, dependency supply chain, secret
16
16
  CI/CD pipeline review, and optional STRIDE threat modeling. Three tiers control depth vs speed.
17
17
  </purpose>
18
18
 
19
+ <required_reading>
20
+ @~/.maestro/workflows/review.md
21
+ </required_reading>
22
+
19
23
  <context>
20
24
  $ARGUMENTS — Parse tier and scope:
21
25
  - Tier: `quick` (default) | `standard` | `deep`
@@ -143,6 +147,26 @@ CONCERNS: {count} critical findings require immediate action
143
147
  NEXT: /quality-review
144
148
  --- END STATUS ---
145
149
  ```
150
+
151
+ **Register artifact on completion** (so retrospective/harvest can trace this audit):
152
+ ```
153
+ Append to state.json.artifacts[]:
154
+ {
155
+ id: nextArtifactId(artifacts, "review"), // RVW-NNN (security-audit reuses review type)
156
+ type: "review",
157
+ subtype: "security-audit",
158
+ milestone: current_milestone || null,
159
+ phase: target_phase || null,
160
+ scope: target_phase ? "phase" : "standalone",
161
+ path: "scratch/{YYYYMMDD}-security-audit-{tier}-{slug}",
162
+ status: critical_count == 0 ? "completed" : "completed_with_concerns",
163
+ tier: tier, // quick|standard|deep
164
+ harvested: false,
165
+ created_at: start_time,
166
+ completed_at: now()
167
+ }
168
+ ```
169
+ Write findings report to the same `path` (severity matrix, file:line refs, remediation).
146
170
  </execution>
147
171
 
148
172
  <success_criteria>
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: spec-remove
3
3
  description: Remove spec entry by ID
4
- argument-hint: "<entry-id>"
4
+ argument-hint: "<entry-id> [--cascade]"
5
5
  allowed-tools:
6
6
  - Read
7
7
  - Write
@@ -26,6 +26,9 @@ $ARGUMENTS -- expects `<entry-id>` (e.g., `spec-learnings-003`, `spec-coding-con
26
26
  **Entry ID format**: `spec-{file-stem}-{NNN}` — the sub-node ID assigned by WikiIndexer when indexing `<spec-entry>` blocks.
27
27
 
28
28
  **Discovery**: Use `maestro wiki list --type spec --json` or `/spec-load --keyword <term>` to find entry IDs.
29
+
30
+ **Flags:**
31
+ - `--cascade` — When the target spec is a ref-type entry (created via `spec-add --ref` and linked to a knowhow document), also delete the referenced knowhow file. Without this flag, ref-type removal leaves an orphan knowhow file.
29
32
  </context>
30
33
 
31
34
  <execution>
@@ -47,5 +50,6 @@ Follow '~/.maestro/workflows/specs-remove.md' completely.
47
50
  - [ ] User confirmed removal (unless -y flag)
48
51
  - [ ] Entry removed from container file via `maestro wiki remove-entry`
49
52
  - [ ] Wiki index auto-updated
50
- - [ ] Confirmation displayed with removed entry details
53
+ - [ ] If `--cascade` and entry has a `ref` attribute: referenced knowhow file deleted, orphan avoided
54
+ - [ ] Confirmation displayed with removed entry details (and cascaded knowhow path if applicable)
51
55
  </success_criteria>