#169 · Primary category: AI Coding Assistants

lean-ctx

agentic-coding ai ai-agents ai-coding claude-code context-engineering context-intelligence context-layer copilot cursor developer-tools gemini-cli lean-context llm mcp mcp-server reduce-token-costs rust token-optimization

LeanCTX is a local-first context engineering layer for AI coding agents, cutting token usage by 60–90% via compression, caching, and session memory.

Project last updated:08/29/26

GitHub Stars

3.7K

Forks

337

Contributors

56

License

Apache-2.0

Why we included this project

Long coding sessions have a familiar failure mode: the agent burns most of its context window re-reading files and echoing shell output, leaving little room for actual reasoning. LeanCTX is a local Rust binary that sits next to your coding agent and changes that. It decides what the agent reads and compresses file views and command output before the model sees them, which turns cached re-reads from roughly two thousand tokens into about thirteen. Session memory survives across chats, so the agent stops re-reading the same files every turn. An optional local proxy shrinks each request prompt-cache-safe without discarding data, and it works with the usual agents, Cursor and Claude Code included. If long sessions and rising token spend are your bottleneck, this is a direct way to fit more useful context into each dollar spent.

Articles for this project

No articles for this project yet.

To suggest a topic or contribute an article, contact us.

Related projects in this category