Elapsed time ticks every second, tokens roll every few seconds
The line shown before the first token: animated dots, elapsed time and a rolling token count.
Time updates every second and the token count rolls to its new value. The tally lives in a ref above the indicator, so it keeps counting when the indicator remounts. The step spinner settles into a tick when its step ends.
Options for the assembled component.
TallyProvider value*RefObject<Tally>Seconds and tokens so far. Create it with useTallyRef.
StepSpinner done*booleanPlays the tick once when it turns true.
_conversation/thinking.tsxThe status line. Announced politely to screen readers.
_conversation/engine/tally.tsxShares elapsed seconds and tokens for one reply.
_shared/ui/think-dots.tsxThe animated mark.
_shared/ui/roll.tsxRolls only the characters that changed.
_shared/ui/step-spinner.tsxSpinner that draws a tick when done.
Ported from the agent-builder conversation module.
Elapsed time ticks every second, tokens roll every few seconds