37 GB
4,042,753 files
Updated about 1 month ago
Name
Size
captured
README.md9.03 kB
xet
pilot-intent-results.md1.82 kB
xet
pilot-intent-run.csv1.07 kB
xet
run-sheet.csv515 Bytes
xet
sonnet-v2-report.md3.72 kB
xet
tasks.json4.43 kB
xet
tool-filter-v1-1-results.json6.97 kB
xet
tool-filter-v1-1-results.md726 Bytes
xet
v2-fixture-results-sonnet.json28.3 kB
xet
v2-fixture-results-sonnet.md3.07 kB
xet
v2-fixture-results.json11.8 kB
xet
v2-fixture-results.md3.2 kB
xet
README.md

Governor vs Caveman Performance Benchmark

Use this when you want measured evidence instead of plugin marketing claims. The goal is to compare quota burn, context growth, and effective task quality for the same tasks under the same conditions.

For the current publishable Sonnet snapshot, start with:

  • benchmarks/sonnet-v2-report.md

Governor should not be judged by token savings alone. Throwing context away is easy; preserving useful model behavior while removing avoidable waste is the hard part.

V2 Principle

Governor wins only if it removes more junk than Caveman while losing less valid context.

Primary metrics:

  • VCLR: lost_required_items / total_required_items
  • decision_preserved: did the model still choose the correct next action?
  • wrong_decision: did compaction cause a wrong diagnosis, scope drift, or retry loop?
  • token_savings: useful, but secondary

Fixture Benchmarks

Before you run full session comparisons, run the V2 fixture benchmark:

python3 scripts/run_benchmark.py

The fixture suite lives in benchmarks/fixtures/.

Starter categories:

  • noisy test/build logs
  • structured/MCP payloads
  • memory/rules files
  • multi-turn intent retention
  • safety no-compress cases

Each fixture defines:

  • raw input or a live tool-event recipe
  • required items that must survive compaction
  • a decision prompt
  • signals for correct vs wrong next action
  • one or more candidate conditions (caveman, governor)

Deterministic VCLR scoring works without model access.

Optional Claude CLI decision evaluation:

python3 scripts/run_benchmark.py --decision-backend claude --model sonnet

If local Claude CLI auth is unavailable, the runner records that rather than crashing.

Refresh Caveman replay files when Claude CLI auth is available:

python3 scripts/capture_fixture_conditions.py \
  --condition caveman \
  --model sonnet \
  --write-summary benchmarks/captured/caveman/latest-summary.json

Refresh reference-style Governor replay files too:

python3 scripts/capture_fixture_conditions.py \
  --condition governor \
  --model sonnet \
  --write-summary benchmarks/captured/governor/latest-summary.json

Conditions

Run each task under these conditions:

  1. control: no Caveman, no Governor.
  2. caveman: captured Caveman comparator output from the same raw fixture input when available; otherwise inline fallback text for framework work only.
  3. governor: live local hook output when the fixture exercises tool filtering, or captured replay output for reference-style benchmark cases when available.

This separation matters. Caveman should mostly win on assistant output brevity. Governor should win when context hygiene, tool-output filtering, planning, and retry reduction matter.

Required Controls

  • Use the same machine, repo commit, Claude Code version, model, and plan tier.
  • Use a fresh Claude Code session for each run.
  • Run /clear or start a new session between conditions.
  • Use the exact prompt text from tasks.json.
  • Do not let one condition see fixes or notes generated by another condition.
  • Run each task at least three times per condition if you want publishable numbers.

What To Record

Fill one row in run-sheet.csv for every task/run/condition.

Required columns:

  • task_id
  • condition
  • run
  • model
  • repo_commit
  • start_context_pct
  • peak_context_pct
  • end_context_pct
  • start_5h_pct
  • end_5h_pct
  • assistant_output_tokens_est
  • failed_tool_calls
  • retry_loops
  • compactions
  • wall_minutes
  • task_success
  • quality_score_0_10
  • requirements_met
  • requirements_total
  • required_items_lost
  • required_items_total
  • vclr
  • decision_preserved
  • wrong_decision
  • critical_errors
  • unplanned_files_changed
  • human_interventions

Governor-specific columns:

  • tool_output_tokens_blocked_est: from /governor:status.
  • memory_original_tokens: from /governor:compress result.
  • memory_compressed_tokens: from /governor:compress result.

Optional columns:

  • start_7d_pct
  • end_7d_pct
  • notes

VCLR Rubric

Use required_items_lost, required_items_total, and vclr to score valid context loss directly.

Examples of required items:

  • failing test name
  • endpoint or path
  • exact warning or irreversible rule
  • feature flag
  • test command
  • contract constraint

Lower vclr is better.

If Governor saves tokens but loses more required items than Caveman, that is a loss even if the output is smaller.

Quality Rubric

Score each completed run after reviewing the final result, diff, and command history.

Field Meaning
task_success success, partial, or failed
quality_score_0_10 Human/evaluator score where 10 means complete, correct, and efficient
requirements_met / requirements_total Count acceptance criteria actually satisfied
critical_errors Unsafe, misleading, destructive, or clearly wrong actions
unplanned_files_changed Files edited outside the task scope
human_interventions Times the human had to redirect, clarify, or repair the run
retry_loops Repeated failed attempts at the same issue

Suggested scoring:

  • 10: fully succeeds, preserves requirements, avoids avoidable broad scans.
  • 8: succeeds with minor omissions or small inefficiencies.
  • 6: partially succeeds but misses one important requirement or needs repair.
  • 4: weak partial result with multiple missed requirements or noisy retries.
  • 2: mostly fails while appearing confident.
  • 0: unsafe, destructive, or unusable result.

Quality gate:

  • A condition is better only if context/usage drops while task success, requirement coverage, and quality score stay equal or improve within normal run variance.
  • If Governor saves tokens but lowers quality, count that as a regression.
  • For coding tasks, run a functional smoke check whenever possible. Syntax-only checks are not enough when the change touches selectors, event handlers, browser behavior, routing, data flow, or persistence.
  • Do not accept self-reported "all checks pass" claims without matching command output, browser evidence, or an independent evaluator check.

Intent-Retention Checks

Use multi-turn tasks to test whether a condition preserves intent after the session gets longer or later prompts push in a conflicting direction.

Recommended sequence:

  1. Ask for an implementation contract with explicit non-negotiables.
  2. Approve a small implementation.
  3. Add a conflicting stakeholder request, such as turning an internal dashboard into a marketing-style product page.
  4. Ask for a final contract check and corrective edit.

Score intent retention separately from token savings:

  • Did the agent keep the original product/user intent?
  • Did it reject or narrow conflicting requests?
  • Did it preserve scoped files and required workflows?
  • Did the final check catch real drift instead of merely claiming success?
  • Did independent smoke checks confirm the implementation still works?

How To Run

For each task in tasks.json:

  1. Reset to the same repo commit.
  2. Start a clean session.
  3. Record starting context and usage percentages from Claude Code statusline or usage UI.
  4. Paste the exact task prompt.
  5. Let the agent complete or stop when it clearly fails.
  6. Record peak/end context, five-hour usage delta, failures, compactions, wall time, whether acceptance criteria passed, quality score, critical errors, and human interventions.
  7. For Governor runs, run /governor:status and copy blocked-token totals.

Then summarize:

python3 scripts/compare_benchmarks.py benchmarks/run-sheet.csv

Interpreting Results

Use these as primary metrics:

  • vclr: valid context loss. Lower is better.
  • decision_preserved: must stay equal or improve.
  • wrong_decision: lower is better.
  • five_hour_delta_pct: real Max-plan burn. Lower is better.
  • peak_context_pct: risk of compaction and 1M-context bloat. Lower is better.
  • assistant_output_tokens_est: where Caveman should be strongest.
  • tool_output_tokens_blocked_est: Governor-specific tool-noise savings.
  • failed_tool_calls: retry-loop waste. Lower is better.
  • retry_loops: repeated attempts at the same failed fix. Lower is better.
  • compactions: fewer means longer useful sessions.
  • task_success, quality_score_0_10, and requirement coverage: must stay equal or improve. Smaller answers are not a win if task quality falls.

Recommended reading:

  • benchmarks/fixtures/README.md
  • benchmarks/fixtures/schema.json

Report Governor honestly:

  • Memory compression savings are recurring context savings.
  • Tool filtering savings apply only when commands produce noisy output.
  • Prompt caching can reduce usage/cost but does not necessarily reduce context window occupancy.
  • Planning/drift guard savings are task-dependent and should be measured as fewer failed loops, fewer broad scans, and fewer unplanned edits.
Total size
37 GB
Files
4,042,753
Last updated
Oct 24
Pre-warmed CDN
US EU US EU

Contributors