Claude Code Plugin Analyzes Token Waste and Anomalies Locally

A developer has created a Claude Code plugin called claude-token-analyzer that diagnoses token waste in Claude Code sessions by analyzing local data. The tool detects six specific anomaly types: HighCost, LowCacheHitRate, CostInefficient, ExcessiveToolUse, HighTokenUsage, and UnusualModelMix, each with severity scoring to prioritize fixes.
How It Works
The plugin is built as a Rust MCP server that parses Claude Code session data from ~/.claude/projects/**/*.jsonl files into a local SQLite database. It performs statistical analysis using standard deviation thresholds and composite anomaly detection. The system is fully local with no cloud components or telemetry.
What It Found
Scanning 8,392 sessions revealed 1,015 anomalies:
- ExcessiveToolUse was the most common (320 sessions) - far more tool calls than typical
- LowCacheHitRate affected 261 sessions - prompts were re-sent without caching
- 66 sessions were "cost-inefficient" - high cost combined with poor cache hit rate
Installation and Usage
Install with: claude plugin install claude-token-analyzer
After installation, you can ask Claude:
- "cta"
- "how much did I spend?"
- "scan for anomalies"
The plugin exposes 7 MCP tools and 6 workflow skills. It also includes Traditional Chinese workflow skills - you can input "看看狀況", "這個月花多少", or "有異常嗎" for Chinese analysis reports.
The tool is available on GitHub at https://github.com/li195111/claude-token-analyzer under MIT License.
📖 Read the full source: r/ClaudeAI
👀 See Also

Claude Usage Bar Colorizer Browser Extension Built with Claude Code
A developer built a browser extension that recolors Claude's usage bars from green to yellow to red based on percentage thresholds, adds a popup with live usage data, and allows customization of thresholds and colors. The extension only runs on Claude's usage page, stores settings locally, and makes no external network requests.

TeamHero v2.6.1: Open-Source Platform for Managing Claude AI Agents
TeamHero v2.6.1 is a local-first, open-source platform that creates a managed team of Claude agents with features like autopilot mode, subtask nesting, flow views, and persistent memory. The tool runs on Node.js with a vanilla HTML/CSS/JS dashboard and requires no database.

Fixing OpenClaw's Blind Spots: Building a Sitemap to Fetch All Anthropic Blogs
OpenClaw's browser tool fails to discover all Anthropic blogs because they're hosted across multiple URLs. A user fixed this by feeding a generated sitemap, then packaged the solution as a shareable skill.

Structured Reasoning Template Improves AI Code Review Accuracy
A Reddit user shares a structured reasoning template adapted from Meta research that forces AI models to complete specific analytical steps before generating code reviews, improving accuracy by 5-12 percentage points according to arXiv:2603.01896.