#119119th of 149 in Skills, plugins and rules
lean-ctx
Local MCP server and shell hook that trim context fed to coding agents
Documentation ↗
(opens in a new tab)Website ↗
(opens in a new tab)Repository on GitHub ↗
(opens in a new tab)
- Stars
- 3.9k
- License
- Apache-2.0
- Last commit
- Oct 2026
- Last release
- Oct 2026
- Language
- Rust
Missed the latest GitHub check; these facts may be older.
Overview
LeanCTX sits between AI coding tools and the files and command output they read. It exposes ctx_* MCP tools with 16 file read modes, compresses shell output with 85+ patterns, and keeps local session memory, with an optional proxy for model requests. It is written in Rust and set up per agent with `lean-ctx wrap cursor|claude|codex`.
Who it is for: Developers using Claude Code, Cursor or Codex who want fewer tokens per task
Strengths
- 16 read modes incl. map, signatures, diff, line ranges; cached re-reads return compact references
- Tree-sitter parsing for 27 languages and 85+ shell-output compression patterns
- Local savings ledger and dashboard; shadow mode estimates savings against an uncompressed baseline
- Install via curl, brew, npm or cargo; wrap and unwrap are reversible
Weaknesses
- Mixed license; enterprise controls and SDK fall under separate terms
- Shadow Mode savings are simulated, not measured against a second run
- Claude Pro/Max OAuth cannot use the proxy; wire-level compression needs an API key
- Addons, snapshots, packages and multi-agent handoff are labeled experimental
What it needs
- no GPU
- Models: Claude Code, Cursor, Codex, Anthropic API (proxy)
Also in Skills, plugins and rules
See all 149| Rank | Project | Score |
|---|---|---|
| 1 | cavemanCuts token use in coding agents with terse replies and compressed inputs | 95 out of 100 |
| 2 | skillsAgent skills for planning, TDD, debugging and code review | 94 out of 100 |
| 3 | eccAgents, skills, hooks and rules bundle for Claude Code, Codex and other harnesses | 94 out of 100 |
| #4 | impeccableDesign skill with 24 commands and a detector for AI-generated frontends | 94 out of 100 |
| #5 | ponytailSkill prompt that makes coding agents write less code and add tests | 92 out of 100 |