skills/code-review/SKILL.md
Code review practices and pull request quality standards. Use when: reviewing a pull request, preparing code for review, writing review comments, checking for common issues, establishing review guidelines, auditing an existing project's review practices, or improving PR quality standards. Integrates linting, testing, security, and CI/CD checks into a cohesive review workflow.
npx skillsauth add michaelsvanbeek/personal-agent-skills code-reviewInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Review in this order — stop at the first category with issues before nitpicking lower ones:
| Priority | Category | Questions to ask | |----------|----------|-----------------| | 1 | Correctness | Does it do what it claims? Are edge cases handled? | | 2 | Security | Input validation? Secret exposure? Injection? Access control? | | 3 | Design | Right abstraction level? Follows existing patterns? Over-engineered? | | 4 | Reliability | Error handling? Logging? Graceful degradation? | | 5 | Performance | Obvious N+1 queries, unbounded loops, or missing indexes? | | 6 | Readability | Clear names? Minimal complexity? Would a new team member understand? | | 7 | Style | Formatting, naming conventions, import order (should be caught by linters) |
Don't review style manually — that's what linters and formatters enforce in CI. If CI passes lint, style is not a review concern.
These should fail the build automatically — don't waste review time on them:
| Check | CI tool | Reference |
|-------|---------|-----------|
| Code formatting | Ruff format / Prettier | linting skills |
| Lint violations | Ruff / ESLint | linting skills |
| Type errors | mypy / TypeScript strict | python / typescript skills |
| Test failures | pytest / vitest | testing skill |
| Coverage regression | pytest-cov --cov-fail-under | cicd skill |
| Known vulnerabilities | pip audit / npm audit | security skill |
Use as a mental model during review. Not every point applies to every PR.
# Bad
"This doesn't look right."
# Good
"This will throw a KeyError if `user_data` doesn't contain 'email'.
Consider using `user_data.get('email')` or validating the field upstream."
Prefix comments to signal intent:
| Prefix | Meaning | |--------|---------| | blocker: | Must fix before merge. Correctness, security, or data loss risk. | | suggestion: | Improvement idea. Take it or leave it. | | question: | Genuine question — I don't understand the intent. | | nit: | Minor style preference. Not worth blocking on. | | praise: | Something done well. Positive reinforcement matters. |
| Lines changed | Assessment | Action | |--------------|------------|--------| | < 100 | Ideal | Fast to review, easy to understand | | 100 – 400 | Acceptable | Should have a clear description | | 400 – 800 | Too large | Split if possible | | > 800 | Unacceptable | Must be split. No reviewer can effectively review this. |
Exceptions: auto-generated code, migrations, dependency lockfile updates.
## What
Brief description of the change.
## Why
Link to issue or explain the motivation.
## How
Key design decisions and approach taken.
## Testing
How to verify the change works:
- [ ] Unit tests pass
- [ ] Manual testing steps (if applicable)
## Checklist
- [ ] Lint / format passes
- [ ] Tests added for new behavior
- [ ] No secrets in code
- [ ] Documentation updated (if user-facing)
development
TypeScript coding standards and type safety conventions. Use when: creating TypeScript files, defining interfaces and types, writing type-safe code, reviewing TypeScript for type correctness, auditing a codebase for type safety gaps, eliminating any or ts-ignore usage, or improving strict-mode compliance. Covers strict typing, avoiding any and ts-ignore, discriminated unions, Zod runtime validation, immutability patterns, and proper type definitions.
testing
Writing clear, actionable tickets in any issue tracker (Jira, Linear, GitHub Issues, ServiceNow, etc.). Use when: creating epics, stories, tasks, bugs, or spikes; writing acceptance criteria; decomposing work for a sprint; linking dependencies between tickets; auditing backlog items for clarity; or coaching a team on ticket quality. Covers title conventions, description templates, acceptance criteria, decomposition rules, dependency linking, and org-specific pluggable configuration.
development
Testing strategy, patterns, and evaluation for software and LLM/AI systems. Use when: writing tests, choosing test boundaries, designing test data, structuring test suites, evaluating LLM outputs, building evaluation pipelines, setting coverage thresholds, auditing test coverage gaps in existing projects, or improving test quality and structure.
development
Writing effective status updates for different audiences and cadences. Use when: writing a weekly status update, preparing a monthly summary, drafting a quarterly review, sending updates to leadership, sharing progress with stakeholders, or improving the clarity and impact of team communications. Covers weekly, monthly, and quarterly formats tailored for upward, lateral, and downward communication.