← Overview
GitHub Trending · listed 3 times

ranxianglei/billion-context

agentany agentcompressorrewrites streammodel APIAnthropic/OpenAI5x fewertokens100Kcontext enough95-97%cache hit rate
+375 that day★ 6.4KTypeScript

Context-compression plugin for month-long agent sessions

billion-context sits between an agent and its model API, rewriting Anthropic/OpenAI streams. It targets small context windows (100K is enough) and 5x fewer tokens.

  • The README cites a healthy prefix-cache hit rate of 95-97%, with compression costing at most 2%.
  • Its 1,500-item third-party evaluation ranks it #1 on ContextBench, and 79.20% vs 62.60% for the best RAG on LongMemEval-S.
  • The paper and benchmark code are in the repo, with the paper under the MIT License.
trynpm install -g billion-context --prefix=~/.local

Trending history

First listed on 8 November 2026 at 4.9K stars, most recently on 11 November 2026 at 6.4K. Biggest day: 9 November 2026, 460 stars.

8/119/1111/11
  1. 11 November 2026+375★ 6.4K
  2. 9 November 2026+460★ 5.2K
  3. 8 November 2026+460★ 4.9K

Related repos

Same owner or also written in TypeScript, from other days on the list.