github alexgreensh/token-optimizer v2.4.3
v2.4.3: Fix stale ContextQ across sessions

latest releases: openclaw-v2.4.1, v5.6.4, v5.6.2...
one month ago

Critical Fix

ContextQ score was stuck showing the same value across all sessions.

Root Cause

The statusline read from one global quality-cache.json file, but multiple sessions (and subagents) raced to overwrite it. The last writer won, causing every session to display a stale score from whichever session wrote last.

Fix

Statusline now reads session-specific cache files with a 3-tier priority:

  1. quality-cache-{session_id}.json (exact match, if Claude Code sends session_id)
  2. Most recently modified quality-cache-*.json (fallback)
  3. Global quality-cache.json (final fallback)

Each session now shows its own quality score and compaction count.

Also in this release (from v2.4.2)

  • Fixed caller dict mutation bug in _auto_remove_bad_env_vars()
  • Fixed _manage_mcp guard logic
  • Consolidated duplicate write functions (-12 lines)
  • Added orphaned temp file cleanup to ensure-health
  • Deduped compaction loss map between JS/Python

Don't miss a new token-optimizer release

NewReleases is sending notifications on new releases.