code-review-detection
**Scope**: Detection commands for common failure modes across languages. Load during any perspective review on a real codebase. **Generated**: 2026-04-13
$ npx -y skills add notque/vexjoy-agent --agent claude-codeHow it fires
How this agent gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
Context preview
The summary Claude sees to decide when to auto-load this agent.
**Scope**: Detection commands for common failure modes across languages. Load during any perspective review on a real codebase. **Generated**: 2026-04-13
Agent definition
code-review-detection.mdCode Review Detection Patterns
> **Scope**: Detection commands for common failure modes across languages. Load during any perspective review on a real codebase. > **Generated**: 2026-04-13
---
Pattern Catalog
Handle All Errors (Skeptical Senior, Pedant)
**Detection**:
rg -n ',\s*_\s*:?=\s*\w+' --type go # Go: blank identifier discarding errors
rg -n 'except:' --type py # Python: bare except
rg -n '\.then\(' --type ts | rg -v '\.catch|async' # JS: promise without catch**Signal**: `result, _ := db.Query(...)` — silent error discard means undetected corruption.
**Preferred action**: Handle error, wrap with `%w` (Go 1.13+), use `errors.Is()`/`errors.As()`.
---
Use Correct HTTP Status Codes (Pedant)
**Detection**:
rg -n 'status.*200|StatusOK' --type go | rg -i 'err\|fail\|error' # 200 on error
rg -n 'InternalServerError|status.*500' --type go | rg -i 'invalid\|bad.request' # 500 for client error
rg -n 'NotFound|status.*404' --type go | rg -i 'auth\|permission' # 404 for authz
Per RFC 7231: 400 invalid input, 404 missing resource, 401 missing auth, 403 insufficient permissions.
---
Load Credentials from Environment (Skeptical Senior, Pedant)
**Detection**:
rg -n 'password\s*=\s*"[^"]{4,}"' --type py --type go --type ts -i
rg -n 'api[_-]?key\s*=\s*"[^"]{8,}"' -i
rg -n 'AKIA[0-9A-Z]{16}' # AWS key pattern
grep -rn 'postgres://\|mysql://\|mongodb://' --include="*.go" --include="*.ts" --include="*.py" | grep -v '_test\|example'Credentials in git history are permanent. Load from env vars or secrets manager.
---
Paginate All List Queries (Skeptical Senior)
**Detection**:
rg -n 'SELECT.*FROM' --type go --type py | rg -v 'LIMIT\|COUNT\|SUM\|MIN\|MAX'
rg -n '\.find\(\|\.all\(\|\.fetch\(' --type py | rg -v 'limit\|paginate\|first\|count'
grep -rn 'findAll\|getAll\|fetchAll' --include="*.ts" --include="*.go"1,000 rows in dev = 50 million in prod. Add LIMIT/OFFSET or cursor pagination.
---
Use Atomic Operations (Skeptical Senior)
**Detection**:
grep -rn 'os.path.exists\|path.exists' --include="*.py" | rg -v 'test\|check' # TOCTOU
rg -n 'await.*get\|await.*find' --type ts -A2 | rg 'await.*set\|await.*update' # async race
**Preferred action**: `sync.Map.LoadOrStore()`, mutex-wrapped check-and-store, or `INSERT ON CONFLICT`.
---
Batch Related Queries (Skeptical Senior)
**Detection**:
rg -n 'for.*in.*\.(all|filter|objects)' --type py -A3 | rg '\.(name|id|title|email)\b'
rg -n 'for.*range' --type go -A5 | rg 'db\.Query\|\.Find\|\.Get'
rg -n 'for.*of\|for.*in' --type ts -A3 | rg 'await.*find\|await.*get'
100 posts = 101 queries. Use `select_related`, `JOIN`, or batch `IN (...)`.
---
Enforce Authorization on Every Resource (Skeptical Senior, Pedant)
**Detection**:
rg -n 'userID|user_id' --type go --type py --type ts -A5 | rg 'db\.\|query\|find' | rg -v 'WHERE.*user_id\|filter.*user_id'
grep -rn 'def get\|def post\|def put' --include="*.py" | rg -v '@login_required\|@permission_required'
rg -n 'router\.(get|post|put|delete)\(' --type ts -B2 | rg -v 'auth\|verify\|require'IDOR: OWASP A01:2021. Always filter by authenticated user's ID.
---
Error-Fix Mappings
| Error Pattern | Root Cause | Fix | |---------------|------------|-----| | `panic: index out of range` | No bounds check | `len(slice) > idx` | | `context deadline exceeded` | No timeout | `context.WithTimeout()` | | `429 Too Many Requests` | No backoff | Exponential backoff with jitter | | `200 OK` with error body | Wrong status | Appropriate 4xx/5xx | | `UNIQUE constraint failed` | No ON CONFLICT | Upsert or explicit check |
---
Detection Commands Reference
rg -n ',\s*_\s*:?=\s*\w+' --type go # Ignored errors
rg -n 'StatusOK' --type go | rg -i 'err\|fail' # HTTP status misuse
rg -n 'password\s*=\s*"[^"]{4,}"' -i # Hardcoded secrets
rg -n 'SELECT.*FROM' --type go | rg -v 'LIMIT' # Missing pagination
grep -rn 'os.path.exists' --include="*.py" # TOCTOU race
rg -n 'for.*range' --type go -A5 | rg 'db\.Query' # N+1
rg -n 'userID' --type go -A5 | rg 'db\.' | rg -v 'WHERE.*user' # Missing authz---
See Also
- `skeptical-senior.md` — production readiness framework
- `pedant.md` — RFC/spec compliance
- `contrarian.md` — assumption auditing, lock-in detection
Read more
Code Review Detection Patterns
> **Scope**: Detection commands for common failure modes across languages. Load during any perspective review on a real codebase. > **Generated**: 2026-04-13
---
Pattern Catalog
Handle All Errors (Skeptical Senior, Pedant)
**Detection**:
rg -n ',\s*_\s*:?=\s*\w+' --type go # Go: blank identifier discarding errors
rg -n 'except:' --type py # Python: bare except
rg -n '\.then\(' --type ts | rg -v '\.catch|async' # JS: promise without catch**Signal**: `result, _ := db.Query(...)` — silent error discard means undetected corruption.
**Preferred action**: Handle error, wrap with `%w` (Go 1.13+), use `errors.Is()`/`errors.As()`.
---
Use Correct HTTP Status Codes (Pedant)
**Detection**:
rg -n 'status.*200|StatusOK' --type go | rg -i 'err\|fail\|error' # 200 on error rg -n 'InternalServerError|status.*500' --type go | rg -i 'invalid\|bad.request' # 500 for client error rg -n 'NotFound|status.*404' --type go | rg -i 'auth\|permission' # 404 for authz
Per RFC 7231: 400 invalid input, 404 missing resource, 401 missing auth, 403 insufficient permissions.
---
Load Credentials from Environment (Skeptical Senior, Pedant)
**Detection**:
rg -n 'password\s*=\s*"[^"]{4,}"' --type py --type go --type ts -i
rg -n 'api[_-]?key\s*=\s*"[^"]{8,}"' -i
rg -n 'AKIA[0-9A-Z]{16}' # AWS key pattern
grep -rn 'postgres://\|mysql://\|mongodb://' --include="*.go" --include="*.ts" --include="*.py" | grep -v '_test\|example'Credentials in git history are permanent. Load from env vars or secrets manager.
---
Paginate All List Queries (Skeptical Senior)
**Detection**:
rg -n 'SELECT.*FROM' --type go --type py | rg -v 'LIMIT\|COUNT\|SUM\|MIN\|MAX'
rg -n '\.find\(\|\.all\(\|\.fetch\(' --type py | rg -v 'limit\|paginate\|first\|count'
grep -rn 'findAll\|getAll\|fetchAll' --include="*.ts" --include="*.go"1,000 rows in dev = 50 million in prod. Add LIMIT/OFFSET or cursor pagination.
---
Use Atomic Operations (Skeptical Senior)
**Detection**:
grep -rn 'os.path.exists\|path.exists' --include="*.py" | rg -v 'test\|check' # TOCTOU rg -n 'await.*get\|await.*find' --type ts -A2 | rg 'await.*set\|await.*update' # async race
**Preferred action**: `sync.Map.LoadOrStore()`, mutex-wrapped check-and-store, or `INSERT ON CONFLICT`.
---
Batch Related Queries (Skeptical Senior)
**Detection**:
rg -n 'for.*in.*\.(all|filter|objects)' --type py -A3 | rg '\.(name|id|title|email)\b' rg -n 'for.*range' --type go -A5 | rg 'db\.Query\|\.Find\|\.Get' rg -n 'for.*of\|for.*in' --type ts -A3 | rg 'await.*find\|await.*get'
100 posts = 101 queries. Use `select_related`, `JOIN`, or batch `IN (...)`.
---
Enforce Authorization on Every Resource (Skeptical Senior, Pedant)
**Detection**:
rg -n 'userID|user_id' --type go --type py --type ts -A5 | rg 'db\.\|query\|find' | rg -v 'WHERE.*user_id\|filter.*user_id'
grep -rn 'def get\|def post\|def put' --include="*.py" | rg -v '@login_required\|@permission_required'
rg -n 'router\.(get|post|put|delete)\(' --type ts -B2 | rg -v 'auth\|verify\|require'IDOR: OWASP A01:2021. Always filter by authenticated user's ID.
---
Error-Fix Mappings
| Error Pattern | Root Cause | Fix | |---------------|------------|-----| | `panic: index out of range` | No bounds check | `len(slice) > idx` | | `context deadline exceeded` | No timeout | `context.WithTimeout()` | | `429 Too Many Requests` | No backoff | Exponential backoff with jitter | | `200 OK` with error body | Wrong status | Appropriate 4xx/5xx | | `UNIQUE constraint failed` | No ON CONFLICT | Upsert or explicit check |
---
Detection Commands Reference
rg -n ',\s*_\s*:?=\s*\w+' --type go # Ignored errors
rg -n 'StatusOK' --type go | rg -i 'err\|fail' # HTTP status misuse
rg -n 'password\s*=\s*"[^"]{4,}"' -i # Hardcoded secrets
rg -n 'SELECT.*FROM' --type go | rg -v 'LIMIT' # Missing pagination
grep -rn 'os.path.exists' --include="*.py" # TOCTOU race
rg -n 'for.*range' --type go -A5 | rg 'db\.Query' # N+1
rg -n 'userID' --type go -A5 | rg 'db\.' | rg -v 'WHERE.*user' # Missing authz---
See Also
- `skeptical-senior.md` — production readiness framework
- `pedant.md` — RFC/spec compliance
- `contrarian.md` — assumption auditing, lock-in detection
Essays and writing behind this toolkit live at vexjoy.com. AI agents skip steps. "Looks correct" replaces running tests. "Trivial change" replaces verification.
Repo: notque/vexjoy-agent
Other agents on vexjoy-agent.
- ansible-automation-engineer
Ansible automation: playbooks, roles, collections, Molecule testing, Vault security.
Open agent - modules
**Scope**: Module selection patterns, builtin vs command/shell decisions, collection modules, and version-specific module changes **Version range**: ansible-core 2.14+ / Ansible Collections (community.general 7.0+) **Generated**: 2026-04-04 — verify against current Ansible
Open agent - testing
**Scope**: Molecule test scenarios, ansible-lint rules, idempotency validation, and check-mode patterns **Version range**: Molecule 6.0+ / ansible-lint 6.0+ / ansible-core 2.14+ **Generated**: 2026-04-04 — verify against current Molecule and ansible-lint documentation
Open agent - base-instructions
Universal operational rules injected by /do at agent dispatch. Domain-specific rules live in each agent's .md file.
Open agent - communication-patterns
**Scope**: Failure modes in agent output style — over-reporting, self-congratulation, verbose narration, and hedging. Covers what to detect and how to fix each. **Version range**: all versions **Generated**: 2026-05-11
Open agent - combat-effects-upgrade
Zero-dependency combat visual upgrades: CSS particle replacement, Framer Motion combat juice, CSS 3D card transforms.
Open agent

