@jmylchreest/aide-plugin 0.0.26 → 0.0.28
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/package.json +1 -1
- package/skills/code-search/SKILL.md +10 -2
- package/skills/decide/SKILL.md +31 -15
- package/skills/design/SKILL.md +24 -8
- package/skills/implement/SKILL.md +15 -6
- package/skills/memorise/SKILL.md +25 -16
- package/skills/plan-swarm/SKILL.md +11 -2
- package/skills/ralph/SKILL.md +82 -57
- package/skills/swarm/SKILL.md +71 -31
- package/skills/worktree-resolve/SKILL.md +20 -4
- package/src/cli/install.ts +2 -2
- package/src/cli/mcp.ts +1 -1
- package/src/core/session-init.ts +11 -0
- package/src/opencode/index.ts +1 -1
package/skills/ralph/SKILL.md
CHANGED
|
@@ -35,39 +35,43 @@ You are now in **Ralph Wiggum mode** - an iterative development methodology that
|
|
|
35
35
|
All state is managed through aide. Use MCP tools for reads, CLI for writes:
|
|
36
36
|
|
|
37
37
|
### Reads (MCP Tools)
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
|
41
|
-
| `
|
|
42
|
-
| `
|
|
43
|
-
| `
|
|
44
|
-
| `
|
|
38
|
+
|
|
39
|
+
| Tool | Purpose |
|
|
40
|
+
| -------------------------------------- | -------------------- |
|
|
41
|
+
| `mcp__plugin_aide_aide__state_get` | Get phase, objective |
|
|
42
|
+
| `mcp__plugin_aide_aide__state_list` | List all state |
|
|
43
|
+
| `mcp__plugin_aide_aide__decision_get` | Get decisions |
|
|
44
|
+
| `mcp__plugin_aide_aide__decision_list` | List all decisions |
|
|
45
|
+
| `mcp__plugin_aide_aide__memory_search` | Search discoveries |
|
|
45
46
|
|
|
46
47
|
### Writes (CLI via Bash)
|
|
48
|
+
|
|
47
49
|
```bash
|
|
48
50
|
# Phase tracking
|
|
49
|
-
aide state set ralph:phase planning # or "building"
|
|
51
|
+
./.aide/bin/aide state set ralph:phase planning # or "building"
|
|
50
52
|
|
|
51
53
|
# Task management (use Claude's native TaskCreate/TaskUpdate/TaskList)
|
|
52
54
|
|
|
53
55
|
# Decisions
|
|
54
|
-
aide decision set <topic> "<decision>" --rationale="<why>"
|
|
56
|
+
./.aide/bin/aide decision set <topic> "<decision>" --rationale="<why>"
|
|
55
57
|
|
|
56
58
|
# Gap analysis / discoveries
|
|
57
|
-
aide memory add --category=discovery --tags=ralph "Gap found: <description>"
|
|
59
|
+
./.aide/bin/aide memory add --category=discovery --tags=ralph "Gap found: <description>"
|
|
58
60
|
```
|
|
59
61
|
|
|
62
|
+
**Binary location:** The aide binary is at `.aide/bin/aide`. If it's on your `$PATH`, you can use `aide` directly.
|
|
63
|
+
|
|
60
64
|
---
|
|
61
65
|
|
|
62
66
|
## Phase 1: Planning Mode
|
|
63
67
|
|
|
64
|
-
When starting a new task or when
|
|
68
|
+
When starting a new task or when `./.aide/bin/aide state get ralph:phase` is empty/planning:
|
|
65
69
|
|
|
66
70
|
### Step 1: Set Phase
|
|
67
71
|
|
|
68
72
|
```bash
|
|
69
|
-
aide state set ralph:phase planning
|
|
70
|
-
aide state set ralph:objective "<what we're building>"
|
|
73
|
+
./.aide/bin/aide state set ralph:phase planning
|
|
74
|
+
./.aide/bin/aide state set ralph:objective "<what we're building>"
|
|
71
75
|
```
|
|
72
76
|
|
|
73
77
|
### Step 2: Gap Analysis (Don't Assume!)
|
|
@@ -83,8 +87,9 @@ rg "describe.*feature\|it.*should" --type ts
|
|
|
83
87
|
```
|
|
84
88
|
|
|
85
89
|
Record findings:
|
|
90
|
+
|
|
86
91
|
```bash
|
|
87
|
-
aide memory add --category=discovery --tags=ralph,gap-analysis "Searched for X: <results>"
|
|
92
|
+
./.aide/bin/aide memory add --category=discovery --tags=ralph,gap-analysis "Searched for X: <results>"
|
|
88
93
|
```
|
|
89
94
|
|
|
90
95
|
Only after confirming gaps exist, proceed to task creation.
|
|
@@ -94,12 +99,13 @@ Only after confirming gaps exist, proceed to task creation.
|
|
|
94
99
|
Create atomic, testable tasks:
|
|
95
100
|
|
|
96
101
|
```bash
|
|
97
|
-
aide task create "Implement user model" --tags=ralph,task-1
|
|
98
|
-
aide task create "Add validation to user model" --tags=ralph,task-2
|
|
99
|
-
aide task create "Write user model tests" --tags=ralph,task-3
|
|
102
|
+
./.aide/bin/aide task create "Implement user model" --tags=ralph,task-1
|
|
103
|
+
./.aide/bin/aide task create "Add validation to user model" --tags=ralph,task-2
|
|
104
|
+
./.aide/bin/aide task create "Write user model tests" --tags=ralph,task-3
|
|
100
105
|
```
|
|
101
106
|
|
|
102
107
|
Each task should be:
|
|
108
|
+
|
|
103
109
|
- Small enough to complete in one iteration
|
|
104
110
|
- Independently testable
|
|
105
111
|
- Clearly defined acceptance criteria
|
|
@@ -107,19 +113,20 @@ Each task should be:
|
|
|
107
113
|
### Step 4: Record Key Decisions
|
|
108
114
|
|
|
109
115
|
```bash
|
|
110
|
-
aide decision set ralph:test-framework "vitest" --rationale="Already configured in project"
|
|
111
|
-
aide decision set ralph:approach "<approach>" --rationale="<why>"
|
|
116
|
+
./.aide/bin/aide decision set ralph:test-framework "vitest" --rationale="Already configured in project"
|
|
117
|
+
./.aide/bin/aide decision set ralph:approach "<approach>" --rationale="<why>"
|
|
112
118
|
```
|
|
113
119
|
|
|
114
120
|
### Step 5: Exit Planning
|
|
115
121
|
|
|
116
122
|
```bash
|
|
117
|
-
aide state set ralph:phase building
|
|
123
|
+
./.aide/bin/aide state set ralph:phase building
|
|
118
124
|
```
|
|
119
125
|
|
|
120
126
|
Report the plan:
|
|
121
|
-
|
|
122
|
-
- List
|
|
127
|
+
|
|
128
|
+
- List tasks: `./.aide/bin/aide task list`
|
|
129
|
+
- List decisions: `./.aide/bin/aide decision list`
|
|
123
130
|
|
|
124
131
|
**DO NOT implement during planning phase.**
|
|
125
132
|
|
|
@@ -127,7 +134,7 @@ Report the plan:
|
|
|
127
134
|
|
|
128
135
|
## Phase 2: Building Mode
|
|
129
136
|
|
|
130
|
-
When
|
|
137
|
+
When `./.aide/bin/aide state get ralph:phase` returns "building":
|
|
131
138
|
|
|
132
139
|
### Iteration Loop
|
|
133
140
|
|
|
@@ -137,26 +144,34 @@ Each iteration follows this exact sequence:
|
|
|
137
144
|
|
|
138
145
|
```bash
|
|
139
146
|
# Check current phase and objective
|
|
140
|
-
aide state get ralph:phase
|
|
141
|
-
aide state get ralph:objective
|
|
147
|
+
./.aide/bin/aide state get ralph:phase
|
|
148
|
+
./.aide/bin/aide state get ralph:objective
|
|
142
149
|
|
|
143
150
|
# List tasks to find next one
|
|
144
|
-
aide task list
|
|
151
|
+
./.aide/bin/aide task list
|
|
145
152
|
|
|
146
153
|
# Check existing decisions
|
|
147
|
-
aide decision list
|
|
154
|
+
./.aide/bin/aide decision list
|
|
148
155
|
```
|
|
149
156
|
|
|
150
157
|
#### 2. Select Next Task
|
|
151
158
|
|
|
152
159
|
Find the first pending task:
|
|
160
|
+
|
|
153
161
|
```bash
|
|
154
|
-
aide task list # Look for [pending] status
|
|
162
|
+
./.aide/bin/aide task list # Look for [pending] status
|
|
155
163
|
```
|
|
156
164
|
|
|
157
165
|
Claim it:
|
|
166
|
+
|
|
158
167
|
```bash
|
|
159
|
-
aide task claim <task-id> --agent=ralph
|
|
168
|
+
./.aide/bin/aide task claim <task-id> --agent=ralph
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
Claim it:
|
|
172
|
+
|
|
173
|
+
```bash
|
|
174
|
+
./.aide/bin/aide task claim <task-id> --agent=ralph
|
|
160
175
|
```
|
|
161
176
|
|
|
162
177
|
#### 3. Verify Gap Still Exists (Don't Assume!)
|
|
@@ -169,8 +184,9 @@ rg "featureName" --type ts
|
|
|
169
184
|
```
|
|
170
185
|
|
|
171
186
|
If gap no longer exists:
|
|
187
|
+
|
|
172
188
|
```bash
|
|
173
|
-
aide task complete <task-id>
|
|
189
|
+
./.aide/bin/aide task complete <task-id>
|
|
174
190
|
# Proceed to next task
|
|
175
191
|
```
|
|
176
192
|
|
|
@@ -198,6 +214,7 @@ npm test -- path/to/test.test.ts
|
|
|
198
214
|
```
|
|
199
215
|
|
|
200
216
|
**BLOCKING RULE**: If tests fail, you MUST:
|
|
217
|
+
|
|
201
218
|
1. Analyze the failure
|
|
202
219
|
2. Fix the issue
|
|
203
220
|
3. Re-run tests
|
|
@@ -208,7 +225,7 @@ npm test -- path/to/test.test.ts
|
|
|
208
225
|
#### 7. Complete Task
|
|
209
226
|
|
|
210
227
|
```bash
|
|
211
|
-
aide task complete <task-id>
|
|
228
|
+
./.aide/bin/aide task complete <task-id>
|
|
212
229
|
```
|
|
213
230
|
|
|
214
231
|
#### 8. Atomic Commit
|
|
@@ -221,7 +238,7 @@ git commit -m "feat: <task description> - tests passing"
|
|
|
221
238
|
#### 9. Check Completion
|
|
222
239
|
|
|
223
240
|
```bash
|
|
224
|
-
aide task list
|
|
241
|
+
./.aide/bin/aide task list
|
|
225
242
|
```
|
|
226
243
|
|
|
227
244
|
If more pending tasks: continue to next iteration (step 2)
|
|
@@ -241,16 +258,19 @@ When tests fail during backpressure checkpoint:
|
|
|
241
258
|
4. **DO** fix and re-run until passing
|
|
242
259
|
|
|
243
260
|
Record blockers:
|
|
261
|
+
|
|
244
262
|
```bash
|
|
245
|
-
aide memory add --category=blocker --tags=ralph "Test failure: <description>"
|
|
263
|
+
./.aide/bin/aide memory add --category=blocker --tags=ralph "Test failure: <description>"
|
|
246
264
|
```
|
|
247
265
|
|
|
248
266
|
### Stuck Conditions
|
|
249
267
|
|
|
250
268
|
If blocked for more than 3 attempts:
|
|
269
|
+
|
|
251
270
|
```bash
|
|
252
|
-
aide memory add --category=blocker --tags=ralph,needs-help "Stuck on: <description>"
|
|
271
|
+
./.aide/bin/aide memory add --category=blocker --tags=ralph,needs-help "Stuck on: <description>"
|
|
253
272
|
```
|
|
273
|
+
|
|
254
274
|
Then ask user for guidance. **DO NOT** proceed without resolution.
|
|
255
275
|
|
|
256
276
|
---
|
|
@@ -261,7 +281,7 @@ Before claiming completion, ALL must pass:
|
|
|
261
281
|
|
|
262
282
|
```bash
|
|
263
283
|
# 1. All tasks complete
|
|
264
|
-
aide task list # Should show all [done]
|
|
284
|
+
./.aide/bin/aide task list # Should show all [done]
|
|
265
285
|
|
|
266
286
|
# 2. All tests
|
|
267
287
|
npm test
|
|
@@ -284,14 +304,14 @@ When all tasks complete and verification passes:
|
|
|
284
304
|
### Update State
|
|
285
305
|
|
|
286
306
|
```bash
|
|
287
|
-
aide state set ralph:phase complete
|
|
288
|
-
aide state set ralph:result "success"
|
|
307
|
+
./.aide/bin/aide state set ralph:phase complete
|
|
308
|
+
./.aide/bin/aide state set ralph:result "success"
|
|
289
309
|
```
|
|
290
310
|
|
|
291
311
|
### Record Session
|
|
292
312
|
|
|
293
313
|
```bash
|
|
294
|
-
aide memory add --category=session --tags=ralph,implementation "
|
|
314
|
+
./.aide/bin/aide memory add --category=session --tags=ralph,implementation "
|
|
295
315
|
## <Feature Name> Complete
|
|
296
316
|
|
|
297
317
|
Implemented using Ralph Wiggum methodology.
|
|
@@ -338,21 +358,21 @@ Implemented using Ralph Wiggum methodology.
|
|
|
338
358
|
|
|
339
359
|
```
|
|
340
360
|
PLANNING PHASE:
|
|
341
|
-
1. aide state set ralph:phase planning
|
|
361
|
+
1. ./.aide/bin/aide state set ralph:phase planning
|
|
342
362
|
2. Search code (don't assume!)
|
|
343
|
-
3. aide memory add findings
|
|
344
|
-
4. aide task create (atomic tasks)
|
|
345
|
-
5. aide decision set (key decisions)
|
|
346
|
-
6. aide state set ralph:phase building
|
|
363
|
+
3. ./.aide/bin/aide memory add findings
|
|
364
|
+
4. ./.aide/bin/aide task create (atomic tasks)
|
|
365
|
+
5. ./.aide/bin/aide decision set (key decisions)
|
|
366
|
+
6. ./.aide/bin/aide state set ralph:phase building
|
|
347
367
|
|
|
348
368
|
BUILDING PHASE (per task):
|
|
349
|
-
1. aide task list (find next)
|
|
350
|
-
2. aide task claim <id>
|
|
369
|
+
1. ./.aide/bin/aide task list (find next)
|
|
370
|
+
2. ./.aide/bin/aide task claim <id>
|
|
351
371
|
3. Re-verify gap exists
|
|
352
372
|
4. Write failing tests
|
|
353
373
|
5. Implement
|
|
354
374
|
6. BACKPRESSURE: Tests MUST pass
|
|
355
|
-
7. aide task complete <id>
|
|
375
|
+
7. ./.aide/bin/aide task complete <id>
|
|
356
376
|
8. Atomic commit
|
|
357
377
|
9. Repeat or verify completion
|
|
358
378
|
```
|
|
@@ -362,10 +382,11 @@ BUILDING PHASE (per task):
|
|
|
362
382
|
## Swarm Compatibility
|
|
363
383
|
|
|
364
384
|
This skill is **swarm-compatible**. Multiple ralph agents can:
|
|
385
|
+
|
|
365
386
|
- Work on different tasks in parallel
|
|
366
|
-
- Share discoveries via
|
|
367
|
-
- Check decisions via
|
|
368
|
-
- Claim tasks atomically via
|
|
387
|
+
- Share discoveries via `./.aide/bin/aide memory`
|
|
388
|
+
- Check decisions via `./.aide/bin/aide decision get`
|
|
389
|
+
- Claim tasks atomically via `./.aide/bin/aide task claim`
|
|
369
390
|
|
|
370
391
|
No file conflicts because all state is in aide's database.
|
|
371
392
|
|
|
@@ -390,8 +411,9 @@ Instead, independently verify the implementation against the original objective.
|
|
|
390
411
|
The QA agent must:
|
|
391
412
|
|
|
392
413
|
#### a) Load the Objective (not the task list)
|
|
414
|
+
|
|
393
415
|
```bash
|
|
394
|
-
aide state get ralph:objective
|
|
416
|
+
./.aide/bin/aide state get ralph:objective
|
|
395
417
|
```
|
|
396
418
|
|
|
397
419
|
#### b) Independent Verification
|
|
@@ -411,39 +433,42 @@ aide state get ralph:objective
|
|
|
411
433
|
#### c) Find & Fix Gaps
|
|
412
434
|
|
|
413
435
|
If gaps are found:
|
|
436
|
+
|
|
414
437
|
```bash
|
|
415
438
|
# Record the gap
|
|
416
|
-
aide memory add --category=discovery --tags=ralph,qa "QA found gap: <description>"
|
|
439
|
+
./.aide/bin/aide memory add --category=discovery --tags=ralph,qa "QA found gap: <description>"
|
|
417
440
|
|
|
418
441
|
# Create fix task
|
|
419
|
-
aide task create "QA fix: <description>" --tags=ralph,qa-fix
|
|
442
|
+
./.aide/bin/aide task create "QA fix: <description>" --tags=ralph,qa-fix
|
|
420
443
|
|
|
421
444
|
# Implement the fix (follow standard backpressure rules)
|
|
422
445
|
# ...
|
|
423
446
|
|
|
424
447
|
# Mark complete
|
|
425
|
-
aide task complete <id>
|
|
448
|
+
./.aide/bin/aide task complete <id>
|
|
426
449
|
```
|
|
427
450
|
|
|
428
451
|
#### d) Final Sign-off
|
|
429
452
|
|
|
430
453
|
Only when QA agent confirms:
|
|
454
|
+
|
|
431
455
|
- All tests passing
|
|
432
456
|
- Build clean
|
|
433
457
|
- Lint clean
|
|
434
458
|
- Objective fully met (not just tasks)
|
|
435
459
|
|
|
436
460
|
```bash
|
|
437
|
-
aide state set ralph:qa "passed"
|
|
438
|
-
aide state set ralph:phase complete
|
|
461
|
+
./.aide/bin/aide state set ralph:qa "passed"
|
|
462
|
+
./.aide/bin/aide state set ralph:phase complete
|
|
439
463
|
```
|
|
440
464
|
|
|
441
465
|
### Step 3: QA Failure Handling
|
|
442
466
|
|
|
443
467
|
If QA finds unfixable issues:
|
|
468
|
+
|
|
444
469
|
```bash
|
|
445
|
-
aide state set ralph:qa "failed"
|
|
446
|
-
aide memory add --category=blocker --tags=ralph,qa "QA failed: <reason>"
|
|
470
|
+
./.aide/bin/aide state set ralph:qa "failed"
|
|
471
|
+
./.aide/bin/aide memory add --category=blocker --tags=ralph,qa "QA failed: <reason>"
|
|
447
472
|
```
|
|
448
473
|
|
|
449
474
|
Report to user with specific failures. **DO NOT** mark complete.
|
package/skills/swarm/SKILL.md
CHANGED
|
@@ -87,6 +87,7 @@ If no plan exists, break the work into independent stories/features:
|
|
|
87
87
|
```
|
|
88
88
|
|
|
89
89
|
Each story should be:
|
|
90
|
+
|
|
90
91
|
- Independent (can be developed in parallel)
|
|
91
92
|
- Complete (has clear boundaries)
|
|
92
93
|
- Testable (has acceptance criteria)
|
|
@@ -102,17 +103,20 @@ git worktree add .aide/worktrees/story-dashboard -b feat/story-dashboard
|
|
|
102
103
|
```
|
|
103
104
|
|
|
104
105
|
**Automatic Integration:**
|
|
106
|
+
|
|
105
107
|
- Worktrees in `.aide/worktrees/` are **auto-discovered** by AIDE hooks
|
|
106
108
|
- When agents spawn, their worktree path is **auto-injected** into context
|
|
107
109
|
- When agents complete, worktrees are marked as **"agent-complete"** (ready for merge)
|
|
108
110
|
- Worktree state is tracked in `.aide/state/worktrees.json`
|
|
109
111
|
|
|
110
112
|
**Naming Convention:**
|
|
113
|
+
|
|
111
114
|
- Use `story-<name>` as worktree directory name
|
|
112
115
|
- Use matching `agent-<name>` as agent_id when spawning
|
|
113
116
|
- Example: `story-auth` worktree → spawn with `agent_id` containing "auth"
|
|
114
117
|
|
|
115
118
|
**If worktree creation fails:**
|
|
119
|
+
|
|
116
120
|
1. Check if branch exists: `git branch -a | grep feat/story-auth`
|
|
117
121
|
2. Remove stale worktree: `git worktree remove .aide/worktrees/story-auth --force`
|
|
118
122
|
3. Prune refs: `git worktree prune`
|
|
@@ -123,6 +127,7 @@ git worktree add .aide/worktrees/story-dashboard -b feat/story-dashboard
|
|
|
123
127
|
Launch agents using the Task tool with `subagent_type: "general-purpose"` (required for Edit/Write access).
|
|
124
128
|
|
|
125
129
|
**IMPORTANT: Task Ownership**
|
|
130
|
+
|
|
126
131
|
- The ORCHESTRATOR does NOT create SDLC tasks
|
|
127
132
|
- Each SUBAGENT creates and manages its OWN tasks
|
|
128
133
|
- Orchestrator only monitors via `TaskList`
|
|
@@ -201,8 +206,10 @@ Use native Claude Code task tools to track your progress:
|
|
|
201
206
|
|
|
202
207
|
**Shared state (MCP + CLI):**
|
|
203
208
|
- Check decisions: \`mcp__plugin_aide_aide__decision_get\` (MCP read)
|
|
204
|
-
- Record decisions:
|
|
205
|
-
- Share discoveries:
|
|
209
|
+
- Record decisions: \`./.aide/bin/aide decision set <topic> "<decision>"\` (CLI write)
|
|
210
|
+
- Share discoveries: \`./.aide/bin/aide memory add --category=discovery "<finding>"\` (CLI write)
|
|
211
|
+
|
|
212
|
+
**Binary location:** The aide binary is at \`.aide/bin/aide\`. If it's on your \`$PATH\`, you can use \`aide\` directly.
|
|
206
213
|
|
|
207
214
|
## Completion
|
|
208
215
|
When all 5 stages are complete:
|
|
@@ -223,6 +230,7 @@ TaskList
|
|
|
223
230
|
```
|
|
224
231
|
|
|
225
232
|
Example output:
|
|
233
|
+
|
|
226
234
|
```
|
|
227
235
|
#10 [completed] [story-auth][DESIGN] Design auth module (agent-auth)
|
|
228
236
|
#11 [completed] [story-auth][TEST] Write auth tests (agent-auth)
|
|
@@ -249,13 +257,13 @@ mcp__plugin_aide_aide__memory_list with category=blocker
|
|
|
249
257
|
|
|
250
258
|
## SDLC Stage Reference
|
|
251
259
|
|
|
252
|
-
| Stage
|
|
253
|
-
|
|
254
|
-
| DESIGN | `/aide:design`
|
|
255
|
-
| TEST
|
|
256
|
-
| DEV
|
|
257
|
-
| VERIFY | `/aide:verify`
|
|
258
|
-
| DOCS
|
|
260
|
+
| Stage | Skill | Creates | Depends On |
|
|
261
|
+
| ------ | ----------------- | ------------------------------------------ | ---------- |
|
|
262
|
+
| DESIGN | `/aide:design` | Interfaces, decisions, acceptance criteria | - |
|
|
263
|
+
| TEST | `/aide:test` | Failing tests | DESIGN |
|
|
264
|
+
| DEV | `/aide:implement` | Passing implementation | TEST |
|
|
265
|
+
| VERIFY | `/aide:verify` | Quality validation | DEV |
|
|
266
|
+
| DOCS | `/aide:docs` | Updated documentation | VERIFY |
|
|
259
267
|
|
|
260
268
|
### VERIFY → BUILD-FIX Loop
|
|
261
269
|
|
|
@@ -277,6 +285,7 @@ mcp__plugin_aide_aide__memory_list with category=blocker
|
|
|
277
285
|
```
|
|
278
286
|
|
|
279
287
|
If VERIFY fails:
|
|
288
|
+
|
|
280
289
|
1. `/aide:build-fix` to fix issues
|
|
281
290
|
2. Re-run `/aide:verify`
|
|
282
291
|
3. Repeat until passing
|
|
@@ -290,11 +299,13 @@ When spawning story agents, include:
|
|
|
290
299
|
You are story agent [AGENT-ID] working in worktree [PATH].
|
|
291
300
|
|
|
292
301
|
## Story
|
|
302
|
+
|
|
293
303
|
[Story name and description]
|
|
294
304
|
|
|
295
305
|
## SDLC Pipeline
|
|
296
306
|
|
|
297
307
|
Execute these stages in order. For each stage:
|
|
308
|
+
|
|
298
309
|
1. Create task with TaskCreate (set blockedBy for dependencies)
|
|
299
310
|
2. Claim task with TaskUpdate (owner=your-id, status=in_progress)
|
|
300
311
|
3. Execute stage using appropriate skill
|
|
@@ -303,60 +314,64 @@ Execute these stages in order. For each stage:
|
|
|
303
314
|
### Stage Tasks to Create
|
|
304
315
|
|
|
305
316
|
TaskCreate({
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
317
|
+
subject: "[STORY-ID][DESIGN] Design [feature]",
|
|
318
|
+
description: "Technical design with interfaces and acceptance criteria",
|
|
319
|
+
activeForm: "Designing [feature]"
|
|
309
320
|
})
|
|
310
321
|
|
|
311
322
|
TaskCreate({
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
323
|
+
subject: "[STORY-ID][TEST] Write tests for [feature]",
|
|
324
|
+
description: "Failing tests based on acceptance criteria",
|
|
325
|
+
activeForm: "Writing tests"
|
|
315
326
|
})
|
|
316
327
|
// ... set blockedBy to DESIGN task ID
|
|
317
328
|
|
|
318
329
|
TaskCreate({
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
330
|
+
subject: "[STORY-ID][DEV] Implement [feature]",
|
|
331
|
+
description: "Make tests pass with minimal code",
|
|
332
|
+
activeForm: "Implementing [feature]"
|
|
322
333
|
})
|
|
323
334
|
// ... set blockedBy to TEST task ID
|
|
324
335
|
|
|
325
336
|
TaskCreate({
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
337
|
+
subject: "[STORY-ID][VERIFY] Verify [feature]",
|
|
338
|
+
description: "Full test suite, lint, type check",
|
|
339
|
+
activeForm: "Verifying [feature]"
|
|
329
340
|
})
|
|
330
341
|
// ... set blockedBy to DEV task ID
|
|
331
342
|
|
|
332
343
|
TaskCreate({
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
344
|
+
subject: "[STORY-ID][DOCS] Document [feature]",
|
|
345
|
+
description: "Update documentation",
|
|
346
|
+
activeForm: "Documenting [feature]"
|
|
336
347
|
})
|
|
337
348
|
// ... set blockedBy to VERIFY task ID
|
|
338
349
|
|
|
339
350
|
## Coordination
|
|
340
351
|
|
|
341
352
|
**Messaging (MCP tools):**
|
|
353
|
+
|
|
342
354
|
- Send status: `message_send` with from=[AGENT-ID], type="status", content="[STAGE] complete"
|
|
343
355
|
- Send blocker: `message_send` with from=[AGENT-ID], type="blocker", content="description"
|
|
344
356
|
- Check inbox: `message_list` with agent_id=[AGENT-ID]
|
|
345
357
|
- Acknowledge: `message_ack` with message_id=N, agent_id=[AGENT-ID]
|
|
346
358
|
|
|
347
359
|
**At each stage transition:**
|
|
360
|
+
|
|
348
361
|
1. Check messages via `message_list`
|
|
349
362
|
2. Acknowledge and act on any requests
|
|
350
363
|
3. Send `status` message with new stage name
|
|
351
364
|
|
|
352
365
|
**Shared state:**
|
|
366
|
+
|
|
353
367
|
- Check existing decisions: `mcp__plugin_aide_aide__decision_get` (MCP read)
|
|
354
|
-
- Record new decisions:
|
|
355
|
-
- Share discoveries:
|
|
368
|
+
- Record new decisions: `./.aide/bin/aide decision set <topic> "<decision>"` (CLI write)
|
|
369
|
+
- Share discoveries: `./.aide/bin/aide memory add --category=discovery "<finding>"` (CLI write)
|
|
356
370
|
|
|
357
371
|
## VERIFY Failure Handling
|
|
358
372
|
|
|
359
373
|
If VERIFY stage fails:
|
|
374
|
+
|
|
360
375
|
1. DO NOT proceed to DOCS
|
|
361
376
|
2. Invoke /aide:build-fix to address failures
|
|
362
377
|
3. Re-run /aide:verify
|
|
@@ -366,6 +381,7 @@ If VERIFY stage fails:
|
|
|
366
381
|
## Completion
|
|
367
382
|
|
|
368
383
|
All stages must complete. When done:
|
|
384
|
+
|
|
369
385
|
1. All 5 tasks show [completed]
|
|
370
386
|
2. VERIFY must have passed (not skipped)
|
|
371
387
|
3. All changes committed to your worktree branch
|
|
@@ -386,6 +402,7 @@ This uses the original task-grabbing model without SDLC stages.
|
|
|
386
402
|
## Coordination via aide
|
|
387
403
|
|
|
388
404
|
**Messages** (MCP tools — primary coordination mechanism):
|
|
405
|
+
|
|
389
406
|
```
|
|
390
407
|
# Send status update (broadcast)
|
|
391
408
|
message_send: from="agent-auth", type="status", content="[DESIGN] complete, starting TEST"
|
|
@@ -401,16 +418,24 @@ message_ack: message_id=42, agent_id="agent-auth"
|
|
|
401
418
|
```
|
|
402
419
|
|
|
403
420
|
**Decisions** (shared across agents):
|
|
421
|
+
|
|
404
422
|
```bash
|
|
405
423
|
# Write (CLI)
|
|
406
|
-
aide decision set "auth-strategy" "JWT with refresh tokens"
|
|
424
|
+
./.aide/bin/aide decision set "auth-strategy" "JWT with refresh tokens"
|
|
407
425
|
|
|
408
426
|
# Read (MCP) - use mcp__plugin_aide_aide__decision_get with topic="auth-strategy"
|
|
409
427
|
```
|
|
410
428
|
|
|
411
429
|
**Memory** (shared discoveries):
|
|
430
|
+
|
|
431
|
+
```bash
|
|
432
|
+
./.aide/bin/aide memory add --category=discovery "User model needs email validation"
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
**Memory** (shared discoveries):
|
|
436
|
+
|
|
412
437
|
```bash
|
|
413
|
-
aide memory add --category=discovery "User model needs email validation"
|
|
438
|
+
./.aide/bin/aide memory add --category=discovery "User model needs email validation"
|
|
414
439
|
```
|
|
415
440
|
|
|
416
441
|
## OpenCode Mode
|
|
@@ -418,11 +443,13 @@ aide memory add --category=discovery "User model needs email validation"
|
|
|
418
443
|
OpenCode does not have native subagent support. For multi-agent swarms with OpenCode:
|
|
419
444
|
|
|
420
445
|
**Setup:**
|
|
446
|
+
|
|
421
447
|
1. Create worktrees as normal (one per story)
|
|
422
448
|
2. Launch separate OpenCode terminal sessions, one per story
|
|
423
449
|
3. Each session works in its assigned worktree directory
|
|
424
450
|
|
|
425
451
|
**Coordination:**
|
|
452
|
+
|
|
426
453
|
- **No TaskList** — OpenCode sessions don't share a task system
|
|
427
454
|
- **Use aide messages** as the primary coordination mechanism:
|
|
428
455
|
- Each session uses `message_send` to report status, blockers, and completion
|
|
@@ -430,12 +457,13 @@ OpenCode does not have native subagent support. For multi-agent swarms with Open
|
|
|
430
457
|
- The orchestrator monitors all agents via `message_list` with their own agent_id
|
|
431
458
|
- **Use aide state** for progress tracking:
|
|
432
459
|
```bash
|
|
433
|
-
aide state set "agent-auth:stage" "TEST"
|
|
434
|
-
aide state set "agent-auth:status" "running"
|
|
460
|
+
./.aide/bin/aide state set "agent-auth:stage" "TEST"
|
|
461
|
+
./.aide/bin/aide state set "agent-auth:status" "running"
|
|
435
462
|
```
|
|
436
463
|
- Monitor all agents: `mcp__plugin_aide_aide__state_list`
|
|
437
464
|
|
|
438
465
|
**Orchestrator role (human or primary session):**
|
|
466
|
+
|
|
439
467
|
1. Decompose stories (use `/aide:plan-swarm` first)
|
|
440
468
|
2. Create worktrees
|
|
441
469
|
3. Launch terminal sessions with instructions
|
|
@@ -447,35 +475,47 @@ OpenCode does not have native subagent support. For multi-agent swarms with Open
|
|
|
447
475
|
Swarm completion checklist - ALL REQUIRED:
|
|
448
476
|
|
|
449
477
|
### Step 1: Verify All Stories Complete
|
|
478
|
+
|
|
450
479
|
```
|
|
451
480
|
TaskList # All story tasks must show [completed]
|
|
452
481
|
```
|
|
482
|
+
|
|
453
483
|
- Every story must have completed all 5 SDLC stages
|
|
454
484
|
- No tasks should be [pending] or [in_progress]
|
|
455
485
|
|
|
456
486
|
### Step 2: Check for Blockers
|
|
487
|
+
|
|
457
488
|
Use `mcp__plugin_aide_aide__memory_list` with category=blocker
|
|
489
|
+
|
|
458
490
|
- If blockers exist, resolve them before proceeding
|
|
459
491
|
- Use `/aide:build-fix` for any remaining build/test issues
|
|
460
492
|
|
|
461
493
|
### Step 3: Final Verification
|
|
494
|
+
|
|
462
495
|
Run verification on each worktree:
|
|
496
|
+
|
|
463
497
|
```bash
|
|
464
498
|
cd .aide/worktrees/story-X && npm test && npm run build
|
|
465
499
|
```
|
|
500
|
+
|
|
466
501
|
- If any fail, invoke `/aide:build-fix` and re-verify
|
|
467
502
|
|
|
468
503
|
### Step 4: Merge Worktrees (MANDATORY)
|
|
504
|
+
|
|
469
505
|
**YOU MUST invoke `/aide:worktree-resolve`** - this is not optional.
|
|
506
|
+
|
|
470
507
|
```
|
|
471
508
|
/aide:worktree-resolve
|
|
472
509
|
```
|
|
510
|
+
|
|
473
511
|
This skill will:
|
|
512
|
+
|
|
474
513
|
- Merge each story branch into main
|
|
475
514
|
- Handle any merge conflicts
|
|
476
515
|
- Clean up worktrees
|
|
477
516
|
|
|
478
517
|
### Step 5: Record Session
|
|
518
|
+
|
|
479
519
|
Only after successful merge, record the swarm session (see Orchestrator Memory below).
|
|
480
520
|
|
|
481
521
|
## Orchestrator Memory
|
|
@@ -483,7 +523,7 @@ Only after successful merge, record the swarm session (see Orchestrator Memory b
|
|
|
483
523
|
After swarm completes, record the session using the CLI:
|
|
484
524
|
|
|
485
525
|
```bash
|
|
486
|
-
aide memory add --category=session --tags=swarm,sdlc,session:${CLAUDE_SESSION_ID:0:8} "## Swarm: [Brief Description]
|
|
526
|
+
./.aide/bin/aide memory add --category=session --tags=swarm,sdlc,session:${CLAUDE_SESSION_ID:0:8} "## Swarm: [Brief Description]
|
|
487
527
|
|
|
488
528
|
### Stories Completed
|
|
489
529
|
- Story A: [outcome]
|