phase-b-reviewer

phase-b-reviewer is an agent for Claude Code from auerbachb/claude-code-config. It costs 44 tokens per session (6,746 once invoked), scanned B, original, MIT.

A review-loop agent that runs after code changes are pushed. It checks automated reviews from tools such as CodeRabbit, BugBot/Cursor, and Greptile, fixes findings, pushes updates, and reports whether the merge conditions are met.

In plain words
What is it for?
Use it to poll for automated code reviews, address their findings, update the handoff record, push corrections, and decide whether the pull request can pass its merge gate.
Why use it?
It helps catch and process new review feedback after a fix, so a change is not considered finished before the latest code has been checked.

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/auerbachb/claude-code-config/phase-b-reviewer
Clone the repo
git clone --depth 1 https://github.com/auerbachb/claude-code-config

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 phase-b-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/agents/auerbachb/claude-code-config/phase-b-reviewer.svg)](https://agentmods.dev/agents/auerbachb/claude-code-config/phase-b-reviewer)
Your own site
<a href="https://agentmods.dev/agents/auerbachb/claude-code-config/phase-b-reviewer"><img src="https://agentmods.dev/badge/agents/auerbachb/claude-code-config/phase-b-reviewer.svg" alt="Measured on agentmods" height="20"></a>
Per session 44 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 6,746 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 2 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.00044 $0.06746
Opus 5 $0.00022 $0.03373
Sonnet 5 $0.00009 $0.01349
Haiku 4.5 $0.00004 $0.00675

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

Security

Grade B, and why

phase-b-reviewer scanned grade B with 2 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 3d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

**Verify before you exit:** `handoff-state.sh --owner-repo {{OWNER}}/{{REPO}} --get "$PR" | jq -r '.phase_completed, .head_sha'` must show `B` and the SHA you just pushed, **and** `find ~/.claude/handoffs -name 'pr-{{PR_

Makes network callslowCapability

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

- Before leaving any work undone — whether you'd frame it as impossible, out of scope, a deployment step, or a runbook for someone else — walk the capability ladder for any provider CLI (`gh`, `git`, `curl`, or a service
.claude/agents/phase-b-reviewer.md · 402 lines

How it starts

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

Phase B: Review Loop

You are a Phase B subagent. Your job: poll for code review results (CodeRabbit, BugBot/Cursor, or Greptile), process any findings, fix code, push, update the handoff file, and determine if the merge gate is met. Then EXIT with an exit report.

Resolving helper scripts (do this first)

You may be spawned against any repo, and most repos carry no .claude/ directory. Never invoke a bare .claude/scripts/<name> path — it silently does not exist outside the config repo. Define these once, then call every helper through run_script:

resolve_script() {
  local name="$1" candidate
  for candidate in \
    "$HOME/.claude/skills-worktree/.claude/scripts/$name" \
    "$HOME/.claude/scripts/$name" \
    ".claude/scripts/$name"; do
    if [[ -x "$candidate" ]]; then echo "$candidate"; return 0; fi
  done
  return 1
}

run_script() {            # run_script <name> [args...]
  local name="$1"; shift
  local path
  if ! path=$(resolve_script "$name"); then
    echo "ERROR: $name not found (checked ~/.claude/skills-worktree/.claude/scripts/, ~/.claude/scripts/, .claude/scripts/)" >&2
    return 127
  fi
  "$path" "$@"
}

run_script returns 127 when nothing resolves, after naming the file on stderr. Treat that exit distinctly from the script's own exit codes: a helper that could not be found has not reported anything about the PR, so never fold it into a "no findings" or "gate met" reading. Say which capability is unavailable in one line and block the step that needed it. Full contract: .claude/reference/portable-skill-resolution.md (issue #1189).

Read reference docs the same way, $HOME/.claude/skills-worktree/.claude/reference/<name> first. Rules under .claude/rules/*.md need no fallback — they auto-load at user scope in every project.

Runtime Context

The parent agent provides:

  • PR number and repo ({{OWNER}}/{{REPO}})
  • Handoff file path (e.g., ~/.claude/handoffs/{{OWNER}}/{{REPO}}/pr-{{PR_NUMBER}}-handoff.json; resolve with handoff-state.sh --owner-repo {{OWNER}}/{{REPO}} --path {{PR_NUMBER}})
  • HEAD SHA from the previous phase
  • Reviewer assignment (cr, bugbot, or greptile)
  • Existing findings (if any were already posted before this agent launched)

Read the full file on GitHub · 402 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. 3d ago First seen · 402 lines · 44 tokens per session scan B 5fed5c63f335

Subscribe to this mod's changes

phase-b-reviewer is an agent published in the GitHub repository auerbachb/claude-code-config (5 stars, last pushed 4d ago), licensed MIT. It adds 44 tokens to every session and 6,746 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it B with 2 findings (reads agent configuration directories, 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

business-analyst

Use this agent when refining task descriptions and defining verifiable acceptance criteria for implementation tasks.

NeoLabHQ/context-engineering-kit · 22 tokens

judge

Use this agent when evaluating implementation artifacts against an evaluation specification produced by the meta judge. Applies rubric dimensions, checklist items, and scoring metadata to produce structured verdicts with self-verification and contrastive rule generation when issues are found.

NeoLabHQ/context-engineering-kit · 48 tokens

code-explorer

Use this agent when analyzing existing codebase features, tracing execution paths, mapping architecture, identifying files affected by proposed changes, or understanding integration points for new development.

NeoLabHQ/context-engineering-kit · 36 tokens

godmode-builder

Executes implementation tasks following a Godmode skill workflow exactly.

arbazkhan971/godmode · 15 tokens

bug-hunter

Use this agent when reviewing local code changes or in the pull request to identify bugs and critical issues through systematic root cause analysis. This agent should be invoked proactively after completing a logical chunk of work.

NeoLabHQ/context-engineering-kit · 43 tokens

contracts-reviewer

Use this agent when reviewing local code changes or pull requests to analyze API, data models, and type design. This agent should be invoked proactively when changes affect public contracts, domain models, database schemas, or type definitions.

NeoLabHQ/context-engineering-kit · 48 tokens