clikit-plugin 0.3.10 → 0.3.11
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.md +38 -10
- package/README.md +20 -22
- package/command/create.md +104 -20
- package/command/discuss.md +111 -0
- package/command/handoff.md +7 -5
- package/command/init.md +2 -2
- package/command/pr.md +2 -4
- package/command/research.md +130 -28
- package/command/resume.md +2 -2
- package/command/ship.md +1 -1
- package/command/start.md +8 -9
- package/command/status.md +11 -9
- package/dist/.tsbuildinfo +1 -1
- package/dist/clikit.schema.json +0 -8
- package/dist/config.d.ts +0 -5
- package/dist/config.d.ts.map +1 -1
- package/dist/hooks/index.d.ts +0 -2
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -72
- package/memory/_templates/discussion.md +91 -0
- package/memory/_templates/handoff.md +2 -2
- package/memory/_templates/plan.md +83 -176
- package/memory/_templates/research.md +33 -7
- package/memory/_templates/review.md +2 -2
- package/memory/discussions/.gitkeep +0 -0
- package/package.json +2 -2
- package/skill/requesting-code-review/SKILL.md +2 -2
- package/skill/ritual-workflow/SKILL.md +6 -4
- package/src/agents/AGENTS.md +13 -11
- package/src/agents/build.md +4 -4
- package/src/agents/explore.md +14 -14
- package/src/agents/plan.md +195 -57
- package/src/agents/research.md +41 -11
- package/src/agents/review.md +3 -3
- package/command/import-plan.md +0 -175
- package/command/issue.md +0 -109
- package/dist/hooks/tilth-first-guard.d.ts +0 -18
- package/dist/hooks/tilth-first-guard.d.ts.map +0 -1
- package/memory/_templates/spec.md +0 -128
package/dist/index.js
CHANGED
|
@@ -16594,10 +16594,6 @@ var DEFAULT_CONFIG = {
|
|
|
16594
16594
|
subagent_question_blocker: {
|
|
16595
16595
|
enabled: true
|
|
16596
16596
|
},
|
|
16597
|
-
tilth_first_guard: {
|
|
16598
|
-
enabled: true,
|
|
16599
|
-
log: false
|
|
16600
|
-
},
|
|
16601
16597
|
truncator: {
|
|
16602
16598
|
enabled: true,
|
|
16603
16599
|
max_output_chars: 30000,
|
|
@@ -17166,46 +17162,6 @@ function isSubagentTool(toolName) {
|
|
|
17166
17162
|
function formatBlockerWarning() {
|
|
17167
17163
|
return `[CliKit:subagent-blocker] Subagent attempted to ask clarifying questions. Subagents should execute autonomously.`;
|
|
17168
17164
|
}
|
|
17169
|
-
// src/hooks/tilth-first-guard.ts
|
|
17170
|
-
var EXPLORE_AGENT = "explore";
|
|
17171
|
-
var FALLBACK_TOOLS = new Set(["read", "grep", "glob"]);
|
|
17172
|
-
var EXPLICIT_TILTH_COMMAND = /^(?:npx\s+)?tilth(?:\s|$)/i;
|
|
17173
|
-
function normalize(value) {
|
|
17174
|
-
return typeof value === "string" ? value.trim().toLowerCase() : "";
|
|
17175
|
-
}
|
|
17176
|
-
function isExploreAgent(agent) {
|
|
17177
|
-
return normalize(agent) === EXPLORE_AGENT;
|
|
17178
|
-
}
|
|
17179
|
-
function isFallbackNavigationTool(toolName) {
|
|
17180
|
-
return FALLBACK_TOOLS.has(normalize(toolName));
|
|
17181
|
-
}
|
|
17182
|
-
function isExplicitTilthCommand(command) {
|
|
17183
|
-
return typeof command === "string" && EXPLICIT_TILTH_COMMAND.test(command.trim());
|
|
17184
|
-
}
|
|
17185
|
-
function markTilthAttempt(state) {
|
|
17186
|
-
return {
|
|
17187
|
-
...state || {},
|
|
17188
|
-
sawTilthAttempt: true
|
|
17189
|
-
};
|
|
17190
|
-
}
|
|
17191
|
-
function shouldBlockTilthFallback(agent, toolName, state) {
|
|
17192
|
-
if (!isExploreAgent(agent)) {
|
|
17193
|
-
return false;
|
|
17194
|
-
}
|
|
17195
|
-
if (!isFallbackNavigationTool(toolName)) {
|
|
17196
|
-
return false;
|
|
17197
|
-
}
|
|
17198
|
-
return state?.sawTilthAttempt !== true;
|
|
17199
|
-
}
|
|
17200
|
-
function formatTilthFirstGuardWarning(toolName) {
|
|
17201
|
-
return `[CliKit:tilth-first-guard] Blocked @explore from using ${toolName} before an explicit tilth CLI attempt.`;
|
|
17202
|
-
}
|
|
17203
|
-
function formatTilthFirstGuardReason(toolName) {
|
|
17204
|
-
return `@explore must call 'tilth <path>' before using ${toolName}. read/grep/glob are fallback tools only.`;
|
|
17205
|
-
}
|
|
17206
|
-
function formatTilthFirstGuardPass(command) {
|
|
17207
|
-
return `[CliKit:tilth-first-guard] Recorded tilth attempt for @explore: ${command}`;
|
|
17208
|
-
}
|
|
17209
17165
|
// src/hooks/truncator.ts
|
|
17210
17166
|
var DEFAULT_MAX_CHARS = 30000;
|
|
17211
17167
|
var DEFAULT_MAX_LINES = 500;
|
|
@@ -18433,7 +18389,6 @@ function ensureDcpInConfig() {
|
|
|
18433
18389
|
var CliKitPlugin = async (ctx) => {
|
|
18434
18390
|
const todosBySession = new Map;
|
|
18435
18391
|
const sessionAgents = new Map;
|
|
18436
|
-
const tilthFirstBySession = new Map;
|
|
18437
18392
|
const defaultMcpEntries = {
|
|
18438
18393
|
"beads-village": {
|
|
18439
18394
|
type: "local",
|
|
@@ -18953,7 +18908,6 @@ ${(content || "").trim()}`.trim();
|
|
|
18953
18908
|
if (sessionID) {
|
|
18954
18909
|
todosBySession.delete(sessionID);
|
|
18955
18910
|
sessionAgents.delete(sessionID);
|
|
18956
|
-
tilthFirstBySession.delete(sessionID);
|
|
18957
18911
|
}
|
|
18958
18912
|
}
|
|
18959
18913
|
},
|
|
@@ -19058,32 +19012,6 @@ ${(content || "").trim()}`.trim();
|
|
|
19058
19012
|
}
|
|
19059
19013
|
}
|
|
19060
19014
|
}
|
|
19061
|
-
if (pluginConfig.hooks?.tilth_first_guard?.enabled !== false && isExploreAgent(activeAgent)) {
|
|
19062
|
-
const tilthGuardConfig = pluginConfig.hooks?.tilth_first_guard;
|
|
19063
|
-
const command = toolInput.command ?? toolInput.cmd;
|
|
19064
|
-
try {
|
|
19065
|
-
if (isToolNamed(toolName, "bash") && command && isExplicitTilthCommand(command)) {
|
|
19066
|
-
const nextState = markTilthAttempt(tilthFirstBySession.get(sessionID));
|
|
19067
|
-
tilthFirstBySession.set(sessionID, nextState);
|
|
19068
|
-
if (tilthGuardConfig?.log === true) {
|
|
19069
|
-
await cliLog("info", formatTilthFirstGuardPass(command.trim()));
|
|
19070
|
-
}
|
|
19071
|
-
}
|
|
19072
|
-
if (isFallbackNavigationTool(toolName)) {
|
|
19073
|
-
const state = tilthFirstBySession.get(sessionID);
|
|
19074
|
-
if (shouldBlockTilthFallback(activeAgent, toolName, state)) {
|
|
19075
|
-
await cliLog("warn", formatTilthFirstGuardWarning(toolName));
|
|
19076
|
-
await showToast("@explore must call tilth before fallback tools", "warning", "CliKit Guard");
|
|
19077
|
-
blockToolExecution(formatTilthFirstGuardReason(toolName));
|
|
19078
|
-
}
|
|
19079
|
-
}
|
|
19080
|
-
} catch (error45) {
|
|
19081
|
-
if (isBlockedToolExecutionError(error45)) {
|
|
19082
|
-
throw error45;
|
|
19083
|
-
}
|
|
19084
|
-
await hookErr("tilth-first-guard", error45, { tool: toolName, sessionID, agent: activeAgent, command });
|
|
19085
|
-
}
|
|
19086
|
-
}
|
|
19087
19015
|
},
|
|
19088
19016
|
"tool.execute.after": async (input, output) => {
|
|
19089
19017
|
const toolName = input.tool;
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
# Discussion Template
|
|
2
|
+
|
|
3
|
+
Use this template when documenting clarified intent before `/create`.
|
|
4
|
+
|
|
5
|
+
**Output path:** `.opencode/memory/discussions/YYYY-MM-DD-<topic>.md`
|
|
6
|
+
|
|
7
|
+
This template is optimized for **pre-create discussion**: the report should reduce guessing for `/create`, `/research`, and `/start` by separating locked intent from unresolved technical work.
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
```markdown
|
|
12
|
+
---
|
|
13
|
+
topic: [Topic Name]
|
|
14
|
+
date: YYYY-MM-DD
|
|
15
|
+
status: draft | approved
|
|
16
|
+
mode: interactive | assumptions
|
|
17
|
+
bead_id: [optional]
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
# Discussion: [Topic]
|
|
21
|
+
|
|
22
|
+
**Goal:** [What outcome the user wants]
|
|
23
|
+
**Why now:** [Why this needs to be clarified before planning]
|
|
24
|
+
**Assumptions:** [Any assumptions made due to incomplete context, or "None"]
|
|
25
|
+
|
|
26
|
+
---
|
|
27
|
+
|
|
28
|
+
## Scope Boundary
|
|
29
|
+
|
|
30
|
+
- **In scope:** [What this discussion covers]
|
|
31
|
+
- **Out of scope:** [What is explicitly excluded]
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## Locked Decisions
|
|
36
|
+
|
|
37
|
+
### Decision 1: [Title]
|
|
38
|
+
- **Decision:** [Confirmed choice]
|
|
39
|
+
- **Why it matters:** [Why `/create` or `/research` must preserve it]
|
|
40
|
+
- **Source:** user-confirmed | prior artifact-confirmed
|
|
41
|
+
|
|
42
|
+
### Decision 2: [Title]
|
|
43
|
+
- **Decision:** [Confirmed choice]
|
|
44
|
+
- **Why it matters:** [Practical consequence]
|
|
45
|
+
- **Source:** user-confirmed | prior artifact-confirmed
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
## Confirmed Assumptions
|
|
50
|
+
|
|
51
|
+
- **Assumption:** [What was assumed]
|
|
52
|
+
- **Confirmed by:** [user / artifact / codebase pattern]
|
|
53
|
+
- **Notes:** [Any caveat]
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
## Open Questions
|
|
58
|
+
|
|
59
|
+
- **Question:** [Unresolved item]
|
|
60
|
+
- **Why unresolved:** [Reason]
|
|
61
|
+
- **Next owner:** `/create` | `/research` | user
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## Codebase Context
|
|
66
|
+
|
|
67
|
+
- **Relevant files/modules:** [Paths or components]
|
|
68
|
+
- **Existing patterns:** [Patterns worth preserving]
|
|
69
|
+
- **Reuse opportunities:** [What downstream work should reuse]
|
|
70
|
+
- **Constraints:** [Technical realities discovered locally]
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
## Canonical References
|
|
75
|
+
|
|
76
|
+
- [Internal doc, file, or prior artifact]
|
|
77
|
+
- [Another source downstream agents should read]
|
|
78
|
+
|
|
79
|
+
---
|
|
80
|
+
|
|
81
|
+
## Deferred / Later
|
|
82
|
+
|
|
83
|
+
- [Idea intentionally postponed]
|
|
84
|
+
- [Follow-up that should not expand current scope]
|
|
85
|
+
|
|
86
|
+
---
|
|
87
|
+
|
|
88
|
+
## Planning Notes
|
|
89
|
+
|
|
90
|
+
- [Specific instruction `/create` should preserve in the plan]
|
|
91
|
+
```
|
|
@@ -9,7 +9,7 @@ Use this template when saving state for session breaks.
|
|
|
9
9
|
```markdown
|
|
10
10
|
---
|
|
11
11
|
date: YYYY-MM-DD
|
|
12
|
-
phase:
|
|
12
|
+
phase: discussed | researched | planned | implementing | validating
|
|
13
13
|
branch: [git branch name]
|
|
14
14
|
bead_id: [optional]
|
|
15
15
|
---
|
|
@@ -28,7 +28,7 @@ bead_id: [optional]
|
|
|
28
28
|
|
|
29
29
|
| Type | Path | Status |
|
|
30
30
|
|------|------|--------|
|
|
31
|
-
|
|
|
31
|
+
| Discussion | `.opencode/memory/discussions/YYYY-MM-DD-topic.md` | 🧭 Reference |
|
|
32
32
|
| Plan | `.opencode/memory/plans/YYYY-MM-DD-feature.md` | ✅ Complete |
|
|
33
33
|
| Research | `.opencode/memory/research/YYYY-MM-DD-topic.md` | 📚 Reference |
|
|
34
34
|
| PRD | `.opencode/memory/prds/YYYY-MM-DD-feature.md` | ⏸️ In Review |
|
|
@@ -7,183 +7,90 @@ Use this template when creating implementation plans.
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
```markdown
|
|
10
|
-
# Implementation Plan: [Feature]
|
|
11
|
-
|
|
12
|
-
**Date:** YYYY-MM-DD
|
|
13
|
-
**Author:** [Name]
|
|
14
|
-
**Status:** Draft | Approved
|
|
15
|
-
**bead_id:** [ID]
|
|
16
|
-
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
## Overview
|
|
20
|
-
|
|
21
|
-
[Brief description of what will be built]
|
|
22
|
-
|
|
23
|
-
## References
|
|
24
|
-
|
|
25
|
-
- **Spec:** `.opencode/memory/specs/YYYY-MM-DD-descriptor.md`
|
|
26
|
-
- **PRD:** `.opencode/memory/prds/YYYY-MM-DD-feature.md` (if applicable)
|
|
27
|
-
- **Research:** `.opencode/memory/research/YYYY-MM-DD-topic.md` (if applicable)
|
|
28
|
-
|
|
29
|
-
---
|
|
30
|
-
|
|
31
|
-
## Conventions & Past Decisions
|
|
32
|
-
|
|
33
|
-
### Git Conventions
|
|
34
|
-
- **Commit format:** [e.g., conventional commits, prefix patterns]
|
|
35
|
-
- **Branch naming:** [e.g., feature/xxx, bead/B-xxx]
|
|
36
|
-
- **File organization:** [patterns observed from recent commits]
|
|
37
|
-
|
|
38
|
-
### Relevant Past Decisions
|
|
39
|
-
- [Decision from memory/handoffs that affects this plan, or "None found"]
|
|
40
|
-
|
|
41
|
-
### Learnings & Gotchas
|
|
42
|
-
- [Past learnings, blockers, workarounds from memory that apply, or "None found"]
|
|
43
|
-
|
|
44
|
-
### Prior Research
|
|
45
|
-
- [Relevant findings from .opencode/memory/research/*.md, or "None found"]
|
|
46
|
-
|
|
47
|
-
---
|
|
48
|
-
|
|
49
|
-
## Tasks
|
|
50
|
-
|
|
51
|
-
### Task 1: [Title]
|
|
52
|
-
|
|
53
|
-
| Field | Value |
|
|
54
|
-
|-------|-------|
|
|
55
|
-
| **task_id** | T-001 |
|
|
56
|
-
| **type** | task \| bug \| feature \| chore |
|
|
57
|
-
| **assignee** | build \| fe \| be \| mobile \| devops |
|
|
58
|
-
| **effort** | S \| M \| L \| XL |
|
|
59
|
-
| **priority** | P0 \| P1 \| P2 |
|
|
60
|
-
| **status** | not_started \| in_progress \| blocked \| done |
|
|
61
|
-
| **dependencies** | [T-xxx] or none |
|
|
62
|
-
|
|
63
|
-
**Description:**
|
|
64
|
-
[What needs to be done]
|
|
65
|
-
|
|
66
|
-
**Input:**
|
|
67
|
-
- [Required artifacts/context]
|
|
68
|
-
|
|
69
|
-
**Output:**
|
|
70
|
-
- [Expected deliverables]
|
|
71
|
-
- [Files to create/modify]
|
|
72
|
-
|
|
73
|
-
**Acceptance Criteria:**
|
|
74
|
-
- [ ] AC-01: [Criteria]
|
|
75
|
-
- [ ] AC-02: [Criteria]
|
|
76
|
-
|
|
77
|
-
**Boundaries:**
|
|
78
|
-
- [What NOT to do]
|
|
79
|
-
|
|
80
|
-
**Task Packet:**
|
|
81
|
-
- **packet_id:** P-T-001
|
|
82
|
-
- **goal:** [Single executable concern]
|
|
83
|
-
- **files_in_scope:**
|
|
84
|
-
- create: [`path/to/new-file.ts`]
|
|
85
|
-
- modify: [`path/to/existing.ts`]
|
|
86
|
-
- delete: []
|
|
87
|
-
- **verification_commands:**
|
|
88
|
-
- `bun run typecheck`
|
|
89
|
-
- `bun test path/to/test.ts`
|
|
90
|
-
- **risks:**
|
|
91
|
-
- [Top risk for this packet]
|
|
92
|
-
- **escalate_if:**
|
|
93
|
-
- [Verification fails twice]
|
|
94
|
-
- [A file outside scope must be edited]
|
|
95
|
-
|
|
96
|
-
---
|
|
97
|
-
|
|
98
|
-
### Task 2: [Title]
|
|
99
|
-
|
|
100
|
-
[Repeat structure]
|
|
101
|
-
|
|
102
|
-
---
|
|
103
|
-
|
|
104
|
-
## File Impact
|
|
105
|
-
|
|
106
|
-
**Files to CREATE:**
|
|
107
|
-
- `path/to/new-file.ts` — [Purpose]
|
|
108
|
-
|
|
109
|
-
**Files to MODIFY:**
|
|
110
|
-
- `path/to/existing.ts` — [Reason]
|
|
111
|
-
|
|
112
|
-
**Files to DELETE:**
|
|
113
|
-
- (none)
|
|
114
|
-
|
|
115
|
-
---
|
|
116
|
-
|
|
117
|
-
## Execution Model
|
|
118
|
-
|
|
119
|
-
- Workflow quick mode: `/create → /start → /verify → /ship`
|
|
120
|
-
- Workflow deep mode: `/create → /research → /design → /start → /verify → /ship`
|
|
121
|
-
- Execution unit: **Task Packet**
|
|
122
|
-
- Source of truth: **Beads**
|
|
123
|
-
- `/start`: execute + per-packet verify loop
|
|
124
|
-
- `/verify`: pre-ship gate (all 4 checks, SHIP_READY verdict required before `/ship`)
|
|
125
|
-
- `/ship`: commit + sync/push landed changes in the shared checkout; `/pr` is an explicit exception path
|
|
126
|
-
|
|
127
|
-
---
|
|
128
|
-
|
|
129
|
-
## Dependencies
|
|
130
|
-
|
|
131
|
-
```mermaid
|
|
132
|
-
graph TD
|
|
133
|
-
T001[T-001: Title] --> T002[T-002: Title]
|
|
134
|
-
T002 --> T003[T-003: Title]
|
|
135
|
-
T001 --> T003
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
---
|
|
139
|
-
|
|
140
|
-
## Effort Summary
|
|
141
|
-
|
|
142
|
-
| Task | Effort | Priority |
|
|
143
|
-
|------|--------|----------|
|
|
144
|
-
| T-001 | S | P0 |
|
|
145
|
-
| T-002 | M | P0 |
|
|
146
|
-
| T-003 | S | P1 |
|
|
147
|
-
|
|
148
|
-
**Total Estimated Effort:** [X days/weeks]
|
|
149
|
-
|
|
150
|
-
---
|
|
151
|
-
|
|
152
|
-
## Risk Assessment
|
|
153
|
-
|
|
154
|
-
| Risk | Probability | Impact | Mitigation |
|
|
155
|
-
|------|-------------|--------|------------|
|
|
156
|
-
| [Risk 1] | L/M/H | L/M/H | [Mitigation] |
|
|
157
|
-
|
|
158
|
-
---
|
|
159
|
-
|
|
160
|
-
## Quick Mode Eligibility
|
|
161
|
-
|
|
162
|
-
Tasks eligible for Quick Mode (no full plan needed):
|
|
163
|
-
- [ ] T-001 (S, ≤3 files, no security/db/api)
|
|
164
|
-
|
|
165
|
-
## Packet Checklist
|
|
166
|
-
|
|
167
|
-
- [ ] Every task has a packet_id
|
|
168
|
-
- [ ] Every packet stays within 1–3 files
|
|
169
|
-
- [ ] Every packet has executable verification commands
|
|
170
|
-
- [ ] Every packet has an escalate_if clause
|
|
171
|
-
- [ ] File Impact matches all packet scopes
|
|
172
|
-
|
|
173
10
|
---
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
11
|
+
phase: XX-name
|
|
12
|
+
plan: NN
|
|
13
|
+
type: execute
|
|
14
|
+
wave: N
|
|
15
|
+
depends_on: []
|
|
16
|
+
files_modified: []
|
|
17
|
+
autonomous: true
|
|
18
|
+
requirements: []
|
|
19
|
+
must_haves:
|
|
20
|
+
truths: []
|
|
21
|
+
artifacts: []
|
|
22
|
+
key_links: []
|
|
182
23
|
---
|
|
183
24
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
25
|
+
<objective>
|
|
26
|
+
[What this plan accomplishes]
|
|
27
|
+
</objective>
|
|
28
|
+
|
|
29
|
+
<context>
|
|
30
|
+
[Relevant context files and source references]
|
|
31
|
+
</context>
|
|
32
|
+
|
|
33
|
+
<tasks>
|
|
34
|
+
<task type="auto">
|
|
35
|
+
<packet_id>P-T001</packet_id>
|
|
36
|
+
<task_id>T-001</task_id>
|
|
37
|
+
<name>Task 1: [Action-oriented name]</name>
|
|
38
|
+
<goal>[One executable concern]</goal>
|
|
39
|
+
<files_in_scope>
|
|
40
|
+
<create>[]</create>
|
|
41
|
+
<modify>["path/to/file.ext"]</modify>
|
|
42
|
+
<delete>[]</delete>
|
|
43
|
+
</files_in_scope>
|
|
44
|
+
<dependencies>[]</dependencies>
|
|
45
|
+
<action>[Specific implementation]</action>
|
|
46
|
+
<acceptance_criteria>
|
|
47
|
+
<criterion cmd="bun test path/to/test.ts">exits 0</criterion>
|
|
48
|
+
<criterion cmd="lsp_diagnostics path/to/file.ext">zero errors</criterion>
|
|
49
|
+
</acceptance_criteria>
|
|
50
|
+
<verification_commands>
|
|
51
|
+
<command>bun run typecheck</command>
|
|
52
|
+
<command>bun test path/to/test.ts</command>
|
|
53
|
+
</verification_commands>
|
|
54
|
+
<risks>
|
|
55
|
+
<risk>[Top risk for this packet]</risk>
|
|
56
|
+
</risks>
|
|
57
|
+
<escalate_if>
|
|
58
|
+
<condition>Verification fails after 2 attempts</condition>
|
|
59
|
+
<condition>Implementation requires file outside files_in_scope</condition>
|
|
60
|
+
</escalate_if>
|
|
61
|
+
<context_refs>
|
|
62
|
+
<discussion_paths>[]</discussion_paths>
|
|
63
|
+
<plan_path>.opencode/memory/plans/YYYY-MM-DD-<feature>.md</plan_path>
|
|
64
|
+
<research_paths>[]</research_paths>
|
|
65
|
+
</context_refs>
|
|
66
|
+
</task>
|
|
67
|
+
</tasks>
|
|
68
|
+
|
|
69
|
+
<file_impact>
|
|
70
|
+
<create>[]</create>
|
|
71
|
+
<modify>["path/to/file.ext"]</modify>
|
|
72
|
+
<delete>[]</delete>
|
|
73
|
+
</file_impact>
|
|
74
|
+
|
|
75
|
+
<dag>
|
|
76
|
+
<wave number="1">P-T001</wave>
|
|
77
|
+
</dag>
|
|
78
|
+
|
|
79
|
+
<boundaries>
|
|
80
|
+
<always>[Required invariants and constraints]</always>
|
|
81
|
+
<ask_first>[Changes that require explicit approval]</ask_first>
|
|
82
|
+
<never>[Out-of-scope or forbidden changes]</never>
|
|
83
|
+
</boundaries>
|
|
84
|
+
|
|
85
|
+
<out_of_scope>
|
|
86
|
+
[Explicitly excluded work]
|
|
87
|
+
</out_of_scope>
|
|
88
|
+
|
|
89
|
+
<verification>
|
|
90
|
+
[Overall phase checks]
|
|
91
|
+
</verification>
|
|
92
|
+
|
|
93
|
+
<success_criteria>
|
|
94
|
+
[Measurable completion]
|
|
95
|
+
</success_criteria>
|
|
189
96
|
```
|
|
@@ -4,6 +4,8 @@ Use this template when documenting research findings.
|
|
|
4
4
|
|
|
5
5
|
**Output path:** `.opencode/memory/research/YYYY-MM-DD-<topic>.md`
|
|
6
6
|
|
|
7
|
+
This template is optimized for **pre-plan research**: the report should reduce guessing for Plan and Build, not just summarize information.
|
|
8
|
+
|
|
7
9
|
---
|
|
8
10
|
|
|
9
11
|
```markdown
|
|
@@ -21,25 +23,35 @@ bead_id: [optional]
|
|
|
21
23
|
# Research: [Topic]
|
|
22
24
|
|
|
23
25
|
**Question:** [Original research question]
|
|
26
|
+
**Planning Goal:** [What planning or implementation decision this report should unblock]
|
|
27
|
+
**Assumptions:** [Any assumption made because context was incomplete, or "None"]
|
|
24
28
|
|
|
25
29
|
---
|
|
26
30
|
|
|
27
31
|
## Summary
|
|
28
32
|
|
|
29
|
-
[2-
|
|
33
|
+
[2-4 sentence answer that directly helps planning or execution]
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Research Brief
|
|
38
|
+
|
|
39
|
+
- **Decision gaps:** [Which unknowns this research was meant to resolve]
|
|
40
|
+
- **Constraints:** [Language, framework, platform, architecture, version limits]
|
|
41
|
+
- **Research scope:** [What was investigated and what was intentionally excluded]
|
|
30
42
|
|
|
31
43
|
---
|
|
32
44
|
|
|
33
45
|
## Key Findings
|
|
34
46
|
|
|
35
47
|
### Finding 1: [Title]
|
|
36
|
-
[Details]
|
|
48
|
+
[VERIFIED]/[CITED]/[ASSUMED] [Details and why this matters]
|
|
37
49
|
|
|
38
50
|
### Finding 2: [Title]
|
|
39
|
-
[Details]
|
|
51
|
+
[VERIFIED]/[CITED]/[ASSUMED] [Details and why this matters]
|
|
40
52
|
|
|
41
53
|
### Finding 3: [Title]
|
|
42
|
-
[Details]
|
|
54
|
+
[VERIFIED]/[CITED]/[ASSUMED] [Details and why this matters]
|
|
43
55
|
|
|
44
56
|
---
|
|
45
57
|
|
|
@@ -76,10 +88,24 @@ bead_id: [optional]
|
|
|
76
88
|
|
|
77
89
|
---
|
|
78
90
|
|
|
79
|
-
##
|
|
91
|
+
## Planning Impact
|
|
92
|
+
|
|
93
|
+
- [How this research should influence the plan or packet boundaries]
|
|
94
|
+
- [What Build should avoid or sequence carefully]
|
|
95
|
+
- [Any dependency, migration, or scope implications]
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
## Verification Hooks
|
|
100
|
+
|
|
101
|
+
- [ ] [Targeted test, command, or assertion to run during implementation]
|
|
102
|
+
- [ ] [Another implementation-time check]
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
## Conflicting Evidence (if any)
|
|
80
107
|
|
|
81
|
-
- [
|
|
82
|
-
- [ ] [Test with specific scenario]
|
|
108
|
+
- [Source A says X, source B says Y, and the practical implication]
|
|
83
109
|
|
|
84
110
|
---
|
|
85
111
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Review Template
|
|
2
2
|
|
|
3
|
-
Use this template when reviewing code, PRDs,
|
|
3
|
+
Use this template when reviewing code, PRDs, or plans.
|
|
4
4
|
|
|
5
5
|
**Output path:** `.opencode/memory/reviews/YYYY-MM-DD-<subject>-review.md`
|
|
6
6
|
|
|
@@ -8,7 +8,7 @@ Use this template when reviewing code, PRDs, specs, or plans.
|
|
|
8
8
|
|
|
9
9
|
```markdown
|
|
10
10
|
---
|
|
11
|
-
type: Code | PRD |
|
|
11
|
+
type: Code | PRD | Plan | Security
|
|
12
12
|
date: YYYY-MM-DD
|
|
13
13
|
reviewer: [Name/Agent]
|
|
14
14
|
artifact: [Path to reviewed artifact]
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clikit-plugin",
|
|
3
|
-
"version": "0.3.
|
|
4
|
-
"description": "OpenCode plugin — 7 agents,
|
|
3
|
+
"version": "0.3.11",
|
|
4
|
+
"description": "OpenCode plugin — 7 agents, 14 commands, 26 skills, 11 hooks",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
@@ -15,7 +15,7 @@ Request review after: major features, significant refactors, before merge, when
|
|
|
15
15
|
|------|---------|
|
|
16
16
|
| Diff range | `a1b2c3d..e4f5g6h` |
|
|
17
17
|
| What changed | "Added JWT auth with refresh tokens" |
|
|
18
|
-
|
|
|
18
|
+
| Plan ref | `.opencode/memory/plans/auth.md` |
|
|
19
19
|
| Known gaps | "Edge case X not handled yet" |
|
|
20
20
|
|
|
21
21
|
## Dispatch
|
|
@@ -23,7 +23,7 @@ Request review after: major features, significant refactors, before merge, when
|
|
|
23
23
|
```
|
|
24
24
|
@review: review changes from <sha>..<sha>
|
|
25
25
|
Context: <what was built>
|
|
26
|
-
|
|
26
|
+
Plan: <path>
|
|
27
27
|
Known issues: <list or none>
|
|
28
28
|
```
|
|
29
29
|
|
|
@@ -14,7 +14,7 @@ DISCOVER → PLAN → IMPLEMENT → VERIFY → COMPLETE
|
|
|
14
14
|
| Phase | Gate (must pass before advancing) |
|
|
15
15
|
|-------|-----------------------------------|
|
|
16
16
|
| DISCOVER | Problem statement written, success criteria defined |
|
|
17
|
-
| PLAN | User approves
|
|
17
|
+
| PLAN | User approves plan |
|
|
18
18
|
| IMPLEMENT | All planned tasks checked off |
|
|
19
19
|
| VERIFY | typecheck + tests + lint + build all pass |
|
|
20
20
|
| COMPLETE | Changes landed on default branch / deployed |
|
|
@@ -23,8 +23,10 @@ DISCOVER → PLAN → IMPLEMENT → VERIFY → COMPLETE
|
|
|
23
23
|
|
|
24
24
|
| Mode | Commands |
|
|
25
25
|
|------|----------|
|
|
26
|
-
| Quick | `/create` → `/start` → `/verify` → `/ship` |
|
|
27
|
-
| Deep (
|
|
26
|
+
| Quick | `/discuss` → `/create` → `/start` → `/verify` → `/ship` |
|
|
27
|
+
| Deep (UI) | `/discuss` → `/create` → `/design` → `/start` → `/verify` → `/ship` |
|
|
28
|
+
|
|
29
|
+
`/create` includes a mandatory pre-plan research pass via `@research` before it finalizes the plan. `/research` remains available as an optional standalone command when the user wants a dedicated evidence pass.
|
|
28
30
|
|
|
29
31
|
## Enforcement
|
|
30
32
|
|
|
@@ -37,5 +39,5 @@ DISCOVER → PLAN → IMPLEMENT → VERIFY → COMPLETE
|
|
|
37
39
|
|
|
38
40
|
- Implementing without a plan
|
|
39
41
|
- Marking COMPLETE with failing `/verify` gates
|
|
40
|
-
- Moving forward without user approval on
|
|
42
|
+
- Moving forward without user approval on the plan
|
|
41
43
|
- Running `/ship` before SHIP_READY
|