Benchmark report

Measured,not claimed.

Every number here comes from real runs of the CLI against real git repositories: 86 labeled scenarios, 800 randomized trials checked against an independent oracle, concurrency and stability tests, token counts, and secret-scanner tests on 1,737,973 lines of real code.

v0.3.3commit 30c2b62 + working treeApple M3Python 3.14.6git version 2.51.02026-10-12
0/86labeled drift scenarios behave as expected
99.9%agreement with an independent oracle over 800 random sequences of git and file operations
0 tokensmedian cost of resume --check; the full resume prompt is 469
0msto check a repo with 10,000 files and 500 uncommitted changes
01 · Gate accuracy

Does the gate say theright thing?

86 scenarios, each applying one change after a checkpoint and comparing the verdict with the expected one. I wrote the expectations before running, so this shows the tool behaves as designed, and where it cannot know better.

Scenarios by family

file change21/21
history20/20
state8/8
no-op5/5
privacy / ignore5/5
evidence4/4
notes safety4/4
net-zero3/3
control2/2
portability2/2
graph2/2
assumption2/2
privacy2/2
blind spot (should warn)1/2
scale2/2
blind spot1/1
sessions1/1

Misses (1)

ScenarioExpectedGot
remote_ahead_unfetched
teammate pushed to origin; local clone has not fetched
REVIEW_REQUIREDREADY

An unfetched remote is invisible by design (no network). Everything else, including rewrites, branch moves, merges, nested repos, privacy exclusions and corrupted state, behaves as labeled.

02 · Randomized testing

800 randomhistories, one oracle.

Each trial applies 1 to 5 random operations (edit, add, delete, commit, branch, amend, reset, stash, rename, ignored files…). An independent oracle, built from plain git plumbing and content hashes, decides what the verdict should be. Seeds 20261012 and 777, so it is reproducible. The second seed never edits the tool's own notes (see below).

Oracle vs tool

tool: READY
tool: REVIEW_REQUIRED
tool: BLOCKED
oracle: READY
147
0
0
oracle: REVIEW_REQUIRED
0
372
1
oracle: BLOCKED
0
0
280

Result

799 / 800

1 disagreement; 0 unexplained. Mean 3.0 operations per trial.

seed 20261012: 399 / 400 agree.

seed 777: 400 / 400 agree (notes excluded from edit targets).

seed 20261012, trial 169: ops commit → env → edit → delete; oracle REVIEW_REQUIRED, tool BLOCKED. contextbridge/graph.json is not valid JSON (Extra data: line 47 column 1 (char 835)); fix or delete it The random 'edit' step appended text to a notes file under contextbridge/ that an earlier `git add -A` had committed. The tool correctly returned BLOCKED (corrupt notes); the oracle only checks that state.json exists. Harness artifact, not a tool bug. Later seeds exclude the notes from edit targets.

03 · Tokens

What it costs anagent to read.

Counted with real tokenizers (cl100k and o200k via tiktoken) over the actual output of the CLI. Claude's own tokenizer is not available offline, so treat these as close proxies, not exact Claude counts.

Tokens a fresh agent must read

ContextBridge (this tool)1,800 git dump
391 full resume
30 gate only
Orvantia website5,922 git dump
380 full resume
30 gate only
Orvantia OS6,569 git dump
378 full resume
30 gate only
ContextBridge site513 git dump
381 full resume
30 gate only

Grey is a typical orientation dump: git status + git log -20 --stat + a diff stat. It is not equivalent information (it has no evidence, decisions or verdict); it shows the size of the cheapest alternative.

Handoff size stays flat as projects grow

1001k10k100k10501002505001000WORK ITEMS RECORDED (LOG)
raw state.jsonfull resumeresume --check

Across all 46 scenarios (cl100k tokens)

OutputMedianp90MaxMin
resume --check6511426230
resume (gate + handoff)468.553758451

The maximum is the scenario with 1,000 new files. The gate collapses repeated findings into a count, so even that output stays small.

04 · Speed

Fast enough to runbefore every turn.

resume --check latency (median of 5)

200 files · 0 uncommitted77 ms
2,000 files · 0 uncommitted78 ms
2,000 files · 500 uncommitted91 ms
10,000 files · 0 uncommitted95 ms
10,000 files · 500 uncommitted143 ms

Each call is a fresh Python process; about 40 ms of that is interpreter startup. Cost scales with uncommitted files (hashing), not repo size.

Other timings

save
265 ms at 10,000 files, 500 uncommitted
run overhead
192 ms on top of the command
export / import
84 ms / 98 ms with 500 work items (88,474 bytes)
scanner
about 3.9 MB/s
CLI startup
37 ms installed from the wheel
05 · Secret scanner

What it catches,and what it misses.

1,000 synthetic fake secrets per format (31 formats with dedicated patterns), then 5 formats with none, then how often it fires on real code.

Detected and redacted: 31 formats

aws access key 100%aws temp key 100%github pat classic 100%github oauth 100%github fine grained 100%slack bot 100%google api 100%openai sk 100%anthropic sk 100%stripe live 100%stripe test 100%stripe restricted 100%sendgrid 100%npm 100%twilio 100%jwt 100%pem rsa 100%pem openssh 100%gitlab pat 100%huggingface 100%pypi token 100%digitalocean 100%shopify 100%mailchimp 100%telegram bot 100%azure account key 100%db url password 100%mongodb srv 100%password assign 100%api key json 100%token env 99%

Redaction removed the secret and left nothing re-detectable in 100% of detections.

Deliberately not detected: 5 formats

high entropy hex 32 0%high entropy base64 44 0%gcp service account private key id 0%short password 7 0%heroku api key uuid 0%

Random hex and base64 strings, UUID-style keys and short passwords are not flagged; doing so would flag hashes and IDs. The scanner is best-effort, and the README says so.

Hits on real code

python stdlib all10 / 979,577 lines
node modules js sample11 / 758,396 lines
package lock files0 / 47,714 lines
markdown docs1 / 2,105 lines

Lines flagged per million lines scanned. What remains is mostly test fixtures with literal passwords, such as passwd = 'my1pa$$word!', and very long minified lines. Lockfiles produced 0 hits.

06 · Reliability

Stable, portable,and lossless.

Test-suite stability

15 / 15 runs

36 tests per run, median 12.0 s. No flaky failures.

Python versions (macOS)

Python 3.11.133/3 runs passed, 36 tests
Python 3.14.63/3 runs passed, 36 tests

Packaging

wheel
25,002 bytes, tests excluded: true
sdist
35,062 bytes
install
py3.11.13 ok (1.0s, 0.3.3) · py3.14.6 ok (0.9s, 0.3.3)
dependencies
0

Concurrent writers

2 writers20 executed
20 recorded
4 writers40 executed
40 recorded
8 writers40 executed
40 recorded

Several processes run run in the same repository at once. Writers take an exclusive lock around reading and writing the notes, so every executed run is recorded with a unique id and the files stay valid JSON.

07 · Method and limits

Read this beforeyou trust it.

What this does not prove

  • It does not measure whether an AI agent finishes tasks better with ContextBridge. That needs many paid agent runs against a baseline.
  • I wrote the scenario expectations, so they reflect my idea of correct. The fuzz oracle is independent code, but also mine.
  • Token counts use OpenAI-style tokenizers as a proxy for Claude's.
  • One machine (Apple M3, macOS). Linux and Windows are covered by CI for functionality, not benchmarked here.
  • No other tool was installed or compared.

Reproduce

git clone https://github.com/Abhinay2206/ContextBridge
cd ContextBridge-Benchmark
python3 bench.py    # speed, labeled scenarios, scanner
python3 bench2.py   # fuzz, tokens, concurrency, matrix
python3 merge.py && python3 charts.py

The harness lives in the ContextBridge-Benchmark folder next to the repo; it is not part of the shipped package.