log-context-mcp: MCP tool reduces log token usage by 96% for Claude debugging

✍️ OpenClawRadar📅 Published: March 14, 2026🔗 Source
log-context-mcp: MCP tool reduces log token usage by 96% for Claude debugging
Ad

log-context-mcp is an MCP (Model Context Protocol) tool built to address the problem of Claude Code burning tokens on verbose log files during debugging sessions. Instead of pasting raw log files that can consume 15k tokens on health checks and INFO spam, this tool preprocesses logs before they hit Claude's context.

How it works

The tool performs several preprocessing steps on log files:

  • Deduplicates lines
  • Groups stack traces
  • Strips noise
  • Produces a ~1000 token summary instead of the full log dump

Performance and testing

Testing on a 2000-line Apache log showed a 96.5% token reduction while still correctly identifying the root cause. The developer built this after repeatedly encountering the problem where Claude would burn 15k tokens on log files before finding the 3 lines that actually mattered.

Ad

Additional features

The tool includes an optional semantic layer that runs a cheap model (Gemma/Haiku/Ollama) on the compressed output for root cause analysis and error timelines. For users who don't want a separate API key, there's a /analyze-log skill that uses a Haiku sub-agent through your existing Claude subscription instead.

Related tools and development status

The developer discovered rtk (a similar tool for general-purpose CLI output compression) after building this log-specific solution. log-context-mcp is more focused on logs specifically, with the semantic analysis layer on top.

The tool is still in early development with plans to submit to the MCP marketplace for easier discovery and add more log format support. It's released under MIT license with setup instructions available on GitHub.

The developer is seeking feedback on what log formats and stacks users would want tested.

📖 Read the full source: r/ClaudeAI

Ad

👀 See Also

Custom llama.cpp Backend Offloads LLM Matrix Multiplication to AMD XDNA2 NPU on Ryzen AI MAX 385
Tools

Custom llama.cpp Backend Offloads LLM Matrix Multiplication to AMD XDNA2 NPU on Ryzen AI MAX 385

A developer built a custom llama.cpp backend that dispatches GEMM operations directly to the AMD XDNA2 NPU on Ryzen AI MAX 385 (Strix Halo), achieving 43.7 t/s decode at 0.947 J/tok with Meta-Llama-3.1-8B-Instruct Q4_K_M. The NPU decode path saves ~10W versus Vulkan-only while matching decode throughput.

OpenClawRadar
Claw Code Agent: Python Reimplementation of Claude Code Architecture for Local Models
Tools

Claw Code Agent: Python Reimplementation of Claude Code Architecture for Local Models

Claw Code Agent is a Python reimplementation of the Claude Code agent architecture that runs with local open-source models through OpenAI-compatible backends like vLLM and Ollama, featuring tool calling, slash commands, and tiered permissions.

OpenClawRadar
Soul MCP Server Adds Persistent Memory and Safety for Local LLMs
Tools

Soul MCP Server Adds Persistent Memory and Safety for Local LLMs

Soul is an open-source MCP server that provides persistent memory across sessions for local LLMs with two commands: n2_boot at start and n2_work_end at end. It includes Ark safety features that block dangerous commands like rm -rf and DROP DATABASE at zero token cost, plus cloud storage configuration.

OpenClawRadar
ClawControl v1.3.1 adds media support, voice dictation, and Linux packaging
Tools

ClawControl v1.3.1 adds media support, voice dictation, and Linux packaging

ClawControl v1.3.1 is a cross-platform OpenClaw client that now supports image sharing, wake-word voice dictation, usage charts, and Linux AppImage/.deb packages. The release includes security updates requiring OpenClaw 2.19+ users to update Control UI Allowed Origins.

OpenClawRadar