LabscoMCP early access ↗
Yuchen20MCP SERVER

Context Crumb

Token-level compressor for agent context: deletes low-signal words from text or a file, keeps the original order, and refuses file types where that would break meaning.

by Yuchen20 ↗Codebase Context Packing & CompressionCommunity

LABSCO SUMMARY

Deletes words, never rewrites them.

A summarizer produces new text you then have to trust; this removes tokens and leaves the rest in place, which is why it can be pointed at logs, issue threads and research dumps without changing what they say. The refusal list is the good part of the design — diffs, lockfiles, SQL and .env files are declined rather than mangled, and auto mode leaves code intact while squeezing the comments around it.

What it is

An MCP adapter over ContextCrumb, a compressor that works word by word rather than by rewriting. It is not a summarizer — surviving text stays in source order with expendable tokens removed, so names, actions, constraints and sequence stay put while filler goes.

What you get

  • Compress inline text with a keep-probability threshold, or a fixed target_keep_ratio when the budget rather than the cutoff is the constraint — compress_text
  • Compress a file on the machine running the server, with encoding and the same threshold controls — compress_file
  • Code-aware handling in auto mode: executable code is preserved exactly and only comments and docstrings are compressed, for Python, JavaScript, TypeScript, JSX, TSX, Go and Rust
  • content_mode to choose the behaviour yourself — auto, prose, code-comments, raw or refuse
  • A refusal path for syntax-sensitive files — diffs, structured configs, lockfiles, SQL and .env — unless you pass force
  • return_tokens to see which tokens were kept and which were dropped
  • A separate proxy, contextcrumb-shrink, that compresses verbose catalog descriptions before an agent reads them while passing tool names, schemas, calls and results through unchanged

Requirements

Python >=3.10 and the MCP extra: pip install "contextcrumb[mcp]", or run it with no install at all via uvx --from "contextcrumb[mcp]" contextcrumb-mcp — which is exactly what the documented client entry does. compress_file reads paths on the server's machine, not the client's. For repeated calls, start contextcrumb service start --allow-root . and add --use-service so each server process is not loading its own model.

Setup effort

One command — pip install "contextcrumb[mcp]"