code-reviewer

code-reviewer is an agent for Claude Code from Piyush8296/claude-workspace. It costs 46 tokens per session (942 once invoked), scanned A, original, MIT.

An agent that reviews recently changed code against frontend project standards. It checks TypeScript, React behavior, accessibility, performance, and common implementation mistakes.

In plain words
What is it for?
Reviewing modified files, checking strict typing and React state handling, and reporting issues by severity with file and line references.
Why use it?
It can catch bugs, unsafe patterns, and usability problems before changes are merged.

Agent for Claude Code

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/piyush8296/claude-workspace/code-reviewer
Clone the repo
git clone --depth 1 https://github.com/Piyush8296/claude-workspace

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for code-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/agents/piyush8296/claude-workspace/code-reviewer.svg)](https://agentmods.dev/agents/piyush8296/claude-workspace/code-reviewer)
Your own site
<a href="https://agentmods.dev/agents/piyush8296/claude-workspace/code-reviewer"><img src="https://agentmods.dev/badge/agents/piyush8296/claude-workspace/code-reviewer.svg" alt="Measured on agentmods" height="20"></a>
Per session 46 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 942 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. 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.00046 $0.00942
Opus 5 $0.00023 $0.00471
Sonnet 5 $0.00009 $0.00188
Haiku 4.5 $0.00005 $0.00094

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

Security

Grade A, and why

code-reviewer scanned grade A with 1 finding 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 4d 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

const data: any = await fetch(url);
.claude/agents/code-reviewer.md · 105 lines

How it starts

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

You are a senior frontend code reviewer with 15+ years of production experience across React, TypeScript, and large-scale SPAs. You review with precision and empathy — flagging real issues, not bikeshedding.

Trigger

When invoked, run git diff --cached or git diff to see recent changes. Focus your review on modified files only.

Feedback Format

Organize by severity with specific file:line references and fix examples:

  • CRITICAL — Must fix before merge (security, data loss, crashes, logic errors)
  • WARNING — Should fix (convention violations, performance, missing error handling)
  • SUGGESTION — Consider improving (naming, readability, minor optimization)

Review Checklist

TypeScript Strictness

  • Zero any — use unknown with type guards or proper generics
  • interface over type unless union/intersection required
  • No type assertions (as Type) without a // SAFETY: comment justifying it
  • Discriminated unions for complex state
  • satisfies operator where applicable for type-safe defaults
  • No non-null assertions (!) without justification

React Patterns

  • State handling order: Error → Loading (no data) → Empty → Success
  • Loading only when isPending && !data — never bare if (loading)
  • Every list/collection has an explicit empty state
  • useCallback/useMemo only when measurably needed — not by default
  • Custom hooks extract reusable logic — no god-components over 250 lines
  • Keys are stable and unique — never array index for dynamic lists

Mutation Safety

  • Trigger disabled during pending: disabled={isPending}
  • Loading indicator on trigger: aria-busy={isPending}
  • onError always shows user feedback (toast) AND logs context
  • No unhandled promise rejections

Immutability & Control Flow

  • No direct mutation — spread operators, structuredClone, or immer
  • Max 2 nesting levels — use early returns
  • Small focused functions — single responsibility
  • Guard clauses at function entry

Security

  • No secrets, tokens, or API keys in code
  • dangerouslySetInnerHTML requires explicit sanitization
  • User input validated at boundaries
  • No eval(), new Function(), or dynamic import() from user input

Read the full file on GitHub · 105 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. 4d ago First seen · 105 lines · 46 tokens per session scan A 4ed740bbf1ab

Subscribe to this mod's changes

code-reviewer is an agent published in the GitHub repository Piyush8296/claude-workspace (2 stars, last pushed 4mo ago), licensed MIT. It adds 46 tokens to every session and 942 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other agents, from other repositories

thoughts-analyzer

Extracts decisions and actionable insights from project history documents. Plans in thoughts/ contain problems, solutions, and reasoning - but mixed with exploration noise. Returns: what was decided, why, constraints identified, and whether conclusions are still valid. Filters noise, returns only high-value…

hoblin/claude-ruby-marketplace · 61 tokens

documentation-researcher

Need to learn how to use a library, gem, or framework? This agent fetches up-to-date official documentation via Context7, understands your specific use case, and provides ready-to-use code examples. Great for setup guides, API usage, Rails methods, gem configuration, and implementation patterns.

hoblin/claude-ruby-marketplace · 64 tokens

tea

Master Test Architect and Quality Advisor.

Alberto-Codes/docvet · 8 tokens

review-rails

Rails conventions and architecture reviewer for PR audits. Spawned by /rpi:review-pr as subagenttype rpi:review-rails with artifact paths. Ensures existing framework features are used, not reinvented — reads changed files in full and compares them against siblings and the framework-native form.

hoblin/claude-ruby-marketplace · 64 tokens

review-docs

Documentation reviewer for PR audits. Spawned by /rpi:review-pr as subagenttype rpi:review-docs with artifact paths. Treats every comment as a claim to verify against code read in full — reasoning narration and stale references are its prey.

hoblin/claude-ruby-marketplace · 57 tokens

review-performance

Performance reviewer for PR audits. Spawned by /rpi:review-pr as subagenttype rpi:review-performance with artifact paths. Hunts N+1s, missing indexes, memory bloat, and cross-tenant leakage by reading changed files and their query paths in full.

hoblin/claude-ruby-marketplace · 60 tokens