/sc-adversarial-hunt
General-purpose adversarial analysis with competing finder, skeptic, and arbiter agents. Works on code, plans, docs, configs, or any artifact.
> /plugin marketplace add kylesnowschwartz/SimpleClaudeHow it fires
How this command gets triggered: by you, by Claude, or both.
- Fires itselfClaude auto-loads it when your prompt matches the work.
- You can call itInvoke it directly when you want it.
- Slash command
/sc-adversarial-hunt
Context preview
What this command does when you run it.
General-purpose adversarial analysis with competing finder, skeptic, and arbiter agents. Works on code, plans, docs, configs, or any artifact.
Command definition
sc-adversarial-hunt.mdname: sc-adversarial-hunt
description: General-purpose adversarial analysis with competing finder, skeptic, and arbiter agents. Works on code, plans, docs, configs, or any artifact.
allowed-tools: Task, Read, Bash, Grep, Glob, AskUserQuestion, TodoWrite
argument-hint: "[target] [optional: focus hint e.g. 'security', 'architecture', 'accuracy']"
Adversarial Hunt
Three agents with competing economic incentives analyze any target. A maximizer finds all possible issues, a skeptic filters false positives through asymmetric penalties, and an arbiter produces the final ground-truth ruling. Domain-agnostic — works on code, plans, documentation, configs, reasoning, or any artifact.
EXECUTION MODEL: STRICTLY SEQUENTIAL
**Phases 2, 3, and 4 MUST run in strict sequence. NEVER launch them in parallel.**
Each phase depends on the previous phase's output:
- Phase 2 (Maximizer) runs first, produces findings
- Phase 3 (Skeptic) REQUIRES the Maximizer's findings as input — cannot start until Phase 2 completes
- Phase 4 (Arbiter) REQUIRES both Maximizer AND Skeptic reports as input — cannot start until Phase 3 completes
**After each Task() call, you MUST wait for the task to complete and read its output before proceeding to the next phase.** Use `TaskOutput` with `block: true` to wait. Display the phase summary to the user. Only then move to the next phase.
Phase 0: Resolve Target and Classify
Parse $ARGUMENTS. The first argument is the target, anything after is a focus hint.
Target resolution
| Argument | Target | |----------|--------| | *(empty)* or `staged` | Uncommitted changes — run `git diff HEAD` | | `branch` | Current branch vs main — run `git diff main...HEAD` | | `pr <number>` | PR diff — run `gh pr diff <number>` | | File or directory path | That specific path |
For diff-based targets, save the diff to `/tmp/adversarial-hunt-diff.txt` and verify non-empty. This file is referenced by agents.
Deep read
Before classifying or generating lenses, YOU (the orchestrator) must actually read the target thoroughly:
- For diffs: read the diff AND the changed source files. Understand what the code does, not just what changed.
- For files/directories: read the files, check imports, trace key call paths with Grep.
- For plans/docs: read the full document and any referenced files.
This deep read is what makes the lenses specific rather than generic. Skip it and the whole process degrades.
Classification
| Domain | Signals | |--------|---------| | **Code** | Source files, diffs, test files | | **Plan/Design** | PLAN.md, ARCHITECTURE.md, ADRs, implementation plans | | **Documentation** | README, API docs, guides, comments | | **Configuration** | YAML, JSON configs, CI/CD pipelines, infrastructure | | **Reasoning** | Analysis documents, investigations, decision records, trade-off evaluations | | **Communication** | Emails, PR descriptions, RFCs, proposals, announcements |
Tell the user: "Target: [what]. Domain: [classified]. Focus: [hint or inferred]."
Phase 1: Generate Lenses
Before launching any agents, generate three domain-specific artifacts from your Phase 0 deep read:
1. Analysis Lenses (for the Maximizer)
Generate 5-8 concrete lenses appropriate to the domain and target. Each lens is a specific angle of attack that references actual elements you found in the target.
Examples of what good lenses look like (do NOT copy these — generate fresh lenses from the actual target):
- Code: "Null propagation paths where X returns nil but Y assumes non-nil"
- Plan: "Dependencies between steps 3 and 7 that aren't acknowledged"
- Config: "Environment variables referenced but never defined"
- Docs: "API examples that contradict the parameter descriptions"
"Check error handling" is too vague. "Error handling gap in the retry loop at auth.rb:45 where TimeoutError isn't caught" is a lens.
2. Severity Scale (for scoring)
Define what +1, +5, and +10 mean for THIS domain and target:
+1 (low): [domain-specific definition]
+5 (medium): [domain-specific definition]
+10 (critical): [domain-specific definition]
3. Disproof Categories (for the Skeptic)
Generate 4-6 categories for valid disproofs, specific to the domain:
- [CATEGORY]: [what it means for this domain]
Show all three artifacts to the user before proceeding. This lets them steer if the lenses are off-target.
Phase 2: Maximizer (Superset)
**BLOCKING**: Launch the Maximizer agent. Wait for it to complete. Read its full output. Display the summary. Only then proceed to Phase 3.
The Maximizer has full read access to the codebase — point it at the files, don't paste content into the prompt.
For diff-based targets, tell the Maximizer where the diff file is AND which source files changed, so it can read both.
Task(
subagent_type: "Explore",
description: "Find all issues in target",
prompt: """
## Role: Maximizer
You are competing for the highest score. You are rewarded by impact:
- +1 point: [GENERATED low definition]
- +5 points: [GENERATED medium definition]
- +10 points: [GENERATED critical definition]
Maximize your score. If something MIGHT be an issue, report it.
Your adversary will try to disprove your findings. Let them try.
## Target
[For diffs]: The diff is at /tmp/adversarial-hunt-diff.txt. The changed files are: [list paths]. Read both the diff and the source files for full context. Also read tests for the changed code if they exist.
[For files]: Analyze these files: [list paths]. Read them and any closely related files (tests, callers, config).
## Analysis Lenses
Examine the target through each of these lenses:
[GENERATED lenses, numbered]
You are not limited to these lenses. If you find issues outside them, report those too.
## Output Format
### FINDING-001: [Short title]
**Impact**: critical (+10) | medium (+5) | low (+1)
**Location**: [file:line, section reference, or specific element]
**Description**: [Wha
Read more
name: sc-adversarial-hunt description: General-purpose adversarial analysis with competing finder, skeptic, and arbiter agents. Works on code, plans, docs, configs, or any artifact. allowed-tools: Task, Read, Bash, Grep, Glob, AskUserQuestion, TodoWrite argument-hint: "[target] [optional: focus hint e.g. 'security', 'architecture', 'accuracy']"
Adversarial Hunt
Three agents with competing economic incentives analyze any target. A maximizer finds all possible issues, a skeptic filters false positives through asymmetric penalties, and an arbiter produces the final ground-truth ruling. Domain-agnostic — works on code, plans, documentation, configs, reasoning, or any artifact.
EXECUTION MODEL: STRICTLY SEQUENTIAL
**Phases 2, 3, and 4 MUST run in strict sequence. NEVER launch them in parallel.**
Each phase depends on the previous phase's output:
- Phase 2 (Maximizer) runs first, produces findings
- Phase 3 (Skeptic) REQUIRES the Maximizer's findings as input — cannot start until Phase 2 completes
- Phase 4 (Arbiter) REQUIRES both Maximizer AND Skeptic reports as input — cannot start until Phase 3 completes
**After each Task() call, you MUST wait for the task to complete and read its output before proceeding to the next phase.** Use `TaskOutput` with `block: true` to wait. Display the phase summary to the user. Only then move to the next phase.
Phase 0: Resolve Target and Classify
Parse $ARGUMENTS. The first argument is the target, anything after is a focus hint.
Target resolution
| Argument | Target | |----------|--------| | *(empty)* or `staged` | Uncommitted changes — run `git diff HEAD` | | `branch` | Current branch vs main — run `git diff main...HEAD` | | `pr <number>` | PR diff — run `gh pr diff <number>` | | File or directory path | That specific path |
For diff-based targets, save the diff to `/tmp/adversarial-hunt-diff.txt` and verify non-empty. This file is referenced by agents.
Deep read
Before classifying or generating lenses, YOU (the orchestrator) must actually read the target thoroughly:
- For diffs: read the diff AND the changed source files. Understand what the code does, not just what changed.
- For files/directories: read the files, check imports, trace key call paths with Grep.
- For plans/docs: read the full document and any referenced files.
This deep read is what makes the lenses specific rather than generic. Skip it and the whole process degrades.
Classification
| Domain | Signals | |--------|---------| | **Code** | Source files, diffs, test files | | **Plan/Design** | PLAN.md, ARCHITECTURE.md, ADRs, implementation plans | | **Documentation** | README, API docs, guides, comments | | **Configuration** | YAML, JSON configs, CI/CD pipelines, infrastructure | | **Reasoning** | Analysis documents, investigations, decision records, trade-off evaluations | | **Communication** | Emails, PR descriptions, RFCs, proposals, announcements |
Tell the user: "Target: [what]. Domain: [classified]. Focus: [hint or inferred]."
Phase 1: Generate Lenses
Before launching any agents, generate three domain-specific artifacts from your Phase 0 deep read:
1. Analysis Lenses (for the Maximizer)
Generate 5-8 concrete lenses appropriate to the domain and target. Each lens is a specific angle of attack that references actual elements you found in the target.
Examples of what good lenses look like (do NOT copy these — generate fresh lenses from the actual target):
- Code: "Null propagation paths where X returns nil but Y assumes non-nil"
- Plan: "Dependencies between steps 3 and 7 that aren't acknowledged"
- Config: "Environment variables referenced but never defined"
- Docs: "API examples that contradict the parameter descriptions"
"Check error handling" is too vague. "Error handling gap in the retry loop at auth.rb:45 where TimeoutError isn't caught" is a lens.
2. Severity Scale (for scoring)
Define what +1, +5, and +10 mean for THIS domain and target:
+1 (low): [domain-specific definition] +5 (medium): [domain-specific definition] +10 (critical): [domain-specific definition]
3. Disproof Categories (for the Skeptic)
Generate 4-6 categories for valid disproofs, specific to the domain:
- [CATEGORY]: [what it means for this domain]
Show all three artifacts to the user before proceeding. This lets them steer if the lenses are off-target.
Phase 2: Maximizer (Superset)
**BLOCKING**: Launch the Maximizer agent. Wait for it to complete. Read its full output. Display the summary. Only then proceed to Phase 3.
The Maximizer has full read access to the codebase — point it at the files, don't paste content into the prompt.
For diff-based targets, tell the Maximizer where the diff file is AND which source files changed, so it can read both.
Task( subagent_type: "Explore", description: "Find all issues in target", prompt: """ ## Role: Maximizer You are competing for the highest score. You are rewarded by impact: - +1 point: [GENERATED low definition] - +5 points: [GENERATED medium definition] - +10 points: [GENERATED critical definition] Maximize your score. If something MIGHT be an issue, report it. Your adversary will try to disprove your findings. Let them try. ## Target [For diffs]: The diff is at /tmp/adversarial-hunt-diff.txt. The changed files are: [list paths]. Read both the diff and the source files for full context. Also read tests for the changed code if they exist. [For files]: Analyze these files: [list paths]. Read them and any closely related files (tests, callers, config). ## Analysis Lenses Examine the target through each of these lenses: [GENERATED lenses, numbered] You are not limited to these lenses. If you find issues outside them, report those too. ## Output Format ### FINDING-001: [Short title] **Impact**: critical (+10) | medium (+5) | low (+1) **Location**: [file:line, section reference, or specific element] **Description**: [Wha
A practical minimalist AI assistant framework that transforms complex AI interactions into natural conversations. Comes with a set of user-commands, sub-agents, hooks, and utilities designed for real-world software development tasks.
Other commands on simpleclaude.
sc-plan
Strategic planning and analysis for requirements and roadmaps
sc-review
Verify code quality, security, performance, and architecture
sc-work
Build, fix, or modify code - handles all implementation tasks
sc-workflow
Guided feature development with codebase understanding and architecture focus
sc-answer
Re-elicit the questions from your last message via the AskUserQuestion tool

