Files
OpenQode/Documentation/implementation_plan_fix_counters.md

758 B

Fix Real-Time Counter Updates

Problem

Sidebar counters (Chars/Toks/Speed) stay at "0" or barely move because the character count update was accidentally restricted to "Thinking" chunks only. Normal text generation was ignored.

Proposed Change

In opencode-ink.mjs (Streaming Loop):

  • Move setThinkingStats(... chars + chunk.length) outside the if (isThinkingChunk) block.
  • This ensures every single character generated by the AI contributes to the counter and drives the speedometer.

Verification

  1. Restart App (Option 5).
  2. Generate Text: Ask "Write a poem".
  3. Observe:
    • Chars should rapidly increase.
    • Speed (cps) should show a number > 0.
    • The activity should be visible immediately.