maestro-flow 0.5.44 → 0.5.46
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/agents/ralph-executor.md +93 -0
- package/.agents/skills/maestro-ralph-cli/SKILL.md +21 -16
- package/.agents/skills/maestro-ralph-v2/SKILL.md +923 -0
- package/.agents/skills/odyssey-debug/SKILL.md +338 -253
- package/.agents/skills/odyssey-improve/SKILL.md +367 -281
- package/.agents/skills/odyssey-planex/SKILL.md +490 -420
- package/.agents/skills/odyssey-review-test-fix/SKILL.md +336 -251
- package/.agents/skills/odyssey-ui/SKILL.md +332 -247
- package/.agy/agents/ralph-executor.md +91 -0
- package/.agy/skills/maestro-ralph-cli/SKILL.md +21 -16
- package/.agy/skills/maestro-ralph-v2/SKILL.md +935 -0
- package/.agy/skills/odyssey-debug/SKILL.md +338 -253
- package/.agy/skills/odyssey-improve/SKILL.md +367 -281
- package/.agy/skills/odyssey-planex/SKILL.md +490 -420
- package/.agy/skills/odyssey-review-test-fix/SKILL.md +336 -251
- package/.agy/skills/odyssey-ui/SKILL.md +332 -247
- package/.claude/agents/ralph-executor.md +91 -0
- package/.claude/commands/maestro-ralph-cli.md +21 -16
- package/.claude/commands/maestro-ralph-v2.md +921 -0
- package/.claude/commands/odyssey-debug.md +352 -267
- package/.claude/commands/odyssey-improve.md +381 -295
- package/.claude/commands/odyssey-planex.md +504 -434
- package/.claude/commands/odyssey-review-test-fix.md +350 -265
- package/.claude/commands/odyssey-ui.md +346 -261
- package/.codex/skills/maestro-next/SKILL.md +1 -1
- package/dashboard/dist-server/dashboard/src/server/wiki/embedding.js +3 -3
- package/dashboard/dist-server/dashboard/src/server/wiki/embedding.js.map +1 -1
- package/dashboard/dist-server/dashboard/src/server/wiki/wiki-indexer.js +4 -4
- package/dashboard/dist-server/dashboard/src/server/wiki/wiki-indexer.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/db/queries.d.ts +6 -0
- package/dashboard/dist-server/src/graph/kg/db/queries.js +141 -19
- package/dashboard/dist-server/src/graph/kg/db/queries.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/svelte-extractor.js +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/svelte-extractor.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/tree-sitter.js +2 -2
- package/dashboard/dist-server/src/graph/kg/extraction/code/tree-sitter.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/vue-extractor.js +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/vue-extractor.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/wasm-stability.js +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/code/wasm-stability.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/extraction/orchestrator.js +2 -2
- package/dashboard/dist-server/src/graph/kg/extraction/orchestrator.js.map +1 -1
- package/dashboard/dist-server/src/graph/kg/surface/hook-injector.js +1 -1
- package/dashboard/dist-server/src/graph/kg/surface/hook-injector.js.map +1 -1
- package/dashboard/dist-server/src/hooks/keyword-spec-injector.js +35 -0
- package/dashboard/dist-server/src/hooks/keyword-spec-injector.js.map +1 -1
- package/dashboard/dist-server/src/hooks/spec-analytics.d.ts +1 -0
- package/dashboard/dist-server/src/hooks/spec-analytics.js.map +1 -1
- package/dashboard/dist-server/src/hooks/wiki-search-bridge.d.ts +32 -0
- package/dashboard/dist-server/src/hooks/wiki-search-bridge.js +71 -0
- package/dashboard/dist-server/src/hooks/wiki-search-bridge.js.map +1 -0
- package/dist/src/agents/api-explore/agent-loop.d.ts +15 -2
- package/dist/src/agents/api-explore/agent-loop.d.ts.map +1 -1
- package/dist/src/agents/api-explore/agent-loop.js +6 -5
- package/dist/src/agents/api-explore/agent-loop.js.map +1 -1
- package/dist/src/agents/api-explore/config.d.ts +56 -0
- package/dist/src/agents/api-explore/config.d.ts.map +1 -1
- package/dist/src/agents/api-explore/config.js +34 -0
- package/dist/src/agents/api-explore/config.js.map +1 -1
- package/dist/src/agents/api-explore/llm.d.ts +5 -1
- package/dist/src/agents/api-explore/llm.d.ts.map +1 -1
- package/dist/src/agents/api-explore/llm.js +10 -8
- package/dist/src/agents/api-explore/llm.js.map +1 -1
- package/dist/src/agents/api-explore/moa-cache.d.ts +12 -0
- package/dist/src/agents/api-explore/moa-cache.d.ts.map +1 -0
- package/dist/src/agents/api-explore/moa-cache.js +50 -0
- package/dist/src/agents/api-explore/moa-cache.js.map +1 -0
- package/dist/src/agents/api-explore/moa-loop.d.ts +49 -0
- package/dist/src/agents/api-explore/moa-loop.d.ts.map +1 -0
- package/dist/src/agents/api-explore/moa-loop.js +43 -0
- package/dist/src/agents/api-explore/moa-loop.js.map +1 -0
- package/dist/src/agents/api-explore/moa-pipeline.d.ts +43 -0
- package/dist/src/agents/api-explore/moa-pipeline.d.ts.map +1 -0
- package/dist/src/agents/api-explore/moa-pipeline.js +276 -0
- package/dist/src/agents/api-explore/moa-pipeline.js.map +1 -0
- package/dist/src/agents/api-explore/runner.d.ts +3 -0
- package/dist/src/agents/api-explore/runner.d.ts.map +1 -1
- package/dist/src/agents/api-explore/runner.js +24 -7
- package/dist/src/agents/api-explore/runner.js.map +1 -1
- package/dist/src/agents/api-explore/session.d.ts +15 -0
- package/dist/src/agents/api-explore/session.d.ts.map +1 -1
- package/dist/src/agents/api-explore/session.js.map +1 -1
- package/dist/src/cli.js +1 -0
- package/dist/src/cli.js.map +1 -1
- package/dist/src/commands/explore.d.ts.map +1 -1
- package/dist/src/commands/explore.js +16 -1
- package/dist/src/commands/explore.js.map +1 -1
- package/dist/src/commands/moa.d.ts +3 -0
- package/dist/src/commands/moa.d.ts.map +1 -0
- package/dist/src/commands/moa.js +202 -0
- package/dist/src/commands/moa.js.map +1 -0
- package/dist/src/graph/kg/db/queries.d.ts +6 -0
- package/dist/src/graph/kg/db/queries.d.ts.map +1 -1
- package/dist/src/graph/kg/db/queries.js +141 -19
- package/dist/src/graph/kg/db/queries.js.map +1 -1
- package/dist/src/graph/kg/extraction/code/svelte-extractor.js +1 -1
- package/dist/src/graph/kg/extraction/code/svelte-extractor.js.map +1 -1
- package/dist/src/graph/kg/extraction/code/tree-sitter.js +2 -2
- package/dist/src/graph/kg/extraction/code/tree-sitter.js.map +1 -1
- package/dist/src/graph/kg/extraction/code/vue-extractor.js +1 -1
- package/dist/src/graph/kg/extraction/code/vue-extractor.js.map +1 -1
- package/dist/src/graph/kg/extraction/code/wasm-stability.js +1 -1
- package/dist/src/graph/kg/extraction/code/wasm-stability.js.map +1 -1
- package/dist/src/graph/kg/extraction/orchestrator.js +2 -2
- package/dist/src/graph/kg/extraction/orchestrator.js.map +1 -1
- package/dist/src/graph/kg/surface/hook-injector.js +1 -1
- package/dist/src/graph/kg/surface/hook-injector.js.map +1 -1
- package/dist/src/hooks/keyword-spec-injector.d.ts.map +1 -1
- package/dist/src/hooks/keyword-spec-injector.js +35 -0
- package/dist/src/hooks/keyword-spec-injector.js.map +1 -1
- package/dist/src/hooks/spec-analytics.d.ts +1 -0
- package/dist/src/hooks/spec-analytics.d.ts.map +1 -1
- package/dist/src/hooks/spec-analytics.js.map +1 -1
- package/dist/src/hooks/wiki-search-bridge.d.ts +33 -0
- package/dist/src/hooks/wiki-search-bridge.d.ts.map +1 -0
- package/dist/src/hooks/wiki-search-bridge.js +71 -0
- package/dist/src/hooks/wiki-search-bridge.js.map +1 -0
- 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/.agents/skills/maestro-ralph-agent/SKILL.md +0 -697
- package/.agents/skills/maestro-ralph-agent-execute/SKILL.md +0 -461
- package/.agy/skills/maestro-ralph-agent/SKILL.md +0 -696
- package/.agy/skills/maestro-ralph-agent-execute/SKILL.md +0 -457
- package/.claude/commands/maestro-ralph-agent-execute.md +0 -459
- package/.claude/commands/maestro-ralph-agent.md +0 -695
|
@@ -14,250 +14,335 @@ allowed-tools:
|
|
|
14
14
|
- view_file
|
|
15
15
|
- write_to_file
|
|
16
16
|
---
|
|
17
|
-
<base>@~/.maestro/workflows/odyssey-base.md</base>
|
|
18
|
-
|
|
19
|
-
<purpose>
|
|
20
|
-
survey → 6-dimension audit → divergent exploration → fix → verify → generalize → discover → persist.
|
|
21
|
-
Exhaustive iteration until all findings addressed or deferred.
|
|
22
|
-
</purpose>
|
|
23
|
-
|
|
24
|
-
<boundary>
|
|
25
|
-
**In scope:** Target component/page visual experience optimization — audit 6 dimensions, divergent exploration, fix, generalize to sibling components.
|
|
26
|
-
**Out of scope:** Backend/data/API → `/odyssey-planex` | Deep bug investigation → `/odyssey-debug` | Code quality review → `/odyssey-review-test-fix`
|
|
27
|
-
|
|
28
|
-
**Decision gate** — ONLY these qualify as decisions:
|
|
29
|
-
- Brand/style direction requiring human creative judgment
|
|
30
|
-
- Layout restructuring that changes user flow significantly
|
|
31
|
-
- Requires new design tokens or breaking component API
|
|
32
|
-
</boundary>
|
|
33
|
-
|
|
34
|
-
<context>
|
|
35
|
-
$ARGUMENTS
|
|
36
|
-
|
|
37
|
-
**Target resolution:** Component path → audit component | Page/route → audit page | `staged`/`HEAD` → diff UI changes | Feature area → resolve to components/pages
|
|
38
|
-
|
|
39
|
-
**Flags:** `--dimensions <list>` dimension subset | `--fix-threshold <severity>` | `--skip-fix` audit+diverge only | `--skip-generalize` skip generalize+discover | `--auto` no delegate confirmation | `-y` auto-confirm | `-c` resume | `--heartbeat` /loop heartbeat
|
|
40
|
-
|
|
41
|
-
**Session**: `.workflow/scratch/{YYYYMMDD}-ui-odyssey-{slug}/`
|
|
42
|
-
**Output**: `session.json` | `evidence.ndjson` | `understanding.md`
|
|
43
|
-
|
|
44
|
-
**session.json — ui-specific fields:**
|
|
45
|
-
```json
|
|
46
|
-
{ "target": "", "dimensions": [],
|
|
47
|
-
"audit_result": { "dimensions_audited": 0, "finding_count": 0, "severity_distribution": {} },
|
|
48
|
-
"diverge_result": { "improvements_proposed": 0, "creative_ideas": 0 },
|
|
49
|
-
"patterns": [], "confirmation": null, "generalization_stats": null }
|
|
50
|
-
```
|
|
51
|
-
|
|
52
|
-
**evidence.ndjson phases:** `survey|audit|diverge|fix|discovery|decision|self-iteration`
|
|
53
|
-
|
|
54
|
-
**phase_goals[]:**
|
|
55
|
-
|
|
56
|
-
| ID | Goal | Phase | skip_when |
|
|
57
|
-
|----|------|-------|-----------|
|
|
58
|
-
| G1 | Survey completed | S_SURVEY | — |
|
|
59
|
-
| G2 | Audit completed | S_AUDIT | — |
|
|
60
|
-
| G3 | Divergent exploration done | S_DIVERGE | — |
|
|
61
|
-
| G4 | Zero remaining: all findings/ideas fixed and verified | S_VERIFY | skip_fix |
|
|
62
|
-
| G5 | Pattern generalized | S_GENERALIZE | skip_generalize |
|
|
63
|
-
| G6 | Discoveries triaged | S_DISCOVER | skip_generalize |
|
|
64
|
-
| G7 | Learnings persisted | S_RECORD | — |
|
|
65
|
-
|
|
66
|
-
**understanding.md — 8 sections:**
|
|
67
|
-
1. Target & Design Context ← S_INTAKE | 2. Survey ← S_SURVEY | 3. Audit ← S_AUDIT
|
|
68
|
-
4. Diverge ← S_DIVERGE | 5. Verify ← S_VERIFY | 6. Generalize ← S_GENERALIZE
|
|
69
|
-
7. Discover ← S_DISCOVER | 8. Learnings ← S_RECORD
|
|
70
|
-
|
|
71
|
-
**Knowledge Persistence categories (section 8):**
|
|
72
|
-
|
|
73
|
-
| Category | Content | Follow-up |
|
|
74
|
-
|----------|---------|-----------|
|
|
75
|
-
| Design pattern | Component pattern + applicable scenarios + token references | `/spec-add ui` |
|
|
76
|
-
| Interaction spec | State definitions + transition rules + feedback patterns | `/spec-add ui` |
|
|
77
|
-
| Accessibility rule | WCAG requirement + implementation approach | `/spec-add ui` |
|
|
78
|
-
| Reusable generalization pattern | Pattern signature + application scope | `/spec-add coding` |
|
|
79
|
-
</context>
|
|
80
|
-
|
|
81
|
-
<invariants>
|
|
82
|
-
1-5 in base. UI-specific:
|
|
83
|
-
6. **Browser is truth** — verify in real rendering, not just code review
|
|
84
|
-
7. **Diverge before converge** — explore creatively first, then implement methodically
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
S_INTAKE →
|
|
100
|
-
S_INTAKE →
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
S_DIVERGE →
|
|
107
|
-
S_DIVERGE →
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
S_VERIFY →
|
|
112
|
-
S_VERIFY →
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
S_GENERALIZE →
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
S_DISCOVER →
|
|
119
|
-
S_DISCOVER →
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
|
153
|
-
|
|
|
154
|
-
|
|
|
155
|
-
|
|
|
156
|
-
|
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
- **
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
```
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
17
|
+
<base>@~/.maestro/workflows/odyssey-base.md</base>
|
|
18
|
+
|
|
19
|
+
<purpose>
|
|
20
|
+
survey → 6-dimension audit → divergent exploration → fix → verify → generalize → discover → persist.
|
|
21
|
+
Exhaustive iteration until all findings addressed or deferred.
|
|
22
|
+
</purpose>
|
|
23
|
+
|
|
24
|
+
<boundary>
|
|
25
|
+
**In scope:** Target component/page visual experience optimization — audit 6 dimensions, divergent exploration, fix, generalize to sibling components.
|
|
26
|
+
**Out of scope:** Backend/data/API → `/odyssey-planex` | Deep bug investigation → `/odyssey-debug` | Code quality review → `/odyssey-review-test-fix`
|
|
27
|
+
|
|
28
|
+
**Decision gate** — ONLY these qualify as decisions:
|
|
29
|
+
- Brand/style direction requiring human creative judgment
|
|
30
|
+
- Layout restructuring that changes user flow significantly
|
|
31
|
+
- Requires new design tokens or breaking component API
|
|
32
|
+
</boundary>
|
|
33
|
+
|
|
34
|
+
<context>
|
|
35
|
+
$ARGUMENTS
|
|
36
|
+
|
|
37
|
+
**Target resolution:** Component path → audit component | Page/route → audit page | `staged`/`HEAD` → diff UI changes | Feature area → resolve to components/pages
|
|
38
|
+
|
|
39
|
+
**Flags:** `--dimensions <list>` dimension subset | `--fix-threshold <severity>` | `--skip-fix` audit+diverge only | `--skip-generalize` skip generalize+discover | `--auto` no delegate confirmation | `-y` auto-confirm | `-c` resume | `--heartbeat` /loop heartbeat
|
|
40
|
+
|
|
41
|
+
**Session**: `.workflow/scratch/{YYYYMMDD}-ui-odyssey-{slug}/`
|
|
42
|
+
**Output**: `session.json` | `evidence.ndjson` | `understanding.md`
|
|
43
|
+
|
|
44
|
+
**session.json — ui-specific fields:**
|
|
45
|
+
```json
|
|
46
|
+
{ "target": "", "dimensions": [],
|
|
47
|
+
"audit_result": { "dimensions_audited": 0, "finding_count": 0, "severity_distribution": {} },
|
|
48
|
+
"diverge_result": { "improvements_proposed": 0, "creative_ideas": 0 },
|
|
49
|
+
"patterns": [], "confirmation": null, "generalization_stats": null }
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
**evidence.ndjson phases:** `survey|audit|diverge|fix|discovery|decision|self-iteration`
|
|
53
|
+
|
|
54
|
+
**phase_goals[]:**
|
|
55
|
+
|
|
56
|
+
| ID | Goal | Phase | skip_when |
|
|
57
|
+
|----|------|-------|-----------|
|
|
58
|
+
| G1 | Survey completed | S_SURVEY | — |
|
|
59
|
+
| G2 | Audit completed | S_AUDIT | — |
|
|
60
|
+
| G3 | Divergent exploration done | S_DIVERGE | — |
|
|
61
|
+
| G4 | Zero remaining: all findings/ideas fixed and verified | S_VERIFY | skip_fix |
|
|
62
|
+
| G5 | Pattern generalized | S_GENERALIZE | skip_generalize |
|
|
63
|
+
| G6 | Discoveries triaged | S_DISCOVER | skip_generalize |
|
|
64
|
+
| G7 | Learnings persisted | S_RECORD | — |
|
|
65
|
+
|
|
66
|
+
**understanding.md — 8 sections:**
|
|
67
|
+
1. Target & Design Context ← S_INTAKE | 2. Survey ← S_SURVEY | 3. Audit ← S_AUDIT
|
|
68
|
+
4. Diverge ← S_DIVERGE | 5. Verify ← S_VERIFY | 6. Generalize ← S_GENERALIZE
|
|
69
|
+
7. Discover ← S_DISCOVER | 8. Learnings ← S_RECORD
|
|
70
|
+
|
|
71
|
+
**Knowledge Persistence categories (section 8):**
|
|
72
|
+
|
|
73
|
+
| Category | Content | Follow-up |
|
|
74
|
+
|----------|---------|-----------|
|
|
75
|
+
| Design pattern | Component pattern + applicable scenarios + token references | `/spec-add ui` |
|
|
76
|
+
| Interaction spec | State definitions + transition rules + feedback patterns | `/spec-add ui` |
|
|
77
|
+
| Accessibility rule | WCAG requirement + implementation approach | `/spec-add ui` |
|
|
78
|
+
| Reusable generalization pattern | Pattern signature + application scope | `/spec-add coding` |
|
|
79
|
+
</context>
|
|
80
|
+
|
|
81
|
+
<invariants>
|
|
82
|
+
1-5 in base. UI-specific:
|
|
83
|
+
6. **Browser is truth** — verify in real rendering, not just code review
|
|
84
|
+
7. **Diverge before converge** — explore creatively first, then implement methodically
|
|
85
|
+
8. **Generalize is mandatory** — S_GENERALIZE and S_DISCOVER execute unless `skip_generalize == true`. "All verified" or context pressure are NOT valid reasons to skip. The phase itself determines whether patterns exist.
|
|
86
|
+
</invariants>
|
|
87
|
+
|
|
88
|
+
<self_iteration>
|
|
89
|
+
Applies to: **S_SURVEY, S_AUDIT, S_DIVERGE, S_GENERALIZE**. Logic in base.
|
|
90
|
+
</self_iteration>
|
|
91
|
+
|
|
92
|
+
<state_machine>
|
|
93
|
+
|
|
94
|
+
<states>
|
|
95
|
+
S_INTAKE → S_SURVEY → S_AUDIT → S_DIVERGE → S_FIX → S_VERIFY → S_GENERALIZE → S_DISCOVER → S_RECORD → END
|
|
96
|
+
</states>
|
|
97
|
+
|
|
98
|
+
<transitions>
|
|
99
|
+
S_INTAKE → S_INTAKE : -c + session found → A_RESUME
|
|
100
|
+
S_INTAKE → S_SURVEY : target resolved → A_INTAKE
|
|
101
|
+
S_INTAKE → S_INTAKE : no target → ask_question
|
|
102
|
+
|
|
103
|
+
S_SURVEY → S_AUDIT : complete
|
|
104
|
+
S_AUDIT → S_DIVERGE : complete
|
|
105
|
+
|
|
106
|
+
S_DIVERGE → S_FIX : !skip_fix AND actionable findings/ideas
|
|
107
|
+
S_DIVERGE → S_GENERALIZE : (skip_fix OR no actionable) AND !skip_generalize
|
|
108
|
+
S_DIVERGE → S_RECORD : (skip_fix OR no actionable) AND skip_generalize
|
|
109
|
+
|
|
110
|
+
S_FIX → S_VERIFY : fix implemented
|
|
111
|
+
S_VERIFY → S_GENERALIZE : verified, !skip_generalize
|
|
112
|
+
S_VERIFY → S_RECORD : verified, skip_generalize
|
|
113
|
+
S_VERIFY → S_FIX : needs_rework
|
|
114
|
+
|
|
115
|
+
S_GENERALIZE → S_DISCOVER : similar code found
|
|
116
|
+
S_GENERALIZE → S_RECORD : all 3 layers scanned with evidence, total_hits == 0
|
|
117
|
+
|
|
118
|
+
S_DISCOVER → S_AUDIT : new component to audit → cross_phase_loops++
|
|
119
|
+
S_DISCOVER → S_FIX : fixable sibling, !skip_fix → cross_phase_loops++
|
|
120
|
+
S_DISCOVER → S_RECORD : remaining_actionable == 0 OR loops >= max_loops → log per-item reasons
|
|
121
|
+
|
|
122
|
+
S_RECORD → END : complete
|
|
123
|
+
</transitions>
|
|
124
|
+
|
|
125
|
+
<actions>
|
|
126
|
+
|
|
127
|
+
### A_INTAKE
|
|
128
|
+
1. Parse arguments: target, flags, `--dimensions` subset
|
|
129
|
+
2. Generate slug, create SESSION_DIR
|
|
130
|
+
3. `maestro search` + Glob prior sessions + ARCHITECTURE.md + spec load ui/coding
|
|
131
|
+
4. Derive `phase_goals[]` from flags
|
|
132
|
+
5. Write `session.json` + `understanding.md` section 1, emit Goal Prompt
|
|
133
|
+
|
|
134
|
+
Commit: `"odyssey-ui({slug}): INTAKE — parse target and load context"`
|
|
135
|
+
|
|
136
|
+
### A_RESUME
|
|
137
|
+
Glob latest session → read `session.json` → jump to `current_state`.
|
|
138
|
+
|
|
139
|
+
### A_SURVEY
|
|
140
|
+
1. **Design system inventory**: Scan for design tokens, CSS variables, theme imports
|
|
141
|
+
2. **Current state analysis**: Styling patterns, layout strategy, component hierarchy
|
|
142
|
+
3. **CLI-assisted**: `maestro delegate --role analyze --mode analysis` — survey tokens, spacing, typography, hierarchy, consistency
|
|
143
|
+
4. Append evidence phase=survey. Update section 2. Mark G1.
|
|
144
|
+
|
|
145
|
+
Commit: `"odyssey-ui({slug}): SURVEY — design token inventory"`
|
|
146
|
+
|
|
147
|
+
### A_AUDIT
|
|
148
|
+
Spawn 6 parallel Agents (one per dimension, or `--dimensions` subset):
|
|
149
|
+
|
|
150
|
+
| Dimension | Focus |
|
|
151
|
+
|-----------|-------|
|
|
152
|
+
| visual_hierarchy | Spacing, typography scale, color contrast, alignment, whitespace, visual weight |
|
|
153
|
+
| interaction_states | Hover, focus, active, disabled, loading, error, empty, selected states |
|
|
154
|
+
| accessibility | WCAG AA contrast, focus management, aria labels, keyboard nav, screen reader |
|
|
155
|
+
| responsiveness | Breakpoints, overflow, touch targets, fluid typography, container queries |
|
|
156
|
+
| micro_interactions | Transitions, animations, feedback indicators, loading states, progress |
|
|
157
|
+
| edge_cases | Long text truncation, empty data, error states, extreme values, i18n, RTL |
|
|
158
|
+
|
|
159
|
+
Each returns `[{title, severity, file, line, description, suggestion, dimension}]`.
|
|
160
|
+
Merge → evidence phase=audit. Write `audit_result`. Update section 3 with severity matrix. Mark G2.
|
|
161
|
+
|
|
162
|
+
Commit: `"odyssey-ui({slug}): AUDIT — 6-dimension review"`
|
|
163
|
+
|
|
164
|
+
### A_DIVERGE
|
|
165
|
+
Goes beyond defect fixing — "what would make this delightful?"
|
|
166
|
+
|
|
167
|
+
**Step 1 — 2 parallel Agents:**
|
|
168
|
+
- **Polish Agent**: Shadows, borders, transitions, hover states, feedback, empty states, skeleton loading, scroll behavior
|
|
169
|
+
- **Delight Agent**: Motion design, progressive disclosure, smart defaults, contextual hints, celebratory feedback, personality in copy
|
|
170
|
+
|
|
171
|
+
Each returns `[{idea, category (polish|delight), impact, effort, description, inspiration}]`
|
|
172
|
+
|
|
173
|
+
**Step 2 — CLI-assisted**: `maestro delegate --role analyze --mode analysis` — polish opportunities, micro-interactions, visual rhythm, delight moments
|
|
174
|
+
|
|
175
|
+
**Step 3 — Consolidate**: Merge audit findings + divergent ideas → prioritized list (severity x impact x effort).
|
|
176
|
+
Append evidence phase=diverge. Update section 4. Mark G3.
|
|
177
|
+
|
|
178
|
+
Commit: `"odyssey-ui({slug}): DIVERGE — creative exploration"`
|
|
179
|
+
|
|
180
|
+
### A_FIX
|
|
181
|
+
Skip if `--skip-fix`.
|
|
182
|
+
1. **Exhaustive fix**: ALL findings/ideas by priority tier (critical → high → medium → low + high-impact ideas). After each tier, re-review — new findings append.
|
|
183
|
+
2. Each fix → evidence phase=fix
|
|
184
|
+
3. Normal: ask_question per-fix | `-y`: auto-proceed, record `deferred`
|
|
185
|
+
|
|
186
|
+
Commit: `"odyssey-ui({slug}): FIX — implement improvements"`
|
|
187
|
+
|
|
188
|
+
### A_VERIFY
|
|
189
|
+
1. Run tests (lint, unit, visual regression)
|
|
190
|
+
2. `maestro delegate --role review --mode analysis` — visual correctness, interaction states, accessibility, responsive
|
|
191
|
+
3. `needs_rework` → S_FIX. `verified` → mark G4. Update section 5, write `confirmation`.
|
|
192
|
+
|
|
193
|
+
Commit: `"odyssey-ui({slug}): VERIFY — visual verification"`
|
|
194
|
+
|
|
195
|
+
### A_GENERALIZE
|
|
196
|
+
|
|
197
|
+
**MANDATORY — executes unless `skip_generalize == true`. Prior-phase convergence, "all verified," or context pressure are NOT valid skip reasons.**
|
|
198
|
+
|
|
199
|
+
Pattern source: audit findings + diverge ideas (severity >= medium OR impact = high).
|
|
200
|
+
|
|
201
|
+
**Step 1 — 3-layer pattern extraction** from UI findings and creative improvements:
|
|
202
|
+
|
|
203
|
+
| Layer | Method | Targets |
|
|
204
|
+
|-------|--------|---------|
|
|
205
|
+
| Syntax | Build regex from fix diffs → Grep | Hardcoded px values, missing aria attributes, inline color values, raw z-index |
|
|
206
|
+
| Semantic | Understand UI anti-pattern → Agent scan | Inconsistent spacing scale, missing hover/focus states, keyboard nav gaps, contrast violations |
|
|
207
|
+
| Structural | Find components with same layout/state shape | Sibling components with same template, parallel page layouts, shared form patterns |
|
|
208
|
+
|
|
209
|
+
Write `session.json.patterns[]`: `[{id, source, layer, signature, description, risk, fix_template, confidence}]`
|
|
210
|
+
|
|
211
|
+
**Thoroughness floor:** ALL 3 layers must be attempted and logged. Each layer records search method, scope, hit count in evidence phase=generalization. "No hits" requires all 3 layers to return 0 with logged evidence.
|
|
212
|
+
|
|
213
|
+
**Step 2 — 4-agent concurrent scan** (single message, 4 Agents):
|
|
214
|
+
|
|
215
|
+
| Agent | Strategy | Scope |
|
|
216
|
+
|-------|----------|-------|
|
|
217
|
+
| Syntax grep | Grep regex from pattern signatures | Full project |
|
|
218
|
+
| Semantic scan | UI anti-pattern check (states, a11y, spacing) | Related components |
|
|
219
|
+
| Structural match | Find structurally similar components/pages | Full project |
|
|
220
|
+
| Historical grep | `git log -S` for pattern signatures | Git history |
|
|
221
|
+
|
|
222
|
+
**Step 3 — Cross-layer dedup:** multi-layer hit → boost | single-layer → `needs_review` | historically fixed → `regression_risk`
|
|
223
|
+
|
|
224
|
+
**Step 4 — Iterative deepening:** Component with ≥3 hits → targeted deep scan (max 1 round).
|
|
225
|
+
|
|
226
|
+
**Step 5 — Persist:** Update understanding.md section 6 + write `session.json.generalization_stats`:
|
|
227
|
+
```json
|
|
228
|
+
{"patterns_extracted": 0, "total_hits": 0, "cross_layer_confirmed": 0, "regression_risks": 0, "by_layer": {"syntax": 0, "semantic": 0, "structural": 0}, "deepening_triggered": false}
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
**Transition guard:** `S_GENERALIZE → S_RECORD` requires `by_layer` has entries for all 3 layers with search evidence logged. Mark G5 done.
|
|
232
|
+
|
|
233
|
+
Commit: `"odyssey-ui({slug}): GENERALIZE — pattern scan complete"`
|
|
234
|
+
|
|
235
|
+
### A_DISCOVER
|
|
236
|
+
|
|
237
|
+
**Executes whenever `total_hits > 0`. Cannot be skipped without `skip_generalize == true`.**
|
|
238
|
+
|
|
239
|
+
1. **Triage** each hit with ±10 lines context → classify:
|
|
240
|
+
- `bug` — confirmed UI defect in sibling component (missing state, broken a11y, inconsistent token)
|
|
241
|
+
- `risk` — potential visual/UX degradation
|
|
242
|
+
- `safe` — false positive (must log individual reason — blanket "pre-existing" forbidden)
|
|
243
|
+
|
|
244
|
+
2. **Route:**
|
|
245
|
+
|
|
246
|
+
| Classification | Action |
|
|
247
|
+
|---------------|--------|
|
|
248
|
+
| new component needing audit | Route to S_AUDIT, `cross_phase_loops++` |
|
|
249
|
+
| fixable sibling (same pattern) | Immediate fix → back to S_FIX, `cross_phase_loops++` |
|
|
250
|
+
| risk + guard addable | Fix directly |
|
|
251
|
+
| risk + design decision needed | Create issue |
|
|
252
|
+
| safe | Skip with logged per-item reason |
|
|
253
|
+
|
|
254
|
+
Normal: ask_question per hit | `-y`: auto-fix with template, create issue for rest
|
|
255
|
+
|
|
256
|
+
3. **Cross-phase loops:** `loops >= max_loops` → must log per-item reasons, advance to S_RECORD.
|
|
257
|
+
|
|
258
|
+
4. Append evidence phase=discovery. Update understanding.md section 7. Mark G6 done.
|
|
259
|
+
|
|
260
|
+
Commit: `"odyssey-ui({slug}): DISCOVER — sibling triage complete"`
|
|
261
|
+
|
|
262
|
+
### A_RECORD
|
|
263
|
+
|
|
264
|
+
1. Finalize understanding.md section 8 — learnings by Knowledge Persistence categories:
|
|
265
|
+
- Design pattern: component pattern + applicable scenarios + token references → `/spec-add ui`
|
|
266
|
+
- Interaction spec: state definitions + transition rules + feedback patterns → `/spec-add ui`
|
|
267
|
+
- Accessibility rule: WCAG requirement + implementation approach → `/spec-add ui`
|
|
268
|
+
- Reusable generalization pattern: signature + application scope → `/spec-add coding`
|
|
269
|
+
|
|
270
|
+
2. Mark G7 done. Pending decisions: Normal → ask_question | `-y` → skip (show deferred count).
|
|
271
|
+
|
|
272
|
+
3. **Goal audit (hardened):**
|
|
273
|
+
- `done` → confirmed
|
|
274
|
+
- `skipped` → confirmed ONLY if corresponding `skip_when` flag is true
|
|
275
|
+
- **Hard rule:** G5 and G6 CANNOT be `skipped` unless `skip_generalize == true`. Pending without flag → `failed` (Normal: ask_question | `-y`: record `failed`)
|
|
276
|
+
- `phase_goals_all_done = true` only when all goals pass this audit
|
|
277
|
+
|
|
278
|
+
4. `current_state = "COMPLETED"`, emit completion summary.
|
|
279
|
+
|
|
280
|
+
**Completion summary:**
|
|
281
|
+
```
|
|
282
|
+
--- UI ODYSSEY COMPLETE ---
|
|
283
|
+
Target: {target} | Dimensions: {dimensions_audited}
|
|
284
|
+
Findings: {C}C {H}H {M}M {L}L | Diverge: {improvements} polish + {creative} delight
|
|
285
|
+
Fix: {fixed_count} applied, verified={yes|skipped}
|
|
286
|
+
Patterns: {extracted} ({by_layer})
|
|
287
|
+
Scan hits: {total} ({cross_layer} cross-layer)
|
|
288
|
+
Issues: {N} created
|
|
289
|
+
Decisions: {N} resolved, {M} pending, {K} deferred
|
|
290
|
+
Learnings: {N} persisted
|
|
291
|
+
Self-iter: {N} rounds
|
|
292
|
+
Goals: {done}/{total} ({skipped} skipped)
|
|
293
|
+
---
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
Commit: `"odyssey-ui({slug}): RECORD — summary and knowledge persistence"`
|
|
297
|
+
|
|
298
|
+
</actions>
|
|
299
|
+
|
|
300
|
+
<appendix>
|
|
301
|
+
|
|
302
|
+
### `-y` ui-specific points
|
|
303
|
+
|
|
304
|
+
| Decision Point | Normal | `-y` |
|
|
305
|
+
|---------------|--------|------|
|
|
306
|
+
| A_FIX improvement confirmation | ask_question | auto-proceed, deferred |
|
|
307
|
+
| A_DISCOVER hit routing | ask_question | auto-fix with template, create issue for rest |
|
|
308
|
+
|
|
309
|
+
### Goal Prompt convergence rules
|
|
310
|
+
|
|
311
|
+
```
|
|
312
|
+
Stop when audit + diverge findings all addressed (fix/issue/decision),
|
|
313
|
+
phase_goals_all_done=true. Fix by impact x severity per tier.
|
|
314
|
+
Re-review after each tier — new findings append and continue.
|
|
315
|
+
Pending decisions must ask_question — no self-resolve.
|
|
316
|
+
```
|
|
317
|
+
|
|
318
|
+
</appendix>
|
|
319
|
+
|
|
320
|
+
</state_machine>
|
|
321
|
+
|
|
322
|
+
<error_codes>
|
|
323
|
+
| Code | Severity | Condition | Recovery |
|
|
324
|
+
|------|----------|-----------|----------|
|
|
325
|
+
| E001 | error | No target specified | Provide target |
|
|
326
|
+
| E002 | error | Target path not found | Check path |
|
|
327
|
+
| W001 | warning | No design system detected | Proceed with defaults |
|
|
328
|
+
| W002 | warning | Some dimension agents failed | Partial coverage |
|
|
329
|
+
| W003 | warning | Generalization 0 hits after full 3-layer scan | Advance to S_RECORD (requires all 3 layers attempted with evidence) |
|
|
330
|
+
</error_codes>
|
|
331
|
+
|
|
332
|
+
<success_criteria>
|
|
333
|
+
- [ ] 6-dimension audit with severity matrix + divergent exploration (polish + delight)
|
|
334
|
+
- [ ] Improvements implemented and verified (unless --skip-fix)
|
|
335
|
+
- [ ] Multi-layer generalization + discoveries classified (unless --skip-generalize)
|
|
336
|
+
- [ ] Every unfixed finding has individual classification and reason
|
|
337
|
+
- [ ] understanding.md section 8 finalized; phase_goals G1-G7 tracked; `-y` no blocking prompts
|
|
338
|
+
</success_criteria>
|
|
339
|
+
|
|
340
|
+
<next_step_routing>
|
|
341
|
+
| Condition | Next |
|
|
342
|
+
|-----------|------|
|
|
343
|
+
| Finding needs deeper debug | `/odyssey-debug "<finding>"` |
|
|
344
|
+
| Issues from discoveries | `/manage-issue list --source ui-odyssey` |
|
|
345
|
+
| Design pattern to document | `/spec-add ui "..."` |
|
|
346
|
+
| Full review of changes | `/odyssey-review-test-fix <changed-files>` |
|
|
347
|
+
| Sibling components to polish | `/odyssey-ui "<sibling>"` |
|
|
348
|
+
</next_step_routing>
|