headroomlabs-ai

headroom

headroomlabs-ai

Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.

AI 简介

Headroom 是一个面向 AI 代理(Agent)的上下文压缩层,用于在 LLM 输入前智能压缩工具输出、日志、RAG 检索片段、文件及对话历史,实现 60–95% 的 token 减少且保持语义等价与答案一致性。它提供 Python/TypeScript 库、HTTP 代理和 MCP 服务器三种集成方式,支持 6 种可逆压缩算法,强调本地优先、无模型依赖与跨 LLM 兼容性。适用于上下文受限场景下的 RAG 系统、长程 Agent 工作流、日志摘要与高吞吐量 AI 服务优化。

Python
Apache License 2.0
80.7k
Stars
6.3k
Forks
214
Watchers
149
Issues

Star 增长

今日+210
近 7 天+822
近 30 天+2934
综合评分120
默认分支main