maestro-flow 0.5.40 → 0.5.42
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-analyze/SKILL.md +0 -42
- package/.agents/skills/maestro-blueprint/SKILL.md +0 -22
- package/.agents/skills/maestro-brainstorm/SKILL.md +4 -24
- package/.agents/skills/maestro-execute/SKILL.md +1 -1
- package/.agents/skills/maestro-grill/SKILL.md +0 -16
- package/.agents/skills/maestro-milestone-audit/SKILL.md +0 -15
- package/.agents/skills/maestro-plan/SKILL.md +5 -62
- package/.agents/skills/maestro-roadmap/SKILL.md +0 -8
- package/.agents/skills/odyssey-debug/SKILL.md +109 -143
- package/.agents/skills/odyssey-improve/SKILL.md +127 -141
- package/.agents/skills/odyssey-planex/SKILL.md +140 -231
- package/.agents/skills/odyssey-review-test-fix/SKILL.md +136 -90
- package/.agents/skills/odyssey-ui/SKILL.md +123 -143
- package/.agents/skills/team-adversarial-swarm/workflows/wf-swarm-synthesize.js +248 -248
- package/.agents/skills/team-coordinate/specs/role-spec-template.md +197 -198
- package/.agents/skills/team-roadmap-dev/SKILL.md +164 -164
- package/.agents/skills/team-roadmap-dev/specs/team-config.json +1 -1
- package/.agents/skills/team-swarm/roles/analyst/role.md +172 -176
- package/.agy/skills/maestro-analyze/SKILL.md +0 -42
- package/.agy/skills/maestro-blueprint/SKILL.md +0 -22
- package/.agy/skills/maestro-brainstorm/SKILL.md +4 -24
- package/.agy/skills/maestro-execute/SKILL.md +1 -1
- package/.agy/skills/maestro-grill/SKILL.md +0 -16
- package/.agy/skills/maestro-milestone-audit/SKILL.md +0 -15
- package/.agy/skills/maestro-plan/SKILL.md +5 -62
- package/.agy/skills/maestro-roadmap/SKILL.md +0 -8
- package/.agy/skills/odyssey-debug/SKILL.md +109 -143
- package/.agy/skills/odyssey-improve/SKILL.md +127 -141
- package/.agy/skills/odyssey-planex/SKILL.md +140 -231
- package/.agy/skills/odyssey-review-test-fix/SKILL.md +136 -90
- package/.agy/skills/odyssey-ui/SKILL.md +123 -143
- package/.agy/skills/team-adversarial-swarm/workflows/wf-swarm-synthesize.js +248 -248
- package/.agy/skills/team-coordinate/specs/role-spec-template.md +197 -198
- package/.agy/skills/team-roadmap-dev/SKILL.md +141 -153
- package/.agy/skills/team-roadmap-dev/specs/team-config.json +1 -1
- package/.agy/skills/team-swarm/roles/analyst/role.md +172 -176
- package/.claude/commands/maestro-analyze.md +0 -42
- package/.claude/commands/maestro-blueprint.md +0 -22
- package/.claude/commands/maestro-brainstorm.md +4 -24
- package/.claude/commands/maestro-execute.md +1 -1
- package/.claude/commands/maestro-grill.md +0 -16
- package/.claude/commands/maestro-milestone-audit.md +0 -15
- package/.claude/commands/maestro-plan.md +5 -62
- package/.claude/commands/maestro-roadmap.md +0 -8
- package/.claude/commands/odyssey-debug.md +109 -143
- package/.claude/commands/odyssey-improve.md +127 -141
- package/.claude/commands/odyssey-planex.md +140 -231
- package/.claude/commands/odyssey-review-test-fix.md +136 -90
- package/.claude/commands/odyssey-ui.md +123 -143
- package/.claude/skills/team-adversarial-swarm/workflows/wf-swarm-synthesize.js +248 -248
- package/.claude/skills/team-coordinate/specs/role-spec-template.md +197 -198
- package/.claude/skills/team-roadmap-dev/SKILL.md +169 -169
- package/.claude/skills/team-roadmap-dev/specs/team-config.json +1 -1
- package/.claude/skills/team-swarm/roles/analyst/role.md +181 -185
- package/.codex/skills/odyssey-debug/SKILL.md +114 -169
- package/.codex/skills/odyssey-improve/SKILL.md +144 -188
- package/.codex/skills/odyssey-planex/SKILL.md +162 -242
- package/.codex/skills/odyssey-review-test-fix/SKILL.md +96 -90
- package/.codex/skills/odyssey-ui/SKILL.md +128 -173
- package/dashboard/dist-server/src/commands/install-backend.js +31 -16
- package/dashboard/dist-server/src/commands/install-backend.js.map +1 -1
- package/dashboard/dist-server/src/core/component-defs.js +25 -0
- package/dashboard/dist-server/src/core/component-defs.js.map +1 -1
- package/dashboard/dist-server/src/tools/spec-loader.js +32 -20
- package/dashboard/dist-server/src/tools/spec-loader.js.map +1 -1
- package/dashboard/dist-server/src/tools/spec-seeds.d.ts +8 -0
- package/dashboard/dist-server/src/tools/spec-seeds.js +114 -0
- package/dashboard/dist-server/src/tools/spec-seeds.js.map +1 -1
- package/dist/src/commands/install-backend.d.ts.map +1 -1
- package/dist/src/commands/install-backend.js +31 -16
- package/dist/src/commands/install-backend.js.map +1 -1
- package/dist/src/commands/spec.d.ts.map +1 -1
- package/dist/src/commands/spec.js +13 -3
- package/dist/src/commands/spec.js.map +1 -1
- package/dist/src/core/component-defs.d.ts.map +1 -1
- package/dist/src/core/component-defs.js +25 -0
- package/dist/src/core/component-defs.js.map +1 -1
- package/dist/src/tools/spec-init.d.ts +4 -3
- package/dist/src/tools/spec-init.d.ts.map +1 -1
- package/dist/src/tools/spec-init.js +9 -5
- package/dist/src/tools/spec-init.js.map +1 -1
- package/dist/src/tools/spec-loader.d.ts.map +1 -1
- package/dist/src/tools/spec-loader.js +32 -20
- package/dist/src/tools/spec-loader.js.map +1 -1
- package/dist/src/tools/spec-seeds.d.ts +8 -0
- package/dist/src/tools/spec-seeds.d.ts.map +1 -1
- package/dist/src/tools/spec-seeds.js +114 -0
- package/dist/src/tools/spec-seeds.js.map +1 -1
- package/dist/src/utils/update-notices.js +11 -0
- package/dist/src/utils/update-notices.js.map +1 -1
- package/package.json +1 -1
- package/workflows/agy-instructions.md +147 -161
- package/workflows/claude-instructions.md +100 -48
- package/workflows/codex-instructions.md +147 -161
- package/workflows/execute.md +4 -3
- package/workflows/explore-usage.md +41 -81
- package/workflows/grill.md +11 -0
- package/workflows/milestone-audit.md +8 -0
- package/workflows/odyssey-base-codex.md +305 -0
- package/workflows/odyssey-base.md +89 -91
- package/workflows/plan.md +6 -0
|
@@ -15,19 +15,19 @@ allowed-tools:
|
|
|
15
15
|
<base>@~/.maestro/workflows/odyssey-base.md</base>
|
|
16
16
|
|
|
17
17
|
<purpose>
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
survey → 6-dimension audit → diagnose → fix → verify → generalize → discover → persist.
|
|
19
|
+
Exhaustive iteration until zero remaining actionable findings.
|
|
20
20
|
</purpose>
|
|
21
21
|
|
|
22
22
|
<boundary>
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
**Zero-residual
|
|
23
|
+
**In scope:** Runtime quality improvement — performance/security/architecture/reliability/observability/maintainability audit → diagnose → fix → generalize.
|
|
24
|
+
**Out of scope:** UI visual → `/odyssey-ui` | New features → `/odyssey-planex` | Single bug → `/odyssey-debug` | Style review → `/odyssey-review-test-fix`
|
|
25
|
+
**Exploration freedom:** Free exploration within boundary — profiling, security scanning, architecture analysis, dependency audit.
|
|
26
|
+
**Zero-residual:** Every finding MUST have a concrete action (fix / issue / decision). "Report and shelve" is not allowed. "Pre-existing issue" is not a valid skip reason.
|
|
27
27
|
</boundary>
|
|
28
28
|
|
|
29
29
|
<context>
|
|
30
|
-
$ARGUMENTS
|
|
30
|
+
$ARGUMENTS
|
|
31
31
|
|
|
32
32
|
**Target resolution:**
|
|
33
33
|
| Input | Resolution |
|
|
@@ -37,17 +37,7 @@ $ARGUMENTS — target and optional flags.
|
|
|
37
37
|
| Feature area keyword | Resolve to related files |
|
|
38
38
|
| `--all` | Full project scan (use with caution) |
|
|
39
39
|
|
|
40
|
-
**Flags:**
|
|
41
|
-
| Flag | Effect | Default |
|
|
42
|
-
|------|--------|---------|
|
|
43
|
-
| `--dimensions <list>` | Comma-separated subset of 6 dimensions | all 6 |
|
|
44
|
-
| `--fix-threshold <severity>` | 修复到哪个 severity 为止(all = 全部修复)| all |
|
|
45
|
-
| `--skip-fix` | Audit + diagnose only, no code changes | false |
|
|
46
|
-
| `--skip-generalize` | Skip S_GENERALIZE and S_DISCOVER | false |
|
|
47
|
-
| `--auto` | CLI delegates without confirmation | false |
|
|
48
|
-
| `-y` | Auto-confirm all decisions (see appendix) | false |
|
|
49
|
-
| `-c` | Resume most recent session | — |
|
|
50
|
-
| `--heartbeat` | Enable /loop heartbeat protocol (see base) | false |
|
|
40
|
+
**Flags:** `--dimensions <list>` dimension subset | `--fix-threshold <severity>` fix cutoff (default: all) | `--skip-fix` audit+diagnose only | `--skip-generalize` skip S_GENERALIZE+S_DISCOVER | `--auto` no delegate confirmation | `-y` auto-confirm | `-c` resume | `--heartbeat` /loop heartbeat
|
|
51
41
|
|
|
52
42
|
**Dimensions (6):**
|
|
53
43
|
1. **performance** — hot paths, N+1 queries, memory allocation, cache efficiency, bundle size, lazy loading
|
|
@@ -57,13 +47,17 @@ $ARGUMENTS — target and optional flags.
|
|
|
57
47
|
5. **observability** — logging coverage, metric gaps, trace propagation, error reporting, health checks
|
|
58
48
|
6. **maintainability** — code complexity (cyclomatic), dead code, test coverage gaps, documentation debt
|
|
59
49
|
|
|
60
|
-
**Session**:
|
|
50
|
+
**Session**: `.workflow/scratch/{YYYYMMDD}-improve-odyssey-{slug}/`
|
|
51
|
+
**Output**: `session.json` | `evidence.ndjson` | `understanding.md`
|
|
61
52
|
|
|
62
|
-
**
|
|
53
|
+
**session.json — improve-specific fields:**
|
|
54
|
+
```json
|
|
55
|
+
{ "target": "", "dimensions": [], "baseline_metrics": {},
|
|
56
|
+
"audit_result": {}, "diagnoses": [], "confirmation": null,
|
|
57
|
+
"generalization_stats": null }
|
|
58
|
+
```
|
|
63
59
|
|
|
64
|
-
**
|
|
65
|
-
|
|
66
|
-
**evidence.ndjson phase-specific fields:**
|
|
60
|
+
**evidence.ndjson phases:** `survey|audit|diagnosis|fix|discovery|decision|self-iteration`
|
|
67
61
|
- `survey`: `category` (dependency|complexity|coverage|error_pattern), `detail`
|
|
68
62
|
- `audit`: `dimension`, `severity`, `measurement`
|
|
69
63
|
- `diagnosis`: `finding_ref`, `hypothesis`, `result` (confirmed|disproved|inconclusive), `root_cause`
|
|
@@ -73,92 +67,79 @@ $ARGUMENTS — target and optional flags.
|
|
|
73
67
|
- `self-iteration`: `stage`, `round`, `assessment`, `expansion`
|
|
74
68
|
|
|
75
69
|
**phase_goals[]:**
|
|
70
|
+
|
|
76
71
|
| ID | Goal | Phase | skip_when |
|
|
77
72
|
|----|------|-------|-----------|
|
|
78
73
|
| G1 | Survey completed | S_SURVEY | — |
|
|
79
74
|
| G2 | Audit completed | S_AUDIT | — |
|
|
80
75
|
| G3 | Diagnosis completed | S_DIAGNOSE | — |
|
|
81
|
-
| G4 | Zero remaining: all findings fixed and verified |
|
|
76
|
+
| G4 | Zero remaining: all findings fixed and verified | S_VERIFY | skip_fix |
|
|
82
77
|
| G5 | Pattern generalized | S_GENERALIZE | skip_generalize |
|
|
83
78
|
| G6 | Discoveries triaged | S_DISCOVER | skip_generalize |
|
|
84
79
|
| G7 | Learnings persisted | S_RECORD | — |
|
|
85
80
|
|
|
86
|
-
**understanding.md — 9 sections
|
|
81
|
+
**understanding.md — 9 sections:**
|
|
87
82
|
1. Target & Baseline ← S_INTAKE | 2. Current State Survey ← S_SURVEY | 3. Audit Findings ← S_AUDIT
|
|
88
83
|
4. Root Cause Diagnosis ← S_DIAGNOSE | 5. Fix & Verification ← S_FIX+S_VERIFY
|
|
89
84
|
6. Generalization ← S_GENERALIZE | 7. Discoveries ← S_DISCOVER
|
|
90
85
|
8. Improvement Metrics ← S_RECORD (before/after) | 9. Engineering Learnings ← S_RECORD
|
|
91
86
|
|
|
92
|
-
|
|
93
|
-
- ARCHITECTURE.md → 模块边界 | `maestro search "<target>" --json` → 先前优化(top 5)
|
|
94
|
-
- `maestro load --type spec --category coding` + `--category debug` → 编码规范 + 已知模式
|
|
95
|
-
- `maestro search --category coding` → knowhow | `Glob(".workflow/scratch/*-improve-odyssey-*")` → 先前会话
|
|
96
|
-
|
|
97
|
-
### Knowledge Persistence(S_RECORD 中写入产出文件)
|
|
87
|
+
**Knowledge Persistence categories (§9):**
|
|
98
88
|
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
|
102
|
-
|
|
103
|
-
|
|
|
104
|
-
|
|
|
105
|
-
| 架构约束 | 违反描述 + 正确边界 + 检查方法 | `/spec-add arch "..."` |
|
|
106
|
-
| 可靠性 pattern | 故障模式 + 处理策略 + 验证手段 | `/spec-add coding "..."` |
|
|
89
|
+
| Category | Content | Follow-up |
|
|
90
|
+
|----------|---------|-----------|
|
|
91
|
+
| Performance pattern | Bottleneck type + fix approach + measurement method | `/spec-add coding` |
|
|
92
|
+
| Security rule | Vulnerability class + fix + prevention method | `/spec-add debug` |
|
|
93
|
+
| Architecture constraint | Violation description + correct boundary + check method | `/spec-add arch` |
|
|
94
|
+
| Reliability pattern | Failure mode + handling strategy + verification method | `/spec-add coding` |
|
|
107
95
|
</context>
|
|
108
96
|
|
|
109
|
-
|
|
97
|
+
<invariants>
|
|
98
|
+
All invariants (evidence append-only, session-as-state, phase goal tracking, auto-commit, zero-residual) defined in base.
|
|
99
|
+
</invariants>
|
|
100
|
+
|
|
101
|
+
<self_iteration>
|
|
102
|
+
Applies to: **S_SURVEY, S_AUDIT, S_DIAGNOSE, S_GENERALIZE**. Logic in base.
|
|
103
|
+
</self_iteration>
|
|
110
104
|
|
|
111
105
|
<state_machine>
|
|
112
106
|
|
|
113
107
|
<states>
|
|
114
|
-
S_INTAKE
|
|
115
|
-
S_SURVEY — Current state: dependency audit, complexity scan, coverage PERSIST: evidence.ndjson (survey) + understanding.md §2
|
|
116
|
-
S_AUDIT — 6-dimension parallel deep audit PERSIST: evidence.ndjson (audit) + understanding.md §3
|
|
117
|
-
S_DIAGNOSE — Root cause analysis for critical/high findings PERSIST: evidence.ndjson (diagnosis|decision) + understanding.md §4
|
|
118
|
-
S_FIX — Implement improvements (skip if --skip-fix) PERSIST: code changes + evidence.ndjson (fix)
|
|
119
|
-
S_VERIFY — Tests + measurement comparison (skip if --skip-fix) PERSIST: session.json.confirmation + understanding.md §5
|
|
120
|
-
S_GENERALIZE — Pattern extraction + 4-agent scan (skip if --skip-gen) PERSIST: session.json.patterns + understanding.md §6
|
|
121
|
-
S_DISCOVER — Classify hits, create issues (skip if --skip-gen) PERSIST: evidence.ndjson (discovery|decision) + understanding.md §7
|
|
122
|
-
S_RECORD — Persist metrics + learnings + final report PERSIST: understanding.md §8-9 + spec entries
|
|
108
|
+
S_INTAKE → S_SURVEY → S_AUDIT → S_DIAGNOSE → S_FIX → S_VERIFY → S_GENERALIZE → S_DISCOVER → S_RECORD → END
|
|
123
109
|
</states>
|
|
124
110
|
|
|
125
111
|
<transitions>
|
|
126
|
-
S_INTAKE:
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
→ S_INTAKE WHEN no target DO AskUserQuestion
|
|
112
|
+
S_INTAKE → S_INTAKE : -c + session found → A_RESUME
|
|
113
|
+
S_INTAKE → S_SURVEY : target resolved → A_INTAKE
|
|
114
|
+
S_INTAKE → S_INTAKE : no target → AskUserQuestion
|
|
130
115
|
|
|
131
|
-
S_SURVEY
|
|
116
|
+
S_SURVEY → S_AUDIT : complete
|
|
132
117
|
|
|
133
|
-
S_AUDIT:
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
→ S_RECORD WHEN no findings OR skip_gen DO A_AUDIT
|
|
118
|
+
S_AUDIT → S_DIAGNOSE : critical/high findings exist
|
|
119
|
+
S_AUDIT → S_GENERALIZE : no critical/high, !skip_generalize
|
|
120
|
+
S_AUDIT → S_RECORD : no findings OR skip_generalize
|
|
137
121
|
|
|
138
|
-
S_DIAGNOSE:
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
→ S_RECORD WHEN hypotheses failed AND retries >= 3 DO mark INCONCLUSIVE
|
|
122
|
+
S_DIAGNOSE → S_FIX : root causes identified, !skip_fix
|
|
123
|
+
S_DIAGNOSE → S_GENERALIZE : root causes identified, skip_fix, !skip_generalize
|
|
124
|
+
S_DIAGNOSE → S_RECORD : root causes identified, skip_fix, skip_generalize
|
|
125
|
+
S_DIAGNOSE → S_DIAGNOSE : hypotheses failed, retries < 3 → A_ESCALATE_DIAGNOSIS
|
|
126
|
+
S_DIAGNOSE → S_RECORD : retries >= 3 → INCONCLUSIVE
|
|
144
127
|
|
|
145
|
-
S_FIX
|
|
128
|
+
S_FIX → S_VERIFY : fix implemented
|
|
146
129
|
|
|
147
|
-
S_VERIFY:
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
→ S_FIX WHEN needs_rework DO A_VERIFY
|
|
130
|
+
S_VERIFY → S_GENERALIZE : verified, !skip_generalize
|
|
131
|
+
S_VERIFY → S_RECORD : verified, skip_generalize
|
|
132
|
+
S_VERIFY → S_FIX : needs_rework
|
|
151
133
|
|
|
152
|
-
S_GENERALIZE:
|
|
153
|
-
|
|
154
|
-
→ S_RECORD WHEN no hits DO A_GENERALIZE
|
|
134
|
+
S_GENERALIZE → S_DISCOVER : hits found
|
|
135
|
+
S_GENERALIZE → S_RECORD : no hits
|
|
155
136
|
|
|
156
|
-
S_DISCOVER → S_DIAGNOSE : new critical issue
|
|
137
|
+
S_DISCOVER → S_DIAGNOSE : new critical issue → cross_phase_loops++
|
|
157
138
|
S_DISCOVER → S_FIX : same-pattern fix, !skip_fix → cross_phase_loops++
|
|
158
|
-
S_DISCOVER → S_RECORD :
|
|
159
|
-
S_DISCOVER → S_RECORD : loops >= max_loops → MUST log
|
|
139
|
+
S_DISCOVER → S_RECORD : remaining_actionable == 0
|
|
140
|
+
S_DISCOVER → S_RECORD : loops >= max_loops → MUST log per-item reasons
|
|
160
141
|
|
|
161
|
-
S_RECORD → END
|
|
142
|
+
S_RECORD → END : complete
|
|
162
143
|
</transitions>
|
|
163
144
|
|
|
164
145
|
<actions>
|
|
@@ -168,108 +149,111 @@ S_RECORD → END DO A_RECORD
|
|
|
168
149
|
2. Generate slug, create `SESSION_DIR`
|
|
169
150
|
3. Search: `maestro search "<keywords>"` + Glob prior sessions + ARCHITECTURE.md + spec load coding/debug
|
|
170
151
|
4. **Baseline capture**: Record current metrics (test pass rate, bundle size, dependency count, complexity hotspots) to `session.json.baseline_metrics`
|
|
171
|
-
5. Derive `phase_goals[]` from flags
|
|
172
|
-
6. Write `session.json` + `understanding.md` §1
|
|
173
|
-
7. Emit Goal Prompt (see Appendix)
|
|
152
|
+
5. Derive `phase_goals[]` from flags
|
|
153
|
+
6. Write `session.json` + `understanding.md` §1, emit Goal Prompt
|
|
174
154
|
|
|
175
|
-
|
|
155
|
+
Commit: `"odyssey-improve({slug}): INTAKE — parse target and capture baseline"`
|
|
176
156
|
|
|
177
157
|
### A_RESUME
|
|
178
|
-
|
|
158
|
+
Glob latest session → read `session.json` → display summary → jump to `current_state`.
|
|
179
159
|
|
|
180
160
|
### A_SURVEY
|
|
181
161
|
Current state survey — understand what exists before proposing changes.
|
|
182
162
|
|
|
183
163
|
1. Dependency audit (package.json/lock), complexity scan (size/nesting), test coverage map, error handling scan (empty catch, unhandled promise)
|
|
184
|
-
2. **CLI-assisted** (optional): `maestro delegate
|
|
185
|
-
3.
|
|
164
|
+
2. **CLI-assisted** (optional): `maestro delegate --role analyze --mode analysis` for dependency health, complexity hotspots, coverage gaps, error patterns. Execute `run_in_background: true`.
|
|
165
|
+
3. Evidence phase=survey. Update §2. Mark G1.
|
|
186
166
|
|
|
187
|
-
|
|
167
|
+
Commit: `"odyssey-improve({slug}): SURVEY — current state analysis"`
|
|
188
168
|
|
|
189
169
|
### A_AUDIT
|
|
190
|
-
Spawn 6 parallel Agents (one per dimension
|
|
170
|
+
Spawn 6 parallel Agents (one per dimension, or `--dimensions` subset).
|
|
191
171
|
Each returns: `[{title, severity, dimension, file, line, description, suggestion, measurement}]`
|
|
192
172
|
|
|
193
|
-
Merge → evidence
|
|
194
|
-
Update
|
|
173
|
+
Merge → evidence phase=audit. Write `session.json.audit_result`.
|
|
174
|
+
Update §3 (findings by dimension + severity matrix). Mark G2.
|
|
195
175
|
|
|
196
|
-
|
|
176
|
+
Commit: `"odyssey-improve({slug}): AUDIT — multi-dimension review"`
|
|
197
177
|
|
|
198
178
|
### A_DIAGNOSE
|
|
199
179
|
Root cause analysis for critical/high findings — don't fix symptoms.
|
|
200
180
|
|
|
201
|
-
1. Group by dimension, prioritize by severity. For each: hypothesis → trace code path + git history → evidence
|
|
202
|
-
2.
|
|
203
|
-
3.
|
|
204
|
-
4. Write `session.json.diagnoses[]`. Update
|
|
181
|
+
1. Group by dimension, prioritize by severity. For each: hypothesis → trace code path + git history → evidence phase=diagnosis
|
|
182
|
+
2. Ambiguity → evidence phase=decision; Normal: AskUserQuestion | `-y`: defer
|
|
183
|
+
3. CLI-assisted for complex findings: `maestro delegate --role analyze --mode analysis` (`run_in_background: true`)
|
|
184
|
+
4. Write `session.json.diagnoses[]`. Update §4. Mark G3.
|
|
205
185
|
|
|
206
|
-
|
|
186
|
+
Commit: `"odyssey-improve({slug}): DIAGNOSE — root cause analysis"`
|
|
207
187
|
|
|
208
188
|
### A_ESCALATE_DIAGNOSIS
|
|
209
|
-
|
|
189
|
+
`retries++`. < 3: `maestro delegate --role analyze`, new hypotheses, → S_DIAGNOSE. >= 3: Normal → AskUserQuestion | `-y` → INCONCLUSIVE → S_RECORD.
|
|
210
190
|
|
|
211
191
|
### A_FIX
|
|
212
|
-
|
|
192
|
+
1. Exhaustive fix: ALL diagnosed issues by severity tier (critical → high → medium → low within fix_threshold), one dimension at a time. After each tier, re-verify — new findings append to current tier.
|
|
193
|
+
2. For each fix: implement → evidence phase=fix
|
|
194
|
+
3. Normal: AskUserQuestion per-fix confirmation | `-y`: auto-proceed, record `deferred`
|
|
213
195
|
|
|
214
|
-
|
|
215
|
-
2. For each fix: implement → record evidence.ndjson (phase: "fix")
|
|
216
|
-
3. **Normal**: AskUserQuestion per-fix confirmation. **`-y`**: auto-proceed, record `deferred`.
|
|
217
|
-
|
|
218
|
-
📌 **Auto-commit**: `git add -A && git commit -m "odyssey-improve({slug}): FIX — 改进实现"`
|
|
196
|
+
Commit: `"odyssey-improve({slug}): FIX — improvements applied"`
|
|
219
197
|
|
|
220
198
|
### A_VERIFY
|
|
221
199
|
1. Run tests covering modified areas
|
|
222
200
|
2. Re-capture metrics, compare with `session.json.baseline_metrics`
|
|
223
|
-
3.
|
|
224
|
-
4. `needs_rework` → S_FIX. `verified` → mark G4
|
|
225
|
-
5. Write `session.json.confirmation`. Update
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
### A_GENERALIZE
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
201
|
+
3. CLI-assisted: `maestro delegate --role review --mode analysis` (`run_in_background: true`)
|
|
202
|
+
4. `needs_rework` → S_FIX. `verified` → mark G4, advance.
|
|
203
|
+
5. Write `session.json.confirmation`. Update §5 (before/after metrics table).
|
|
204
|
+
|
|
205
|
+
Commit: `"odyssey-improve({slug}): VERIFY — improvements verified"`
|
|
206
|
+
|
|
207
|
+
### A_GENERALIZE, A_DISCOVER, A_RECORD
|
|
208
|
+
Base shared_actions. Improve overrides:
|
|
209
|
+
- **A_GENERALIZE** pattern source: diagnoses + fixes
|
|
210
|
+
- **A_RECORD** §8: improvement metrics (before/after comparison from baseline_metrics vs current). §9: learnings per Knowledge Persistence table. Completion summary lists suggested `/spec-add` commands.
|
|
211
|
+
|
|
212
|
+
**Completion summary:**
|
|
213
|
+
```
|
|
214
|
+
--- IMPROVE ODYSSEY COMPLETE ---
|
|
215
|
+
Target: {target}
|
|
216
|
+
Dimensions: {dimensions}
|
|
217
|
+
Findings: {critical}C / {high}H / {medium}M / {low}L
|
|
218
|
+
Diagnosed: {count}
|
|
219
|
+
Fixed: {count} ({verified} verified)
|
|
220
|
+
Metrics: {improved} improved / {regressed} regressed
|
|
221
|
+
Patterns: {count} ({by_layer})
|
|
222
|
+
Scan hits: {total} ({cross_layer_confirmed} confirmed)
|
|
223
|
+
Issues: {N} created
|
|
224
|
+
Decisions: {N} resolved, {M} pending, {K} deferred
|
|
225
|
+
Learnings: {N} persisted
|
|
226
|
+
Self-iter: {N} rounds across {M} stages
|
|
227
|
+
Cross-loops: {N}
|
|
228
|
+
Goals: {done}/{total} ({skipped} skipped)
|
|
229
|
+
---
|
|
230
|
+
```
|
|
247
231
|
|
|
248
232
|
</actions>
|
|
249
233
|
|
|
250
234
|
<appendix>
|
|
251
235
|
|
|
252
|
-
###
|
|
253
|
-
**⚠️ 仅在 A_INTAKE 完成后显示一次,A_RECORD 完成时不重复。**
|
|
254
|
-
|
|
255
|
-
列出所有非 skipped 的 phase_goals,附加收敛规则:
|
|
256
|
-
- 穷尽迭代至所有 findings 已处理(fix/issue/decision)且 `phase_goals_all_done=true`
|
|
257
|
-
- 修复按 severity 逐轮迭代,每轮 re-verify
|
|
258
|
-
- Baseline 修复前采集,修复后对比确认改进
|
|
259
|
-
- pending decision 必须 AskUserQuestion,不允许"只报告不处理"
|
|
236
|
+
### `-y` improve-specific points
|
|
260
237
|
|
|
261
|
-
### `-y` Auto-Confirm Behavior
|
|
262
238
|
| Decision Point | Normal | `-y` |
|
|
263
239
|
|---------------|--------|------|
|
|
264
240
|
| A_FIX improvement confirmation | AskUserQuestion | auto-proceed, `deferred` |
|
|
265
241
|
| A_DIAGNOSE ambiguity | AskUserQuestion | best-effort, `deferred` |
|
|
266
242
|
| A_ESCALATE 3-strike | AskUserQuestion 3-way | auto INCONCLUSIVE |
|
|
267
|
-
| A_DISCOVER hit routing | AskUserQuestion | auto create issue
|
|
243
|
+
| A_DISCOVER hit routing | AskUserQuestion | auto create issue |
|
|
268
244
|
| A_DISCOVER ambiguous items | AskUserQuestion | all `deferred` |
|
|
269
|
-
| A_RECORD pending decisions | AskUserQuestion | skip, show deferred count |
|
|
270
|
-
| A_RECORD goal audit | AskUserQuestion | auto accept |
|
|
271
245
|
|
|
272
|
-
`deferred` items shown
|
|
246
|
+
`deferred` items shown in completion summary; recoverable via `-c`.
|
|
247
|
+
|
|
248
|
+
### Goal Prompt convergence rules
|
|
249
|
+
|
|
250
|
+
```
|
|
251
|
+
Exhaust iteration until all findings actioned (fix/issue/decision)
|
|
252
|
+
and phase_goals_all_done=true.
|
|
253
|
+
Fix by severity tiers, re-verify after each tier.
|
|
254
|
+
Baseline captured before fix, compared after to confirm improvement.
|
|
255
|
+
Pending decisions must AskUserQuestion — no silent resolve.
|
|
256
|
+
```
|
|
273
257
|
|
|
274
258
|
</appendix>
|
|
275
259
|
|
|
@@ -294,16 +278,18 @@ Skip if `--skip-fix`. Implement improvements for diagnosed root causes.
|
|
|
294
278
|
- [ ] understanding.md §8 (metrics) and §9 (learnings) completed
|
|
295
279
|
- [ ] phase_goals G1-G7 tracked and audited
|
|
296
280
|
- [ ] Session resumable via -c
|
|
281
|
+
- [ ] Completion summary
|
|
297
282
|
</success_criteria>
|
|
298
283
|
|
|
299
284
|
<next_step_routing>
|
|
300
|
-
| Condition | Next
|
|
301
|
-
|
|
285
|
+
| Condition | Next |
|
|
286
|
+
|-----------|------|
|
|
302
287
|
| Security findings need deep investigation | `/odyssey-debug "<finding>"` |
|
|
303
288
|
| UI-related findings | `/odyssey-ui "<component>"` |
|
|
304
289
|
| Issues created from discoveries | `/manage-issue list --source improve-odyssey` |
|
|
305
290
|
| Architecture pattern to document | `/spec-add arch "..."` |
|
|
306
291
|
| Performance pattern to persist | `/spec-add coding "..."` |
|
|
307
|
-
|
|
|
308
|
-
|
|
|
292
|
+
| Formal review of changes | `/odyssey-review-test-fix <changed-files>` |
|
|
293
|
+
| Pending decisions | Filter evidence phase=decision status=pending |
|
|
309
294
|
</next_step_routing>
|
|
295
|
+
</output>
|