ace-review 0.49.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.
- checksums.yaml +7 -0
- data/.ace-defaults/nav/protocols/guide-sources/ace-review.yml +10 -0
- data/.ace-defaults/nav/protocols/prompt-sources/ace-review.yml +36 -0
- data/.ace-defaults/nav/protocols/tmpl-sources/ace-review.yml +10 -0
- data/.ace-defaults/nav/protocols/wfi-sources/ace-review.yml +19 -0
- data/.ace-defaults/review/config.yml +79 -0
- data/.ace-defaults/review/presets/code-fit.yml +64 -0
- data/.ace-defaults/review/presets/code-shine.yml +44 -0
- data/.ace-defaults/review/presets/code-valid.yml +39 -0
- data/.ace-defaults/review/presets/docs.yml +42 -0
- data/.ace-defaults/review/presets/spec.yml +37 -0
- data/CHANGELOG.md +1780 -0
- data/LICENSE +21 -0
- data/README.md +42 -0
- data/Rakefile +14 -0
- data/exe/ace-review +27 -0
- data/exe/ace-review-feedback +17 -0
- data/handbook/guides/code-review-process.g.md +234 -0
- data/handbook/prompts/base/sections.md +23 -0
- data/handbook/prompts/base/system.md +60 -0
- data/handbook/prompts/focus/architecture/atom.md +30 -0
- data/handbook/prompts/focus/architecture/reflection.md +60 -0
- data/handbook/prompts/focus/frameworks/rails.md +40 -0
- data/handbook/prompts/focus/frameworks/vue-firebase.md +45 -0
- data/handbook/prompts/focus/languages/ruby.md +50 -0
- data/handbook/prompts/focus/phase/correctness.md +51 -0
- data/handbook/prompts/focus/phase/polish.md +43 -0
- data/handbook/prompts/focus/phase/quality.md +42 -0
- data/handbook/prompts/focus/quality/performance.md +48 -0
- data/handbook/prompts/focus/quality/security.md +47 -0
- data/handbook/prompts/focus/scope/docs.md +38 -0
- data/handbook/prompts/focus/scope/spec.md +58 -0
- data/handbook/prompts/focus/scope/tests.md +36 -0
- data/handbook/prompts/format/compact.md +12 -0
- data/handbook/prompts/format/detailed.md +39 -0
- data/handbook/prompts/format/standard.md +16 -0
- data/handbook/prompts/guidelines/icons.md +19 -0
- data/handbook/prompts/guidelines/tone.md +21 -0
- data/handbook/prompts/synthesis-review-reports.system.md +318 -0
- data/handbook/prompts/synthesize-feedback.system.md +147 -0
- data/handbook/skills/as-review-apply-feedback/SKILL.md +39 -0
- data/handbook/skills/as-review-package/SKILL.md +36 -0
- data/handbook/skills/as-review-pr/SKILL.md +38 -0
- data/handbook/skills/as-review-run/SKILL.md +30 -0
- data/handbook/skills/as-review-verify-feedback/SKILL.md +31 -0
- data/handbook/templates/review-tasks/task-review-summary.template.md +148 -0
- data/handbook/workflow-instructions/review/apply-feedback.wf.md +212 -0
- data/handbook/workflow-instructions/review/package.wf.md +16 -0
- data/handbook/workflow-instructions/review/pr.wf.md +284 -0
- data/handbook/workflow-instructions/review/run.wf.md +262 -0
- data/handbook/workflow-instructions/review/verify-feedback.wf.md +286 -0
- data/lib/ace/review/atoms/context_limit_resolver.rb +162 -0
- data/lib/ace/review/atoms/diff_boundary_finder.rb +133 -0
- data/lib/ace/review/atoms/feedback_id_generator.rb +66 -0
- data/lib/ace/review/atoms/feedback_slug_generator.rb +61 -0
- data/lib/ace/review/atoms/feedback_state_validator.rb +98 -0
- data/lib/ace/review/atoms/pr_comment_formatter.rb +325 -0
- data/lib/ace/review/atoms/preset_validator.rb +103 -0
- data/lib/ace/review/atoms/priority_filter.rb +115 -0
- data/lib/ace/review/atoms/retry_with_backoff.rb +75 -0
- data/lib/ace/review/atoms/slug_generator.rb +50 -0
- data/lib/ace/review/atoms/token_estimator.rb +86 -0
- data/lib/ace/review/cli/commands/feedback/create.rb +173 -0
- data/lib/ace/review/cli/commands/feedback/list.rb +280 -0
- data/lib/ace/review/cli/commands/feedback/resolve.rb +109 -0
- data/lib/ace/review/cli/commands/feedback/session_discovery.rb +70 -0
- data/lib/ace/review/cli/commands/feedback/show.rb +177 -0
- data/lib/ace/review/cli/commands/feedback/skip.rb +125 -0
- data/lib/ace/review/cli/commands/feedback/verify.rb +149 -0
- data/lib/ace/review/cli/commands/feedback.rb +79 -0
- data/lib/ace/review/cli/commands/review.rb +378 -0
- data/lib/ace/review/cli/feedback_cli.rb +71 -0
- data/lib/ace/review/cli.rb +103 -0
- data/lib/ace/review/errors.rb +146 -0
- data/lib/ace/review/models/feedback_item.rb +216 -0
- data/lib/ace/review/models/review_options.rb +208 -0
- data/lib/ace/review/models/reviewer.rb +181 -0
- data/lib/ace/review/molecules/context_composer.rb +123 -0
- data/lib/ace/review/molecules/context_extractor.rb +159 -0
- data/lib/ace/review/molecules/feedback_directory_manager.rb +183 -0
- data/lib/ace/review/molecules/feedback_file_reader.rb +178 -0
- data/lib/ace/review/molecules/feedback_file_writer.rb +210 -0
- data/lib/ace/review/molecules/feedback_synthesizer.rb +588 -0
- data/lib/ace/review/molecules/gh_cli_executor.rb +124 -0
- data/lib/ace/review/molecules/gh_comment_poster.rb +205 -0
- data/lib/ace/review/molecules/gh_comment_resolver.rb +199 -0
- data/lib/ace/review/molecules/gh_pr_comment_fetcher.rb +408 -0
- data/lib/ace/review/molecules/gh_pr_fetcher.rb +240 -0
- data/lib/ace/review/molecules/llm_executor.rb +142 -0
- data/lib/ace/review/molecules/multi_model_executor.rb +278 -0
- data/lib/ace/review/molecules/nav_prompt_resolver.rb +145 -0
- data/lib/ace/review/molecules/pr_task_spec_resolver.rb +58 -0
- data/lib/ace/review/molecules/preset_manager.rb +494 -0
- data/lib/ace/review/molecules/prompt_composer.rb +76 -0
- data/lib/ace/review/molecules/prompt_resolver.rb +168 -0
- data/lib/ace/review/molecules/strategies/adaptive_strategy.rb +193 -0
- data/lib/ace/review/molecules/strategies/chunked_strategy.rb +459 -0
- data/lib/ace/review/molecules/strategies/full_strategy.rb +114 -0
- data/lib/ace/review/molecules/subject_extractor.rb +315 -0
- data/lib/ace/review/molecules/subject_filter.rb +199 -0
- data/lib/ace/review/molecules/subject_strategy.rb +96 -0
- data/lib/ace/review/molecules/task_report_saver.rb +161 -0
- data/lib/ace/review/molecules/task_resolver.rb +48 -0
- data/lib/ace/review/organisms/feedback_manager.rb +386 -0
- data/lib/ace/review/organisms/review_manager.rb +1059 -0
- data/lib/ace/review/version.rb +7 -0
- data/lib/ace/review.rb +135 -0
- metadata +351 -0
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
---
|
|
2
|
+
doc-type: workflow
|
|
3
|
+
title: Code Review Workflow
|
|
4
|
+
purpose: Review code with preset and plan feedback application
|
|
5
|
+
ace-docs:
|
|
6
|
+
last-updated: 2026-03-18
|
|
7
|
+
last-checked: 2026-03-21
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Code Review Workflow
|
|
11
|
+
|
|
12
|
+
## Goal
|
|
13
|
+
|
|
14
|
+
Review code using ace-review, verify feedback items, and create a plan for applying fixes.
|
|
15
|
+
|
|
16
|
+
## Arguments
|
|
17
|
+
|
|
18
|
+
- `$1`: Preset name (optional). Run `ace-review --list-presets` to see options.
|
|
19
|
+
- `$2+`: Subject(s) using `type:value` syntax (optional, additive to preset):
|
|
20
|
+
|
|
21
|
+
**IMPORTANT: The type prefix is REQUIRED for all subjects except keywords**
|
|
22
|
+
|
|
23
|
+
- `staged`, `working` - keywords (no prefix needed)
|
|
24
|
+
- `diff:origin/main..HEAD` - git range (prefix required)
|
|
25
|
+
- `pr:123` - PR diff (prefix required)
|
|
26
|
+
- `files:lib/**/*.rb` - file pattern (prefix required)
|
|
27
|
+
- `task:145` - task context (prefix required)
|
|
28
|
+
|
|
29
|
+
## Instructions
|
|
30
|
+
|
|
31
|
+
### Step 1: Run Code Review
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
# Default preset
|
|
35
|
+
ace-review --auto-execute
|
|
36
|
+
|
|
37
|
+
# With preset
|
|
38
|
+
ace-review --preset $1 --auto-execute
|
|
39
|
+
|
|
40
|
+
# With subject(s) - additive to preset
|
|
41
|
+
ace-review --subject "$2" --auto-execute
|
|
42
|
+
|
|
43
|
+
# File pattern review (NOTE: files: prefix is REQUIRED)
|
|
44
|
+
ace-review --preset spec --subject "files:.ace-taskflow/**/*.md" --auto-execute
|
|
45
|
+
|
|
46
|
+
# Multiple subjects merge automatically
|
|
47
|
+
ace-review --subject pr:76 --subject files:CHANGELOG.md --auto-execute
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
**Important for Claude Code**: Run with 15-minute timeout (900000ms) and wait for completion inline (not background). Review typically takes 3-5 minutes.
|
|
51
|
+
|
|
52
|
+
#### Execution Guard (Mandatory)
|
|
53
|
+
|
|
54
|
+
- Completion is defined by **process exit** (success or failure), not by partial output.
|
|
55
|
+
- Do **not** treat temporary silence/no new output as completion.
|
|
56
|
+
- Do **not** run any Step 2+ commands until Step 1 process exit is confirmed.
|
|
57
|
+
- If 15-minute timeout (900000ms) is reached, report timeout and last observed output, then stop dependent steps.
|
|
58
|
+
|
|
59
|
+
Wait for the review process to exit. Note the session directory path from the output.
|
|
60
|
+
|
|
61
|
+
The review generates:
|
|
62
|
+
- LLM model reviews (e.g., `review-gemini.md`)
|
|
63
|
+
- Feedback items in `feedback/` directory
|
|
64
|
+
|
|
65
|
+
### Step 2: List Feedback Items
|
|
66
|
+
|
|
67
|
+
List the feedback items extracted from the review:
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
ace-review-feedback list --status draft
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
**Precondition**: Run this step only after Step 1 process exit is confirmed.
|
|
74
|
+
|
|
75
|
+
When session ambiguity is possible, use explicit session path from Step 1:
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
ace-review-feedback list --status draft --session <session-dir-from-step-1>
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
This shows all draft feedback items with their IDs, severity, and summaries.
|
|
82
|
+
|
|
83
|
+
#### Understanding Feedback Context
|
|
84
|
+
|
|
85
|
+
Feedback items are **session-scoped**. The `feedback list` command discovers items based on:
|
|
86
|
+
1. Explicit `--session <path>` flag (if provided)
|
|
87
|
+
2. `.ace-review-session` cache file in current directory (auto-created after reviews)
|
|
88
|
+
|
|
89
|
+
If `feedback list` returns empty after a review, first verify Step 1 process completion.
|
|
90
|
+
The session may not be linked to current context.
|
|
91
|
+
Use `ace-review-feedback list --session <session-dir>` to list from a specific session:
|
|
92
|
+
|
|
93
|
+
```bash
|
|
94
|
+
# List feedback from a specific session (path shown in review output)
|
|
95
|
+
ace-review-feedback list --session .ace-local/review/sessions/review-8p2pk3
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Step 3: Verify Feedback Items
|
|
99
|
+
|
|
100
|
+
**For thorough verification**, use the dedicated verification workflow:
|
|
101
|
+
|
|
102
|
+
```
|
|
103
|
+
ace-bundle wfi://review/verify-feedback
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
This workflow guides you through multi-dimensional claim analysis:
|
|
107
|
+
- **Existence claims**: Does the code/issue actually exist?
|
|
108
|
+
- **Scope claims**: Does the issue apply where claimed (CI, production, etc.)?
|
|
109
|
+
- **Documentation claims**: Are there docs/handling elsewhere?
|
|
110
|
+
- **Pattern claims**: Is this consistent with codebase patterns?
|
|
111
|
+
|
|
112
|
+
**For quick verification** of straightforward items:
|
|
113
|
+
|
|
114
|
+
```bash
|
|
115
|
+
# Read the finding details
|
|
116
|
+
ace-review-feedback show {id}
|
|
117
|
+
|
|
118
|
+
# Verify and mark result
|
|
119
|
+
ace-review-feedback verify {id} --valid --research "Confirmed: issue exists at line X"
|
|
120
|
+
ace-review-feedback verify {id} --invalid --research "False positive: handled by Y"
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
**Categorization guide:**
|
|
124
|
+
|
|
125
|
+
| Result | Command | When |
|
|
126
|
+
|--------|---------|------|
|
|
127
|
+
| ✅ VALID | `--valid` | Issue confirmed in code |
|
|
128
|
+
| ❌ INVALID | `--invalid` | **False positive** - claim is factually incorrect |
|
|
129
|
+
| ✅ DONE | `feedback resolve {id}` | Already fixed in this PR |
|
|
130
|
+
| ⏭️ SKIP | `verify --skip --research "Design: ..."` | **Correct finding**, but not being fixed |
|
|
131
|
+
| 📋 DEFER | `verify --skip --research "Tracked in task XXX"` | Important, but not this PR (create task first) |
|
|
132
|
+
|
|
133
|
+
**Key distinction:**
|
|
134
|
+
- `verify --invalid`: The finding is **wrong** (false positive)
|
|
135
|
+
- "Code doesn't exist" → Actually exists
|
|
136
|
+
- "Missing validation" → Exists elsewhere
|
|
137
|
+
- "Fails in CI" → Doesn't run in CI
|
|
138
|
+
- `verify --skip`: The finding is **correct**, but you're not fixing it
|
|
139
|
+
- Design decision: Intentional choice
|
|
140
|
+
- Deferred: Tracking in separate task
|
|
141
|
+
|
|
142
|
+
**Skip verification for:**
|
|
143
|
+
- Low priority items (verify only if time permits)
|
|
144
|
+
- Documentation-only suggestions
|
|
145
|
+
- Style/formatting recommendations
|
|
146
|
+
|
|
147
|
+
### Step 4: List Pending Items
|
|
148
|
+
|
|
149
|
+
After verification, list items ready to work on:
|
|
150
|
+
|
|
151
|
+
```bash
|
|
152
|
+
ace-review-feedback list --status pending
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
This shows only verified valid items that need fixing.
|
|
156
|
+
|
|
157
|
+
### Step 5: Apply Priority Threshold
|
|
158
|
+
|
|
159
|
+
**Default behavior**: Implement **Medium and higher** severity items (skip Low).
|
|
160
|
+
|
|
161
|
+
This means:
|
|
162
|
+
- 🔴 Critical → Implement
|
|
163
|
+
- 🟡 High → Implement
|
|
164
|
+
- 🟢 Medium → Implement
|
|
165
|
+
- 🔵 Low → Skip (unless explicitly requested)
|
|
166
|
+
|
|
167
|
+
### Step 6: Implement Fixes
|
|
168
|
+
|
|
169
|
+
For each pending item:
|
|
170
|
+
|
|
171
|
+
1. **Read the full details:**
|
|
172
|
+
```bash
|
|
173
|
+
ace-review-feedback show {id}
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
2. **Implement the fix** based on the recommendation
|
|
177
|
+
|
|
178
|
+
3. **Mark as resolved:**
|
|
179
|
+
```bash
|
|
180
|
+
ace-review-feedback resolve {id} --resolution "Fixed in commit abc123"
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
4. **Commit the fix** with a clear message referencing the feedback item
|
|
184
|
+
|
|
185
|
+
### Step 7: Handle Not-Applicable Items
|
|
186
|
+
|
|
187
|
+
Before skipping, complete the verification checklist:
|
|
188
|
+
|
|
189
|
+
1. **Read the code** - Does the issue actually still exist?
|
|
190
|
+
2. **Check current changes** - Was this already fixed in this PR?
|
|
191
|
+
3. **Consider effort** - Is this a quick win (< 5 min) that should just be done?
|
|
192
|
+
|
|
193
|
+
For items that won't be fixed in this PR:
|
|
194
|
+
|
|
195
|
+
```bash
|
|
196
|
+
# Design decision - intentionally this way
|
|
197
|
+
ace-review-feedback verify {id} --skip --research "Design: uses polling for simplicity"
|
|
198
|
+
|
|
199
|
+
# Important but deferred - ALWAYS create/reference a task
|
|
200
|
+
ace-review-feedback verify {id} --skip --research "Tracked in task 253"
|
|
201
|
+
```
|
|
202
|
+
|
|
203
|
+
**Never skip with "out of scope"** - either:
|
|
204
|
+
- It's a design decision (explain why)
|
|
205
|
+
- It needs a follow-up task (create one and reference it)
|
|
206
|
+
|
|
207
|
+
## Quick Reference
|
|
208
|
+
|
|
209
|
+
```bash
|
|
210
|
+
# Discovery
|
|
211
|
+
ace-review --list-presets # Available presets
|
|
212
|
+
ace-review --list-prompts # Available prompt modules
|
|
213
|
+
|
|
214
|
+
# Subject types (type:value syntax)
|
|
215
|
+
--subject staged # Staged changes (keyword)
|
|
216
|
+
--subject working # Unstaged changes (keyword)
|
|
217
|
+
--subject diff:origin/main..HEAD # Git range
|
|
218
|
+
--subject pr:123 # PR diff
|
|
219
|
+
--subject files:lib/**/*.rb # File pattern
|
|
220
|
+
--subject task:145 # Task context
|
|
221
|
+
|
|
222
|
+
# Feedback commands
|
|
223
|
+
ace-review-feedback list # All feedback
|
|
224
|
+
ace-review-feedback list --status draft # Unverified items
|
|
225
|
+
ace-review-feedback list --status pending # Verified valid items
|
|
226
|
+
ace-review-feedback list --session <path> # From specific session
|
|
227
|
+
ace-review-feedback show {id} # Full item details
|
|
228
|
+
ace-review-feedback verify {id} --valid # Mark as valid
|
|
229
|
+
ace-review-feedback verify {id} --invalid # Mark as false positive
|
|
230
|
+
ace-review-feedback verify {id} --skip # Mark as skipped
|
|
231
|
+
ace-review-feedback resolve {id} # Mark as fixed
|
|
232
|
+
|
|
233
|
+
# Common patterns
|
|
234
|
+
ace-review --auto-execute # Default preset
|
|
235
|
+
ace-review --subject staged --auto-execute # Staged only
|
|
236
|
+
ace-review --subject diff:origin/main..HEAD --auto-execute # vs main
|
|
237
|
+
ace-review --subject pr:76 --subject files:README.md --auto-execute # Combined
|
|
238
|
+
|
|
239
|
+
# Debug
|
|
240
|
+
ace-review --dry-run # See what would run
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
## Common Mistakes
|
|
244
|
+
|
|
245
|
+
❌ **Wrong**: `ace-review --subject path/to/file`
|
|
246
|
+
✅ **Correct**: `ace-review --subject files:path/to/file`
|
|
247
|
+
|
|
248
|
+
❌ **Wrong**: `ace-review --subject 123`
|
|
249
|
+
✅ **Correct**: `ace-review --subject pr:123`
|
|
250
|
+
|
|
251
|
+
❌ **Wrong**: `ace-review --subject origin/main..HEAD`
|
|
252
|
+
✅ **Correct**: `ace-review --subject diff:origin/main..HEAD`
|
|
253
|
+
|
|
254
|
+
The type prefix (`files:`, `pr:`, `diff:`, `task:`) is **required** for all subjects except the keywords `staged` and `working`.
|
|
255
|
+
|
|
256
|
+
## Success Criteria
|
|
257
|
+
|
|
258
|
+
- [ ] Review completed with feedback items
|
|
259
|
+
- [ ] Feedback items verified (Critical/High priority)
|
|
260
|
+
- [ ] False positives marked as invalid
|
|
261
|
+
- [ ] Confirmed items implemented with commits
|
|
262
|
+
- [ ] Items marked as resolved with commit references
|
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
---
|
|
2
|
+
doc-type: workflow
|
|
3
|
+
title: Verify Feedback Workflow
|
|
4
|
+
purpose: Verify feedback items through multi-dimensional claim analysis
|
|
5
|
+
ace-docs:
|
|
6
|
+
last-updated: 2026-03-12
|
|
7
|
+
last-checked: 2026-03-21
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Verify Feedback Workflow
|
|
11
|
+
|
|
12
|
+
## Goal
|
|
13
|
+
|
|
14
|
+
Verify each feedback item through systematic claim analysis, marking items as valid, invalid, or skipped based on evidence gathered from the codebase, documentation, and execution context.
|
|
15
|
+
|
|
16
|
+
## Why This Workflow Exists
|
|
17
|
+
|
|
18
|
+
Simple verification ("does this code exist?") catches some false positives, but misses **scope claims** - assertions about where or when code executes. For example:
|
|
19
|
+
|
|
20
|
+
- "E2E tests may fail in CI" → E2E tests don't run in CI (scope error)
|
|
21
|
+
- "Missing API key validation" → Keys are validated in middleware (location error)
|
|
22
|
+
- "Thread-unsafe code" → Code only runs in single-threaded context (context error)
|
|
23
|
+
|
|
24
|
+
This workflow ensures each claim dimension is verified.
|
|
25
|
+
|
|
26
|
+
## Arguments
|
|
27
|
+
|
|
28
|
+
- `--session <path>` - Specific session directory (optional)
|
|
29
|
+
- `--status draft` - Filter to unverified items (default)
|
|
30
|
+
|
|
31
|
+
## Prerequisites
|
|
32
|
+
|
|
33
|
+
Before running this workflow, you need feedback items from a code review:
|
|
34
|
+
1. Run a code review: `ace-bundle wfi://review/run` or `ace-bundle wfi://review/pr`
|
|
35
|
+
2. Feedback items will be in `draft` status
|
|
36
|
+
|
|
37
|
+
## Instructions
|
|
38
|
+
|
|
39
|
+
### Step 1: List Draft Feedback Items
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
# List unverified items
|
|
43
|
+
ace-review-feedback list --status draft
|
|
44
|
+
|
|
45
|
+
# From specific session
|
|
46
|
+
ace-review-feedback list --status draft --session <path>
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
If no items appear, the review may not have generated extractable feedback.
|
|
50
|
+
|
|
51
|
+
### Step 2: For Each Item, Run Multi-Dimensional Verification
|
|
52
|
+
|
|
53
|
+
For each feedback item, verify claims across multiple dimensions before marking valid/invalid/skipped.
|
|
54
|
+
|
|
55
|
+
#### 2a. Read the Feedback Item
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
ace-review-feedback show <id>
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Identify the claim being made. Common claim types:
|
|
62
|
+
|
|
63
|
+
| Claim Type | Example | Verification Question |
|
|
64
|
+
|------------|---------|----------------------|
|
|
65
|
+
| **Existence** | "Method X is undefined" | Does X exist in codebase? |
|
|
66
|
+
| **Scope** | "Fails in CI environment" | Does this code run in CI? |
|
|
67
|
+
| **Documentation** | "Behavior is undocumented" | Are there docs elsewhere? |
|
|
68
|
+
| **Pattern** | "Inconsistent with codebase" | What patterns exist? |
|
|
69
|
+
| **Security** | "Exposes sensitive data" | What data flows here? |
|
|
70
|
+
| **Performance** | "N+1 query issue" | How is this code called? |
|
|
71
|
+
|
|
72
|
+
#### 2b. Verify Each Claim Dimension
|
|
73
|
+
|
|
74
|
+
For each feedback item, work through applicable verification questions:
|
|
75
|
+
|
|
76
|
+
**1. Is the factual claim true?**
|
|
77
|
+
- If "X doesn't exist" → Search for X
|
|
78
|
+
- If "missing validation" → Check the specific code path
|
|
79
|
+
- If "undefined reference" → Verify the symbol resolution
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
# Example: Verify class exists
|
|
83
|
+
grep -rn "class TaskPatternExtractor" ace-git/lib/
|
|
84
|
+
|
|
85
|
+
# Example: Check for validation
|
|
86
|
+
grep -rn "validate" path/to/file.rb
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
**2. Does the scope match?**
|
|
90
|
+
- If "fails in CI" → Does this code execute in CI?
|
|
91
|
+
- If "production issue" → Does config differ in production?
|
|
92
|
+
- If "user-facing" → Is this actually exposed to users?
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
# Example: Check CI workflow for test execution
|
|
96
|
+
cat .github/workflows/test.yml | grep -A5 "run:"
|
|
97
|
+
|
|
98
|
+
# Example: Check if E2E tests run in CI
|
|
99
|
+
grep -rn "e2e\|end-to-end" .github/workflows/
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
**3. Is it already addressed elsewhere?**
|
|
103
|
+
- If "missing docs" → Check README, handbook, inline comments
|
|
104
|
+
- If "no error handling" → Check if caller handles errors
|
|
105
|
+
- If "missing validation" → Check middleware/filters
|
|
106
|
+
|
|
107
|
+
```bash
|
|
108
|
+
# Example: Check for documentation
|
|
109
|
+
grep -rn "api-key\|API_KEY" README.md docs/ handbook/
|
|
110
|
+
|
|
111
|
+
# Example: Check frontmatter for requirements
|
|
112
|
+
head -30 path/to/file.md
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
**4. Does it follow established patterns?**
|
|
116
|
+
- If "inconsistent approach" → What do similar files do?
|
|
117
|
+
- If "should use X instead" → What's the project standard?
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
# Example: Check existing patterns
|
|
121
|
+
grep -rn "def self\." lib/ace/review/atoms/ | head -20
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
#### 2c. Document Verification Result
|
|
125
|
+
|
|
126
|
+
Based on verification:
|
|
127
|
+
|
|
128
|
+
**Valid Finding** - All claim dimensions check out:
|
|
129
|
+
```bash
|
|
130
|
+
ace-review-feedback verify <id> --valid --research "Confirmed: <evidence>"
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
**Invalid Finding** - Any claim dimension fails:
|
|
134
|
+
```bash
|
|
135
|
+
ace-review-feedback verify <id> --invalid --research "<dimension> incorrect: <evidence>"
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
**Skip Finding** - Valid but not being fixed:
|
|
139
|
+
```bash
|
|
140
|
+
ace-review-feedback verify <id> --skip --research "Design: <reason>"
|
|
141
|
+
ace-review-feedback verify <id> --skip --research "Tracked in task XXX"
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
### Step 3: Common False Positive Patterns
|
|
145
|
+
|
|
146
|
+
Watch for these scope errors that simple verification misses:
|
|
147
|
+
|
|
148
|
+
| False Positive Pattern | How to Detect |
|
|
149
|
+
|----------------------|---------------|
|
|
150
|
+
| "CI environment" claims | Check if code actually runs in CI workflows |
|
|
151
|
+
| "Production" claims | Verify environment-specific behavior |
|
|
152
|
+
| "External API" claims | Check if feature is actually enabled/used |
|
|
153
|
+
| "Thread safety" claims | Verify concurrency context |
|
|
154
|
+
| "User input" claims | Trace actual data flow |
|
|
155
|
+
|
|
156
|
+
### Step 4: Verification Decision Table
|
|
157
|
+
|
|
158
|
+
| Factual Claim | Scope Correct | Addressed | Verdict |
|
|
159
|
+
|--------------|---------------|-----------|---------|
|
|
160
|
+
| True | True | No | **VALID** |
|
|
161
|
+
| True | True | Yes | **INVALID** (already addressed) |
|
|
162
|
+
| True | False | - | **INVALID** (scope error) |
|
|
163
|
+
| False | - | - | **INVALID** (factual error) |
|
|
164
|
+
|
|
165
|
+
### Step 5: Final Summary
|
|
166
|
+
|
|
167
|
+
After verifying all items:
|
|
168
|
+
|
|
169
|
+
```bash
|
|
170
|
+
# Check verification status
|
|
171
|
+
ace-review-feedback list
|
|
172
|
+
|
|
173
|
+
# Should show items as pending (valid) or invalid
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
## Examples
|
|
177
|
+
|
|
178
|
+
### Example 1: CI Scope Error
|
|
179
|
+
|
|
180
|
+
**Feedback**: "E2E tests may fail in CI environments without API keys"
|
|
181
|
+
|
|
182
|
+
**Verification**:
|
|
183
|
+
1. Factual: Do E2E tests make API calls? → Yes
|
|
184
|
+
2. Scope: Do E2E tests run in CI? → **NO** (check workflows)
|
|
185
|
+
3. Addressed: Are API requirements documented? → Yes (frontmatter)
|
|
186
|
+
|
|
187
|
+
**Result**: INVALID - scope claim is wrong
|
|
188
|
+
```bash
|
|
189
|
+
ace-review-feedback verify <id> --invalid --research "E2E tests are agent-executed, not CI. API requirements documented in frontmatter."
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
### Example 2: Valid Finding
|
|
193
|
+
|
|
194
|
+
**Feedback**: "Missing null check in user_handler.rb:45"
|
|
195
|
+
|
|
196
|
+
**Verification**:
|
|
197
|
+
1. Factual: Is there a null check? → No
|
|
198
|
+
2. Scope: Can this receive null? → Yes (from API response)
|
|
199
|
+
3. Addressed: Is null handled elsewhere? → No
|
|
200
|
+
|
|
201
|
+
**Result**: VALID
|
|
202
|
+
```bash
|
|
203
|
+
ace-review-feedback verify <id> --valid --research "Confirmed: API can return null, no check present"
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
### Example 3: Location Error
|
|
207
|
+
|
|
208
|
+
**Feedback**: "No input validation for user email"
|
|
209
|
+
|
|
210
|
+
**Verification**:
|
|
211
|
+
1. Factual: Is email validated in handler? → No
|
|
212
|
+
2. Scope: Is this the entry point? → Yes
|
|
213
|
+
3. Addressed: Is validation elsewhere? → **YES** (middleware)
|
|
214
|
+
|
|
215
|
+
**Result**: INVALID - validation exists in different location
|
|
216
|
+
```bash
|
|
217
|
+
ace-review-feedback verify <id> --invalid --research "Email validated in AuthMiddleware:23"
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
## Quick Reference
|
|
221
|
+
|
|
222
|
+
> **Tip**: Exact flag syntax per subcommand is available in the embedded `<feedback_cli_reference>` section above (loaded via ace-bundle).
|
|
223
|
+
|
|
224
|
+
```bash
|
|
225
|
+
# List items to verify
|
|
226
|
+
ace-review-feedback list --status draft
|
|
227
|
+
|
|
228
|
+
# Show item details
|
|
229
|
+
ace-review-feedback show <id>
|
|
230
|
+
|
|
231
|
+
# Mark as valid (confirmed issue)
|
|
232
|
+
ace-review-feedback verify <id> --valid --research "Evidence..."
|
|
233
|
+
|
|
234
|
+
# Mark as invalid (false positive)
|
|
235
|
+
ace-review-feedback verify <id> --invalid --research "Reason..."
|
|
236
|
+
|
|
237
|
+
# Mark as skipped (valid but not fixing)
|
|
238
|
+
ace-review-feedback verify <id> --skip --research "Design: reason..."
|
|
239
|
+
|
|
240
|
+
# Search helpers
|
|
241
|
+
grep -rn "pattern" path/ # Find code
|
|
242
|
+
cat file | head -30 # Check frontmatter
|
|
243
|
+
ls .github/workflows/ # Check CI config
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
## Choosing Between Verification Modes
|
|
247
|
+
|
|
248
|
+
All three modes archive feedback items, but they mean different things:
|
|
249
|
+
|
|
250
|
+
```
|
|
251
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
252
|
+
│ Is the feedback claim factually correct? │
|
|
253
|
+
├─────────────────┬───────────────────────────────────────────────┤
|
|
254
|
+
│ NO │ YES │
|
|
255
|
+
│ → verify --invalid │ → Are you fixing it? │
|
|
256
|
+
│ (False positive) │ ├─ YES → verify --valid (then resolve) │
|
|
257
|
+
│ │ └─ NO → verify --skip "..." │
|
|
258
|
+
│ │ (Not applicable) │
|
|
259
|
+
└────────────────────┴─────────────────────────────────────────────┘
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
| Question | `verify --invalid` | `verify --skip` |
|
|
263
|
+
|----------|-------------------|-----------------|
|
|
264
|
+
| Is the claim factually wrong? | ✅ Yes | ❌ No |
|
|
265
|
+
| Is the finding correct but not fixed? | ❌ No | ✅ Yes |
|
|
266
|
+
|
|
267
|
+
### Quick Examples
|
|
268
|
+
|
|
269
|
+
**`verify --invalid`** - The finding is incorrect:
|
|
270
|
+
- "Code doesn't exist" → Actually exists
|
|
271
|
+
- "Missing validation" → Exists elsewhere
|
|
272
|
+
- "Fails in CI" → Doesn't run in CI
|
|
273
|
+
|
|
274
|
+
**`verify --skip`** - The finding is correct but not being fixed:
|
|
275
|
+
- "Design: using polling for simplicity"
|
|
276
|
+
- "Tracked in task 253"
|
|
277
|
+
- "Duplicate of abc120"
|
|
278
|
+
|
|
279
|
+
## Success Criteria
|
|
280
|
+
|
|
281
|
+
- [ ] Each draft feedback item reviewed
|
|
282
|
+
- [ ] Factual claims verified against codebase
|
|
283
|
+
- [ ] Scope claims verified (where/when code executes)
|
|
284
|
+
- [ ] Existing documentation/handling checked
|
|
285
|
+
- [ ] Each item marked valid or invalid with research notes
|
|
286
|
+
- [ ] No items left in draft status
|