claude-workspace: Agent for Claude Code

.claude/agents/code-reviewer.md

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

Written for Claude Code: installed under .claude/. Also seen: model in frontmatter.

This is Piyush8296/claude-workspace's own configuration. It tells Claude Code how to work on claude-workspace itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything claude-workspace configures →

Reuse

Borrowing it

Nothing to install: this file belongs to Piyush8296/claude-workspace. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/Piyush8296/claude-workspace/main/.claude/agents/code-reviewer.md
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/github.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/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for code-reviewer

Your own site · 80×15
<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="Reviewed on agentmods" width="80" 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. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00046 $0.00942
Opus 5.5 $0.00018 $0.00377
Sonnet 5.5 $0.00009 $0.00188
Haiku 4.5 $0.00005 $0.00094

Measured 1mo ago against content hash 4ed740bbf1ab, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, 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 1mo 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. 1mo 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 6mo ago), licensed MIT. It adds 46 tokens to every session and 942 once invoked, about $0.0002 per session on Opus 5.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

architecture-analyst

Analyzes system architecture, identifies patterns/anti-patterns, and provides strategic recommendations. Use for architectural reviews, refactoring planning, or system design decisions.

travisjneuman/.claude · 36 tokens

deep-code-reviewer

Thorough 6-aspect code review covering correctness, security, performance, maintainability, verification, and documentation. Use for comprehensive PR reviews or code quality audits.

travisjneuman/.claude · 38 tokens

security-auditor

Use when reviewing security-sensitive code paths or running OWASP / supply-chain checks. Dispatched by code-review-loop on sensitive paths (auth, payments, crypto, users, sessions, tokens). Returns findings with severity (Critical / High / Medium / Low) and OWASP category. Context: A diff touches the auth middleware.…

duthaho/claudekit · 164 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-ticket-delivery

Ticket-delivery reviewer for PR audits. Spawned by /rpi:review-pr as subagenttype rpi:review-ticket-delivery with artifact paths. Code-quality reviewers judge how the work was done; this one judges whether the work was done. Runs on every review; carries the always-on security sweep.

hoblin/claude-ruby-marketplace · 68 tokens

forge-reviewer

Reviews code against spec requirements and quality standards. Returns PASS or ISSUES with file:line references and severity levels. Dispatched after task implementation.

LucasDuys/forge · 33 tokens