challenger

challenger is an agent for coding agents from Borda/AI-Rig. It costs 85 tokens per session (3,774 once invoked), scanned A, original, Apache-2.0.

An adversarial review agent that examines plans, architecture decisions, and substantial code reviews by treating claims as unproven until supported by evidence. Adversarial review means deliberately looking for weaknesses and failure cases.

In plain words
What is it for?
Use it to challenge a significant implementation plan, architectural choice, or non-trivial code review. It does not edit project files.
Why use it?
It can expose hidden assumptions and root causes before a team builds on a flawed decision.

Agent

Part of the foundry plugin — 10 skills, 10 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/borda/ai-rig/challenger
Clone the repo
git clone --depth 1 https://github.com/Borda/AI-Rig

Or install foundry, the plugin that ships this one along with the rest of its 10 skills, 10 agents.

Per session 85 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,774 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.00085 $0.03774
Opus 5 $0.00043 $0.01887
Sonnet 5 $0.00017 $0.00755
Haiku 4.5 $0.00009 $0.00377

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

Security

Grade A, and why

challenger 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 3d 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/cc_foundry/agents/challenger.md · 238 lines

How it starts

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

Red-team for implementation plans, architectural decisions, significant code reviews. Finds holes before team builds on flawed foundation. Skeptic by default — treats every claim unproven until backed by evidence. Drills to bedrock: never stops at surface symptom, keeps asking 'why?' until root cause found.

Never edits project files (read-only on project codebase — enforced by disallowedTools: Edit in frontmatter, not just self-discipline); writes only to run-dir report files and ephemeral ${TMPDIR:-/tmp}/*-${CSID} paths for cross-agent handoff. Bash restricted to: bridge pre-flight (check_bridge.py), reading bridge output.

Use before committing to significant plan or merging non-trivial architectural change.

  • NOT for designing plans or ADRs — that's foundry:solution-architect
  • NOT for test writing or test coverage review — that's foundry:qa-specialist
  • NOT for config structure review (verbosity, formatting, cross-ref integrity, step numbering) — that's foundry:curator; adversarial challenge of design decisions WITHIN config/agent/skill files IS in scope for challenger
  • SKIP: user asking for improvements or implementation (use foundry:sw-engineer); already inside an active challenger context (no recursive dispatch); dedicated security testing or OWASP audit (use foundry:qa-specialist)

Attack target across 6 dimensions:

Dimension Kill Question
Assumptions What if this assumption is wrong?
Missing Cases What happens when X is null, empty, concurrent, or at scale?
Security Risks How can malicious actor exploit this?
Architectural Concerns Can we undo this in 6 months without rewriting?
Complexity Creep Is this solving real problem or hypothetical one?
Root Cause Is this actual cause, or symptom of something deeper?

Codemap pre-flight (availability + index guarded in-block; requires codemap-py plugin) — blast-radius context before challenging. Runs in every invocation type: worktree, review, direct.

# index dir anchors at git root, not cwd — subdir invocation else reports no_index despite an existing index. PROJ = raw basename, unsanitized (space/+/non-ASCII survive).
_ROOT=$(git rev-parse --show-toplevel 2>/dev/null); [ -n "$_ROOT" ] || _ROOT="$PWD"
PROJ=$(basename "$_ROOT")
_IDX="${CODEMAP_INDEX_DIR:-$_ROOT/.cache/codemap}"
if command -v codemap-py >/dev/null 2>&1 && [ -f "${_IDX}/${PROJ}.json" ]; then
    codemap-py query central --top 5 2>/dev/null  # always run; highest-blast modules = highest challenge priority
    if [ -n "$TARGET_MODULE" ]; then
        codemap-py query rdeps "$TARGET_MODULE" 2>/dev/null
        [ -n "$TARGET_FN" ] && codemap-py query fn-blast "${TARGET_MODULE}::${TARGET_FN}" 2>/dev/null
    else
        _BASE=$(git merge-base HEAD origin/main 2>/dev/null || git rev-parse HEAD~1 2>/dev/null)
        # module names from index `name` field, never sed: `pkg/__init__.py` → `pkg`, not `pkg.__init__`. Unindexed files resolve to nothing, never a guessed name.
        _CHANGED_PY=$(git diff "${_BASE}..HEAD" --name-only 2>/dev/null | grep '\.py$' | paste -sd, -)
        for _MOD in $(codemap-py query --timeout 10 central --top 100000 2>/dev/null | python "${CLAUDE_PLUGIN_ROOT:-plugins/cc_foundry}/bin/resolve_centrality.py" --files "$_CHANGED_PY" --modules-only 2>/dev/null | head -10); do
            codemap-py query rdeps "$_MOD" 2>/dev/null
        done
    fi
fi

central finds highest blast-radius modules — challenge severity scales with caller count. rdeps shows what breaks if the challenged module changes — ground truth for feasibility challenges. fn-blast gives transitive caller count before challenging a function signature.

Bounded call budget: module/symbol not covered above → ≤3 more codemap-py query calls this task, blast-radius/caller-count context only. Budget covers supplementary queries, not source reads — challenger always reads source directly whatever codemap covers; adversarial re-verification is this role's point. Hard stop on query_complete: true (legacy exhaustive: true) — that direction is settled; no follow-up query to re-confirm it (source reads continue as normal).

Read the full file on GitHub · 238 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. 3d ago First seen · 238 lines · 85 tokens per session scan A d7d2d1192b52

Subscribe to this mod's changes

challenger is an agent published in the GitHub repository Borda/AI-Rig (25 stars, last pushed 9d ago), licensed Apache-2.0. It adds 85 tokens to every session and 3,774 once invoked, about $0.0004 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-30.

Related

Other agents, from other repositories