opencodekit 0.16.14 → 0.16.17

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.
Files changed (70) hide show
  1. package/dist/index.js +1 -1
  2. package/dist/template/.opencode/AGENTS.md +1 -1
  3. package/dist/template/.opencode/agent/plan.md +77 -161
  4. package/dist/template/.opencode/command/create.md +75 -307
  5. package/dist/template/.opencode/command/design.md +53 -589
  6. package/dist/template/.opencode/command/handoff.md +76 -180
  7. package/dist/template/.opencode/command/init.md +45 -211
  8. package/dist/template/.opencode/command/plan.md +62 -514
  9. package/dist/template/.opencode/command/pr.md +56 -226
  10. package/dist/template/.opencode/command/research.md +55 -266
  11. package/dist/template/.opencode/command/resume.md +33 -138
  12. package/dist/template/.opencode/command/review-codebase.md +54 -202
  13. package/dist/template/.opencode/command/ship.md +78 -127
  14. package/dist/template/.opencode/command/start.md +47 -577
  15. package/dist/template/.opencode/command/status.md +55 -354
  16. package/dist/template/.opencode/command/ui-review.md +52 -298
  17. package/dist/template/.opencode/command/verify.md +36 -250
  18. package/dist/template/.opencode/dcp.jsonc +10 -9
  19. package/dist/template/.opencode/memory.db-shm +0 -0
  20. package/dist/template/.opencode/memory.db-wal +0 -0
  21. package/dist/template/.opencode/plugin/README.md +8 -4
  22. package/dist/template/.opencode/plugin/swarm-enforcer.ts +182 -27
  23. package/dist/template/.opencode/skill/augment-context-engine/SKILL.md +112 -0
  24. package/dist/template/.opencode/skill/augment-context-engine/mcp.json +6 -0
  25. package/dist/template/.opencode/skill/core-data-expert/SKILL.md +82 -0
  26. package/dist/template/.opencode/skill/core-data-expert/references/batch-operations.md +543 -0
  27. package/dist/template/.opencode/skill/core-data-expert/references/cloudkit-integration.md +259 -0
  28. package/dist/template/.opencode/skill/core-data-expert/references/concurrency.md +522 -0
  29. package/dist/template/.opencode/skill/core-data-expert/references/fetch-requests.md +643 -0
  30. package/dist/template/.opencode/skill/core-data-expert/references/glossary.md +233 -0
  31. package/dist/template/.opencode/skill/core-data-expert/references/migration.md +393 -0
  32. package/dist/template/.opencode/skill/core-data-expert/references/model-configuration.md +597 -0
  33. package/dist/template/.opencode/skill/core-data-expert/references/performance.md +300 -0
  34. package/dist/template/.opencode/skill/core-data-expert/references/persistent-history.md +553 -0
  35. package/dist/template/.opencode/skill/core-data-expert/references/project-audit.md +60 -0
  36. package/dist/template/.opencode/skill/core-data-expert/references/saving.md +574 -0
  37. package/dist/template/.opencode/skill/core-data-expert/references/stack-setup.md +625 -0
  38. package/dist/template/.opencode/skill/core-data-expert/references/testing.md +300 -0
  39. package/dist/template/.opencode/skill/core-data-expert/references/threading.md +589 -0
  40. package/dist/template/.opencode/skill/swift-concurrency/SKILL.md +246 -0
  41. package/dist/template/.opencode/skill/swift-concurrency/references/actors.md +640 -0
  42. package/dist/template/.opencode/skill/swift-concurrency/references/async-algorithms.md +822 -0
  43. package/dist/template/.opencode/skill/swift-concurrency/references/async-await-basics.md +249 -0
  44. package/dist/template/.opencode/skill/swift-concurrency/references/async-sequences.md +670 -0
  45. package/dist/template/.opencode/skill/swift-concurrency/references/core-data.md +533 -0
  46. package/dist/template/.opencode/skill/swift-concurrency/references/glossary.md +128 -0
  47. package/dist/template/.opencode/skill/swift-concurrency/references/linting.md +142 -0
  48. package/dist/template/.opencode/skill/swift-concurrency/references/memory-management.md +542 -0
  49. package/dist/template/.opencode/skill/swift-concurrency/references/migration.md +1076 -0
  50. package/dist/template/.opencode/skill/swift-concurrency/references/performance.md +574 -0
  51. package/dist/template/.opencode/skill/swift-concurrency/references/sendable.md +578 -0
  52. package/dist/template/.opencode/skill/swift-concurrency/references/tasks.md +604 -0
  53. package/dist/template/.opencode/skill/swift-concurrency/references/testing.md +565 -0
  54. package/dist/template/.opencode/skill/swift-concurrency/references/threading.md +452 -0
  55. package/dist/template/.opencode/skill/swiftui-expert-skill/SKILL.md +290 -0
  56. package/dist/template/.opencode/skill/swiftui-expert-skill/references/animation-advanced.md +351 -0
  57. package/dist/template/.opencode/skill/swiftui-expert-skill/references/animation-basics.md +284 -0
  58. package/dist/template/.opencode/skill/swiftui-expert-skill/references/animation-transitions.md +326 -0
  59. package/dist/template/.opencode/skill/swiftui-expert-skill/references/image-optimization.md +286 -0
  60. package/dist/template/.opencode/skill/swiftui-expert-skill/references/layout-best-practices.md +312 -0
  61. package/dist/template/.opencode/skill/swiftui-expert-skill/references/liquid-glass.md +377 -0
  62. package/dist/template/.opencode/skill/swiftui-expert-skill/references/list-patterns.md +153 -0
  63. package/dist/template/.opencode/skill/swiftui-expert-skill/references/modern-apis.md +400 -0
  64. package/dist/template/.opencode/skill/swiftui-expert-skill/references/performance-patterns.md +377 -0
  65. package/dist/template/.opencode/skill/swiftui-expert-skill/references/scroll-patterns.md +305 -0
  66. package/dist/template/.opencode/skill/swiftui-expert-skill/references/sheet-navigation-patterns.md +292 -0
  67. package/dist/template/.opencode/skill/swiftui-expert-skill/references/state-management.md +447 -0
  68. package/dist/template/.opencode/skill/swiftui-expert-skill/references/text-formatting.md +285 -0
  69. package/dist/template/.opencode/skill/swiftui-expert-skill/references/view-structure.md +276 -0
  70. package/package.json +1 -1
@@ -2,20 +2,17 @@
2
2
  description: Verify implementation completeness, correctness, and coherence
3
3
  argument-hint: "<bead-id> [--quick] [--fix]"
4
4
  agent: review
5
- subtask: true
6
5
  ---
7
6
 
8
7
  # Verify: $ARGUMENTS
9
8
 
10
- Three-dimensional verification before claiming work complete. Inspired by OpenSpec's verify workflow.
9
+ Check implementation against PRD before shipping.
11
10
 
12
11
  ## Load Skills
13
12
 
14
13
  ```typescript
15
14
  skill({ name: "beads" });
16
15
  skill({ name: "verification-before-completion" });
17
- skill({ name: "systematic-debugging" });
18
- skill({ name: "memory-system" });
19
16
  ```
20
17
 
21
18
  ## Parse Arguments
@@ -23,285 +20,74 @@ skill({ name: "memory-system" });
23
20
  | Argument | Default | Description |
24
21
  | ----------- | -------- | -------------------------------- |
25
22
  | `<bead-id>` | required | The bead to verify |
26
- | `--quick` | false | Skip coherence check, gates only |
27
- | `--fix` | false | Auto-fix issues where possible |
23
+ | `--quick` | false | Gates only, skip coherence check |
24
+ | `--fix` | false | Auto-fix lint/format issues |
28
25
 
29
- ---
30
-
31
- ## Phase 1: Check Memory for Context
32
-
33
- Search for relevant verification patterns and past issues:
34
-
35
- ```typescript
36
- memory_search({ query: "$ARGUMENTS verification issues patterns", limit: 3 });
37
- ```
38
-
39
- ---
40
-
41
- ## Phase 2: Gather Artifacts
26
+ ## Phase 1: Gather Context
42
27
 
43
28
  ```bash
44
29
  br show $ARGUMENTS
45
30
  ls .beads/artifacts/$ARGUMENTS/
46
31
  ```
47
32
 
48
- Read all artifacts:
33
+ Read the PRD and any other artifacts (plan.md, research.md, design.md).
49
34
 
50
- ```bash
51
- cat .beads/artifacts/$ARGUMENTS/prd.md 2>/dev/null
52
- cat .beads/artifacts/$ARGUMENTS/plan.md 2>/dev/null
53
- cat .beads/artifacts/$ARGUMENTS/research.md 2>/dev/null
54
- cat .beads/artifacts/$ARGUMENTS/design.md 2>/dev/null
55
- ```
35
+ ## Phase 2: Completeness
56
36
 
57
- ---
37
+ Extract all requirements/tasks from the PRD and verify each is implemented:
58
38
 
59
- ## Phase 3: Completeness Check
39
+ - For each requirement: find evidence in the codebase (file:line reference)
40
+ - Mark as: complete, partial, or missing
41
+ - Report completeness score (X/Y requirements met)
60
42
 
61
- **Are all required artifacts present?**
43
+ ## Phase 3: Correctness
62
44
 
63
- | Artifact | Required | Status |
64
- | ------------- | -------- | ------ |
65
- | `prd.md` | Yes | [ ] |
66
- | `plan.md` | Yes | [ ] |
67
- | `research.md` | No | [ ] |
68
- | `design.md` | No | [ ] |
45
+ Detect project type and run the appropriate verification gates:
69
46
 
70
- **Are all tasks in the PRD addressed?**
47
+ | Project Type | Detect Via | Build | Test | Lint | Typecheck |
48
+ | --------------- | ----------------------------- | ---------------- | --------------- | ----------------------------- | ------------------------------------- |
49
+ | Node/TypeScript | `package.json` | `npm run build` | `npm test` | `npm run lint` | `npm run typecheck` or `tsc --noEmit` |
50
+ | Rust | `Cargo.toml` | `cargo build` | `cargo test` | `cargo clippy -- -D warnings` | (included in build) |
51
+ | Python | `pyproject.toml` / `setup.py` | — | `pytest` | `ruff check .` | `mypy .` |
52
+ | Go | `go.mod` | `go build ./...` | `go test ./...` | `golangci-lint run` | (included in build) |
71
53
 
72
- Extract tasks/criteria from prd.md and verify each is implemented:
54
+ Check `package.json` scripts, `Makefile`, or `justfile` for project-specific commands first — prefer those over generic defaults.
73
55
 
74
- ```markdown
75
- ## Completeness Report
56
+ If `--fix` flag provided, run the project's auto-fix command (e.g., `npm run lint:fix`, `ruff check --fix`, `cargo clippy --fix`).
76
57
 
77
- | Requirement | Status | Evidence |
78
- | ----------------- | ---------- | ----------------------- |
79
- | [Req 1 from spec] | ✓ Complete | `src/foo.ts:42` |
80
- | [Req 2 from spec] | ✓ Complete | `src/bar.ts:15` |
81
- | [Req 3 from spec] | ⚠ Partial | Missing edge case tests |
82
- | [Req 4 from spec] | ✗ Missing | Not implemented |
83
- ```
84
-
85
- **Completeness Score:** X/Y requirements met
86
-
87
- ---
88
-
89
- ## Phase 4: Correctness Check
90
-
91
- **Do the automated gates pass?**
92
-
93
- ```bash
94
- # Detect project type and run gates
95
- ls package.json Cargo.toml pyproject.toml go.mod 2>/dev/null
96
- ```
97
-
98
- **Node/TypeScript:**
99
-
100
- ```bash
101
- npm run build 2>&1 | tail -10
102
- npm test 2>&1 | tail -20
103
- npm run lint 2>&1 | tail -10
104
- npm run typecheck 2>&1 | tail -10
105
- ```
58
+ Report gate results (pass/warn/fail for each).
106
59
 
107
- **Rust:**
108
-
109
- ```bash
110
- cargo build 2>&1 | tail -10
111
- cargo test 2>&1 | tail -20
112
- cargo clippy -- -D warnings 2>&1 | tail -10
113
- ```
114
-
115
- **Python:**
116
-
117
- ```bash
118
- pytest 2>&1 | tail -20
119
- ruff check . 2>&1 | tail -10
120
- mypy . 2>&1 | tail -10
121
- ```
122
-
123
- **Go:**
124
-
125
- ```bash
126
- go build ./... 2>&1 | tail -10
127
- go test ./... 2>&1 | tail -20
128
- golangci-lint run 2>&1 | tail -10
129
- ```
130
-
131
- ```markdown
132
- ## Correctness Report
133
-
134
- | Gate | Status | Details |
135
- | --------- | ------ | ------------------------- |
136
- | Build | ✓ Pass | |
137
- | Tests | ✓ Pass | 42 tests, 0 failures |
138
- | Lint | ⚠ Warn | 2 warnings (non-blocking) |
139
- | Typecheck | ✓ Pass | |
140
- ```
141
-
142
- **Correctness Score:** X/Y gates passed
143
-
144
- ---
145
-
146
- ## Phase 5: Coherence Check (skip with --quick)
147
-
148
- **Do artifacts agree with each other?**
60
+ ## Phase 4: Coherence (skip with --quick)
149
61
 
150
62
  Cross-reference artifacts for contradictions:
151
63
 
152
- | Check | Status | Issue |
153
- | ---------------------------- | ------ | ----------------------------------- |
154
- | prd.md plan.md | ✓ | Plan addresses all PRD requirements |
155
- | plan.md ↔ implementation | ✓ | Code follows plan structure |
156
- | research.md ↔ implementation | ⚠ | Didn't use recommended approach |
157
- | design.md ↔ implementation | ✓ | Follows design patterns |
158
-
159
- **Common coherence issues:**
160
-
161
- - Plan says X, implementation does Y
162
- - Research recommended approach A, used approach B (without justification)
163
- - Spec says must-have, implementation treats as optional
164
- - Design specifies pattern, implementation uses different pattern
64
+ - PRD vs implementation (does code address all PRD requirements?)
65
+ - Plan vs implementation (did code follow the plan?)
66
+ - Research recommendations vs actual approach (if different, is it justified?)
165
67
 
166
- ```markdown
167
- ## Coherence Report
168
-
169
- Contradictions found: 1
170
-
171
- 1. **Research vs Implementation**
172
- - Research recommended: Use `zod` for validation
173
- - Implementation uses: Manual validation
174
- - Impact: Medium - works but less maintainable
175
- - Action: Document decision or refactor
176
- ```
68
+ Flag contradictions with specific file references.
177
69
 
178
- **Coherence Score:** X/Y checks passed
179
-
180
- ---
181
-
182
- ## Phase 6: Verification Summary
183
-
184
- ```
185
- Verification: $ARGUMENTS
186
- ━━━━━━━━━━━━━━━━━━━━━━━
187
-
188
- Dimension Score Status
189
- ───────────────────────────────
190
- Completeness 4/5 ⚠ PARTIAL
191
- Correctness 4/4 ✓ PASS
192
- Coherence 3/4 ⚠ PARTIAL
193
-
194
- Overall: ⚠ NEEDS ATTENTION
195
-
196
- Issues Found:
197
- ─────────────
198
- BLOCKING (must fix):
199
- • [Req 4] Not implemented
200
-
201
- NON-BLOCKING (should fix):
202
- • [Req 3] Missing edge case tests
203
- • Research recommendation not followed
204
-
205
- Recommendations:
206
- ────────────────
207
- 1. Implement [Req 4] before closing
208
- 2. Add tests for edge case X
209
- 3. Document why zod was not used, or refactor to use it
210
- ```
211
-
212
- ---
213
-
214
- ## Phase 7: Auto-Fix (if --fix)
215
-
216
- For fixable issues, attempt automatic resolution:
217
-
218
- ```typescript
219
- // If lint issues are fixable
220
- if (hasLintWarnings && canAutoFix) {
221
- bash({ command: "npm run lint -- --fix" });
222
- }
223
-
224
- // If missing tests detected
225
- if (missingTests) {
226
- console.log("Consider adding tests for: [list uncovered code]");
227
- }
228
- ```
229
-
230
- ---
231
-
232
- ## Phase 8: Update Bead Notes
233
-
234
- Record verification results in bead:
70
+ ## Phase 5: Report
235
71
 
236
72
  ```bash
237
73
  br comments add $ARGUMENTS "Verification: [PASS|PARTIAL|FAIL] - [summary]"
238
74
  ```
239
75
 
240
- ---
241
-
242
- ## Phase 9: Record Findings
243
-
244
- If significant issues or patterns discovered:
245
-
246
- ```typescript
247
- observation({
248
- type: "discovery",
249
- title: "Verification findings for $ARGUMENTS",
250
- narrative: "[Summary of issues found, patterns discovered, or lessons learned]",
251
- concepts: "verification, testing, quality",
252
- bead_id: "$ARGUMENTS",
253
- confidence: "high",
254
- });
255
- ```
256
-
257
- ---
258
-
259
- ## Output
260
-
261
- ```
262
- Verification Complete: $ARGUMENTS
263
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
264
-
265
- Result: ✓ READY TO SHIP | ⚠ NEEDS WORK | ✗ BLOCKED
266
-
267
- Completeness: [score] - [status]
268
- Correctness: [score] - [status]
269
- Coherence: [score] - [status]
270
-
271
- [If READY TO SHIP]
272
- Next: /ship $ARGUMENTS
273
-
274
- [If NEEDS WORK]
275
- Fix these before shipping:
276
- • [issue 1]
277
- • [issue 2]
278
-
279
- [If BLOCKED]
280
- Cannot proceed until:
281
- • [blocker 1]
282
- ```
283
-
284
- ---
285
-
286
- ## Examples
287
-
288
- ```bash
289
- # Full verification
290
- /verify br-feature-auth
291
-
292
- # Quick check (gates only)
293
- /verify br-feature-auth --quick
76
+ Output:
294
77
 
295
- # Verify and auto-fix where possible
296
- /verify br-feature-auth --fix
297
- ```
78
+ 1. **Result**: READY TO SHIP / NEEDS WORK / BLOCKED
79
+ 2. **Completeness**: score and status
80
+ 3. **Correctness**: gate results
81
+ 4. **Coherence**: contradictions found (if not --quick)
82
+ 5. **Blocking issues** to fix before shipping
83
+ 6. **Next step**: `/ship $ARGUMENTS` if ready, or list fixes needed
298
84
 
299
- ---
85
+ Record significant findings with `observation()`.
300
86
 
301
87
  ## Related Commands
302
88
 
303
89
  | Need | Command |
304
90
  | ----------------- | ------------------ |
305
- | Ship after verify | `/ship $ARGUMENTS` |
91
+ | Ship after verify | `/ship <id>` |
306
92
  | Review code | `/review-codebase` |
307
93
  | Check status | `/status` |
@@ -3,9 +3,9 @@
3
3
  "enabled": true,
4
4
  "debug": false,
5
5
  // "minimal" shows prune activity without noise; "detailed" shows token counts
6
- "pruneNotification": "off",
6
+ "pruneNotification": "detailed",
7
7
  // "chat" (in-conversation) or "toast" (system notification)
8
- "pruneNotificationType": "chat",
8
+ "pruneNotificationType": "toast",
9
9
  // Commands: /dcp context, /dcp stats, /dcp sweep
10
10
  "commands": {
11
11
  "enabled": true,
@@ -30,8 +30,8 @@
30
30
  "settings": {
31
31
  "nudgeEnabled": true,
32
32
  "nudgeFrequency": 10,
33
- // v2.0.1: percentage support - 90% of model's 128k context
34
- "contextLimit": "90%",
33
+ // v2.0.1: percentage support - 90% of model's 128k context
34
+ "contextLimit": "90%",
35
35
  // Protect state-modifying and critical workflow tools
36
36
  // LSP excluded: ephemeral exploration, prune after understanding
37
37
  "protectedTools": [
@@ -55,11 +55,12 @@
55
55
  "permission": "allow",
56
56
  "showDistillation": false
57
57
  },
58
- "compress": {
59
- // v2.0.1: compress is experimental, deny by default
60
- "permission": "deny",
61
- "showCompression": false,
62
- },
58
+ "compress": {
59
+ // v2.0.1: compress is experimental, deny by default
60
+ "permission": "deny",
61
+ "showCompression": false
62
+ }
63
+ },
63
64
  "strategies": {
64
65
  // Dedup = zero LLM cost, high impact - always enable
65
66
  "deduplication": {
@@ -82,12 +82,16 @@ Session 3: read_session("previous") → Tests (90k) → close
82
82
 
83
83
  ### swarm-enforcer.ts
84
84
 
85
- **Swarm protocol guardrails (Beads-as-board)** - nudges agents to follow the Beads-first workflow.
85
+ **Swarm protocol guardrails (Beads-as-board)** - enforces the `/create` `/start` `/ship` workflow.
86
86
 
87
87
  - Treats `.beads/` as the single source of truth for the swarm task board
88
- - If user expresses implementation intent and no task is `in_progress`, injects a nudge to use `br ready/show/update`
89
- - If there are `in_progress` tasks but `.beads/artifacts/<id>/spec.md` is missing, nudges to create it before implementation
90
- - On `file.edited`, warns if code is being changed without a claimed task or with missing `spec.md`
88
+ - **Workflow stage tracking**: Computes each bead's stage based on artifacts and status:
89
+ - `⏳needs:/create` no prd.md exists yet
90
+ - `⏳needs:/start` has prd.md but not claimed (in_progress)
91
+ - `✅ready:/ship` — in_progress with prd.md, ready for implementation
92
+ - `⚠needs:/create→/start` — in_progress but missing prd.md
93
+ - **System prompt injection** via `experimental.chat.system.transform`: injects workflow stage per bead, enforcement rules ("Do NOT implement until `/start`"), and protocol reminders into every LLM call
94
+ - On `file.edited`, warns if code is being changed without a claimed task or when workflow is incomplete (no prd.md)
91
95
  - On `session.idle`, reminds to `br close` + `br sync` when work is done
92
96
 
93
97
  ### notification.ts