leanctx: Drop-in prompt compression for production LLM apps

by jia-gao · LLM Plugin · ★ 320

Last updated: · Indexed by AgentSkillsHub · Auto-synced every 8h

How to install leanctx

pip install 'leanctx[openai,lingua]'    # or [anthropic], [gemini]
pip install leanctx                              # core (passthrough only — useful for testing the wrapper)

Taken from the project's README on GitHub.

Security audit verdict: SAFE · quality 64/100

None of the 44 rules matched — no credential harvesting, no data exfiltration, no curl-pipe-shell installer. Scanned against 44 published rules built on the SlowMist agent-security taxonomy, refreshed every 8 hours.

The quality score combines nine heuristic checks of the repo and its README: completeness, clarity, specificity, examples, structure, agent readiness, step-by-step content, instruction quality and security notes. It rates how well the project explains itself to an agent, not the code.

anthropiccost-optimizationgeminilangchainlanggraphllmllm-inferencellmlinguaopenaiprompt-compression

Quick Facts

Stars320
Forks7
LanguagePython
CategoryLLM Plugin
LicenseMIT
Quality Score64/100
Open Issues1
Last Updated2026-08-22
Created2026-04-18
Platformsgemini, python
Est. Tokens~16k

About leanctx

leanctx Drop-in prompt compression for production LLM applications. Cut your input-token bill by 40–60% — without changing your code. On the public LongBench v2 leaderboard's short subset, leanctx-Lingua doubles accuracy versus naive head+tail truncation (40 % vs 20 %) while removing 57 % of tokens. Open-source models, runs locally, MIT-licensed.

leanctx alternative? Top 6 similar tools

Looking for a leanctx alternative? If you're comparing leanctx with other llm plugin tools, these 6 projects are the closest alternatives on Agent Skills Hub — ranked by topic overlap, star count, and community traction.

  • context-compressor by Huzaifa785 · ⭐ 91

    AI-powered text compression library for RAG systems and API calls. Reduce token usage by up to 50-60% while pr

  • sage by Storia-AI · ⭐ 1.3k

    Chat with any codebase in under two minutes | Fully local or via third-party APIs

  • open-extract by velocitybolt · ⭐ 192

    Structured Data Extractor for AI Agents. Search your documents or the web for specific data and get it back in

  • flock by Onelevenvy · ⭐ 1.1k

    Flock is a workflow-based low-code platform for rapidly building chatbots, RAG, and coordinating multi-agent t

  • autollm by fcakyon · ⭐ 1.0k

    Ship RAG based LLM web apps in seconds.

  • argo by xark-argo · ⭐ 836

    ARGO is an open-source AI Agent platform that brings Local Manus to your desktop. With one-click model downloa

More LLM Plugin Tools

Explore other popular llm plugin tools:

View all LLM Plugin tools →

Popular Python Agent Tools

How this security grade is produced

Grades come from a rule-based scan built on the SlowMist agent-security taxonomy: 44 published rules, covering credential harvesting, data exfiltration, curl | sh installers and more. It is a first-layer scan, not a manual audit — we say so rather than overstate it.

The scale of the problem is documented independently: Liu et al. (2026), in a study of 31,132 agent skills, report that 26.1% contain security vulnerabilities. Our own full-catalog census is published as a citable open dataset.

Sources & who's responsible:

View on GitHub → Browse LLM Plugin tools