Top 200 ReposEXPLORER
Browse agents, categories and pages
Back to results
Planned, not doneThe source describes an intention, not a finished result.

Add an Independent Judge Agent to Application Development

Overview

After Claude Code implements a change, run a separate, read-only Claude Code session in bare mode as a judge that reviews the diff in stages against your acceptance criteria and writes a verdict for you to act on.

Problem or Objective

More in Coding and Code Review

AI Agents and Models

Tools and Integrations

Tools
Claude Code · Git
Prerequisites
A Claude subscription or Anthropic Console account, Claude Code installed, and a Git repository with a main branch to diff against.

How It Works

Build the feature as usual in an interactive Claude Code session, with your coding standards and review checklist in CLAUDE.md. When the implementer says it is done, start a separate judge run instead of asking the same session to check itself: pipe the diff against your main branch into claude --bare -p with a judge prompt, and allow only the Read tool so the judge can open files but not change them. Bare mode skips the project's CLAUDE.md, auto memory, hooks, skills and MCP servers, so put the acceptance criteria and checklist straight into the judge prompt. Ask for staged reviews in one report: first whether the change meets each acceptance criterion, then correctness and tests, then security. Save the output to a file. Read the verdict yourself, hand any findings back to the implementing session to fix, rerun the judge, and merge only when you are satisfied.

Implementation Workflow

Steps assembled from the agents, tools and prompt of this entry. Adapt them to your own setup.

  1. Choose the agentSet up Claude Code.
  2. Connect the toolsConnect the tools this workflow relies on: Claude Code, Git.
  3. Check the prerequisitesA Claude subscription or Anthropic Console account, Claude Code installed, and a Git repository with a main branch to diff against.
  4. Gather your detailsCollect what the prompt asks for: Feature being judged, Acceptance criteria, Review checklist.
  5. Run the starter promptPaste the starter prompt below into Claude Code and adapt it to your case.
  6. Check against the documentationCompare what you get with the documentation at code.claude.com before you rely on it.

Practical Starter Prompt: Judge a finished change

Fill the fields to adapt the prompt. Empty fields stay as visible [placeholders].

Preview
You are a reviewer who did not write this change. The diff for [Feature being judged] is on standard input; open any file you need, but change nothing. Acceptance criteria: [Acceptance criteria]. Review checklist: [Review checklist]. Report in three stages: 1) for each criterion, met or not met with the file and line that shows it; 2) correctness and test coverage, naming any untested path; 3) security issues. End with a verdict of pass or needs changes and a numbered list of fixes. Do not suggest merging; a person decides.

Pipe the diff into claude --bare -p with this prompt, allow only the Read tool, and save the output to a file. Read the verdict yourself, send fixes back to the implementing session, rerun the judge, and merge only after your own review.

Expected Results and Benefits

This is a suggested workflow, not a reported result. The points below are what the cited documentation says the tools can do.

This is a suggested workflow, not a reported outcome. Claude Code's docs document non-interactive runs with claude -p, a --bare mode that skips auto-discovery of CLAUDE.md, auto memory, hooks, skills and MCP servers, --allowedTools for limiting what a run may use, and piping a diff into Claude for review. No cited page measures how many defects a separate judge run catches compared with an ordinary review.

Limitations and Considerations

Without --bare, a -p session runs the hooks in the project's settings and connects the servers in its .mcp.json even in a folder you have never trusted, so use bare mode for the judge in unfamiliar repositories. Allow only read tools for the judge so it cannot edit the code it is judging. The judge's verdict is advice: a person still reads the diff and decides what merges. Most Claude Code surfaces require a Claude subscription or Anthropic Console account, and each judge run uses part of your usage. Results depend on your setup and were not independently reproduced by Top 200 Repos.

GitHub Repositories

AI Agent Repository

Source code of the agent that does the work.

Official Website

The official site of the main tool or project in this use case.

Visit Website (opens in a new tab)code.claude.com

Related Videos

About anthropics/claude-code

About anthropics/claude-code

Independent creators. Listing a video implies no endorsement, sponsorship or partnership.

Sources

  1. Run Claude Code programmatically - Claude Code Docs (opens in a new tab)

    Project documentation · code.claude.com · Undated · Source checked 26 Nov 2026, 17:27 UTC

    What this source supports
    • Runs non-interactively with claude -p, or from Python and TypeScript through the Agent SDK, for scripts and automation.
    • Add --bare to reduce startup time by skipping auto-discovery of your hooks, skills, custom commands, subagents, installed plugins, MCP servers, auto memory, and CLAUDE.md.
    • Without --bare, a -p session runs the hooks in a project's .claude/settings.json and connects the servers in its .mcp.json, even in a folder you've never trusted.
    • Use --allowedTools to let Claude use certain tools without prompting.
  2. Overview - Claude Code Docs (opens in a new tab)

    Project documentation · code.claude.com · Undated · Source checked 25 Nov 2026, 11:57 UTC

    What this source supports
    • CLAUDE.md is read at the start of every session; use it to set coding standards, architecture decisions, preferred libraries, and review checklists.
    • Claude Code can be piped into, for example git diff main --name-only | claude -p "review these changed files for security issues".
    • Most surfaces require a Claude subscription or Anthropic Console account.
Report a problem

More with Claude Code

Planned, not done

Create Custom Store Tools Instead of Paying for Subscriptions

Use Claude Code to write small in-house tools for an online shop, such as a reply helper for support mail or a margin report, as an alternative to paying for separate apps, with testing before you rely on them.

code.claude.comanthropics/claude-code
Reported by source

Answer technical questions by letting async agents run experiments

Simon Willison sends research questions to cloud coding agents such as Claude Code for web and Codex Cloud, which write and run experiments in a dedicated repo and open a PR.

simonwillison.net · 6 Nov 2025anthropics/claude-code, openai/codex
Planned, not done

Structure Repeated Browser Research Into Evidence Tables

Give Claude Code the open-source Browser Use CLI with a local browser, ask the same research questions across a short list of pages, and keep every answer as a sourced table row.

github.comanthropics/claude-code, browser-use/browser-use

View all: Claude Code