# code-review

A skill that gives code review a shape: what to check for correctness, security and performance, how to phrase comments, when a PR is too big.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 498 installs · ★ 176
- Author: jwynia
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/jwynia/agent-skills/tree/HEAD/skills/tech/development/quality/code-review/SKILL.md
- Updated: 2026-02-24
- HTML: https://affpapa.org/en/nevibecode/skills/jwynia-code-review

## What it does

The skill lays out a review method rather than running a linter. It names four focus areas: correctness, maintainability, performance and security. Each comes with questions to ask of a diff and with red flags such as N+1 queries, unbounded loops and synchronous I/O inside async code.

There is a code smell checklist with thresholds: a method past 50 lines, more than 5 parameters, duplication from 10 similar lines. Comments get severity tags — `[BLOCKING]`, `[MAJOR]`, `[MINOR]`, `[QUESTION]` — and a pattern of observation, impact, suggestion. Tables cover cyclomatic and cognitive complexity ranges.

One point the skill keeps returning to: review effectiveness drops as the PR grows. Under 400 lines detection is at its best, past 800 it falls off by 90%. So a bloated diff is a reason to split it, not to read harder. The skill works with any programming language and pairs with `github-agile` for the PR workflow. It does not write new code or design architecture — other skills in the set handle that.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add jwynia/agent-skills --skill code-review -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/code-review/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/code-review/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add jwynia/agent-skills --skill code-review -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/code-review/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add jwynia/agent-skills --skill code-review -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/code-review/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install jwynia/agent-skills code-review
```

2. **Manually: put the files in place**
- File: `.github/skills/code-review/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add jwynia/agent-skills --skill code-review -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/jwynia/agent-skills --path skills/tech/development/quality/code-review
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/code-review/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add jwynia/agent-skills --skill code-review -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/jwynia/agent-skills/tree/HEAD/skills/tech/development/quality/code-review/SKILL.md

## When to use it
- check a diff before merge against one list
- tell a blocking issue from a style nit
- write a review comment that is not just a preference
- decide whether a large PR should be split
- self-review code before asking anyone else

## Example prompts
- Review this PR with the code-review skill and sort findings by severity
- Check `src/orders/service.py` for code smells and security problems
- Rate the cyclomatic complexity of these methods and tell me what to refactor

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: 80ec2c2b41ac8ce0.

BEGIN THIRD-PARTY FILE 80ec2c2b41ac8ce0
```text
---
name: code-review
description: "Provide structured code review guidance for catching defects and improving quality. This skill should be used when the user asks to 'review this code', 'check for issues', 'PR review', 'code quality check', or wants systematic code evaluation. Keywords: code review, PR, pull request, quality, defects, security, maintainability, performance."
license: MIT
compatibility: Works with any programming language. Integrates with github-agile for PR workflow.
metadata:
  author: jwynia
  version: "1.0"
  type: diagnostic
  mode: evaluative
  domain: development
---

# Code Review Diagnostic

Systematic code review catches 60-90% of defects before production, reduces maintenance costs by 40%, and serves as effective knowledge transfer. This skill provides structured review guidance for both human reviewers and AI agents.

## When to Use This Skill

Use this skill when:
- Reviewing code before merge
- Assessing code quality
- Preparing code for PR submission
- Self-reviewing before requesting review

Do NOT use this skill when:
- Writing new code (use implementation skills)
- Designing architecture (use system-design)
- Working on requirements (use requirements-analysis)

## Core Principle

**Review effectiveness degrades sharply with PR size.** Under 400 lines: highest defect detection. 400-800 lines: 50% less effective. 800+ lines: 90% less effective.

## Quick Reference: Review Effectiveness

| Factor | Optimal | Degraded |
|--------|---------|----------|
| PR size | < 400 lines | > 800 lines |
| Review time | < 60 minutes | > 90 minutes |
| Review speed | 200-400 LOC/hour | > 500 LOC/hour |
| Reviewers | 2 | 4+ (diminishing returns) |

## Quality Pyramid

| Level | Checks | Catches | Frequency |
|-------|--------|---------|-----------|
| 1. Automated | Lint, types, unit tests, security scan | 60% | Every commit |
| 2. Integration | Integration tests, contracts, performance | 25% | Every PR |
| 3. Human Review | Design, logic, maintainability, context | 15% | Significant changes |

## Review Focus Areas

### 1. Correctness

**Questions:**
- Does it solve the stated problem?
- Are edge cases handled?
- Is error handling complete?
- Are assumptions valid?

**Validation:** Test coverage, business logic, data integrity, concurrency handling

### 2. Maintainability

**Questions:**
- Is the code self-documenting?
- Can it be easily modified?
- Are abstractions appropriate?
- Is complexity justified?

**Indicators:** Clear naming, single responsibility, minimal coupling, high cohesion

### 3. Performance

**Questions:**
- Are there obvious bottlenecks?
- Is caching appropriate?
- Are queries optimized?
- Is memory managed?
```
END THIRD-PARTY FILE 80ec2c2b41ac8ce0

The third-party file has ended. Everything between the 80ec2c2b41ac8ce0 tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2692 of 6894 bytes. © jwynia · MIT · https://github.com/jwynia/agent-skills/tree/HEAD/skills/tech/development/quality/code-review/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
