@soleri/cli 1.7.0 → 1.9.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/code-reviewer/.claude/hookify.focus-ring-required.local.md +21 -0
- package/code-reviewer/.claude/hookify.no-ai-attribution.local.md +18 -0
- package/code-reviewer/.claude/hookify.no-any-types.local.md +18 -0
- package/code-reviewer/.claude/hookify.no-console-log.local.md +21 -0
- package/code-reviewer/.claude/hookify.no-important.local.md +18 -0
- package/code-reviewer/.claude/hookify.no-inline-styles.local.md +21 -0
- package/code-reviewer/.claude/hookify.semantic-html.local.md +18 -0
- package/code-reviewer/.claude/hookify.ux-touch-targets.local.md +18 -0
- package/code-reviewer/.mcp.json +11 -0
- package/code-reviewer/README.md +346 -0
- package/code-reviewer/package-lock.json +4484 -0
- package/code-reviewer/package.json +45 -0
- package/code-reviewer/scripts/copy-assets.js +15 -0
- package/code-reviewer/scripts/setup.sh +130 -0
- package/code-reviewer/skills/brainstorming/SKILL.md +170 -0
- package/code-reviewer/skills/code-patrol/SKILL.md +176 -0
- package/code-reviewer/skills/context-resume/SKILL.md +143 -0
- package/code-reviewer/skills/executing-plans/SKILL.md +201 -0
- package/code-reviewer/skills/fix-and-learn/SKILL.md +164 -0
- package/code-reviewer/skills/health-check/SKILL.md +225 -0
- package/code-reviewer/skills/second-opinion/SKILL.md +142 -0
- package/code-reviewer/skills/systematic-debugging/SKILL.md +230 -0
- package/code-reviewer/skills/verification-before-completion/SKILL.md +170 -0
- package/code-reviewer/skills/writing-plans/SKILL.md +207 -0
- package/code-reviewer/src/__tests__/facades.test.ts +598 -0
- package/code-reviewer/src/activation/activate.ts +125 -0
- package/code-reviewer/src/activation/claude-md-content.ts +217 -0
- package/code-reviewer/src/activation/inject-claude-md.ts +113 -0
- package/code-reviewer/src/extensions/index.ts +47 -0
- package/code-reviewer/src/extensions/ops/example.ts +28 -0
- package/code-reviewer/src/identity/persona.ts +62 -0
- package/code-reviewer/src/index.ts +278 -0
- package/code-reviewer/src/intelligence/data/architecture.json +5 -0
- package/code-reviewer/src/intelligence/data/code-review.json +5 -0
- package/code-reviewer/tsconfig.json +30 -0
- package/code-reviewer/vitest.config.ts +23 -0
- package/dist/commands/create.js +6 -0
- package/dist/commands/create.js.map +1 -1
- package/dist/commands/extend.d.ts +2 -0
- package/dist/commands/extend.js +167 -0
- package/dist/commands/extend.js.map +1 -0
- package/dist/main.js +2 -0
- package/dist/main.js.map +1 -1
- package/dist/prompts/archetypes.d.ts +21 -0
- package/dist/prompts/archetypes.js +183 -0
- package/dist/prompts/archetypes.js.map +1 -0
- package/dist/prompts/create-wizard.d.ts +1 -1
- package/dist/prompts/create-wizard.js +295 -76
- package/dist/prompts/create-wizard.js.map +1 -1
- package/dist/prompts/playbook.d.ts +63 -0
- package/dist/prompts/playbook.js +250 -0
- package/dist/prompts/playbook.js.map +1 -0
- package/package.json +1 -1
- package/src/commands/create.ts +6 -0
- package/src/commands/extend.ts +197 -0
- package/src/main.ts +2 -0
- package/src/prompts/archetypes.ts +212 -0
- package/src/prompts/create-wizard.ts +345 -69
- package/src/prompts/playbook.ts +301 -0
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: second-opinion
|
|
3
|
+
description: Use when the user asks "should I", "what do you think about", "which approach", "compare options", "what would you recommend", "pros and cons", "trade-offs", or faces any technical decision and wants an informed recommendation backed by vault knowledge, brain patterns, and web research.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Second Opinion — Decision Support From All Sources
|
|
7
|
+
|
|
8
|
+
Before making any technical decision, get an informed recommendation that synthesizes vault knowledge, brain patterns, cross-project experience, and web research. Never decide in a vacuum.
|
|
9
|
+
|
|
10
|
+
## When to Use
|
|
11
|
+
|
|
12
|
+
- "Should I use Redis or Memcached?"
|
|
13
|
+
- "What's the best way to handle auth?"
|
|
14
|
+
- "Which testing framework?"
|
|
15
|
+
- "Microservices or monolith?"
|
|
16
|
+
- Any fork-in-the-road technical decision
|
|
17
|
+
|
|
18
|
+
## The Magic: Multi-Source Decision Intelligence
|
|
19
|
+
|
|
20
|
+
### Step 1: Understand the Decision
|
|
21
|
+
|
|
22
|
+
Classify the intent to understand what kind of decision this is:
|
|
23
|
+
|
|
24
|
+
```
|
|
25
|
+
code-reviewer_core op:route_intent
|
|
26
|
+
params: { prompt: "<user's question>" }
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
### Step 2: Search All Knowledge Sources (in order)
|
|
30
|
+
|
|
31
|
+
**Vault — has this been decided before?**
|
|
32
|
+
```
|
|
33
|
+
code-reviewer_core op:search_intelligent
|
|
34
|
+
params: { query: "<the decision or options being considered>" }
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
Look specifically for:
|
|
38
|
+
- Previous decisions on this topic (type: "decision")
|
|
39
|
+
- Patterns that favor one approach
|
|
40
|
+
- Anti-patterns that warn against an approach
|
|
41
|
+
|
|
42
|
+
**Brain — what's proven to work?**
|
|
43
|
+
```
|
|
44
|
+
code-reviewer_core op:brain_strengths
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
```
|
|
48
|
+
code-reviewer_core op:brain_recommend
|
|
49
|
+
params: { projectName: "<current project>" }
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
**Cross-project — what did other projects choose?**
|
|
53
|
+
```
|
|
54
|
+
code-reviewer_core op:memory_cross_project_search
|
|
55
|
+
params: { query: "<the decision topic>", crossProject: true }
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
**Memory — any relevant context from past sessions?**
|
|
59
|
+
```
|
|
60
|
+
code-reviewer_core op:memory_search
|
|
61
|
+
params: { query: "<decision topic>" }
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
**Web — what does the broader community say?**
|
|
65
|
+
Search the web for:
|
|
66
|
+
- Comparison articles (X vs Y for [use case])
|
|
67
|
+
- Benchmarks and performance data
|
|
68
|
+
- Community consensus on best practices
|
|
69
|
+
- Known limitations and gotchas
|
|
70
|
+
|
|
71
|
+
### Step 3: Synthesize and Present
|
|
72
|
+
|
|
73
|
+
Format the recommendation as a decision brief:
|
|
74
|
+
|
|
75
|
+
```
|
|
76
|
+
## Decision: [Question]
|
|
77
|
+
|
|
78
|
+
### What the Vault Says
|
|
79
|
+
[Existing decisions, patterns, and anti-patterns from vault]
|
|
80
|
+
|
|
81
|
+
### What the Brain Recommends
|
|
82
|
+
[Proven patterns, cross-project insights]
|
|
83
|
+
|
|
84
|
+
### What the Web Says
|
|
85
|
+
[Community consensus, benchmarks, comparison data]
|
|
86
|
+
|
|
87
|
+
### Options Analysis
|
|
88
|
+
|
|
89
|
+
| Criteria | Option A | Option B | Option C |
|
|
90
|
+
|----------|----------|----------|----------|
|
|
91
|
+
| [criteria 1] | ... | ... | ... |
|
|
92
|
+
| [criteria 2] | ... | ... | ... |
|
|
93
|
+
| Vault support | [existing patterns?] | [existing patterns?] | — |
|
|
94
|
+
| Brain confidence | [strength score] | [strength score] | — |
|
|
95
|
+
|
|
96
|
+
### Recommendation
|
|
97
|
+
[Clear recommendation with reasoning]
|
|
98
|
+
|
|
99
|
+
### Risks
|
|
100
|
+
[What could go wrong with the recommended approach]
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### Step 4: Capture the Decision
|
|
104
|
+
|
|
105
|
+
Once the user decides, capture it to the vault for future reference:
|
|
106
|
+
|
|
107
|
+
```
|
|
108
|
+
code-reviewer_core op:capture_knowledge
|
|
109
|
+
params: {
|
|
110
|
+
title: "<decision title>",
|
|
111
|
+
description: "<chosen option, rationale, rejected alternatives and why>",
|
|
112
|
+
type: "decision",
|
|
113
|
+
category: "<relevant domain>",
|
|
114
|
+
tags: ["<option-a>", "<option-b>", "decision", "<domain>"]
|
|
115
|
+
}
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
This is critical — the next person who faces the same decision will find it in the vault.
|
|
119
|
+
|
|
120
|
+
## The Magic
|
|
121
|
+
|
|
122
|
+
This feels like magic because the user asks "should I use X?" and instead of a generic AI opinion, they get:
|
|
123
|
+
1. What their own project decided before (vault)
|
|
124
|
+
2. What's proven to work across projects (brain)
|
|
125
|
+
3. What other linked projects chose (cross-project)
|
|
126
|
+
4. What the broader community recommends (web)
|
|
127
|
+
5. A synthesized recommendation with trade-offs
|
|
128
|
+
6. The decision captured for the next person who asks
|
|
129
|
+
|
|
130
|
+
It's like having a senior architect who remembers every decision ever made.
|
|
131
|
+
|
|
132
|
+
## Agent Tools Reference
|
|
133
|
+
|
|
134
|
+
| Op | When to Use |
|
|
135
|
+
|----|-------------|
|
|
136
|
+
| `route_intent` | Classify the decision type |
|
|
137
|
+
| `search_intelligent` | Find previous decisions and patterns |
|
|
138
|
+
| `brain_strengths` | Proven approaches |
|
|
139
|
+
| `brain_recommend` | Project-specific recommendations |
|
|
140
|
+
| `memory_cross_project_search` | What other projects decided |
|
|
141
|
+
| `memory_search` | Session context for this decision |
|
|
142
|
+
| `capture_knowledge` | Persist the final decision |
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: systematic-debugging
|
|
3
|
+
description: Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
<!-- Adapted from superpowers (MIT License) -->
|
|
7
|
+
|
|
8
|
+
# Systematic Debugging
|
|
9
|
+
|
|
10
|
+
## Overview
|
|
11
|
+
|
|
12
|
+
Random fixes waste time and create new bugs. Quick patches mask underlying issues.
|
|
13
|
+
|
|
14
|
+
**Core principle:** ALWAYS find root cause before attempting fixes. Symptom fixes are failure.
|
|
15
|
+
|
|
16
|
+
**Violating the letter of this process is violating the spirit of debugging.**
|
|
17
|
+
|
|
18
|
+
## The Iron Law
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
NO FIXES WITHOUT ROOT CAUSE INVESTIGATION FIRST
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
If you haven't completed Phase 1, you cannot propose fixes.
|
|
25
|
+
|
|
26
|
+
## When to Use
|
|
27
|
+
|
|
28
|
+
Use for ANY technical issue:
|
|
29
|
+
- Test failures
|
|
30
|
+
- Bugs in production
|
|
31
|
+
- Unexpected behavior
|
|
32
|
+
- Performance problems
|
|
33
|
+
- Build failures
|
|
34
|
+
- Integration issues
|
|
35
|
+
|
|
36
|
+
**Use this ESPECIALLY when:**
|
|
37
|
+
- Under time pressure (emergencies make guessing tempting)
|
|
38
|
+
- "Just one quick fix" seems obvious
|
|
39
|
+
- You've already tried multiple fixes
|
|
40
|
+
- Previous fix didn't work
|
|
41
|
+
- You don't fully understand the issue
|
|
42
|
+
|
|
43
|
+
## Phase 0: Search Before Investigating
|
|
44
|
+
|
|
45
|
+
**BEFORE touching any code**, search for existing solutions. Follow this order:
|
|
46
|
+
|
|
47
|
+
### Vault First
|
|
48
|
+
```
|
|
49
|
+
code-reviewer_core op:search_intelligent
|
|
50
|
+
params: { query: "<description of the bug or error message>" }
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
If the vault has a matching anti-pattern or previous fix, it likely contains the root cause and solution — apply it directly. This can save hours of investigation.
|
|
54
|
+
|
|
55
|
+
Also check brain strengths for relevant debugging patterns:
|
|
56
|
+
|
|
57
|
+
```
|
|
58
|
+
code-reviewer_core op:brain_strengths
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Check memory for similar bugs across sessions:
|
|
62
|
+
|
|
63
|
+
```
|
|
64
|
+
code-reviewer_core op:memory_search
|
|
65
|
+
params: { query: "<error or symptom>" }
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### Web Search Second
|
|
69
|
+
If the vault has nothing, search the web before investigating from scratch:
|
|
70
|
+
- **Paste the exact error message** — someone likely hit this before
|
|
71
|
+
- **Check GitHub issues** on relevant libraries
|
|
72
|
+
- **Check Stack Overflow** for the error + framework/library combination
|
|
73
|
+
- **Check official docs** — is this a known limitation or misconfiguration?
|
|
74
|
+
|
|
75
|
+
A 30-second search that finds "this is a known issue in v3.2, upgrade to v3.3" saves hours of root cause investigation.
|
|
76
|
+
|
|
77
|
+
### Then Investigate
|
|
78
|
+
Only if vault and web search produce no answer, proceed to Phase 1.
|
|
79
|
+
|
|
80
|
+
## Start a Debug Loop
|
|
81
|
+
|
|
82
|
+
For complex bugs, start a validation loop to track investigation iterations:
|
|
83
|
+
|
|
84
|
+
```
|
|
85
|
+
code-reviewer_core op:loop_start
|
|
86
|
+
params: { prompt: "Debug: <bug description>", mode: "custom" }
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
## The Four Phases
|
|
90
|
+
|
|
91
|
+
You MUST complete each phase before proceeding to the next.
|
|
92
|
+
|
|
93
|
+
### Phase 1: Root Cause Investigation
|
|
94
|
+
|
|
95
|
+
**BEFORE attempting ANY fix:**
|
|
96
|
+
|
|
97
|
+
1. Read Error Messages Carefully
|
|
98
|
+
2. Reproduce Consistently
|
|
99
|
+
3. Check Recent Changes
|
|
100
|
+
4. Gather Evidence in Multi-Component Systems (add diagnostic instrumentation at each component boundary)
|
|
101
|
+
5. Trace Data Flow backward through call stack
|
|
102
|
+
|
|
103
|
+
Track each investigation step:
|
|
104
|
+
```
|
|
105
|
+
code-reviewer_core op:loop_iterate
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
### Phase 2: Pattern Analysis
|
|
109
|
+
|
|
110
|
+
1. Find Working Examples
|
|
111
|
+
2. Compare Against References (read completely, don't skim)
|
|
112
|
+
3. Identify Differences
|
|
113
|
+
4. Understand Dependencies
|
|
114
|
+
|
|
115
|
+
Search vault for working patterns to compare against:
|
|
116
|
+
```
|
|
117
|
+
code-reviewer_core op:search_intelligent
|
|
118
|
+
params: { query: "<working feature similar to broken one>" }
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
### Phase 3: Hypothesis and Testing
|
|
122
|
+
|
|
123
|
+
1. Form Single Hypothesis ("I think X is the root cause because Y")
|
|
124
|
+
2. Test Minimally (one variable at a time)
|
|
125
|
+
3. Verify Before Continuing
|
|
126
|
+
4. When You Don't Know — say so, ask for help
|
|
127
|
+
|
|
128
|
+
### Phase 4: Implementation
|
|
129
|
+
|
|
130
|
+
1. Create Failing Test Case (use test-driven-development skill)
|
|
131
|
+
2. Implement Single Fix (root cause only, one change at a time)
|
|
132
|
+
3. Verify Fix
|
|
133
|
+
4. If Fix Doesn't Work: count attempts. If < 3, return to Phase 1. If >= 3, STOP and question architecture.
|
|
134
|
+
5. If 3+ Fixes Failed: Question Architecture — discuss with human partner before attempting more fixes.
|
|
135
|
+
|
|
136
|
+
## Phase 5: Capture the Learning
|
|
137
|
+
|
|
138
|
+
Complete the debug loop:
|
|
139
|
+
```
|
|
140
|
+
code-reviewer_core op:loop_complete
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
**MANDATORY after every resolved bug.** A fix without a capture is an incomplete fix.
|
|
144
|
+
|
|
145
|
+
```
|
|
146
|
+
code-reviewer_core op:capture_knowledge
|
|
147
|
+
params: {
|
|
148
|
+
title: "<short bug description>",
|
|
149
|
+
description: "<root cause, solution, and what made it hard to find>",
|
|
150
|
+
type: "anti-pattern",
|
|
151
|
+
category: "<relevant domain>",
|
|
152
|
+
tags: ["<relevant>", "<tags>"]
|
|
153
|
+
}
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
For quick captures when the fix is straightforward:
|
|
157
|
+
|
|
158
|
+
```
|
|
159
|
+
code-reviewer_core op:capture_quick
|
|
160
|
+
params: {
|
|
161
|
+
title: "<bug description>",
|
|
162
|
+
description: "<root cause and fix>"
|
|
163
|
+
}
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
Capture a session summary:
|
|
167
|
+
```
|
|
168
|
+
code-reviewer_core op:session_capture
|
|
169
|
+
params: { summary: "<bug, root cause, fix, files modified>" }
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
This is what makes the agent smarter over time. Next time someone hits a similar bug, Phase 0 vault search will surface your solution immediately.
|
|
173
|
+
|
|
174
|
+
## Red Flags - STOP and Follow Process
|
|
175
|
+
|
|
176
|
+
- "Quick fix for now, investigate later"
|
|
177
|
+
- "Just try changing X and see if it works"
|
|
178
|
+
- "Add multiple changes, run tests"
|
|
179
|
+
- "Skip the test, I'll manually verify"
|
|
180
|
+
- "It's probably X, let me fix that"
|
|
181
|
+
- "I don't fully understand but this might work"
|
|
182
|
+
- Proposing solutions before tracing data flow
|
|
183
|
+
- "One more fix attempt" (when already tried 2+)
|
|
184
|
+
- Each fix reveals new problem in different place
|
|
185
|
+
|
|
186
|
+
**ALL of these mean: STOP. Return to Phase 1.**
|
|
187
|
+
|
|
188
|
+
## Common Rationalizations
|
|
189
|
+
|
|
190
|
+
| Excuse | Reality |
|
|
191
|
+
|--------|---------|
|
|
192
|
+
| "Issue is simple, don't need process" | Simple issues have root causes too. |
|
|
193
|
+
| "Emergency, no time for process" | Systematic is FASTER than guess-and-check thrashing. |
|
|
194
|
+
| "Just try this first, then investigate" | First fix sets the pattern. Do it right from the start. |
|
|
195
|
+
| "I'll write test after confirming fix works" | Untested fixes don't stick. Test first proves it. |
|
|
196
|
+
| "Multiple fixes at once saves time" | Can't isolate what worked. Causes new bugs. |
|
|
197
|
+
| "Reference too long, I'll adapt the pattern" | Partial understanding guarantees bugs. Read it completely. |
|
|
198
|
+
| "I see the problem, let me fix it" | Seeing symptoms ≠ understanding root cause. |
|
|
199
|
+
| "One more fix attempt" (after 2+ failures) | 3+ failures = architectural problem. Question pattern, don't fix again. |
|
|
200
|
+
| "Skip the vault, I know this one" | The vault may know it better. 30 seconds to check saves hours. |
|
|
201
|
+
|
|
202
|
+
## Quick Reference
|
|
203
|
+
|
|
204
|
+
| Phase | Key Activities | Agent Tools |
|
|
205
|
+
|-------|---------------|-------------|
|
|
206
|
+
| **0. Search First** | Vault search, web search, memory | `search_intelligent`, `brain_strengths`, `memory_search` |
|
|
207
|
+
| **1. Root Cause** | Read errors, reproduce, trace | `loop_iterate` |
|
|
208
|
+
| **2. Pattern** | Find working examples, compare | `search_intelligent` |
|
|
209
|
+
| **3. Hypothesis** | Form theory, test minimally | `loop_iterate` |
|
|
210
|
+
| **4. Implementation** | Create test, fix, verify | `loop_iterate` |
|
|
211
|
+
| **5. Capture** | Persist root cause, close loop | `capture_knowledge`, `loop_complete`, `session_capture` |
|
|
212
|
+
|
|
213
|
+
## Agent Tools Reference
|
|
214
|
+
|
|
215
|
+
| Op | When to Use |
|
|
216
|
+
|----|-------------|
|
|
217
|
+
| `search_intelligent` | Search vault for known bugs and patterns |
|
|
218
|
+
| `brain_strengths` | Check proven debugging patterns |
|
|
219
|
+
| `memory_search` | Search across session memories |
|
|
220
|
+
| `loop_start` | Begin iterative debug cycle |
|
|
221
|
+
| `loop_iterate` | Track each investigation/fix attempt |
|
|
222
|
+
| `loop_complete` | Finish debug cycle |
|
|
223
|
+
| `capture_knowledge` | Full anti-pattern capture |
|
|
224
|
+
| `capture_quick` | Fast capture for simple fixes |
|
|
225
|
+
| `session_capture` | Persist session context |
|
|
226
|
+
|
|
227
|
+
**Related skills:**
|
|
228
|
+
- test-driven-development
|
|
229
|
+
- verification-before-completion
|
|
230
|
+
- fix-and-learn (combines debugging + capture in one workflow)
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: verification-before-completion
|
|
3
|
+
description: Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
<!-- Adapted from superpowers (MIT License) -->
|
|
7
|
+
|
|
8
|
+
# Verification Before Completion
|
|
9
|
+
|
|
10
|
+
## Overview
|
|
11
|
+
|
|
12
|
+
Claiming work is complete without verification is dishonesty, not efficiency.
|
|
13
|
+
|
|
14
|
+
**Core principle:** Evidence before claims, always.
|
|
15
|
+
|
|
16
|
+
**Violating the letter of this rule is violating the spirit of this rule.**
|
|
17
|
+
|
|
18
|
+
## The Iron Law
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
NO COMPLETION CLAIMS WITHOUT FRESH VERIFICATION EVIDENCE
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
If you haven't run the verification command in this message, you cannot claim it passes.
|
|
25
|
+
|
|
26
|
+
## The Gate Function
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
BEFORE claiming any status or expressing satisfaction:
|
|
30
|
+
|
|
31
|
+
1. IDENTIFY: What command proves this claim?
|
|
32
|
+
2. RUN: Execute the FULL command (fresh, complete)
|
|
33
|
+
3. READ: Full output, check exit code, count failures
|
|
34
|
+
4. VERIFY: Does output confirm the claim?
|
|
35
|
+
- If NO: State actual status with evidence
|
|
36
|
+
- If YES: State claim WITH evidence
|
|
37
|
+
5. AGENT CHECK: Run system diagnostics
|
|
38
|
+
6. ONLY THEN: Make the claim
|
|
39
|
+
|
|
40
|
+
Skip any step = lying, not verifying
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
## Agent System Checks
|
|
44
|
+
|
|
45
|
+
After passing all verification commands, run system diagnostics:
|
|
46
|
+
|
|
47
|
+
### Health Check
|
|
48
|
+
```
|
|
49
|
+
code-reviewer_core op:admin_health
|
|
50
|
+
```
|
|
51
|
+
Catches issues tests might miss — vault corruption, stale caches, configuration drift.
|
|
52
|
+
|
|
53
|
+
### Full Diagnostic
|
|
54
|
+
```
|
|
55
|
+
code-reviewer_core op:admin_diagnostic
|
|
56
|
+
```
|
|
57
|
+
Comprehensive system check — module status, database integrity, cache health, configuration validity.
|
|
58
|
+
|
|
59
|
+
### Vault Analytics
|
|
60
|
+
```
|
|
61
|
+
code-reviewer_core op:admin_vault_analytics
|
|
62
|
+
```
|
|
63
|
+
Verify knowledge quality metrics — are capture rates healthy? Any degradation?
|
|
64
|
+
|
|
65
|
+
If any check reports problems, address them before claiming completion.
|
|
66
|
+
|
|
67
|
+
## Common Failures
|
|
68
|
+
|
|
69
|
+
| Claim | Requires | Not Sufficient |
|
|
70
|
+
|-------|----------|----------------|
|
|
71
|
+
| Tests pass | Test command output: 0 failures | Previous run, "should pass" |
|
|
72
|
+
| Linter clean | Linter output: 0 errors | Partial check, extrapolation |
|
|
73
|
+
| Build succeeds | Build command: exit 0 | Linter passing, logs look good |
|
|
74
|
+
| Bug fixed | Test original symptom: passes | Code changed, assumed fixed |
|
|
75
|
+
| Regression test works | Red-green cycle verified | Test passes once |
|
|
76
|
+
| Agent completed | VCS diff shows changes | Agent reports "success" |
|
|
77
|
+
| Requirements met | Line-by-line checklist | Tests passing |
|
|
78
|
+
| Agent healthy | `admin_diagnostic` clean | "No errors in logs" |
|
|
79
|
+
|
|
80
|
+
## Red Flags - STOP
|
|
81
|
+
|
|
82
|
+
- Using "should", "probably", "seems to"
|
|
83
|
+
- Expressing satisfaction before verification ("Great!", "Perfect!", "Done!", etc.)
|
|
84
|
+
- About to commit/push/PR without verification
|
|
85
|
+
- Trusting agent success reports
|
|
86
|
+
- Relying on partial verification
|
|
87
|
+
- Thinking "just this once"
|
|
88
|
+
- Tired and wanting work over
|
|
89
|
+
- ANY wording implying success without having run verification
|
|
90
|
+
|
|
91
|
+
## Rationalization Prevention
|
|
92
|
+
|
|
93
|
+
| Excuse | Reality |
|
|
94
|
+
|--------|---------|
|
|
95
|
+
| "Should work now" | RUN the verification |
|
|
96
|
+
| "I'm confident" | Confidence ≠ evidence |
|
|
97
|
+
| "Just this once" | No exceptions |
|
|
98
|
+
| "Linter passed" | Linter ≠ compiler |
|
|
99
|
+
| "Agent said success" | Verify independently |
|
|
100
|
+
| "I'm tired" | Exhaustion ≠ excuse |
|
|
101
|
+
| "Partial check is enough" | Partial proves nothing |
|
|
102
|
+
| "Different words so rule doesn't apply" | Spirit over letter |
|
|
103
|
+
|
|
104
|
+
## Key Patterns
|
|
105
|
+
|
|
106
|
+
**Tests:**
|
|
107
|
+
```
|
|
108
|
+
[Run test command] [See: 34/34 pass] "All tests pass"
|
|
109
|
+
NOT: "Should pass now" / "Looks correct"
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
**Regression tests (TDD Red-Green):**
|
|
113
|
+
```
|
|
114
|
+
Write -> Run (pass) -> Revert fix -> Run (MUST FAIL) -> Restore -> Run (pass)
|
|
115
|
+
NOT: "I've written a regression test" (without red-green verification)
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
**Build:**
|
|
119
|
+
```
|
|
120
|
+
[Run build] [See: exit 0] "Build passes"
|
|
121
|
+
NOT: "Linter passed" (linter doesn't check compilation)
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
**Requirements:**
|
|
125
|
+
```
|
|
126
|
+
Re-read plan -> Create checklist -> Verify each -> Report gaps or completion
|
|
127
|
+
NOT: "Tests pass, phase complete"
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
**Agent delegation:**
|
|
131
|
+
```
|
|
132
|
+
Agent reports success -> Check VCS diff -> Verify changes -> Report actual state
|
|
133
|
+
NOT: Trust agent report
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
## After Verification — Capture Session
|
|
137
|
+
|
|
138
|
+
Once work is verified complete, capture a session summary so context persists:
|
|
139
|
+
|
|
140
|
+
```
|
|
141
|
+
code-reviewer_core op:session_capture
|
|
142
|
+
params: {
|
|
143
|
+
summary: "<what was accomplished, files modified, key decisions>"
|
|
144
|
+
}
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
This ensures the next session has context about what was verified and completed.
|
|
148
|
+
|
|
149
|
+
## When To Apply
|
|
150
|
+
|
|
151
|
+
**ALWAYS before:**
|
|
152
|
+
- ANY variation of success/completion claims
|
|
153
|
+
- ANY expression of satisfaction
|
|
154
|
+
- ANY positive statement about work state
|
|
155
|
+
- Committing, PR creation, task completion
|
|
156
|
+
- Moving to next task
|
|
157
|
+
- Delegating to agents
|
|
158
|
+
|
|
159
|
+
## The Bottom Line
|
|
160
|
+
|
|
161
|
+
Run the command. Read the output. THEN claim the result. This is non-negotiable.
|
|
162
|
+
|
|
163
|
+
## Agent Tools Reference
|
|
164
|
+
|
|
165
|
+
| Op | When to Use |
|
|
166
|
+
|----|-------------|
|
|
167
|
+
| `admin_health` | Quick system health check |
|
|
168
|
+
| `admin_diagnostic` | Comprehensive system diagnostic |
|
|
169
|
+
| `admin_vault_analytics` | Knowledge quality metrics |
|
|
170
|
+
| `session_capture` | Persist verified completion context |
|