code-review

A structured checklist for reviewing code, including design principles, security risks, and general quality issues.

In plain words
What is it for?
Reviewing a change or codebase, assigning issue severity, checking SOLID design principles, and examining common security and quality problems.
Why use it?
It makes review comments consistent and helps identify problems such as injection risks, authentication gaps, duplication, and overly coupled code.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/dineshdb/pie/code-review
Any agent
npx skills add dineshdb/pie --skill code-review
Clone the repo
git clone --depth 1 https://github.com/dineshdb/pie

Made for: Claude Code, Codex.

Per session 16 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 712 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00016 $0.00712
Opus 5 $0.00008 $0.00356
Sonnet 5 $0.00003 $0.00142
Haiku 4.5 $0.00002 $0.00071

Measured 2d ago against content hash 5c9ea21950c3, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

code-review scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.pie/skills/code-review/SKILL.md · 97 lines

How it starts

The opening of the file, as written. The whole thing — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Code Review

Review git changes with severity levels. Default to review-only unless asked to fix.

Preflight

git status -sb
git diff --stat
git diff

Edge cases:

  • No changes: Ask if reviewing staged or a commit range.
  • Large diff (>500 lines): Summarize by file, review in batches by module.
  • Mixed concerns: Group findings by feature, not file order.

Severity Levels

Level Name Action
P0 Critical Must block merge
P1 High Should fix before merge
P2 Medium Fix in this PR or follow-up
P3 Low Optional improvement

SOLID + Architecture Smells

Principle Smell Fix
SRP Module with unrelated responsibilities Split by concern
OCP Editing to add behavior instead of extending Add extension point
LSP Subclass breaks expectations, needs type checks Fix abstraction
ISP Wide interface with unused methods Narrow the interface
DIP High-level logic tied to low-level impl Invert dependency

Security Checklist

  • SQL injection, XSS, command injection, SSRF, path traversal
  • Auth bypass, missing tenancy checks
  • Hardcoded secrets, API keys in logs
  • Unsafe deserialization, weak crypto
  • Race conditions: concurrent access, TOCTOU, missing locks

Quick scan:

rg -i "AKIA[0-9A-Z]{16}" .            # AWS keys
rg "ghp_[a-zA-Z0-9]{36}" .            # GitHub tokens
rg -i "password.*=" .                  # Hardcoded passwords
rg -i "eval\s*\(" .                    # Code injection
rg -i "SELECT.*\+.*FROM" .             # SQL concatenation

Quality Checks

  • Error handling: swallowed exceptions, broad catch, missing handling
  • Performance: N+1 queries, CPU in hot paths, unbounded memory
  • Boundaries: null handling, empty collections, numeric edges, off-by-one

Read the full file on GitHub · 97 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 97 lines · 16 tokens per session scan A 5c9ea21950c3

Subscribe to this mod's changes

code-review is a skill published in the GitHub repository dineshdb/pie (2 stars, last pushed 3mo ago), licensed MIT. It adds 16 tokens to every session and 712 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories