TuringCorp-net/mosaic-memory-compress
A generic, pluggable stateless dialogue-compression algorithm with a ready-to-use DSH adapter: it keeps a conversation bounded at a constant message count by keeping recent rounds verbatim, structurally truncating the middle band and collapsing the oldest rounds into one heavy checkpoint — graduated, visible loss instead of a reset-and-summarize handover brief.
MosaicMemoryCompress keeps an LLM conversation bounded automatically by modelling biological forgetting inside a single message array instead of resetting to a summary brief. Recent rounds stay verbatim (the vivid present), the middle band is structurally truncated (reasoning, arguments and tool results trimmed while text is kept), and the oldest rounds collapse into one heavy checkpoint holding identity, environment, permissions and rules (semantic memory). The steady-state message count is constant — roughly 2 + heavyStart × (messages per round) — so the compression ratio approaches 100% whether the conversation is at round 60 or round 15,000. Loss is graduated and visible: the zone structure tells the model what it no longer knows, so it can fetch detail from shadowed storage on demand. The package works with any LLM agent framework, and this repository ships the DSH adapter.
Install
dsh plugin --profile web add mosaic-memory-compressCopied verbatim from the README's install block ('registry package' form); the same block shows a github:TuringCorp-net/mosaic-memory-compress form for installing straight from the public repo when no npm package is wanted.
Compatibility
A generic, framework-agnostic compression algorithm that ships a ready-to-use adapter module for DeepSeek Harness. The README contrasts its graduated approach with threshold summarization and describes the DSH adapter as the intended integration path.
Details
- Repo: TuringCorp-net/mosaic-memory-compress
- Category: Memory
- Stars: 3
- Version: GitHub repo TuringCorp-net/mosaic-memory-compress; npm package mosaic-memory-compress at 1.3.4 (registry check 2026-10-10; registry repository field resolves back to this repo). MIT license.
Alternatives
863683348/dsh-plugin-focus · akslcw/dsh-negative-ledger · askdkc/kiokuko-dsh