/project-toolkit:benchmark-modelsfrom project-toolkit
Runs the same prompt through Claude, GPT (Codex CLI), and Gemini side by side, comparing latency, tokens, cost, tool calls, and optional quality via an Anthropic-API judge. Reports per-metric leaders.
Ships in project-toolkit. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Run the same prompt across providers and compare them on data, not vibes. The
deterministic work lives in scripts/model_benchmark.py (stdlib-only, ported
from gstack's bun benchmark; no SDKs, no gstack runtime). This skill is the
interactive wrapper: pick a prompt, preview auth with a dry-run, confirm
providers, run, interpret, optionally save.
Providers wrap existing CLIs and their own auth (no API keys needed except the optional judge):
claude via claude -p --output-format jsongpt via codex exec ... -s read-only --jsongemini via gemini -p ... --output-format stream-jsonInvoke this skill when the user says any of:
benchmark modelscompare modelsmodel shootoutwhich model is bestcross-model comparisonA request for the best model gets per-metric leaders and a rerun plan, not a winner (Step 4).
Do NOT invoke for web page performance (that is a different concern).
ANTHROPIC_API_KEY (adds ~$0.05/run).Asking the user. "Ask the user" means the host's structured ask tool, at most 3 questions per call: Claude Code AskUserQuestion; Muse Code request_user_input; Codex request_user_input in Plan mode only, never in codex exec or a subagent. With no such tool, ask one plain question in chat.
Resolve the driver first. In a repository checkout, use BENCH="$(git rev-parse --show-toplevel)/.claude/skills/benchmark-models/scripts/model_benchmark.py". From an installed skill copy, use the local skill path: BENCH="$PWD/scripts/model_benchmark.py" when your shell is in the benchmark-models skill directory.
Ask the user to decide the prompt:
A) Benchmark a skill: pass that skill's SKILL.md path as the prompt. To list
candidates, search the installed skills dir, not just . (skills usually live
under ~/.claude/skills/ or ~/.copilot/skills/, not the project root).
Allowed-root constraint: $BENCH reads a prompt file only when it
resolves under the repo checkout, the current directory, or a path listed in
MODEL_BENCHMARK_SKILL_ROOTS (see resolve_prompt and _allowed_prompt_roots
in the benchmark script). A SKILL.md under ~/.claude/skills/ or
~/.copilot/skills/ is outside the repo and cwd, so the run aborts with exit
code 2 ("prompt file must be under an allowed root") and benchmarks nothing.
Before running, export the skills dir, for example
export MODEL_BENCHMARK_SKILL_ROOTS=~/.claude/skills (or ~/.copilot/skills),
or copy the file into and run from an allowed root. A prompt already inside the
repo or cwd needs no env var.
B) Inline prompt: pass --prompt "<text>".
C) A prompt file on disk: pass its path (verify it exists first).
Then preview availability without spending anything:
python3 "$BENCH" --prompt "dry-run" --models claude,gpt,gemini --dry-run
The "Adapter availability" block shows OK or NOT READY (with a remediation hint)
per provider. If ALL are NOT READY, STOP: nothing can run. Suggest claude,
codex login, or gemini login / export GOOGLE_API_KEY.
From the dry-run, ask the user which providers to include (default: all authed). Unauthed providers are skipped cleanly and never abort the batch.
If ANTHROPIC_API_KEY is set, ask the user whether to enable --judge
(quality scoring, ~$0.05). Never auto-enable it; it costs real money. If the key
is absent, omit --judge.
model_benchmark.py enforces the throwaway workdir itself: when --workdir is
omitted it defaults to a fresh tempfile.mkdtemp(), removed automatically when
the run ends, and it refuses (exit 2) a --workdir that resolves inside the
repo checkout (root or any subdirectory) or equals the current directory,
unless --allow-cwd-workdir is also passed, and it refuses (exit 2) a
--workdir that is not an existing directory. A caller-supplied --workdir is
never removed. This matters because both the Claude and
Gemini adapters can write to the workdir: Gemini runs with --yolo
(unsandboxed), and Claude carries no read-only flag. Only the GPT/Codex adapter
is constrained (-s read-only). Pass --workdir explicitly only when you want
a workdir you can inspect afterward:
WORKDIR="$(mktemp -d)"
python3 "$BENCH" <prompt-spec> --models <picked> [--judge] --output table --workdir "$WORKDIR"
<prompt-spec> is --prompt "<text>" (B) or a file path (A/C). Stream the
output; each provider runs the full prompt, so expect 30s-5min.
For an installed-skill path (A) under ~/.claude/skills/ or ~/.copilot/skills/
(outside the repo and cwd), export MODEL_BENCHMARK_SKILL_ROOTS first (see Step 1
Option A) or the run aborts with exit code 2 before any provider starts.
Summarize the per-metric leaders: fastest (latency), cheapest (cost), highest quality (if judged). One run per provider is inconclusive, not a preference: report n and an interval or margin (or say none can be estimated at n=1), call no winner from a directional delta, and rerun to confirm. Call out any provider that errored, with its remediation path. Offer to save a JSON baseline so future runs can be diffed for regressions:
python3 "$BENCH" <prompt-spec> --models <picked> [--judge] --output json > benchmark-$(date +%Y%m%d)-<slug>.json
Runs the benchmark. Pure stdlib; safe to run directly.
python3 scripts/model_benchmark.py <prompt-file | --prompt "text"> \
[--models claude,gpt,gemini] [--judge] [--dry-run] \
[--output table|json|markdown] [--workdir PATH] [--allow-cwd-workdir] \
[--timeout-ms N] [--skip-unavailable]
Exit codes (ADR-035): 0 success, 1 logic/runtime error, 2 config or usage
error, 3 external dependency failure, 4 authentication or authorization
failure.
Notes:
--dry-run resolves auth and prints availability without sending any prompt.http.client (no SDK)
and fails soft: a judge error warns and leaves quality blank, it never aborts
the run.gpt and gemini CLIs receive the prompt
through command arguments, which some systems expose through process listings
or crash reports.gpt/codex adapter runs -s read-only; the gemini
adapter passes --yolo (auto-approve), which is NOT sandboxed. The driver
refuses a --workdir inside the repo checkout or equal to cwd (exit 2)
unless --allow-cwd-workdir is passed, so a disposable, auto-cleaned
workdir is the default.PRICING table at the top of the script. An unpriced
model costs 0.0 with a stderr warning; add a row rather than guess.| Avoid | Why | Instead |
|---|---|---|
| Running the benchmark before the dry-run | Spends API calls on unauthed providers that will just error | Always Step 1 dry-run first; only run authed providers |
Auto-enabling --judge | It adds real per-run cost the user did not approve | Opt-in only, after the Step 2 question |
| Benchmarking in a live repo with a write-prone prompt | The gemini adapter is not sandboxed (--yolo) | Use a disposable --workdir |
| Guessing a price for an unlisted model | Produces a wrong cost number that looks authoritative | Add a row to the PRICING table; unlisted stays 0.0 with a warning |
Listing skills to benchmark via find . only | Installed skills live under ~/.claude / ~/.copilot, not the project root | Search the installed skills dir |
The skill run is complete when:
SKILL.md outside the repo/cwd,
MODEL_BENCHMARK_SKILL_ROOTS was set (or the file staged under an allowed
root) so the run did not abort with exit code 2.--judge was included only after explicit user opt-in.uv run pytest tests/skills/benchmark-models/ -q
passes (the driver carries unit tests at 100% coverage).What SKILL.md sets; muted values are Claude Code's defaults
105 skills in this plugin
/adr-generatorCreate comprehensive Architectural Decision Records (ADRs). Researches the destination directory to detect existing template conventions, gathers context, determines next ADR number, generates the ADR, validates completeness, and saves. Supports multiple ADR formats (MADR, Nygard, Alexandrian, project canonical). Use when documenting technical decisions, creating new ADR files, or capturing rationale so future readers can revisit a choice. Use when you say "write an ADR", "document this decision", "document these design choices", "record why we chose this", "capture the rationale", or "for future maintainers", or when creating an ADR-like markdown file under docs/decisions/, docs/adr/, docs/architecture/, architecture/decisions/, or .project-toolkit/architecture/. Do NOT use to debate or review an existing ADR (use adr-review)./adr-reviewMulti-agent debate orchestration for Architecture Decision Records. Automatically triggers on ADR create/edit/delete. Coordinates architect, critic, independent-thinker, security, analyst, and high-level-advisor agents in structured debate rounds until consensus. Use when you say "review this ADR", when an ADR is created/edited/deleted, or when reviewing, accepting, or updating a decision file under .project-toolkit/architecture/, docs/architecture/, docs/decisions/, docs/adr/, or architecture/decisions/, including intent like "review this decision record" or "check this rationale for future maintainers". Do NOT use to author a new ADR (use adr-generator)./agent-harness-referenceField reference for Claude Code and GitHub Copilot CLI hook contracts. Covers hook locations, events, matchers, payloads, decisions, exit codes, timeouts, plugin roots, and cloud limits with official URLs and versioned probes. Use for `harness contract`, `copilot cli hook behavior`, `hook payload format`, `stale plugin root`, `Errno 2 _dispatch.py`, or before changing cross-harness hooks. Do NOT use to run the porting campaign (in the ai-agents repository, use `ai-agents-portability-campaign`)./ai-agents-external-claimsVerify external, vendor, and third-party claims (numbers, attributions, structure) against authoritative primary sources before they land in a repo artifact or external deliverable. Covers stake-holding sources, round-number tells, citation-chain drift, and the walk-the-gate-or-file-conservative discipline. Use when you say `verify an external claim`, `check a vendor number`, `is this stat real`, `validate a third-party citation`. Do NOT use for running an experiment (use `ai-agents-research-methodology` in the ai-agents repository) or command-injection scanning (use `security-scan`)./analysis-provenanceIdentify code ownership before modifying validators or linters. Checks file headers for provenance indicators, reviews documentation, and determines provenance as UPSTREAM, LOCAL, VENDOR, or UNKNOWN. Prevents accidental modification of upstream tools./analyzeSystematic multi-step codebase analysis producing prioritized findings with file-line evidence. Covers architecture reviews, security assessments, and code quality evaluations through guided exploration, investigation planning, and synthesis. Use when you say "analyze this codebase", "run security assessment", "architecture review of this system", "find code smells", or "review code quality" across multiple files. Do NOT use for single-file maintainability scoring (use code-qualities-assessment) or CWE-78 injection pattern scanning (use security-scan).2 plugins in one repository ship this exact skill · first indexed Nov 13, 2026
npx claudepluginhub rjmurillo/ai-agents --plugin project-toolkitOther plugins' skills for the same job