agentleFS
charlesmsiegelcharlesmsiegel/coding-skills/skills/brutal-review/SKILL.md

brutal-review

Skill2 starsChanged 4 months agoMITView on GitHub

Tear a change apart the way a hostile senior reviewer would — hunt for the input that breaks it, not for style. Use when the user wants a harsh, adversarial, or skeptical review of a diff, branch, PR, or pasted change: "brutal review", "tear this apart", "what would a hostile reviewer say", "what edge cases am I missing", "poke holes in this", "be harsh", "what's wrong with this". Language-agnostic. Every criticism must name the concrete input, sequence, or state that breaks the code — a complaint with no failing case is cut before it reaches the user. Produces a ranked findings artifact with a blocking/non-blocking verdict. For "simplify this", "clean this up", or "is this over-engineered", use python-code-doctor instead; this skill uses its analyze_diff.py for Python diffs when that skill happens to be installed, and the repo's own tools otherwise.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

8 rules. About 0 are common, 6 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Get the change and its context: Default to the working diff.

    line 43
  2. Distinctive:

    Read enough of the *surrounding* code to know what the change assumes.

    line 52
  3. Distinctive:

    Run the mechanical pass first, if one applies: Do not spend attacking attention on what a tool already finds.

    line 57
  4. Very specific:

    Test for the file in its own if.

    line 79
  5. Distinctive:

    If it genuinely isn't there, do not go looking for it on the network or reimplement it: run the repo's tools and continue.

    line 84
  6. Distinctive:

    Kill your own weak findings: Before writing anything down, take each candidate and try to *dismiss* it: does the failing case actually …

    line 96
  7. Very specific:

    Rank and deliver: Use references/review-verdicts.md for the severity rubric and the blocking call.

    line 102
  8. Distinctive:

    Every criticism carries a failing case: No exceptions, including for security and performance claims.

    line 126

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Brutal Review

A hostile-reviewer skill. The job is to find the input that breaks this change before a user does — and to be specific enough that every finding can be confirmed or dismissed in under a minute.

The stance, and the failure it invites

Adopt the posture of a senior reviewer who has been burned by code like this before, has no stake in the author's feelings, and assumes the change is wrong until it survives an attack.

That posture has exactly one failure mode, and it is the one to guard against hardest: inventing criticism to satisfy the persona. A review asked to be harsh will happily manufacture plausible-sounding objections — "this could have race conditions", "this might not scale", "consider error handling" — that name no actual defect. That is worse than a soft review, because it costs the author real time and teaches them to discount the next one.

So the discipline is:

Every finding names the concrete input, sequence, or state that produces the wrong result. If you cannot write down the failing case, you do not have a finding — you have a feeling. Cut it.

"What happens with an empty list?" is a question, not a finding. "total() returns None instead of 0 for an empty list, and format_total() on line 48 then raises on None" is a finding. Harshness comes from what you look for, never from how you phrase it.

Workflow

Let SKILL=/path/to/this/skill — the directory holding this SKILL.md. Commands run from the repository under review, not from the skill directory. Needs git; gh only for the PR form of step 1. This skill ships no detectors of its own, so there is nothing to install.

  1. Get the change and its context. Default to the working diff; take an explicit ref, PR, or pasted snippet when given one.

    git diff                       # uncommitted
    git diff --merge-base main     # the branch's whole contribution
    gh pr diff <n>                 # a specific PR

    Read enough of the surrounding code to know what the change assumes. Most real defects live at the seam between new code and old, and a diff hides that seam by definition — the caller that still passes the old argument shape is not in the diff.

  2. Run the mechanical pass first, if one applies. Do not spend attacking attention on what a tool already finds.

    This skill ships no detectors — it uses whatever the repo or the environment already provides (ruff, eslint, go vet, clippy, mypy, the project's own make lint). Prefer the repo's own configured tools; they encode rules the maintainers agreed to.

    For a Python diff, the python-code-doctor skill adds a diff-scoped detector pass. It is optional and lives in a separate skill directory, so look before invoking:

    # sibling install (~/.claude/skills/, ~/.codex/skills/, .kiro/skills/, ...)
    PS="$(dirname "$SKILL")/python-code-doctor"
    if [ -f "$PS/scripts/analyze_diff.py" ]; then
        python "$PS/scripts/analyze_diff.py" --format json    # non-zero here is a real failure
    else
        echo "python-code-doctor not installed — using the repo's own tools only"
    fi

    Test for the file in its own if. Chaining && … || … would report "not installed" when the analyzer is installed and exits non-zero — an unresolvable base ref, a broken git diff — which turns an incomplete mechanical pass into what looks like an absent optional component.

    If it genuinely isn't there, do not go looking for it on the network or reimplement it: run the repo's tools and continue. The mechanical pass is an accelerator, not a precondition. But the three cases — ran clean, ran and failed, never ran — must not look alike to a reader, so record which one happened in Not reviewed.

    Either way their findings are inputs to this review, not the review.

  3. Attack the change, using references/attack-checklist.md. Work the angles deliberately rather than reading top-to-bottom — reading in file order finds style, and attacking by failure mode finds bugs.
  4. Kill your own weak findings. Before writing anything down, take each candidate and try to dismiss it: does the failing case actually reach this code? Is it already handled upstream? Would the test suite have caught it? A finding that survives your own attempt to refute it is worth the author's time. This step is what separates a brutal review from a rude one.
  5. Rank and deliver. Use references/review-verdicts.md for the severity rubric and the blocking call.

Output

A findings artifact, ranked most-severe first, plus one explicit verdict. Per finding:

  • Where — file:line.
  • What breaks — the concrete input, sequence, or state, and the wrong result it produces.
  • Why it matters — the consequence, not a restatement of the defect.
  • The fix — a specific one. "Handle this better" is not a fix.

Then the verdict: blocking, non-blocking, or needs a decision from the author. Say which findings drive it. A review that ranks nothing and blocks on everything has made no judgment.

State what you did not review, always. Untouched callers you didn't trace, generated files you skipped, a subsystem you don't understand. A silent gap reads as a clean bill of health.

Rules that keep this honest

  • Every criticism carries a failing case. No exceptions, including for security and performance claims. "This is O(n²)" needs the n that hurts and where it comes from.
  • Attack the code, never the author. "This is careless" is noise; the review is about inputs and outputs. Contempt for the code is the persona; contempt for a person is just abuse, and it makes the findings easier to dismiss.
  • Say when the change is fine. A brutal reviewer who never approves anything is not rigorous, just miscalibrated. If the attack pass turns up nothing above a nit, say so plainly and list what you attacked — that is the evidence.
  • Separate "wrong" from "not how I'd do it." Both can appear; they must be labelled differently, and only the first can block.
  • Do not fix while reviewing. Report; let the author decide. If they ask for fixes, that is a separate pass.

Reference index (load on demand)

Load this when…File
Running the attack pass — the failure-mode angles, per-angle prompts, and the seams a diff hidesreferences/attack-checklist.md
Ranking findings, deciding blocking vs nit, phrasing harshly without being wrong, and handling pushbackreferences/review-verdicts.md

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.