758 B
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 theif (isThinkingChunk)block. - This ensures every single character generated by the AI contributes to the counter and drives the speedometer.
Verification
- Restart App (Option 5).
- Generate Text: Ask "Write a poem".
- Observe:
Charsshould rapidly increase.Speed(cps) should show a number > 0.- The activity should be visible immediately.