Context Mode – 315 KB of MCP output becomes 5.4 KB in Claude Code
Context compression for Claude Code—98% reduction, 315KB becomes 5.4KB, extends sessions 6x.
Context window optimization for AI coding agents. Sandboxes tool output, 98% reduction. 15 platforms
Context-aware summarizer cuts Playwright dumps from 56KB to under 1KB with zero friction.
Claude Code users hitting context limits in MCP workflows
Cloudflare Code Mode · Tree-sitter-based code summarizers
I built an MCP server that sits between Claude Code and these outputs. It processes them in sandboxes and only returns summaries. 315 KB becomes 5.4 KB.
It supports 10 language runtimes, SQLite FTS5 with BM25 ranking for search, and batch execution. Session time before slowdown goes from ~30 min to ~3 hours.
MIT licensed, single command install:
/plugin marketplace add mksglu/claude-context-mode
/plugin install context-mode@claude-context-mode
Benchmarks and source: https://github.com/mksglu/claude-context-mode
Would love feedback from anyone hitting context limits in Claude Code.
NOTE: Because of the timezone issue, I’m resurfacing the same content here.
I’ve already notified support about this via email, so they’re aware.
Original post: https://news.ycombinator.com/item?id=47148025
Context compression for Claude Code—98% reduction, 315KB becomes 5.4KB, extends sessions 6x.
Tree-sitter AST compression cuts LLM context tokens 50-70% while preserving API structure.
Caveman mode cuts tokens 70% while Claude Code alternatives charge monthly.
Cuts cargo test output from 61 lines to 1 — saves 60-90% of wasted LLM tokens.
Merkle tree hashing detects stale files before reusing subagent context.
Two MCP tools replace hundreds when typical integrations need one tool per endpoint.