maestro-flow 0.4.10 → 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 (354) hide show
  1. package/.agents/agents/cli-explore-agent.md +187 -0
  2. package/.agents/agents/cross-role-reviewer.md +173 -0
  3. package/.agents/agents/impeccable-agent.md +101 -0
  4. package/.agents/agents/role-design-author.md +218 -0
  5. package/.agents/agents/team-supervisor.md +145 -0
  6. package/.agents/agents/team-worker.md +239 -0
  7. package/.agents/agents/ui-design-agent.md +272 -0
  8. package/.agents/agents/workflow-analyzer.md +117 -0
  9. package/.agents/agents/workflow-codebase-mapper.md +79 -0
  10. package/.agents/agents/workflow-collab-planner.md +145 -0
  11. package/.agents/agents/workflow-debugger.md +105 -0
  12. package/.agents/agents/workflow-executor.md +134 -0
  13. package/.agents/agents/workflow-external-researcher.md +88 -0
  14. package/.agents/agents/workflow-integration-checker.md +85 -0
  15. package/.agents/agents/workflow-nyquist-auditor.md +87 -0
  16. package/.agents/agents/workflow-phase-researcher.md +87 -0
  17. package/.agents/agents/workflow-plan-checker.md +92 -0
  18. package/.agents/agents/workflow-planner.md +197 -0
  19. package/.agents/agents/workflow-project-researcher.md +76 -0
  20. package/.agents/agents/workflow-research-synthesizer.md +72 -0
  21. package/.agents/agents/workflow-reviewer.md +84 -0
  22. package/.agents/agents/workflow-roadmapper.md +83 -0
  23. package/.agents/agents/workflow-verifier.md +122 -0
  24. package/.agents/skills/codify-to-knowhow/SKILL.md +169 -0
  25. package/.agents/skills/codify-to-knowhow/phases/01-load-manifest.md +101 -0
  26. package/.agents/skills/codify-to-knowhow/phases/02-generate-knowhow.md +97 -0
  27. package/.agents/skills/codify-to-knowhow/phases/03-generate-specs.md +92 -0
  28. package/.agents/skills/codify-to-knowhow/phases/04-index-verify.md +119 -0
  29. package/.agents/skills/learn-decompose/SKILL.md +118 -0
  30. package/.agents/skills/learn-follow/SKILL.md +129 -0
  31. package/.agents/skills/learn-investigate/SKILL.md +154 -0
  32. package/.agents/skills/learn-retro/SKILL.md +159 -0
  33. package/.agents/skills/learn-second-opinion/SKILL.md +124 -0
  34. package/.agents/skills/maestro/SKILL.md +258 -0
  35. package/.agents/skills/maestro-amend/SKILL.md +165 -0
  36. package/.agents/skills/maestro-analyze/SKILL.md +161 -0
  37. package/.agents/skills/maestro-blueprint/SKILL.md +132 -0
  38. package/.agents/skills/maestro-brainstorm/SKILL.md +134 -0
  39. package/.agents/skills/maestro-collab/SKILL.md +174 -0
  40. package/.agents/skills/maestro-composer/SKILL.md +181 -0
  41. package/.agents/skills/maestro-execute/SKILL.md +133 -0
  42. package/.agents/skills/maestro-fork/SKILL.md +88 -0
  43. package/.agents/skills/maestro-guard/SKILL.md +103 -0
  44. package/.agents/skills/maestro-help/SKILL.md +300 -0
  45. package/.agents/skills/maestro-help/index/catalog.json +202 -0
  46. package/.agents/skills/maestro-help/phases/01-parse-intent.md +122 -0
  47. package/.agents/skills/maestro-help/phases/02-search-present.md +183 -0
  48. package/.agents/skills/maestro-help/phases/03-workflow-guide.md +213 -0
  49. package/.agents/skills/maestro-impeccable/SKILL.md +251 -0
  50. package/.agents/skills/maestro-init/SKILL.md +80 -0
  51. package/.agents/skills/maestro-learn/SKILL.md +142 -0
  52. package/.agents/skills/maestro-merge/SKILL.md +66 -0
  53. package/.agents/skills/maestro-milestone-audit/SKILL.md +72 -0
  54. package/.agents/skills/maestro-milestone-complete/SKILL.md +79 -0
  55. package/.agents/skills/maestro-milestone-release/SKILL.md +98 -0
  56. package/.agents/skills/maestro-overlay/SKILL.md +180 -0
  57. package/.agents/skills/maestro-plan/SKILL.md +182 -0
  58. package/.agents/skills/maestro-player/SKILL.md +177 -0
  59. package/.agents/skills/maestro-quick/SKILL.md +67 -0
  60. package/.agents/skills/maestro-ralph/SKILL.md +756 -0
  61. package/.agents/skills/maestro-ralph-execute/SKILL.md +273 -0
  62. package/.agents/skills/maestro-roadmap/SKILL.md +131 -0
  63. package/.agents/skills/maestro-tools-execute/SKILL.md +119 -0
  64. package/.agents/skills/maestro-tools-register/SKILL.md +159 -0
  65. package/.agents/skills/maestro-ui-codify/SKILL.md +82 -0
  66. package/.agents/skills/maestro-update/SKILL.md +178 -0
  67. package/.agents/skills/maestro-verify/SKILL.md +111 -0
  68. package/.agents/skills/manage-codebase-rebuild/SKILL.md +77 -0
  69. package/.agents/skills/manage-codebase-refresh/SKILL.md +59 -0
  70. package/.agents/skills/manage-harvest/SKILL.md +96 -0
  71. package/.agents/skills/manage-issue/SKILL.md +75 -0
  72. package/.agents/skills/manage-issue-discover/SKILL.md +83 -0
  73. package/.agents/skills/manage-knowhow/SKILL.md +79 -0
  74. package/.agents/skills/manage-knowhow-capture/SKILL.md +81 -0
  75. package/.agents/skills/manage-learn/SKILL.md +67 -0
  76. package/.agents/skills/manage-status/SKILL.md +54 -0
  77. package/.agents/skills/manage-wiki/SKILL.md +64 -0
  78. package/.agents/skills/quality-auto-test/SKILL.md +138 -0
  79. package/.agents/skills/quality-debug/SKILL.md +122 -0
  80. package/.agents/skills/quality-refactor/SKILL.md +69 -0
  81. package/.agents/skills/quality-retrospective/SKILL.md +79 -0
  82. package/.agents/skills/quality-review/SKILL.md +130 -0
  83. package/.agents/skills/quality-sync/SKILL.md +53 -0
  84. package/.agents/skills/quality-test/SKILL.md +119 -0
  85. package/.agents/skills/security-audit/SKILL.md +157 -0
  86. package/.agents/skills/skill-iter-tune/SKILL.md +384 -0
  87. package/.agents/skills/skill-iter-tune/phases/01-setup.md +144 -0
  88. package/.agents/skills/skill-iter-tune/phases/02-execute.md +292 -0
  89. package/.agents/skills/skill-iter-tune/phases/03-evaluate.md +312 -0
  90. package/.agents/skills/skill-iter-tune/phases/04-improve.md +186 -0
  91. package/.agents/skills/skill-iter-tune/phases/05-report.md +166 -0
  92. package/.agents/skills/skill-iter-tune/specs/evaluation-criteria.md +63 -0
  93. package/.agents/skills/skill-iter-tune/templates/eval-prompt.md +134 -0
  94. package/.agents/skills/skill-iter-tune/templates/execute-prompt.md +97 -0
  95. package/.agents/skills/spec-add/SKILL.md +70 -0
  96. package/.agents/skills/spec-load/SKILL.md +73 -0
  97. package/.agents/skills/spec-remove/SKILL.md +53 -0
  98. package/.agents/skills/spec-setup/SKILL.md +50 -0
  99. package/.agents/skills/team-coordinate/SKILL.md +268 -0
  100. package/.agents/skills/team-coordinate/roles/coordinator/commands/analyze-task.md +247 -0
  101. package/.agents/skills/team-coordinate/roles/coordinator/commands/dispatch.md +131 -0
  102. package/.agents/skills/team-coordinate/roles/coordinator/commands/monitor.md +358 -0
  103. package/.agents/skills/team-coordinate/roles/coordinator/role.md +365 -0
  104. package/.agents/skills/team-coordinate/specs/knowledge-transfer.md +111 -0
  105. package/.agents/skills/team-coordinate/specs/pipelines.md +97 -0
  106. package/.agents/skills/team-coordinate/specs/quality-gates.md +112 -0
  107. package/.agents/skills/team-coordinate/specs/role-spec-template.md +198 -0
  108. package/.agents/skills/team-executor/SKILL.md +191 -0
  109. package/.agents/skills/team-executor/roles/executor/commands/monitor.md +239 -0
  110. package/.agents/skills/team-executor/roles/executor/role.md +171 -0
  111. package/.agents/skills/team-executor/specs/session-schema.md +264 -0
  112. package/.agents/skills/team-lifecycle-v4/SKILL.md +211 -0
  113. package/.agents/skills/team-lifecycle-v4/roles/analyst/role.md +96 -0
  114. package/.agents/skills/team-lifecycle-v4/roles/coordinator/commands/analyze.md +56 -0
  115. package/.agents/skills/team-lifecycle-v4/roles/coordinator/commands/dispatch.md +56 -0
  116. package/.agents/skills/team-lifecycle-v4/roles/coordinator/commands/monitor.md +206 -0
  117. package/.agents/skills/team-lifecycle-v4/roles/coordinator/role.md +130 -0
  118. package/.agents/skills/team-lifecycle-v4/roles/executor/commands/fix.md +35 -0
  119. package/.agents/skills/team-lifecycle-v4/roles/executor/commands/implement.md +62 -0
  120. package/.agents/skills/team-lifecycle-v4/roles/executor/role.md +69 -0
  121. package/.agents/skills/team-lifecycle-v4/roles/planner/role.md +87 -0
  122. package/.agents/skills/team-lifecycle-v4/roles/reviewer/commands/review-code.md +34 -0
  123. package/.agents/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +44 -0
  124. package/.agents/skills/team-lifecycle-v4/roles/reviewer/role.md +71 -0
  125. package/.agents/skills/team-lifecycle-v4/roles/supervisor/role.md +194 -0
  126. package/.agents/skills/team-lifecycle-v4/roles/tester/role.md +89 -0
  127. package/.agents/skills/team-lifecycle-v4/roles/writer/role.md +97 -0
  128. package/.agents/skills/team-lifecycle-v4/specs/knowledge-transfer.md +114 -0
  129. package/.agents/skills/team-lifecycle-v4/specs/pipelines.md +140 -0
  130. package/.agents/skills/team-lifecycle-v4/specs/quality-gates.md +130 -0
  131. package/.agents/skills/team-lifecycle-v4/templates/architecture.md +254 -0
  132. package/.agents/skills/team-lifecycle-v4/templates/epics.md +196 -0
  133. package/.agents/skills/team-lifecycle-v4/templates/product-brief.md +133 -0
  134. package/.agents/skills/team-lifecycle-v4/templates/requirements.md +224 -0
  135. package/.agents/skills/team-quality-assurance/SKILL.md +149 -0
  136. package/.agents/skills/team-quality-assurance/roles/analyst/role.md +90 -0
  137. package/.agents/skills/team-quality-assurance/roles/coordinator/commands/analyze.md +72 -0
  138. package/.agents/skills/team-quality-assurance/roles/coordinator/commands/dispatch.md +111 -0
  139. package/.agents/skills/team-quality-assurance/roles/coordinator/commands/monitor.md +250 -0
  140. package/.agents/skills/team-quality-assurance/roles/coordinator/role.md +143 -0
  141. package/.agents/skills/team-quality-assurance/roles/executor/role.md +68 -0
  142. package/.agents/skills/team-quality-assurance/roles/generator/role.md +70 -0
  143. package/.agents/skills/team-quality-assurance/roles/scout/role.md +77 -0
  144. package/.agents/skills/team-quality-assurance/roles/strategist/role.md +73 -0
  145. package/.agents/skills/team-quality-assurance/specs/pipelines.md +115 -0
  146. package/.agents/skills/team-quality-assurance/specs/team-config.json +131 -0
  147. package/.agents/skills/team-review/SKILL.md +149 -0
  148. package/.agents/skills/team-review/roles/coordinator/commands/analyze.md +71 -0
  149. package/.agents/skills/team-review/roles/coordinator/commands/dispatch.md +91 -0
  150. package/.agents/skills/team-review/roles/coordinator/commands/monitor.md +224 -0
  151. package/.agents/skills/team-review/roles/coordinator/role.md +132 -0
  152. package/.agents/skills/team-review/roles/fixer/role.md +78 -0
  153. package/.agents/skills/team-review/roles/reviewer/role.md +70 -0
  154. package/.agents/skills/team-review/roles/scanner/role.md +81 -0
  155. package/.agents/skills/team-review/specs/dimensions.md +82 -0
  156. package/.agents/skills/team-review/specs/finding-schema.json +82 -0
  157. package/.agents/skills/team-review/specs/pipelines.md +102 -0
  158. package/.agents/skills/team-review/specs/team-config.json +27 -0
  159. package/.agents/skills/team-tech-debt/SKILL.md +130 -0
  160. package/.agents/skills/team-tech-debt/roles/assessor/role.md +79 -0
  161. package/.agents/skills/team-tech-debt/roles/coordinator/commands/analyze.md +47 -0
  162. package/.agents/skills/team-tech-debt/roles/coordinator/commands/dispatch.md +156 -0
  163. package/.agents/skills/team-tech-debt/roles/coordinator/commands/monitor.md +209 -0
  164. package/.agents/skills/team-tech-debt/roles/coordinator/role.md +123 -0
  165. package/.agents/skills/team-tech-debt/roles/executor/role.md +78 -0
  166. package/.agents/skills/team-tech-debt/roles/planner/role.md +71 -0
  167. package/.agents/skills/team-tech-debt/roles/scanner/role.md +92 -0
  168. package/.agents/skills/team-tech-debt/roles/validator/role.md +80 -0
  169. package/.agents/skills/team-tech-debt/specs/pipelines.md +47 -0
  170. package/.agents/skills/team-tech-debt/specs/team-config.json +129 -0
  171. package/.agents/skills/team-testing/SKILL.md +145 -0
  172. package/.agents/skills/team-testing/roles/analyst/role.md +105 -0
  173. package/.agents/skills/team-testing/roles/coordinator/commands/analyze.md +70 -0
  174. package/.agents/skills/team-testing/roles/coordinator/commands/dispatch.md +108 -0
  175. package/.agents/skills/team-testing/roles/coordinator/commands/monitor.md +257 -0
  176. package/.agents/skills/team-testing/roles/coordinator/role.md +134 -0
  177. package/.agents/skills/team-testing/roles/executor/role.md +101 -0
  178. package/.agents/skills/team-testing/roles/generator/role.md +100 -0
  179. package/.agents/skills/team-testing/roles/strategist/role.md +85 -0
  180. package/.agents/skills/team-testing/specs/pipelines.md +101 -0
  181. package/.agents/skills/team-testing/specs/team-config.json +93 -0
  182. package/.agents/skills/wiki-connect/SKILL.md +64 -0
  183. package/.agents/skills/wiki-digest/SKILL.md +70 -0
  184. package/.agents/skills/workflow-skill-designer/SKILL.md +498 -0
  185. package/.agents/skills/workflow-skill-designer/phases/01-requirements-analysis.md +356 -0
  186. package/.agents/skills/workflow-skill-designer/phases/02-orchestrator-design.md +444 -0
  187. package/.agents/skills/workflow-skill-designer/phases/03-phase-design.md +458 -0
  188. package/.agents/skills/workflow-skill-designer/phases/04-validation.md +471 -0
  189. package/.agy/agents/cli-explore-agent.md +1 -3
  190. package/.agy/agents/cross-role-reviewer.md +170 -0
  191. package/.agy/agents/role-design-author.md +215 -0
  192. package/.agy/agents/ui-design-agent.md +1 -18
  193. package/.agy/agents/workflow-analyzer.md +1 -1
  194. package/.agy/agents/workflow-external-researcher.md +1 -1
  195. package/.agy/skills/maestro/SKILL.md +63 -27
  196. package/.agy/skills/maestro-analyze/SKILL.md +30 -4
  197. package/.agy/skills/maestro-blueprint/SKILL.md +132 -0
  198. package/.agy/skills/maestro-brainstorm/SKILL.md +119 -103
  199. package/.agy/skills/maestro-help/SKILL.md +48 -14
  200. package/.agy/skills/maestro-help/index/catalog.json +29 -11
  201. package/.agy/skills/maestro-help/phases/01-parse-intent.md +1 -1
  202. package/.agy/skills/maestro-help/phases/02-search-present.md +6 -4
  203. package/.agy/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  204. package/.agy/skills/maestro-init/SKILL.md +3 -3
  205. package/.agy/skills/maestro-milestone-audit/SKILL.md +5 -3
  206. package/.agy/skills/maestro-milestone-complete/SKILL.md +7 -5
  207. package/.agy/skills/maestro-plan/SKILL.md +14 -4
  208. package/.agy/skills/maestro-ralph/SKILL.md +368 -162
  209. package/.agy/skills/maestro-ralph-execute/SKILL.md +81 -67
  210. package/.agy/skills/maestro-roadmap/SKILL.md +42 -81
  211. package/.agy/skills/quality-auto-test/SKILL.md +1 -1
  212. package/.agy/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  213. package/.agy/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  214. package/.agy/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  215. package/.agy/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  216. package/.agy/skills/team-lifecycle-v4/templates/epics.md +2 -2
  217. package/.agy/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  218. package/.agy/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  219. package/.claude/agents/cli-explore-agent.md +1 -3
  220. package/.claude/agents/cross-role-reviewer.md +171 -0
  221. package/.claude/agents/role-design-author.md +216 -0
  222. package/.claude/agents/ui-design-agent.md +1 -18
  223. package/.claude/agents/workflow-analyzer.md +1 -1
  224. package/.claude/agents/workflow-external-researcher.md +1 -1
  225. package/.claude/commands/maestro-analyze.md +30 -4
  226. package/.claude/commands/maestro-blueprint.md +130 -0
  227. package/.claude/commands/maestro-brainstorm.md +132 -116
  228. package/.claude/commands/maestro-init.md +3 -3
  229. package/.claude/commands/maestro-milestone-audit.md +5 -3
  230. package/.claude/commands/maestro-milestone-complete.md +7 -5
  231. package/.claude/commands/maestro-plan.md +14 -4
  232. package/.claude/commands/maestro-ralph-execute.md +81 -67
  233. package/.claude/commands/maestro-ralph.md +368 -162
  234. package/.claude/commands/maestro-roadmap.md +42 -81
  235. package/.claude/commands/maestro.md +63 -27
  236. package/.claude/commands/quality-auto-test.md +1 -1
  237. package/.claude/skills/maestro-help/SKILL.md +48 -14
  238. package/.claude/skills/maestro-help/index/catalog.json +29 -11
  239. package/.claude/skills/maestro-help/phases/01-parse-intent.md +1 -1
  240. package/.claude/skills/maestro-help/phases/02-search-present.md +6 -4
  241. package/.claude/skills/maestro-help/phases/03-workflow-guide.md +60 -33
  242. package/.claude/skills/team-lifecycle-v4/roles/analyst/role.md +1 -1
  243. package/.claude/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  244. package/.claude/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  245. package/.claude/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  246. package/.claude/skills/team-lifecycle-v4/templates/epics.md +2 -2
  247. package/.claude/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  248. package/.claude/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  249. package/.codex/skills/maestro/SKILL.md +84 -41
  250. package/.codex/skills/maestro-amend/SKILL.md +157 -0
  251. package/.codex/skills/maestro-analyze/SKILL.md +71 -23
  252. package/.codex/skills/maestro-blueprint/SKILL.md +122 -0
  253. package/.codex/skills/maestro-brainstorm/SKILL.md +135 -45
  254. package/.codex/skills/maestro-composer/SKILL.md +1 -1
  255. package/.codex/skills/maestro-execute/SKILL.md +13 -4
  256. package/.codex/skills/maestro-help/SKILL.md +28 -18
  257. package/.codex/skills/maestro-help/catalog.json +29 -11
  258. package/.codex/skills/maestro-init/SKILL.md +7 -7
  259. package/.codex/skills/maestro-plan/SKILL.md +27 -9
  260. package/.codex/skills/maestro-ralph/SKILL.md +740 -491
  261. package/.codex/skills/maestro-roadmap/SKILL.md +55 -72
  262. package/.codex/skills/maestro-update/SKILL.md +169 -0
  263. package/.codex/skills/maestro-verify/SKILL.md +11 -2
  264. package/.codex/skills/manage-codebase-rebuild/SKILL.md +2 -2
  265. package/.codex/skills/manage-harvest/SKILL.md +10 -2
  266. package/.codex/skills/quality-retrospective/SKILL.md +9 -2
  267. package/.codex/skills/team-lifecycle-v4/roles/analyst/role.md +2 -2
  268. package/.codex/skills/team-lifecycle-v4/roles/reviewer/commands/review-spec.md +2 -2
  269. package/.codex/skills/team-lifecycle-v4/roles/writer/role.md +1 -1
  270. package/.codex/skills/team-lifecycle-v4/templates/architecture.md +3 -3
  271. package/.codex/skills/team-lifecycle-v4/templates/epics.md +2 -2
  272. package/.codex/skills/team-lifecycle-v4/templates/product-brief.md +3 -3
  273. package/.codex/skills/team-lifecycle-v4/templates/requirements.md +2 -2
  274. package/README.md +8 -8
  275. package/README.zh-CN.md +8 -8
  276. package/dashboard/dist-server/dashboard/src/server/routes/settings.js +3 -3
  277. package/dashboard/dist-server/dashboard/src/server/routes/settings.js.map +1 -1
  278. package/dist/src/agents/cli-agent-runner.d.ts.map +1 -1
  279. package/dist/src/agents/cli-agent-runner.js +13 -7
  280. package/dist/src/agents/cli-agent-runner.js.map +1 -1
  281. package/dist/src/commands/install-backend.d.ts +12 -0
  282. package/dist/src/commands/install-backend.d.ts.map +1 -1
  283. package/dist/src/commands/install-backend.js +144 -0
  284. package/dist/src/commands/install-backend.js.map +1 -1
  285. package/dist/src/commands/spec.d.ts.map +1 -1
  286. package/dist/src/commands/spec.js +8 -1
  287. package/dist/src/commands/spec.js.map +1 -1
  288. package/dist/src/core/component-defs.d.ts +6 -0
  289. package/dist/src/core/component-defs.d.ts.map +1 -1
  290. package/dist/src/core/component-defs.js +97 -0
  291. package/dist/src/core/component-defs.js.map +1 -1
  292. package/dist/src/tools/spec-init.d.ts +16 -2
  293. package/dist/src/tools/spec-init.d.ts.map +1 -1
  294. package/dist/src/tools/spec-init.js +58 -187
  295. package/dist/src/tools/spec-init.js.map +1 -1
  296. package/dist/src/tools/spec-loader.d.ts.map +1 -1
  297. package/dist/src/tools/spec-loader.js +16 -16
  298. package/dist/src/tools/spec-loader.js.map +1 -1
  299. package/dist/src/tools/spec-seeds.d.ts +33 -0
  300. package/dist/src/tools/spec-seeds.d.ts.map +1 -0
  301. package/dist/src/tools/spec-seeds.js +200 -0
  302. package/dist/src/tools/spec-seeds.js.map +1 -0
  303. package/dist/src/tools/spec-writer.d.ts.map +1 -1
  304. package/dist/src/tools/spec-writer.js +7 -9
  305. package/dist/src/tools/spec-writer.js.map +1 -1
  306. package/dist/src/tui/install-ui/ExtraMcpConfig.d.ts +11 -0
  307. package/dist/src/tui/install-ui/ExtraMcpConfig.d.ts.map +1 -0
  308. package/dist/src/tui/install-ui/ExtraMcpConfig.js +61 -0
  309. package/dist/src/tui/install-ui/ExtraMcpConfig.js.map +1 -0
  310. package/dist/src/tui/install-ui/InstallConfirm.d.ts +3 -0
  311. package/dist/src/tui/install-ui/InstallConfirm.d.ts.map +1 -1
  312. package/dist/src/tui/install-ui/InstallConfirm.js +1 -1
  313. package/dist/src/tui/install-ui/InstallConfirm.js.map +1 -1
  314. package/dist/src/tui/install-ui/InstallExecution.d.ts +2 -0
  315. package/dist/src/tui/install-ui/InstallExecution.d.ts.map +1 -1
  316. package/dist/src/tui/install-ui/InstallExecution.js +14 -2
  317. package/dist/src/tui/install-ui/InstallExecution.js.map +1 -1
  318. package/dist/src/tui/install-ui/InstallFlow.d.ts +1 -1
  319. package/dist/src/tui/install-ui/InstallFlow.d.ts.map +1 -1
  320. package/dist/src/tui/install-ui/InstallFlow.js +16 -3
  321. package/dist/src/tui/install-ui/InstallFlow.js.map +1 -1
  322. package/dist/src/tui/install-ui/InstallHub.d.ts +2 -0
  323. package/dist/src/tui/install-ui/InstallHub.d.ts.map +1 -1
  324. package/dist/src/tui/install-ui/InstallHub.js +8 -0
  325. package/dist/src/tui/install-ui/InstallHub.js.map +1 -1
  326. package/dist/src/tui/install-ui/InstallResult.d.ts.map +1 -1
  327. package/dist/src/tui/install-ui/InstallResult.js +3 -1
  328. package/dist/src/tui/install-ui/InstallResult.js.map +1 -1
  329. package/dist/src/utils/update-notices.js +31 -0
  330. package/dist/src/utils/update-notices.js.map +1 -1
  331. package/package.json +5 -2
  332. package/templates/business-test-report.json +1 -1
  333. package/templates/index.json +1 -1
  334. package/templates/roadmap.md +15 -9
  335. package/templates/state.json +18 -17
  336. package/workflows/analyze.md +79 -11
  337. package/workflows/auto-test.md +6 -6
  338. package/workflows/blueprint.md +431 -0
  339. package/workflows/brainstorm.md +603 -496
  340. package/workflows/business-test.md +7 -7
  341. package/workflows/codebase-rebuild.md +4 -4
  342. package/workflows/harvest.md +184 -10
  343. package/workflows/init.md +9 -8
  344. package/workflows/maestro.md +1 -1
  345. package/workflows/milestone-audit.md +12 -4
  346. package/workflows/milestone-complete.md +11 -6
  347. package/workflows/plan.md +88 -22
  348. package/workflows/roadmap-common.md +1 -1
  349. package/workflows/roadmap.md +13 -3
  350. package/workflows/spec-generate.md +24 -13
  351. package/workflows/ui-design.md +2 -2
  352. package/workflows/ui-style.md +1 -1
  353. package/.agy/agents/conceptual-planning-agent.md +0 -244
  354. package/.claude/agents/conceptual-planning-agent.md +0 -245
@@ -0,0 +1,157 @@
1
+ ---
2
+ name: maestro-amend
3
+ description: Generate overlays to fix workflow command deficiencies
4
+ argument-hint: "[description] [--from-verify <dir>] [--from-review <dir>] [--from-session <id>] [--from-issues ISS-xxx,...] [--scan] [--dry-run]"
5
+ allowed-tools: Read, Write, Bash, Glob, Grep, request_user_input
6
+ ---
7
+ <purpose>
8
+ Signal-driven overlay generator — collect workflow deficiency signals from multiple sources, diagnose which commands need amendment, batch-generate targeted overlays. All amendments use overlay system (`~/.maestro/overlays/*.json`) — non-invasive, idempotent, survives reinstall.
9
+
10
+ Differs from `/maestro-overlay` (single explicit intent). This command **discovers** what needs amending by analyzing workflow artifacts.
11
+ </purpose>
12
+
13
+ <required_reading>
14
+ @~/.maestro/workflows/overlays.md
15
+ @~/.maestro/cli-tools.json
16
+ </required_reading>
17
+
18
+ <context>
19
+ $ARGUMENTS — optional description and/or source flags.
20
+
21
+ **Signal sources**:
22
+
23
+ | Flag | Source | Collects |
24
+ |------|--------|----------|
25
+ | `--from-verify <dir>` | verification.json | Workflow gaps from verify failures |
26
+ | `--from-review <dir>` | review.json | Process deficiencies from code review |
27
+ | `--from-session <id>` | Session artifacts | Problems during workflow execution |
28
+ | `--from-issues ISS-xxx,...` | issues.jsonl | Issues tracing to command deficiency |
29
+ | `--scan` | Auto-scan .workflow/ | Discover all workflow-related signals |
30
+ | _(positional text)_ | User description | Direct observation |
31
+
32
+ Multiple combinable. No flags + no description → interactive (scan + AskUserQuestion).
33
+
34
+ **Control**: `--dry-run` (preview, don't install), `-y` (skip confirmations)
35
+
36
+ **CLI targeting**: `"cli": "claude"` (default, patches .claude/commands/), `"codex"` (patches .codex/skills/), `"both"` (both paths)
37
+
38
+ **Output**: `~/.maestro/overlays/amend-{slug}.json` + optional `~/.maestro/overlays/docs/amend-{slug}.md`
39
+ </context>
40
+
41
+ <state_machine>
42
+
43
+ <states>
44
+ S_COLLECT — 收集信号(从 flags / scan / description) PERSIST: —
45
+ S_DIAGNOSE — 映射信号到命令补丁 PERSIST: —
46
+ S_GROUP — 分组、规划 overlay 粒度 PERSIST: —
47
+ S_PREVIEW — 展示注入点地图、用户确认 PERSIST: —
48
+ S_DRAFT — 生成 overlay JSON PERSIST: overlay files
49
+ S_INSTALL — 安装 overlay PERSIST: command files
50
+ S_REPORT — 报告摘要 + post-patch routing PERSIST: —
51
+ </states>
52
+
53
+ <transitions>
54
+
55
+ S_COLLECT:
56
+ → S_DIAGNOSE WHEN: signals found DO: A_COLLECT_SIGNALS
57
+ → ERROR(E001) WHEN: no signals from any source
58
+
59
+ S_DIAGNOSE:
60
+ → S_GROUP WHEN: command deficiencies identified DO: A_DIAGNOSE_SIGNALS
61
+ → ERROR(E003) WHEN: all signals are code bugs (not command gaps)
62
+
63
+ S_GROUP:
64
+ → S_PREVIEW DO: A_GROUP_OVERLAYS
65
+
66
+ S_PREVIEW:
67
+ → S_DRAFT WHEN: user confirms "Apply all" or selects patches
68
+ → S_PREVIEW WHEN: user selects "Edit" DO: modify signal target/section
69
+ → END WHEN: user cancels
70
+
71
+ S_DRAFT:
72
+ → S_INSTALL WHEN: not --dry-run DO: A_DRAFT_OVERLAYS
73
+ → END WHEN: --dry-run DO: display JSON + section map preview
74
+
75
+ S_INSTALL:
76
+ → S_REPORT DO: A_INSTALL_OVERLAYS (`maestro overlay add`, retry max 2 on validation failure)
77
+
78
+ S_REPORT:
79
+ → END DO: display summary (signals collected/applied/skipped, overlay details, skipped code-bug routing)
80
+
81
+ </transitions>
82
+
83
+ <actions>
84
+
85
+ ### A_COLLECT_SIGNALS
86
+
87
+ **If source flags**: extract signals from each specified source.
88
+ **If --scan or interactive**: scan .workflow/ for:
89
+ - verification.json → must_have_failures, anti_patterns (filter for command gap direction)
90
+ - review.json → findings tagged "process" or "workflow"
91
+ - debug understanding.md → root causes with workflow/command cause_type
92
+ - issues.jsonl → status=open AND tags include "workflow"/"command"
93
+ - execution summaries → plan deviations suggesting missing command step
94
+
95
+ **If only description**: parse for affected command(s), what's missing, expected behavior.
96
+
97
+ ### A_DIAGNOSE_SIGNALS
98
+
99
+ Per signal, determine:
100
+ - signal_id, source, description, target_command, target_section, patch_mode, fix_direction, severity
101
+
102
+ **Section mapping**:
103
+
104
+ | Signal pattern | Section | Mode |
105
+ |---------------|---------|------|
106
+ | Missing pre-check/gate | execution | prepend |
107
+ | Missing post-step/verification | execution | append |
108
+ | Missing reading/context | required_reading / deferred_reading | append |
109
+ | Incomplete success criteria | success_criteria | append |
110
+ | Missing error handling | error_codes | append |
111
+ | Scope/context gap | context | append |
112
+ | Entirely new concern | _(new section)_ | new-section |
113
+
114
+ Read pristine source from `$PKG_ROOT/.claude/commands/<name>.md` to confirm section.
115
+ Classify: command deficiency → proceed; code bug → skip (suggest /maestro-quick).
116
+
117
+ ### A_GROUP_OVERLAYS
118
+
119
+ Group by target command + section (merge same command+section).
120
+ Granularity: 1-2 signals → `patch-{command}-{slug}.json`; 3+ cross-command → `amend-{slug}.json`.
121
+ Read target commands to verify sections exist, check existing overlays.
122
+
123
+ Display section map with injection points per target command.
124
+
125
+ ### A_DRAFT_OVERLAYS
126
+
127
+ Build overlay JSON per schema: name, description, targets[], cli, priority (60), enabled, patches[{section, mode, content}].
128
+ Content rules: heading includes `(patch: SIG-NNN)`, concise, supplementary doc to `~/.maestro/overlays/docs/` if >10 lines.
129
+
130
+ ### A_INSTALL_OVERLAYS
131
+
132
+ ```bash
133
+ maestro overlay add ~/.maestro/overlays/amend-{slug}.json
134
+ ```
135
+ On validation failure: fix JSON, retry (max 2).
136
+
137
+ </actions>
138
+
139
+ </state_machine>
140
+
141
+ <error_codes>
142
+ | Code | Condition | Recovery |
143
+ |------|-----------|----------|
144
+ | E001 | No signals from any source | Verify artifact paths or provide description |
145
+ | E003 | All signals are code bugs, not command gaps | Use /maestro-quick or /maestro-plan --gaps |
146
+ | E004 | Overlay validation failed after 2 retries | Review JSON manually |
147
+ | W001 | Some signals skipped (code bugs) | Route to appropriate fix command |
148
+ | W002 | Target command has >= 3 existing overlays | Consider consolidating |
149
+ </error_codes>
150
+
151
+ <success_criteria>
152
+ - [ ] Signals classified: command deficiency vs code bug
153
+ - [ ] Pristine command sources read to verify injection points
154
+ - [ ] Section map with injection points confirmed by user
155
+ - [ ] Overlay JSON installed successfully; command files contain overlay markers
156
+ - [ ] Skipped code-bug signals routed to alternatives
157
+ </success_criteria>
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: maestro-analyze
3
3
  description: Use when a topic needs structured multi-dimensional investigation before planning or decision-making
4
- argument-hint: "[-y|--yes] [-c|--concurrency N] [--continue] \"<phase|topic> [-q|--quick] [--gaps [ISS-ID]]\""
4
+ argument-hint: "[-y|--yes] [-c|--concurrency N] [--continue] [--from <source>] \"<phase|topic> [-q|--quick] [--gaps [ISS-ID]]\""
5
5
  allowed-tools: spawn_agents_on_csv, Read, Write, Edit, Bash, Glob, Grep, AskUserQuestion
6
6
  ---
7
7
 
@@ -10,6 +10,12 @@ Wave-based multi-dimensional analysis using `spawn_agents_on_csv`. Diamond topol
10
10
  Wave 1 (CLI exploration, parallel) -> Wave 2 (6-dimension scoring, parallel) -> Wave 3 (decision synthesis).
11
11
 
12
12
  **Tri-depth**: Full mode (all 3 waves), Quick mode (`-q`, Wave 3 only), Gaps mode (`--gaps`, issue root cause pipeline).
13
+
14
+ **Dual-layer scope (D-003)**:
15
+ - **Macro layer** (text argument, e.g. `analyze "auth refactor"`): broad impact exploration. Produces `scope_verdict ∈ {small, medium, large}` to drive downstream routing (roadmap vs plan).
16
+ - **Phase layer** (numeric argument, e.g. `analyze 1`): phase-scoped deep analysis under `current_milestone`. Milestone resolved via D-007 `phase_slugs` reverse lookup, NEVER direct `current_milestone` read.
17
+
18
+ Produces context-package.json (standardized cross-command context contract) in all modes.
13
19
  </purpose>
14
20
 
15
21
  <context>
@@ -21,11 +27,26 @@ $ARGUMENTS -- phase number, topic text, and optional flags.
21
27
  - `--continue`: Resume existing session
22
28
  - `-q, --quick`: Skip exploration + scoring, Wave 3 only
23
29
  - `--gaps [ISS-ID]`: Issue root cause analysis. If ISS-ID: single issue. If omitted: all open/registered from issues.jsonl.
30
+ - `--from <source>`: Load upstream context package (brainstorm:ID, analyze:ID, @file, or path). Resolves to context-package.json for upstream context inheritance.
24
31
 
25
32
  **Session**: `.workflow/.csv-wave/{YYYYMMDD}-analyze-{slug}/`
26
- **Output**: tasks.csv, results.csv, discoveries.ndjson, context.md (all modes), analysis.md + conclusions.json (full mode only)
33
+ **Output**: tasks.csv, results.csv, discoveries.ndjson, context.md, context-package.json (all modes), analysis.md + conclusions.json (full mode AND quick mode; quick writes minimal conclusions.json with `scope_verdict` + `implementation_scope[]` only)
27
34
  </context>
28
35
 
36
+ <interview_protocol>
37
+ Interview the user relentlessly until shared understanding is reached. Active only in interactive mode; skip when `-y/--yes`, `--continue`, or input is already specific (explicit phase number or unambiguous topic).
38
+
39
+ - One decision per turn via AskUserQuestion with 2–4 options + a (Recommended) default; every question must include a `Proceed now` option so the user can end the interview at any time.
40
+ - Never ask what code can verify — resolve via `state.json`, `roadmap.md`, `issues.jsonl`, `maestro spec load`, `maestro wiki search`, Grep, or Read.
41
+ - Walk the decision dependency tree strictly: scope → depth → dimensions → Go/No-Go threshold. Do not open the next branch until the current one is settled.
42
+ - Scope guard: only ask about decisions owned by `analyze`. Do not prejudge plan/execute concerns.
43
+
44
+ Decision points: scope (phase / topic / milestone-wide / adhoc / --gaps) → depth (quick / standard / deep) → dimensions (which of the 6 to keep) → Go/No-Go threshold.
45
+
46
+ Exit: on `Proceed now` or when all decision points are settled, write the table below into `context.md` under an `Interview Decisions` section (and mirror into `analysis.md` in full mode):
47
+ `| # | Decision | Choice | Source (user / code / default) |`
48
+ </interview_protocol>
49
+
29
50
  <csv_schema>
30
51
 
31
52
  ### tasks.csv
@@ -62,7 +83,9 @@ Available exploration dimensions: architecture, implementation, performance, sec
62
83
  5. **Quick mode shortcut**: -q generates only wave 3 task
63
84
  6. **Gaps mode pipeline**: --gaps follows: Load issues from issues.jsonl -> Classify & group by location/component -> CSV gen (W1: 1 explore row per issue, W2: 1 synthesis per group) -> Execute waves -> Write issue.analysis record per issue -> Append history `{ action: "analyzed", at: <ISO>, by: "maestro-analyze --gaps" }` -> Output context.md for plan --gaps
64
85
  7. **Graceful degradation**: Missing exploration reduces scoring quality; missing scoring reduces synthesis quality
65
- 8. **Tri-output**: context.md always. analysis.md + conclusions.json full-mode only. Gaps mode writes to issues.jsonl + context.md
86
+ 8. **Tri-output**: context.md + context-package.json always. analysis.md (full only) + conclusions.json (full + quick — quick writes minimal with `scope_verdict` + `implementation_scope[]`). Gaps mode writes to issues.jsonl + context.md + context-package.json
87
+ 9. **D-007 milestone resolution**: numeric scope MUST reverse-lookup `state.json.milestones[].phase_slugs`. NEVER read `current_milestone` directly for phase-scoped artifact registration.
88
+ 10. **scope_verdict mandatory** (D-003): macro/adhoc/standalone scopes MUST produce `scope_verdict ∈ {small, medium, large}` in conclusions.json. Drives downstream chain (roadmap vs plan).
66
89
  </invariants>
67
90
 
68
91
  <state_machine>
@@ -80,21 +103,30 @@ S_AGGREGATE -- 注册 artifact、输出摘要 PERSIST: state
80
103
  <transitions>
81
104
 
82
105
  S_PARSE:
83
- -> S_CONTEXT WHEN: scope resolved (milestone/phase/adhoc/standalone/gaps)
106
+ -> S_CONTEXT WHEN: scope resolved (milestone/phase/macro/adhoc/standalone/gaps)
84
107
  -> ERROR(E001) WHEN: no args and no roadmap
85
108
 
86
- **Scope routing**:
87
- | Condition | Scope | Slug |
88
- |-----------|-------|------|
89
- | --gaps flag | gaps | ISS-ID slugified or "issue-gaps" |
90
- | Empty subject + milestone + roadmap | milestone | milestone name slugified |
91
- | Empty subject, no roadmap | ERROR E001 | -- |
92
- | Numeric + milestone + roadmap | phase | phase slug from roadmap |
93
- | Text subject + milestone | adhoc | subject slugified (max 40) |
94
- | Text subject, no milestone | standalone | subject slugified (max 40) |
109
+ **Scope routing** (text → macro layer, numeric → phase layer per D-003):
110
+ | Condition | Scope | Layer | Slug |
111
+ |-----------|-------|-------|------|
112
+ | --gaps flag | gaps | — | ISS-ID slugified or "issue-gaps" |
113
+ | Empty subject + milestone + roadmap | milestone | phase | milestone name slugified |
114
+ | Empty subject, no roadmap | ERROR E001 | — | -- |
115
+ | Numeric + milestone + roadmap | phase | phase | phase slug from roadmap |
116
+ | Text subject + milestone | macro | macro | subject slugified (max 40) |
117
+ | Text subject, no milestone | macro | macro | subject slugified (max 40) |
118
+
119
+ **D-007 milestone reverse lookup** (numeric scope only):
120
+ ```
121
+ resolve_milestone(phase_number):
122
+ for ms in state.json.milestones[]:
123
+ if str(phase_number) in ms.phase_slugs: return ms.id
124
+ return state.json.current_milestone # fallback (standalone)
125
+ ```
126
+ Write resolved milestone into `session.milestone` and artifact registration; NEVER use `current_milestone` directly for phase-scoped runs.
95
127
 
96
128
  S_CONTEXT:
97
- -> S_CSV_GEN DO: load project.md, roadmap.md, state.json, prior artifacts, specs
129
+ -> S_CSV_GEN DO: load project.md, roadmap.md, state.json, prior artifacts, specs, upstream context-package (if --from)
98
130
 
99
131
  S_CSV_GEN:
100
132
  -> S_WAVE_1 WHEN: full mode DO: generate N explore + 6 score + 1 synthesis rows
@@ -144,9 +176,18 @@ Merge results -> master tasks.csv.
144
176
  Filter wave==3 -> build prev_context from wave 2 scores (or project context for quick mode) -> spawn.
145
177
 
146
178
  **Synthesis agent**:
147
- - Full mode: analysis.md (executive summary, per-dimension scores, risk matrix, Go/No-Go), context.md (Locked/Free/Deferred decisions), conclusions.json
148
- - Quick mode: context.md only from available project context
149
- - Gaps mode: per-issue analysis records -> issues.jsonl + context.md for plan --gaps
179
+ - Full mode: analysis.md (executive summary, per-dimension scores, risk matrix, Go/No-Go), context.md (Locked/Free/Deferred decisions), context-package.json, conclusions.json (with `scope_verdict` + `implementation_scope[]`)
180
+ - Quick mode: context.md + context-package.json + **minimal conclusions.json** (`scope_verdict` + `implementation_scope[]` only seeds plan task generation per redesign §8.3)
181
+ - Gaps mode: per-issue analysis records -> issues.jsonl + context.md + context-package.json for plan --gaps
182
+
183
+ **`scope_verdict` evaluation** (D-003 §5.3, macro/standalone/adhoc scopes only):
184
+ | Verdict | Criteria |
185
+ |---------|----------|
186
+ | `large` | 3+ independent subsystems, OR hard dependencies requiring serialized verification points |
187
+ | `medium` | 1-2 subsystems, parallel-safe |
188
+ | `small` | Single file or few files, directly executable |
189
+
190
+ Write to `conclusions.json.scope_verdict` (all modes that produce conclusions); mirror into `context.md` and `context-package.json.source.scope_verdict`. Phase-scoped runs may omit (default null).
150
191
 
151
192
  Gray area detection: domain-aware (things users SEE/CALL/RUN/READ), phase-specific (skip prior decided areas).
152
193
 
@@ -156,17 +197,19 @@ Gray area detection: domain-aware (things users SEE/CALL/RUN/READ), phase-specif
156
197
  2. **Confidence scoring** (full mode): factors -- findings_depth(.30), evidence_strength(.25), coverage_breadth(.20), user_validation(.15), consistency(.10). Thresholds: <60% deeper, 60-80% optional, 80-95% converging, >95% converge.
157
198
  3. Auto-create issues from Deferred items -> issues.jsonl
158
199
  4. Spec enrichment: Locked decisions -> `maestro spec add arch`; code patterns -> `maestro spec add coding`
159
- 5. Register artifact in state.json (type: analyze)
200
+ 5. Register artifact in state.json (type: analyze, includes context_package field pointing to context-package.json)
160
201
  6. Copy outputs to scratchDir, display summary
161
- 7. **Next-step routing**:
202
+ 7. **Next-step routing** (D-003 §5.3 — macro scope uses `scope_verdict` for downstream chain selection):
162
203
 
163
204
  | Scope | Condition | Next |
164
205
  |-------|-----------|------|
165
206
  | Phase/Milestone | Go + UI work needed | `$maestro-impeccable build {target}` |
166
207
  | Phase/Milestone | Go + ready to plan | `$maestro-plan` or `$maestro-plan {phase}` |
167
208
  | Phase/Milestone | No-Go | `$maestro-brainstorm {topic}` |
168
- | Adhoc/Standalone | Ready to plan | `$maestro-plan --dir {scratch_dir}` |
169
- | Adhoc/Standalone | Need more exploration | `$maestro-analyze {topic} --continue` |
209
+ | Macro/Adhoc/Standalone | `scope_verdict == "large"` | `$maestro-roadmap --from analyze:{ANL_ID}` |
210
+ | Macro/Adhoc/Standalone | `scope_verdict == "medium"` | `$maestro-plan --from analyze:{ANL_ID}` |
211
+ | Macro/Adhoc/Standalone | `scope_verdict == "small"` | `$maestro-plan --from analyze:{ANL_ID}` |
212
+ | Macro/Adhoc/Standalone | Need more exploration | `$maestro-analyze {topic} --continue` |
170
213
  | Gaps | Issues analyzed | `$maestro-plan --gaps` |
171
214
  | Gaps | Need more context | `$maestro-analyze --gaps {ISS-ID}` |
172
215
 
@@ -201,8 +244,12 @@ Protocol: read before analysis, append-only, dedup by type+key.
201
244
  </error_codes>
202
245
 
203
246
  <success_criteria>
247
+ - [ ] Interactive mode: interview decision table written to `context.md` "Interview Decisions" (mirrored into `analysis.md` in full mode)
204
248
  - [ ] All waves executed in order (or skipped per mode)
205
- - [ ] context.md produced (all modes); analysis.md + conclusions.json (full mode)
249
+ - [ ] context.md produced (all modes); analysis.md (full mode); conclusions.json (full mode AND quick mode with at minimum `scope_verdict` + `implementation_scope[]`)
250
+ - [ ] context-package.json produced (all modes) with constraints, requirements, insights, open_questions
251
+ - [ ] `scope_verdict ∈ {small, medium, large}` written into conclusions.json + context.md (macro/adhoc/standalone scopes)
252
+ - [ ] D-007 milestone reverse lookup applied for numeric scope; `session.milestone` populated via `phase_slugs`, never via direct `current_milestone` read
206
253
  - [ ] context.md contains all decisions classified as Locked/Free/Deferred
207
254
  - [ ] Decision Recording Protocol applied to all decisions
208
255
  - [ ] Confidence scored per dimension with factor-based model (full mode)
@@ -210,7 +257,8 @@ Protocol: read before analysis, append-only, dedup by type+key.
210
257
  - [ ] Pressure pass completed ≥ 1 time on highest-risk dimension before synthesis
211
258
  - [ ] Deferred items auto-created as issues
212
259
  - [ ] Scope creep redirected to Deferred section
213
- - [ ] Artifact registered in state.json
260
+ - [ ] Artifact registered in state.json (includes context_package field)
261
+ - [ ] Upstream context loaded via `--from` when specified
214
262
  - [ ] discoveries.ndjson append-only throughout
215
263
  - [ ] Next step routed (plan for Go, brainstorm for No-Go, plan --gaps for Gaps)
216
264
  </success_criteria>
@@ -0,0 +1,122 @@
1
+ ---
2
+ name: maestro-blueprint
3
+ description: Generate formal specification package (Product Brief, PRD, Architecture, Epics) through 7-phase document chain (P0 Spec Study → P1 Discovery → P1.5 Req Expansion → P2 Product Brief → P3 PRD → P4 Architecture → P5 Epics → P6 Readiness Check)
4
+ argument-hint: "<idea or @file> [-y] [-c] [--from <source>]"
5
+ allowed-tools: Read, Write, Edit, Bash, Glob, Grep, spawn_agents_on_csv, request_user_input
6
+ ---
7
+ <purpose>
8
+ Formal specification document chain producing a complete specification package through 7 sequential phases (P0–P6, plus P1.5 requirement expansion) with multi-CLI analysis and interactive refinement. Pure documentation — no code generation, no roadmap generation.
9
+
10
+ Parallel to `brainstorm` as an upstream origin command:
11
+ - **brainstorm** = divergent exploration (lightweight, multi-role creative)
12
+ - **blueprint** = convergent documentation (heavyweight, 7-phase formal spec chain)
13
+
14
+ Output: `.workflow/blueprint/BLP-{slug}-{date}/` containing Product Brief, PRD, Architecture, and Epics.
15
+ </purpose>
16
+
17
+ <required_reading>
18
+ @~/.maestro/workflows/blueprint.md
19
+ </required_reading>
20
+
21
+ <deferred_reading>
22
+ - [blueprint-config.json](~/.maestro/templates/blueprint-config.json) — read when initializing blueprint configuration
23
+ </deferred_reading>
24
+
25
+ <context>
26
+ $ARGUMENTS -- idea text, @file reference, or upstream context source.
27
+
28
+ **Flags:**
29
+ - `-y` / `--yes`: Auto mode — skip interactive questions, use recommended defaults
30
+ - `-c` / `--continue`: Resume from last checkpoint (reads blueprint-config.json)
31
+ - `--from <source>`: Load upstream context package (brainstorm:ID, @file, or path). Consumes context-package.json
32
+ - `--from-brainstorm SESSION-ID`: (backward compat alias for `--from brainstorm:ID`)
33
+
34
+ **Input types:**
35
+ - Direct text: `"Build a real-time collaboration platform with WebSocket"`
36
+ - File reference: `@requirements.md`
37
+ - Context import: `--from brainstorm:BRN-001` or `--from @requirements.md` or `--from path/`
38
+ - Resume: `-c` (resumes from first incomplete phase)
39
+
40
+ **Pipeline position:**
41
+ ```
42
+ maestro-brainstorm (optional upstream)
43
+ ↓ guidance-specification.md / context-package.json
44
+ maestro-blueprint
45
+ ↓ .workflow/blueprint/BLP-{slug}-{date}/
46
+ maestro-analyze → maestro-roadmap → maestro-plan
47
+ ```
48
+
49
+ **Output boundary**: ALL file writes MUST target `.workflow/blueprint/BLP-{slug}-{date}/` or `.workflow/state.json` only. NEVER modify source code or files outside these paths.
50
+
51
+ ### Pre-load specs
52
+ 1. **Architecture specs**: Run `maestro spec load --category arch` to load architecture constraints. Use as context for architecture decisions (Phase 4).
53
+ 2. Optional — proceed without if unavailable.
54
+ </context>
55
+
56
+ <interview_protocol>
57
+ Interview the user relentlessly about every aspect of the spec until shared understanding is reached. Walk down each branch of the design tree, resolving dependencies between decisions one-by-one; if a question can be answered by exploring the codebase, explore the codebase instead. Active only in interactive mode; skip when `-y/--yes`, `-c/--continue`, or input is already specific (clear idea + scope).
58
+
59
+ - Ask one question per turn via request_user_input and wait for the user's feedback before continuing; every question must carry a recommended answer marked `(Recommended)`, 2–4 options total, and a `Proceed now` option.
60
+ - Never ask what code can verify — resolve via `state.json`, existing artifacts, `maestro spec load`, or direct codebase exploration (Glob/Grep/Read) instead of prompting.
61
+ - Walk the decision dependency tree depth-first: scope → spec type → focus areas → requirement priorities. Do not open the next branch until the current one is settled.
62
+ - Scope guard: only decide the shape of the specification. Do not pre-resolve roadmap phases or plan tasks — those belong to downstream commands.
63
+
64
+ Decision points: scope (full product / feature set / single feature) → spec type (service / api / library / platform) → focus areas → whether to run codebase exploration.
65
+
66
+ Exit: on consensus or `Proceed now`, persist decisions in blueprint-config.json and proceed to Phase 1.
67
+ </interview_protocol>
68
+
69
+ <execution>
70
+ Follow `~/.maestro/workflows/blueprint.md` completely.
71
+
72
+ ### Phase chain
73
+
74
+ ```
75
+ P0: Spec Study → P1: Discovery → P1.5: Req Expansion → P2: Product Brief → P3: PRD → P4: Architecture → P5: Epics → P6: Readiness Check
76
+ ```
77
+
78
+ P6 gate: Pass (>=80%) → Handoff | Review (60-79%) → Handoff w/caveats | Fail (<60%) → P6.5 Auto-Fix (max 2 iter) → re-check
79
+
80
+ ### Next-step routing on completion
81
+
82
+ | Condition | Suggestion |
83
+ |-----------|-----------|
84
+ | Need codebase analysis | /maestro-analyze {topic} --from blueprint:BLP-xxx |
85
+ | Ready for roadmap | /maestro-roadmap --from blueprint:BLP-xxx |
86
+ | Small scope, direct plan | /maestro-plan --from blueprint:BLP-xxx |
87
+ | Need project setup | /maestro-init |
88
+ </execution>
89
+
90
+ <error_codes>
91
+ | Code | Severity | Condition | Recovery |
92
+ |------|----------|-----------|----------|
93
+ | E001 | error | Idea text or @file required | Prompt user for input |
94
+ | E002 | error | Context source not found (--from) | Show available sessions/sources |
95
+ | E006 | error | `.workflow/` not initialized | Run maestro-init first |
96
+ | E007 | error | Phase 6 readiness Fail after 2 auto-fix iterations | Present manual fix options |
97
+ | W001 | warning | CLI analysis failed, using fallback | Continue with available data |
98
+ | W002 | warning | Codebase exploration failed | Continue without codebase context |
99
+ | W003 | warning | Glossary has < 5 terms | Note in readiness check |
100
+ | W004 | warning | Review-level readiness score (60-79%) | Proceed with caveats |
101
+ | W005 | warning | External research agent failed | Continue without apiResearchContext |
102
+ </error_codes>
103
+
104
+ <success_criteria>
105
+ - [ ] Interactive mode: interview decisions persisted in blueprint-config.json
106
+ - [ ] `blueprint-config.json` created with session metadata and phase tracking
107
+ - [ ] `product-brief.md` with vision, goals, scope, multi-perspective synthesis
108
+ - [ ] `glossary.json` with 5+ core terms for cross-document consistency
109
+ - [ ] `requirements/` directory with `_index.md` + individual `REQ-*.md` + `NFR-*.md` files
110
+ - [ ] All requirements have RFC 2119 keywords and acceptance criteria
111
+ - [ ] `architecture/` directory with `_index.md` + individual `ADR-*.md` files
112
+ - [ ] Architecture includes state machine, config model, error handling, observability (service type)
113
+ - [ ] `epics/` directory with `_index.md` + individual `EPIC-*.md` files
114
+ - [ ] Cross-Epic dependency map (Mermaid) and MVP subset tagged
115
+ - [ ] `readiness-report.md` with 4-dimension quality scores and traceability matrix
116
+ - [ ] `blueprint-summary.md` with one-page executive summary
117
+ - [ ] All documents have valid YAML frontmatter with session_id
118
+ - [ ] Glossary terms used consistently across all documents
119
+ - [ ] Readiness gate: Pass (>=80%) or Review (>=60%) with documented caveats
120
+ - [ ] Artifact registered in state.json (type=blueprint)
121
+ - [ ] context-package.json generated for downstream consumption
122
+ </success_criteria>