agentleFS
ridermwridermw/my-skills/skills/adversarial-review/SKILL.md

adversarial-review

Skill0 starsChanged 3 months agoMITView on GitHub

Pressure-tests an idea, plan, or change by running separated adversarial reviewer perspectives rather than a generic pros/cons list, then synthesizes consensus-ranked findings with severity, confidence and cited evidence. SPAR mode debates a decision through roles with conflicting incentives; Rubber Duck mode runs independent critique reviewers over an artifact and ranks what they agree on. Always discloses the execution path it actually achieved and never claims reviewers or model diversity it did not. Use when the user asks to pressure-test, stress-test, poke holes in, red-team or critique an idea, proposal, strategy, architecture tradeoff, code change, test plan, debugging hypothesis, suspected bug or risky decision. For a bounded pre-coding readiness gate on a concrete implementation plan use plan-exit-review, and for a maximum-rigor audit of a high-risk plan use plan-mega-review; this skill is adversarial critique of any artifact or decision, not a plan-approval workflow.

63 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use design-doc, simplify and 6 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • maragudkSkill

    design-doc

    For when you're asked to write a design doc or specification, especially after a brainstorm or feature design session.

    Also in 3 projects that use this

  • Hugging FaceSkill

    simplify

    Refactor code after tests pass. The "Refactor" phase of Red-Green-Refactor.

    Also in 4 projects that use this

  • AnthropicSkill

    status

    Case status summary by audience — client-facing (plain language), internal (for the professor), or court-ready (formal caption format per local rules). Same facts, different framing and depth. Use when a student needs to update the client, brief the professor, or prepare a court status report.

    Also in 3 projects that use this

  • GoogleSkill

    code-review

    Adversarial systems, concurrency, memory-model, and architecture code review protocol. Use this skill whenever asked to review code, PRs, diffs, or branches in Filament.

    Also in 6 projects that use this

  • VercelSkill

    web-design-guidelines

    Review UI code for Web Interface Guidelines compliance. Use when asked to "review my UI", "check accessibility", "audit design", "review UX", or "check my site against best practices".

    Also in 3 projects that use this

  • DockerSkill

    research

    Research a documentation topic — locate affected files, understand the problem, identify what to change. Use when investigating an issue, a question, or a topic before writing a fix. Triggers on: "research issue 1234", "investigate what needs changing for #500", "what files are affected by #200", "where is X documented", "is our docs page about Y accurate", "look into how we document Z".

    Also in 3 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

30 rules. 0 are common, 24 are distinctive, and 6 are very specific to this project.

  • 0

    Common

    Most of the 56 edited versions we read keep these.

  • 24

    Distinctive

    This author's own choices. Worth a look.

  • 6

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If the conversation already contains <skill-context name="adversarial-review">, for example after /adversarial-review, the skill is loaded.

    line 20
  2. Distinctive:

    Every reviewer prompt starts with this exact line:

    line 26
  3. Very specific:

    Before you choose a mode, write one line: Target: <exact target>.

    line 42
  4. Distinctive:

    If you cannot identify the exact target, or it differs from what the user named, ask before you launch reviewers.

    line 49
  5. Distinctive:

    Enumerate, then rank: Ask the runtime which models it exposes and group them by provider.

    line 106
  6. Distinctive:

    Never fabricate: If a provider, model, or effort level is not actually exposed, do not invent it and do not substitute a small-tier model …

    line 132
  7. Very specific:

    Do not let the same context that produced the artifact be the only critic.

    line 157
  8. Distinctive:

    Before listing findings, each Rubber Duck reviewer writes one failure narrative:

    line 161
  9. Distinctive:

    Use the failure narrative as input to the findings list.

    line 165
  10. Distinctive:

    Every Rubber Duck review checks these categories:

    line 169
  11. Distinctive:

    Do not send identical persona instructions to all reviewers unless the user explicitly asks for repeated sampling.

    line 195
  12. Distinctive:

    Use sections: Conflict framing, Roles, Perspective [Role], Synthesis, Open question(s).

    line 207
  13. Distinctive:

    Use sections: Critique target, Execution disclosure, Consensus-ranked findings, Single-reviewer findings worth considering, Recommended …

    line 223
  14. Distinctive:

    Ask each reviewer to return findings in this shape:

    line 227
  15. Distinctive:

    Every finding must cite specific evidence: file path and line, plan section, data flow, threat path, reproduction idea, or concrete …

    line 262
  16. Distinctive:

    Keep single-reviewer findings in a separate section when they are high severity, well-evidenced, or plausibly important.

    line 274
  17. Distinctive:

    Do not discard a serious issue only because one reviewer found it.

    line 275
  18. Distinctive:

    Do not inflate consensus by counting the main assistant's synthesis as an additional reviewer.

    line 276
  19. Distinctive:

    Treat contradictory findings as a signal.

    line 277
  20. Distinctive:

    After independent first-pass reviews, the synthesizer may show reviewers the other findings and ask:

    line 293
  21. Distinctive:

    Do not count this second round as new independent consensus.

    line 297
  22. Distinctive:

    If all reviewers agree too neatly, run a groupthink check: ask one reviewer to identify what shared assumption could make all reviewers …

    line 299
  23. Distinctive:

    If one or more reviewers fail:

    line 303
  24. Distinctive:

    Do not invent missing reviewer findings.

    line 308
  25. Very specific:

    If no reviewer returns usable findings, fall back to single-agent critique and disclose the fallback.

    line 309
  26. Very specific:

    Before any launch, write the Target: line (see Identify the Target) and the Mode: line once.

    line 319
  27. Distinctive:

    No slash commands: invoke by name, e.g.

    line 332
  28. Very specific:

    No model override: run three independent subagents if possible and disclose model diversity not confirmed.

    line 335
  29. Distinctive:

    No three-subagent support: run the available critique subagent count and disclose the downgrade.

    line 336
  30. Distinctive:

    No subagents: simulate separated perspectives sequentially and disclose that limitation.

    line 338

“Common” is measured: kept by at least 6 in 10 of the 56 edited versions of this file we could read. “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

Adversarial Review

Updated: October 3, 2026

First Response Line

Your first visible line after this skill loads is:

Adversarial review | Updated: <date>

Replace <date> with the Updated: date at the top of this loaded text. Write this line before the mode, the target, any reviewer launch, or any analysis.

If the conversation already contains <skill-context name="adversarial-review">, for example after /adversarial-review, the skill is loaded. Do not call the skill tool for it again unless the runtime requires a loader call. Write the first response line from that loaded text.

The runtime can show its own invocation card before this line. This skill cannot change that card.

Reviewer Guard

Every reviewer prompt starts with this exact line:

Reviewer guard: You are a reviewer launched by adversarial-review. Do not load the adversarial-review skill. Do not launch agents or tasks. Review only the target below and return findings in the requested schema.

If your own prompt starts with Reviewer guard:, you are a reviewer. Do not choose a mode, launch agents, or load this skill. Review the target with the Premortem Pass, Review Constitution, Severity and Confidence Calibration, and Evidence Standards. Return the output your prompt requests: the Reviewer Output Schema for Rubber Duck, or the strongest objection, strongest support, hidden assumption, and failure mode for a SPAR role.

Overview

Stress-test thinking before committing. Use separated perspectives first, then synthesize; do not collapse into a generic pros/cons list.

For implementation plans, code changes, tests, debugging hypotheses, or critique requests, prefer independent reviewer contexts and consensus-ranked findings. Consensus is useful only when independence is real.

Identify the Target

Before you choose a mode, write one line: Target: <exact target>.

  • Repository file, plan, or change: repository-relative path or diff range at the commit SHA, or uncommitted changes on <branch> at <HEAD SHA>.
  • Pull request: full URL plus the head commit SHA.
  • Comment, thread, or web document: full URL.
  • Pasted text that is not in a file: its first words in quotes.

If you cannot identify the exact target, or it differs from what the user named, ask before you launch reviewers. Give every reviewer the same target line.

Choose the Mode

User needMode
Idea, proposal, strategy, product bet, architecture tradeoffSPAR
Code change, implementation plan, tests, debugging hypothesis, critique requestRubber Duck
Ambiguous high-stakes decisionSPAR, then Rubber Duck on the favored path
Unclear or out-of-scope requestAsk the user to clarify the decision or artifact before selecting a mode

Capability Check

Apply Proportionality first. For work warranting subagents, select the eligible reviewer roster using the Model Diversity Heuristic and available independent contexts. Record the roster and count (at most three for Rubber Duck), then derive the execution path below. Rubber Duck dispatch reuses that selection; excluded providers do not count.

CapabilityExecution path
At least two selected reviewers on distinct eligible preferred providers with confirmed model overrides, plus an optional rule 9 reviewermulti-model-subagents
At least two selected independent contexts but distinct model control is unavailable or unconfirmedparallel-subagents
One selected critique/generic subagentsingle-subagent
No eligible subagent can be selectedsingle-agent

For a substantive artifact, target three independent reviewer contexts whenever possible; see Proportionality below for when a smaller artifact does not warrant three. When eligible providers or independent contexts are insufficient, reduce the selected count and disclose the downgrade.

Proportionality. Three reviewers are for a substantive artifact — a plan, a design, a diff, a decision with real consequences. For a single function, a one-line question, or a change you could fully critique yourself in a couple of steps, run single-agent, say so, and skip the subagent overhead. Do not spawn reviewers whose combined cost exceeds the value of the critique.

Output length

Match length to the findings, not to the section list. Report every section the mode calls for, but collapse an empty one to a single line instead of padding it. Lead with the highest-priority finding. Do not restate the artifact back to the user, and do not repeat the same finding in full in both the consensus-ranked list and the recommended-changes list — cross-reference it.

Model Diversity Heuristic

The goal is three independent, high-effort reasoning contexts from OpenAI, Anthropic, and xAI. Select by provider, tier, and generation, never by version number. For xAI, choose the newest exposed frontier general-reasoning Grok model. Google and Gemini models are not eligible reviewer substitutes.

Never hardcode a model version — not in this file, and not in your selection reasoning. A concrete version is wrong the moment the runtime updates, and a stale allow-list silently degrades the review by excluding models that did not exist when it was written. Enumerate what the runtime actually exposes at request time, then rank it.

Selection rules:

  1. Enumerate, then rank. Ask the runtime which models it exposes and group them by provider. Do not assume any particular provider or model exists. If the runtime exposes no model list or no provider metadata, tier selection is not possible — do not guess a lineup from memory. Say so, select the independent contexts available without claiming model control, and disclose model diversity not confirmed. Capability Check derives the execution path from the selected count.
  2. Use the preferred provider trio. Assign one reviewer each from OpenAI, Anthropic, and xAI. Independence comes from different providers, not from three variants of one family. If a preferred provider is not exposed, fill that one slot under rule 9; never use Google or Gemini.
  3. Take each provider's frontier general-reasoning tier — the tier that provider positions for its hardest reasoning and agentic work — and the newest generation of that tier.
  4. Exclude the small/fast tier. Skip anything the runtime labels or markets as mini, small, flash, lite, nano, turbo, instant, fast, cheap, or economical, and any model presented as the lightweight sibling of a larger one. Judge by the runtime's own tier description at request time, not by a remembered list of names — tier labels change.
  5. Reasoning effort: xhigh for every reviewer. Request xhigh for each selected model even when it exposes a higher setting. If a model does not expose xhigh, or effort is not controllable, leave effort unset and disclose the limitation rather than silently choosing another level or implying that xhigh was set.
  6. Code review: a code-specialized model may hold a reviewer slot only if it is that provider's frontier tier; otherwise keep general-reasoning models.
  7. Never fabricate. If a provider, model, or effort level is not actually exposed, do not invent it and do not substitute a small-tier model to fill a slot. Fill a missing provider slot under rule 9 when it applies. Otherwise run the reviewers you can, reduce the count, and disclose model diversity not confirmed.
  8. Fewer than three providers is a downgrade to disclose, not a reason to lower the tier bar. Two frontier reviewers beat three where one is a small-tier stand-in.
  9. Fill a missing provider slot with a third context, not a third provider. If only two preferred providers are exposed, give the third reviewer a different frontier model from one of those two providers. It must pass rules 3 and 4, and it must differ from the model that provider already uses. The third model is never Google or Gemini and never a small tier. Disclose three contexts, two providers. If no such model exists, reduce the count.
  10. Pass an explicit model for every reviewer, then check it. The runtime can replace an omitted model with a configured default, which can put every reviewer on one model. After launch, compare each requested model with the model that actually started. If they differ, disclose the substitution, count providers from the started models, and recalculate the execution path from the started models. If the runtime does not accept a model override, launch without model and disclose model diversity not confirmed.

Degeneration-of-Thought Safeguard

Do not let the same context that produced the artifact be the only critic. Prefer fresh reviewer contexts. If fresh contexts are unavailable, disclose single-context critique and lower confidence in the review.

Premortem Pass

Before listing findings, each Rubber Duck reviewer writes one failure narrative:

It is 18 months from now and this shipped system failed in the most damaging credible way. What happened, who was affected, what decision caused it, and which current assumption made it possible?

Use the failure narrative as input to the findings list. Trace each credible failure back to a specific current decision, assumption, missing test, missing control, or operational gap.

Review Constitution

Every Rubber Duck review checks these categories:

  • correctness
  • security
  • reliability
  • performance
  • maintainability
  • test coverage
  • observability
  • operational failure modes
  • data integrity
  • dependency and supply-chain risk

For UI work, also check accessibility, empty/loading/error states, and user trust. For AI-agent or LLM work, also check prompt injection, excessive agency, insecure output handling, sensitive information disclosure, and overreliance.

Adversarial Reviewer Lenses

Reviewer lenses should be distinct. Prefer three of:

  • Security/abuse reviewer: attack surface, trust boundaries, authorization, injection, secrets, abuse paths.
  • Correctness/data-integrity reviewer: edge cases, invalid input, state transitions, silent wrong results, data loss.
  • Reliability/operations reviewer: retries, timeouts, partial failure, deploy/rollback, monitoring, incident response.
  • Performance/scale reviewer: load cliffs, concurrency, memory growth, resource leaks, N+1 work, throttling.
  • Future maintainer reviewer: confusing abstractions, undocumented invariants, brittle coupling, misleading names.
  • Product/user-harm reviewer: confusing UX, broken promises, user trust, accessibility, privacy expectations.

Do not send identical persona instructions to all reviewers unless the user explicitly asks for repeated sampling.

SPAR Mode

  1. State: Mode: SPAR.
  2. Frame the core tension in one sentence.
  3. Pick 3-5 roles with genuinely conflicting incentives.
  4. If execution path is multi-model-subagents or parallel-subagents, dispatch one role per agent in parallel with agent_type: rubber-duck. Start each prompt with the reviewer guard, then the target line. If the path is single-subagent, launch one role that way and simulate the other roles sequentially. Otherwise simulate all roles sequentially. Say which roles were simulated.
  5. For each role, give the strongest objection, strongest support, hidden assumption, and failure mode.
  6. Synthesize only after role perspectives.
  7. End with the single most important open question. If decision-blocking information is genuinely missing, end with up to three such questions instead — but do not pad to more than one when one suffices.

Use sections: Conflict framing, Roles, Perspective [Role], Synthesis, Open question(s).

Rubber Duck Mode

  1. State: Mode: Rubber Duck.
  2. Choose the execution path from Capability Check.
  3. Launch every reviewer with agent_type: rubber-duck. Start each prompt with the reviewer guard, then the target line. If the runtime has no rubber-duck agent, use a general critique subagent and disclose rubber-duck unavailable.
  4. For multi-model-subagents, launch the selected reviewer roster in parallel with its chosen models, effort settings, and distinct Adversarial Reviewer Lenses.
  5. For parallel-subagents, launch the selected number of independent critique subagents in parallel without claiming distinct model coverage.
  6. For single-subagent, launch one critique subagent and perform synthesis yourself; do not count the synthesizer as a second reviewer.
  7. For single-agent, perform the critique yourself and disclose that no subagent was launched.
  8. Each reviewer must receive the same critique target and must not see other reviewers' findings during the first pass.
  9. Each reviewer runs the Premortem Pass, checks the Review Constitution, and returns findings in the Reviewer Output Schema.
  10. Focus only on high-signal issues: correctness, security, reliability, missing tests, bad assumptions, and edge cases.
  11. Separate accepted findings from rejected or unverified concerns.

Use sections: Critique target, Execution disclosure, Consensus-ranked findings, Single-reviewer findings worth considering, Recommended changes, Rejected or unverified concerns, Next action.

Reviewer Output Schema

Ask each reviewer to return findings in this shape:

- title:
  category:
  severity: critical | high | medium | low
  confidence: high | medium | low
  evidence:
  recommended_change:
  dedupe_key:

The dedupe_key should be a short normalized label for matching equivalent issues across reviewers, such as auth-cache-leakage, missing-timeout, or unchecked-null-input.

Each reviewer ends with:

Recommendation: <fix | investigate | ship-as-is> because <one-line reason naming the strongest finding>

Severity and Confidence Calibration

  • critical: likely data loss, security breach, privilege escalation, irreversible user harm, or production outage.
  • high: plausible major reliability, correctness, auth, privacy, or operational failure.
  • medium: localized bug, missing test, maintainability risk, or performance issue with bounded impact.
  • low: minor issue or speculative concern with limited impact.
  • high confidence: directly evidenced by code, plan text, test output, or reproducible reasoning.
  • medium confidence: plausible and specific, but not fully proven.
  • low confidence: speculative, ambiguous, or dependent on unstated assumptions.

Single-reviewer critical or high findings with high-confidence evidence must stay visible even without consensus.

Evidence Standards

Every finding must cite specific evidence: file path and line, plan section, data flow, threat path, reproduction idea, or concrete assumption. Vague concerns are not actionable findings.

For security findings, include STRIDE category when applicable, affected entry point, trust boundary crossed, exploit path, impact, and mitigation.

Consensus Aggregation

After reviewers finish:

  1. Normalize equivalent findings by dedupe_key, title, evidence, and recommended change.
  2. Group matching findings across reviewers.
  3. Rank grouped findings by number of independent reviewers that found the issue.
  4. Break ties by severity, then confidence, then evidence quality.
  5. Keep single-reviewer findings in a separate section when they are high severity, well-evidenced, or plausibly important.
  6. Do not discard a serious issue only because one reviewer found it.
  7. Do not inflate consensus by counting the main assistant's synthesis as an additional reviewer.
  8. Treat contradictory findings as a signal. Preserve the disagreement and recommend how to resolve it.

For each consensus-ranked finding, show:

Priority:
Found by:
Severity:
Confidence:
Issue:
Evidence:
Recommended change:

Cross-Examination Round

After independent first-pass reviews, the synthesizer may show reviewers the other findings and ask:

What did they miss? Which of your original findings should change? Which disagreement is itself a risk?

Do not count this second round as new independent consensus. It is for refinement, conflict discovery, and missed-assumption detection only.

If all reviewers agree too neatly, run a groupthink check: ask one reviewer to identify what shared assumption could make all reviewers wrong.

Reviewer Failure Handling

If one or more reviewers fail:

  • Continue with completed reviewers when at least one usable review exists.
  • Disclose which reviewer failed and whether its model was requested.
  • Rank consensus by completed reviewer count, not the original target of three.
  • Do not invent missing reviewer findings.
  • If no reviewer returns usable findings, fall back to single-agent critique and disclose the fallback.

Judge/Synthesizer Rules

The final synthesizer is a judge, not a fourth reviewer. It deduplicates, evaluates evidence, preserves disagreements, ranks findings, and recommends action. It does not add consensus votes.

LOC is not a proxy for risk. A tiny auth, permissions, data deletion, billing, or security-boundary change can require full adversarial review.

Always Disclose

Before any launch, write the Target: line (see Identify the Target) and the Mode: line once. Then, after the reviewers return and before the findings, write these lines. Keep each line to one sentence.

Execution path: <path> (adversarial-review, Updated: <date>)
Reviewers: <launched count>; <agent type>; <model and effort for each, or model not changed / model diversity not confirmed>; three independent contexts <achieved | not achieved>
Consensus ranking: <performed | not performed, with reason>
Premortem: <one sentence that names the most damaging credible failure>

Never pretend agents were launched or models were changed. Say an agent was launched only if you personally invoked a tool for it in this conversation and can name the tool or agent. Say a model changed only if the runtime confirmed it or the subagent tool accepted a concrete model override. Otherwise say model not changed; retain the actual execution path and launched count.

Portability Fallbacks

  • No slash commands: invoke by name, e.g. "Use adversarial-review on..."
  • Unknown CLI or no skill loader: paste or include this SKILL.md at conversation start and say, "Use the adversarial-review skill from this file on my next request."
  • Skill not loading: if the assistant does not mention adversarial-review or choose SPAR/Rubber Duck mode, assume the file was not loaded.
  • No model override: run three independent subagents if possible and disclose model diversity not confirmed; never substitute a small-tier model to fill a slot.
  • No three-subagent support: run the available critique subagent count and disclose the downgrade.
  • No rubber-duck agent: use generic critique subagents and disclose rubber-duck unavailable.
  • No subagents: simulate separated perspectives sequentially and disclose that limitation.

Common Mistakes

MistakeFix
Balanced pros/consCreate roles with incompatible incentives
Synthesizing too earlyCollect role or reviewer perspectives first
Treating critique as automatically trueVerify findings before changing plans
Hidden execution detailsDisclose mode, execution path, subagents, models, and ranking
Style feedbackPrioritize defects, risks, assumptions, evidence, and tests
Counting yourself as a reviewerConsensus counts only independent reviewer contexts
Claiming model diversity without model controlSay model diversity not confirmed
Naming a specific model versionSelect by provider tier and generation from what the runtime exposes now
Filling a reviewer slot with a small/fast modelUse rule 9 with a frontier model, or reduce the reviewer count and disclose it
Dropping single-reviewer critical findingsKeep serious single-reviewer findings separately
Letting reviewers influence each otherGive each reviewer the same target but not other reviewers' findings during first pass
Treating consensus as proofConsensus is a prioritization signal, not a guarantee
Ignoring disagreementPreserve contradictions and recommend a resolution path
Using LOC as risk proxySmall auth, billing, deletion, or security-boundary changes can be critical

Example

User: "Use adversarial-review on this plan: cache all GET responses in memory for 10 minutes."

Expected shape: choose Rubber Duck mode; disclose whether three model-diverse subagents were launched; collect independent findings; normalize equivalent issues; rank by consensus.

Example consensus:

  • Reviewer A found issues 1, 2, and 3.
  • Reviewer B found issues 2, 3, and 4.
  • Reviewer C found issues 1 and 2.

Final ranking:

  1. Issue 2: found by 3 reviewers.
  2. Issues 1 and 3: found by 2 reviewers.
  3. Issue 4: found by 1 reviewer, retained only if severity/evidence justifies it.

For the cache example, likely high-priority findings include auth leakage from shared cache keys, invalidation gaps, per-user/per-permission cache keys, stale reads, memory growth, missing observability, and missing tests for authorization boundaries.

Disclosure example:

Adversarial review | Updated: October 3, 2026
Target: plan text "cache all GET responses in memory for 10 minutes"
Mode: Rubber Duck
Execution path: multi-model-subagents (adversarial-review, Updated: October 3, 2026)
Reviewers: 3; rubber-duck; one frontier model per preferred provider at xhigh; three independent contexts achieved
Consensus ranking: performed
Premortem: a shared cache key serves one user's authorized response to another user.

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.