metis: Command for Claude Code

.claude/commands/redteam.md

redteam is a command for Claude Code from terrene-foundation/metis. It costs 19 tokens per session (1,840 once invoked), scanned A, original, Apache-2.0.

A workspace validation command that tests whether an implemented project matches its documented requirements. Red-team testing means deliberately looking for failures and gaps before release.

In plain words
What is it for?
Use it to audit a project, check user flows, record findings, and repeatedly fix issues until the validation gaps are closed.
Why use it?
It helps uncover missing behavior, unfinished work, and differences between the specification and the actual code.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

This is terrene-foundation/metis's own configuration. It tells Claude Code how to work on metis itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything metis configures →

Reuse

Borrowing it

Nothing to install: this file belongs to terrene-foundation/metis. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/terrene-foundation/metis/main/.claude/commands/redteam.md
Clone the repo
git clone --depth 1 https://github.com/terrene-foundation/metis

Made for: Claude Code.

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 redteam

README.md
[![agentmods](https://agentmods.dev/badge/commands/terrene-foundation/metis/redteam.svg)](https://agentmods.dev/commands/terrene-foundation/metis/redteam)
Your own site
<a href="https://agentmods.dev/commands/terrene-foundation/metis/redteam"><img src="https://agentmods.dev/badge/commands/terrene-foundation/metis/redteam.svg" alt="Measured on agentmods" height="20"></a>
Per session 19 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,840 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00019 $0.01840
Opus 5 $0.00010 $0.00920
Sonnet 5 $0.00004 $0.00368
Haiku 4.5 $0.00002 $0.00184

Measured 6d ago against content hash b2cd05c268cd, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

redteam 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 6d 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.

.claude/commands/redteam.md · 137 lines

How it starts

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

Workspace Resolution

  1. If $ARGUMENTS specifies a project name, use workspaces/$ARGUMENTS/
  2. Otherwise, use the most recently modified directory under workspaces/ (excluding instructions/)
  3. If no workspace exists, ask the user to create one first
  4. Read all files in workspaces/<project>/briefs/ for user context

Phase Check

  • Verify todos/active/ is empty (all implemented) or note remaining items
  • Read workspaces/<project>/03-user-flows/ for validation criteria
  • Validation results go into workspaces/<project>/04-validate/
  • If gaps are found, document them and feed back to implementation (use /implement to fix)

Execution Model

Autonomous execution model (see rules/autonomous-execution.md). Red team converges through iterative rounds. Findings are fixed autonomously, not reported for human triage.

Workflow

1. Spec compliance audit (MUST run first)

File existence is NOT compliance. Use the protocol in skills/spec-compliance/SKILL.md to verify each spec promise via AST parsing and targeted greps, NOT file existence or self-reports.

A "spec" is any documented promise about behavior, regardless of where it lives. Sources to audit:

  • specs/** — domain specifications (PRIMARY source of truth)
  • workspaces/<project>/briefs/** — user-supplied requirements
  • workspaces/<project>/01-analysis/** — analyst findings, deep analyses, design notes
  • workspaces/<project>/02-plans/** — implementation plans, ADRs, contracts
  • workspaces/<project>/todos/completed/** — what each todo claimed to deliver
  • Inline spec sections in README.md, CHANGELOG.md, or design docs the project references

For every spec promise found in these sources:

  1. Extract literal acceptance assertions from the spec text (class signatures, field names, decorator call sites, MOVE shim semantics, security tests, migration completion).
  2. Verify each assertion via grep or ast.parse against the actual code.
  3. Re-derive every check from scratch — do NOT trust .spec-coverage, .test-results, convergence-verify.py, or any prior round's self-report. Self-reports are inputs to verify, not evidence to trust.
  4. Save the assertion table to workspaces/<project>/.spec-coverage-v2.md (the -v2 suffix prevents confusion with legacy file-existence reports).

Read the full file on GitHub · 137 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. 6d ago First seen · 137 lines · 19 tokens per session scan A b2cd05c268cd

Subscribe to this mod's changes

redteam is a command published in the GitHub repository terrene-foundation/metis (2 stars, last pushed 4mo ago), licensed Apache-2.0. It adds 19 tokens to every session and 1,840 once invoked, about $0.0001 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.