Most LLM-tooling focuses on compressing a single slice of output; the real cause of session quality loss is structural bloat and compaction loss that never gets measured. Token Optimizer tackles that blind spot by making every token visible and recoverable so sessions survive compactions and context quality doesn't quietly degrade.
What Sets It Apart
- Measured, local-first approach: captures per-turn token breakdowns, cache reads, subagent spend and quality scores in a local SQLite store and a bookmarkable dashboard — nothing is sent off-host.
- Smart compaction and checkpoints: snapshots session state at thresholds, archives large tool outputs, and restores critical decisions after compaction so you don't lose the work that led to decisions.
- Active compression + structural fixes: delta-mode diffs on re-reads, AST-based structure summaries for large code files, and a growing set of CLI output compressors (git, pytest, linters, logs) to cut repetitive runtime noise.
- Multi-platform integration: native plugins / adapters for Claude Code, OpenClaw and Codex (beta), with a single-file HTML dashboard and CLI for environments without extension support.
Who it's for — fit and trade-offs
Great fit if you run long, tool-heavy LLM sessions (multi-agent orchestration, code-heavy debugging, or repeated large file reads) and want reproducible token savings plus session continuity. The tool prioritizes safety: it never mutates existing in-context conversation blocks (avoids prompt-cache invalidation) and runs with zero runtime dependencies.
Look elsewhere if you require a cloud-hosted analytics service, need permissive commercial licensing for high-revenue enterprise use (the project ships under PolyForm Noncommercial), or if you prefer lossless, full-output retention for every CLI command — some compressors are intentionally lossy and are toggleable.