Files
openclaw/ui/src
Val Alexander 7c520cc0ea web UI: fix context notice using accumulated inputTokens instead of prompt snapshot (#51721)
The context-usage banner in the web UI fell back to inputTokens when
totalTokens was missing. inputTokens is accumulated across all API
calls in a run (tool-use loops, compaction retries), so it overstates
actual context window utilization -- e.g. showing "100% context used
757.3k / 200k" when the real prompt snapshot is only 46k/200k (23%).

Drop the inputTokens fallback so the banner only fires when a genuine
prompt snapshot (totalTokens) is available.

Made-with: Cursor
2026-03-21 11:16:32 -05:00
..