Other

项目介绍

chopratejas/headroom-zed 是一个托管在 GitHub 上的开源项目,主要使用 Rust 编写,采用 Other 许可证,目前获得 69 个 Star、15 次 Fork。

仓库全名
chopratejas/headroom-zed
开源许可证
Other
Star 数
69
Fork 数
15
未关闭 Issue
3

README 摘要

Headroom for Zed Context compression for Zed's AI agent. Same answers, fraction of the tokens. What it does This extension registers Headroom as an MCP context server in Zed, giving the AI agent three tools: Tool | What it does | headroomcompress | Compress large content (files, JSON, logs, search results) on demand | headroomretrieve | Retrieve original uncompressed content by hash | headroomstats | Show session…

完整内容见 GitHub 原始 README 或本页 。

常见问题

headroom-zed 用什么语言开发?

主要使用 Rust 编写,采用 Other 许可证,目前有 69 个 Star。

headroom-zed 可以免费商用吗?

仓库标注的许可证为 Other,商用前请先阅读仓库 LICENSE 文件确认授权范围。

如何获取 headroom-zed 的源码?

可以直接克隆仓库:git clone https://github.com/chopratejas/headroom-zed.git,默认分支为 main;安装与运行步骤见仓库 README。

headroom-zed 最近还在维护吗?

仓库最近一次更新为 3月19日,当前有 3 个未关闭 Issue;Star 数为 69,可作为社区活跃度的参考。

关于

Zed extension for Headroom — context compression for AI agents

描述取自 GitHub 官方 API,中文内容由 GitRead 中文社区 编辑团队整理。

简要分析

热度分
102
价值分
46
活跃状态
活跃

README

Headroom for Zed

Context compression for Zed’s AI agent. Same answers, fraction of the tokens.

What it does

This extension registers Headroom as an MCP context server in Zed, giving the AI agent three tools:

Tool What it does
headroom_compress Compress large content (files, JSON, logs, search results) on demand
headroom_retrieve Retrieve original uncompressed content by hash
headroom_stats Show session stats: tokens saved, cost saved, recent events

Setup

1. Install Headroom

pip install "headroom-ai[mcp]"

2. Install the extension

In Zed: Extensions → search Headroom → Install

That’s it. Zed’s agent now has access to compression tools.

3. (Optional) Automatic compression for all traffic

The MCP tools above are on-demand — the agent calls them when it wants to compress. For automatic compression of every LLM request, start the Headroom proxy:

headroom proxy

Then add to your Zed settings (settings.json):

{
  "language_models": {
    "openai": {
      "api_url": "http://localhost:8787/v1"
    }
  }
}

Now every request is automatically compressed — 50-90% fewer tokens, same quality. The MCP tools and proxy work independently or together.

How it works

The extension tells Zed to run headroom mcp serve as a background process. This starts Headroom’s MCP server, which exposes the compression tools over the Model Context Protocol. Zed’s agent can then call these tools like any other MCP tool.

Compression uses Headroom’s full pipeline: SmartCrusher for JSON, CodeCompressor for code, Kompress for text (with [ml] extra). Originals are stored locally for the session and retrievable on demand — nothing is lost.

Requirements

  • Headroom — pip install "headroom-ai[mcp]"
  • Python 3.10+
  • headroom command in PATH

License

Apache License 2.0

评论

暂无评论