Run a full-codebase audit of CachiBot using 8 parallel review agents (DRY, Security, API, Data, Frontend, Tests, State, Observability). Each agent reports findings with file paths and line numbers, compiled into a dated report.
Run a full-codebase audit of CachiBot using 8 parallel review agents (DRY, Security, API, Data, Frontend, Tests, State, Observability). Each agent reports findings with file paths and line numbers, compiled into a dated report.
Code Review — 8-Agent Sweep
Run a full-codebase audit of CachiBot using 8 parallel review agents. Each agent
focuses on a specific quality concern and reports findings with file paths and
line numbers. Results are compiled into a single dated report.
Instructions
Note today's date for the report header.
Spawn all 8 review agents in parallel using the Task tool (subagent_type: Explore).
Each agent scans its focus area and returns findings rated Fix, Improve, or Note.
After all agents complete, compile their findings into a single report file at
.reviews/YYYY-MM-DD-review.md (create the .reviews/ directory if it doesn't exist).
Print a summary to the user with totals per severity.
Hardcoded strings that should be in constants or i18n
Inline styles that should be in CSS/Tailwind classes
Props being drilled through 3+ levels instead of using context or stores
useEffect with missing or incorrect dependency arrays
Components re-rendering unnecessarily — missing memo, unstable references
in deps
6. Derek — The Test Coverage Analyst
Scope:tests/ and full codebase
Looks for: Missing tests, weak assertions, untested paths
Which endpoints in api/routes/ have zero test coverage?
Which utility functions and service methods lack unit tests?
Are error paths tested, or only happy paths?
Do integration tests exist for critical flows (auth, chat, WebSocket)?
Are there tests that assert on implementation details instead of behavior
(brittle tests)?
Frontend: are there any component or store tests? What's missing?
Are test fixtures/factories available, or does every test build its own
data from scratch?
7. Luna — The State & Integration Reviewer
Scope:frontend/src/stores/, frontend/src/api/Looks for: State management issues, frontend-backend contract mismatches
Zustand stores with stale state bugs — data fetched but never refreshed,
or refreshed too aggressively
API client methods that don't handle errors consistently — some throw,
some return null, some swallow
Type mismatches between frontend TypeScript interfaces and backend Pydantic
models — fields that exist on one side but not the other
localStorage persistence of sensitive data (tokens, keys, admin state)
WebSocket reconnection logic — does the client recover from disconnects
gracefully?
Race conditions — multiple concurrent requests updating the same store slice
Loading/error states that are missing or inconsistent across views
8. Oscar — The Observability Reviewer
Scope: Full codebase
Looks for: Silent failures, missing logs, poor error messages, bare excepts
Bare except Exception or except: blocks that swallow errors silently —
every catch should log or re-raise
Important operations with no logging at all (user creation, config changes,
provider key updates)
Log messages that are too vague to be useful ("error occurred" with no
context)
Error responses that expose internal details (tracebacks, file paths, SQL)
to the client
Missing logger = logging.getLogger(...) in modules that should have one
Inconsistent log levels — warnings that should be errors, debug that should
be info
Health check gaps — what breaks silently with no way to detect it?
Report Format
After all agents finish, write .reviews/YYYY-MM-DD-review.md with this structure:
# CachiBot Code Review — YYYY-MM-DD**Reviewers:** Tina, Marcus, Priya, Carlos, Zoe, Derek, Luna, Oscar
**Scope:** cachibot/, frontend/src/, desktop/
## Summary
| Severity | Count |
|----------|-------|
| Fix | N |
| Improve | N |
| Note | N |
## Tina — DRY### Fix-`path/to/file.py:42` — Description
### Improve-`path/to/file.ts:108` — Description
### Note-`path/to/file.py:15` — Description
## Marcus — Security
(same structure)
... (all 8 agents)
## Previous Reviews
(Link to or diff against the last review file in .reviews/ if one exists,
noting which prior findings were fixed and which are still open.)
Severity Definitions
Fix — Real bug, security issue, or maintenance risk. Should be fixed now.
Improve — Worth doing, not urgent. Better patterns, cleaner code.
Note — Awareness item. No action needed yet, but worth knowing about.