Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Run an A/B test of the same task at multiple model tiers (Haiku, Sonnet, optionally Opus). Captures outputs, computes structural and semantic diffs, scores quality, writes a markdown comparison report. Use when the user wants to validate "is Haiku good enough for this task class?" or runs /tokenwise:ab "<task description>".
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-04 | ✗→✓ | ▲ Improved | 1% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 30% | 0% |
| case-08 | ✗→✓ | ▲ Improved | -28% | 0% |
| case-09 | ✗→✓ | ▲ Improved | -6% | 0% |
| case-11 | ✗→✓ | ▲ Improved | -22% | 0% |
Run the same task at multiple tiers and compare outputs.
Expected form: <task description> [--tiers haiku,sonnet,opus]
-- flag (or the whole string if no flags)--tiers haiku,sonnet is the default (skip Opus by default — it's the baseline)--tiers haiku,sonnet,opus runs all threeIf $ARGUMENTS is empty, ask the user: > What task should I A/B test? Provide a task description (e.g., "rename getCwd to getCurrentWorkingDirectory across the codebase").
A/B test will run this task <N> times (once per tier). Estimated cost: $<rough estimate based on task size>. Proceed? [Y/n] Estimate by treating the task as ~10k input + ~1k output per tier and summing.
Task(description: <task>, subagent_type: "general-purpose", model: <tier>, prompt: <task>)model: param is silently overridden (Anthropic Issue #47488), warn user and abort with:> Cannot A/B test on this Claude Code build — subagent model routing is not honored. See /tokenwise:install probe results.
> Compare these N outputs for the task "<task>". Score each from 1-10 on (a) completeness, (b) correctness, (c) clarity. Return a JSON object: {"<tier>": {"completeness": N, "correctness": N, "clarity": N, "overall": N, "notes": "..."}}. Be honest — if two outputs are equivalent, give them the same score.
/tokenwise:report:./tokenwise-ab-<YYYYMMDD-HHMMSS>.md:markdown# A/B Test — <first 80 chars of task> Run: <ISO 8601 timestamp> Task: "<full task>" Tiers tested: <list> ## Tier comparison | Tier | Tokens (in/out) | Cost | Duration | Quality | |--------|------------------|----------|----------|---------| | Haiku | <in> / <out> | $<cost> | <ms> | <q>/10 | | Sonnet | ... | ... | ... | ... | ## Semantic scores (table with completeness/correctness/clarity per tier, plus notes from the judge) ## Recommendation (One paragraph: which tier is sufficient for this task class, what override rule to add to CLAUDE.md if any.) ## Output diffs (For each tier, include the full output verbatim, or a truncated version with full output in a fenced block.)
.tokenwise/log.ndjson with task_class: "ab-test" so it doesn't pollute regular routing stats. A/B test complete. Report: tokenwise-ab-<ts>.md Recommendation: <one-sentence recommendation>
Task (for spawning per-tier runs and the semantic judge), Read, Write, Bash.
Other measured skills in the registry, with their headline benchmark lift.