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,116 +1,133 @@
1
- ---
2
- name: maestro-brainstorm
3
- description: Use when exploring ideas, evaluating approaches, or needing multi-perspective analysis before implementation
4
- argument-hint: "[topic|role-name] [--yes] [--count N] [--session ID] [--update] [--skip-questions] [--include-questions] [--style-skill PKG]"
5
- allowed-tools:
6
- - Read
7
- - Write
8
- - Bash
9
- - Glob
10
- - Grep
11
- - Agent
12
- - AskUserQuestion
13
- ---
14
- <purpose>
15
- Unified brainstorming combining interactive framework generation, multi-role parallel analysis, and cross-role synthesis. Two modes: Auto (full pipeline with guidance-specification → parallel role analysis → synthesis) and Single Role (individual role analysis for an existing session). Outputs structured artifacts in .brainstorming/ directory ready for downstream planning.
16
- </purpose>
17
-
18
- <required_reading>
19
- @~/.maestro/workflows/brainstorm.md
20
- </required_reading>
21
-
22
- <deferred_reading>
23
- - [scratch-index.json](~/.maestro/templates/scratch-index.json) — read when operating in scratch mode
24
- - [index.json](~/.maestro/templates/index.json) — read when operating in phase mode
25
- - [brainstorm-visualize.md](~/.maestro/workflows/brainstorm-visualize.md) — read when html-prototypes/ produced and user wants to browse them
26
- </deferred_reading>
27
-
28
- <context>
29
- $ARGUMENTS -- topic text for auto mode, or role name for single role mode.
30
-
31
- **Auto mode**: topic text (e.g., "Build real-time collaboration platform") triggers full pipeline.
32
- **Single role mode**: valid role name (e.g., "system-architect") runs one role analysis.
33
- **All output** goes to `.workflow/scratch/{YYYYMMDD}-brainstorm-{slug}/`.
34
- **Artifact registration**: On completion, registers artifact (type=brainstorm) in state.json.
35
- **Output boundary**: ALL file writes MUST target `{output_dir}/` or `.workflow/state.json` only. NEVER modify source code or files outside these paths.
36
-
37
- **Valid roles**: data-architect, product-manager, product-owner, scrum-master, subject-matter-expert, system-architect, test-strategist, ui-designer, ux-expert
38
-
39
- **Flags**:
40
- - `--yes` / `-y`: Auto mode, skip interactive questions, use defaults
41
- - `--count N`: Number of roles to select (default 3, max 9)
42
- - `--session ID`: Use existing session
43
- - `--update`: Update existing analysis (single role)
44
- - `--skip-questions`: Skip context gathering questions
45
- - `--include-questions`: Force context gathering even if analysis exists
46
- - `--style-skill PKG`: Style package for ui-designer role
47
-
48
- ### Pre-load specs
49
- 1. **Architecture specs**: Run `maestro spec load --category arch` to load architecture constraints. Use as context for multi-role analysis — ensures roles respect documented decisions.
50
- 2. Optionalproceed without if unavailable.
51
-
52
- ### Role Knowledge
53
- 1. Browse accumulated knowledge for this role:
54
- `maestro wiki list --category arch`
55
- 2. Analyze the index, identify entries relevant to the current task
56
- 3. Load selected documents:
57
- `maestro wiki load <id1> [id2] [id3...]`
58
- 4. Review loaded knowledge before proceeding
59
- </context>
60
-
61
- <execution>
62
- Follow '~/.maestro/workflows/brainstorm.md' completely.
63
-
64
- **Next-step routing on completion:**
65
-
66
- Auto mode:
67
- - Project not initialized Skill({ skill: "maestro-init" })
68
- - Project initialized, need spec package Skill({ skill: "maestro-roadmap", args: "--mode full --from-brainstorm {session_id}" })
69
- - Project initialized, quick roadmap Skill({ skill: "maestro-roadmap", args: "--from-brainstorm {session_id}" })
70
- - Need deeper analysis first → Skill({ skill: "maestro-analyze", args: "{topic}" })
71
- - `html-prototypes/` produced with 2+ files and user wants to browse load `~/.maestro/workflows/brainstorm-visualize.md` and launch visualizer server (optional, user-triggered)
72
- - DESIGN.md established during Step 3.5 → suggest: "Run `/maestro-impeccable build <feature-description>` to build with the established design system"
73
-
74
- Single role mode:
75
- - More roles needed → Skill({ skill: "maestro-brainstorm", args: "{next_role} --session {session_id}" })
76
- - All roles done, run synthesis → Skill({ skill: "maestro-brainstorm", args: "{topic} --session {session_id}" })
77
- </execution>
78
-
79
- <error_codes>
80
- | Code | Severity | Condition | Recovery |
81
- |------|----------|-----------|----------|
82
- | E001 | error | Topic or role argument required | Prompt user for topic text or role name |
83
- | E002 | error | No active session for single role mode | Guide user to run auto mode first |
84
- | E003 | error | Invalid role name | Show valid roles list |
85
- | W001 | warning | Fewer than 10 ideas in divergent phase | Proceed with available ideas |
86
- | W002 | warning | Project context (.workflow/) not found | Continue without project context |
87
- | W003 | warning | Role template not found | Use generic analysis structure |
88
- | W004 | warning | Validation score < 60 | Log warning, suggest manual review |
89
- | W005 | warning | External research agent failed | Continue without designResearchContext |
90
- </error_codes>
91
-
92
- <success_criteria>
93
- **Auto mode**:
94
- - [ ] guidance-specification.md with RFC 2119 keywords, terminology, non-goals, feature decomposition
95
- - [ ] design-research.md persisted when Step 1.7 external research ran (fail-soft: absence not a failure)
96
- - [ ] Spec Review Gate passed (Step 3.5) or `--yes` bypassed
97
- - [ ] Role analysis files for each selected NON-UI role in `.brainstorming/{role}/`
98
- - [ ] If `ui-designer` in selected_roles AND Step 3.5 ran: `.workflow/impeccable/DESIGN.md` exists (visual style established via impeccable explore)
99
- - [ ] If `ui-designer` in selected_roles: `ui-designer/analysis.md` exists with UX analysis (interaction flows, state design, information architecture)
100
- - [ ] Feature specs in `.brainstorming/feature-specs/` (or synthesis-specification.md)
101
- - [ ] UI-bearing feature specs reference DESIGN.md for visual constraints in Section 3 (Interface Contract)
102
- - [ ] feature-index.json and synthesis-changelog.md
103
- - [ ] Final Output Gate passed (Step 5.5) or `--yes` bypassed
104
- - [ ] All user decisions captured with Decision Recording Protocol
105
- - [ ] Session metadata updated with completion status
106
- - [ ] Confidence scored per role completion and after cross-role analysis
107
- - [ ] Readiness gate checked before spec generation
108
- - [ ] Pressure pass completed on at least 1 feature spec
109
- - [ ] Confidence summary appended to synthesis-changelog.md
110
-
111
- **Single role mode**:
112
- - [ ] analysis.md written to `{output_dir}/{role}/`
113
- - [ ] Feature-point organization used when feature list available
114
- - [ ] Framework reference included when guidance-specification.md exists
115
- - [ ] Session metadata updated
116
- </success_criteria>
1
+ ---
2
+ name: maestro-brainstorm
3
+ description: Use when exploring ideas, evaluating approaches, or needing multi-perspective analysis before implementation
4
+ argument-hint: "[topic|role-name] [--yes] [--count N] [--session ID] [--update] [--skip-questions] [--include-questions] [--style-skill PKG]"
5
+ allowed-tools:
6
+ - Read
7
+ - Write
8
+ - Bash
9
+ - Glob
10
+ - Grep
11
+ - Agent
12
+ - AskUserQuestion
13
+ ---
14
+ <purpose>
15
+ Unified brainstorming combining interactive framework generation, multi-role parallel analysis, cross-role review, and resolution writeback. Two modes: Auto (full pipeline: guidance-specification → parallel {role}/ multi-file analysis → cross-role-reviewer compares Decision Digests for conflicts/gaps/synergies → user-confirmed resolutions patched into role files + logged in guidance §12) and Single Role (individual role analysis for an existing session). Outputs structured artifacts in `.workflow/scratch/brainstorm-{slug}-{date}/` ready for downstream planning (roadmap / analyze / blueprint consume `guidance-specification.md`).
16
+ </purpose>
17
+
18
+ <required_reading>
19
+ @~/.maestro/workflows/brainstorm.md
20
+ </required_reading>
21
+
22
+ <deferred_reading>
23
+ - [scratch-index.json](~/.maestro/templates/scratch-index.json) — read when operating in scratch mode
24
+ - [index.json](~/.maestro/templates/index.json) — read when operating in phase mode
25
+ - [brainstorm-visualize.md](~/.maestro/workflows/brainstorm-visualize.md) — read when html-prototypes/ produced and user wants to browse them
26
+ </deferred_reading>
27
+
28
+ <context>
29
+ $ARGUMENTS -- topic text for auto mode, or role name for single role mode.
30
+
31
+ **Auto mode**: topic text (e.g., "Build real-time collaboration platform") triggers full pipeline.
32
+ **Single role mode**: valid role name (e.g., "system-architect") runs one role analysis.
33
+ **All output** goes to `.workflow/scratch/brainstorm-{slug}-{YYYYMMDD}/` (orchestrator MUST resolve this to an absolute path before passing to sub-agents).
34
+ **Artifact registration**: On completion, registers artifact (type=brainstorm) in state.json.
35
+ **Output boundary**: ALL file writes MUST target `{output_dir}/` or `.workflow/state.json` only. NEVER modify source code or files outside these paths.
36
+ **Produced files**: `guidance-specification.md`, `design-research.md` (optional), `{role}/analysis.md` + `{role}/analysis-F-*.md` + `{role}/findings-*.md` (per selected role).
37
+
38
+ **Valid roles**: data-architect, product-manager, product-owner, scrum-master, subject-matter-expert, system-architect, test-strategist, ui-designer, ux-expert
39
+
40
+ **Flags**:
41
+ - `--yes` / `-y`: Auto mode, skip interactive questions, use defaults
42
+ - `--count N`: Number of roles to select (default 3, max 9)
43
+ - `--session ID`: Use existing session
44
+ - `--update`: Update existing analysis (single role)
45
+ - `--skip-questions`: Skip context gathering questions
46
+ - `--include-questions`: Force context gathering even if analysis exists
47
+ - `--style-skill PKG`: Style package for ui-designer role
48
+
49
+ ### Pre-load specs
50
+ 1. **Architecture specs**: Run `maestro spec load --category arch` to load architecture constraints. Use as context for multi-role analysis ensures roles respect documented decisions.
51
+ 2. Optional — proceed without if unavailable.
52
+
53
+ ### Role Knowledge
54
+ 1. Browse accumulated knowledge for this role:
55
+ `maestro wiki list --category arch`
56
+ 2. Analyze the index, identify entries relevant to the current task
57
+ 3. Load selected documents:
58
+ `maestro wiki load <id1> [id2] [id3...]`
59
+ 4. Review loaded knowledge before proceeding
60
+ </context>
61
+
62
+ <interview_protocol>
63
+ Interview the user relentlessly until shared understanding is reached. Active only in interactive mode; skip when `--yes/-y`, `--skip-questions`, `--session` (existing session), or input is already specific.
64
+
65
+ - 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.
66
+ - Search-first when uncertain: before asking, resolve via `state.json`, the session directory, `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.
67
+ - Writeback cadence: each time a decision settles, immediately append/update its row in `guidance-specification.md` §11 (create the section if absent). Do NOT batch writeback to the end — partial decisions must already be on disk before the next question.
68
+ - Branch jumps allowed: the user may switch freely between mode / role / upstream / sub-pipeline branches; sequence is not enforced, but every decision point must end with a definite answer.
69
+ - Scope guard: only ask about decisions owned by `brainstorm`. Do not pre-resolve roadmap/plan choices.
70
+
71
+ Decision points: mode (auto / single-role / review-only) / role selection and `--count` / `--from` upstream source / whether to enable design-research and the DESIGN.md sub-pipeline.
72
+
73
+ Exit: on consensus or explicit user signal to proceed, finalize session metadata. The §11 table (already populated incrementally) uses this schema:
74
+ `| # | Decision | Choice | Source (user / code / default) |`
75
+ </interview_protocol>
76
+
77
+ <execution>
78
+ Follow '~/.maestro/workflows/brainstorm.md' completely.
79
+
80
+ **Next-step routing on completion:**
81
+
82
+ Auto mode:
83
+ - Project not initialized Skill({ skill: "maestro-init" })
84
+ - Project initialized, need formal spec package Skill({ skill: "maestro-blueprint", args: "--from brainstorm:{artifact_id}" })
85
+ - Project initialized, quick roadmap Skill({ skill: "maestro-roadmap", args: "--from brainstorm:{artifact_id}" })
86
+ - Need deeper analysis first Skill({ skill: "maestro-analyze", args: "{topic} --from brainstorm:{artifact_id}" })
87
+ - `html-prototypes/` produced with 2+ files and user wants to browse load `~/.maestro/workflows/brainstorm-visualize.md` and launch visualizer server (optional, user-triggered)
88
+ - DESIGN.md established during Step 3.5 suggest: "Run `/maestro-impeccable build <feature-description>` to build with the established design system"
89
+
90
+ Single role mode:
91
+ - More roles needed → Skill({ skill: "maestro-brainstorm", args: "{next_role} --session {session_id}" })
92
+ - All roles done, run synthesis → Skill({ skill: "maestro-brainstorm", args: "{topic} --session {session_id}" })
93
+ </execution>
94
+
95
+ <error_codes>
96
+ | Code | Severity | Condition | Recovery |
97
+ |------|----------|-----------|----------|
98
+ | E001 | error | Topic or role argument required | Prompt user for topic text or role name |
99
+ | E002 | error | No active session for single role mode | Guide user to run auto mode first |
100
+ | E003 | error | Invalid role name | Show valid roles list |
101
+ | E006 | error | `--review-only` but no `{role}/analysis.md` found | Run auto or single-role mode first |
102
+ | E007 | error | `--review-only` but `guidance-specification.md` missing | Run auto mode to generate guidance first |
103
+ | W001 | warning | Fewer than 10 ideas in divergent phase | Proceed with available ideas |
104
+ | W002 | warning | Project context (.workflow/) not found | Continue without project context |
105
+ | W003 | warning | Role template not found | Use generic analysis structure |
106
+ | W004 | warning | Validation score < 60 | Log warning, suggest manual review |
107
+ | W005 | warning | External research agent failed | Continue without designResearchContext |
108
+ | W006 | warning | Reviewer patch_targets heading drift (no match) | Skip that patch; report in final summary |
109
+ </error_codes>
110
+
111
+ <success_criteria>
112
+ **Auto mode**:
113
+ - [ ] Interactive mode: interview decision table written to `guidance-specification.md` §11 and session metadata
114
+ - [ ] `guidance-specification.md` with RFC 2119 keywords, terminology, non-goals, feature decomposition (§10), decision tracking (§11), cross-role resolutions placeholder (§12)
115
+ - [ ] `design-research.md` persisted when Step 1.7 external research ran (fail-soft: absence not a failure)
116
+ - [ ] If `ui-designer` in selected_roles AND Step 3.5 ran: `.workflow/impeccable/DESIGN.md` exists (visual style established via impeccable explore)
117
+ - [ ] `{role}/analysis.md` written for each selected role, containing §2 Decision Digest (4 tables) + §3 Cross-Cutting Foundations + §4 File Index
118
+ - [ ] `{role}/analysis-F-{id}-{slug}.md` written per feature (one file per feature, < 2000 words)
119
+ - [ ] `system-architect/analysis.md` §3 includes Data Model + State Machine when system-architect is selected
120
+ - [ ] `ui-designer/analysis.md` references DESIGN.md visual constraints when ui-designer is selected
121
+ - [ ] Each `{role}/analysis.md` §2 Decisions table has ≥ 1 row per feature
122
+ - [ ] Cross-role review (Step 4.5) executed; reviewer compares §2 Decision Digests; output includes `patch_targets[]` for every finding
123
+ - [ ] If findings exist: each accepted resolution applied via Edit (annotate / strikeout / append) AND logged in `guidance-specification.md` §12 "Cross-Role Resolutions"
124
+ - [ ] If zero findings: final report explicitly states "No cross-role issues detected"; guidance §12 unchanged
125
+ - [ ] Heading-drift patch failures surfaced in final report (if any)
126
+ - [ ] Session metadata updated with completion status (review_findings_count, resolutions_applied, patches_skipped)
127
+
128
+ **Single role mode**:
129
+ - [ ] `{role}/analysis.md` written with §2 Decision Digest + §4 File Index
130
+ - [ ] `{role}/analysis-F-*.md` written when guidance §10 feature list available
131
+ - [ ] §2 Decisions table references guidance decision IDs
132
+ - [ ] Session metadata updated
133
+ </success_criteria>
@@ -19,7 +19,7 @@ Since `.workflow/` is gitignored, this command explicitly copies project context
19
19
 
20
20
  Also supports `--sync` mode to pull latest main branch changes and shared artifacts into an active worktree (prevents source and artifact drift for long-lived worktrees).
21
21
 
22
- Produces `.workflow/worktrees.json` registry in the main worktree and `.workflow/worktree-scope.json` marker in the worktree.
22
+ Produces `.workflow/worktrees.json` registry in the main worktree and `.workflow/worktree-scope.json` marker in the worktree, and writes a scoped `state.json` inside the worktree containing only the forked milestone's artifacts.
23
23
  </purpose>
24
24
 
25
25
  <required_reading>
@@ -77,10 +77,11 @@ Read `.workflow/config.json`. If file missing, initialize with empty guard secti
77
77
  - Write config
78
78
 
79
79
  **`deny <path>`:**
80
- - Normalize path to forward slashes
80
+ - Normalize path to forward slashes, ensure trailing slash for directories
81
+ - If `guard.mode` is `allow`, switch to `deny` and clear paths with warning
81
82
  - Set `guard.mode = "deny"`
82
83
  - Add path to `guard.paths` (deduplicate)
83
- - Set `guard.enabled = true` if not already
84
+ - Set `guard.enabled = true` if not already (symmetric with `allow`: adding a deny path auto-enables the guard)
84
85
  - Write config
85
86
 
86
87
  **Step 4: Confirm**
@@ -74,6 +74,8 @@ responsive-design.md, spatial-design.md, typography.md, ux-writing.md
74
74
 
75
75
  ## Chains
76
76
 
77
+ Chain step names below reuse Command Routing names but resolve through the chain runner. To avoid ambiguity with Direct command invocation, internal display, todo items, and session status records always tag chain steps with the `impeccable:` prefix (e.g. `impeccable:craft`, `impeccable:critique`). The bare names in this table refer to the workflow file at `~/.maestro/workflows/impeccable/{name}.md` that the chain step reads.
78
+
77
79
  | Chain | Steps | Scenario |
78
80
  |-------|-------|----------|
79
81
  | build | teach? → explore? → shape → craft → critique → [refine] → audit → polish | New from scratch |
@@ -181,17 +183,17 @@ Before reading any command workflow:
181
183
  ## Chain Execution
182
184
 
183
185
  1. Prerequisites ✓
184
- 2. **Display chain preview**: parse chain definition, output full step preview:
186
+ 2. **Display chain preview**: parse chain definition, output full step preview (chain steps prefixed `impeccable:` to disambiguate from Direct commands):
185
187
  ```
186
188
  ── Chain: build ──────────────────────────
187
- 1. teach (conditional: PRODUCT.md missing)
188
- 2. explore (conditional: DESIGN.md missing)
189
- 3. shape
190
- 4. craft
191
- 5. critique ◆ quality gate (threshold: 26/40)
192
- 6. [refine] ↺ auto-fix loop (max: 3)
193
- 7. audit ◆ quality gate (threshold: 14/20)
194
- 8. polish
189
+ 1. impeccable:teach (conditional: PRODUCT.md missing)
190
+ 2. impeccable:explore (conditional: DESIGN.md missing)
191
+ 3. impeccable:shape
192
+ 4. impeccable:craft
193
+ 5. impeccable:critique ◆ quality gate (threshold: 26/40)
194
+ 6. impeccable:[refine] ↺ auto-fix loop (max: 3)
195
+ 7. impeccable:audit ◆ quality gate (threshold: 14/20)
196
+ 8. impeccable:polish
195
197
  ─────────────────────────────────────────
196
198
  Target: {target}
197
199
  ```
@@ -205,9 +207,9 @@ Before reading any command workflow:
205
207
  "gate_history": [], "loop_count": 0, "status": "running" }
206
208
  ```
207
209
  4. **TodoWrite init**: create todo items for all chain steps
208
- - One item per step, format: `[chain] step N: {command} — {description}`
210
+ - One item per step, format: `[chain] step N: impeccable:{command} — {description}` (use `impeccable:` prefix to disambiguate from Direct command items)
209
211
  - If conditional step is skipped, immediately mark completed
210
- - Quality gate steps include threshold: `[chain] step 5: critique ◆ gate ≥26/40`
212
+ - Quality gate steps include threshold: `[chain] step 5: impeccable:critique ◆ gate ≥26/40`
211
213
  5. For each step:
212
214
  - Read `~/.maestro/workflows/impeccable/{command}.md` → execute
213
215
  - **Step start**: TodoWrite marks current step in_progress
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: maestro-init
3
3
  description: Initialize project with auto state detection
4
- argument-hint: "[-y] [--from-brainstorm SESSION-ID]"
4
+ argument-hint: "[-y] [--from <source>]"
5
5
  allowed-tools:
6
6
  - Read
7
7
  - Write
@@ -25,7 +25,7 @@ Initialize a new project through auto state detection and unified flow. Invoked
25
25
  <context>
26
26
  **Flags:**
27
27
  - `-y` -- Automatic mode. After config questions, runs research without further interaction. Expects idea document via @ reference.
28
- - `--from-brainstorm SESSION-ID` -- Import from a brainstorm session. Reads guidance-specification.md to pre-fill project vision, goals, constraints, and terminology. Skips interactive questioning.
28
+ - `--from <source>` -- Load upstream context package (brainstorm:ID, @file, or path). Consumes context-package.json to pre-fill project vision, goals, constraints, and terminology. Skips interactive questioning. Alias: `--from-brainstorm`
29
29
 
30
30
  **Load project state if exists:**
31
31
  Check for `.workflow/state.json` -- loads context if project already initialized.
@@ -63,7 +63,7 @@ Other commands:
63
63
  |------|----------|-----------|----------|
64
64
  | E001 | error | No arguments provided when -y requires @ reference | Check arguments format, re-run with correct input |
65
65
  | E002 | error | .workflow/ already exists for greenfield init | Check .workflow/ directory state, resolve conflicts |
66
- | E003 | error | Brainstorm session not found (--from-brainstorm) | Check arguments format, re-run with correct input |
66
+ | E003 | error | Context source not found (--from / --from-brainstorm) | Check arguments format, re-run with correct input |
67
67
  | W001 | warning | Research agent failed, continuing with partial results | Retry research or proceed with partial results |
68
68
  </error_codes>
69
69
 
@@ -34,8 +34,10 @@ Milestone: $ARGUMENTS (optional -- defaults to current_milestone from state.json
34
34
 
35
35
  **Data source:**
36
36
  - `.workflow/state.json` — artifacts[], current_milestone, milestones[]
37
- - `.workflow/roadmap.md` — milestone-to-phase mapping
37
+ - `.workflow/roadmap.md` — milestone-to-phase mapping (standard milestones only)
38
38
  - Plan scratch dirs — for task status verification
39
+
40
+ **Adhoc milestone support (D-008):** When the target milestone has `type == "adhoc"` (or `type` field is missing, defaulting to `"standard"`), the audit skips roadmap.md parsing and phase coverage checks. It only validates artifact chain completeness (PLN→EXC exists) and runs integration checks.
39
41
  </context>
40
42
 
41
43
  <execution>
@@ -59,8 +61,8 @@ Audit checklist steps (phase coverage, ad-hoc completeness, execution completene
59
61
  </error_codes>
60
62
 
61
63
  <success_criteria>
62
- - [ ] All phases in milestone identified from roadmap
63
- - [ ] Artifact chains verified (ANL→PLN→EXC) per phase
64
+ - [ ] All phases in milestone identified from roadmap (standard) or milestone_obj.phases (adhoc)
65
+ - [ ] Artifact chains verified: ANL→PLN→EXC per phase (standard) or PLN→EXC exists (adhoc)
64
66
  - [ ] Ad-hoc artifacts checked for completion
65
67
  - [ ] Integration check completed (shared interfaces, data contracts)
66
68
  - [ ] Audit report written with clear PASS/FAIL verdict
@@ -26,8 +26,8 @@ Milestone: $ARGUMENTS (optional -- defaults to current_milestone from state.json
26
26
  **Requires:** `/maestro-milestone-audit` should have passed.
27
27
 
28
28
  **State files:**
29
- - `.workflow/state.json` — artifacts[], milestones[], current_milestone, milestone_history[]
30
- - `.workflow/roadmap.md` — milestone structure
29
+ - `.workflow/state.json` — artifacts[], milestones[] (with `type` field: `"standard"` | `"adhoc"`), current_milestone, milestone_history[]
30
+ - `.workflow/roadmap.md` — milestone structure (standard milestones only; adhoc milestones may not have roadmap)
31
31
  - `.workflow/milestones/{milestone}/audit-report.md` — audit results
32
32
  </context>
33
33
 
@@ -52,8 +52,10 @@ If user confirms promotion, invoke `Skill({ skill: "spec-add", args: "<category>
52
52
 
53
53
  **Next-step routing on completion:**
54
54
  - Cut a release → `/maestro-milestone-release`
55
- - Next milestone → `/maestro-analyze` or `/maestro-plan 1`
55
+ - Next milestone → `/maestro-analyze` or `/maestro-plan 1` (standard milestones only)
56
56
  - View state → `/manage-status`
57
+
58
+ **Adhoc milestone (D-008):** When completing an adhoc milestone, skip roadmap snapshot and do not advance to next milestone. Set `current_milestone = null`, `status = "idle"`. Adhoc milestones are self-contained — no successor in roadmap chain.
57
59
  </execution>
58
60
 
59
61
  <error_codes>
@@ -69,7 +71,7 @@ If user confirms promotion, invoke `Skill({ skill: "spec-add", args: "<category>
69
71
  - [ ] Scratch artifacts moved to milestones/{M}/artifacts/
70
72
  - [ ] Artifact entries archived to milestone_history
71
73
  - [ ] Knowhow extracted to specs/learnings.md
72
- - [ ] state.json updated: next milestone as current, artifacts[] cleared
73
- - [ ] Roadmap snapshot saved
74
+ - [ ] state.json updated: next milestone as current (standard) or current_milestone=null (adhoc), artifacts[] cleared
75
+ - [ ] Roadmap snapshot saved (standard only; adhoc skips)
74
76
  - [ ] project.md Context updated with milestone summary
75
77
  </success_criteria>
@@ -44,7 +44,7 @@ $ARGUMENTS -- optional explicit version string and flags.
44
44
  </context>
45
45
 
46
46
  <execution>
47
- Follow '~/.maestro/workflows/release.md' completely.
47
+ Follow '~/.maestro/workflows/milestone-release.md' completely.
48
48
 
49
49
  **High-level flow:**
50
50
  1. Validate preconditions (milestone completed, clean tree, audit PASS)
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: maestro-plan
3
3
  description: Use when creating, revising, or verifying an execution plan for a phase or task
4
- argument-hint: "[phase] [--collab] [--spec SPEC-xxx] [-y] [--gaps] [--tdd] [--dir <path>] [--revise [instructions]] [--check <plan-dir>]"
4
+ argument-hint: "[phase] [--collab] [--spec SPEC-xxx] [-y] [--gaps] [--tdd] [--dir <path>] [--from <source>] [--revise [instructions]] [--check <plan-dir>]"
5
5
  allowed-tools:
6
6
  - Read
7
7
  - Write
@@ -39,12 +39,24 @@ $ARGUMENTS — phase number, or no args for milestone-wide planning, with option
39
39
  Scope routing, base flags (`--collab`, `--spec`, `-y`, `--gaps`, `--dir`), output directory format, and artifact registration are defined in workflow plan.md.
40
40
 
41
41
  **Command-level flags** (extensions beyond workflow base):
42
+ - `--from <source>`: Load upstream context directly (bypasses roadmap requirement):
43
+ - `analyze:ANL-xxx` → CONTEXT_DIR = artifact path, scope = "standalone"
44
+ - `blueprint:BLP-xxx` → CONTEXT_DIR = blueprint path, scope = "standalone"
45
+ - `@file` or `path/` → load context-package.json from path
42
46
  - `--revise [instructions]` -- See workflow plan.md § Revise Mode
43
47
  - `--check <plan-dir>` -- See workflow plan.md § Check Mode
44
48
 
45
- **Upstream context:**
46
- - Reads `context.md` from prior analyze artifact (auto-discovered from state.json or via --dir)
47
- - Reads `conclusions.json` if available (implementation_scope seeds task generation)
49
+ **Upstream context (resolution priority):**
50
+ 1. `--from analyze:ANL-xxx` uses analyze conclusions.implementation_scope directly
51
+ 2. `--from blueprint:BLP-xxx` uses blueprint requirements + architecture
52
+ 3. `--dir <path>` → explicit context directory (unchanged)
53
+ 4. Numeric arg → scope = "phase", resolve from roadmap (unchanged)
54
+ 5. No args + roadmap → scope = "milestone" (unchanged)
55
+ 6. No args + no roadmap → search state.json for latest analyze artifact, fallback standalone
56
+
57
+ **Ad-hoc milestone (D-008):** When scope resolves to "standalone" via the standard standalone resolution (no `--from` source), and `current_milestone == null`, plan auto-creates an adhoc milestone (`type: "adhoc"`) in state.json before proceeding. This ensures downstream milestone-audit/complete have a valid milestone context. See workflow plan.md § "Ad-hoc Milestone Auto-Creation".
58
+
59
+ **Exception (`--from analyze:ANL-xxx` / `blueprint:BLP-xxx`):** When scope is set to "standalone" by `--from`, skip adhoc milestone auto-creation — the upstream analyze/blueprint artifact already provides the milestone context (or is intentionally milestone-free). Adhoc creation in this path would conflict with the `--from` semantic of "this is a one-shot plan rooted in an existing artifact".
48
60
 
49
61
  ### Role Knowledge
50
62
  `maestro wiki list --category arch` → select relevant → `maestro wiki load`