github alexgreensh/token-optimizer v5.4.5

latest releases: v5.8.8, v5.8.7, v5.8.6...
one month ago

What's new in v5.4.5 (since v5.3.11)

This release rolls up six fixes that ship together. If you're upgrading from v5.3.11, everything below is in your update.

Dashboard & toggles

  • Hook detection fixed. The dashboard now correctly detects plugin-installed hooks. Smart Compaction, quality cache, and session collection show ON when they actually are. (v5.4.1)
  • Context window shows 1M. No more 200K hardcode — detects your real window size from session data. (v5.4.3)
  • Toggles work from daemon URL. Clicking toggles at http://localhost:24842/token-optimizer now actually flips them instead of silently failing. File:// mode also works. (v5.4.3)
  • Structure Map beta now enabled by default for opt-in users. (v5.4.3)

Daemon auto-update (no manual steps)

  • v5.4.4 — SessionStart auto-regenerates the daemon script when it's outdated after a plugin version bump. Previously you had to run setup-daemon by hand. Restart happens via launchctl kickstart on macOS.
  • v5.4.5 — Auto-restart now covers all three platforms. Linux uses systemctl --user restart; Windows uses schtasks /End + /Run. Existing users on any OS get working toggles on their first session after update.

Savings accuracy

  • Model rate detection. _log_savings_event now detects the actual session model from JSONL instead of hardcoding Sonnet 4. Savings report reflects your real usage. (v5.3.12)
  • Structural savings tracking. New category: baseline_overhead_delta × context_loads_since_baseline. Captures the compounding effect of overhead reductions across all future sessions.
  • Subagent multiplier. Context loads now include subagent invocations from JSONL, not just sessions × turns. Savings numbers now reflect real context load count.

Compaction checkpoints (v5.4.0)

Post-compact checkpoints now carry stronger continuity signal:

  • TodoWrite snapshot (current + completed items)
  • Git branch and SHA
  • Active plan doc path (auto-detected from reads of docs/plans/*.md)
  • Recently-read file list
  • JSON sidecar alongside the .md for machine-readable resume
  • Same 4K token cap — higher signal, no bloat

Under the hood

  • 47 tests pass across 5 test files
  • Daemon has a new /api/health endpoint for capability probing
  • CORS headers on daemon so file:// dashboards can POST to localhost:24842

Upgrading? Claude Code updates this plugin automatically when version bumps in plugin.json. If you installed v5.3.11 and want v5.4.5 right now, run /plugin update or just open a new session — the version mismatch path will refresh your dashboard and daemon on the next SessionStart.

Don't miss a new token-optimizer release

NewReleases is sending notifications on new releases.