opencodekit 0.13.0 → 0.13.2
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/README.md +2 -2
- package/dist/index.js +1 -1
- package/dist/template/.opencode/README.md +2 -2
- package/dist/template/.opencode/command/implement.md +195 -39
- package/dist/template/.opencode/command/new-feature.md +229 -188
- package/dist/template/.opencode/command/plan.md +354 -82
- package/dist/template/.opencode/command/research.md +29 -2
- package/dist/template/.opencode/command/start.md +125 -4
- package/dist/template/.opencode/memory/project/beads-workflow.md +274 -42
- package/dist/template/.opencode/opencode.json +523 -557
- package/dist/template/.opencode/skill/source-code-research/SKILL.md +537 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -251,10 +251,10 @@ You've successfully set up OpenCodeKit when:
|
|
|
251
251
|
|
|
252
252
|
---
|
|
253
253
|
|
|
254
|
-
**OpenCodeKit v0.13.
|
|
254
|
+
**OpenCodeKit v0.13.2**
|
|
255
255
|
**Architecture**: Two-layer (Memory + Beads + Git)
|
|
256
256
|
**Package**: `npx opencodekit` to scaffold new projects
|
|
257
|
-
**New in v0.13.
|
|
257
|
+
**New in v0.13.2**: Multimodal support for gemini-claude models (image, PDF input)
|
|
258
258
|
**Ready for**: Daily production use
|
|
259
259
|
|
|
260
260
|
Enjoy your streamlined agent system with clean phase transitions!
|
package/dist/index.js
CHANGED
|
@@ -750,7 +750,7 @@ var cac = (name = "") => new CAC(name);
|
|
|
750
750
|
// package.json
|
|
751
751
|
var package_default = {
|
|
752
752
|
name: "opencodekit",
|
|
753
|
-
version: "0.13.
|
|
753
|
+
version: "0.13.2",
|
|
754
754
|
description: "CLI tool for bootstrapping and managing OpenCodeKit projects",
|
|
755
755
|
type: "module",
|
|
756
756
|
repository: {
|
|
@@ -330,8 +330,8 @@ fi
|
|
|
330
330
|
|
|
331
331
|
---
|
|
332
332
|
|
|
333
|
-
**OpenCodeKit v0.13.
|
|
333
|
+
**OpenCodeKit v0.13.2**
|
|
334
334
|
**Architecture:** Two-Layer (Memory + Beads + Git)
|
|
335
|
-
**New in v0.13.
|
|
335
|
+
**New in v0.13.2:** Multimodal support for gemini-claude models (image, PDF input)
|
|
336
336
|
**Package:** `npx opencodekit` to scaffold new projects
|
|
337
337
|
**Last Updated:** January 8, 2026
|
|
@@ -1,14 +1,21 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Implement a bead - load context, make changes, verify
|
|
3
|
-
argument-hint: "<bead-id>"
|
|
2
|
+
description: Implement a bead - load context, delegate research, make changes, verify
|
|
3
|
+
argument-hint: "<bead-id> [--parallel]"
|
|
4
4
|
agent: build
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# Implement: $ARGUMENTS
|
|
8
8
|
|
|
9
|
-
You're implementing a tracked task. Stay focused, verify as you go, hand off if you hit limits.
|
|
9
|
+
You're implementing a tracked task. Stay focused, delegate research, verify as you go, hand off if you hit limits.
|
|
10
10
|
|
|
11
|
-
##
|
|
11
|
+
## Parse Arguments
|
|
12
|
+
|
|
13
|
+
| Argument | Default | Description |
|
|
14
|
+
| ------------ | -------- | ----------------------------------------- |
|
|
15
|
+
| `<bead-id>` | required | The bead to implement |
|
|
16
|
+
| `--parallel` | false | Run aggressive parallel subagent research |
|
|
17
|
+
|
|
18
|
+
## First: Load Skills & Context
|
|
12
19
|
|
|
13
20
|
```typescript
|
|
14
21
|
skill({ name: "beads" });
|
|
@@ -16,27 +23,54 @@ skill({ name: "test-driven-development" });
|
|
|
16
23
|
skill({ name: "verification-before-completion" });
|
|
17
24
|
```
|
|
18
25
|
|
|
19
|
-
Get the task details and check
|
|
26
|
+
Get the task details and check hierarchy:
|
|
20
27
|
|
|
28
|
+
```bash
|
|
29
|
+
bd show $ARGUMENTS
|
|
30
|
+
bd dep tree $ARGUMENTS 2>/dev/null || echo "No dependencies"
|
|
31
|
+
bd list --status=in_progress # See what else is active
|
|
21
32
|
```
|
|
22
|
-
|
|
23
|
-
|
|
33
|
+
|
|
34
|
+
Check for messages from other agents:
|
|
35
|
+
|
|
36
|
+
```typescript
|
|
37
|
+
bd - inbox({ n: 5, unread: true });
|
|
24
38
|
```
|
|
25
39
|
|
|
26
|
-
Check
|
|
40
|
+
## Check Hierarchy Position
|
|
41
|
+
|
|
42
|
+
Identify where this task sits:
|
|
43
|
+
|
|
44
|
+
| Type | Action |
|
|
45
|
+
| --------- | ------------------------------------------- |
|
|
46
|
+
| `epic` | Don't implement directly - work on subtasks |
|
|
47
|
+
| `task` | May implement or delegate to subtasks |
|
|
48
|
+
| `subtask` | Implement directly - this is leaf work |
|
|
27
49
|
|
|
50
|
+
**If this is an epic with subtasks:**
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
bd ready --json | grep -q "$ARGUMENTS"
|
|
28
54
|
```
|
|
29
|
-
|
|
30
|
-
|
|
55
|
+
|
|
56
|
+
→ Work on ready subtasks instead: `/implement <subtask-id>`
|
|
57
|
+
|
|
58
|
+
## Git State Check
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
git status --porcelain
|
|
62
|
+
git branch --show-current
|
|
31
63
|
```
|
|
32
64
|
|
|
65
|
+
If dirty, ask whether to stash, commit, or continue.
|
|
66
|
+
|
|
33
67
|
Create a branch if not already on one for this task:
|
|
34
68
|
|
|
35
69
|
```bash
|
|
36
|
-
git checkout -b $ARGUMENTS
|
|
70
|
+
git checkout -b $ARGUMENTS 2>/dev/null || echo "Already on branch"
|
|
37
71
|
```
|
|
38
72
|
|
|
39
|
-
Mark the task in progress:
|
|
73
|
+
Mark the task in progress (if not already):
|
|
40
74
|
|
|
41
75
|
```bash
|
|
42
76
|
bd update $ARGUMENTS --status in_progress
|
|
@@ -46,59 +80,163 @@ bd update $ARGUMENTS --status in_progress
|
|
|
46
80
|
|
|
47
81
|
Check what context exists:
|
|
48
82
|
|
|
49
|
-
```
|
|
50
|
-
|
|
83
|
+
```bash
|
|
84
|
+
ls .beads/artifacts/$ARGUMENTS/ 2>/dev/null || echo "No artifacts"
|
|
51
85
|
```
|
|
52
86
|
|
|
53
|
-
|
|
87
|
+
| Found | Action |
|
|
88
|
+
| ------------- | ------------------------------------ |
|
|
89
|
+
| `plan.md` | Follow it step by step |
|
|
90
|
+
| `spec.md` | Implement directly from requirements |
|
|
91
|
+
| `research.md` | Use findings to guide implementation |
|
|
92
|
+
| Nothing | Work from bead description |
|
|
54
93
|
|
|
55
94
|
Check for previous session work:
|
|
56
95
|
|
|
57
96
|
```typescript
|
|
58
|
-
|
|
59
|
-
read_session({ session_reference: "last"
|
|
97
|
+
search_session({ query: "$ARGUMENTS" });
|
|
98
|
+
read_session({ session_reference: "last" });
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Parallel Subagent Research (if --parallel or complex task)
|
|
102
|
+
|
|
103
|
+
**Delegation Pattern: Fire and Continue**
|
|
104
|
+
|
|
105
|
+
For complex tasks, launch research subagents in parallel before diving into code:
|
|
106
|
+
|
|
107
|
+
```typescript
|
|
108
|
+
// Codebase patterns - find similar implementations
|
|
109
|
+
Task({
|
|
110
|
+
subagent_type: "explore",
|
|
111
|
+
prompt: `For implementing $ARGUMENTS, find:
|
|
112
|
+
1. Similar patterns in this codebase (grep/ast-grep)
|
|
113
|
+
2. Related test files and testing patterns
|
|
114
|
+
3. Configuration or setup requirements
|
|
115
|
+
Return: File paths, code patterns, test approach`,
|
|
116
|
+
description: "Explore patterns for implementation",
|
|
117
|
+
});
|
|
118
|
+
|
|
119
|
+
// External best practices - library docs
|
|
120
|
+
Task({
|
|
121
|
+
subagent_type: "scout",
|
|
122
|
+
prompt: `Research best practices for $ARGUMENTS:
|
|
123
|
+
1. Official documentation for libraries involved
|
|
124
|
+
2. Common implementation patterns (Context7, GitHub)
|
|
125
|
+
3. Known pitfalls or gotchas
|
|
126
|
+
Return: Code examples, API usage, warnings`,
|
|
127
|
+
description: "Scout external docs",
|
|
128
|
+
});
|
|
129
|
+
|
|
130
|
+
// Continue working immediately - don't wait for results
|
|
60
131
|
```
|
|
61
132
|
|
|
133
|
+
**Subagent Rules:**
|
|
134
|
+
| Agent | Use For | Can Do | Cannot Do |
|
|
135
|
+
| -------- | ------------------------------ | ---------------- | ---------------- |
|
|
136
|
+
| `explore`| Codebase search, patterns | Read, grep, glob | Edit, bd sync |
|
|
137
|
+
| `scout` | External docs, best practices | Fetch, search | Edit, bd sync |
|
|
138
|
+
| `review` | Code review, debugging | Read, analyze | Edit, bd sync |
|
|
139
|
+
| `planner`| Architecture, decomposition | Read, plan | Edit, bd sync |
|
|
140
|
+
|
|
141
|
+
**You (build agent) are the leader:**
|
|
142
|
+
|
|
143
|
+
- Subagents return results to you
|
|
144
|
+
- Only you modify files and update beads
|
|
145
|
+
- Integrate subagent findings into your implementation
|
|
146
|
+
|
|
62
147
|
## Estimate Your Budget
|
|
63
148
|
|
|
64
149
|
Look at the task complexity and set limits:
|
|
65
150
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
151
|
+
| Size | Tool Calls | Scope |
|
|
152
|
+
| ------ | ---------- | ----------------------------------- |
|
|
153
|
+
| Small | ~10 | Simple change, one file, clear path |
|
|
154
|
+
| Medium | ~30 | Multiple files, some exploration |
|
|
155
|
+
| Large | ~100 | Cross-cutting, needs checkpoints |
|
|
156
|
+
| XL | Stop | Decompose into subtasks first |
|
|
157
|
+
|
|
158
|
+
**If XL detected:**
|
|
159
|
+
|
|
160
|
+
```
|
|
161
|
+
This task is too large for a single session.
|
|
162
|
+
Recommend: /plan $ARGUMENTS --create-beads
|
|
163
|
+
```
|
|
70
164
|
|
|
71
|
-
If you hit 80% of budget without finishing, create a handoff. Don't push past limits
|
|
165
|
+
If you hit 80% of budget without finishing, create a handoff. Don't push past limits.
|
|
166
|
+
|
|
167
|
+
## Lock Files Before Editing
|
|
168
|
+
|
|
169
|
+
For shared files or multi-agent coordination:
|
|
170
|
+
|
|
171
|
+
```typescript
|
|
172
|
+
bd - reserve({ paths: ["src/file-to-edit.ts"], ttl: 600 });
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
Release after completing edits:
|
|
176
|
+
|
|
177
|
+
```typescript
|
|
178
|
+
bd - release({ paths: ["src/file-to-edit.ts"] });
|
|
179
|
+
```
|
|
72
180
|
|
|
73
181
|
## Do The Work
|
|
74
182
|
|
|
75
183
|
Detect project type and know your verification commands:
|
|
76
184
|
|
|
77
|
-
```
|
|
78
|
-
|
|
185
|
+
```bash
|
|
186
|
+
ls package.json Cargo.toml pyproject.toml go.mod Makefile 2>/dev/null
|
|
79
187
|
```
|
|
80
188
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
189
|
+
| Project | Test Command | Lint Command |
|
|
190
|
+
| ------- | --------------- | ----------------------------------- |
|
|
191
|
+
| Node/TS | `npm test` | `npm run lint && npm run typecheck` |
|
|
192
|
+
| Rust | `cargo test` | `cargo clippy -- -D warnings` |
|
|
193
|
+
| Python | `pytest` | `ruff check . && mypy .` |
|
|
194
|
+
| Go | `go test ./...` | `golangci-lint run` |
|
|
85
195
|
|
|
86
196
|
**Rules while implementing:**
|
|
87
197
|
|
|
88
|
-
1. Read before edit
|
|
89
|
-
2. Run verification after each logical change
|
|
90
|
-
3.
|
|
91
|
-
4. Checkpoint
|
|
92
|
-
5.
|
|
198
|
+
1. **Read before edit.** Always.
|
|
199
|
+
2. **Run verification** after each logical change
|
|
200
|
+
3. **Delegate when stuck**: If blocked on understanding, launch `@explore` or `@scout`
|
|
201
|
+
4. **Checkpoint** after significant progress: `git commit -m "WIP: $ARGUMENTS - [step]"`
|
|
202
|
+
5. **Create child beads** for discovered subtasks:
|
|
203
|
+
```bash
|
|
204
|
+
bd create "Discovered: [subtask]" -t subtask -p 2
|
|
205
|
+
bd dep add <new-id> $ARGUMENTS --type blocks
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
**Progress tracking** - every 10 tool calls:
|
|
93
209
|
|
|
94
|
-
|
|
210
|
+
- Am I on track?
|
|
211
|
+
- Should I checkpoint?
|
|
212
|
+
- Am I approaching budget?
|
|
213
|
+
- Need to delegate research?
|
|
214
|
+
|
|
215
|
+
## Subtask Coordination (if parent task)
|
|
216
|
+
|
|
217
|
+
If implementing a task with subtasks:
|
|
218
|
+
|
|
219
|
+
```bash
|
|
220
|
+
# Check which subtasks are ready
|
|
221
|
+
bd ready --json | jq '.[] | select(.parent == "$ARGUMENTS")'
|
|
222
|
+
|
|
223
|
+
# Work on ready subtasks in order
|
|
224
|
+
# When subtask done:
|
|
225
|
+
bd close <subtask-id> --reason "Completed: description"
|
|
226
|
+
|
|
227
|
+
# Check if parent can close
|
|
228
|
+
bd dep tree $ARGUMENTS
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
**Pattern: Complete subtasks before parent**
|
|
95
232
|
|
|
96
233
|
## Before Claiming Done
|
|
97
234
|
|
|
98
235
|
Verify against success criteria in the spec:
|
|
99
236
|
|
|
100
|
-
```
|
|
101
|
-
|
|
237
|
+
```bash
|
|
238
|
+
cat .beads/artifacts/$ARGUMENTS/spec.md | grep -A 20 "Success Criteria" || \
|
|
239
|
+
cat .beads/artifacts/$ARGUMENTS/spec.md | grep -A 20 "Acceptance Criteria"
|
|
102
240
|
```
|
|
103
241
|
|
|
104
242
|
Run each verification command. All must pass. No exceptions.
|
|
@@ -107,7 +245,7 @@ Run the full test suite one more time:
|
|
|
107
245
|
|
|
108
246
|
```bash
|
|
109
247
|
# Whatever your project uses
|
|
110
|
-
npm test && npm run
|
|
248
|
+
npm test && npm run typecheck
|
|
111
249
|
```
|
|
112
250
|
|
|
113
251
|
## Complete
|
|
@@ -126,9 +264,12 @@ git diff --cached --stat
|
|
|
126
264
|
Implementation Complete: $ARGUMENTS
|
|
127
265
|
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
128
266
|
|
|
267
|
+
Type: [epic/task/subtask]
|
|
129
268
|
Tests: Pass ✓
|
|
130
269
|
Changes: [files modified]
|
|
131
270
|
|
|
271
|
+
Subtasks: [N completed / M total] (if applicable)
|
|
272
|
+
|
|
132
273
|
Would you like me to:
|
|
133
274
|
1. Commit these changes
|
|
134
275
|
2. Show full diff first
|
|
@@ -144,10 +285,17 @@ git commit -m "$ARGUMENTS: [summary]"
|
|
|
144
285
|
bd sync
|
|
145
286
|
```
|
|
146
287
|
|
|
147
|
-
Suggest next step:
|
|
288
|
+
Suggest next step based on hierarchy:
|
|
289
|
+
|
|
290
|
+
| Situation | Next Command |
|
|
291
|
+
| -------------------- | --------------------------- |
|
|
292
|
+
| Subtask done | `/implement <next-subtask>` |
|
|
293
|
+
| All subtasks done | `/finish <parent-task>` |
|
|
294
|
+
| Task done, no parent | `/finish $ARGUMENTS` |
|
|
295
|
+
| Need PR | `/pr $ARGUMENTS` |
|
|
148
296
|
|
|
149
297
|
```
|
|
150
|
-
Next:
|
|
298
|
+
Next: [recommended command]
|
|
151
299
|
```
|
|
152
300
|
|
|
153
301
|
If gates fail, fix them. Don't proceed with broken code.
|
|
@@ -161,3 +309,11 @@ Hit budget limit or context getting too large? Create a handoff:
|
|
|
161
309
|
```
|
|
162
310
|
|
|
163
311
|
Then start a fresh session. Don't grind past diminishing returns.
|
|
312
|
+
|
|
313
|
+
## Release File Locks
|
|
314
|
+
|
|
315
|
+
Before ending session:
|
|
316
|
+
|
|
317
|
+
```typescript
|
|
318
|
+
bd - release({ _: true }); // List and release all locks
|
|
319
|
+
```
|