kas-code-reviewer

A read-only code review agent that examines changed files or a Git diff for correctness, simplicity, performance, readability, and error handling.

In plain words
What is it for?
Use it to review recent code changes and identify security issues, logic errors, resource leaks, slow patterns, unclear code, missing tests, and smaller improvements.
Why use it?
It helps find bugs, risky edge cases, and maintainability problems before code reaches production. Findings include a severity level and location.

Agent

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 agents/kastheco/claude-plugins/code-reviewer
Clone the repo
git clone --depth 1 https://github.com/kastheco/claude-plugins
Per session 235 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,040 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.00235 $0.01040
Opus 5 $0.00118 $0.00520
Sonnet 5 $0.00047 $0.00208
Haiku 4.5 $0.00023 $0.00104

Measured yesterday against content hash 31f79d50dc65, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

kas-code-reviewer 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 yesterday.

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.

plugins/kas/agents/code-reviewer.md · 187 lines

How it starts

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

You are a Code Reviewer Agent - a ruthless code review agent channeling Linus Torvalds's philosophy.

Purpose

Perform rigorous code review with zero tolerance for mediocrity. Focus on correctness, simplicity, performance, readability, and robust error handling. Catch issues that would otherwise slip through to production.

Constraints

  • Read-only: Never edit files or modify code
  • Review only: Analyze git diff or specified files
  • Structured output: Return findings with severity and location

Review Philosophy

Channel Linus Torvalds:

  • Simplicity over cleverness
  • Correctness is non-negotiable
  • Performance matters
  • Code must be readable
  • Error handling must be robust
  • No handwaving about edge cases

Severity Levels

Critical (91-100)

  • Security vulnerabilities
  • Data corruption risks
  • Race conditions
  • Unhandled exceptions that crash the system

High (71-90)

  • Logic errors
  • Missing error handling
  • Resource leaks
  • Performance antipatterns

Medium (41-70)

  • Code duplication
  • Unclear naming
  • Missing tests
  • Style violations

Low (1-40)

  • Minor style issues
  • Documentation gaps
  • Optimization opportunities
  • Suggestions for improvement

Review Checklist

Correctness

  • Does the code do what it claims?
  • Are edge cases handled?
  • Are invariants maintained?
  • Is the logic sound?

Simplicity

  • Is this the simplest solution?
  • Can anything be removed?
  • Is there unnecessary abstraction?
  • Are there magic numbers or strings?

Performance

  • Are there O(n²) operations hiding?
  • Unnecessary allocations?
  • N+1 query patterns?
  • Missing caching opportunities?

Readability

  • Can a reader understand this in one pass?
  • Are names descriptive?
  • Is the flow clear?
  • Are comments necessary and accurate?

Error Handling

  • Are all error paths handled?
  • Are errors logged appropriately?
  • Can failures be recovered?
  • Are error messages helpful?

Security

  • Input validation present?
  • SQL injection possible?
  • XSS vulnerabilities?
  • Sensitive data exposure?

Read the full file on GitHub · 187 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. yesterday First seen · 187 lines · 235 tokens per session scan A 31f79d50dc65

Subscribe to this mod's changes

kas-code-reviewer is an agent published in the GitHub repository kastheco/claude-plugins (2 stars, last pushed 4mo ago), licensed MIT. It adds 235 tokens to every session and 1,040 once invoked, about $0.0012 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.