Adversarial Spec (Multi-LLM Spec Refinement)
Refines a PRD or technical spec by having Claude debate GPT, Gemini, Grok and other models round after round until every participant agrees.
Docs & OfficeIntermediate★ 556⑂ 49AI score 9/10Last updated: Jan 22, 2026
What it does
- Provides two document blueprints — PRD and Technical Specification — each with its own critique checklist.
- Sends your draft in parallel to the models you select (OpenAI, Anthropic, Gemini, xAI, Mistral, Groq, OpenRouter, Deepseek, Zhipu, Codex CLI, Gemini CLI, or AWS Bedrock) and has Claude add its own independent critique and synthesis.
- Iterates up to 10 rounds until all participants return
[AGREE], with a--pressanti-laziness check when a model agrees suspiciously early. - Extras: deep interview mode before the debate, focus areas (security, scalability, performance, ux, reliability, cost), reviewer personas, context injection of existing docs/schemas, named sessions with resume, per-round checkpoints, retry with backoff, and token cost tracking.
- Final output is printed and written to
spec-output.md, with an optional hand-off from PRD to a matching tech spec and optional Telegram human-in-the-loop notifications.
Who it's for
- PMs and founders writing specs solo who want adversarial review instead of a rubber stamp.
- Engineers and architects on small teams without a strong design-review culture.
- Anyone who already holds multiple provider API keys (or Codex/Gemini CLI access) and can absorb per-round token cost.
Example uses
- "Draft a PRD for our new payment onboarding flow" → interview mode gathers requirements, Claude drafts, gpt-4o and gemini critique, consensus PRD lands in
spec-output.mdafter three rounds. - Load an existing
./docs/auth-spec.mdand run with--focus security --persona security-engineerto surface missing authn/authz and input-validation details. - Cycle 1 with cheap fast models for structure, cycle 2 with o1 or claude-opus for hard validation, then read the cycles/rounds summary of every change made.
· · · Install guide · · ·
Try it now, no install
Paste this into Claude to use the skill without installing anything.
Read the instructions in this file and follow them to help me: https://raw.githubusercontent.com/zscole/adversarial-spec/HEAD/skills/adversarial-spec/SKILL.md What I want: (describe your task here)
If Claude can't open the link, open it yourself and paste the contents instead.
↓ If it works for you, download the ZIP below and install it. Then it runs on its own — no pasting each time.
Install in the Claude app (no terminal)
- Download the ZIP with the button below.
- In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
- Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
Install in Claude Code
Let Claude do it — paste this into Claude Code
Install the skill I found on Claude Skill Mart. Copy the skills/adversarial-spec folder from the GitHub repo zscole/adversarial-spec into my ~/.claude/skills/adversarial-spec/. When it's done, tell me in one line what this skill can do.
Install with a command instead
git clone https://github.com/zscole/adversarial-spec.git /tmp/adversarial-spec && mkdir -p ~/.claude/skills && cp -r /tmp/adversarial-spec/skills/adversarial-spec ~/.claude/skills/⚠ This is a third-party skill. Check the source repository before installing.
- Clone the repository:
git clone https://github.com/zscole/adversarial-spec.git - Copy the skill into your Claude Code skills folder:
mkdir -p ~/.claude/skills && cp -r adversarial-spec/skills/adversarial-spec ~/.claude/skills/ - Make sure you have Python 3.10+ and install the dependency:
pip install litellm(do NOT install the unrelatedllmpackage). - Export at least one provider key, e.g.
export OPENAI_API_KEY=...orexport GEMINI_API_KEY=...(add to~/.zshrcor~/.bashrcto persist). - Optional subscription route instead of keys:
npm install -g @openai/codex && codex login, ornpm install -g @google/gemini-cli && gemini auth. - Verify your setup:
python3 "$(find ~/.claude -name debate.py -path '*adversarial-spec*' | head -1)" providers - Restart Claude Code and ask something like "refine this spec with an adversarial multi-model debate" to trigger the skill.
- Optional: if you hit the claude.ai token vs
ANTHROPIC_API_KEYconflict error, rununset ANTHROPIC_API_KEY(or log out of claude.ai) before retrying.
View source on GitHub ↗License: MIT