lcc

What lcc is

lcc removes old tool output from a coding agent’s context. In stashed mode, every byte it removes is one recall away, checked by hash. Every pass lists what it removed, and why, in a receipt.

That is the product. Everything in the left column below serves it. The right column is research: it is kept in the repository and documented, but no product claim rests on it.

Rules every product path keeps

Glossary

term meaning
context everything sent to the model on one request: system prompt, tool schemas, injected instructions, the transcript
lossless a removed tool output is replaced by a pointer to an identical output still in context. Nothing leaves the context.
recoverable lossless, plus old file reads replaced by a “re-read” pointer when the file is unchanged
stashed an old tool output moves to the local stash and is replaced by [removed: … · lcc recall <id>]
stash the local, content-addressed store of removed outputs (~/.cache/lcc/stash, 0700/0600, LCC_STASH_DIR)
recall the CLI command and MCP tool that returns a stashed output by id, byte for byte; --file also says whether a recalled file read still matches the file
receipt what a pass reports: what was removed, why, by which rule, token counts, hashes and the cache effect. The JSON report, and in Claude Code the ledger and statusline (guide)
handoff lcc handoff: a verbatim packet of what the next agent needs, from any agent tool’s session (HANDOFF.md)
lossy experimental. It failed two blind audits (REAL_SESSION_BENCHMARKS.md), and it is not part of the product.
MSI Minimum Sufficient Inference, a research protocol frozen as a research release by ADR 0022. Not the product.

Product and research

product (supported, measured on real sessions) research (frozen or experimental, no product claims)
rules provider (lossless, recoverable, stashed), and auto, the local specialist-v3 ranker that the plugin and compact_transcript use by default MSI specs and engines (ADR 0022)
recall (CLI and MCP), the stash, verify_stashed causal necessity labels (ADR 0021)
measure-session, share-stats, handoff lossy, the Jev and Laya providers
Claude Code plugin (compaction hook, statusline), MCP server semantic retrieval scaffold (ADR 0011, ADR 0012)
block mode compact with its cache contract (ADR 0015) the prepare/optimize cleaning pipeline: it works, but it is not the story

Other agent tools (Codex, Gemini CLI, Aider, OpenCode, Cline, Cursor) get the product through the CLI and the MCP server. Compacting earlier covers their compaction settings.