maestro-flow 0.5.37 → 0.5.39
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.
- package/.agents/skills/maestro/SKILL.md +11 -5
- package/.agents/skills/maestro-ralph/SKILL.md +80 -12
- package/.agents/skills/maestro-ralph-execute/SKILL.md +17 -6
- package/.agents/skills/manage-drift-realign/SKILL.md +153 -0
- package/.agents/skills/odyssey-debug/SKILL.md +90 -269
- package/.agents/skills/odyssey-improve/SKILL.md +39 -240
- package/.agents/skills/odyssey-planex/SKILL.md +21 -105
- package/.agents/skills/odyssey-review-test-fix/SKILL.md +98 -318
- package/.agents/skills/odyssey-ui/SKILL.md +82 -265
- package/.agy/skills/maestro/SKILL.md +11 -5
- package/.agy/skills/maestro-ralph/SKILL.md +80 -12
- package/.agy/skills/maestro-ralph-execute/SKILL.md +17 -6
- package/.agy/skills/manage-drift-realign/SKILL.md +153 -0
- package/.agy/skills/odyssey-debug/SKILL.md +90 -269
- package/.agy/skills/odyssey-improve/SKILL.md +39 -240
- package/.agy/skills/odyssey-planex/SKILL.md +21 -105
- package/.agy/skills/odyssey-review-test-fix/SKILL.md +98 -318
- package/.agy/skills/odyssey-ui/SKILL.md +82 -265
- package/.claude/commands/maestro-ralph-execute.md +17 -6
- package/.claude/commands/maestro-ralph.md +80 -12
- package/.claude/commands/maestro.md +11 -5
- package/.claude/commands/manage-drift-realign.md +151 -0
- package/.claude/commands/odyssey-debug.md +90 -269
- package/.claude/commands/odyssey-improve.md +39 -240
- package/.claude/commands/odyssey-planex.md +21 -105
- package/.claude/commands/odyssey-review-test-fix.md +98 -318
- package/.claude/commands/odyssey-ui.md +82 -265
- package/.codex/skills/maestro/SKILL.md +16 -8
- package/.codex/skills/maestro-ralph/SKILL.md +138 -11
- package/.codex/skills/maestro-ralph-execute/SKILL.md +17 -6
- package/.codex/skills/manage-drift-realign/SKILL.md +471 -0
- package/.codex/skills/odyssey-debug/SKILL.md +167 -338
- package/.codex/skills/odyssey-improve/SKILL.md +226 -395
- package/.codex/skills/odyssey-planex/SKILL.md +317 -159
- package/.codex/skills/odyssey-review-test-fix/SKILL.md +137 -255
- package/.codex/skills/odyssey-ui/SKILL.md +197 -338
- package/README.md +25 -8
- package/README.zh-CN.md +6 -6
- package/dashboard/dist-server/dashboard/src/server/wiki/embedding.d.ts +23 -2
- package/dashboard/dist-server/dashboard/src/server/wiki/embedding.js +242 -26
- package/dashboard/dist-server/dashboard/src/server/wiki/embedding.js.map +1 -1
- package/dashboard/dist-server/dashboard/src/server/wiki/wiki-indexer.d.ts +2 -0
- package/dashboard/dist-server/dashboard/src/server/wiki/wiki-indexer.js +92 -29
- package/dashboard/dist-server/dashboard/src/server/wiki/wiki-indexer.js.map +1 -1
- package/dashboard/dist-server/src/commands/hooks.d.ts +2 -1
- package/dashboard/dist-server/src/commands/hooks.js +16 -9
- package/dashboard/dist-server/src/commands/hooks.js.map +1 -1
- package/dashboard/dist-server/src/commands/install-backend.d.ts +10 -0
- package/dashboard/dist-server/src/commands/install-backend.js +69 -0
- package/dashboard/dist-server/src/commands/install-backend.js.map +1 -1
- package/dashboard/dist-server/src/core/component-defs.d.ts +11 -0
- package/dashboard/dist-server/src/core/component-defs.js +34 -2
- package/dashboard/dist-server/src/core/component-defs.js.map +1 -1
- package/dashboard/dist-server/src/hooks/kg-sync-hook.js +5 -0
- package/dashboard/dist-server/src/hooks/kg-sync-hook.js.map +1 -1
- package/dashboard/dist-server/src/hooks/session-context.js +276 -3
- package/dashboard/dist-server/src/hooks/session-context.js.map +1 -1
- package/dashboard/dist-server/src/search/daemon-client.d.ts +8 -3
- package/dashboard/dist-server/src/search/daemon-client.js +20 -0
- package/dashboard/dist-server/src/search/daemon-client.js.map +1 -1
- package/dist/src/cli.js +3 -2
- package/dist/src/cli.js.map +1 -1
- package/dist/src/commands/domain.d.ts.map +1 -1
- package/dist/src/commands/domain.js +12 -3
- package/dist/src/commands/domain.js.map +1 -1
- package/dist/src/commands/hooks.d.ts +2 -1
- package/dist/src/commands/hooks.d.ts.map +1 -1
- package/dist/src/commands/hooks.js +16 -9
- package/dist/src/commands/hooks.js.map +1 -1
- package/dist/src/commands/install-backend.d.ts +10 -0
- package/dist/src/commands/install-backend.d.ts.map +1 -1
- package/dist/src/commands/install-backend.js +69 -0
- package/dist/src/commands/install-backend.js.map +1 -1
- package/dist/src/commands/install.js +34 -2
- package/dist/src/commands/install.js.map +1 -1
- package/dist/src/commands/ralph.d.ts.map +1 -1
- package/dist/src/commands/ralph.js +8 -0
- package/dist/src/commands/ralph.js.map +1 -1
- package/dist/src/commands/search.d.ts.map +1 -1
- package/dist/src/commands/search.js +59 -6
- package/dist/src/commands/search.js.map +1 -1
- package/dist/src/commands/spec.d.ts.map +1 -1
- package/dist/src/commands/spec.js +15 -0
- package/dist/src/commands/spec.js.map +1 -1
- package/dist/src/commands/timeline.d.ts +14 -0
- package/dist/src/commands/timeline.d.ts.map +1 -0
- package/dist/src/commands/timeline.js +377 -0
- package/dist/src/commands/timeline.js.map +1 -0
- package/dist/src/core/component-defs.d.ts +11 -0
- package/dist/src/core/component-defs.d.ts.map +1 -1
- package/dist/src/core/component-defs.js +34 -2
- package/dist/src/core/component-defs.js.map +1 -1
- package/dist/src/core/install-executor.d.ts.map +1 -1
- package/dist/src/core/install-executor.js +11 -1
- package/dist/src/core/install-executor.js.map +1 -1
- package/dist/src/core/install-profile.d.ts.map +1 -1
- package/dist/src/core/install-profile.js +52 -17
- package/dist/src/core/install-profile.js.map +1 -1
- package/dist/src/hooks/kg-sync-hook.d.ts.map +1 -1
- package/dist/src/hooks/kg-sync-hook.js +5 -0
- package/dist/src/hooks/kg-sync-hook.js.map +1 -1
- package/dist/src/hooks/session-context.d.ts.map +1 -1
- package/dist/src/hooks/session-context.js +276 -3
- package/dist/src/hooks/session-context.js.map +1 -1
- package/dist/src/i18n/locales/en.d.ts.map +1 -1
- package/dist/src/i18n/locales/en.js +4 -1
- package/dist/src/i18n/locales/en.js.map +1 -1
- package/dist/src/i18n/locales/zh.d.ts.map +1 -1
- package/dist/src/i18n/locales/zh.js +4 -1
- package/dist/src/i18n/locales/zh.js.map +1 -1
- package/dist/src/i18n/types.d.ts +3 -0
- package/dist/src/i18n/types.d.ts.map +1 -1
- package/dist/src/ralph/cmd-complete.d.ts +4 -0
- package/dist/src/ralph/cmd-complete.d.ts.map +1 -1
- package/dist/src/ralph/cmd-complete.js +8 -0
- package/dist/src/ralph/cmd-complete.js.map +1 -1
- package/dist/src/ralph/cmd-next.js +58 -8
- package/dist/src/ralph/cmd-next.js.map +1 -1
- package/dist/src/ralph/status-schema.d.ts +29 -2
- package/dist/src/ralph/status-schema.d.ts.map +1 -1
- package/dist/src/ralph/status-schema.js +1 -1
- package/dist/src/search/daemon-client.d.ts +8 -3
- package/dist/src/search/daemon-client.d.ts.map +1 -1
- package/dist/src/search/daemon-client.js +20 -0
- package/dist/src/search/daemon-client.js.map +1 -1
- package/dist/src/search/daemon.d.ts +3 -3
- package/dist/src/search/daemon.d.ts.map +1 -1
- package/dist/src/search/daemon.js +9 -3
- package/dist/src/search/daemon.js.map +1 -1
- package/dist/src/tui/install-ui/ComponentGrid.d.ts.map +1 -1
- package/dist/src/tui/install-ui/ComponentGrid.js +71 -38
- package/dist/src/tui/install-ui/ComponentGrid.js.map +1 -1
- package/dist/src/tui/install-ui/ComponentGrid.logic.d.ts +12 -3
- package/dist/src/tui/install-ui/ComponentGrid.logic.d.ts.map +1 -1
- package/dist/src/tui/install-ui/ComponentGrid.logic.js +21 -4
- package/dist/src/tui/install-ui/ComponentGrid.logic.js.map +1 -1
- package/dist/src/tui/install-ui/CyberItem.d.ts +3 -1
- package/dist/src/tui/install-ui/CyberItem.d.ts.map +1 -1
- package/dist/src/tui/install-ui/CyberItem.js +6 -5
- package/dist/src/tui/install-ui/CyberItem.js.map +1 -1
- package/dist/src/tui/install-ui/GroupedHub.d.ts +9 -0
- package/dist/src/tui/install-ui/GroupedHub.d.ts.map +1 -1
- package/dist/src/tui/install-ui/GroupedHub.js +54 -47
- package/dist/src/tui/install-ui/GroupedHub.js.map +1 -1
- package/dist/src/tui/install-ui/InstallConfirm.js +1 -1
- package/dist/src/tui/install-ui/InstallConfirm.js.map +1 -1
- package/dist/src/tui/install-ui/InstallFlow.d.ts.map +1 -1
- package/dist/src/tui/install-ui/InstallFlow.js +54 -5
- package/dist/src/tui/install-ui/InstallFlow.js.map +1 -1
- package/dist/src/tui/install-ui/types.d.ts +1 -0
- package/dist/src/tui/install-ui/types.d.ts.map +1 -1
- package/dist/src/tui/install-ui/types.js.map +1 -1
- package/dist/src/tui/install-ui/useInstallFlowState.d.ts +8 -2
- package/dist/src/tui/install-ui/useInstallFlowState.d.ts.map +1 -1
- package/dist/src/tui/install-ui/useInstallFlowState.js +145 -15
- package/dist/src/tui/install-ui/useInstallFlowState.js.map +1 -1
- package/dist/src/utils/update-notices.js +12 -0
- package/dist/src/utils/update-notices.js.map +1 -1
- package/package.json +1 -1
- package/workflows/agy-instructions.md +127 -88
- package/workflows/analyze.md +2 -2
- package/workflows/auto-test.md +7 -1
- package/workflows/blueprint.md +22 -19
- package/workflows/brainstorm.md +11 -3
- package/workflows/business-test.md +4 -0
- package/workflows/codebase-rebuild.md +8 -1
- package/workflows/codebase-refresh.md +7 -1
- package/workflows/codex-instructions.md +1 -1
- package/workflows/debug.md +5 -2
- package/workflows/domain-add.md +6 -0
- package/workflows/drift-realign.md +396 -0
- package/workflows/execute.md +5 -4
- package/workflows/explore-usage.md +2 -2
- package/workflows/finish-work.md +6 -6
- package/workflows/fork.md +2 -2
- package/workflows/grill.md +6 -5
- package/workflows/harvest.md +2 -2
- package/workflows/impeccable.md +3 -2
- package/workflows/init.md +7 -7
- package/workflows/integration-test.md +1 -0
- package/workflows/issue-gaps-analyze.codex.md +2 -0
- package/workflows/issue-gaps-analyze.md +4 -4
- package/workflows/issue-plan.md +1 -1
- package/workflows/knowhow.md +7 -1
- package/workflows/knowledge-audit.md +1 -1
- package/workflows/maestro-super.md +2 -2
- package/workflows/maestro.md +3 -3
- package/workflows/map.md +2 -2
- package/workflows/milestone-audit.md +1 -1
- package/workflows/milestone-complete.md +1 -1
- package/workflows/odyssey-base.md +258 -0
- package/workflows/plan.md +7 -6
- package/workflows/quick.md +8 -6
- package/workflows/ralph-amend-goal.md +177 -0
- package/workflows/refactor.md +2 -0
- package/workflows/retrospective.md +7 -3
- package/workflows/review.md +6 -4
- package/workflows/roadmap-common.md +3 -3
- package/workflows/roadmap.md +8 -5
- package/workflows/spec-generate.md +23 -18
- package/workflows/specs-load.md +1 -1
- package/workflows/specs-setup.md +2 -0
- package/workflows/sync.md +4 -2
- package/workflows/test-gen.md +1 -1
- package/workflows/test.md +1 -1
- package/workflows/ui-codify-extract.md +1 -0
- package/workflows/ui-codify-knowhow.md +1 -1
- package/workflows/ui-codify-package.md +1 -1
- package/workflows/ui-codify.md +9 -7
- package/workflows/ui-design.md +9 -7
- package/workflows/ui-style.md +6 -4
- package/workflows/verify.md +4 -4
- package/workflows/wiki-connect.md +2 -0
- package/workflows/wiki-digest.md +5 -3
- package/workflows/wiki-manage.md +4 -0
- package/workflows/maestro.codex.md +0 -365
package/workflows/init.md
CHANGED
|
@@ -37,7 +37,7 @@ state.json exists → Path C (existing) | source files exist → Path B (brownfi
|
|
|
37
37
|
- Target users / stakeholders
|
|
38
38
|
- Success criteria
|
|
39
39
|
|
|
40
|
-
Decision gate: When
|
|
40
|
+
Decision gate: When ≥3 research dimensions gathered, ask "Ready to create project.md?"
|
|
41
41
|
- "Create project.md" → proceed
|
|
42
42
|
- "Keep exploring" → continue questioning
|
|
43
43
|
|
|
@@ -67,9 +67,9 @@ state.json exists → Path C (existing) | source files exist → Path B (brownfi
|
|
|
67
67
|
|
|
68
68
|
If `--auto`: use template defaults (all the above on).
|
|
69
69
|
|
|
70
|
-
3. **Research** (
|
|
70
|
+
3. **Research** (conditional, triggered when `config.workflow.research == true`) -- MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep when triggered: Spawn 4 parallel `workflow-project-researcher` agents writing to `.workflow/research/`: STACK.md, FEATURES.md, ARCHITECTURE.md, PITFALLS.md.
|
|
71
71
|
|
|
72
|
-
4. **Synthesize** -- Spawn `workflow-research-synthesizer` agent:
|
|
72
|
+
4. **Synthesize** -- MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn `workflow-research-synthesizer` agent:
|
|
73
73
|
- Input: all `.workflow/research/` documents
|
|
74
74
|
- Output: `.workflow/research/SUMMARY.md` with consolidated findings
|
|
75
75
|
|
|
@@ -103,10 +103,10 @@ state.json exists → Path C (existing) | source files exist → Path B (brownfi
|
|
|
103
103
|
|
|
104
104
|
If `.workflow/specs/` does not exist:
|
|
105
105
|
|
|
106
|
-
1. Run `Bash("maestro spec init")` — creates empty seed files (skeleton only, no codebase scan)
|
|
106
|
+
1. MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Run `Bash("maestro spec init")` — creates empty seed files (skeleton only, no codebase scan)
|
|
107
107
|
|
|
108
108
|
2. If project has existing source files (package.json, tsconfig.json, pyproject.toml, go.mod, etc.):
|
|
109
|
-
-
|
|
109
|
+
- MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: auto-trigger `Skill({ skill: "spec-setup" })` — scan codebase and populate specs with detected conventions
|
|
110
110
|
- Note: Specs are further enriched by analyze, plan, and execute stages via `maestro spec add`
|
|
111
111
|
|
|
112
112
|
3. If greenfield project (no source files):
|
|
@@ -117,8 +117,8 @@ If `.workflow/specs/` does not exist:
|
|
|
117
117
|
|
|
118
118
|
If `.workflow/domain/` does not exist:
|
|
119
119
|
|
|
120
|
-
1. Run `Bash("maestro domain init")` — creates `.workflow/domain/glossary.yaml` with empty terms array
|
|
121
|
-
2. If brownfield project (has source files): run `maestro domain discover --auto` to scan codebase for initial term candidates, present top 5 for confirmation
|
|
120
|
+
1. MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Run `Bash("maestro domain init")` — creates `.workflow/domain/glossary.yaml` with empty terms array
|
|
121
|
+
2. If brownfield project (has source files): MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: run `maestro domain discover --auto` to scan codebase for initial term candidates, present top 5 for confirmation
|
|
122
122
|
3. If greenfield project: skip discovery (no codebase to scan); domain terms will be populated by grill/brainstorm sessions via finish-work extraction
|
|
123
123
|
|
|
124
124
|
|
|
@@ -30,6 +30,7 @@ If existing session at `${PHASE_DIR}/.tests/integration/state.json`: offer resum
|
|
|
30
30
|
### Step 1.3: Load Project Specs
|
|
31
31
|
|
|
32
32
|
```
|
|
33
|
+
# MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep
|
|
33
34
|
specs_content = maestro spec load --category test
|
|
34
35
|
arch_content = maestro spec load --category arch
|
|
35
36
|
```
|
|
@@ -94,6 +94,7 @@ Write `tasks.csv` to session folder.
|
|
|
94
94
|
Filter `wave == 1 && status == pending`. Write `wave-1.csv`.
|
|
95
95
|
|
|
96
96
|
```javascript
|
|
97
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep:
|
|
97
98
|
spawn_agents_on_csv({
|
|
98
99
|
csv_path: `${sessionFolder}/wave-1.csv`,
|
|
99
100
|
id_column: "id",
|
|
@@ -121,6 +122,7 @@ Merge results into master `tasks.csv`, delete `wave-1.csv`.
|
|
|
121
122
|
Filter `wave == 2 && status == pending`. Build `prev_context` from wave 1 findings of issues in same group. Write `wave-2.csv` with `prev_context` column.
|
|
122
123
|
|
|
123
124
|
```javascript
|
|
125
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep:
|
|
124
126
|
spawn_agents_on_csv({
|
|
125
127
|
csv_path: `${sessionFolder}/wave-2.csv`,
|
|
126
128
|
id_column: "id",
|
|
@@ -68,7 +68,7 @@ For each group:
|
|
|
68
68
|
Merge keywords from all issues in group: title, description, location, affected_components.
|
|
69
69
|
Deduplicate keywords.
|
|
70
70
|
|
|
71
|
-
Standard depth: maestro explore per group (keywords as prompt), fallback grep.
|
|
71
|
+
Standard depth: maestro explore per group (keywords as prompt), fallback grep; flag analysis as [LOW CONFIDENCE] (grep fallback, semantic depth lost).
|
|
72
72
|
Deep depth: maestro explore multi-prompt + semantic Agent search (error handling,
|
|
73
73
|
data flow, deps), merge results.
|
|
74
74
|
|
|
@@ -81,7 +81,7 @@ For each group:
|
|
|
81
81
|
### Step 4: Run Analysis (per group, parallel across groups)
|
|
82
82
|
|
|
83
83
|
```
|
|
84
|
-
Launch analysis for each group in parallel using Agent tool:
|
|
84
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Launch analysis for each group in parallel using Agent tool:
|
|
85
85
|
|
|
86
86
|
Agent({
|
|
87
87
|
subagent_type: "general-purpose",
|
|
@@ -97,10 +97,10 @@ Launch analysis for each group in parallel using Agent tool:
|
|
|
97
97
|
|
|
98
98
|
Alternatively, attempt CLI delegate first per group:
|
|
99
99
|
|
|
100
|
-
maestro delegate "<same prompt>" --role analyze --mode analysis
|
|
100
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: maestro delegate "<same prompt>" --role analyze --mode analysis
|
|
101
101
|
|
|
102
102
|
If delegate fails (timeout, unavailable, parse error):
|
|
103
|
-
Fall back to Agent tool with same prompt.
|
|
103
|
+
Fall back to Agent tool with same prompt; set analysis confidence=low and flag as [LOW CONFIDENCE] (delegate failed).
|
|
104
104
|
Record fallback in analysis metadata: { tool: "agent-fallback", reason: "<error>" }
|
|
105
105
|
|
|
106
106
|
Validate response per issue: all required fields present.
|
package/workflows/issue-plan.md
CHANGED
|
@@ -47,7 +47,7 @@ Otherwise ANALYSIS_CONTEXT = "" (proceed without).
|
|
|
47
47
|
```
|
|
48
48
|
Delegate planning prompt with issue details + ANALYSIS_CONTEXT:
|
|
49
49
|
|
|
50
|
-
maestro delegate "Generate step-by-step solution for {ISS-ID}: {ISSUE.title}
|
|
50
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: maestro delegate "Generate step-by-step solution for {ISS-ID}: {ISSUE.title}
|
|
51
51
|
ISSUE: title, description, severity, location, fix_direction
|
|
52
52
|
{ANALYSIS_CONTEXT}
|
|
53
53
|
TASK: Break into atomic steps with action types (create|modify|delete|test)
|
package/workflows/knowhow.md
CHANGED
|
@@ -69,7 +69,13 @@ Full-text search across both stores. Rank: exact match > heading > content.
|
|
|
69
69
|
|
|
70
70
|
### Step 5-9: View, Edit, Delete, Prune, Integrity Check
|
|
71
71
|
|
|
72
|
-
|
|
72
|
+
MANDATORY: execute View/Edit/Delete/Prune/Integrity-Check logic per spec; REQUIRED produce: per-step result + final store-consistency report; BLOCKED if any step's produce missing.
|
|
73
|
+
|
|
74
|
+
- **View**: Workflow `maestro wiki get <slug>`, System Read file; BLOCKED if entry not found.
|
|
75
|
+
- **Edit**: System store only, direct file edit preserving frontmatter; BLOCKED if frontmatter schema invalid after edit.
|
|
76
|
+
- **Delete**: Workflow `maestro wiki delete <slug>`, System mv to `.workflow/.trash/`; REQUIRED produce backup; BLOCKED if backup missing.
|
|
77
|
+
- **Prune**: Scan `status=deprecated|superseded` entries, list candidates, delete after confirm; REQUIRED produce prune report; BLOCKED if delete without backup.
|
|
78
|
+
- **Integrity Check**: Workflow verify `wiki-index.json` matches disk, System verify MEMORY.md links; REQUIRED produce report {missing[], stale[]}; BLOCKED if missing>0.
|
|
73
79
|
|
|
74
80
|
---
|
|
75
81
|
|
|
@@ -350,5 +350,5 @@ Next:
|
|
|
350
350
|
4. **Double confirmation** — `--purge` 需 flag + 交互输入 artifact id 双重确认
|
|
351
351
|
5. **Rescue before delete** — 删 artifact 前若 harvest-log 无记录,强制提示先跑 `/manage-harvest`
|
|
352
352
|
6. **No dedup re-run** — audit 不做"是否重复"判断(harvest 负责),只做"是否矛盾/失效/老化"
|
|
353
|
-
7. **Graceful degradation** — LLM detector 不可用时跳过 B/G 类语义场景,A/D/F
|
|
353
|
+
7. **Graceful degradation** — LLM detector 不可用时跳过 B/G 类语义场景,A/D/F 类正则+图算法仍可执行; Stage 8 报告加 partial_audit: true, skipped: [B,G] 并标 [LOW CONFIDENCE]
|
|
354
354
|
8. **Idempotent** — 同一存储状态下重跑 `--dry-run` 必须输出一致的 finding 集
|
|
@@ -6,7 +6,7 @@ Super mode implies `-y` (all auto flags propagated) plus these additional behavi
|
|
|
6
6
|
|
|
7
7
|
## 1. Requirement Expansion
|
|
8
8
|
|
|
9
|
-
On receiving user intent, autonomously expand incomplete requirements into a complete product scope. Delegate via role (`maestro delegate --role analyze --mode analysis`) for requirement completeness analysis and gap-filling. Accept requirements that add real user value; discard noise.
|
|
9
|
+
On receiving user intent, autonomously expand incomplete requirements into a complete product scope. MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Delegate via role (`maestro delegate --role analyze --mode analysis`) for requirement completeness analysis and gap-filling. Accept requirements that add real user value; discard noise.
|
|
10
10
|
|
|
11
11
|
## 2. Progressive Document Loading
|
|
12
12
|
|
|
@@ -14,7 +14,7 @@ Read execution documents (workflow maestro.md, chain steps) incrementally per-ph
|
|
|
14
14
|
|
|
15
15
|
## 3. Autonomous Decision-Making
|
|
16
16
|
|
|
17
|
-
All design/architecture/scope decisions are made via Gemini delegate (`--mode analysis`). No AskUserQuestion calls. Decision criteria: mainstream industry standards, pragmatism, simplicity.
|
|
17
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: All design/architecture/scope decisions are made via Gemini delegate (`--mode analysis`). No AskUserQuestion calls. Decision criteria: mainstream industry standards, pragmatism, simplicity.
|
|
18
18
|
|
|
19
19
|
## 4. Auto-Advance Milestones
|
|
20
20
|
|
package/workflows/maestro.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Workflow: maestro
|
|
2
2
|
|
|
3
3
|
Intelligent coordinator that routes user intent to optimal command chain based on project state.
|
|
4
|
-
Builds a `ralph_protocol_version: "
|
|
4
|
+
Builds a `ralph_protocol_version: "2"` session: every executable step carries `skill,args,stage,scope,command_scope,command_path`; every cross-step gate is a `step.decision` node. All execution dispatched to unified executor (`maestro-ralph-execute`); the command body (`.claude/commands/maestro.md`) owns session build + dispatch. `--exec` is legacy input only — recorded to `legacy_options.exec_mode`, never changes execution. This brain is consumed for **classification only** (intent → task_type → chain); it does NOT prescribe execution semantics.
|
|
5
5
|
|
|
6
6
|
**Prerequisites:**
|
|
7
7
|
- None for initial invocation (can bootstrap)
|
|
@@ -217,7 +217,7 @@ If user chooses "Execute from step N": set `$START_STEP = N` (used in 3f to set
|
|
|
217
217
|
|
|
218
218
|
### 3e: Step-level command resolution (v1)
|
|
219
219
|
|
|
220
|
-
> **Superseded by `ralph_protocol_version: "
|
|
220
|
+
> **Superseded by `ralph_protocol_version: "2"`.** The command body resolves `command_scope`/`command_path` per execution step via `maestro ralph skills --platform claude --json --quiet`; cross-step gates carry `step.decision`. Do NOT write a per-step `type` field (legacy skill/cli). `--exec` is recorded to `legacy_options.exec_mode` only — it never changes execution. FSM owns step ordering + decision evaluation (control-plane precedence, see command-body invariant 15).
|
|
221
221
|
|
|
222
222
|
```
|
|
223
223
|
If execMode is 'cli' or 'internal' → force that type for all steps ("cli" or "skill").
|
|
@@ -292,7 +292,7 @@ status.json already created in Step 3g, TodoWrite initialized in Step 3h.
|
|
|
292
292
|
Skill({ skill: "maestro-ralph-execute" })
|
|
293
293
|
```
|
|
294
294
|
|
|
295
|
-
The unified executor discovers the latest running session from `.workflow/.maestro/*/status.json` and executes steps in order. maestro sessions (source: "maestro") are `ralph_protocol_version: "
|
|
295
|
+
The unified executor discovers the latest running session from `.workflow/.maestro/*/status.json` and executes steps in order. maestro sessions (source: "maestro") are `ralph_protocol_version: "2"`: execution steps load via `maestro ralph next`; any `step.decision` node hands off to `Skill("maestro-ralph")` for evaluation (same mechanism as ralph sessions). Decision nodes ARE supported in maestro sessions.
|
|
296
296
|
|
|
297
297
|
---
|
|
298
298
|
|
package/workflows/map.md
CHANGED
|
@@ -19,7 +19,7 @@ Codebase scanning with parallel mapper agents.
|
|
|
19
19
|
|
|
20
20
|
## Step 2: Spawn Parallel Mapper Agents
|
|
21
21
|
|
|
22
|
-
Spawn 4 parallel `workflow-codebase-mapper` agents, each writing to `.workflow/research/`:
|
|
22
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn 4 parallel `workflow-codebase-mapper` agents, each writing to `.workflow/research/`:
|
|
23
23
|
|
|
24
24
|
| Agent | Focus | Output | Content |
|
|
25
25
|
|-------|-------|--------|---------|
|
|
@@ -41,7 +41,7 @@ Each agent spawned in parallel as `workflow-codebase-mapper` subagent with specs
|
|
|
41
41
|
After all 4 agents complete:
|
|
42
42
|
|
|
43
43
|
1. Verify all 4 documents exist with >10 lines each.
|
|
44
|
-
2. If any missing/empty → log failure, re-spawn that agent (max 1 retry).
|
|
44
|
+
2. If any missing/empty → log failure, re-spawn that agent (max 1 retry); after retry exhausted, flag SUMMARY as [LOW CONFIDENCE] (incomplete) and list missing docs.
|
|
45
45
|
|
|
46
46
|
---
|
|
47
47
|
|
|
@@ -46,7 +46,7 @@ For each execute artifact, read `{path}/.task/TASK-*.json` and verify all tasks
|
|
|
46
46
|
|
|
47
47
|
## Step 5: Integration Check
|
|
48
48
|
|
|
49
|
-
Spawn `workflow-integration-checker` agent:
|
|
49
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn `workflow-integration-checker` agent:
|
|
50
50
|
|
|
51
51
|
```
|
|
52
52
|
Agent({
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
- Update `archive.json.pruned = { "at": now, "counts": { open_questions, constraints, insights, references }, "ref": "context-package.pruned.json" }`
|
|
56
56
|
- Otherwise leave both files untouched and set `archive.json.pruned = { "at": now, "counts": {...zeros}, "ref": null }`
|
|
57
57
|
|
|
58
|
-
c. If the session dir lacks `archive.json` (legacy session prior to lifecycle convention), skip (a) and (b)
|
|
58
|
+
c. If the session dir lacks `archive.json` (legacy session prior to lifecycle convention), skip (a) and (b); log W0xx "legacy session not indexed"; flag archive as [LOW CONFIDENCE] (lifecycle.indexed=false, legacy session).
|
|
59
59
|
|
|
60
60
|
---
|
|
61
61
|
|
|
@@ -0,0 +1,258 @@
|
|
|
1
|
+
# Odyssey 共享基座
|
|
2
|
+
|
|
3
|
+
所有 Odyssey 命令(debug, improve, planex, review-test-fix, ui)共享此基座。
|
|
4
|
+
|
|
5
|
+
<execution_discipline>
|
|
6
|
+
**四条铁律:**
|
|
7
|
+
|
|
8
|
+
1. **Phase auto-commit** — 每个阶段完成后自动 `git commit`,无需用户确认
|
|
9
|
+
- 代码变更 + understanding.md → `git add` → `git commit -m "{command}({slug}): {phase} — {摘要}"`
|
|
10
|
+
- session.json / evidence.ndjson 为运行时状态,不纳入 commit
|
|
11
|
+
|
|
12
|
+
2. **Confident edits only, but must attempt** — 有把握才改代码;仅在真正需要人类判断时记录 decision
|
|
13
|
+
- Confident → edit + commit
|
|
14
|
+
- Needs decision → `evidence.ndjson {"phase":"decision","status":"pending"}`,不动代码
|
|
15
|
+
- ⚠️ **Decision gate** — 仅以下情形算 decision:跨模块架构权衡需人类方向 | 业务语义歧义修复可能改变意图 | 需引入新依赖或 breaking API
|
|
16
|
+
- ❌ "不确定怎么修"、"范围太大"、"历史遗留" 不是合法 decision 理由
|
|
17
|
+
|
|
18
|
+
3. **多 CLI 辅助** — `maestro delegate` 多角度交叉验证
|
|
19
|
+
- 不同阶段用不同 `--role`(analyze / review / explore)
|
|
20
|
+
- 所有 delegate 调用 `run_in_background: true`,等回调继续
|
|
21
|
+
|
|
22
|
+
4. **禁止以上下文消耗为由中断** — harness 自动 context compression;以"上下文不足"或"已执行 N 阶段"为由中断属纪律违反,必须完整走到 S_RECORD → END
|
|
23
|
+
|
|
24
|
+
**Zero-residual:** 每个发现必须有 action(fix / issue / decision)。"仅报告"和"历史遗留跳过"均禁止。
|
|
25
|
+
</execution_discipline>
|
|
26
|
+
|
|
27
|
+
<shared_schemas>
|
|
28
|
+
|
|
29
|
+
### session.json 标准字段(所有命令共有)
|
|
30
|
+
|
|
31
|
+
```json
|
|
32
|
+
{
|
|
33
|
+
"session_id": "{type}-odyssey-{YYYYMMDD-HHmmss}",
|
|
34
|
+
"current_state": "S_INTAKE",
|
|
35
|
+
"flags": { "skip_fix": false, "skip_generalize": false, "auto": false, "auto_confirm": false },
|
|
36
|
+
"phase_goals": [], "phase_goals_all_done": false,
|
|
37
|
+
"self_iteration_log": [],
|
|
38
|
+
"cross_phase_loops": 0, "max_loops": 5,
|
|
39
|
+
"created_at": "", "updated_at": ""
|
|
40
|
+
}
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
各命令在此基础上添加特有字段(如 `issue`, `target`, `requirement` 等)。
|
|
44
|
+
|
|
45
|
+
### evidence.ndjson 基础 schema(每行共有字段)
|
|
46
|
+
|
|
47
|
+
```json
|
|
48
|
+
{"ts":"","phase":"","type":"","source":"","content":"","note":""}
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
各命令定义 phase-specific 扩展字段(如 `hypothesis`, `severity`, `dimension` 等)。
|
|
52
|
+
|
|
53
|
+
### generalization_stats schema
|
|
54
|
+
|
|
55
|
+
```json
|
|
56
|
+
{
|
|
57
|
+
"patterns_extracted": 0, "total_hits": 0,
|
|
58
|
+
"cross_layer_confirmed": 0, "regression_risks": 0,
|
|
59
|
+
"by_layer": {"syntax": 0, "semantic": 0, "structural": 0},
|
|
60
|
+
"deepening_triggered": false
|
|
61
|
+
}
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
</shared_schemas>
|
|
65
|
+
|
|
66
|
+
<anti_stall>
|
|
67
|
+
**防停滞机制**
|
|
68
|
+
|
|
69
|
+
### session.json 新增字段
|
|
70
|
+
|
|
71
|
+
```json
|
|
72
|
+
{
|
|
73
|
+
"progress_metrics": {
|
|
74
|
+
"phase_stats": {},
|
|
75
|
+
"stale_count": 0,
|
|
76
|
+
"last_productive_phase": "",
|
|
77
|
+
"convergence_trend": "unknown"
|
|
78
|
+
},
|
|
79
|
+
"directions_tried": []
|
|
80
|
+
}
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Progress Tracking
|
|
84
|
+
|
|
85
|
+
每个分析阶段结束时:
|
|
86
|
+
1. 统计 `new_findings`(去重后新发现)和 `repeated`(与已有 evidence 重复)
|
|
87
|
+
2. 写入 `progress_metrics.phase_stats[state_name]`
|
|
88
|
+
3. `new == 0` → `stale_count++`,`convergence_trend = "stalling"`
|
|
89
|
+
4. `new > 0` → `stale_count = 0`,更新 `last_productive_phase`
|
|
90
|
+
5. 连续 2 阶段 new 递减 → `convergence_trend = "diminishing"`
|
|
91
|
+
|
|
92
|
+
### Direction Diversity
|
|
93
|
+
|
|
94
|
+
```json
|
|
95
|
+
{
|
|
96
|
+
"phase": "S_DIAGNOSE", "round": 1,
|
|
97
|
+
"strategy_type": "scope_widen|perspective_shift|tool_switch|structural_pivot",
|
|
98
|
+
"strategy_desc": "扩展搜索到 utils/", "result": "2 new findings"
|
|
99
|
+
}
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
**去重规则:** 自迭代前检查同 phase 历史 → 新策略必须在 `strategy_type` 或 `strategy_desc` 上不同 → 4 种 type 均已尝试 → 强制升级 stale_count
|
|
103
|
+
|
|
104
|
+
### Stall Escalation Ladder
|
|
105
|
+
|
|
106
|
+
| stale_count | 策略 |
|
|
107
|
+
|-------------|------|
|
|
108
|
+
| 0 | 正常推进 |
|
|
109
|
+
| 1 | **换视角** — 不同 CLI 工具、反向追踪、手动阅读。方向必须与 directions_tried 不同 |
|
|
110
|
+
| 2 | **结构性转向** — 重定义搜索维度、换分析框架、拆解子问题。不是参数调优 |
|
|
111
|
+
| 3 | **人工升级** — AskUserQuestion / `-y` 自动 INCONCLUSIVE 并推进 |
|
|
112
|
+
|
|
113
|
+
### /loop Heartbeat(可选,`--heartbeat` 启用)
|
|
114
|
+
|
|
115
|
+
建议用户 `/loop 270s`。每阶段更新 `session.json.updated_at`。超 15 分钟未更新 → 告警 + stale_count。连续 2 次无更新 → 建议 `-c` resume。
|
|
116
|
+
</anti_stall>
|
|
117
|
+
|
|
118
|
+
<self_iteration>
|
|
119
|
+
**Quality Gate(进度感知版)**
|
|
120
|
+
|
|
121
|
+
| 维度 | sufficient | insufficient |
|
|
122
|
+
|------|-----------|-------------|
|
|
123
|
+
| Coverage | 已知相关文件/模块均已分析 | 遗漏 grep/git log 可发现的目标 |
|
|
124
|
+
| Depth | ≥80% 发现有 file:line 级证据 | 多数仅泛泛描述 |
|
|
125
|
+
| Actionability | 每条结论有具体后续动作 | 仅"建议关注"类无操作结论 |
|
|
126
|
+
|
|
127
|
+
**进度感知迭代(替代固定 3 轮):**
|
|
128
|
+
- phase complete → evaluate 3 dims + check `progress_metrics`
|
|
129
|
+
- any insufficient AND `stale_count < 3` → re-enter,expansion strategy 必须经 directions_tried 去重
|
|
130
|
+
- 按 Stall Escalation Ladder 选择策略类型
|
|
131
|
+
|
|
132
|
+
**Expansion strategies:**
|
|
133
|
+
- `scope_widen`: 更多目录、git log 深度 ×2、额外 delegate 角度
|
|
134
|
+
- `perspective_shift`: 不同 CLI 工具、反向追踪、手动阅读
|
|
135
|
+
- `tool_switch`: 切换到未使用的分析工具
|
|
136
|
+
- `structural_pivot`: 重定义问题框架、拆解子问题
|
|
137
|
+
|
|
138
|
+
**Exit:** all sufficient → advance | `stale_count >= 3` → log gaps, advance
|
|
139
|
+
|
|
140
|
+
**Log:** `evidence.ndjson {"phase":"self-iteration"}` + `session.json.self_iteration_log[]` + `directions_tried[]`
|
|
141
|
+
</self_iteration>
|
|
142
|
+
|
|
143
|
+
<shared_actions>
|
|
144
|
+
|
|
145
|
+
### A_GENERALIZE
|
|
146
|
+
|
|
147
|
+
3 层 pattern extraction → 4-agent 并发 scan → cross-layer dedup → iterative deepening。
|
|
148
|
+
|
|
149
|
+
**Pattern 来源:** 由各命令指定(root cause / audit findings / implementation patterns 等)。
|
|
150
|
+
|
|
151
|
+
**3 层提取:**
|
|
152
|
+
|
|
153
|
+
| Layer | Method | Example |
|
|
154
|
+
|-------|--------|---------|
|
|
155
|
+
| Syntax | Regex → Grep | `eval(`, missing `await`, inline styles |
|
|
156
|
+
| Semantic | Agent 理解反模式 → scan | 未处理异步错误、缺少校验 |
|
|
157
|
+
| Structural | 文件/模块结构相似性 | 同类导入结构、缺少 override |
|
|
158
|
+
|
|
159
|
+
Write `session.json.patterns[]`: `[{id, source, layer, signature, description, risk, fix_template, confidence}]`
|
|
160
|
+
|
|
161
|
+
**4-agent 并发 scan(单条消息):**
|
|
162
|
+
|
|
163
|
+
| Agent | Strategy | Scope |
|
|
164
|
+
|-------|----------|-------|
|
|
165
|
+
| Syntax grep | Grep regex | Full project |
|
|
166
|
+
| Semantic scan | 反模式检查 | Related modules |
|
|
167
|
+
| Structural match | 结构相似文件 | Full project |
|
|
168
|
+
| Historical grep | `git log -S` | Git history |
|
|
169
|
+
|
|
170
|
+
**Cross-layer dedup:** 多层命中 → boost | 单层 → `needs_review` | 历史已修 → `regression_risk`
|
|
171
|
+
|
|
172
|
+
**Iterative deepening:** module ≥3 hits → 定向深扫(max 1 round)
|
|
173
|
+
|
|
174
|
+
**Persist:** understanding.md 泛化 section + `session.json.generalization_stats`(schema 见 shared_schemas)
|
|
175
|
+
|
|
176
|
+
📌 Auto-commit: `"...({slug}): GENERALIZE — 泛化扫描完成"`
|
|
177
|
+
|
|
178
|
+
### A_DISCOVER
|
|
179
|
+
|
|
180
|
+
1. **Triage** 每个 hit ±10 行上下文 → 分类 `bug` / `risk` / `safe`
|
|
181
|
+
2. **Route:**
|
|
182
|
+
- bug + 可直接修 → **立即修复** → back to S_FIX
|
|
183
|
+
- bug + 需跨模块决策 → 创建 issue(含 fix 建议 + 影响分析)
|
|
184
|
+
- risk → 评估能否直接加 guard;能 → 修
|
|
185
|
+
- safe → skip
|
|
186
|
+
Normal: AskUserQuestion | `-y`: auto-fix 可修的,其余 create issue
|
|
187
|
+
3. **Cross-phase loops:** `cross_phase_loops++`。`loops >= max_loops` → 必须逐项记录原因(禁止笼统"历史遗留")
|
|
188
|
+
4. Append evidence + update understanding.md
|
|
189
|
+
|
|
190
|
+
📌 Auto-commit: `"...({slug}): DISCOVER — 发现分类完成"`
|
|
191
|
+
|
|
192
|
+
### A_RECORD
|
|
193
|
+
|
|
194
|
+
1. Finalize understanding.md 最后一节 — learnings 按各命令指定的分类表结构化
|
|
195
|
+
- **两步模式:** 执行中写产出文件(临时)→ 完成后用户通过 next_step_routing 沉淀永久知识
|
|
196
|
+
2. Mark record goal done。Pending decisions: Normal → AskUserQuestion | `-y` → skip (show deferred count)
|
|
197
|
+
3. **Goal audit:** all `completion_confirmed` → `phase_goals_all_done = true`。未完成: Normal → AskUserQuestion | `-y` → auto accept
|
|
198
|
+
4. `current_state = "COMPLETED"`,emit completion summary(格式由各命令定义)
|
|
199
|
+
|
|
200
|
+
📌 Auto-commit: `"...({slug}): RECORD — 会话总结与知识沉淀"`
|
|
201
|
+
|
|
202
|
+
</shared_actions>
|
|
203
|
+
|
|
204
|
+
<shared_appendix>
|
|
205
|
+
|
|
206
|
+
### Goal Prompt 机制
|
|
207
|
+
|
|
208
|
+
**⚠️ 时机守卫:仅 INTAKE 完成后显示一次。RECORD 完成时禁止重显。**
|
|
209
|
+
|
|
210
|
+
```
|
|
211
|
+
📋 {Command} Odyssey 会话已创建。可随时复制以下 /goal 设定终止条件:
|
|
212
|
+
|
|
213
|
+
/goal 完成以下目标:
|
|
214
|
+
{for each G in phase_goals where status != "skipped":}
|
|
215
|
+
- {G.id}: {G.goal} — 完成条件: {G.done_when}
|
|
216
|
+
{end for}
|
|
217
|
+
{command-specific convergence rules}
|
|
218
|
+
遇到 phase=decision 的 pending 必须 AskUserQuestion,不得自行 resolve。
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
输出后继续执行不阻塞。
|
|
222
|
+
|
|
223
|
+
### `-y` 通用规则
|
|
224
|
+
|
|
225
|
+
- Decision pending → best-effort continue, record `deferred`
|
|
226
|
+
- 3-strike escalation → auto INCONCLUSIVE
|
|
227
|
+
- Discovery routing → auto create issue
|
|
228
|
+
- Record pending → skip, show deferred count
|
|
229
|
+
- Record goal audit → auto accept
|
|
230
|
+
|
|
231
|
+
`deferred` items 在 completion summary 显示为"待决策";可通过 `-c` 恢复。各命令在自身文件中列出特有 decision points。
|
|
232
|
+
|
|
233
|
+
### Phase Goal Lifecycle
|
|
234
|
+
|
|
235
|
+
`pending → done (confirmed=true)` | `pending → skipped (confirmed=true)` | `pending → failed (confirmed=false)`
|
|
236
|
+
|
|
237
|
+
`phase_goals_all_done = true` 仅当 ALL goals 有 `completion_confirmed == true`。
|
|
238
|
+
|
|
239
|
+
### Pre-load(可选,缺失不阻塞)
|
|
240
|
+
|
|
241
|
+
| 层级 | 命令 |
|
|
242
|
+
|------|------|
|
|
243
|
+
| Codebase docs | Read `.workflow/codebase/ARCHITECTURE.md` |
|
|
244
|
+
| Wiki search | `maestro search "<keywords>" --json`(top 5) |
|
|
245
|
+
| Specs | `maestro load --type spec --category <cat>` |
|
|
246
|
+
| Role knowledge | `maestro search --category <cat>` → `maestro load --type knowhow --id <id>` |
|
|
247
|
+
| Prior sessions | `Glob(".workflow/scratch/*-{type}-odyssey-*")` |
|
|
248
|
+
|
|
249
|
+
### Common Error Codes
|
|
250
|
+
|
|
251
|
+
| Code | Severity | Condition | Recovery |
|
|
252
|
+
|------|----------|-----------|----------|
|
|
253
|
+
| E003 | error | Resume but no session found | Start new |
|
|
254
|
+
| E004 | error | Delegate failed | Retry or proceed without |
|
|
255
|
+
| W003 | warning | Generalization 0 hits | Skip discovery |
|
|
256
|
+
| W004 | warning | Delegate parse failed | Use raw output |
|
|
257
|
+
|
|
258
|
+
</shared_appendix>
|
package/workflows/plan.md
CHANGED
|
@@ -148,7 +148,7 @@ When `--tdd` is active:
|
|
|
148
148
|
4b. **Load design reference** (if available)
|
|
149
149
|
- If `${PHASE_DIR}/design-ref/MASTER.md` exists: load MASTER.md, design-tokens.json, animation-tokens.json (optional), layout-templates/layout-*.json
|
|
150
150
|
- Every UI task must include in `read_first[]`: design-tokens.json, animation-tokens.json, relevant layout-*.json, MASTER.md
|
|
151
|
-
- Else if phase goal matches UI keywords (`landing|page|dashboard|frontend|UI|component|界面`):
|
|
151
|
+
- Else if phase goal matches UI keywords (`landing|page|dashboard|frontend|UI|component|界面`): run `maestro-impeccable --chain build` (REQUIRED when design keywords matched)
|
|
152
152
|
|
|
153
153
|
5. **Load upstream analysis** (if available)
|
|
154
154
|
- If `${PHASE_DIR}/conclusions.json` exists with non-empty status: load as explorationContext (conclusions + explorations.json + perspectives.json)
|
|
@@ -166,13 +166,14 @@ When `--tdd` is active:
|
|
|
166
166
|
|
|
167
167
|
6. **Parallel exploration** (skip if `--gaps` or upstream analysis loaded)
|
|
168
168
|
- Exploration angles (1-4 based on complexity): architecture, implementation, integration, risk
|
|
169
|
-
- Spawn 1-4 `cli-explore-agent` in parallel, each with phase goal + success_criteria + one angle
|
|
169
|
+
- MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn 1-4 `cli-explore-agent` in parallel, each with phase goal + success_criteria + one angle
|
|
170
170
|
- Output: `.process/exploration-{angle}.json`, `.process/explorations-manifest.json`, `.process/context-package.json`
|
|
171
171
|
|
|
172
172
|
6b. **CLI supplementary context** (runs in parallel with step 6, skip if `--gaps` or no CLI tools enabled)
|
|
173
173
|
```
|
|
174
174
|
IF no CLI tools enabled: skip
|
|
175
175
|
|
|
176
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep:
|
|
176
177
|
Bash({
|
|
177
178
|
command: 'maestro delegate "PURPOSE: Gather implementation context for planning phase
|
|
178
179
|
TASK: Identify existing patterns for similar features | Map dependency graph of target modules | Find potential conflict points with other recent changes
|
|
@@ -319,7 +320,7 @@ Bidirectional linking (main flow, post-planner): update matching issues in `.wor
|
|
|
319
320
|
|
|
320
321
|
### Steps
|
|
321
322
|
|
|
322
|
-
1. **Spawn workflow-plan-checker agent**
|
|
323
|
+
1. MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: **Spawn workflow-plan-checker agent**
|
|
323
324
|
- Input: plan.json + all .task/TASK-*.json + index.json (success_criteria)
|
|
324
325
|
- Check dimensions: requirements coverage, feasibility, dependency correctness (no circular deps), convergence criteria quality (grep-verifiable, no subjective language), read_first completeness, action concreteness (no vague references), wave structure (no conflicting files), completeness (no orphan tasks), UI-observable coverage (when plan touches UI: each delivery wave has ≥1 `[UI-observable]` criterion)
|
|
325
326
|
|
|
@@ -335,7 +336,7 @@ Bidirectional linking (main flow, post-planner): update matching issues in `.wor
|
|
|
335
336
|
|
|
336
337
|
4. **Plan Readiness Gate** (blocks P4.5)
|
|
337
338
|
|
|
338
|
-
Block if: requirements_coverage < 40% | task missing read_first/convergence.criteria | no pressure pass | circular deps. If blocked → AskUserQuestion: 修订计划 or 忽略风险并继续 (record residual_risks). Add confidence section to plan.json
|
|
339
|
+
Block if: requirements_coverage < 40% | task missing read_first/convergence.criteria | no pressure pass | circular deps. If blocked → AskUserQuestion: 修订计划 or 忽略风险并继续 (record residual_risks). Add confidence section to plan.json with `evidence_source: plan-checker findings (round N)`.
|
|
339
340
|
|
|
340
341
|
5. **Update index.json**
|
|
341
342
|
- Set `index.json.plan` = `{ task_ids, task_count, complexity, waves, executor_assignments: {}, confidence: overall_score }`
|
|
@@ -412,9 +413,9 @@ Bidirectional linking (main flow, post-planner): update matching issues in `.wor
|
|
|
412
413
|
| E005: Plan directory not found (--check) | Check path, use --dir |
|
|
413
414
|
| Phase directory not found | Abort with message: "Phase {phase} not found. Run /workflow:init first." |
|
|
414
415
|
| No context.md | Warn, proceed with exploration only |
|
|
415
|
-
| Exploration agent fails | Log error, continue with available explorations |
|
|
416
|
+
| Exploration agent fails | Log error, continue with available explorations; flag plan as [LOW CONFIDENCE] (partial explorations) |
|
|
416
417
|
| Planner produces invalid JSON | Retry once, then abort with error details |
|
|
417
|
-
| Plan-checker exceeds 3 rounds | Accept plan with warnings, note in index.json |
|
|
418
|
+
| Plan-checker exceeds 3 rounds | Accept plan with warnings, note in index.json; flag plan as [LOW CONFIDENCE] (checker unresolved) |
|
|
418
419
|
| User cancels clarification | Proceed with available context |
|
|
419
420
|
|
|
420
421
|
---
|
package/workflows/quick.md
CHANGED
|
@@ -215,7 +215,7 @@ Passed inline to planner agent in Step 5.
|
|
|
215
215
|
|
|
216
216
|
**Spawn workflow-planner in quick mode:**
|
|
217
217
|
|
|
218
|
-
Spawn `workflow-planner` agent with:
|
|
218
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn `workflow-planner` agent with:
|
|
219
219
|
|
|
220
220
|
- **Context**: mode (`quick` or `quick-full`), directory, description, state.json, CLAUDE.md, specs, context.md (if discuss mode)
|
|
221
221
|
- **Constraints**: single plan with 1-3 atomic tasks, no research phase. Full mode: ~40% context usage + require files/action/convergence.criteria/implementation per task. Default: ~30% context usage.
|
|
@@ -243,7 +243,7 @@ Skip entirely if NOT $FULL_MODE.
|
|
|
243
243
|
Spawning plan checker...
|
|
244
244
|
```
|
|
245
245
|
|
|
246
|
-
Spawn `workflow-plan-checker` agent to verify plan.json and TASK-*.json:
|
|
246
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn `workflow-plan-checker` agent to verify plan.json and TASK-*.json:
|
|
247
247
|
|
|
248
248
|
- **Check dimensions**: requirement coverage, task completeness (files/action/convergence.criteria/implementation), scope sanity (1-3 tasks), context compliance (if discuss mode).
|
|
249
249
|
- **Return**: `## VERIFICATION PASSED` or `## ISSUES FOUND` with structured issue list.
|
|
@@ -263,15 +263,17 @@ If iteration_count < 2:
|
|
|
263
263
|
|
|
264
264
|
If iteration_count >= 2:
|
|
265
265
|
- Display: "Max iterations reached. {N} issues remain."
|
|
266
|
-
- Offer: 1) Force proceed, 2) Abort
|
|
266
|
+
- Offer: 1) Force proceed, 2) Abort; if Force proceed, flag plan as [LOW CONFIDENCE] (remaining issues)
|
|
267
267
|
|
|
268
268
|
---
|
|
269
269
|
|
|
270
|
+
**GATE Step 6→7**: REQUIRED plan.json verified by plan-checker BEFORE execution; BLOCKED if plan.json not verified
|
|
271
|
+
|
|
270
272
|
### Step 7: Spawn Executor
|
|
271
273
|
|
|
272
274
|
**Spawn workflow-executor:**
|
|
273
275
|
|
|
274
|
-
Spawn `workflow-executor` agent:
|
|
276
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn `workflow-executor` agent:
|
|
275
277
|
|
|
276
278
|
- **Read**: plan.json, TASK-*.json, state.json, CLAUDE.md
|
|
277
279
|
- **Constraints**: execute all tasks, atomic commits per task, write summaries to `${QUICK_DIR}/.summaries/TASK-{NNN}-summary.md`
|
|
@@ -296,13 +298,13 @@ Skip entirely if NOT $FULL_MODE.
|
|
|
296
298
|
Spawning verifier...
|
|
297
299
|
```
|
|
298
300
|
|
|
299
|
-
Spawn `workflow-verifier` agent: check plan objectives against actual codebase using plan.json and summaries. Write result to `${QUICK_DIR}/verification.json`.
|
|
301
|
+
MANDATORY, NOT SUBSTITUTABLE by manual Read/Grep: Spawn `workflow-verifier` agent: check plan objectives against actual codebase using plan.json and summaries. Write result to `${QUICK_DIR}/verification.json`.
|
|
300
302
|
|
|
301
303
|
Read verification result:
|
|
302
304
|
| Status | Action |
|
|
303
305
|
|--------|--------|
|
|
304
306
|
| passed | Store "Verified", continue |
|
|
305
|
-
| gaps_found | Display gaps, offer: 1) Re-run executor, 2) Accept as-is |
|
|
307
|
+
| gaps_found | Display gaps, offer: 1) Re-run executor, 2) Accept as-is; if Accept as-is, flag execution as [LOW CONFIDENCE] (gaps unresolved) |
|
|
306
308
|
|
|
307
309
|
---
|
|
308
310
|
|