maestro-flow 0.3.8 → 0.3.9

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 (211) hide show
  1. package/.claude/commands/learn-decompose.md +3 -3
  2. package/.claude/commands/learn-follow.md +5 -5
  3. package/.claude/commands/learn-investigate.md +3 -3
  4. package/.claude/commands/learn-retro.md +6 -6
  5. package/.claude/commands/learn-second-opinion.md +3 -3
  6. package/.claude/commands/maestro-analyze.md +123 -99
  7. package/.claude/commands/maestro-brainstorm.md +2 -2
  8. package/.claude/commands/maestro-execute.md +137 -97
  9. package/.claude/commands/maestro-fork.md +111 -0
  10. package/.claude/commands/maestro-init.md +6 -6
  11. package/.claude/commands/maestro-merge.md +77 -0
  12. package/.claude/commands/maestro-milestone-audit.md +72 -60
  13. package/.claude/commands/maestro-milestone-complete.md +67 -59
  14. package/.claude/commands/maestro-milestone-release.md +6 -6
  15. package/.claude/commands/maestro-plan.md +151 -130
  16. package/.claude/commands/maestro-quick.md +4 -4
  17. package/.claude/commands/maestro-roadmap.md +5 -5
  18. package/.claude/commands/maestro-spec-generate.md +5 -5
  19. package/.claude/commands/maestro-ui-design.md +3 -3
  20. package/.claude/commands/maestro-verify.md +106 -87
  21. package/.claude/commands/maestro.md +10 -4
  22. package/.claude/commands/manage-codebase-rebuild.md +4 -4
  23. package/.claude/commands/manage-codebase-refresh.md +1 -1
  24. package/.claude/commands/manage-harvest.md +5 -5
  25. package/.claude/commands/manage-issue-discover.md +1 -1
  26. package/.claude/commands/manage-issue-execute.md +6 -6
  27. package/.claude/commands/manage-issue.md +6 -6
  28. package/.claude/commands/manage-learn.md +2 -2
  29. package/.claude/commands/manage-memory-capture.md +4 -4
  30. package/.claude/commands/manage-memory.md +2 -2
  31. package/.claude/commands/manage-status.md +24 -24
  32. package/.claude/commands/quality-business-test.md +5 -5
  33. package/.claude/commands/quality-debug.md +4 -4
  34. package/.claude/commands/quality-integration-test.md +4 -4
  35. package/.claude/commands/quality-refactor.md +3 -3
  36. package/.claude/commands/quality-retrospective.md +2 -2
  37. package/.claude/commands/quality-review.md +4 -4
  38. package/.claude/commands/quality-sync.md +3 -3
  39. package/.claude/commands/quality-test-gen.md +4 -4
  40. package/.claude/commands/quality-test.md +9 -9
  41. package/.claude/commands/spec-add.md +2 -2
  42. package/.claude/commands/spec-load.md +1 -1
  43. package/.claude/commands/spec-setup.md +5 -5
  44. package/.claude/commands/wiki-connect.md +3 -3
  45. package/.claude/commands/wiki-digest.md +4 -4
  46. package/.codex/skills/maestro-analyze/SKILL.md +52 -14
  47. package/.codex/skills/maestro-execute/SKILL.md +27 -26
  48. package/.codex/skills/maestro-milestone-audit/SKILL.md +103 -209
  49. package/.codex/skills/maestro-milestone-complete/SKILL.md +149 -158
  50. package/.codex/skills/maestro-plan/SKILL.md +47 -17
  51. package/.codex/skills/maestro-roadmap/SKILL.md +3 -2
  52. package/.codex/skills/team-coordinate/roles/coordinator/commands/monitor.md +2 -2
  53. package/.codex/skills/team-executor/roles/executor/commands/monitor.md +1 -1
  54. package/.codex/skills/team-lifecycle-v4/roles/coordinator/commands/monitor.md +2 -2
  55. package/.codex/skills/team-lifecycle-v4/specs/knowledge-transfer.md +2 -2
  56. package/.codex/skills/team-quality-assurance/roles/coordinator/commands/monitor.md +1 -1
  57. package/.codex/skills/team-review/roles/coordinator/commands/monitor.md +1 -1
  58. package/.codex/skills/team-tech-debt/roles/coordinator/commands/monitor.md +1 -1
  59. package/.codex/skills/team-testing/roles/coordinator/commands/monitor.md +1 -1
  60. package/README.md +19 -14
  61. package/README.zh-CN.md +16 -12
  62. package/bin/maestro-mcp.js +1 -1
  63. package/chains/_intent-map.json +21 -9
  64. package/chains/_router.json +30 -77
  65. package/chains/brainstorm-driven.json +17 -6
  66. package/chains/full-lifecycle.json +22 -23
  67. package/chains/milestone-close.json +20 -7
  68. package/chains/milestone-fork-merge.json +50 -0
  69. package/chains/roadmap-driven.json +17 -6
  70. package/chains/spec-driven.json +17 -6
  71. package/dashboard/dist/assets/{ArtifactsPage-BmPOu8sO.js → ArtifactsPage-DZNCi6tn.js} +12 -7
  72. package/dashboard/dist/assets/ChatInput-Bvr-FeEq.js +49 -0
  73. package/dashboard/dist/assets/ChatPage-D9zTkJZo.js +22 -0
  74. package/dashboard/dist/assets/CollabPage-B4NAHXS2.js +1 -0
  75. package/dashboard/dist/assets/ExecutionPanel-CFt4LJyq.js +1 -0
  76. package/dashboard/dist/assets/KanbanPage-C8USth6H.js +21 -0
  77. package/dashboard/dist/assets/{MarkdownRenderer-BjZ43aSa.js → MarkdownRenderer-X4af_WNb.js} +1 -1
  78. package/dashboard/dist/assets/McpPage-BKfCVIyU.js +21 -0
  79. package/dashboard/dist/assets/OutputPanel-BlBQFJSW.js +1 -0
  80. package/dashboard/dist/assets/ProblemsPanel-De3DLvoI.js +1 -0
  81. package/dashboard/dist/assets/{RequirementBoardPage-B7yRL0s_.js → RequirementBoardPage-Bf1trzqs.js} +2 -2
  82. package/dashboard/dist/assets/{RequirementPage-D8J_-b6O.js → RequirementPage-Bllxe2XI.js} +10 -5
  83. package/dashboard/dist/assets/{SpecsPage-6lO8v8_C.js → SpecsPage-9lwxKT27.js} +2 -2
  84. package/dashboard/dist/assets/{SupervisorPage-Ds5N378a.js → SupervisorPage-SusdfHFq.js} +1 -1
  85. package/dashboard/dist/assets/{TeamsPage-DrkKr17T.js → TeamsPage-DsuM6OwC.js} +2 -2
  86. package/dashboard/dist/assets/TreeBrowser-Q12qobZs.js +6 -0
  87. package/dashboard/dist/assets/WorkflowPage-D_Fzdy3_.js +6 -0
  88. package/dashboard/dist/assets/{arrow-left-CadP5YgU.js → arrow-left-Bqtb2hle.js} +1 -1
  89. package/dashboard/dist/assets/{check-5xufDzS8.js → check-u6fGOwQO.js} +1 -1
  90. package/dashboard/dist/assets/{chevron-right-CYbpR4ev.js → chevron-right-Csu22t58.js} +1 -1
  91. package/dashboard/dist/assets/{circle-Bm-5Q-Yh.js → circle-CMrkbRNg.js} +1 -1
  92. package/dashboard/dist/assets/{circle-alert-BqcYuT7x.js → circle-alert-c3tH1P4z.js} +1 -1
  93. package/dashboard/dist/assets/{circle-check-big-yyzAFysU.js → circle-check-big-TDSeWstm.js} +1 -1
  94. package/dashboard/dist/assets/{circle-check-DEVzW_lm.js → circle-check-gYxxSYuH.js} +1 -1
  95. package/dashboard/dist/assets/{code-BBdC8Wmw.js → code-CFN2uX9V.js} +1 -1
  96. package/dashboard/dist/assets/{columns-3-CQ9Trztr.js → columns-3-38xIDlzy.js} +1 -1
  97. package/dashboard/dist/assets/{download-DayuF-sn.js → download-DC7KkKyP.js} +1 -1
  98. package/dashboard/dist/assets/{folder-CqXeSKeC.js → folder-CWq_lAnf.js} +1 -1
  99. package/dashboard/dist/assets/index-DWG-WrzT.js +231 -0
  100. package/dashboard/dist/assets/{index-Dru5HYy0.js → index-Do71weNR.js} +1 -1
  101. package/dashboard/dist/assets/index-GUNJodSR.css +1 -0
  102. package/dashboard/dist/assets/{list-DBOD6IUt.js → list-CgIP_2A-.js} +1 -1
  103. package/dashboard/dist/assets/{minus-fQI1Syn2.js → minus-DYoN5UGk.js} +1 -1
  104. package/dashboard/dist/assets/{pen-line-Bkbbngl5.js → pen-line-Bh_WKYHm.js} +1 -1
  105. package/dashboard/dist/assets/{proxy-teW12DdZ.js → proxy-BKxDAKTj.js} +1 -1
  106. package/dashboard/dist/assets/{search-Bq3ygFUW.js → search-SieXnOgr.js} +1 -1
  107. package/dashboard/dist/assets/{shallow-22ZN8sFt.js → shallow-Bme1JY57.js} +1 -1
  108. package/dashboard/dist/assets/{table-BEYtdWc4.js → table-llyEtj-7.js} +1 -1
  109. package/dashboard/dist/assets/terminal-BB3Xfuv5.js +6 -0
  110. package/dashboard/dist/assets/{trash-2-DMqGBgcF.js → trash-2-C8f4vFFM.js} +1 -1
  111. package/dashboard/dist/assets/{zap-9DVkGVtt.js → zap-4uwlzVm0.js} +1 -1
  112. package/dashboard/dist/index.html +2 -2
  113. package/dashboard/dist-server/dashboard/src/server/agents/claude-code-adapter.js +8 -4
  114. package/dashboard/dist-server/dashboard/src/server/agents/claude-code-adapter.js.map +1 -1
  115. package/dashboard/dist-server/dashboard/src/server/agents/entry-normalizer.d.ts +1 -0
  116. package/dashboard/dist-server/dashboard/src/server/agents/entry-normalizer.js +2 -1
  117. package/dashboard/dist-server/dashboard/src/server/agents/entry-normalizer.js.map +1 -1
  118. package/dashboard/dist-server/dashboard/src/server/agents/stream-json-adapter.js +20 -10
  119. package/dashboard/dist-server/dashboard/src/server/agents/stream-json-adapter.js.map +1 -1
  120. package/dashboard/dist-server/dashboard/src/server/routes/git.d.ts +2 -0
  121. package/dashboard/dist-server/dashboard/src/server/routes/git.js +79 -0
  122. package/dashboard/dist-server/dashboard/src/server/routes/git.js.map +1 -0
  123. package/dashboard/dist-server/dashboard/src/server/routes/index.js +3 -0
  124. package/dashboard/dist-server/dashboard/src/server/routes/index.js.map +1 -1
  125. package/dashboard/dist-server/dashboard/src/server/routes/workspace.js +43 -0
  126. package/dashboard/dist-server/dashboard/src/server/routes/workspace.js.map +1 -1
  127. package/dashboard/dist-server/dashboard/src/server/state/state-manager.js +43 -3
  128. package/dashboard/dist-server/dashboard/src/server/state/state-manager.js.map +1 -1
  129. package/dashboard/package.json +59 -59
  130. package/dist/src/cli.js +3 -1
  131. package/dist/src/cli.js.map +1 -1
  132. package/dist/src/commands/{team.d.ts → collab.d.ts} +2 -2
  133. package/dist/src/commands/collab.d.ts.map +1 -0
  134. package/dist/src/commands/{team.js → collab.js} +391 -24
  135. package/dist/src/commands/collab.js.map +1 -0
  136. package/dist/src/commands/msg.d.ts.map +1 -1
  137. package/dist/src/commands/msg.js +4 -3
  138. package/dist/src/commands/msg.js.map +1 -1
  139. package/dist/src/hooks/team-monitor.d.ts.map +1 -1
  140. package/dist/src/hooks/team-monitor.js +16 -0
  141. package/dist/src/hooks/team-monitor.js.map +1 -1
  142. package/dist/src/tools/collab-adapter.d.ts +85 -0
  143. package/dist/src/tools/collab-adapter.d.ts.map +1 -0
  144. package/dist/src/tools/collab-adapter.js +320 -0
  145. package/dist/src/tools/collab-adapter.js.map +1 -0
  146. package/dist/src/tools/namespace-guard.d.ts +2 -0
  147. package/dist/src/tools/namespace-guard.d.ts.map +1 -1
  148. package/dist/src/tools/namespace-guard.js +12 -0
  149. package/dist/src/tools/namespace-guard.js.map +1 -1
  150. package/dist/src/tools/phase-gate-evaluator.d.ts +45 -0
  151. package/dist/src/tools/phase-gate-evaluator.d.ts.map +1 -0
  152. package/dist/src/tools/phase-gate-evaluator.js +42 -0
  153. package/dist/src/tools/phase-gate-evaluator.js.map +1 -0
  154. package/dist/src/tools/team-members.d.ts +18 -0
  155. package/dist/src/tools/team-members.d.ts.map +1 -1
  156. package/dist/src/tools/team-members.js +50 -0
  157. package/dist/src/tools/team-members.js.map +1 -1
  158. package/dist/src/tools/team-tasks.d.ts +120 -0
  159. package/dist/src/tools/team-tasks.d.ts.map +1 -0
  160. package/dist/src/tools/team-tasks.js +365 -0
  161. package/dist/src/tools/team-tasks.js.map +1 -0
  162. package/dist/src/tools/transition-recorder.d.ts +3 -0
  163. package/dist/src/tools/transition-recorder.d.ts.map +1 -1
  164. package/dist/src/tools/transition-recorder.js +52 -1
  165. package/dist/src/tools/transition-recorder.js.map +1 -1
  166. package/dist/src/utils/get-version.d.ts.map +1 -1
  167. package/dist/src/utils/get-version.js +15 -4
  168. package/dist/src/utils/get-version.js.map +1 -1
  169. package/package.json +1 -1
  170. package/templates/config.json +7 -0
  171. package/templates/worktree-scope.json +10 -0
  172. package/templates/worktrees.json +27 -0
  173. package/workflows/analyze.md +86 -36
  174. package/workflows/brainstorm.md +17 -37
  175. package/workflows/execute.md +94 -28
  176. package/workflows/fork.md +309 -0
  177. package/workflows/init.md +10 -1
  178. package/workflows/issue.md +66 -7
  179. package/workflows/maestro-coordinate.md +23 -16
  180. package/workflows/maestro.md +52 -35
  181. package/workflows/merge.md +285 -0
  182. package/workflows/milestone-audit.md +89 -70
  183. package/workflows/milestone-complete.md +89 -156
  184. package/workflows/plan.md +122 -17
  185. package/workflows/retrospective.md +3 -3
  186. package/workflows/roadmap.md +11 -3
  187. package/workflows/spec-generate.md +9 -0
  188. package/workflows/status.md +76 -27
  189. package/workflows/ui-design.md +14 -12
  190. package/workflows/verify.md +44 -8
  191. package/.claude/commands/maestro-phase-add.md +0 -63
  192. package/.claude/commands/maestro-phase-transition.md +0 -75
  193. package/.codex/skills/maestro-phase-add/SKILL.md +0 -154
  194. package/.codex/skills/maestro-phase-transition/SKILL.md +0 -173
  195. package/chains/singles/phase-add.json +0 -31
  196. package/chains/singles/phase-transition.json +0 -23
  197. package/dashboard/dist/assets/ChatInput-CL8YDfOU.js +0 -67
  198. package/dashboard/dist/assets/ChatPage-CT-ozBK2.js +0 -8
  199. package/dashboard/dist/assets/CollabPage-C0rWMden.js +0 -1
  200. package/dashboard/dist/assets/KanbanPage-C6WbAlwI.js +0 -16
  201. package/dashboard/dist/assets/McpPage-BPIXADQi.js +0 -16
  202. package/dashboard/dist/assets/TreeBrowser-g_QUKemL.js +0 -11
  203. package/dashboard/dist/assets/WorkflowPage-X8aNkDEr.js +0 -6
  204. package/dashboard/dist/assets/git-branch-SqFf4Ru5.js +0 -6
  205. package/dashboard/dist/assets/index-D2Mtyw7I.css +0 -1
  206. package/dashboard/dist/assets/index-nufWop4p.js +0 -231
  207. package/dashboard/dist/assets/wrench-B84-zdLI.js +0 -11
  208. package/dist/src/commands/team.d.ts.map +0 -1
  209. package/dist/src/commands/team.js.map +0 -1
  210. package/workflows/phase-add.md +0 -252
  211. package/workflows/phase-transition.md +0 -399
@@ -1,154 +0,0 @@
1
- ---
2
- name: maestro-phase-add
3
- description: Add or insert a new phase into the project roadmap with automatic renumbering
4
- argument-hint: "\"phase name\" [--after N] [--before N]"
5
- allowed-tools: Read, Write, Edit, Bash, Glob, Grep, AskUserQuestion
6
- ---
7
-
8
- # Maestro Phase Add (Single Agent)
9
-
10
- ## Usage
11
-
12
- ```bash
13
- $maestro-phase-add "authentication"
14
- $maestro-phase-add "caching-layer" --after 2
15
- $maestro-phase-add "security-hardening" --before 5
16
- ```
17
-
18
- **Flags**:
19
- - `"phase name"`: Required. Used as both slug and title (slug = lowercase, hyphens)
20
- - `--after N`: Insert after phase N (renumbers subsequent phases)
21
- - `--before N`: Insert before phase N (renumbers from N onward)
22
- - If neither: append at end
23
-
24
- **Output**: New phase directory, updated roadmap.md, updated state.json
25
-
26
- ---
27
-
28
- ## Overview
29
-
30
- Single mutation operation on the project roadmap. Creates a new phase directory with initialized index.json, inserts the phase entry into roadmap.md at the correct position, and handles automatic renumbering of all affected phase directories and references.
31
-
32
- ---
33
-
34
- ## Implementation
35
-
36
- ### Step 1: Parse Arguments
37
-
38
- Extract:
39
- - Phase name/slug (required — E001 if missing)
40
- - `--after N` or `--before N` flag (mutually exclusive)
41
- - Generate slug: lowercase, replace spaces with hyphens, strip special chars
42
-
43
- ### Step 2: Load Roadmap State
44
-
45
- ```bash
46
- cat .workflow/roadmap.md
47
- cat .workflow/state.json
48
- ls -d .workflow/phases/*/
49
- ```
50
-
51
- - Parse existing phases from roadmap.md
52
- - List existing phase directories
53
- - Check for duplicate slug (E003 if exists)
54
- - Verify roadmap.md exists (E002 if not)
55
-
56
- ### Step 3: Calculate Position
57
-
58
- - If `--after N`: new phase number = N + 1
59
- - If `--before N`: new phase number = N
60
- - If neither: new phase number = max_existing + 1
61
-
62
- ### Step 4: Renumber Existing Phases (if inserting)
63
-
64
- **Only when `--after N` or `--before N` is used.**
65
-
66
- For each phase with number >= new phase number (process in reverse order to avoid collisions):
67
-
68
- 1. Rename directory: `.workflow/phases/{NN}-{slug}` → `.workflow/phases/{NN+1}-{slug}`
69
- 2. Update index.json inside renamed directory: `"phase": N+1`
70
-
71
- ```bash
72
- # Rename in reverse order to prevent collisions
73
- for dir in $(ls -rd .workflow/phases/*/); do
74
- # Extract number, if >= insertion point, rename to number+1
75
- done
76
- ```
77
-
78
- ### Step 5: Create Phase Directory
79
-
80
- ```bash
81
- mkdir -p .workflow/phases/{NN}-{slug}
82
- ```
83
-
84
- Format NN as zero-padded 2-digit number (e.g., 03).
85
-
86
- ### Step 6: Initialize Phase index.json
87
-
88
- Read template from `~/.maestro/templates/index.json` if available, otherwise create:
89
-
90
- ```json
91
- {
92
- "phase": <N>,
93
- "slug": "<slug>",
94
- "title": "<phase name>",
95
- "status": "pending",
96
- "created_at": "<ISO timestamp>",
97
- "tasks": []
98
- }
99
- ```
100
-
101
- Write to `.workflow/phases/{NN}-{slug}/index.json`.
102
-
103
- ### Step 7: Update roadmap.md
104
-
105
- Insert new phase entry at the correct position in roadmap.md:
106
- - Match the existing phase entry format
107
- - If inserting, update all subsequent phase numbers in the document
108
-
109
- ### Step 8: Update state.json
110
-
111
- If renumbering affected `current_phase` or `phases_completed`:
112
- - Adjust `current_phase` number if it was shifted
113
- - Adjust all entries in `phases_completed` that were shifted
114
-
115
- ### Step 9: Completion Report
116
-
117
- ```
118
- === PHASE ADDED ===
119
- Phase: {NN} - {phase name}
120
- Location: .workflow/phases/{NN}-{slug}/
121
-
122
- {if renumbered}
123
- Renumbered: Phases {start}-{end} shifted by +1
124
- {endif}
125
-
126
- Updated:
127
- .workflow/roadmap.md
128
- .workflow/phases/{NN}-{slug}/index.json
129
- {if renumbered}.workflow/state.json{endif}
130
-
131
- Next steps:
132
- $maestro-plan "" -- Plan tasks for the new phase
133
- $manage-status -- View updated roadmap
134
- ```
135
-
136
- ---
137
-
138
- ## Error Handling
139
-
140
- | Code | Severity | Description | Recovery |
141
- |------|----------|-------------|----------|
142
- | E001 | error | Phase name/slug required | Provide phase name as argument |
143
- | E002 | error | roadmap.md not found | Run maestro-init first |
144
- | E003 | error | Duplicate phase name/slug exists | Choose a different name |
145
-
146
- ---
147
-
148
- ## Core Rules
149
-
150
- 1. **Reverse-order renumbering** — always rename directories from highest to lowest to prevent collisions
151
- 2. **State consistency** — state.json phase references must be adjusted after renumbering
152
- 3. **Match existing format** — new roadmap.md entries must match the style of existing entries
153
- 4. **Zero-padded numbers** — always use 2-digit format (01, 02, ... 99)
154
- 5. **Slug normalization** — lowercase, hyphens only, no special characters
@@ -1,173 +0,0 @@
1
- ---
2
- name: maestro-phase-transition
3
- description: Mark current or specified phase as complete, extract learnings, advance to next phase
4
- argument-hint: "[phase-number] [--force]"
5
- allowed-tools: Read, Write, Edit, Bash, Glob, Grep
6
- ---
7
-
8
- # Maestro Phase Transition (Single Agent)
9
-
10
- ## Usage
11
-
12
- ```bash
13
- $maestro-phase-transition ""
14
- $maestro-phase-transition "2"
15
- $maestro-phase-transition "3 --force"
16
- ```
17
-
18
- **Flags**:
19
- - `[phase-number]`: Phase to transition from (defaults to current_phase from state.json)
20
- - `--force`: Skip gap checks and force transition even with warnings
21
-
22
- **Output**: Updated state.json, completed phase index.json, initialized next phase, learnings extracted
23
-
24
- ---
25
-
26
- ## Overview
27
-
28
- State-machine transition skill. Validates that the current phase meets completion criteria (tasks done, verification passed, no unresolved gaps), marks it complete, extracts learnings, and advances to the next phase. Creates next phase directory if needed.
29
-
30
- ---
31
-
32
- ## Implementation
33
-
34
- ### Step 1: Parse Arguments
35
-
36
- Extract:
37
- - Phase number (optional, integer)
38
- - `--force` flag
39
-
40
- ### Step 2: Load State
41
-
42
- ```bash
43
- cat .workflow/state.json
44
- ```
45
-
46
- Determine phase number:
47
- - If provided: use specified phase
48
- - If omitted: use `current_phase` from state.json
49
- - If neither: error E001
50
-
51
- ### Step 3: Resolve Phase Directory
52
-
53
- ```bash
54
- ls -d .workflow/phases/*/ | grep "^.workflow/phases/0*{N}-"
55
- ```
56
-
57
- Read phase files:
58
- - `.workflow/phases/{NN}-{slug}/index.json` — phase metadata, task statuses
59
- - `.workflow/phases/{NN}-{slug}/verification.json` — verification results (if exists)
60
- - `.workflow/phases/{NN}-{slug}/review.json` — code review results (if exists)
61
-
62
- ### Step 4: Validate Completion
63
-
64
- Check the following (skip all if `--force`):
65
-
66
- 1. **Task completion**: All tasks in index.json have status "completed" or "skipped"
67
- 2. **Verification passed**: verification.json exists and verdict is not "FAIL" (E002 if failed)
68
- 3. **No critical gaps**: No unresolved critical gaps in verification results (E003)
69
- 4. **Review status**: Check review.json if exists
70
- - BLOCK verdict → W003 (warning, suggest quality-review fix)
71
- - No review.json → W004 (warning, suggest running quality-review)
72
- 5. **UAT status**: Check for test failures → W002
73
-
74
- If warnings only (no errors) and not `--force`: display warnings and ask user to confirm.
75
-
76
- ### Step 5: Mark Phase Complete
77
-
78
- Update `.workflow/phases/{NN}-{slug}/index.json`:
79
- ```json
80
- {
81
- "status": "complete",
82
- "completed_at": "<ISO timestamp>"
83
- }
84
- ```
85
-
86
- ### Step 6: Extract Learnings
87
-
88
- Analyze phase artifacts for learnings:
89
- 1. Read verification.json gaps and resolutions
90
- 2. Read review.json feedback patterns
91
- 3. Read task summaries for recurring themes
92
- 4. Identify patterns: what worked, what didn't, what to carry forward
93
-
94
- Append to `.workflow/specs/learnings.md`:
95
- ```markdown
96
- ## Phase {N}: {slug}
97
- **Completed**: {date}
98
-
99
- ### What Worked
100
- - {items}
101
-
102
- ### Challenges
103
- - {items}
104
-
105
- ### Carry Forward
106
- - {items}
107
- ```
108
-
109
- ### Step 7: Initialize Next Phase
110
-
111
- Determine next phase number = N + 1.
112
-
113
- Check if next phase directory exists:
114
- - If exists: verify index.json has status "pending", update to "active"
115
- - If not exists: create directory and initialize
116
-
117
- ```bash
118
- mkdir -p .workflow/phases/{NN+1}-{next_slug}
119
- ```
120
-
121
- Write `index.json` for next phase (read template from `~/.maestro/templates/index.json` if available):
122
- ```json
123
- {
124
- "phase": <N+1>,
125
- "status": "active",
126
- "created_at": "<ISO timestamp>"
127
- }
128
- ```
129
-
130
- ### Step 8: Update Project State
131
-
132
- Update `.workflow/state.json`:
133
- - `current_phase`: N + 1
134
- - `phases_completed`: append phase N
135
-
136
- ### Step 9: Completion Report
137
-
138
- ```
139
- === PHASE TRANSITION ===
140
- From: Phase {N} ({slug}) → COMPLETE
141
- To: Phase {N+1} ({next_slug}) → ACTIVE
142
-
143
- Learnings extracted: .workflow/specs/learnings.md
144
- State updated: .workflow/state.json
145
-
146
- Next steps:
147
- $maestro-plan "" -- Plan tasks for Phase {N+1}
148
- $manage-status -- View project dashboard
149
- ```
150
-
151
- ---
152
-
153
- ## Error Handling
154
-
155
- | Code | Severity | Description | Recovery |
156
- |------|----------|-------------|----------|
157
- | E001 | error | Phase number required and could not determine | Specify phase number explicitly |
158
- | E002 | error | Phase has not passed verification | Run maestro-verify first |
159
- | E003 | error | Phase has unresolved critical gaps | Fix gaps, re-verify |
160
- | W001 | warning | Phase has warnings but no blockers | Proceed with confirmation |
161
- | W002 | warning | UAT test failures exist | Review recommended |
162
- | W003 | warning | Code review verdict is BLOCK | Fix review findings first |
163
- | W004 | warning | Code review not yet run | Run quality-review first |
164
-
165
- ---
166
-
167
- ## Core Rules
168
-
169
- 1. **Verify before transition** — refuse to transition without verification (unless --force)
170
- 2. **Learnings are mandatory** — always extract and persist learnings, even if minimal
171
- 3. **Next phase must be ready** — create directory and index.json before reporting success
172
- 4. **State consistency** — state.json and index.json must agree at all times
173
- 5. **Warnings need acknowledgment** — display warnings and require user confirmation (unless --force)
@@ -1,31 +0,0 @@
1
- {
2
- "$schema": "../chain-graph.schema.json",
3
- "id": "singles/phase-add",
4
- "name": "Phase Add",
5
- "description": "Add or insert a new phase into the project roadmap with automatic renumbering",
6
- "version": "1.0.0",
7
- "tags": [
8
- "maestro",
9
- "phase"
10
- ],
11
- "entry": "phase_add",
12
- "inputs": {
13
- "description": {
14
- "type": "string"
15
- }
16
- },
17
- "nodes": {
18
- "phase_add": {
19
- "type": "command",
20
- "cmd": "maestro-phase-add",
21
- "next": "done",
22
- "analyze": false,
23
- "args": "\"{description}\"",
24
- "description": "Add or insert a new phase into the project roadmap with automatic renumbering"
25
- },
26
- "done": {
27
- "type": "terminal",
28
- "status": "success"
29
- }
30
- }
31
- }
@@ -1,23 +0,0 @@
1
- {
2
- "$schema": "../chain-graph.schema.json",
3
- "id": "singles/phase-transition",
4
- "name": "Phase Transition",
5
- "description": "Mark current phase as complete, extract learnings, advance to next phase",
6
- "version": "1.0.0",
7
- "tags": ["lifecycle", "transition"],
8
- "entry": "phase_transition",
9
- "inputs": {},
10
- "nodes": {
11
- "phase_transition": {
12
- "type": "command",
13
- "cmd": "maestro-phase-transition",
14
- "description": "Complete current phase, archive artifacts, extract learnings, advance state",
15
- "next": "done",
16
- "analyze": false
17
- },
18
- "done": {
19
- "type": "terminal",
20
- "status": "success"
21
- }
22
- }
23
- }