headroom
AGENTS.md79k starsChanged 2 months agoApache-2.0View on GitHub
The PyPI package is headroom-ai; the import and the CLI are headroom. In-process, no API key, no model download. HEADROOM_OFFLINE=1 makes the run zero-network (no update check, no model or pricing-table downloads, no beacon). Verify without a provider key:
- Installs packages
1 other project uses a version of this.
Trending
Less talk lately.about the whole repository
Most recently taken up by
- headroomlabs-ai/headroomword for word, first seen Nov 8, 2026
Who's talking about chopratejas/headroom
- Better Stack“Headroom: The Netflix Tool That Makes AI Agents 10x Cheaper”YouTube · Jun 8, 2026 · 107k views
- The Linux Foundation“Headroom: A Context Optimization Layer for LLM Applications - Tejas Chopra, Netflix, Inc.”YouTube · Jun 3, 2026 · 41k views
- DIY Smart Code“I Tested Headroom: 96% Log Compression?”YouTube · Jun 14, 2026 · 12k views
- Income stream surfers“Someone just open-sourced tokenminimizing (8500 stars on GitHub)”YouTube · Jun 3, 2026 · 8.8k views
- The Contextian“Headroom: Cut AI agent token bloat by 95%”YouTube · Jun 14, 2026 · 4.3k views
The biggest 5 of 106 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 106
Talked about on GitHub, YouTube, Bluesky, Hacker News and the web (106 times).
On GitHub · 50
- Jun 5, 2026feat(compression): integrate headroom-ai for tool output compression — NousResearch/hermes-agent17 reactions · 11 comments
- Jun 9, 2026[Feature Request] 支持出站上游代理(Upstream Proxy),允许在 CC-Switch 和供应商之间插入中间层(如 Headroom 压缩代理) — farion1231/cc-switch12 reactions · 12 comments
- Jun 18, 2026Feature Request: Integrate Headroom compression layer (60-95% token reduction) — decolua/9router9 reactions · 2 comments
- Jun 7, 2026fix(codex): respect HERMES_CODEX_BASE_URL in all paths — NousResearch/hermes-agent3 reactions · 5 comments
- Jun 6, 2026[Feature]: I vibed a hermes-headroom wrapper that saved me 70%, someone should integrate something like it ASAP. — NousResearch/hermes-agent2 reactions · 2 comments
45 more on GitHub
- Apr 8, 2026`CHANGELOG.md` is not updated during the release process — headroomlabs-ai/headroom2 reactions · 2 comments
- Oct 18, 2026seo: accurate sitemap lastmod, fix retired-slug internal links, link /alternatives cluster, docs canonical, cite independent studies — Supercompress/Supercompress1 reaction · 1 comment
- Jun 14, 2026Token compression pipeline — icedream/werkler1 reaction · 2 comments
- Jun 12, 2026Evaluate Headroom context compression at the lib/ai/sdk.ts chokepoint (inference cost / margin) — JovieInc/Jovie1 reaction · 6 comments
- Jun 11, 2026ci: limit commitlint to pull requests — headroomlabs-ai/headroom1 reaction
- Jun 10, 2026feat: Janet compression plugin + /plugins slash command — dirge-code/dirge1 reaction · 2 comments
- Jun 2, 2026[Feature] Compression methodology integration — cheaper-inference/OmniRoute1 reaction · 1 comment
- May 10, 2026Tools Comparisons alternatives — jgravelle/jcodemunch-mcp1 reaction · 6 comments
- Apr 20, 2026[BUG] Multiple documentation issues — headroomlabs-ai/headroom1 reaction · 5 comments
- Jan 20, 2026Add Headroom Context Optimization to LLM Optimization Tools — Shubhamsaboo/awesome-llm-apps1 reaction · 1 comment
- Oct 28, 2026docs: add AGENTS.md for agents using Headroom and agents changing the repo — headroomlabs-ai/headroom0 reactions · 2 comments
- Oct 3, 2026ci: bump the uv group across 1 directory with 9 updates — herominutes/headroom0 reactions
- Sep 26, 2026Hosted CI token E2E: ten of the sixteen token tools through their pinned upstream CLIs/MCP, Headroom compression, RTK inline tests (GPT-6 reviewed) — native-agent-stack/native-agent-stack0 reactions · 1 comment
- Sep 26, 2026build(deps): bump vendor/headroom from `c632023` to `94206e2` — DelwarOfficial/Lithic-CLI0 reactions
- Sep 25, 2026Headroom: run the MCP server with its usage beacon off (HEADROOM_OFFLINE=1, DO_NOT_TRACK=1) — native-agent-stack/native-agent-stack0 reactions · 1 comment
- Sep 25, 2026Grand-dashboard checkpoint: token stack inside subagents and the host request lane — native-agent-stack/native-agent-stack0 reactions · 2 comments
- Sep 25, 2026headroom-ai: Add version 0.37.0 — riseproject-dev/python-wheels0 reactions · 1 comment
- Sep 18, 2026fix: record Serena's license as GPL-3.0-or-later for the whole package — sehoon787/my-claude0 reactions
- Sep 18, 2026feat: add Serena and Headroom MCP servers plus the archify diagram skill — sehoon787/my-codex0 reactions · 1 comment
- Sep 5, 2026build(deps): bump vendor/headroom from `c632023` to `32d7ca4` — DelwarOfficial/Lithic-CLI0 reactions · 1 comment
- Sep 2, 2026deps: bump headroom-ai from 0.36.5 to 0.37.0 in the dev-dependencies group — SerayaEryn/claude-search-compress0 reactions
- Aug 31, 2026chore(deps): bump headroom-ai from 0.32.1 to 0.37.0 — juliopessan/agent-finops-ZWCA0 reactions · 1 comment
- Aug 29, 2026build(deps): bump vendor/headroom from `c632023` to `34a5517` — DelwarOfficial/Lithic-CLI0 reactions · 1 comment
- Aug 22, 2026build(deps): bump vendor/headroom from `c632023` to `93f2d7a` — DelwarOfficial/Lithic-CLI0 reactions · 1 comment
- Aug 14, 2026chore: install agent skills and plugins (OmniRoute, task-observer, claude-mem, headroom, claude-code-setup) — JesseLaving/efficience0 reactions · 1 comment
- Aug 8, 2026build(deps): bump vendor/headroom from `c632023` to `9fd5ae3` — DelwarOfficial/Lithic-CLI0 reactions · 1 comment
- Jul 29, 2026Attached Claude sessions report inflated context percent: proxy base URL drops the assumed window from 1M to 200k — hyparam/hypaware0 reactions
- Jul 25, 2026build(deps-dev): bump headroom-ai from 0.27.0 to 0.32.1 — DelwarOfficial/Lithic-CLI0 reactions
- Jul 21, 2026docs: add comprehensive project blueprint and future roadmap — benyamin-persia/headroom0 reactions
- Jun 23, 2026fix(proxy): feed Codex responses into traffic learner — headroomlabs-ai/headroom0 reactions · 4 comments
- Jun 22, 2026chore(links): canonicalize 7 moved source URLs — JSONbored/awesome-claude0 reactions · 3 comments
- Jun 21, 2026Use Headroom to cut agent run cost: prompt-cache hits (CacheAligner) + lossless/reversible memory-digest curation (CCR) — open-orcha/orcha0 reactions · 4 comments
- Jun 21, 2026⚠️ Failed to create server discovery PR — fuzzylabs/awesome-secure-mcp-servers0 reactions
- Jun 21, 2026Headroom token compression — bashfulrobot/nixerator0 reactions · 1 comment
- Jun 21, 2026📱 SNS 콘텐츠 - 2026-06-21 13:18 KST — leaf468/autothreads0 reactions
- Jun 21, 2026🤖 AI 트렌드 리포트 - 2026-06-21 13:18 KST — leaf468/autothreads0 reactions
- Jun 20, 2026AI Briefing Request - 2026-06-20 16:00 UTC+8 — happyfeetw/pulse-mind0 reactions
- Jun 20, 2026Add use of Headroom proxy as a hook example — keithmackay/modelrouter0 reactions · 1 comment
- Jun 19, 2026Add headroom context compression as a shared agentic workflow — github/gh-aw0 reactions · 4 comments
- Jun 18, 2026feat: use with upstream proxy — fkiene/llmtrim0 reactions · 1 comment
- Jun 18, 2026[Feature]: headroom level compression — BerriAI/litellm0 reactions · 2 comments
- Jun 18, 2026P8 https://github.com/chopratejas/headroom — attogram/rock-talk0 reactions
- Jun 18, 2026[FEATURE] claude 模块支持 headroom — x-cmd/x-cmd0 reactions · 5 comments
- Jun 16, 2026Agent Booster — adopt Headroom patterns: cache-alignment, SmartCrusher, booster learn, shared index — sseshachala/conductai0 reactions · 2 comments
- Jun 15, 2026Looking to proxy Ollama requests to Headroom for Anthropic queries — psenger/ollama-claude-proxy0 reactions · 2 comments
On YouTube · 25
- Jun 8, 2026Headroom: The Netflix Tool That Makes AI Agents 10x Cheaper — Better Stacksays it tested it107k views · 158 comments
- Jun 3, 2026Headroom: A Context Optimization Layer for LLM Applications - Tejas Chopra, Netflix, Inc. — The Linux Foundation41k views
- Jun 14, 2026I Tested Headroom: 96% Log Compression? — DIY Smart Codesays it tested it12k views · 13 comments
- Jun 3, 2026Someone just open-sourced tokenminimizing (8500 stars on GitHub) — Income stream surfers8.8k views · 5 comments
- Jun 14, 2026Headroom: Cut AI agent token bloat by 95% — The Contextiansays it tested it4.3k views
20 more on YouTube
- Jun 3, 2026LLM API 費用狂燒?Headroom 實測:上下文壓縮 95%,成本直接砍半! — GitCoverysays it tested it2.2k views · 1 comment
- Jun 1, 2026Headroom: The Context Optimization Layer for LLM Applications — Research Paper Review1.4k views
- Jun 2, 2026Headroom — Compress Your Agent's Context 60-95% Before It Hits The LLM — Prism Labssays it tested it1.3k views · 2 comments
- Jun 21, 2026Headroom Reduced My Token Usage in 30 Seconds — Open Source Spotlight1.1k views · 2 comments
- Jun 2, 2026Compress tool outputs, logs, files, and RAG chunks before they reach the LLM — headroom — Amplify Imagination1k views
- Jun 22, 2026Headroom: The Open Source Context Compression Layer from Github — Full Stack734 views
- Jun 5, 2026Headroom's Origin Story: From 1 Commit to 56 Devs 🌊 — CodeTimelapse600 views
- Jun 17, 2026Headroom: The Local Proxy Cutting AI Agent Tokens by 60-95% — TechWealth Hub438 views · 2 comments
- Jul 28, 2026Headroom – The Context Compression Layer for AI Agents — Praveen Govindaraj352 views · 1 comment
- Jun 22, 2026Headroom: Cleaner Context For Coding Agents — BACKFIRED X349 views · 1 comment
- Jun 3, 2026chopratejas/headroom - Gource visualisation — Gourcer282 views
- Jun 7, 2026headroom - GitHub Trending Today — GitHub Trending Digest249 views
- Jun 21, 2026headroom - GitHub Trending Today — GitHub Trending Digest204 views
- Jun 20, 2026Headroom:AI Agent 的上下文壓縮層 — Github雷達186 views
- Jun 23, 2026headroom - GitHub Trending Today — GitHub Trending Digest169 views · 1 comment
- Jun 21, 2026I Visualized Headroom: The Code That Saves 95% Tokens 😲 — CodeTimelapse123 views
- Jun 5, 2026chopratejas/headroom: AI update in 40 seconds — The Agents Feed122 views
- Jun 3, 2026LLM API costs burning through your budget? Headroom tested: Context compression 95%, costs cut i... — DevCovery79 views
- Jun 30, 2026Headroom: Compressing AI Context Without Losing Intelligence — Praveen Govindaraj73 views
- Jun 22, 2026headroom - GitHub Trending Today — GitHub Trending Digest64 views
On Bluesky · 20
- Jun 18, 2026Un ingeniero de Netflix ha sacado algo tremendo. ¡Promete ahorrarte hasta el 95% de los tokens! ¿Cómo? Comprime tu contexto antes de… — @midu.dev9 likes and reposts · 1 reply
- Jun 20, 2026This is a great tool to make your agent sessions more token efficient: github.com/chopratejas/... — @mikestaub2.bsky.social6 likes and reposts
- Jun 14, 2026Headroom compresse les outputs d'outils, logs, fichiers et chunks RAG avant qu'ils atteignent le LLM — 60 à 95% de tokens en moins, sans… — @camilleroux.com5 likes and reposts · 2 replies
- Jun 20, 2026headroom compresses tool outputs, logs, and RAG chunks before they hit the model, then serves the original back on demand. Its README… — @jeremymorgan.com3 likes and reposts · 1 reply
- Jun 16, 2026Headroom: a Tool to compress everything your AI Agent reads — tool outputs, logs, RAG chunks, files, and conversation history — before it… — @lcheylus.bsky.social3 likes and reposts · 1 reply
15 more on Bluesky
- Jun 1, 2026the github github.com/chopratejas/... #LLM #ai — @danincode.bsky.social3 likes and reposts
- Jun 5, 2026「Claude Codeにも使えるトークン削減ライブラリHeadroom、60〜95%削減で同等精度」——気になったので一次ソースまで見ましたぁ。 元ポスト https://x.com/commte/status/2061645252503670966 💎 Claude… — @lutie-echosphere.bsky.social2 likes and reposts · 1 reply
- Jun 1, 2026AIエージェントが読み込むログやファイルを圧縮してトークン消費を大幅に抑えるツールらしい 長文のやり取りでコストを気にせず開発できそうかな yug1224 starred chopratejas/headroom… — @yug1224.com2 likes and reposts
- Jun 22, 2026been hearing about headroom lately - have you used it? thoughts? 🍿 🔗 github.com/chopratejas... — @kelset.dev1 likes and repost
- Jun 18, 2026Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 60-95% fewer tokens, same answers. github.com/chopratejas/... — @asiermarques.com1 likes and repost · 1 reply
- Jun 12, 2026Worth exploring - a GitHub repo focused on compressing outputs, logs, files, and RAG chunks before LLMs, reducing token use by up to 95%… — @alexiskirke.bsky.social1 likes and repost
- Jun 7, 2026トークン節約するossのツールも人気さいきんあるんだ。みてみよう。 github.com/chopratejas/... — @nsega.dev1 likes and repost · 1 reply
- Jun 6, 2026今日のGitHubトレンド chopratejas/headroom AIエージェント向けのコンテキスト圧縮レイヤーです。 ツール出力やログ、RAGの結果、会話履歴などをLLMに送信する前に圧縮し、トークン数を60%から95%削減します。… — @dailygithubtrends.bsky.social1 likes and repost
- Jun 4, 2026chopratejas/headroom Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 60-95% fewer tokens, same answers.… — @llms.activitypub.awakari.com.ap.brid.gy1 likes and repost
- Jun 2, 2026💎 Hidden Gem! 💎 (1000+ new stars) 📦 chopratejas / headroom ⭐ 5,130 (+1,266) 🗒 Python Compress tool outputs, logs, files, and RAG chunks… — @github-trending.bsky.social1 likes and repost · 1 reply
- May 28, 2026Headroom Headroom compresses everything your AI agent reads - tool outputs, logs, RAG chunks, files, and conversation history - before it… — @pythonhub.dev1 likes and repost
- Jun 19, 2026💎 Hidden Gem! 💎 (1000+ new stars) 📦 chopratejas / headroom ⭐ 36,589 (+3,938) 🗒 Python Compress tool outputs, logs, files, and RAG… — @github-trending.bsky.social0 likes and reposts · 1 reply
- Jun 19, 2026via feed: GitHub - chopratejas/headroom: Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 60-95% fewer tokens,… — @elburro.bsky.social0 likes and reposts · 1 reply
- May 19, 2026On parle beaucoup de context windows plus grandes. Mais l’avantage compétitif sera aussi de mieux compresser ce qu’on donne au modèle.… — @jordbastin.bsky.social0 likes and reposts · 1 reply
- May 3, 2026its context optimizer thingamabob github.com/chopratejas/... — @a.rapeable.dog0 likes and reposts · 1 reply
On Hacker News · 9
- Jun 20, 2026Compress tool outputs, logs, files, RAG chunks before LLM for 60-95% less tokens4 points
- May 16, 2026A Compression Tool for LLM Reads. Est. 60-95% Fewer Tokens4 points
- May 31, 2026Headroom – LLM Input Compression3 points
- Jan 18, 2026Show HN: Headroom (OSS): Cuts LLM costs by 85%3 points · 5 comments
- Jun 18, 2026TokenMinMaxing2 points
4 more on Hacker News
- Jun 17, 2026Headroom2 points
- Jan 13, 2026Headroom – context optimization layer for tool-using agents2 points · 2 comments
- Mar 4, 2026The Context Optimization Layer for LLM Applications1 point
- Jan 15, 2026Show HN: Headroom – Reversible context compression for LLMs(~60% cost reduction)1 point · 1 comment
On the web · 2
- Oct 30, 2026headroom - Everything is a Skill - 6er Agent Skills Hub — 6erskills.com
- Jun 1, 2026chopratejas/headroom:... – GitHub Daily Trend — podcasts.apple.com
Other versions1 project uses a version of this.
Word for word · 1
- headroomlabs-ai/headroom★ 79k100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,774 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository3 other files it gives its agents.
- .github/copilot-instructions.mdCopilot instructions
- llms.txtllms.txt
- headroomSkill
The file
We split this AGENTS.md into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 20
Verify without a provider key:
- Distinctive: line 37
Every external PR needs a "Real behavior proof" section (setup, exact commands, observed output, what was not tested).
≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AGENTS.md
If you landed here to use Headroom in an app
The PyPI package is headroom-ai; the import and the CLI are headroom.
pip install headroom-aifrom headroom import compress
result = compress(messages, model="gpt-4o") # OpenAI or Anthropic message dicts
# send result.messages instead of messages; log result.tokens_before / tokens_after / tokens_savedIn-process, no API key, no model download. HEADROOM_OFFLINE=1 makes the run
zero-network (no update check, no model or pricing-table downloads, no beacon).
Verify without a provider key:
HEADROOM_OFFLINE=1 python -c "from headroom import compress; log='\n'.join(f'INFO step {i} ok' for i in range(3000))+'\nFATAL disk full'; r=compress([{'role':'user','content':'What failed?'},{'role':'assistant','content':None,'tool_calls':[{'id':'c1','type':'function','function':{'name':'logs','arguments':'{}'}}]},{'role':'tool','tool_call_id':'c1','content':log}], model='gpt-4o'); print(r.tokens_before, '->', r.tokens_after, 'FATAL kept:', 'FATAL' in str(r.messages))"- FastAPI example: https://docs.headroomlabs.ai/docs/fastapi
- Full docs index for agents: https://docs.headroomlabs.ai/llms.txt (hand-curated subset:
llms.txtin this repo) - Coding agents (Claude Code, Codex, Cursor, Copilot):
uv tool install --python 3.13 "headroom-ai[all]"thenheadroom wrap claude headroom.integrations.asgi.CompressionMiddlewareis for apps that serve/v1/chat/completions-style routes, not for an app that calls a provider; usecompress()for that- Canonical repo: https://github.com/headroomlabs-ai/headroom.
github.com/chopratejas/headroomredirects here; there is noheadroom-sdkorg. The PyPI distribution namedheadroomis a different project.
If you are changing this repo
- Layout: Python package in
headroom/, Rust core and PyO3 extension incrates/(built by maturin), TypeScript SDK insdk/typescript/, docs site (Next.js + Fumadocs) indocs/content/docs/, agent plugins inplugins/, examples inexamples/. - Setup:
uv sync --extra devandmake install-git-hooks(pre-commit, commitlint, pre-push). Python checks:uv run ruff check .,uv run ruff format .,uv run pytest. Rust checks:make ci-precheck-rust. All gates:make ci-precheck. SeeCONTRIBUTING.md. - Commits and PR titles are Conventional Commits (
feat:,fix:,docs:, ...). Never editCHANGELOG.md; release-please writes it from PR titles. - Every external PR needs a "Real behavior proof" section (setup, exact commands, observed output, what was not tested). Bug fixes need a test that fails before the fix.
- One docs site:
docs/, deployed by Vercel to docs.headroomlabs.ai.wiki/and thegh-pagesbranch are not published; do not add content there. - Public API examples in
README.md,llms.txt,AGENTS.mdanddocs/must use names that exist inheadroom/compress.py(compress,CompressResult.messages,.tokens_before,.tokens_after,.tokens_saved,.compression_ratio,.transforms_applied). - Savings claims anywhere in the repo must match the measured table under "Proof" in
README.md: 21-57% on the four agent scenarios, 90%+ on repeated JSON arrays and log lines, little on prose. - Version-carrying files (
pyproject.toml, plugin and marketplace manifests,sdk/typescript/package.json,server.json) are kept in step byscripts/version-sync.pyand gated byscripts/verify-versions.py; add any new one to both.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

