Independent reproducible benchmark on local backends (Ollama + LM Studio): ~51% avg, per-content-type breakdown, and one edge case #1371
Replies: 2 comments
-
|
Hey @gamerhateyou — how's your experience scaling Claude Code with headroom? Do things start lagging and forcing you into annoying loop-and-reprompt cycles as the code grows, or is it keeping up? |
Beta Was this translation helpful? Give feedback.
-
|
Thanks Amar — happy to dig in, but I'd steer this back to the thread, since the benchmark and your question are two different paths. What I measured (#1371) was Headroom as a compression proxy in front of two simple OpenAI-compatible clients — Ollama ( What the numbers do say, across 5 reproducible needle-in-a-haystack scenarios (fixed seed):
The one bit relevant to your Claude-Code question: that dropped detail isn't gone — the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
First off — really nice engineering. The thing I appreciate most is how conservative the defaults are: it compresses hard where it safely can (repetitive logs) and leaves code and prose essentially untouched. That honesty in the defaults is rarer than it should be.
I wanted numbers on my own workload rather than from a homepage, so I built a small reproducible harness and ran Headroom 0.27.0 as a proxy in front of two local backends:
qwen2.5:14b(WSL)qwen3-14b(Windows)Method: a fixed-seed dataset of 5 "needle in a haystack" scenarios — each a noisy tool output with one verifiable fact buried inside. For each scenario I measured (a) tokens saved and (b) whether the model still finds the needle on the compressed context vs the full one. Compression is identical across backends (it happens before the model; tokens counted with tiktoken), so the savings below are backend-independent.
Savings + needle survival
docker ps, 12 containers)Latency (Ollama
qwen2.5:14b, warm model, cache invalidated each run, median of 3):On local models the prefill saving is honestly the most tangible win — and compressed logs that used to overflow Ollama's default context window now fit comfortably.
The one edge case. The 200-line log compressed to ~5 kept lines. It correctly kept the
ERRORline (right timestamp + endpoint) but dropped the indented stack-trace lines right under it — which is exactly where the cause was (psycopg2.OperationalError: connection pool exhausted). With full context the model named that cause; with the compressed one it honestly said the cause wasn't in the trace anymore. Identical on both backends, so it's information loss, not the model.To be fair to the design: the compressed log ends with
Retrieve more: hash=e42faf1f...— the CCR pointer. So it's not lost, it's recoverable: an MCP client (e.g. Claude Code) can call the retrieval tool and expand it. A plain client (raw Ollama / generic OpenAI app) can't. Might be worth making that asymmetry louder in the docs — aggressive log compression is great for triage, but for deep diagnosis the client needs to be able to re-expand.Two notes for anyone benchmarking on local models:
OLLAMA_CONTEXT_LENGTH=16384fixed it.--no-ccr-inject-toolon the proxy, otherwise the injected retrieval tool trips them up.Full write-up with the harness details and raw outputs (Italian, but the numbers/tables stand on their own): https://homelabz.cc/blog/headroom-guida-pratica-installazione-test-reali
(Separately filed the
[all]/hnswlib install rollback as #1368.)Happy to share the harness if it's useful to anyone.
Beta Was this translation helpful? Give feedback.
All reactions