@jspg-ai/coding-bb 0.0.3-beta.30 → 0.0.3-beta.32
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/cbb/lib/external/index.js +228 -0
- package/cbb/lib/install/claude-code.js +3 -3
- package/cbb/lib/install/init.js +125 -30
- package/cbb/lib/install/minimax.js +2 -2
- package/cbb/lib/install/tool-selection.js +8 -30
- package/cbb/worktrees/skills/cbb-local-mode/SKILL.md +1 -1
- package/cbb/worktrees/skills/cbb-worktree-init/SKILL.md +1 -1
- package/cbb/worktrees/skills/cbb-worktree-push/SKILL.md +32 -40
- package/config/upstream-mirrors.json +5 -0
- package/external/frontend-design/.version +6 -0
- package/external/frontend-design/LICENSE.txt +177 -0
- package/external/frontend-design/SKILL.md +71 -0
- package/openspec/.version +2 -2
- package/openspec/commands/archive.md +15 -8
- package/openspec/commands/bulk-archive.md +13 -6
- package/openspec/commands/continue.md +0 -1
- package/openspec/commands/explore.md +1 -1
- package/openspec/commands/ff.md +1 -1
- package/openspec/commands/onboard.md +9 -4
- package/openspec/commands/update.md +11 -5
- package/openspec/commands/verify.md +57 -26
- package/openspec/skills/openspec-apply-change/SKILL.md +1 -1
- package/openspec/skills/openspec-archive-change/SKILL.md +16 -9
- package/openspec/skills/openspec-bulk-archive-change/SKILL.md +14 -7
- package/openspec/skills/openspec-continue-change/SKILL.md +1 -2
- package/openspec/skills/openspec-explore/SKILL.md +2 -2
- package/openspec/skills/openspec-ff-change/SKILL.md +2 -2
- package/openspec/skills/openspec-new-change/SKILL.md +1 -1
- package/openspec/skills/openspec-onboard/SKILL.md +10 -5
- package/openspec/skills/openspec-propose/SKILL.md +1 -1
- package/openspec/skills/openspec-sync-specs/SKILL.md +1 -1
- package/openspec/skills/openspec-update-change/SKILL.md +12 -6
- package/openspec/skills/openspec-verify-change/SKILL.md +59 -27
- package/package.json +3 -2
- package/superpowers/.version +3 -3
- package/superpowers/skills/writing-plans/SKILL.md +32 -20
- package/superpowers/skills/writing-plans/plan-document-reviewer-prompt.md +0 -49
|
@@ -7,7 +7,7 @@ compatibility: Requires openspec CLI.
|
|
|
7
7
|
metadata:
|
|
8
8
|
author: openspec
|
|
9
9
|
version: "1.0"
|
|
10
|
-
generatedBy: "1.13.
|
|
10
|
+
generatedBy: "1.13.2"
|
|
11
11
|
---
|
|
12
12
|
|
|
13
13
|
Verify that an implementation matches the change artifacts (specs, tasks, design).
|
|
@@ -36,7 +36,7 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
36
36
|
- Auto-select if only one active change exists
|
|
37
37
|
- If ambiguous, run `openspec list --json` to get available changes and ask the user to select one
|
|
38
38
|
|
|
39
|
-
When prompting, show changes
|
|
39
|
+
When prompting, show all active changes returned by the list, including changes with `status: "no-tasks"`.
|
|
40
40
|
Include the schema used for each change if available.
|
|
41
41
|
Mark changes with incomplete tasks as "(In Progress)".
|
|
42
42
|
|
|
@@ -57,7 +57,9 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
57
57
|
openspec instructions apply --change "<name>" --json
|
|
58
58
|
```
|
|
59
59
|
|
|
60
|
-
This returns the change directory
|
|
60
|
+
This returns the change directory, `contextFiles` (artifact ID -> array of concrete file paths), `taskTrackingConfigured`, and top-level `tasks` and `progress` aggregated from every concrete file matched by the schema's `apply.tracks` configuration that could be read. Read all available artifacts from `contextFiles`.
|
|
61
|
+
|
|
62
|
+
Treat apply `state` and `instruction` as context, not a verification verdict. Do not implement tasks or archive the change during verification.
|
|
61
63
|
|
|
62
64
|
4. **Initialize verification report structure**
|
|
63
65
|
|
|
@@ -68,32 +70,59 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
68
70
|
|
|
69
71
|
Each dimension can have CRITICAL, WARNING, or SUGGESTION issues.
|
|
70
72
|
|
|
73
|
+
Verification is advisory. Respect intentional omissions such as `skip_specs: true`, optional design documents, and schemas without task tracking. Do not require or invent optional or intentionally omitted artifacts to obtain a clean report. `Not verified` describes a limit of this report, not a new archive prerequisite. Archive retains its own checks and user-confirmation behavior.
|
|
74
|
+
|
|
75
|
+
Mark checks the schema does not define, or artifacts the status reports as intentionally skipped, as **Not applicable**. The correctness checks of a change whose readable delta specs contain REMOVED or RENAMED requirements but no ADDED or MODIFIED requirements are also **Not applicable** (see step 6). Exclude them from skipped-check counts and the archive-readiness assessment. Reserve **Not verified** for applicable checks whose evidence is missing or unusable.
|
|
76
|
+
|
|
77
|
+
If only task evidence is available for applicable checks, verify task completion only and mark the remaining applicable checks, including **Code Pattern Consistency**, as not verified with the reason "Only task evidence available".
|
|
78
|
+
|
|
79
|
+
If artifacts cannot be read or contain no usable requirements, scenarios, or design decisions, mark the affected checks as not verified with the specific reason. Continue checks supported by the remaining evidence, but a partially checked input set is not a fully verified check. Missing requirements affect Spec Coverage and Requirement Implementation Mapping; missing scenarios affect Scenario Coverage; missing design decisions affect Design Adherence.
|
|
80
|
+
|
|
71
81
|
5. **Verify Completeness**
|
|
72
82
|
|
|
73
83
|
**Task Completion**:
|
|
74
|
-
- If `
|
|
75
|
-
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
-
|
|
79
|
-
- If
|
|
80
|
-
- Add CRITICAL issue for each incomplete task
|
|
84
|
+
- If `taskTrackingConfigured` is false, report **Task Completion** as not applicable. Do not treat empty `tasks` as missing evidence.
|
|
85
|
+
- Otherwise, use the top-level `tasks` and `progress` fields. They already aggregate every readable concrete file matched by `apply.tracks`, regardless of the tracked artifact's ID; do not infer tracking from a `contextFiles` key.
|
|
86
|
+
- If `unavailableTrackingFiles` is nonempty, mark **Task Completion** as not verified and include every unavailable path and reason. Continue using any readable task evidence, but do not infer completion from the partial `tasks` and `progress` fields.
|
|
87
|
+
- If `taskTrackingConfigured` is true and `tasks` is empty, mark **Task Completion** as not verified and record the reason from apply `state` and `instruction`. Nonzero totals alone do not establish evaluable task descriptions.
|
|
88
|
+
- Report complete vs total tasks from `progress`.
|
|
89
|
+
- If `progress.remaining` is greater than 0:
|
|
90
|
+
- Add CRITICAL issue for each listed incomplete task. If the remaining count exceeds the listed incomplete tasks, also report the incomplete checkboxes without descriptions and recommend adding descriptions and completing them. Do not infer completion from the listed tasks alone.
|
|
81
91
|
- Recommendation: "Complete task: <description>" or "Mark as done if already implemented"
|
|
82
92
|
|
|
83
93
|
**Spec Coverage**:
|
|
94
|
+
- If status marks the spec artifact skipped by `skip_specs: true`, or the schema defines no spec artifact, report the spec-dependent checks as not applicable.
|
|
95
|
+
- Otherwise, `contextFiles` is keyed by artifact id, and artifact ids come from the active schema. If `contextFiles.specs` is absent or empty, mark **Spec Coverage**, **Requirement Implementation Mapping**, and **Scenario Coverage** as not verified; do not treat any of them as clean.
|
|
84
96
|
- If delta specs exist in `contextFiles.specs`:
|
|
85
|
-
- Extract all requirements (marked with "### Requirement:")
|
|
86
|
-
- For each requirement:
|
|
97
|
+
- Extract all requirements (marked with "### Requirement:", or listed as `FROM:`/`TO:` pairs under `## RENAMED Requirements`) and note the delta section each one sits under: `## ADDED`, `## MODIFIED`, `## REMOVED`, or `## RENAMED Requirements`. The section decides what the check looks for.
|
|
98
|
+
- For each ADDED or MODIFIED requirement (for MODIFIED, check the text in the delta, not the old wording):
|
|
87
99
|
- Search codebase for keywords related to the requirement
|
|
88
100
|
- Assess if implementation likely exists
|
|
89
|
-
- If requirements appear unimplemented:
|
|
101
|
+
- If ADDED or MODIFIED requirements appear unimplemented:
|
|
90
102
|
- Add CRITICAL issue: "Requirement not found: <requirement name>"
|
|
91
103
|
- Recommendation: "Implement requirement X: <description>"
|
|
104
|
+
- For each REMOVED requirement, the change asks for the behavior to be gone, so invert the check:
|
|
105
|
+
- Search codebase for the removed behavior. Matches in `openspec/` artifacts or docs, or in code that serves only the Migration note or an ADDED requirement, are not evidence by themselves. Report any code path that still delivers the removed behavior, including one shared with an ADDED requirement.
|
|
106
|
+
- Finding no implementation is the expected result. Never report a REMOVED requirement as "Requirement not found" or recommend implementing it.
|
|
107
|
+
- If the behavior is still present:
|
|
108
|
+
- Add CRITICAL issue: "Removed requirement still implemented: <requirement name>"
|
|
109
|
+
- Recommendation: "Remove the remaining implementation at <file>:<lines>, following the requirement's Migration note if it has one"
|
|
110
|
+
- For each RENAMED entry (`FROM:`/`TO:`), the name changes but the behavior stays, so check the TO requirement for that unchanged behavior:
|
|
111
|
+
- Do not report the FROM name as missing, and do not require code symbols, identifiers, or file names to be renamed.
|
|
112
|
+
- If the TO name also appears under MODIFIED, its behavior is checked there against the MODIFIED text; skip it here.
|
|
113
|
+
- Otherwise, read the baseline requirement in the main spec at `<planningHome.root>/openspec/specs/<capability-path>/spec.md`, using the same capability path as the delta spec: the requirement under the FROM name, or under the TO name only when the FROM name is absent because the main spec is already synced. Its body and scenarios are the evidence for the behavior the TO requirement keeps.
|
|
114
|
+
- Search codebase for that behavior and assess if it is still implemented.
|
|
115
|
+
- If it appears unimplemented:
|
|
116
|
+
- Add CRITICAL issue: "Renamed requirement not found: <TO name>"
|
|
117
|
+
- Recommendation: "Restore the behavior of <TO name> (renamed from <FROM name>); a rename must not change behavior"
|
|
118
|
+
- If the baseline requirement cannot be found or read, mark **Spec Coverage** as not verified for that entry with the reason. Never count an unchecked rename as passing.
|
|
92
119
|
|
|
93
120
|
6. **Verify Correctness**
|
|
94
121
|
|
|
122
|
+
If the delta specs are readable and contain at least one REMOVED or RENAMED requirement but no ADDED or MODIFIED requirements (the change only removes or renames requirements), report **Requirement Implementation Mapping** and **Scenario Coverage** as **Not applicable**. The REMOVED and RENAMED checks under Spec Coverage are the evidence for such a change (each RENAMED entry is checked there against its baseline behavior), so do not mark these two checks as not verified. A delta spec with no parseable requirements at all is unusable evidence, not a removal-only change: mark these checks as not verified.
|
|
123
|
+
|
|
95
124
|
**Requirement Implementation Mapping**:
|
|
96
|
-
- For each requirement from delta specs:
|
|
125
|
+
- For each ADDED or MODIFIED requirement from delta specs (REMOVED entries, and RENAMED entries without a MODIFIED block, were settled under Spec Coverage):
|
|
97
126
|
- Search codebase for implementation evidence
|
|
98
127
|
- If found, note file paths and line ranges
|
|
99
128
|
- Assess if implementation matches requirement intent
|
|
@@ -102,26 +131,29 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
102
131
|
- Recommendation: "Review <file>:<lines> against requirement X"
|
|
103
132
|
|
|
104
133
|
**Scenario Coverage**:
|
|
105
|
-
- For each scenario in delta specs (marked with "#### Scenario:"):
|
|
134
|
+
- For each scenario under an ADDED or MODIFIED requirement in delta specs (marked with "#### Scenario:"):
|
|
106
135
|
- Check if conditions are handled in code
|
|
107
136
|
- Check if tests exist covering the scenario
|
|
108
137
|
- If scenario appears uncovered:
|
|
109
138
|
- Add WARNING: "Scenario not covered: <scenario name>"
|
|
110
139
|
- Recommendation: "Add test or implementation for scenario: <description>"
|
|
140
|
+
- Skip scenarios under a REMOVED requirement; that behavior is meant to be gone.
|
|
111
141
|
|
|
112
142
|
7. **Verify Coherence**
|
|
113
143
|
|
|
114
144
|
**Design Adherence**:
|
|
145
|
+
- If the schema defines no design artifact, report **Design Adherence** as not applicable.
|
|
115
146
|
- If `contextFiles.design` exists:
|
|
116
147
|
- Extract key decisions (look for sections like "Decision:", "Approach:", "Architecture:")
|
|
117
148
|
- Verify implementation follows those decisions
|
|
118
149
|
- If contradiction detected:
|
|
119
150
|
- Add WARNING: "Design decision not followed: <decision>"
|
|
120
151
|
- Recommendation: "Update implementation or revise design.md to match reality"
|
|
121
|
-
-
|
|
152
|
+
- Otherwise, if `contextFiles.design` is absent or empty: mark **Design Adherence** as not verified. With other supporting artifacts, **Code Pattern Consistency** still runs; the task-only case remains limited to task completion.
|
|
122
153
|
|
|
123
154
|
**Code Pattern Consistency**:
|
|
124
|
-
-
|
|
155
|
+
- If implementation changes cannot be identified, mark **Code Pattern Consistency** as not verified and explain the missing evidence.
|
|
156
|
+
- Otherwise, review new code for consistency with project patterns
|
|
125
157
|
- Check file naming, directory structure, coding style
|
|
126
158
|
- If significant deviations found:
|
|
127
159
|
- Add SUGGESTION: "Code pattern deviation: <details>"
|
|
@@ -141,11 +173,15 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
141
173
|
| Coherence | Followed/Issues |
|
|
142
174
|
```
|
|
143
175
|
|
|
176
|
+
In each Status cell, report the results of checks that ran and `Not verified (<reason>)` for every skipped check. If all checks in a dimension were skipped, start the cell with `Not verified`. Never score a skipped check as passing. Treat every not verified or partially verified check as skipped in the final assessment. Count only ADDED and MODIFIED requirements in N, and report REMOVED and RENAMED requirements separately (for example, "1 removal confirmed, 1 rename verified"). For a change that only removes or renames requirements, the Correctness cell reads `Not applicable (no ADDED or MODIFIED requirements)`.
|
|
177
|
+
|
|
144
178
|
**Issues by Priority**:
|
|
145
179
|
|
|
146
180
|
1. **CRITICAL** (Must fix before archive):
|
|
147
181
|
- Incomplete tasks
|
|
148
182
|
- Missing requirement implementations
|
|
183
|
+
- Removed requirements still implemented
|
|
184
|
+
- Renamed requirements whose behavior is no longer implemented
|
|
149
185
|
- Each with specific, actionable recommendation
|
|
150
186
|
|
|
151
187
|
2. **WARNING** (Should fix):
|
|
@@ -159,9 +195,12 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
159
195
|
- Each with specific recommendation
|
|
160
196
|
|
|
161
197
|
**Final Assessment**:
|
|
162
|
-
- If CRITICAL issues: "X critical issue(s) found. Fix before archiving."
|
|
163
|
-
- If
|
|
164
|
-
- If
|
|
198
|
+
- If CRITICAL issues: "X critical issue(s) found. Fix before archiving." If any check was skipped, also name every skipped check and its reason.
|
|
199
|
+
- If no CRITICAL issues, one or more warnings, and no checks were skipped: "No critical issues. Y warning(s) to consider. Ready for archive (with noted improvements)."
|
|
200
|
+
- If only suggestions and no checks were skipped: "No critical issues or warnings. Z suggestion(s) to consider. Ready for archive (with noted improvements)."
|
|
201
|
+
- If no issues and no checks were skipped: "All checks passed. Ready for archive."
|
|
202
|
+
- If any check was skipped and there are no CRITICAL issues: do not claim readiness. Say "No critical issues found in the checks that ran. <check(s)> not verified: <reason>." Include the warning count when nonzero.
|
|
203
|
+
- Include the suggestion count when nonzero in every final assessment.
|
|
165
204
|
|
|
166
205
|
**Verification Heuristics**
|
|
167
206
|
|
|
@@ -171,13 +210,6 @@ In both branches, never create the root as a side effect: do not run `openspec i
|
|
|
171
210
|
- **False Positives**: When uncertain, prefer SUGGESTION over WARNING, WARNING over CRITICAL
|
|
172
211
|
- **Actionability**: Every issue must have a specific recommendation with file/line references where applicable
|
|
173
212
|
|
|
174
|
-
**Graceful Degradation**
|
|
175
|
-
|
|
176
|
-
- If only tasks.md exists: verify task completion only, skip spec/design checks
|
|
177
|
-
- If tasks + specs exist: verify completeness and correctness, skip design
|
|
178
|
-
- If full artifacts: verify all three dimensions
|
|
179
|
-
- Always note which checks were skipped and why
|
|
180
|
-
|
|
181
213
|
**Output Format**
|
|
182
214
|
|
|
183
215
|
Use clear markdown with:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jspg-ai/coding-bb",
|
|
3
|
-
"version": "0.0.3-beta.
|
|
3
|
+
"version": "0.0.3-beta.32",
|
|
4
4
|
"description": "整合业界热门且高价值的工具、框架与技能,为 AI CODING AGENT 提供统一的行为准则与工作流,辅助开发者将需求高效落地为符合规范的代码",
|
|
5
5
|
"main": "cbb/lib/install/init.js",
|
|
6
6
|
"bin": {
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
"openspec/",
|
|
13
13
|
"config/",
|
|
14
14
|
"superpowers/",
|
|
15
|
+
"external/",
|
|
15
16
|
"!**/__pycache__/",
|
|
16
17
|
"!**/*.pyc",
|
|
17
18
|
"!**/*.pyo"
|
|
@@ -19,7 +20,7 @@
|
|
|
19
20
|
"scripts": {
|
|
20
21
|
"sync:shared": "node scripts/sync-shared.js",
|
|
21
22
|
"pretest": "node scripts/sync-shared.js --check",
|
|
22
|
-
"test": "node test/lib/install/cleanup.test.js && node test/lib/utils/settings.test.js && node test/lib/utils/gitignore.test.js && node test/lib/utils/githook.test.js && node test/lib/utils/version.test.js && node test/lib/install/workspaces.test.js && node test/lib/utils/checkbox.test.js && node test/lib/utils/output.test.js && node test/lib/install/cli-help.test.js && node test/lib/install/adapters.test.js && node test/lib/install/tool-selection.test.js && node test/lib/install/agents-nav.test.js && node test/lib/install/command-skill.test.js && node test/lib/utils/plugin-hook.test.js && node test/lib/wiki/wiki-publish.test.js && node test/lib/wiki/wiki-parse-args.test.js && node test/lib/wiki/wiki-split.test.js && node test/lib/superpowers/superpowers.test.js && node test/worktrees/push-branches.test.js && node test/worktrees/commit-worktrees.test.js && node test/worktrees/push-worktrees.test.js && node test/worktrees/check-env-deep.test.js && node test/worktrees/create-worktrees.test.js && node test/worktrees/make-mr-urls.test.js && node test/lib/install/setup-decision.test.js && node test/lib/openspec/protected-paths.test.js"
|
|
23
|
+
"test": "node test/lib/install/cleanup.test.js && node test/lib/utils/settings.test.js && node test/lib/utils/gitignore.test.js && node test/lib/utils/githook.test.js && node test/lib/utils/version.test.js && node test/lib/install/workspaces.test.js && node test/lib/utils/checkbox.test.js && node test/lib/utils/output.test.js && node test/lib/install/cli-help.test.js && node test/lib/install/adapters.test.js && node test/lib/install/tool-selection.test.js && node test/lib/install/agents-nav.test.js && node test/lib/install/command-skill.test.js && node test/lib/utils/plugin-hook.test.js && node test/lib/wiki/wiki-publish.test.js && node test/lib/wiki/wiki-parse-args.test.js && node test/lib/wiki/wiki-split.test.js && node test/lib/superpowers/superpowers.test.js && node test/lib/external/external.test.js && node test/worktrees/push-branches.test.js && node test/worktrees/commit-worktrees.test.js && node test/worktrees/push-worktrees.test.js && node test/worktrees/check-env-deep.test.js && node test/worktrees/create-worktrees.test.js && node test/worktrees/make-mr-urls.test.js && node test/lib/install/setup-decision.test.js && node test/lib/openspec/protected-paths.test.js"
|
|
23
24
|
},
|
|
24
25
|
"keywords": [
|
|
25
26
|
"cbb",
|
package/superpowers/.version
CHANGED
|
@@ -7,9 +7,7 @@ description: Use when you have a spec or requirements for a multi-step task, bef
|
|
|
7
7
|
|
|
8
8
|
## Overview
|
|
9
9
|
|
|
10
|
-
Write
|
|
11
|
-
|
|
12
|
-
Assume they are a skilled developer, but know almost nothing about our toolset or problem domain. Assume they don't know good test design very well.
|
|
10
|
+
Write implementation plans for an engineer who has not seen this codebase or this spec. Assume they write idiomatic code in the project's language once they know the exact interface and the exact test, and that they will make a reasonable choice wherever the plan leaves one open. What they cannot know is what you decided: which files, which names and signatures, which values from the spec, which tests prove each task. Document those. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits.
|
|
13
11
|
|
|
14
12
|
**Announce at start:** "I'm using the writing-plans skill to create the implementation plan."
|
|
15
13
|
|
|
@@ -42,9 +40,9 @@ deliverable needs them; split only where a reviewer could meaningfully
|
|
|
42
40
|
reject one task while approving its neighbor. Each task ends with an
|
|
43
41
|
independently testable deliverable.
|
|
44
42
|
|
|
45
|
-
##
|
|
43
|
+
## Step Granularity
|
|
46
44
|
|
|
47
|
-
**Each step is one action
|
|
45
|
+
**Each step is one action with a checkable result:**
|
|
48
46
|
- "Write the failing test" - step
|
|
49
47
|
- "Run it to make sure it fails" - step
|
|
50
48
|
- "Implement the minimal code to make the test pass" - step
|
|
@@ -120,12 +118,11 @@ def test_specific_behavior():
|
|
|
120
118
|
Run: `pytest tests/path/test.py::test_name -v`
|
|
121
119
|
Expected: FAIL with "function not defined"
|
|
122
120
|
|
|
123
|
-
- [ ] **Step 3:
|
|
121
|
+
- [ ] **Step 3: Implement `function(input: InputType) -> ResultType` in `exact/path/to/file.py`**
|
|
124
122
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
```
|
|
123
|
+
One line on the approach when the signature and the test leave a choice
|
|
124
|
+
(which library call, which data structure); a code block only for an
|
|
125
|
+
algorithm they do not determine.
|
|
129
126
|
|
|
130
127
|
- [ ] **Step 4: Run test to verify it passes**
|
|
131
128
|
|
|
@@ -140,15 +137,28 @@ git commit -m "feat: add specific feature"
|
|
|
140
137
|
```
|
|
141
138
|
````
|
|
142
139
|
|
|
143
|
-
##
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
-
|
|
150
|
-
|
|
151
|
-
-
|
|
140
|
+
## What a Step Contains
|
|
141
|
+
|
|
142
|
+
A step is done when the implementer can write exactly one reasonable thing
|
|
143
|
+
from it. That is the whole requirement: unambiguous, not complete. Each kind
|
|
144
|
+
of step carries what makes it unambiguous and nothing more:
|
|
145
|
+
|
|
146
|
+
- **A test step:** the test's name and its assertions, as code, with the
|
|
147
|
+
spec's exact values in them.
|
|
148
|
+
- **A code step:** the exact signature (name, parameters, return type), the
|
|
149
|
+
file it lives in, and the specific values the spec pins. The implementer
|
|
150
|
+
writes the body. A body appears only for an algorithm the signature and
|
|
151
|
+
tests do not determine, or for exact copy the spec fixes.
|
|
152
|
+
- **A verification step:** the command to run and the output that means it
|
|
153
|
+
passed.
|
|
154
|
+
- **A reference to another task:** that task's Interfaces block says what
|
|
155
|
+
to use; the plan does not repeat that task's code.
|
|
156
|
+
|
|
157
|
+
A plan is the set of decisions the implementer cannot make alone. A plan
|
|
158
|
+
longer than the code it describes has written the code instead. Lines that
|
|
159
|
+
decide nothing ("TBD", "handle edge cases", "add appropriate validation",
|
|
160
|
+
"write tests for the above", a type or function no task defines) are the
|
|
161
|
+
opposite failure, and the self-review catches both.
|
|
152
162
|
|
|
153
163
|
## Self-Review
|
|
154
164
|
|
|
@@ -156,12 +166,14 @@ After writing the complete plan, look at the spec with fresh eyes and check the
|
|
|
156
166
|
|
|
157
167
|
**1. Spec coverage:** Skim each section/requirement in the spec. Can you point to a task that implements it? List any gaps.
|
|
158
168
|
|
|
159
|
-
**2.
|
|
169
|
+
**2. Step scan:** Every step must let the implementer write exactly one reasonable thing, and no step may carry more than that: a line that decides nothing is a gap, a function body the signature and tests already determine is a transcript. Fix both.
|
|
160
170
|
|
|
161
171
|
**3. Type consistency:** Do the types, method signatures, and property names you used in later tasks match what you defined in earlier tasks? A function called `clearLayers()` in Task 3 but `clearFullLayers()` in Task 7 is a bug.
|
|
162
172
|
|
|
163
173
|
**4. Review Focus:** For each input class or failure mode the spec implies, is there a task whose tests exercise it? The five uncovered ones most likely to bite a person go in the Review Focus section, and each line there gets its test added to the owning task. An empty section means you checked and found none, not that you skipped the check.
|
|
164
174
|
|
|
175
|
+
**5. Proportion:** Compare the plan's length to the spec's. A plan several times longer than the spec it implements is a transcript of the program, not a plan. If code blocks are most of the document, replace bodies with signatures, test names and assertions, and check that each step is still unambiguous.
|
|
176
|
+
|
|
165
177
|
If you find issues, fix them inline. No need to re-review — just fix and move on. If you find a spec requirement with no task, add the task.
|
|
166
178
|
|
|
167
179
|
## Execution Handoff
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
# Plan Document Reviewer Prompt Template
|
|
2
|
-
|
|
3
|
-
Use this template when dispatching a plan document reviewer subagent.
|
|
4
|
-
|
|
5
|
-
**Purpose:** Verify the plan is complete, matches the spec, and has proper task decomposition.
|
|
6
|
-
|
|
7
|
-
**Dispatch after:** The complete plan is written.
|
|
8
|
-
|
|
9
|
-
```
|
|
10
|
-
Subagent (general-purpose):
|
|
11
|
-
description: "Review plan document"
|
|
12
|
-
prompt: |
|
|
13
|
-
You are a plan document reviewer. Verify this plan is complete and ready for implementation.
|
|
14
|
-
|
|
15
|
-
**Plan to review:** [PLAN_FILE_PATH]
|
|
16
|
-
**Spec for reference:** [SPEC_FILE_PATH]
|
|
17
|
-
|
|
18
|
-
## What to Check
|
|
19
|
-
|
|
20
|
-
| Category | What to Look For |
|
|
21
|
-
|----------|------------------|
|
|
22
|
-
| Completeness | TODOs, placeholders, incomplete tasks, missing steps |
|
|
23
|
-
| Spec Alignment | Plan covers spec requirements, no major scope creep |
|
|
24
|
-
| Task Decomposition | Tasks have clear boundaries, steps are actionable |
|
|
25
|
-
| Buildability | Could an engineer follow this plan without getting stuck? |
|
|
26
|
-
|
|
27
|
-
## Calibration
|
|
28
|
-
|
|
29
|
-
**Only flag issues that would cause real problems during implementation.**
|
|
30
|
-
An implementer building the wrong thing or getting stuck is an issue.
|
|
31
|
-
Minor wording, stylistic preferences, and "nice to have" suggestions are not.
|
|
32
|
-
|
|
33
|
-
Approve unless there are serious gaps — missing requirements from the spec,
|
|
34
|
-
contradictory steps, placeholder content, or tasks so vague they can't be acted on.
|
|
35
|
-
|
|
36
|
-
## Output Format
|
|
37
|
-
|
|
38
|
-
## Plan Review
|
|
39
|
-
|
|
40
|
-
**Status:** Approved | Issues Found
|
|
41
|
-
|
|
42
|
-
**Issues (if any):**
|
|
43
|
-
- [Task X, Step Y]: [specific issue] - [why it matters for implementation]
|
|
44
|
-
|
|
45
|
-
**Recommendations (advisory, do not block approval):**
|
|
46
|
-
- [suggestions for improvement]
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
**Reviewer returns:** Status, Issues (if any), Recommendations
|