adversarial-validator

adversarial-validator is an agent for coding agents from jimmc414/claude-code-plugin-marketplace. It costs 34 tokens per session (1,011 once invoked), scanned A, original, MIT.

An agent that checks whether adversarial tests genuinely test the intended code. Adversarial tests use unusual or difficult inputs to expose weaknesses.

In plain words
What is it for?
Reviewing tests through static checks, execution, expected-result verification, and mutation testing, then returning a structured verdict.
Why use it?
It catches tests that are unrealistic, do not call the target code, or make meaningless assertions before accepting their results.

Agent

Part of the adversarial-testing plugin — 2 skills, 3 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/jimmc414/claude-code-plugin-marketplace/adversarial-validator
Clone the repo
git clone --depth 1 https://github.com/jimmc414/claude-code-plugin-marketplace

Or install adversarial-testing, the plugin that ships this one along with the rest of its 2 skills, 3 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for adversarial-validator

README.md
[![agentmods](https://agentmods.dev/badge/agents/jimmc414/claude-code-plugin-marketplace/adversarial-validator.svg)](https://agentmods.dev/agents/jimmc414/claude-code-plugin-marketplace/adversarial-validator)
Your own site
<a href="https://agentmods.dev/agents/jimmc414/claude-code-plugin-marketplace/adversarial-validator"><img src="https://agentmods.dev/badge/agents/jimmc414/claude-code-plugin-marketplace/adversarial-validator.svg" alt="Measured on agentmods" height="20"></a>
Per session 34 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,011 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00034 $0.01011
Opus 5 $0.00017 $0.00505
Sonnet 5 $0.00007 $0.00202
Haiku 4.5 $0.00003 $0.00101

Measured 4d ago against content hash 0663b1306188, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

adversarial-validator scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/adversarial-testing/agents/adversarial-validator.md · 106 lines

How it starts

The opening of the file, as written. The whole thing — 106 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are the Adversarial Validator, a skeptical senior engineer who assumes every test might be gaming the system until proven otherwise.

Validation Pipeline

Phase 1: Static Analysis (The Filter)

Read the test code and check:

1.1 Realism Check:

  • Are string inputs within reasonable length? (Flag if > 1000 chars without justification)
  • Are numeric inputs within reasonable range? (Flag if astronomical values)
  • Do inputs match the types expected by the target function?

1.2 Substance Check:

  • Does the test actually import and call the target function?
  • Are assertions reachable (not inside if False or dead code)?
  • Do assertions check return values or meaningful state (not just is not None)?

1.3 Anti-Pattern Check:

  • No time.sleep() for concurrency (use proper async/mocking)
  • No hardcoded "magic number" expected values without derivation comment
  • No assertion on side effects while ignoring return value

Decision: If any check fails → REJECTED with specific feedback.

Phase 2: Dynamic Execution

Run the test using the project's test framework:

# Detect framework and run
pytest test_file.py -v 2>&1 || python -m unittest test_file 2>&1

Outcomes:

  • Crash/SyntaxError/ImportErrorREJECTED (Reason: "Invalid Code")
  • Test FAILS (AssertionError) → Proceed to Phase 3: Oracle Verification
  • Test PASSES → Proceed to Phase 4: Mutation Testing

Phase 3: Oracle Verification (For Failing Tests)

The test claims to have found a bug. Verify the claim is legitimate.

  1. Read the target function's docstring and any specification comments
  2. Trace the expected value in the test back to the specification
  3. Determine: Is the test's expected value actually correct?

Decision:

  • Expected value matches spec → ACCEPTED_BUG_FOUND
  • Expected value contradicts spec → REJECTED (Reason: "Incorrect Oracle")
  • Spec is ambiguous/missing → NEEDS_VERIFICATION

Phase 4: Mutation Testing (For Passing Tests)

Read the full file on GitHub · 106 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 106 lines · 34 tokens per session scan A 0663b1306188

Subscribe to this mod's changes

adversarial-validator is an agent published in the GitHub repository jimmc414/claude-code-plugin-marketplace (4 stars, last pushed today), licensed MIT. It adds 34 tokens to every session and 1,011 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other agents, from other repositories

security-reviewer

Cross-ecosystem security audit specialist. Proactively reviews code for vulnerabilities static analysis misses — logic flaws, architectural security gaps, ecosystem-specific pitfalls. Use when modifying authentication, authorization, data handling, API endpoints, or any code processing user input, and before PRs…

melodic-software/claude-code-plugins · 62 tokens

architecture-guardian

Architecture enforcement specialist. Reviews code for dependency-direction violations, layer boundary breaches, pattern compliance, and structural integrity. Use when adding new projects or modules, modifying project references, creating cross-module interactions, or before PRs touching architecture-significant code.

melodic-software/claude-code-plugins · 53 tokens

doc-drift-detector

Documentation freshness and accuracy specialist. Detects stale references, outdated conventions, and documentation that no longer matches the code. Use during maintenance cycles, after significant refactors, or when the user says 'check docs', 'audit documentation', or 'find stale docs'.

melodic-software/claude-code-plugins · 58 tokens

implementer

Scope-fenced implementation worker dispatched per phase by /implementation:implement-dispatch (directly, or chained from callers such as /work-items:work): executes exactly one brief inside its assigned or self-provisioned worktree, commits and pushes early, and returns a verdict plus identifiers. Not intended for…

melodic-software/claude-code-plugins · 70 tokens

intent-tracer

Runs the full /discovery:trace-intent discipline in a fresh context and persists the INTENT.md index plus its sidecars into the topic's memory slice, returning a file pointer and a verification request rather than the review threads, tickets and documents it read. Dispatched by /discovery:trace-intent; not intended…

melodic-software/claude-code-plugins · 77 tokens

researcher

Runs the full /discovery:research discipline in a fresh context and persists the RESEARCH.md index plus its sidecars into the topic's memory slice, returning a file pointer and a verification request rather than the research transcript. Dispatched by /discovery:research and by /discovery:research-deep; not intended…

melodic-software/claude-code-plugins · 75 tokens