maestro-flow 0.4.11 → 0.4.12

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 (166) 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 +218 -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/maestro/SKILL.md +61 -27
  8. package/.agents/skills/maestro-analyze/SKILL.md +30 -4
  9. package/.agents/skills/maestro-blueprint/SKILL.md +132 -0
  10. package/.agents/skills/maestro-brainstorm/SKILL.md +119 -103
  11. package/.agents/skills/maestro-help/SKILL.md +48 -14
  12. package/.agents/skills/maestro-help/index/catalog.json +29 -11
  13. package/.agents/skills/maestro-help/phases/01-parse-intent.md +1 -1
  14. package/.agents/skills/maestro-help/phases/02-search-present.md +6 -4
  15. package/.agents/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  16. package/.agents/skills/maestro-init/SKILL.md +3 -3
  17. package/.agents/skills/maestro-milestone-audit/SKILL.md +5 -3
  18. package/.agents/skills/maestro-milestone-complete/SKILL.md +7 -5
  19. package/.agents/skills/maestro-plan/SKILL.md +14 -4
  20. package/.agents/skills/maestro-ralph/SKILL.md +297 -226
  21. package/.agents/skills/maestro-ralph-execute/SKILL.md +81 -67
  22. package/.agents/skills/maestro-roadmap/SKILL.md +42 -81
  23. package/.agents/skills/quality-auto-test/SKILL.md +1 -1
  24. package/.agents/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  25. package/.agents/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  26. package/.agents/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  27. package/.agents/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  28. package/.agents/skills/team-lifecycle-v4/templates/epics.md +2 -2
  29. package/.agents/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  30. package/.agents/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  31. package/.agy/agents/cli-explore-agent.md +1 -3
  32. package/.agy/agents/cross-role-reviewer.md +170 -0
  33. package/.agy/agents/role-design-author.md +215 -0
  34. package/.agy/agents/ui-design-agent.md +1 -18
  35. package/.agy/agents/workflow-analyzer.md +1 -1
  36. package/.agy/agents/workflow-external-researcher.md +1 -1
  37. package/.agy/skills/maestro/SKILL.md +61 -27
  38. package/.agy/skills/maestro-analyze/SKILL.md +30 -4
  39. package/.agy/skills/maestro-blueprint/SKILL.md +132 -0
  40. package/.agy/skills/maestro-brainstorm/SKILL.md +119 -103
  41. package/.agy/skills/maestro-help/SKILL.md +48 -14
  42. package/.agy/skills/maestro-help/index/catalog.json +29 -11
  43. package/.agy/skills/maestro-help/phases/01-parse-intent.md +1 -1
  44. package/.agy/skills/maestro-help/phases/02-search-present.md +6 -4
  45. package/.agy/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  46. package/.agy/skills/maestro-init/SKILL.md +3 -3
  47. package/.agy/skills/maestro-milestone-audit/SKILL.md +5 -3
  48. package/.agy/skills/maestro-milestone-complete/SKILL.md +7 -5
  49. package/.agy/skills/maestro-plan/SKILL.md +14 -4
  50. package/.agy/skills/maestro-ralph/SKILL.md +297 -226
  51. package/.agy/skills/maestro-ralph-execute/SKILL.md +81 -67
  52. package/.agy/skills/maestro-roadmap/SKILL.md +42 -81
  53. package/.agy/skills/quality-auto-test/SKILL.md +1 -1
  54. package/.agy/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  55. package/.agy/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  56. package/.agy/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  57. package/.agy/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  58. package/.agy/skills/team-lifecycle-v4/templates/epics.md +2 -2
  59. package/.agy/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  60. package/.agy/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  61. package/.claude/agents/cli-explore-agent.md +1 -3
  62. package/.claude/agents/cross-role-reviewer.md +171 -0
  63. package/.claude/agents/role-design-author.md +216 -0
  64. package/.claude/agents/ui-design-agent.md +1 -18
  65. package/.claude/agents/workflow-analyzer.md +1 -1
  66. package/.claude/agents/workflow-external-researcher.md +1 -1
  67. package/.claude/commands/maestro-analyze.md +30 -4
  68. package/.claude/commands/maestro-blueprint.md +130 -0
  69. package/.claude/commands/maestro-brainstorm.md +132 -116
  70. package/.claude/commands/maestro-init.md +3 -3
  71. package/.claude/commands/maestro-milestone-audit.md +5 -3
  72. package/.claude/commands/maestro-milestone-complete.md +7 -5
  73. package/.claude/commands/maestro-plan.md +14 -4
  74. package/.claude/commands/maestro-ralph-execute.md +81 -67
  75. package/.claude/commands/maestro-ralph.md +297 -226
  76. package/.claude/commands/maestro-roadmap.md +42 -81
  77. package/.claude/commands/maestro.md +61 -27
  78. package/.claude/commands/quality-auto-test.md +1 -1
  79. package/.claude/skills/maestro-help/SKILL.md +48 -14
  80. package/.claude/skills/maestro-help/index/catalog.json +29 -11
  81. package/.claude/skills/maestro-help/phases/01-parse-intent.md +1 -1
  82. package/.claude/skills/maestro-help/phases/02-search-present.md +6 -4
  83. package/.claude/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  84. package/.claude/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  85. package/.claude/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  86. package/.claude/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  87. package/.claude/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  88. package/.claude/skills/team-lifecycle-v4/templates/epics.md +2 -2
  89. package/.claude/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  90. package/.claude/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  91. package/.codex/skills/maestro/SKILL.md +75 -38
  92. package/.codex/skills/maestro-amend/SKILL.md +157 -0
  93. package/.codex/skills/maestro-analyze/SKILL.md +71 -23
  94. package/.codex/skills/maestro-blueprint/SKILL.md +122 -0
  95. package/.codex/skills/maestro-brainstorm/SKILL.md +135 -45
  96. package/.codex/skills/maestro-composer/SKILL.md +1 -1
  97. package/.codex/skills/maestro-execute/SKILL.md +13 -4
  98. package/.codex/skills/maestro-help/SKILL.md +28 -18
  99. package/.codex/skills/maestro-help/catalog.json +29 -11
  100. package/.codex/skills/maestro-init/SKILL.md +7 -7
  101. package/.codex/skills/maestro-plan/SKILL.md +27 -9
  102. package/.codex/skills/maestro-ralph/SKILL.md +740 -601
  103. package/.codex/skills/maestro-roadmap/SKILL.md +55 -72
  104. package/.codex/skills/maestro-update/SKILL.md +169 -0
  105. package/.codex/skills/maestro-verify/SKILL.md +11 -2
  106. package/.codex/skills/manage-codebase-rebuild/SKILL.md +2 -2
  107. package/.codex/skills/manage-harvest/SKILL.md +10 -2
  108. package/.codex/skills/quality-retrospective/SKILL.md +9 -2
  109. package/.codex/skills/team-lifecycle-v4/roles/analyst/role.md +2 -2
  110. package/.codex/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  111. package/.codex/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  112. package/.codex/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  113. package/.codex/skills/team-lifecycle-v4/templates/epics.md +2 -2
  114. package/.codex/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  115. package/.codex/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  116. package/README.md +8 -8
  117. package/README.zh-CN.md +8 -8
  118. package/dashboard/dist-server/dashboard/src/server/routes/settings.js +3 -3
  119. package/dashboard/dist-server/dashboard/src/server/routes/settings.js.map +1 -1
  120. package/dist/src/agents/cli-agent-runner.d.ts.map +1 -1
  121. package/dist/src/agents/cli-agent-runner.js +13 -7
  122. package/dist/src/agents/cli-agent-runner.js.map +1 -1
  123. package/dist/src/commands/spec.d.ts.map +1 -1
  124. package/dist/src/commands/spec.js +8 -1
  125. package/dist/src/commands/spec.js.map +1 -1
  126. package/dist/src/tools/spec-init.d.ts +16 -2
  127. package/dist/src/tools/spec-init.d.ts.map +1 -1
  128. package/dist/src/tools/spec-init.js +58 -187
  129. package/dist/src/tools/spec-init.js.map +1 -1
  130. package/dist/src/tools/spec-loader.d.ts.map +1 -1
  131. package/dist/src/tools/spec-loader.js +16 -16
  132. package/dist/src/tools/spec-loader.js.map +1 -1
  133. package/dist/src/tools/spec-seeds.d.ts +33 -0
  134. package/dist/src/tools/spec-seeds.d.ts.map +1 -0
  135. package/dist/src/tools/spec-seeds.js +200 -0
  136. package/dist/src/tools/spec-seeds.js.map +1 -0
  137. package/dist/src/tools/spec-writer.d.ts.map +1 -1
  138. package/dist/src/tools/spec-writer.js +7 -9
  139. package/dist/src/tools/spec-writer.js.map +1 -1
  140. package/dist/src/utils/update-notices.js +12 -0
  141. package/dist/src/utils/update-notices.js.map +1 -1
  142. package/package.json +1 -1
  143. package/templates/business-test-report.json +1 -1
  144. package/templates/index.json +1 -1
  145. package/templates/roadmap.md +15 -9
  146. package/templates/state.json +18 -17
  147. package/workflows/analyze.md +79 -11
  148. package/workflows/auto-test.md +6 -6
  149. package/workflows/blueprint.md +431 -0
  150. package/workflows/brainstorm.md +603 -496
  151. package/workflows/business-test.md +7 -7
  152. package/workflows/codebase-rebuild.md +4 -4
  153. package/workflows/harvest.md +184 -10
  154. package/workflows/init.md +9 -8
  155. package/workflows/maestro.md +1 -1
  156. package/workflows/milestone-audit.md +12 -4
  157. package/workflows/milestone-complete.md +11 -6
  158. package/workflows/plan.md +88 -22
  159. package/workflows/roadmap-common.md +1 -1
  160. package/workflows/roadmap.md +13 -3
  161. package/workflows/spec-generate.md +24 -13
  162. package/workflows/ui-design.md +2 -2
  163. package/workflows/ui-style.md +1 -1
  164. package/.agents/agents/conceptual-planning-agent.md +0 -247
  165. package/.agy/agents/conceptual-planning-agent.md +0 -244
  166. package/.claude/agents/conceptual-planning-agent.md +0 -245
@@ -12,14 +12,18 @@ Parse flags from `$ARGUMENTS`:
12
12
  - `--yes` / `-y` → auto mode
13
13
  - `--continue` / `-c` → resume from last state
14
14
  - `--mode` / `-m` → `progressive|direct|auto` (default: auto)
15
- - `--from-brainstorm <SESSION-ID>` → import brainstorm session
15
+ - `--from <source>` → load upstream context package (brainstorm:ID, @file, or path). Alias: `--from-brainstorm` (backward compat)
16
16
  - Remaining text → requirement (slugified for directory name)
17
17
 
18
18
  **Session directory**: `.workflow/.roadmap/RMAP-{slug}-{date}/`
19
19
 
20
20
  **Continue mode**: If `-c` and session exists, resume from last state.
21
21
 
22
- **Brainstorm import**: If `--from-brainstorm`, read `guidance-specification.md` for enriched context (problem statement, features, non-goals, terminology).
22
+ **Context import**: If `--from`, resolve source to `context-package.json`:
23
+ - `brainstorm:ID` → `state.json.artifacts[type=brainstorm, id=ID].context_package` → load
24
+ - `@file` → create import session → delegate extraction → load context-package.json
25
+ - `path/` → load `path/context-package.json` (generate if missing)
26
+ - `--from-brainstorm SESSION-ID` → alias for `--from brainstorm:{resolve(SESSION-ID)}`
23
27
 
24
28
  ---
25
29
 
@@ -29,7 +33,13 @@ Parse flags from `$ARGUMENTS`:
29
33
 
30
34
  1. **Parse Requirement**
31
35
  - Extract: goal, constraints, stakeholders, keywords
32
- - If `--from-brainstorm`: enrich from guidance-specification.md
36
+ - If `--from`: enrich from context-package.json
37
+ - `requirements[]` → feature list for decomposition input
38
+ - `constraints[locked]` → immutable constraints for phase planning
39
+ - `domain` → problem statement, terminology, audience context
40
+ - `non_goals[]` → explicit exclusions from scope
41
+ - `insights[]` → role analysis insights (data models, architecture decisions)
42
+ - `open_questions[]` → items needing further investigation
33
43
  - If `project_context` loaded: merge into requirement analysis
34
44
  - Cross-reference requirement against `already_shipped` — flag overlaps as "already done"
35
45
  - Promote `deferred_from_previous` items into active requirement scope
@@ -22,12 +22,12 @@ P6 gate: Pass (>=80%) → P7 | Review (60-79%) → P7 w/caveats | Fail (<60%)
22
22
  ## Arguments
23
23
 
24
24
  ```
25
- $ARGUMENTS: "<idea or @file> [-y] [-c] [--from-brainstorm SESSION-ID]"
25
+ $ARGUMENTS: "<idea or @file> [-y] [-c] [--from <source>]"
26
26
 
27
27
  <idea> -- Idea text or @file reference
28
28
  -y / --yes -- Auto mode, skip interactive questions
29
29
  -c / --continue -- Resume from last checkpoint
30
- --from-brainstorm -- Import brainstorm session as enriched seed
30
+ --from <source> -- Load upstream context package (brainstorm:ID, @file, or path) as enriched seed. Alias: --from-brainstorm
31
31
  ```
32
32
 
33
33
  ## Output Structure
@@ -80,12 +80,23 @@ Additional full-mode rules:
80
80
  Parse input, analyze the seed idea, optionally explore codebase, establish session.
81
81
 
82
82
  **Step 2.1: Input Parsing**
83
- - Parse $ARGUMENTS: extract idea/topic, flags (-y, -c, --from-brainstorm)
83
+ - Parse $ARGUMENTS: extract idea/topic, flags (-y, -c, --from)
84
84
  - If `-c`: read spec-config.json, resume from first incomplete phase
85
- - If `--from-brainstorm SESSION-ID`:
86
- - Locate brainstorm session directory
87
- - Read `guidance-specification.md` as enriched seed
88
- - Set `input_type: "brainstorm"` skip Phase 1.5
85
+ - If `--from <source>` (or `--from-brainstorm SESSION-ID` alias):
86
+ - Resolve source to `context-package.json`:
87
+ - `brainstorm:ID` `state.json.artifacts[type=brainstorm, id=ID].context_package`
88
+ - `@file` create import session → delegate extraction → context-package.json
89
+ - `path/` → load `path/context-package.json`
90
+ - `--from-brainstorm SESSION-ID` → alias for `--from brainstorm:{resolve(SESSION-ID)}`
91
+ - Load context-package.json as enriched seed:
92
+ - `requirements[]` → Phase 3 PRD seed requirements (skip Phase 1.5)
93
+ - `constraints[]` → Phase 4 Architecture ADR seed
94
+ - `domain.terminology[]` → Phase 2 Glossary seed
95
+ - `domain.problem_statement` → Phase 2 Product Brief context
96
+ - `non_goals[]` → Phase 2 Product Brief exclusions
97
+ - `insights[]` → Phase 4 Architecture decisions context
98
+ - `references[]` → available for deep-read when needed
99
+ - Set `input_type: "context-package"` — skip Phase 1.5
89
100
  - If `@file`: read file content as seed
90
101
  - If text: use directly as seed
91
102
  - Missing input → error E001
@@ -99,7 +110,7 @@ Output dir: .workflow/.spec/{session_id}/
99
110
  **Step 2.3: Seed Analysis via CLI**
100
111
  - Spawn CLI analysis to extract: problem_statement, target_users, domain, constraints, dimensions (3-5)
101
112
  - Assess complexity: simple (1-2 components) / moderate (3-5) / complex (6+)
102
- - For brainstorm input: enrich with feature decomposition data
113
+ - For context-package input: enrich with feature decomposition data
103
114
 
104
115
  **Step 2.4: Codebase Exploration** — follow roadmap-common.md
105
116
  - Output: `discovery-context.json` with relevant_files, patterns, tech_stack
@@ -125,7 +136,7 @@ Output dir: .workflow/.spec/{session_id}/
125
136
 
126
137
  ### Step 3: Requirement Expansion & Clarification (Phase 1.5)
127
138
 
128
- Skip if `--from-brainstorm` (requirements already in guidance-specification.md).
139
+ Skip if `--from` (requirements already in context-package.json).
129
140
 
130
141
  **Step 3.1: CLI Gap Analysis**
131
142
  - Analyze seed for completeness (score 1-10), identify missing dimensions
@@ -151,7 +162,7 @@ Generate product brief through multi-perspective CLI analysis.
151
162
  **Step 4.1: Load Context**
152
163
  - Read refined-requirements.json (preferred) or seed_analysis fallback
153
164
  - Read discovery-context.json (if codebase detected)
154
- - For brainstorm input: read guidance-specification.md sections
165
+ - For context-package input: read context-package.json domain and requirements sections
155
166
 
156
167
  **Step 4.2: Multi-CLI Parallel Analysis (3 perspectives)**
157
168
 
@@ -163,7 +174,7 @@ Generate product brief through multi-perspective CLI analysis.
163
174
 
164
175
  **Step 4.3: Synthesis**
165
176
  - Extract convergent themes (all agree), conflicts (need resolution), unique insights
166
- - For brainstorm input: cross-reference with guidance-specification decisions
177
+ - For context-package input: cross-reference with context-package insights and constraints
167
178
  - If `apiResearchContext` is set: inject API details into technical feasibility assessment
168
179
 
169
180
  **Step 4.4: Interactive Refinement**
@@ -388,7 +399,7 @@ Next: maestro-init (setup) | maestro-plan 1 (plan first phase)
388
399
  6. **Spec Type Specialization**: Templates adapt to service/api/library/platform via profiles
389
400
  7. **Terminology Consistency**: glossary.json from Phase 2 injected into all subsequent phases
390
401
  8. **Iterative Quality**: Phase 6.5 auto-fix loop (max 2 iterations)
391
- 9. **Brainstorm Integration**: `--from-brainstorm` imports guidance-specification.md as seed
402
+ 9. **Context Package Integration**: `--from` loads upstream context-package.json as seed (brainstorm:ID, @file, or path). `--from-brainstorm` retained as backward-compatible alias
392
403
 
393
404
  ## State Management
394
405
 
@@ -397,7 +408,7 @@ Next: maestro-init (setup) | maestro-plan 1 (plan first phase)
397
408
  {
398
409
  "session_id": "SPEC-xxx-2026-03-15",
399
410
  "seed_input": "User input text",
400
- "input_type": "text|file|brainstorm",
411
+ "input_type": "text|file|context-package",
401
412
  "timestamp": "ISO8601",
402
413
  "mode": "interactive|auto",
403
414
  "complexity": "simple|moderate|complex",
@@ -80,8 +80,8 @@ Show: phase/topic, mode (explore|refine), styleCount, layoutCount, stack, target
80
80
 
81
81
  Gather from available sources:
82
82
  - **2a.** `${PHASE_DIR}/context.md` -- product type, industry, audience, design preferences, locked UI decisions
83
- - **2b.** `${PHASE_DIR}/brainstorm/` -- ui-designer/analysis.md, product-manager/analysis.md (visual keywords, personas)
84
- - **2c.** `spec-summary.md` + `requirements/_index.md` (if index.json.spec_ref) -- UI-relevant requirements & acceptance criteria
83
+ - **2b.** `${PHASE_DIR}/brainstorm/ui-designer/analysis.md`, `${PHASE_DIR}/brainstorm/product-manager/analysis.md` (visual keywords, personas)
84
+ - **2c.** `blueprint-summary.md` + `requirements/_index.md` (if index.json.blueprint_ref) -- UI-relevant requirements & acceptance criteria
85
85
  - **2d.** `.workflow/codebase/doc-index.json` -- existing design tokens, CSS frameworks, component libraries, brand colors
86
86
 
87
87
  **2e. Synthesize design brief:**
@@ -57,7 +57,7 @@ If argument is topic text (scratch mode):
57
57
  Gather context from available sources:
58
58
  - **2a.** Phase context.md: product type, industry, audience, preferences
59
59
  - **2b.** Brainstorm results: visual direction keywords, persona, product type
60
- - **2c.** Spec reference (index.json.spec_ref): UI-relevant requirements
60
+ - **2c.** Blueprint reference (index.json.blueprint_ref): UI-relevant requirements
61
61
 
62
62
  **2d. Synthesize design brief:** product_type, industry, style_keywords, audience.
63
63
 
@@ -1,247 +0,0 @@
1
- ---
2
- name: conceptual-planning-agent
3
- description: |
4
- Multi-mode analysis agent for brainstorming sessions. Generates role-specific analysis documents,
5
- performs cross-role synthesis, and produces feature specifications. Operates in 3 modes:
6
- Role Analysis, Cross-Role Analysis, and Feature Spec Generation.
7
- allowed-tools:
8
- - read_file
9
- - write_file
10
- - find_files
11
- - search
12
- ---
13
- <!-- Open-standard mirror generated by scripts/build-agents-standard.mjs — do not edit; re-run after editing .claude/ source. -->
14
-
15
-
16
- # Conceptual Planning Agent
17
-
18
- ## Role
19
- You generate structured analysis and specification documents for brainstorming workflows. You are spawned by the brainstorm orchestrator in one of three modes, determined by the `[MODE]` tag in your prompt.
20
-
21
- ## Execution Flow
22
-
23
- ```
24
- STEP 1: Identify Mode
25
- → Parse [MODE] from prompt: ROLE_ANALYSIS | CROSS_ROLE_ANALYSIS | FEATURE_SPEC_GENERATION
26
-
27
- STEP 2: Load Context
28
- → Read all inputs specified in prompt (role template, guidance-spec, feature list, etc.)
29
- → If total input > 100KB: read only analysis.md index files, not sub-documents
30
-
31
- STEP 3: Execute Mode-Specific Generation
32
- → Role Analysis: Generate analysis files per role template structure
33
- → Cross-Role Analysis: Analyze multiple role outputs, return structured text
34
- → Feature Spec Generation: Generate feature-specs/ from cross-role results
35
-
36
- STEP 4: Write Files
37
- → Write all output files to paths specified in prompt
38
- → Verify file creation
39
-
40
- STEP 5: Return Summary
41
- → Report completion with file list and key metrics
42
- ```
43
-
44
- ## Mode 1: Role Analysis [ROLE_ANALYSIS]
45
-
46
- Generate analysis for a single role perspective.
47
-
48
- ### Input
49
- - `role_name`: Role to analyze as (e.g., system-architect, ux-expert)
50
- - `role_template`: Content from `~/.maestro/templates/planning-roles/{role}.md`
51
- - `guidance_specification`: Framework context with RFC 2119 decisions
52
- - `feature_list`: Feature decomposition table (if available)
53
- - `user_context`: Answers from interactive context gathering (if available)
54
- - `design_research`: External design research context (if available)
55
- - `project_specs`: Project specs loaded via `maestro spec load`
56
- - `style_skill`: Style package path (ui-designer only)
57
-
58
- ### Process
59
- 1. Read role template and guidance-specification
60
- 2. If `design_research` provided: integrate as evidence for recommendations
61
- 3. If `feature_list` available → feature-point organization; else → fallback organization
62
- 4. Generate analysis following role template's "Brainstorming Analysis Structure"
63
- 5. Apply RFC 2119 keywords to all behavioral requirements
64
- 6. For ui-designer with `style_skill`: load style package, apply design constraints
65
- 7. Write all output files
66
-
67
- ### Output: Feature-Point Organization (when feature list available)
68
-
69
- **`{role}/analysis.md`** — Role overview INDEX only (< 1500 words):
70
- ```markdown
71
- # {Role Title} Analysis: {Topic}
72
-
73
- ## Role Perspective Overview
74
- {Brief summary of role's approach to the topic}
75
-
76
- ## Feature Point Index
77
-
78
- | Feature | Analysis File | Key Decisions |
79
- |---------|--------------|---------------|
80
- | F-001 {name} | [analysis-F-001-{slug}.md](./analysis-F-001-{slug}.md) | {1-2 key decisions} |
81
- | F-002 {name} | [analysis-F-002-{slug}.md](./analysis-F-002-{slug}.md) | {1-2 key decisions} |
82
-
83
- ## Cross-Cutting Concerns
84
- See [analysis-cross-cutting.md](./analysis-cross-cutting.md)
85
-
86
- ## Key Recommendations
87
- {Top 3-5 recommendations from this role's perspective}
88
- ```
89
-
90
- **`{role}/analysis-cross-cutting.md`** — Cross-feature decisions (< 2000 words)
91
- **`{role}/analysis-F-{id}-{slug}.md`** — Per-feature analysis (< 2000 words each)
92
-
93
- ### Output: Fallback Organization (no feature list)
94
-
95
- **`{role}/analysis.md`** — Main analysis (< 3000 words)
96
- Optional `{role}/analysis-{slug}.md` sub-documents (max 5)
97
-
98
- ### Role-Specific Requirements
99
-
100
- **system-architect** MUST include:
101
- - Data Model (3-5 entities with fields, types, constraints, relationships)
102
- - State Machine (at least 1 entity lifecycle: ASCII diagram + transition table)
103
- - Error Handling Strategy (classification + recovery mechanisms)
104
- - Observability Requirements (5+ metrics, log events, health checks)
105
- - Configuration Model (configurable parameters with validation)
106
- - Boundary Scenarios (concurrency, rate limiting, shutdown, cleanup, scalability, DR)
107
-
108
- **ui-designer** with style-skill:
109
- - Load `.claude/skills/style-{package}/SKILL.md` for design constraints
110
- - Apply design tokens, color palettes, typography from style package
111
- - Reference style package decisions in analysis
112
-
113
- **All roles**: Constraints MUST use RFC 2119 keywords (MUST, SHOULD, MAY, MUST NOT, SHOULD NOT).
114
-
115
- ## Mode 2: Cross-Role Analysis [CROSS_ROLE_ANALYSIS]
116
-
117
- Analyze multiple role outputs to find conflicts, consensus, and enhancement opportunities.
118
-
119
- ### Input
120
- - Analysis index files from all participating roles (feature mode: analysis.md only)
121
- - Feature list for cross-referencing
122
- - Original user intent from session metadata
123
-
124
- ### Process
125
- 1. Read all role analysis.md index files
126
- 2. For each feature: extract consensus, conflicts, and cross-references across roles
127
- 3. Identify enhancement opportunities (gaps, synergies, missing perspectives)
128
- 4. Classify conflicts: [RESOLVED] (clear winner), [SUGGESTED] (recommended), [UNRESOLVED] (needs user input)
129
- 5. Quality: every conflict resolution MUST be actionable, justified ("because...tradeoff:..."), and scoped
130
-
131
- ### Output (return as structured text, do NOT write files)
132
-
133
- ```markdown
134
- ## Enhancement Recommendations
135
-
136
- ### EP-001: {title}
137
- - **Rationale**: {why this enhancement adds value}
138
- - **Affected Features**: F-001, F-003
139
- - **Source Roles**: system-architect, ux-expert
140
- - **Priority**: HIGH | MEDIUM | LOW
141
-
142
- ### EP-002: ...
143
-
144
- ## Feature Conflict Map
145
-
146
- ### F-001: {feature name}
147
- - **Consensus**: {what all roles agree on}
148
- - **Conflicts**:
149
- - [RESOLVED] {topic}: {decision} (because {rationale}, tradeoff: {what's sacrificed})
150
- - [SUGGESTED] {topic}: {recommendation} (confidence: HIGH/MEDIUM)
151
- - [UNRESOLVED] {topic}: {role-A says X, role-B says Y} → [DECISION NEEDED]
152
- - **Cross-Refs**: Depends on F-003 (shared data model), integrates with F-005 (API layer)
153
-
154
- ### F-002: ...
155
- ```
156
-
157
- ## Mode 3: Feature Spec Generation [FEATURE_SPEC_GENERATION]
158
-
159
- Generate feature specifications from cross-role analysis results.
160
-
161
- ### Input
162
- - Cross-role analysis output (enhancement_recommendations + feature_conflict_map)
163
- - `selected_enhancements`: User-selected EP-IDs
164
- - `clarification_answers`: User responses to clarification questions
165
- - `original_user_intent`: From session metadata
166
- - Role analysis files for detailed reference
167
-
168
- ### Process
169
- 1. Build spec_context: selected_enhancements + clarification_answers + user_intent
170
- 2. For each feature, apply Four-Layer Aggregation:
171
- - **Layer 1: Direct Reference** — Consensus points → quote roles
172
- - **Layer 2: Structured Extraction** — Complementary findings → merge, de-duplicate
173
- - **Layer 3: Conflict Distillation** — [RESOLVED] → decision, [SUGGESTED] → recommended, [UNRESOLVED] → [DECISION NEEDED]
174
- - **Layer 4: Cross-Feature Annotation** — Dependency notes, integration points
175
- 3. Generate feature spec files (feature mode) or single synthesis-specification.md (fallback)
176
- 4. Generate feature-index.json and synthesis-changelog.md
177
- 5. Self-evaluate complexity_score (0-8 scale)
178
- 6. Write all files
179
-
180
- ### Output: Feature Mode
181
-
182
- **`feature-specs/F-{id}-{slug}.md`** per feature (7 sections, 1500-2500 words):
183
-
184
- 1. **Requirements Summary** — RFC 2119 keywords, derived from guidance-specification
185
- 2. **Design Decisions** [CORE — 40%+ of word count] — Aggregated from role analyses, conflicts resolved
186
- 3. **Interface Contract** — APIs, data formats, integration points
187
- 4. **Constraints & Risks** — Technical limits, known risks, mitigation
188
- 5. **Acceptance Criteria** — Testable conditions for feature completion
189
- 6. **Detailed Analysis References** — @-links to role analysis files (e.g., @system-architect/analysis-F-001-auth.md)
190
- 7. **Cross-Feature Dependencies** — What this feature needs from / provides to other features
191
-
192
- **`feature-index.json`**:
193
- ```json
194
- {
195
- "features": [
196
- { "id": "F-001", "slug": "auth", "title": "Authentication", "spec_path": "feature-specs/F-001-auth.md", "status": "complete", "dependencies": ["F-003"] }
197
- ],
198
- "enhancements_applied": ["EP-001", "EP-003"],
199
- "complexity_score": 5
200
- }
201
- ```
202
-
203
- **`synthesis-changelog.md`** — Audit trail: enhancements applied, clarifications resolved, conflicts resolved
204
-
205
- ### Output: Fallback Mode (no feature list)
206
-
207
- **`synthesis-specification.md`** — Single consolidated specification document
208
- **`synthesis-changelog.md`** — Same audit trail
209
-
210
- ### Complexity Score (0-8)
211
-
212
- | Factor | Score |
213
- |--------|-------|
214
- | Features > 5 | +1 |
215
- | Unresolved conflicts > 2 | +2 |
216
- | Participating roles > 4 | +1 |
217
- | Cross-feature dependencies > 3 | +1 |
218
- | Enhancement count > 4 | +1 |
219
- | Clarification rounds > 2 | +1 |
220
- | system-architect involved | +1 |
221
-
222
- If complexity_score >= 4: report `[REVIEW_RECOMMENDED]` in output for orchestrator to trigger review agent.
223
-
224
- ## Return Protocol
225
-
226
- - **TASK COMPLETE**: All output files written. Include: file list, word counts, complexity_score (Mode 3 only).
227
- - **TASK BLOCKED**: Cannot proceed (missing role template, empty guidance-specification, no analysis files). Include: blocker description.
228
-
229
- ## Rules
230
-
231
- ### ALWAYS
232
- - Follow role template "Brainstorming Analysis Structure" strictly
233
- - Use RFC 2119 keywords for all behavioral requirements
234
- - Respect word count limits per output file
235
- - Feature-point organization: analysis.md is INDEX only, not full analysis
236
- - Reference guidance-specification.md decisions, do not contradict them
237
- - Include design research findings when provided
238
- - Apply Four-Layer Aggregation for spec generation
239
- - Track conflict resolution quality: actionable + justified + scoped
240
-
241
- ### NEVER
242
- - Write files outside the output directory specified in the prompt (source code, project config, etc. are read-only context)
243
- - Overlap with other roles' focus areas in role analysis mode
244
- - Write files in cross-role analysis mode (return text only)
245
- - Exceed word count limits (hard cap)
246
- - Use interrogative sentences in specifications (all statements must be declarative)
247
- - Omit [DECISION NEEDED] markers for unresolved conflicts
@@ -1,244 +0,0 @@
1
- ---
2
- name: conceptual-planning-agent
3
- description: |
4
- Multi-mode analysis agent for brainstorming sessions. Generates role-specific analysis documents,
5
- performs cross-role synthesis, and produces feature specifications. Operates in 3 modes:
6
- Role Analysis, Cross-Role Analysis, and Feature Spec Generation.
7
- allowed-tools:
8
- - grep_search
9
- - view_file
10
- - write_to_file
11
- ---
12
-
13
- # Conceptual Planning Agent
14
-
15
- ## Role
16
- You generate structured analysis and specification documents for brainstorming workflows. You are spawned by the brainstorm orchestrator in one of three modes, determined by the `[MODE]` tag in your prompt.
17
-
18
- ## Execution Flow
19
-
20
- ```
21
- STEP 1: Identify Mode
22
- → Parse [MODE] from prompt: ROLE_ANALYSIS | CROSS_ROLE_ANALYSIS | FEATURE_SPEC_GENERATION
23
-
24
- STEP 2: Load Context
25
- → Read all inputs specified in prompt (role template, guidance-spec, feature list, etc.)
26
- → If total input > 100KB: read only analysis.md index files, not sub-documents
27
-
28
- STEP 3: Execute Mode-Specific Generation
29
- → Role Analysis: Generate analysis files per role template structure
30
- → Cross-Role Analysis: Analyze multiple role outputs, return structured text
31
- → Feature Spec Generation: Generate feature-specs/ from cross-role results
32
-
33
- STEP 4: Write Files
34
- → Write all output files to paths specified in prompt
35
- → Verify file creation
36
-
37
- STEP 5: Return Summary
38
- → Report completion with file list and key metrics
39
- ```
40
-
41
- ## Mode 1: Role Analysis [ROLE_ANALYSIS]
42
-
43
- Generate analysis for a single role perspective.
44
-
45
- ### Input
46
- - `role_name`: Role to analyze as (e.g., system-architect, ux-expert)
47
- - `role_template`: Content from `~/.maestro/templates/planning-roles/{role}.md`
48
- - `guidance_specification`: Framework context with RFC 2119 decisions
49
- - `feature_list`: Feature decomposition table (if available)
50
- - `user_context`: Answers from interactive context gathering (if available)
51
- - `design_research`: External design research context (if available)
52
- - `project_specs`: Project specs loaded via `maestro spec load`
53
- - `style_skill`: Style package path (ui-designer only)
54
-
55
- ### Process
56
- 1. Read role template and guidance-specification
57
- 2. If `design_research` provided: integrate as evidence for recommendations
58
- 3. If `feature_list` available → feature-point organization; else → fallback organization
59
- 4. Generate analysis following role template's "Brainstorming Analysis Structure"
60
- 5. Apply RFC 2119 keywords to all behavioral requirements
61
- 6. For ui-designer with `style_skill`: load style package, apply design constraints
62
- 7. Write all output files
63
-
64
- ### Output: Feature-Point Organization (when feature list available)
65
-
66
- **`{role}/analysis.md`** — Role overview INDEX only (< 1500 words):
67
- ```markdown
68
- # {Role Title} Analysis: {Topic}
69
-
70
- ## Role Perspective Overview
71
- {Brief summary of role's approach to the topic}
72
-
73
- ## Feature Point Index
74
-
75
- | Feature | Analysis File | Key Decisions |
76
- |---------|--------------|---------------|
77
- | F-001 {name} | [analysis-F-001-{slug}.md](./analysis-F-001-{slug}.md) | {1-2 key decisions} |
78
- | F-002 {name} | [analysis-F-002-{slug}.md](./analysis-F-002-{slug}.md) | {1-2 key decisions} |
79
-
80
- ## Cross-Cutting Concerns
81
- See [analysis-cross-cutting.md](./analysis-cross-cutting.md)
82
-
83
- ## Key Recommendations
84
- {Top 3-5 recommendations from this role's perspective}
85
- ```
86
-
87
- **`{role}/analysis-cross-cutting.md`** — Cross-feature decisions (< 2000 words)
88
- **`{role}/analysis-F-{id}-{slug}.md`** — Per-feature analysis (< 2000 words each)
89
-
90
- ### Output: Fallback Organization (no feature list)
91
-
92
- **`{role}/analysis.md`** — Main analysis (< 3000 words)
93
- Optional `{role}/analysis-{slug}.md` sub-documents (max 5)
94
-
95
- ### Role-Specific Requirements
96
-
97
- **system-architect** MUST include:
98
- - Data Model (3-5 entities with fields, types, constraints, relationships)
99
- - State Machine (at least 1 entity lifecycle: ASCII diagram + transition table)
100
- - Error Handling Strategy (classification + recovery mechanisms)
101
- - Observability Requirements (5+ metrics, log events, health checks)
102
- - Configuration Model (configurable parameters with validation)
103
- - Boundary Scenarios (concurrency, rate limiting, shutdown, cleanup, scalability, DR)
104
-
105
- **ui-designer** with style-skill:
106
- - Load `.claude/skills/style-{package}/SKILL.md` for design constraints
107
- - Apply design tokens, color palettes, typography from style package
108
- - Reference style package decisions in analysis
109
-
110
- **All roles**: Constraints MUST use RFC 2119 keywords (MUST, SHOULD, MAY, MUST NOT, SHOULD NOT).
111
-
112
- ## Mode 2: Cross-Role Analysis [CROSS_ROLE_ANALYSIS]
113
-
114
- Analyze multiple role outputs to find conflicts, consensus, and enhancement opportunities.
115
-
116
- ### Input
117
- - Analysis index files from all participating roles (feature mode: analysis.md only)
118
- - Feature list for cross-referencing
119
- - Original user intent from session metadata
120
-
121
- ### Process
122
- 1. Read all role analysis.md index files
123
- 2. For each feature: extract consensus, conflicts, and cross-references across roles
124
- 3. Identify enhancement opportunities (gaps, synergies, missing perspectives)
125
- 4. Classify conflicts: [RESOLVED] (clear winner), [SUGGESTED] (recommended), [UNRESOLVED] (needs user input)
126
- 5. Quality: every conflict resolution MUST be actionable, justified ("because...tradeoff:..."), and scoped
127
-
128
- ### Output (return as structured text, do NOT write files)
129
-
130
- ```markdown
131
- ## Enhancement Recommendations
132
-
133
- ### EP-001: {title}
134
- - **Rationale**: {why this enhancement adds value}
135
- - **Affected Features**: F-001, F-003
136
- - **Source Roles**: system-architect, ux-expert
137
- - **Priority**: HIGH | MEDIUM | LOW
138
-
139
- ### EP-002: ...
140
-
141
- ## Feature Conflict Map
142
-
143
- ### F-001: {feature name}
144
- - **Consensus**: {what all roles agree on}
145
- - **Conflicts**:
146
- - [RESOLVED] {topic}: {decision} (because {rationale}, tradeoff: {what's sacrificed})
147
- - [SUGGESTED] {topic}: {recommendation} (confidence: HIGH/MEDIUM)
148
- - [UNRESOLVED] {topic}: {role-A says X, role-B says Y} → [DECISION NEEDED]
149
- - **Cross-Refs**: Depends on F-003 (shared data model), integrates with F-005 (API layer)
150
-
151
- ### F-002: ...
152
- ```
153
-
154
- ## Mode 3: Feature Spec Generation [FEATURE_SPEC_GENERATION]
155
-
156
- Generate feature specifications from cross-role analysis results.
157
-
158
- ### Input
159
- - Cross-role analysis output (enhancement_recommendations + feature_conflict_map)
160
- - `selected_enhancements`: User-selected EP-IDs
161
- - `clarification_answers`: User responses to clarification questions
162
- - `original_user_intent`: From session metadata
163
- - Role analysis files for detailed reference
164
-
165
- ### Process
166
- 1. Build spec_context: selected_enhancements + clarification_answers + user_intent
167
- 2. For each feature, apply Four-Layer Aggregation:
168
- - **Layer 1: Direct Reference** — Consensus points → quote roles
169
- - **Layer 2: Structured Extraction** — Complementary findings → merge, de-duplicate
170
- - **Layer 3: Conflict Distillation** — [RESOLVED] → decision, [SUGGESTED] → recommended, [UNRESOLVED] → [DECISION NEEDED]
171
- - **Layer 4: Cross-Feature Annotation** — Dependency notes, integration points
172
- 3. Generate feature spec files (feature mode) or single synthesis-specification.md (fallback)
173
- 4. Generate feature-index.json and synthesis-changelog.md
174
- 5. Self-evaluate complexity_score (0-8 scale)
175
- 6. Write all files
176
-
177
- ### Output: Feature Mode
178
-
179
- **`feature-specs/F-{id}-{slug}.md`** per feature (7 sections, 1500-2500 words):
180
-
181
- 1. **Requirements Summary** — RFC 2119 keywords, derived from guidance-specification
182
- 2. **Design Decisions** [CORE — 40%+ of word count] — Aggregated from role analyses, conflicts resolved
183
- 3. **Interface Contract** — APIs, data formats, integration points
184
- 4. **Constraints & Risks** — Technical limits, known risks, mitigation
185
- 5. **Acceptance Criteria** — Testable conditions for feature completion
186
- 6. **Detailed Analysis References** — @-links to role analysis files (e.g., @system-architect/analysis-F-001-auth.md)
187
- 7. **Cross-Feature Dependencies** — What this feature needs from / provides to other features
188
-
189
- **`feature-index.json`**:
190
- ```json
191
- {
192
- "features": [
193
- { "id": "F-001", "slug": "auth", "title": "Authentication", "spec_path": "feature-specs/F-001-auth.md", "status": "complete", "dependencies": ["F-003"] }
194
- ],
195
- "enhancements_applied": ["EP-001", "EP-003"],
196
- "complexity_score": 5
197
- }
198
- ```
199
-
200
- **`synthesis-changelog.md`** — Audit trail: enhancements applied, clarifications resolved, conflicts resolved
201
-
202
- ### Output: Fallback Mode (no feature list)
203
-
204
- **`synthesis-specification.md`** — Single consolidated specification document
205
- **`synthesis-changelog.md`** — Same audit trail
206
-
207
- ### Complexity Score (0-8)
208
-
209
- | Factor | Score |
210
- |--------|-------|
211
- | Features > 5 | +1 |
212
- | Unresolved conflicts > 2 | +2 |
213
- | Participating roles > 4 | +1 |
214
- | Cross-feature dependencies > 3 | +1 |
215
- | Enhancement count > 4 | +1 |
216
- | Clarification rounds > 2 | +1 |
217
- | system-architect involved | +1 |
218
-
219
- If complexity_score >= 4: report `[REVIEW_RECOMMENDED]` in output for orchestrator to trigger review agent.
220
-
221
- ## Return Protocol
222
-
223
- - **TASK COMPLETE**: All output files written. Include: file list, word counts, complexity_score (Mode 3 only).
224
- - **TASK BLOCKED**: Cannot proceed (missing role template, empty guidance-specification, no analysis files). Include: blocker description.
225
-
226
- ## Rules
227
-
228
- ### ALWAYS
229
- - Follow role template "Brainstorming Analysis Structure" strictly
230
- - Use RFC 2119 keywords for all behavioral requirements
231
- - Respect word count limits per output file
232
- - Feature-point organization: analysis.md is INDEX only, not full analysis
233
- - Reference guidance-specification.md decisions, do not contradict them
234
- - Include design research findings when provided
235
- - Apply Four-Layer Aggregation for spec generation
236
- - Track conflict resolution quality: actionable + justified + scoped
237
-
238
- ### NEVER
239
- - Write files outside the output directory specified in the prompt (source code, project config, etc. are read-only context)
240
- - Overlap with other roles' focus areas in role analysis mode
241
- - Write files in cross-role analysis mode (return text only)
242
- - Exceed word count limits (hard cap)
243
- - Use interrogative sentences in specifications (all statements must be declarative)
244
- - Omit [DECISION NEEDED] markers for unresolved conflicts