opencodekit 0.11.0 → 0.12.0
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/dist/index.js +1 -1
- package/dist/template/.opencode/AGENTS.md +2 -2
- package/dist/template/.opencode/agent/build.md +20 -20
- package/dist/template/.opencode/agent/explore.md +13 -13
- package/dist/template/.opencode/agent/planner.md +20 -20
- package/dist/template/.opencode/agent/review.md +18 -18
- package/dist/template/.opencode/agent/rush.md +20 -20
- package/dist/template/.opencode/agent/scout.md +16 -16
- package/dist/template/.opencode/agent/vision.md +19 -19
- package/dist/template/.opencode/command/accessibility-check.md +6 -2
- package/dist/template/.opencode/command/analyze-mockup.md +6 -0
- package/dist/template/.opencode/command/analyze-project.md +6 -0
- package/dist/template/.opencode/command/brainstorm.md +6 -0
- package/dist/template/.opencode/command/commit.md +6 -1
- package/dist/template/.opencode/command/create.md +369 -134
- package/dist/template/.opencode/command/design-audit.md +6 -0
- package/dist/template/.opencode/command/design.md +6 -0
- package/dist/template/.opencode/command/finish.md +1 -0
- package/dist/template/.opencode/command/fix-ci.md +1 -0
- package/dist/template/.opencode/command/fix-types.md +6 -0
- package/dist/template/.opencode/command/fix-ui.md +6 -0
- package/dist/template/.opencode/command/fix.md +6 -0
- package/dist/template/.opencode/command/handoff.md +6 -1
- package/dist/template/.opencode/command/implement.md +1 -0
- package/dist/template/.opencode/command/import-plan.md +7 -2
- package/dist/template/.opencode/command/integration-test.md +5 -0
- package/dist/template/.opencode/command/issue.md +11 -2
- package/dist/template/.opencode/command/new-feature.md +8 -0
- package/dist/template/.opencode/command/plan.md +282 -21
- package/dist/template/.opencode/command/pr.md +6 -1
- package/dist/template/.opencode/command/research-and-implement.md +6 -0
- package/dist/template/.opencode/command/research.md +6 -0
- package/dist/template/.opencode/command/resume.md +8 -0
- package/dist/template/.opencode/command/revert-feature.md +7 -2
- package/dist/template/.opencode/command/review-codebase.md +6 -0
- package/dist/template/.opencode/command/status.md +6 -0
- package/dist/template/.opencode/command/triage.md +17 -12
- package/dist/template/.opencode/command/ui-review.md +4 -0
- package/dist/template/.opencode/opencode.json +479 -514
- package/dist/template/.opencode/package.json +1 -1
- package/dist/template/.opencode/plugin/beads.ts +857 -270
- package/dist/template/.opencode/skill/beads/SKILL.md +110 -17
- package/dist/template/.opencode/skill/beads/references/DEPENDENCIES.md +3 -3
- package/dist/template/.opencode/skill/beads/references/WORKFLOWS.md +1 -1
- package/package.json +1 -1
|
@@ -1,19 +1,26 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Create
|
|
2
|
+
description: Create bead(s) with automatic complexity analysis and decomposition
|
|
3
3
|
argument-hint: "[optional title]"
|
|
4
4
|
agent: build
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# Create Task
|
|
8
8
|
|
|
9
|
+
## Load Beads Skill
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
skill({ name: "beads" });
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
This skill provides the full beads workflow including Epic → Task → Subtask hierarchy.
|
|
16
|
+
|
|
9
17
|
## Phase 1: Check for Similar Work
|
|
10
18
|
|
|
11
19
|
Before creating, search for existing or past work:
|
|
12
20
|
|
|
13
21
|
```typescript
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
bd_ls({ status: "all", limit: 20 });
|
|
22
|
+
memory_search({ query: "[keywords from title/problem]", type: "observations" });
|
|
23
|
+
bd_ls({ status: "all", limit: 20, offset: 0 });
|
|
17
24
|
```
|
|
18
25
|
|
|
19
26
|
If similar task exists:
|
|
@@ -36,52 +43,94 @@ If similar task exists:
|
|
|
36
43
|
|
|
37
44
|
Keep it brief. Get: clear goal, success criteria, scope, constraints.
|
|
38
45
|
|
|
39
|
-
## Phase 3:
|
|
46
|
+
## Phase 3: Complexity Analysis
|
|
40
47
|
|
|
41
|
-
|
|
48
|
+
Analyze the request to determine if it should be a single bead or decomposed:
|
|
42
49
|
|
|
43
|
-
###
|
|
50
|
+
### Complexity Signals
|
|
44
51
|
|
|
45
|
-
|
|
46
|
-
|
|
52
|
+
```
|
|
53
|
+
SIMPLE (Single Bead) COMPLEX (Needs Decomposition)
|
|
54
|
+
━━━━━━━━━━━━━━━━━━━━ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
55
|
+
• Single file change • Multiple unrelated files
|
|
56
|
+
• One clear action • Multiple distinct actions
|
|
57
|
+
• ~30 min or less • Hours/days of work
|
|
58
|
+
• No phases needed • Has natural phases
|
|
59
|
+
• One skill domain • Crosses domains (FE + BE)
|
|
60
|
+
• Bug fix or small feature • New system or major feature
|
|
61
|
+
```
|
|
47
62
|
|
|
48
|
-
###
|
|
63
|
+
### Automatic Classification
|
|
49
64
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
65
|
+
```typescript
|
|
66
|
+
const analyzeComplexity = (request: string) => {
|
|
67
|
+
const signals = {
|
|
68
|
+
// COMPLEX signals
|
|
69
|
+
multiDomain: /frontend.*backend|api.*ui|database.*interface/i,
|
|
70
|
+
multiPhase: /first.*then|phase|step \d|after.*before/i,
|
|
71
|
+
largeScope: /system|architecture|refactor.*entire|redesign/i,
|
|
72
|
+
multiComponent: /and.*and|multiple|several|all.*components/i,
|
|
73
|
+
integration: /integrate|connect|sync.*between/i,
|
|
74
|
+
|
|
75
|
+
// SIMPLE signals
|
|
76
|
+
singleAction: /fix|update|add|remove|change.*one/i,
|
|
77
|
+
bugFix: /bug|error|broken|not working|crash/i,
|
|
78
|
+
smallScope: /typo|config|env|readme|comment/i,
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
let complexScore = 0;
|
|
82
|
+
if (signals.multiDomain.test(request)) complexScore += 3;
|
|
83
|
+
if (signals.multiPhase.test(request)) complexScore += 2;
|
|
84
|
+
if (signals.largeScope.test(request)) complexScore += 3;
|
|
85
|
+
if (signals.multiComponent.test(request)) complexScore += 2;
|
|
86
|
+
if (signals.integration.test(request)) complexScore += 2;
|
|
87
|
+
|
|
88
|
+
let simpleScore = 0;
|
|
89
|
+
if (signals.singleAction.test(request)) simpleScore += 2;
|
|
90
|
+
if (signals.bugFix.test(request)) simpleScore += 1;
|
|
91
|
+
if (signals.smallScope.test(request)) simpleScore += 3;
|
|
92
|
+
|
|
93
|
+
return complexScore > simpleScore + 2 ? "COMPLEX" : "SIMPLE";
|
|
94
|
+
};
|
|
95
|
+
```
|
|
56
96
|
|
|
57
|
-
|
|
97
|
+
### Decision Point
|
|
58
98
|
|
|
59
|
-
|
|
99
|
+
```
|
|
100
|
+
COMPLEXITY ANALYSIS
|
|
101
|
+
━━━━━━━━━━━━━━━━━━━
|
|
60
102
|
|
|
61
|
-
|
|
103
|
+
Request: "[user's request]"
|
|
62
104
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
ttl: 600,
|
|
68
|
-
});
|
|
69
|
-
```
|
|
105
|
+
Signals detected:
|
|
106
|
+
✓ Multiple domains (frontend + backend)
|
|
107
|
+
✓ Multi-phase work (setup → implement → test)
|
|
108
|
+
✓ Integration required
|
|
70
109
|
|
|
71
|
-
|
|
110
|
+
Classification: COMPLEX
|
|
72
111
|
|
|
73
|
-
|
|
74
|
-
Creating:
|
|
75
|
-
Title: [title]
|
|
76
|
-
Type: [type]
|
|
77
|
-
Priority: [0-4]
|
|
78
|
-
Estimate: [S/M/L/XL] (~[N] tool calls)
|
|
79
|
-
Role: [fe/be/mobile/devops/qa] (optional)
|
|
112
|
+
Recommendation: Create Epic with 3-4 subtasks
|
|
80
113
|
|
|
81
|
-
|
|
114
|
+
Options:
|
|
115
|
+
1. [Recommended] Create Epic + decompose into subtasks
|
|
116
|
+
2. Create single bead (override complexity detection)
|
|
117
|
+
3. Let me clarify scope first
|
|
118
|
+
|
|
119
|
+
Choose (1/2/3): _
|
|
82
120
|
```
|
|
83
121
|
|
|
84
|
-
|
|
122
|
+
**STOP and wait for user confirmation.**
|
|
123
|
+
|
|
124
|
+
## Phase 4A: Simple Path (Single Bead)
|
|
125
|
+
|
|
126
|
+
If SIMPLE or user overrides:
|
|
127
|
+
|
|
128
|
+
### Type & Priority
|
|
129
|
+
|
|
130
|
+
- **Type**: bug | feature | task | chore
|
|
131
|
+
- **Priority**: 0 (critical) to 4 (low), default 2
|
|
132
|
+
|
|
133
|
+
### Create Single Bead
|
|
85
134
|
|
|
86
135
|
```typescript
|
|
87
136
|
bd_add({
|
|
@@ -89,69 +138,196 @@ bd_add({
|
|
|
89
138
|
type: "[type]",
|
|
90
139
|
pri: [priority],
|
|
91
140
|
desc: "[description]",
|
|
92
|
-
tags: ["[role]", "[estimate]"],
|
|
141
|
+
tags: ["[role]", "[estimate]"],
|
|
93
142
|
});
|
|
94
143
|
```
|
|
95
144
|
|
|
96
|
-
###
|
|
145
|
+
### Create Spec
|
|
146
|
+
|
|
147
|
+
Write `.beads/artifacts/<bead-id>/spec.md` (see Standard Spec template below).
|
|
148
|
+
|
|
149
|
+
**Continue to Phase 6.**
|
|
150
|
+
|
|
151
|
+
## Phase 4B: Complex Path (Epic + Subtasks)
|
|
152
|
+
|
|
153
|
+
If COMPLEX and user confirms decomposition:
|
|
154
|
+
|
|
155
|
+
### Step 1: Identify Natural Breakdown
|
|
156
|
+
|
|
157
|
+
```
|
|
158
|
+
DECOMPOSITION ANALYSIS
|
|
159
|
+
━━━━━━━━━━━━━━━━━━━━━━
|
|
160
|
+
|
|
161
|
+
Request: "Add user authentication with OAuth"
|
|
162
|
+
|
|
163
|
+
Natural breakdown:
|
|
164
|
+
|
|
165
|
+
1. Database & Schema [Backend]
|
|
166
|
+
- User table, sessions table
|
|
167
|
+
- Can start immediately
|
|
168
|
+
|
|
169
|
+
2. OAuth Provider Integration [Backend]
|
|
170
|
+
- Google, GitHub providers
|
|
171
|
+
- Depends on: #1
|
|
97
172
|
|
|
98
|
-
|
|
173
|
+
3. Auth API Endpoints [Backend]
|
|
174
|
+
- Login, logout, refresh
|
|
175
|
+
- Depends on: #1, #2
|
|
176
|
+
|
|
177
|
+
4. Frontend Auth Flow [Frontend]
|
|
178
|
+
- Login page, protected routes
|
|
179
|
+
- Depends on: #3
|
|
180
|
+
|
|
181
|
+
5. Testing & Documentation [QA]
|
|
182
|
+
- E2E tests, API docs
|
|
183
|
+
- Depends on: #3, #4
|
|
184
|
+
|
|
185
|
+
Parallel execution possible:
|
|
186
|
+
- Track A: #1 → #2 → #3
|
|
187
|
+
- Track B: #4 (can start after #3 ready)
|
|
188
|
+
- Track C: #5 (final)
|
|
189
|
+
|
|
190
|
+
Create this structure? (yes/modify)
|
|
191
|
+
```
|
|
192
|
+
|
|
193
|
+
**STOP and wait for user confirmation.**
|
|
194
|
+
|
|
195
|
+
### Step 2: Create Epic
|
|
99
196
|
|
|
100
197
|
```typescript
|
|
101
|
-
bd_add({
|
|
102
|
-
title: "[
|
|
103
|
-
type: "
|
|
198
|
+
const epic = bd_add({
|
|
199
|
+
title: "[Feature Name]",
|
|
200
|
+
type: "epic",
|
|
104
201
|
pri: [priority],
|
|
105
|
-
|
|
202
|
+
desc: "[Overview of the feature]",
|
|
203
|
+
tags: ["epic", "[domain]"],
|
|
106
204
|
});
|
|
205
|
+
// Returns: { id: "bd-a3f8" }
|
|
107
206
|
```
|
|
108
207
|
|
|
109
|
-
###
|
|
208
|
+
### Step 3: Create Child Tasks with Dependencies
|
|
110
209
|
|
|
111
210
|
```typescript
|
|
112
|
-
|
|
211
|
+
// Task 1: No dependencies (can start immediately)
|
|
212
|
+
const task1 = bd_add({
|
|
213
|
+
title: "Database schema for auth",
|
|
214
|
+
type: "task",
|
|
215
|
+
pri: 2,
|
|
216
|
+
parent: "bd-a3f8", // Links to epic
|
|
217
|
+
desc: "Create user and session tables",
|
|
218
|
+
tags: ["backend", "database", "S"],
|
|
219
|
+
});
|
|
220
|
+
// Returns: { id: "bd-a3f8.1" }
|
|
221
|
+
|
|
222
|
+
// Task 2: Depends on Task 1
|
|
223
|
+
const task2 = bd_add({
|
|
224
|
+
title: "OAuth provider integration",
|
|
225
|
+
type: "task",
|
|
226
|
+
pri: 2,
|
|
227
|
+
parent: "bd-a3f8",
|
|
228
|
+
deps: ["bd-a3f8.1"], // Blocked by task 1
|
|
229
|
+
desc: "Integrate Google and GitHub OAuth",
|
|
230
|
+
tags: ["backend", "M"],
|
|
231
|
+
});
|
|
232
|
+
// Returns: { id: "bd-a3f8.2" }
|
|
233
|
+
|
|
234
|
+
// Task 3: Depends on Tasks 1 and 2
|
|
235
|
+
const task3 = bd_add({
|
|
236
|
+
title: "Auth API endpoints",
|
|
237
|
+
type: "task",
|
|
238
|
+
pri: 2,
|
|
239
|
+
parent: "bd-a3f8",
|
|
240
|
+
deps: ["bd-a3f8.1", "bd-a3f8.2"],
|
|
241
|
+
desc: "Login, logout, refresh endpoints",
|
|
242
|
+
tags: ["backend", "api", "M"],
|
|
243
|
+
});
|
|
244
|
+
// Returns: { id: "bd-a3f8.3" }
|
|
245
|
+
|
|
246
|
+
// Task 4: Depends on Task 3 (different domain - can be parallel agent)
|
|
247
|
+
const task4 = bd_add({
|
|
248
|
+
title: "Frontend auth flow",
|
|
249
|
+
type: "task",
|
|
250
|
+
pri: 2,
|
|
251
|
+
parent: "bd-a3f8",
|
|
252
|
+
deps: ["bd-a3f8.3"],
|
|
253
|
+
desc: "Login page, protected routes, auth context",
|
|
254
|
+
tags: ["frontend", "M"],
|
|
255
|
+
});
|
|
256
|
+
// Returns: { id: "bd-a3f8.4" }
|
|
257
|
+
|
|
258
|
+
// Task 5: Final task
|
|
259
|
+
const task5 = bd_add({
|
|
260
|
+
title: "Auth testing and docs",
|
|
261
|
+
type: "task",
|
|
262
|
+
pri: 3,
|
|
263
|
+
parent: "bd-a3f8",
|
|
264
|
+
deps: ["bd-a3f8.3", "bd-a3f8.4"],
|
|
265
|
+
desc: "E2E tests and API documentation",
|
|
266
|
+
tags: ["qa", "docs", "S"],
|
|
267
|
+
});
|
|
268
|
+
// Returns: { id: "bd-a3f8.5" }
|
|
113
269
|
```
|
|
114
270
|
|
|
115
|
-
|
|
271
|
+
### Step 4: Visualize Dependency Graph
|
|
116
272
|
|
|
117
|
-
```
|
|
118
|
-
|
|
273
|
+
```
|
|
274
|
+
DEPENDENCY GRAPH: bd-a3f8 "User Authentication"
|
|
275
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
276
|
+
|
|
277
|
+
bd-a3f8.1 [Database] ────┬────► bd-a3f8.2 [OAuth] ────┐
|
|
278
|
+
(ready) │ │ │
|
|
279
|
+
│ ▼ │
|
|
280
|
+
└────► bd-a3f8.3 [API] ◄─────┘
|
|
281
|
+
│
|
|
282
|
+
┌────────────────┼────────────────┐
|
|
283
|
+
▼ ▼
|
|
284
|
+
bd-a3f8.4 [Frontend] bd-a3f8.5 [Testing]
|
|
285
|
+
│ ▲
|
|
286
|
+
└─────────────────────────────────┘
|
|
287
|
+
|
|
288
|
+
READY NOW: bd-a3f8.1 (no blockers)
|
|
289
|
+
BLOCKED: bd-a3f8.2, bd-a3f8.3, bd-a3f8.4, bd-a3f8.5
|
|
119
290
|
```
|
|
120
291
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
Write `.beads/artifacts/<bead-id>/spec.md`:
|
|
292
|
+
## Phase 5: Create Spec for Epic
|
|
124
293
|
|
|
125
|
-
|
|
294
|
+
Write `.beads/artifacts/<epic-id>/spec.md`:
|
|
126
295
|
|
|
127
296
|
```markdown
|
|
128
|
-
# [
|
|
297
|
+
# [Feature Name]
|
|
129
298
|
|
|
130
|
-
**
|
|
299
|
+
**Epic:** <epic-id>
|
|
131
300
|
**Created:** [date]
|
|
132
|
-
**Status:**
|
|
133
|
-
**
|
|
301
|
+
**Status:** In Progress
|
|
302
|
+
**Complexity:** XL (decomposed into [N] subtasks)
|
|
134
303
|
|
|
135
304
|
## Goal
|
|
136
305
|
|
|
137
306
|
[1-2 sentences: What exactly are we building and why?]
|
|
138
307
|
|
|
139
|
-
##
|
|
308
|
+
## Subtasks
|
|
140
309
|
|
|
141
|
-
|
|
310
|
+
| ID | Title | Status | Depends On | Assignee |
|
|
311
|
+
| -------- | ----------------- | ------- | ---------- | -------- |
|
|
312
|
+
| <epic>.1 | Database schema | Ready | - | backend |
|
|
313
|
+
| <epic>.2 | OAuth integration | Blocked | .1 | backend |
|
|
314
|
+
| <epic>.3 | API endpoints | Blocked | .1, .2 | backend |
|
|
315
|
+
| <epic>.4 | Frontend flow | Blocked | .3 | frontend |
|
|
316
|
+
| <epic>.5 | Testing & docs | Blocked | .3, .4 | qa |
|
|
142
317
|
|
|
143
|
-
|
|
318
|
+
## Parallel Execution
|
|
144
319
|
|
|
145
|
-
|
|
320
|
+
Agents can work in parallel on:
|
|
146
321
|
|
|
147
|
-
-
|
|
322
|
+
- **After .1 completes:** .2 can start
|
|
323
|
+
- **After .3 completes:** .4 and .5 can start in parallel
|
|
148
324
|
|
|
149
325
|
## Success Criteria
|
|
150
326
|
|
|
151
|
-
- [ ]
|
|
152
|
-
|
|
153
|
-
- [ ] [
|
|
154
|
-
- Verify: `[
|
|
327
|
+
- [ ] All subtasks completed
|
|
328
|
+
- [ ] Integration tests passing
|
|
329
|
+
- [ ] [Specific acceptance criterion]
|
|
330
|
+
- Verify: `[command]`
|
|
155
331
|
|
|
156
332
|
## Constraints
|
|
157
333
|
|
|
@@ -168,111 +344,170 @@ Write `.beads/artifacts/<bead-id>/spec.md`:
|
|
|
168
344
|
[Additional context]
|
|
169
345
|
```
|
|
170
346
|
|
|
171
|
-
|
|
347
|
+
## Phase 6: Spec Quality Check
|
|
172
348
|
|
|
173
|
-
|
|
349
|
+
Before presenting, verify:
|
|
174
350
|
|
|
175
|
-
|
|
176
|
-
|
|
351
|
+
- [ ] **Testable criteria?** Each success criterion has a verification command
|
|
352
|
+
- [ ] **Constraints explicit?** "Must" and "Never" rules documented
|
|
353
|
+
- [ ] **Dependencies correct?** Graph makes sense, no cycles
|
|
354
|
+
- [ ] **Scope clear?** In/Out boundaries defined
|
|
355
|
+
- [ ] **Parallel paths identified?** Agents can work concurrently
|
|
356
|
+
|
|
357
|
+
## Phase 7: Review and Confirm
|
|
177
358
|
|
|
178
|
-
|
|
179
|
-
2. [Step 2]
|
|
180
|
-
3. [Step 3]
|
|
359
|
+
Present the structure for approval:
|
|
181
360
|
|
|
182
|
-
|
|
361
|
+
```
|
|
362
|
+
CREATED: [Feature Name]
|
|
363
|
+
━━━━━━━━━━━━━━━━━━━━━━━
|
|
364
|
+
|
|
365
|
+
Epic: bd-a3f8 "[Feature Name]"
|
|
366
|
+
|
|
367
|
+
Subtasks:
|
|
368
|
+
├── bd-a3f8.1: Database schema [S] ← READY
|
|
369
|
+
├── bd-a3f8.2: OAuth integration [M] ← blocked by .1
|
|
370
|
+
├── bd-a3f8.3: API endpoints [M] ← blocked by .1, .2
|
|
371
|
+
├── bd-a3f8.4: Frontend flow [M] ← blocked by .3
|
|
372
|
+
└── bd-a3f8.5: Testing & docs [S] ← blocked by .3, .4
|
|
183
373
|
|
|
184
|
-
|
|
185
|
-
|
|
374
|
+
Parallel Tracks:
|
|
375
|
+
• Backend agent: .1 → .2 → .3
|
|
376
|
+
• Frontend agent: .4 (after .3)
|
|
377
|
+
• QA agent: .5 (after .3, .4)
|
|
186
378
|
|
|
187
|
-
|
|
379
|
+
Spec: .beads/artifacts/bd-a3f8/spec.md
|
|
188
380
|
|
|
189
|
-
|
|
190
|
-
|
|
381
|
+
Quality check:
|
|
382
|
+
✓ Testable criteria
|
|
383
|
+
✓ Dependencies valid
|
|
384
|
+
✓ Parallel paths identified
|
|
191
385
|
|
|
192
|
-
|
|
386
|
+
Approve? (yes/modify)
|
|
387
|
+
```
|
|
193
388
|
|
|
194
|
-
|
|
195
|
-
- [Uncertainty to resolve]
|
|
389
|
+
**STOP and wait for human response.**
|
|
196
390
|
|
|
197
|
-
##
|
|
391
|
+
## Phase 8: Sync & Report
|
|
198
392
|
|
|
199
|
-
|
|
393
|
+
```typescript
|
|
394
|
+
bd_sync({ reason: "Created epic $ARGUMENTS with subtasks" });
|
|
200
395
|
```
|
|
201
396
|
|
|
202
|
-
|
|
397
|
+
### Next Steps by Structure
|
|
203
398
|
|
|
204
|
-
|
|
399
|
+
**Single Bead (Simple):**
|
|
205
400
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
- [ ] **Scope clear?** In/Out boundaries defined
|
|
210
|
-
- [ ] **Estimate realistic?** Based on similar past work
|
|
401
|
+
```
|
|
402
|
+
Next: /implement <bead-id>
|
|
403
|
+
```
|
|
211
404
|
|
|
212
|
-
|
|
405
|
+
**Epic with Subtasks (Complex):**
|
|
213
406
|
|
|
214
|
-
|
|
407
|
+
```
|
|
408
|
+
Ready to start: bd-a3f8.1 (first unblocked task)
|
|
215
409
|
|
|
216
|
-
|
|
410
|
+
Next steps:
|
|
411
|
+
├── /implement bd-a3f8.1 (start first task)
|
|
412
|
+
├── bd ready (see all ready work)
|
|
413
|
+
└── bd_blocked() (see blocked tasks)
|
|
217
414
|
|
|
415
|
+
For parallel agents:
|
|
416
|
+
├── Agent 1: /implement bd-a3f8.1
|
|
417
|
+
├── Agent 2: (wait for .1, then .2)
|
|
418
|
+
└── Agent 3: (wait for .3, then .4)
|
|
218
419
|
```
|
|
219
|
-
Spec Preview:
|
|
220
|
-
━━━━━━━━━━━━━
|
|
221
420
|
|
|
222
|
-
|
|
421
|
+
## Templates
|
|
223
422
|
|
|
224
|
-
|
|
225
|
-
Quality check:
|
|
226
|
-
✓ Testable criteria
|
|
227
|
-
✓ Constraints explicit
|
|
228
|
-
✓ Scope clear
|
|
229
|
-
[✓/⚠] Edge cases (if L/XL)
|
|
423
|
+
### Standard Spec (Simple Tasks)
|
|
230
424
|
|
|
231
|
-
|
|
232
|
-
|
|
425
|
+
```markdown
|
|
426
|
+
# [Title]
|
|
233
427
|
|
|
234
|
-
**
|
|
428
|
+
**Bead:** <bead-id>
|
|
429
|
+
**Created:** [date]
|
|
430
|
+
**Status:** To Do
|
|
431
|
+
**Estimate:** [S/M] (~[N] tool calls)
|
|
235
432
|
|
|
236
|
-
|
|
237
|
-
If "yes": Proceed to sync and report.
|
|
433
|
+
## Goal
|
|
238
434
|
|
|
239
|
-
|
|
435
|
+
[1-2 sentences: What exactly are we building and why?]
|
|
240
436
|
|
|
241
|
-
|
|
242
|
-
bd_release({ _: true });
|
|
243
|
-
bd_sync({ reason: "Created task $ARGUMENTS" });
|
|
244
|
-
```
|
|
437
|
+
## Scope
|
|
245
438
|
|
|
246
|
-
|
|
247
|
-
Created: <bead-id>
|
|
248
|
-
━━━━━━━━━━━━━━━━━
|
|
439
|
+
**In-Scope:**
|
|
249
440
|
|
|
250
|
-
|
|
251
|
-
Type: [type]
|
|
252
|
-
Estimate: [S/M/L/XL] (~[N] tool calls)
|
|
441
|
+
- [What we ARE doing]
|
|
253
442
|
|
|
254
|
-
|
|
255
|
-
```
|
|
443
|
+
**Out-of-Scope:**
|
|
256
444
|
|
|
257
|
-
|
|
445
|
+
- [What we are NOT doing]
|
|
258
446
|
|
|
259
|
-
|
|
447
|
+
## Success Criteria
|
|
260
448
|
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
449
|
+
- [ ] [Criterion 1]
|
|
450
|
+
- Verify: `[actual command to test this]`
|
|
451
|
+
- [ ] [Criterion 2]
|
|
452
|
+
- Verify: `[actual command to test this]`
|
|
264
453
|
|
|
265
|
-
|
|
454
|
+
## Constraints
|
|
266
455
|
|
|
267
|
-
|
|
268
|
-
Next: /research <bead-id>
|
|
269
|
-
```
|
|
456
|
+
**Must:**
|
|
270
457
|
|
|
271
|
-
|
|
458
|
+
- [Required constraint]
|
|
459
|
+
|
|
460
|
+
**Never:**
|
|
272
461
|
|
|
462
|
+
- [Anti-pattern or forbidden action]
|
|
463
|
+
|
|
464
|
+
## Notes
|
|
465
|
+
|
|
466
|
+
[Additional context]
|
|
273
467
|
```
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
468
|
+
|
|
469
|
+
## When to Decompose
|
|
470
|
+
|
|
471
|
+
| Scenario | Action |
|
|
472
|
+
| -------------------------- | ------------------------------------ |
|
|
473
|
+
| Bug fix | Single bead |
|
|
474
|
+
| Config change | Single bead |
|
|
475
|
+
| Small feature (1 file) | Single bead |
|
|
476
|
+
| Feature touching 2-3 files | Single bead with phases in plan |
|
|
477
|
+
| Feature crossing FE/BE | Epic + subtasks by domain |
|
|
478
|
+
| New system/service | Epic + subtasks by component |
|
|
479
|
+
| Refactor multiple areas | Epic + subtasks by area |
|
|
480
|
+
| Integration work | Epic + subtasks by integration point |
|
|
481
|
+
|
|
482
|
+
## Anti-Patterns
|
|
483
|
+
|
|
484
|
+
❌ **One Giant Bead**
|
|
485
|
+
Creating a single bead for "Implement entire auth system" - agents lose context, can't parallelize.
|
|
486
|
+
|
|
487
|
+
❌ **Too Many Tiny Beads**
|
|
488
|
+
Creating 20 beads for a simple feature - overhead exceeds value.
|
|
489
|
+
|
|
490
|
+
❌ **No Dependencies**
|
|
491
|
+
Creating subtasks without linking dependencies - agents don't know execution order.
|
|
492
|
+
|
|
493
|
+
❌ **Missing Domain Tags**
|
|
494
|
+
Not tagging with `frontend`/`backend`/`qa` - can't route to specialized agents.
|
|
495
|
+
|
|
496
|
+
## Integration with Parallel Agents
|
|
497
|
+
|
|
498
|
+
When epic is created with proper dependencies:
|
|
499
|
+
|
|
500
|
+
```typescript
|
|
501
|
+
// Agent 1 claims ready work
|
|
502
|
+
bd_init({ team: "project", role: "backend" });
|
|
503
|
+
bd_claim(); // Gets bd-a3f8.1 (first ready task)
|
|
504
|
+
|
|
505
|
+
// Agent 1 completes, Agent 2 can now start
|
|
506
|
+
bd_done({ id: "bd-a3f8.1", msg: "Schema created" });
|
|
507
|
+
|
|
508
|
+
// Agent 2 claims next ready work
|
|
509
|
+
bd_claim(); // Gets bd-a3f8.2 (now unblocked)
|
|
510
|
+
|
|
511
|
+
// After bd-a3f8.3 completes, both .4 and .5 become ready
|
|
512
|
+
// Multiple agents can work on them in parallel
|
|
278
513
|
```
|