Skip to content

[BUG] Tool-heavy runs refresh the whole UI for every message (lag/crash at high volume) #1851

Description

@daewoongoh

Problem (one or two sentences)

During tool-heavy runs, nearly every streamed message forces a full UI refresh, which causes visible lag and, at high message volume, a gray-screen / crash. The built-in debounce meant to coalesce these refreshes is effectively disabled on that path.

Context (who is affected and when)

Affects anyone running long, tool-heavy tasks (many tool calls, browser use, deep agentic loops) that stream a large number of partial messages. The more messages arrive in a short window, the worse it gets — the lag/crash that earlier work (#1078) set out to remove still occurs at high message counts.

Reproduction steps

  1. Start a run that streams many partial messages in quick succession (e.g., a tool-heavy task that produces many incremental updates).
  2. Observe how the UI behaves as messages accumulate.
  3. Increase message volume (more steps, more tool calls) and note the effect.

Expected result

Incremental, partial updates should be coalesced by the debounce so the UI only refreshes periodically, keeping long runs smooth even with many messages.

Actual result

Each partial message triggers its own full UI refresh. In one measurement, 20 messages arriving close together produced ~20 full refreshes instead of a small handful. At high message counts this causes visible lag and the gray-screen/crash behavior persists.

App Version

Zoo Code v3.84.0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions