5-phase-workflow 1.1.1 → 1.2.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/README.md +2 -16
- package/bin/install.js +20 -12
- package/docs/findings.md +361 -0
- package/docs/progress.md +102 -0
- package/docs/workflow-guide.md +39 -12
- package/package.json +1 -1
- package/src/commands/5/configure.md +47 -3
- package/src/commands/5/discuss-feature.md +42 -11
- package/src/commands/5/implement-feature.md +168 -457
- package/src/commands/5/plan-feature.md +65 -96
- package/src/commands/5/plan-implementation.md +136 -361
- package/src/commands/5/quick-implement.md +79 -40
- package/src/commands/5/review-code.md +234 -187
- package/src/commands/5/verify-implementation.md +296 -232
- package/src/skills/configure-project/SKILL.md +1 -1
- package/src/templates/workflow/FEATURE-SPEC.md +83 -0
- package/src/templates/workflow/FIX-PLAN.md +55 -0
- package/src/templates/workflow/PLAN.md +30 -0
- package/src/templates/workflow/QUICK-PLAN.md +17 -0
- package/src/templates/workflow/REVIEW-FINDINGS.md +58 -0
- package/src/templates/workflow/REVIEW-SUMMARY.md +35 -0
- package/src/templates/workflow/STATE.json +9 -0
- package/src/templates/workflow/VERIFICATION-REPORT.md +95 -0
- package/src/agents/integration-agent.md +0 -220
- package/src/agents/review-processor.md +0 -161
- package/src/agents/step-executor.md +0 -109
- package/src/agents/step-fixer.md +0 -133
- package/src/agents/step-verifier.md +0 -126
- package/src/agents/verification-agent.md +0 -445
|
@@ -1,307 +1,371 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: 5:verify-implementation
|
|
3
|
-
description: Verifies
|
|
4
|
-
allowed-tools: Read, Glob,
|
|
3
|
+
description: Verifies a feature implementation is complete and working with multi-layer checks. Phase 4 of the 5-phase workflow.
|
|
4
|
+
allowed-tools: Read, Glob, Grep, Bash, Write, Task, AskUserQuestion
|
|
5
5
|
context: fork
|
|
6
6
|
user-invocable: true
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# Verify Implementation (Phase 4)
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
Verify that an implementation is complete, correct, and meets feature requirements through multi-layer verification.
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
1. Automatically by `/implement-feature` at the end of Wave 7
|
|
15
|
-
2. Manually by the developer to verify a feature
|
|
16
|
-
3. After fixing issues to re-verify
|
|
13
|
+
## Scope
|
|
17
14
|
|
|
18
|
-
**
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
15
|
+
**This command verifies the implementation across three layers:**
|
|
16
|
+
1. Infrastructure — files exist, build passes, tests pass
|
|
17
|
+
2. Feature completeness — code satisfies acceptance criteria and requirements from the feature spec
|
|
18
|
+
3. Quality — new files have corresponding tests
|
|
22
19
|
|
|
23
|
-
|
|
20
|
+
If verification finds gaps, it generates a fix plan and offers to apply fixes automatically.
|
|
24
21
|
|
|
25
|
-
|
|
22
|
+
## Process
|
|
26
23
|
|
|
27
|
-
|
|
24
|
+
### Step 1: Load All Artifacts
|
|
28
25
|
|
|
29
|
-
|
|
30
|
-
- Return fail status immediately
|
|
31
|
-
- Display clear error message: "Error: Implementation plan not found at `.5/{feature-name}/plan/`. Please run /5:plan-implementation first."
|
|
32
|
-
- Do not proceed to Step 2
|
|
26
|
+
Read all workflow artifacts for the feature:
|
|
33
27
|
|
|
34
|
-
**
|
|
35
|
-
-
|
|
36
|
-
-
|
|
28
|
+
**Required:**
|
|
29
|
+
- `.5/{feature-name}/plan.md` — implementation plan (Phase 2)
|
|
30
|
+
- `.5/{feature-name}/state.json` — implementation state (Phase 3)
|
|
37
31
|
|
|
38
|
-
**
|
|
39
|
-
-
|
|
40
|
-
- Extract:
|
|
41
|
-
- `build_command`
|
|
42
|
-
- `test_command`
|
|
43
|
-
- Expected New Files list
|
|
44
|
-
- Expected Modified Files list
|
|
45
|
-
- Build Targets list
|
|
46
|
-
- Test Modules list
|
|
32
|
+
**Optional:**
|
|
33
|
+
- `.5/{feature-name}/feature.md` — feature spec (Phase 1)
|
|
47
34
|
|
|
48
|
-
**
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
35
|
+
**If `plan.md` or `state.json` is missing:** hard stop.
|
|
36
|
+
```
|
|
37
|
+
Cannot verify — missing required artifacts.
|
|
38
|
+
|
|
39
|
+
Missing: {plan.md | state.json | both}
|
|
40
|
+
|
|
41
|
+
Run these first:
|
|
42
|
+
- /5:plan-implementation {feature-name} (creates plan.md)
|
|
43
|
+
- /5:implement-feature {feature-name} (creates state.json)
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
**If `feature.md` is missing:** warn and continue. Feature completeness verification (Layer 2) will be skipped.
|
|
47
|
+
```
|
|
48
|
+
Note: feature.md not found — skipping feature completeness checks.
|
|
49
|
+
This is normal for quick-implement workflows. Infrastructure and quality checks will still run.
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
Extract from artifacts:
|
|
53
|
+
- Components table from `plan.md` (step, component, action, file, description, complexity)
|
|
54
|
+
- Build and test commands from `plan.md`
|
|
55
|
+
- Completed/failed components from `state.json`
|
|
56
|
+
- Acceptance criteria and functional requirements from `feature.md` (if present)
|
|
57
|
+
|
|
58
|
+
### Step 2: Infrastructure Verification (Layer 1)
|
|
53
59
|
|
|
54
|
-
|
|
60
|
+
#### 2a. Check Files Exist
|
|
55
61
|
|
|
56
|
-
|
|
62
|
+
For each component in the plan:
|
|
63
|
+
- Use Glob to verify the file exists
|
|
64
|
+
- Record: EXISTS / MISSING
|
|
65
|
+
|
|
66
|
+
#### 2b. Run Build
|
|
67
|
+
|
|
68
|
+
Execute the build command from the plan (or auto-detect from `.claude/.5/config.json`):
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
{build-command}
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Record: SUCCESS / FAILED with errors.
|
|
75
|
+
|
|
76
|
+
**If build fails, stop here.** Broken code cannot be meaningfully verified for completeness. Set overall status to FAILED and skip to Step 6.
|
|
77
|
+
|
|
78
|
+
#### 2c. Run Tests
|
|
79
|
+
|
|
80
|
+
Execute the test command from the plan (or auto-detect):
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
{test-command}
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
Record: SUCCESS / FAILED with details (which tests failed, error messages).
|
|
87
|
+
|
|
88
|
+
### Step 3: Feature Completeness Verification (Layer 2)
|
|
89
|
+
|
|
90
|
+
**Skip this step entirely if `feature.md` was not found in Step 1.**
|
|
91
|
+
|
|
92
|
+
Spawn a sonnet agent to cross-reference the implementation against the feature spec:
|
|
57
93
|
|
|
58
94
|
```
|
|
59
95
|
Task tool call:
|
|
60
96
|
subagent_type: general-purpose
|
|
61
|
-
|
|
97
|
+
model: sonnet
|
|
98
|
+
description: "Verify feature completeness for {feature-name}"
|
|
62
99
|
prompt: |
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
100
|
+
You are verifying that an implementation satisfies its feature specification.
|
|
101
|
+
|
|
102
|
+
## Feature Specification
|
|
103
|
+
{full text of feature.md}
|
|
104
|
+
|
|
105
|
+
## Implementation Plan
|
|
106
|
+
{full text of plan.md}
|
|
107
|
+
|
|
108
|
+
## Instructions
|
|
109
|
+
|
|
110
|
+
1. **Read each implemented file** listed in the components table below:
|
|
111
|
+
{components table from plan.md}
|
|
112
|
+
|
|
113
|
+
2. **Check acceptance criteria** from the feature spec.
|
|
114
|
+
For each acceptance criterion, determine:
|
|
115
|
+
- SATISFIED — code clearly implements this criterion (cite file:line as evidence)
|
|
116
|
+
- NOT SATISFIED — no code found that implements this criterion
|
|
117
|
+
|
|
118
|
+
3. **Check functional requirements** from the feature spec.
|
|
119
|
+
For each requirement, determine:
|
|
120
|
+
- IMPLEMENTED — code implements this requirement (cite file:line)
|
|
121
|
+
- NOT IMPLEMENTED — no code found for this requirement
|
|
122
|
+
|
|
123
|
+
4. **Check component completeness** from the plan.
|
|
124
|
+
For each component in the table, read the file and determine:
|
|
125
|
+
- COMPLETE — file exists and implements what the description says
|
|
126
|
+
- PARTIAL — file exists but is missing described functionality
|
|
127
|
+
- MISSING — file does not exist
|
|
128
|
+
|
|
129
|
+
## Output Format
|
|
130
|
+
Return EXACTLY this structure:
|
|
131
|
+
|
|
132
|
+
ACCEPTANCE_CRITERIA:
|
|
133
|
+
- criterion: "{text of criterion}"
|
|
134
|
+
status: SATISFIED | NOT SATISFIED
|
|
135
|
+
evidence: "{file:line}" or "none"
|
|
136
|
+
notes: "{brief explanation}"
|
|
137
|
+
|
|
138
|
+
REQUIREMENTS:
|
|
139
|
+
- requirement: "{text of requirement}"
|
|
140
|
+
status: IMPLEMENTED | NOT IMPLEMENTED
|
|
141
|
+
evidence: "{file:line}" or "none"
|
|
142
|
+
notes: "{brief explanation}"
|
|
143
|
+
|
|
144
|
+
COMPONENTS:
|
|
145
|
+
- component: "{component name}"
|
|
146
|
+
file: "{file path}"
|
|
147
|
+
status: COMPLETE | PARTIAL | MISSING
|
|
148
|
+
notes: "{what's missing if partial}"
|
|
149
|
+
|
|
150
|
+
SUMMARY:
|
|
151
|
+
- criteria_satisfied: {N}/{M}
|
|
152
|
+
- requirements_implemented: {N}/{M}
|
|
153
|
+
- components_complete: {N}/{M}
|
|
154
|
+
|
|
155
|
+
## Rules
|
|
156
|
+
- Read every file referenced in the components table
|
|
157
|
+
- Be precise with evidence — cite actual file paths and line numbers
|
|
158
|
+
- PARTIAL means the file exists but is missing specific functionality described in the plan
|
|
159
|
+
- Do NOT interact with the user
|
|
160
|
+
- Do NOT modify any files
|
|
84
161
|
```
|
|
85
162
|
|
|
86
|
-
|
|
163
|
+
Parse the agent's structured output into:
|
|
164
|
+
- Acceptance criteria results (satisfied/not satisfied counts)
|
|
165
|
+
- Requirements results (implemented/not implemented counts)
|
|
166
|
+
- Component completeness results (complete/partial/missing counts)
|
|
87
167
|
|
|
88
|
-
|
|
89
|
-
- Overall status (passed/passed-with-warnings/failed)
|
|
90
|
-
- Implementation completeness results (tasks, method signatures, test coverage, acceptance criteria)
|
|
91
|
-
- File existence results
|
|
92
|
-
- Problem detection results (errors vs warnings)
|
|
93
|
-
- Compilation results
|
|
94
|
-
- Test results
|
|
95
|
-
- Generated verification report (Markdown)
|
|
168
|
+
### Step 4: Quality Checks (Layer 3)
|
|
96
169
|
|
|
97
|
-
|
|
170
|
+
For each component with action `create` in the plan:
|
|
171
|
+
- Determine the expected test file path using common patterns:
|
|
172
|
+
- `src/foo/Bar.ts` → look for `src/foo/Bar.test.ts`, `src/foo/Bar.spec.ts`, `test/foo/Bar.test.ts`, `tests/foo/Bar.test.ts`
|
|
173
|
+
- `src/foo/bar.py` → look for `tests/foo/test_bar.py`, `tests/test_bar.py`, `src/foo/test_bar.py`
|
|
174
|
+
- Adapt pattern based on project conventions
|
|
175
|
+
- Use Glob to check if a test file exists
|
|
176
|
+
- Record: HAS TEST / NO TEST
|
|
98
177
|
|
|
99
|
-
|
|
100
|
-
`.5/{feature-name}/verification.md`
|
|
178
|
+
This is a lightweight check — it only verifies test files exist for new code, not test quality.
|
|
101
179
|
|
|
102
|
-
### Step 5:
|
|
180
|
+
### Step 5: Determine Status
|
|
103
181
|
|
|
104
|
-
|
|
182
|
+
Evaluate all three layers:
|
|
105
183
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
184
|
+
**PASSED** — all conditions met:
|
|
185
|
+
- All files exist
|
|
186
|
+
- Build succeeds
|
|
187
|
+
- Tests pass
|
|
188
|
+
- All acceptance criteria satisfied (or Layer 2 skipped)
|
|
189
|
+
- All requirements implemented (or Layer 2 skipped)
|
|
190
|
+
- All components complete
|
|
191
|
+
|
|
192
|
+
**PARTIAL** — infrastructure OK but gaps exist:
|
|
193
|
+
- All files exist AND build succeeds AND tests pass
|
|
194
|
+
- BUT: some acceptance criteria not satisfied, OR some requirements not implemented, OR some components partial, OR some new files lack tests
|
|
195
|
+
|
|
196
|
+
**FAILED** — infrastructure problems:
|
|
197
|
+
- Any files missing, OR build fails, OR tests fail
|
|
198
|
+
|
|
199
|
+
### Step 6: Generate Verification Report
|
|
200
|
+
|
|
201
|
+
Write `.5/{feature-name}/verification.md` using the template structure from `.claude/templates/workflow/VERIFICATION-REPORT.md`.
|
|
202
|
+
|
|
203
|
+
The report covers:
|
|
204
|
+
- **Header:** ticket, feature, status, timestamp
|
|
205
|
+
- **Layer 1 — Infrastructure:** file existence checklist, build result, test result
|
|
206
|
+
- **Layer 2 — Feature Completeness:** acceptance criteria status, requirements status, component completeness (or "Skipped — no feature.md" if not available)
|
|
207
|
+
- **Layer 3 — Quality:** test coverage for new files
|
|
208
|
+
- **Summary table:** layer-by-layer pass/fail overview
|
|
130
209
|
|
|
131
|
-
|
|
210
|
+
### Step 7: Update State
|
|
211
|
+
|
|
212
|
+
Update `.5/{feature-name}/state.json`:
|
|
132
213
|
```json
|
|
133
214
|
{
|
|
134
|
-
"
|
|
135
|
-
"
|
|
215
|
+
"verificationStatus": "passed | partial | failed",
|
|
216
|
+
"verifiedAt": "{ISO-timestamp}",
|
|
217
|
+
"verificationLayers": {
|
|
218
|
+
"infrastructure": "passed | failed",
|
|
219
|
+
"featureCompleteness": "passed | partial | skipped",
|
|
220
|
+
"quality": "passed | partial"
|
|
221
|
+
}
|
|
136
222
|
}
|
|
137
223
|
```
|
|
138
224
|
|
|
139
|
-
### Step
|
|
225
|
+
### Step 8: Handle Results
|
|
140
226
|
|
|
141
227
|
**If PASSED:**
|
|
228
|
+
|
|
142
229
|
```
|
|
143
|
-
Verification
|
|
230
|
+
Verification passed!
|
|
144
231
|
|
|
145
|
-
All
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
- Compilation: Success
|
|
149
|
-
- Tests: All passing ({N} tests)
|
|
150
|
-
- Errors: 0
|
|
151
|
-
- Warnings: {N}
|
|
232
|
+
Layer 1 (Infrastructure): All files exist, build OK, tests OK
|
|
233
|
+
Layer 2 (Feature Completeness): {N}/{N} criteria satisfied, {N}/{N} requirements implemented
|
|
234
|
+
Layer 3 (Quality): {N}/{N} new files have tests
|
|
152
235
|
|
|
153
|
-
|
|
236
|
+
Report: .5/{feature-name}/verification.md
|
|
154
237
|
|
|
155
|
-
|
|
156
|
-
1. Commit your changes (recommended before code review)
|
|
157
|
-
2. Run `/clear` to reset context
|
|
158
|
-
3. Run `/5:review-code` for CodeRabbit review
|
|
238
|
+
Would you like to commit these changes?
|
|
159
239
|
```
|
|
160
240
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
241
|
+
Use AskUserQuestion with options:
|
|
242
|
+
1. "Yes - commit now (Recommended)"
|
|
243
|
+
2. "No - I'll commit later"
|
|
164
244
|
|
|
165
|
-
|
|
166
|
-
- Implementation: {N}/{N} tasks completed ({N} partial or minor deviations)
|
|
167
|
-
- Files: {N}/{N} exist
|
|
168
|
-
- Compilation: Success
|
|
169
|
-
- Tests: All passing ({N} tests)
|
|
170
|
-
- Errors: 0
|
|
171
|
-
- Warnings: {N}
|
|
245
|
+
If yes: stage and commit with message format `{TICKET-ID} {description}`.
|
|
172
246
|
|
|
173
|
-
|
|
174
|
-
.5/{feature-name}/verification.md
|
|
247
|
+
Then go to Step 11 (Next Steps).
|
|
175
248
|
|
|
176
|
-
|
|
249
|
+
**If PARTIAL or FAILED:**
|
|
177
250
|
|
|
178
|
-
Next steps:
|
|
179
|
-
1. Commit your changes (recommended before code review)
|
|
180
|
-
2. Run `/clear` to reset context
|
|
181
|
-
3. Run `/5:review-code` for CodeRabbit review
|
|
182
251
|
```
|
|
252
|
+
Verification {status}.
|
|
253
|
+
|
|
254
|
+
Layer 1 (Infrastructure): {summary}
|
|
255
|
+
Layer 2 (Feature Completeness): {summary}
|
|
256
|
+
Layer 3 (Quality): {summary}
|
|
183
257
|
|
|
184
|
-
|
|
258
|
+
{Count} issue(s) found. Generating fix plan...
|
|
259
|
+
|
|
260
|
+
Report: .5/{feature-name}/verification.md
|
|
185
261
|
```
|
|
186
|
-
Verification FAILED
|
|
187
262
|
|
|
188
|
-
|
|
189
|
-
- Implementation: {N}/{N} tasks incomplete
|
|
190
|
-
- Files missing: {N}
|
|
191
|
-
- Compilation: Failed
|
|
192
|
-
- Tests: {N} failures
|
|
193
|
-
- Errors: {N}
|
|
263
|
+
Continue to Step 9.
|
|
194
264
|
|
|
195
|
-
|
|
196
|
-
.5/{feature-name}/verification.md
|
|
265
|
+
### Step 9: Generate Fix Plan (PARTIAL or FAILED only)
|
|
197
266
|
|
|
198
|
-
|
|
199
|
-
```
|
|
267
|
+
Write `.5/{feature-name}/fix-plan.md` using the template structure from `.claude/templates/workflow/FIX-PLAN.md`.
|
|
200
268
|
|
|
201
|
-
|
|
269
|
+
Build fix entries from verification results:
|
|
202
270
|
|
|
203
|
-
**
|
|
271
|
+
**From Layer 1 (Infrastructure):**
|
|
272
|
+
- Missing files → fix: create the file (reference the plan component)
|
|
273
|
+
- Build failures → fix: describe the build error and likely cause
|
|
274
|
+
- Test failures → fix: describe failing test and likely cause
|
|
204
275
|
|
|
205
|
-
**
|
|
206
|
-
|
|
207
|
-
|
|
276
|
+
**From Layer 2 (Feature Completeness):**
|
|
277
|
+
- Unsatisfied acceptance criteria → fix: describe what code needs to change
|
|
278
|
+
- Unimplemented requirements → fix: describe what needs to be added
|
|
279
|
+
- Partial components → fix: describe what's missing from the component
|
|
280
|
+
|
|
281
|
+
**From Layer 3 (Quality):**
|
|
282
|
+
- Missing test files → fix: create test file for the component
|
|
283
|
+
|
|
284
|
+
Each fix entry follows the same table format as `plan.md`:
|
|
285
|
+
|
|
286
|
+
| # | Category | File | Issue | Fix | Complexity |
|
|
287
|
+
|---|----------|------|-------|-----|------------|
|
|
288
|
+
| 1 | infrastructure | src/models/Foo.ts | File missing | Create file per plan component #3 | simple |
|
|
289
|
+
| 2 | feature-gap | src/services/Bar.ts | Missing validation for criterion "..." | Add input validation in processOrder() | moderate |
|
|
290
|
+
| 3 | quality | tests/services/Bar.test.ts | No test file for BarService | Create test file with basic CRUD tests | simple |
|
|
291
|
+
|
|
292
|
+
### Step 10: Offer Fix Options
|
|
293
|
+
|
|
294
|
+
Use AskUserQuestion:
|
|
295
|
+
1. "Apply fixes automatically (Recommended)" — spawn agents to apply each fix
|
|
296
|
+
2. "I'll fix manually, then re-run /5:verify-implementation"
|
|
297
|
+
|
|
298
|
+
**If user selects "Apply fixes automatically":**
|
|
299
|
+
|
|
300
|
+
For each fix in the fix plan, spawn an agent following the same pattern as `implement-feature`:
|
|
301
|
+
|
|
302
|
+
- **simple** fixes → `haiku` model
|
|
303
|
+
- **moderate** fixes → `haiku` or `sonnet` depending on context
|
|
304
|
+
- **complex** fixes → `sonnet` model
|
|
305
|
+
|
|
306
|
+
Group independent fixes for parallel execution. Fixes modifying the same file must be sequential.
|
|
208
307
|
|
|
209
|
-
It's recommended to commit changes before running CodeRabbit review (/review-code).
|
|
210
308
|
```
|
|
309
|
+
Task tool call:
|
|
310
|
+
subagent_type: general-purpose
|
|
311
|
+
model: {based on complexity}
|
|
312
|
+
description: "Fix: {short description}"
|
|
313
|
+
prompt: |
|
|
314
|
+
You are fixing a verification issue in a codebase.
|
|
211
315
|
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
316
|
+
## Issue
|
|
317
|
+
Category: {infrastructure | feature-gap | quality}
|
|
318
|
+
File: {file-path}
|
|
319
|
+
Issue: {description of what's wrong}
|
|
320
|
+
Fix: {description of what to do}
|
|
215
321
|
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
- Stage all relevant files
|
|
219
|
-
- Create commit with proper message format
|
|
220
|
-
- After committing, tell user: "Changes committed. Next steps: Run `/clear` followed by `/5:review-code` for CodeRabbit review."
|
|
322
|
+
## Context
|
|
323
|
+
{relevant section from plan.md or feature.md}
|
|
221
324
|
|
|
222
|
-
|
|
223
|
-
|
|
325
|
+
## Instructions
|
|
326
|
+
1. If creating a new file: find a similar existing file using Glob, read it to understand the pattern, create the new file following that pattern
|
|
327
|
+
2. If modifying a file: read the file, make the described change
|
|
328
|
+
3. Verify the file exists after changes
|
|
329
|
+
4. Report what you did
|
|
224
330
|
|
|
225
|
-
|
|
331
|
+
Use Glob to find similar files. Use Read to understand patterns. Use Write/Edit to create/modify files.
|
|
332
|
+
```
|
|
226
333
|
|
|
227
|
-
|
|
334
|
+
After all fixes are applied, re-run build and tests:
|
|
228
335
|
|
|
336
|
+
```bash
|
|
337
|
+
{build-command}
|
|
338
|
+
{test-command}
|
|
229
339
|
```
|
|
230
|
-
{TICKET-ID} Short description of what is done (~50 chars)
|
|
231
340
|
|
|
232
|
-
-
|
|
233
|
-
-
|
|
234
|
-
-
|
|
235
|
-
|
|
341
|
+
Update `fix-plan.md` with results:
|
|
342
|
+
- Mark each fix as APPLIED / FAILED
|
|
343
|
+
- Record build and test results after fixes
|
|
344
|
+
|
|
345
|
+
Report to user:
|
|
236
346
|
```
|
|
347
|
+
Applied {N} fixes.
|
|
237
348
|
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
- Blank line after first line
|
|
241
|
-
- Bullet points for changes (what changed and why)
|
|
242
|
-
- Only important points, no verbose descriptions
|
|
243
|
-
- No emojis
|
|
244
|
-
- No AI attribution or Co-Authored-By lines
|
|
349
|
+
Build: {status}
|
|
350
|
+
Tests: {status}
|
|
245
351
|
|
|
246
|
-
|
|
247
|
-
When creating the commit, use HEREDOC format:
|
|
352
|
+
{If any fixes failed, list them}
|
|
248
353
|
|
|
249
|
-
|
|
250
|
-
git add [relevant files]
|
|
251
|
-
git commit -m "$(cat <<'EOF'
|
|
252
|
-
PROJ-1234 Short description here
|
|
253
|
-
|
|
254
|
-
- Change 1 and reason
|
|
255
|
-
- Change 2 and reason
|
|
256
|
-
EOF
|
|
257
|
-
)"
|
|
354
|
+
Updated: .5/{feature-name}/fix-plan.md
|
|
258
355
|
```
|
|
259
356
|
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
1. **Thin orchestrator** - Delegate verification work to agent, keep interactive parts in main context
|
|
276
|
-
2. **Comprehensive** - Agent checks everything (files, problems, compilation, tests)
|
|
277
|
-
3. **Categorized** - Separate errors (block) from warnings (report)
|
|
278
|
-
4. **Actionable** - Clear report of what needs fixing
|
|
279
|
-
5. **Persistent** - Save report for reference
|
|
280
|
-
6. **Resumable** - Can be re-run after fixes
|
|
281
|
-
7. **Commit ready** - Prompt for commit after successful verification
|
|
282
|
-
|
|
283
|
-
## DO NOT
|
|
284
|
-
|
|
285
|
-
- DO NOT run compilation or tests directly (agent handles this)
|
|
286
|
-
- DO NOT run problem detection directly (agent handles this)
|
|
287
|
-
- DO NOT block on warnings (only errors block)
|
|
288
|
-
- DO NOT skip state file update
|
|
289
|
-
- DO NOT skip saving verification report
|
|
290
|
-
- DO NOT skip asking about commit if verification passed
|
|
291
|
-
- DO NOT automatically create commits without user approval
|
|
292
|
-
- DO NOT use emojis in commit messages
|
|
293
|
-
- DO NOT include AI attribution or Co-Authored-By lines in commit messages
|
|
294
|
-
|
|
295
|
-
## Error Handling
|
|
296
|
-
|
|
297
|
-
If the verification-agent fails to return results:
|
|
298
|
-
1. Record the failure in the state file
|
|
299
|
-
2. Mark overall verification as FAILED
|
|
300
|
-
3. Include diagnostic information in report
|
|
301
|
-
4. Suggest re-running verification
|
|
302
|
-
|
|
303
|
-
## Related Documentation
|
|
304
|
-
|
|
305
|
-
- [Agent: verification-agent](../agents/verification-agent.md)
|
|
306
|
-
- [/implement-feature command](implement-feature.md)
|
|
307
|
-
- [/plan-implementation command](plan-implementation.md)
|
|
357
|
+
**If user selects manual fix:** exit with guidance.
|
|
358
|
+
```
|
|
359
|
+
Fix plan saved: .5/{feature-name}/fix-plan.md
|
|
360
|
+
|
|
361
|
+
When ready, re-run: /5:verify-implementation {feature-name}
|
|
362
|
+
```
|
|
363
|
+
|
|
364
|
+
### Step 11: Next Steps
|
|
365
|
+
|
|
366
|
+
Tell user:
|
|
367
|
+
```
|
|
368
|
+
Next steps:
|
|
369
|
+
1. Run `/clear` to reset context (recommended between phases)
|
|
370
|
+
2. Run `/5:review-code`
|
|
371
|
+
```
|