review-code
Skill3 starsChanged 8 months agoMITView on GitHub
Use when reviewing changed code before committing or after completing a feature — checks performance, architecture, type safety, and code quality against project standards
41 other projects use a version of this.
Adopted by
Most recently taken up by
- kamui/skillstheir own version, first seen Oct 1, 2026
- GeiserX/agent-skillstheir own version, first seen Sep 30, 2026
- mgiovani/cc-arsenaltheir own version, first seen Sep 25, 2026
- gtrabanco/agentic-workflowtheir own version, first seen Sep 22, 2026
- elfrost/ai-patchlabtheir own version, first seen Sep 22, 2026
- yamanidev/claude-code-configurationtheir own version, first seen Sep 13, 2026
Used with
Projects with it also use review-deps, review-security and 9 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
cjohnhansonSkillreview-deps
Judge dependencies, advisories, and licences. Use as a required review, or as /review-deps. Not for how a dependency is called: review-code covers that.
Also in 3 projects that use this
PydanticSkillreview-security
Security review of the current branch against its merge base — sandbox escapes, memory errors, panics and resource-limit bypasses. Use when reviewing changes for security risk, or before merging anything touching the heap/ module, path_security.rs, the wire protocol or the pool.
Also in 5 projects that use this
dirkkok101Skillreview-design
Use before /plan, after /technical-design, when user says "review design", "check the design", or when design quality is uncertain.
Also in 4 projects that use this
JetBrainsSkillreview-plan
Manually re-run the autonomous plan review (Phase 2 — consistency + structural). The same review runs automatically as the first phase of /execute-tracks; this command is for re-runs after inline replanning or whenever the plan needs explicit re-validation. TRIGGER when: user asks to re-validate the plan after inline replanning; user requests explicit plan review outside /execute-tracks. SKIP: /execute-tracks already running State 0 in this session (autonomous Phase 2 path will fire) — do not double-run.
Also in 5 projects that use this
Microsoft AzureSkillreview-pr
Review a pull request for functional issues, coding guideline adherence, and best practices. Use this when asked to review, inspect, or provide feedback on a pull request (Azure DevOps or GitHub). Proposes comments for user approval before posting.
Also in 4 projects that use this
AWSSkillship
Finalize dev work on an issue branch — update docs, push, and open a PR.
Also in 6 projects that use this
Other versions41 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 41
- ankitvgupta/exo★ 497same name
- ninehills/skills★ 280same name
- rengwu/wayfinder-maps★ 133same name
- avibebuilder/claude-prime★ 120same name
- fitlab-ai/agent-infra★ 86same name
- ninehills/public-skills★ 86same name
- zhao-wuyan/ccw-command-explorer★ 43same name
- gtrabanco/agentic-workflow★ 21same name
- renzrollon/interlock★ 17same name
- hellotern/Sextant★ 15same name
31 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository36 other files it gives its agents.
- adrSkill
- analyticsSkill
- api-contractSkill
- api-designSkill
- ci-pipelineSkill
- claude-mdSkill
- code-qualitySkill
- data-modelSkill
- db-migrateSkill
- debugSkill
- deploySkill
- dep-updateSkill
- disk-cleanupSkill
- docker-buildSkill
- eng-leadSkill
- event-drivenSkill
- fullstack-healthcheckSkill
- go-featureSkill
- go-integration-testSkill
- go-refactorSkill
- go-scaffoldSkill
- incident-responseSkill
- interactive-clarifySkill
- observabilitySkill
- onboardingSkill
- product-specSkill
- py-featureSkill
- py-integration-testSkill
- py-migrateSkill
- py-refactorSkill
- py-scaffoldSkill
- react-featureSkill
- react-refactorSkill
- react-scaffoldSkill
- securitySkill
- system-designSkill
The file
We split this skill into the rules it gives an agent
9 rules. 0 are common, 8 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 34 edited versions we read keep these.
8
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 10
Verification rule: Every fix must be verified.
- Distinctive: line 14
Run git diff (or git diff HEAD if there are staged changes) to see what changed.
- Distinctive: line 24
Use the Agent tool to launch all four agents concurrently.
- Distinctive: line 126
Wait for all four agents to complete.
- Distinctive: line 139
Every finding gets classified before action:
- Distinctive: line 147
Default to AUTO-FIX: Only use ASK when there are genuinely multiple valid approaches.
- Distinctive: line 154
Do NOT argue with findings or add defensive commentary — fix or skip
- Distinctive: line 158
Every finding must include evidence: No vague claims.
- Very specific: line 190
REQUIRED: Update CLAUDE.md if review reveals project-specific gotchas (claude-md)
“Common” is measured: kept by at least 6 in 10 of the 34 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Code Review
Review all changed files for performance, architecture violations, type safety, and code quality. Fix every real issue found. Severity-ranked — critical issues first.
Verification rule: Every fix must be verified. Run tests after fixing. Never say "this should fix it" — show the test output proving it does.
Phase 1: Identify Changes & Detect Stack
Run git diff (or git diff HEAD if there are staged changes) to see what changed. If no git changes, review files edited in this conversation.
Auto-detect stack from changed files:
.gofiles → Go review rules.pyfiles → Python review rules.tsx/.tsfiles → React review rules- Mixed → apply all relevant rule sets
Phase 2: Launch Four Review Agents in Parallel
Use the Agent tool to launch all four agents concurrently. Pass each agent the full diff plus the detected stack context.
Agent 1: Performance & Efficiency Review (CRITICAL)
This is the highest priority review. Check every change against these rules:
Database (Go/pgx):
- N+1 queries — any query inside a loop is a bug. Must use batch query, JOIN, or
pgx.Batch - Unbounded queries — every SELECT must have LIMIT. No
SELECT * FROM tablewithout pagination - Missing indexes — new WHERE/JOIN/ORDER BY columns on large tables need index migrations
- Sequential queries — independent queries that should use
errgroupfor parallel execution - Missing batch inserts — multiple INSERTs in a loop → use
pgx.Batchor multi-value INSERT - Inefficient COUNT — separate COUNT query when it could be
COUNT(*) OVER()window function
Database (Python/SQLAlchemy):
- N+1 queries — lazy-loaded relationships accessed in loops. Must use
selectinload()orjoinedload() - Missing eager loading — related models accessed but not loaded in the query options
- Sequential async I/O — independent awaits that should use
asyncio.gather() - Unbounded queries — missing
.limit()on queries that return lists
Algorithm & Data Structures (all stacks):
- O(n²) when O(n) possible — nested loops on same data, list membership in loop (use map/set)
- Redundant allocations — slice/list creation inside loops without pre-allocation
- Linear search for lookup — using list/slice where map/set gives O(1)
- String concatenation in loop — use
strings.Builder(Go) or"".join()(Python) - Unnecessary copies — passing large structs by value in Go where pointer suffices
React:
- Unbounded list rendering — >50 items without virtualization
- Missing debounce — search/filter inputs firing API on every keystroke
- Fetch in render — API calls outside of hooks/React Query
- Missing pagination — fetching all items from API without limit/offset
General:
- Redundant computation — same value computed multiple times, repeated file reads, duplicate API calls
- Hot-path bloat — expensive work in startup, per-request, or per-render paths
- Memory leaks — unbounded caches, missing cleanup, event listener leaks
- TOCTOU — checking existence before operating instead of operating and handling error
Agent 2: Architecture & Structure Review
Clean architecture boundaries:
- Domain imports external —
internal/domain/(Go) orsrc/domain/(Python) must not import infrastructure, interfaces, fiber, pgx, sqlalchemy, fastapi, or any framework - Application imports infrastructure —
internal/application/orsrc/application/must not import infrastructure packages directly - Handler contains business logic — logic beyond parsing request and calling use case belongs in application layer
- Domain entity exposed in API response — handlers must map to DTOs, never return domain types directly
- Repository returns non-domain types — repos must return domain entities, not ORM models
Go-specific:
- Missing swaggo annotations — every handler must have
// FuncName godocblock with @Summary, @Tags, @Param, @Success, @Failure, @Router - Manual body parsing — must use
pkg.ValidateBody[T],pkg.ValidateQuery[T],pkg.ValidateParams[T]instead of manualBodyParser+ validation - Missing
exampletags — DTO/response structs should haveexampletags for Swagger UI - Error handling — naked
errorreturns without wrapping context. Usefmt.Errorf("operation: %w", err) - Exported function without comment — all exported functions need doc comments
Python-specific:
- Missing type annotations — all functions must have return types, all parameters typed
- ABC instead of Protocol — repository interfaces should use
Protocolfor structural typing - Missing
Mapped[]types — SQLAlchemy models must useMapped[type]withmapped_column() - Untyped dict — passing
dictwhere a Pydantic model or dataclass should be used
React-specific:
- Prop drilling >3 levels — should use Context or state library
- Business logic in component — extract to custom hook
- Missing loading/error/empty states — every data-fetching component needs all three
Agent 3: Code Quality & Reuse Review
Duplication & reuse:
- Duplicate logic — search codebase for existing utilities that could replace new code
- Copy-paste with variation — near-duplicate blocks that should be unified
- Inline logic for existing util — hand-rolled string manipulation, path handling, type guards when helpers exist
Code smells:
- Redundant state — state that duplicates or can be derived from other state
- Parameter sprawl — function growing too many params instead of using options struct/config
- Stringly-typed code — raw strings where constants/enums already exist in codebase
- Magic numbers — unexplained numeric literals (extract to named constants)
- Dead code — unused functions, unreachable branches, commented-out code
Error handling:
- Swallowed errors —
_ = someFunc()or empty catch blocks hiding failures - Panic in library code (Go) — use error returns, never panic
- Bare except (Python) —
except Exceptionorexcept:without specific error types
Agent 4: Security & Safety Review (NON-NEGOTIABLE)
Security is a non-negotiable. Any security finding is automatically CRITICAL.
- SQL injection — string concatenation in queries instead of parameterized args
- Missing input validation — user input used without validation (should go through ValidateBody/Query/Params or Pydantic)
- Sensitive data in logs — passwords, tokens, API keys logged or included in error messages
- Missing auth check — endpoint without
@Security BearerAuthannotation or missing auth middleware - CORS misconfiguration — overly permissive origins in production config
- Hardcoded secrets — API keys, passwords, connection strings in code instead of env vars
- Path traversal — user-controlled file paths without sanitization
- Mass assignment — binding all request fields to model without allowlist
- Missing rate limiting — public endpoints without rate limiting middleware
- Insecure defaults — debug mode, verbose errors, or stack traces exposed in production config
Phase 3: Aggregate & Fix
Wait for all four agents to complete. Aggregate findings by severity:
Severity Levels
| Level | Definition | Action |
| CRITICAL | N+1 queries, SQL injection, unbounded queries, security holes, architecture violations | Must fix before commit |
| HIGH | Missing indexes, O(n²) algorithms, missing validation, swallowed errors | Must fix before commit |
| MEDIUM | Missing swaggo annotations, type safety gaps, code duplication, missing error context | Fix now, acceptable to defer with TODO |
| LOW | Missing example tags, minor style issues, potential future optimization | Note and skip if time-constrained |
Fix-First Classification
Every finding gets classified before action:
| Classification | Definition | Action |
| AUTO-FIX | Mechanical issue with one correct solution (missing LIMIT, N+1 query, missing parameterized query) | Fix directly, no discussion |
| ASK | Judgment call with trade-offs (architecture refactor, API design choice, scope decision) | Present options to user via AskUserQuestion |
| SKIP | False positive or irrelevant to this codebase | Note and move on |
Default to AUTO-FIX. Only use ASK when there are genuinely multiple valid approaches. Never ASK about non-negotiables (security, N+1, tests) — those are always AUTO-FIX.
Fix Process
- Fix all CRITICAL and HIGH issues directly in code (AUTO-FIX)
- Fix MEDIUM issues — skip only if clearly a false positive
- Note LOW issues in summary — do not spend time on these
- Do NOT argue with findings or add defensive commentary — fix or skip
Evidence-First Reporting
Every finding must include evidence. No vague claims.
## Code Review Results
### Status: DONE / DONE_WITH_CONCERNS
### Fixed (N issues) — AUTO-FIX
- [CRITICAL] Fixed N+1 query in `UserRepository.List` (user_repo.go:45)
Evidence: query inside for loop, replaced with batch IN clause
- [HIGH] Added LIMIT to events query in `ActivityService` (activity.go:78)
Evidence: SELECT without LIMIT on table with 100k+ rows
- [CRITICAL] Fixed SQL injection in `SearchHandler` (search_handler.go:23)
Evidence: string concatenation `"WHERE name = '" + input + "'"`, replaced with parameterized query
### Asked (N issues) — ASK
- [MEDIUM] `UserService` has 8 methods — split into smaller services?
Presented options to user: keep as-is vs split by domain
### Skipped (N issues) — SKIP
- [LOW] Missing example tag on InternalDTO — not exposed in Swagger
### Clean
- No architecture violations found
- Security review passedChains
- Invoked by:
eng-lead(code review gate before committing) - Complements: All
*-featureand*-refactorskills as final quality gate - REQUIRED: Fix all CRITICAL and HIGH issues before code is committed
- REQUIRED: Update CLAUDE.md if review reveals project-specific gotchas (
claude-md)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

