llmtrim
llmtrim is a local proxy that sits between your AI tools (Claude Code, Codex, Cursor or your own app) and the LLM provider. It strips wasted tokens out of every request, such as a 200-line build log where only two lines are errors, a tool schema resent identically dozens of times, or a JSON array of near-identical rows, and forwards the smaller request while the reply comes back unchanged. The README reports a 31% input and 74% output token reduction measured over 112 A/B cases, with no change in answer quality.
It can be used as a proxy, a CLI, an MCP server, or a library for Python, Ruby, Swift and Kotlin, and installs with npm, an install script, Homebrew, cargo, scoop or Docker. Each compression step is re-measured with the provider's tokenizer and reverted if it does not save tokens, and the original request is resent if the provider rejects the compressed one. Setup installs a private certificate limited to LLM API domains, a shell proxy setting and a login service; `llmtrim uninstall` reverses all three, and prompts are not written to disk.
Features
Why choose it
Trade-offs
Maintenance check
- Last commit
- 2026-09-29
- Commits, last 90 days
- 100+
- Releases, last 90 days
- 22
- Latest release
- v0.13.7 (2026-09-16)
- Open issues
- 13
- Recent issues with at least one comment
- 9/13
Oldest week on the left; the latest four weeks are orange. Source: GitHub commit activity.
Status rule: archived on GitHub = Archived; last commit within 90 days = Active; 91 to 365 days = Slowing; older = Stale. All figures come from the GitHub API on the date shown.
Most discussed open issues
- #273 feat: Codex localhost gateway without MITM proxy1 comments · 2026-08-28
- #156 feat: `sub` hot swapping1 comments · 2026-07-12
- #297 mcp install: add a DeepSeek Harness (DSH) target0 comments · 2026-09-16
Issue titles are quoted from GitHub. Open the link to check whether a problem still applies to the version you use.
Compatibility
Quick start
Use cases
Alternatives
Comments
No comments yet. Be the first!