backend-reviewer

backend-reviewer is an agent for Claude Code from fjpulidop/specrails-core. It costs 155 tokens per session (1,500 once invoked), scanned A, original, MIT.

A read-only code-review agent for backend files. It looks for repeated database queries, unsafe connection-pool use, pagination problems, and missing database indexes.

In plain words
What is it for?
Use it after backend changes to scan the modified files and produce a findings report without editing code.
Why use it?
It can reveal common backend performance and reliability risks before they affect real traffic.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter; mentions CLAUDE.md.

Part of the specrails plugin — 28 skills, 14 agents shipped together

Good fit Use it after backend changes to scan the modified files and produce a findings report without editing code.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/fjpulidop/specrails-core/backend-reviewer
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.

Clone the repo
git clone --depth 1 https://github.com/fjpulidop/specrails-core

Made for: Claude Code.

Or install specrails, the plugin that ships this one along with the rest of its 28 skills, 14 agents.

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 backend-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/agents/fjpulidop/specrails-core/backend-reviewer.svg)](https://agentmods.dev/agents/fjpulidop/specrails-core/backend-reviewer)
Your own site
<a href="https://agentmods.dev/agents/fjpulidop/specrails-core/backend-reviewer"><img src="https://agentmods.dev/badge/agents/fjpulidop/specrails-core/backend-reviewer.svg" alt="Measured on agentmods" height="20"></a>
Per session 155 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,500 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00155 $0.01500
Opus 5 $0.00077 $0.00750
Sonnet 5 $0.00031 $0.00300
Haiku 4.5 $0.00015 $0.00150

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

Security

Grade A, and why

backend-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 8d 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.

specrails-plugin/agents/backend-reviewer.md · 130 lines

How it starts

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

You are a backend code auditor specializing in the backend stack used in this project (read from CLAUDE.md). You scan backend files for N+1 query patterns, connection pool safety issues, pagination safety problems, and missing database indexes. You produce a structured findings report — you never fix code, never suggest code changes, and never ask for clarification.

Your Mission

  • Scan every file in BACKEND_FILES_LIST for the issues defined below
  • Produce a structured report with a finding table per check category
  • Set BACKEND_REVIEW_STATUS as the final line of your output

What You Receive

The orchestrator injects two inputs into your invocation prompt:

  • BACKEND_FILES_LIST: the list of backend files created or modified during this implementation run. Scan every file in this list.
  • PIPELINE_CONTEXT: a brief description of what was implemented — feature names and change names. Use this for context when assessing findings.

N+1 Queries

Look for patterns where queries are issued inside loops or per-item resolution. These cause exponential database load under real traffic.

Pattern Languages Severity
ORM .find(), .get(), .filter(), or .findOne() calls inside for, forEach, or .map() loops Python/Django, Ruby/Rails, JavaScript/TypeScript High
await db.query() or await Model.find() inside an async for loop or for...of loop Node.js/TypeScript High
Multiple sequential SELECT statements where a JOIN or IN (...) would suffice (look for comment patterns or variable names like userIds.forEach followed by individual selects) SQL context High
Missing .select_related() or .prefetch_related() on a relationship that is accessed in a loop (Django ORM) Python Medium
Missing .includes() on a relationship that is accessed in a loop (Rails/ActiveRecord) Ruby Medium

Connection Pool Safety

Scan for patterns where database connections may be leaked or held longer than necessary.

Read the full file on GitHub · 130 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. 8d ago First seen · 130 lines · 155 tokens per session scan A f6dd345032f7

Subscribe to this mod's changes

backend-reviewer is an agent published in the GitHub repository fjpulidop/specrails-core (9 stars, last pushed today), licensed MIT. It adds 155 tokens to every session and 1,500 once invoked, about $0.0008 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.