Skip to content
Guides

OpenClaw streaming and chunking

Block replies versus preview messages, the chunker rules, coalescing, the per-channel modes, and tool-progress lines

6 min read

How a long reply reaches a chat is decided by two independent layers, and the docs open with the fact that matters most: there is no true token-delta streaming to channel messages. Block streaming emits completed blocks as the assistant produces them; preview streaming, on Telegram, Discord, Slack, Matrix, Mattermost and Teams, updates a temporary preview message while generating. Here are the controls, the chunking rules, the merging and pacing options, the preview modes and their per-channel defaults, and the tool-progress lines that keep a long turn from looking silent.

Block streaming

  • Off by default under the agent defaults; a break setting chooses between emitting as the chunker fills, on each text end, or flushing once the message ends, still chunked when the buffer exceeds the maximum.
  • A chunk setting sets minimum and maximum characters and a break preference, a coalesce setting merges streamed blocks before sending, each channel can force block streaming on or off per account, and a text chunk limit of four thousand characters is the hard cap per channel, with Discord also splitting tall replies at seventeen lines.
  • The chunk mode is length by default or newline, which splits on blank lines, paragraph boundaries, before falling back to length; the settings must use the nested spelling under a channel’s streaming key, and the doctor migrates the legacy flat keys.
  • The chunker itself: no emit until the buffer reaches the minimum unless forced, splits preferred before the maximum and forced at it, a break chain of paragraph, then newline, then sentence, then whitespace, then a hard break, and never inside a code fence, which is closed and reopened when a forced split lands there; the maximum is clamped to the channel limit.
OpenClaw has two independent streaming layers, and there is no true token-delta streaming to channel messages.

Coalescing, pacing, media

With block streaming on, consecutive chunks can be merged before sending: coalescing waits for an idle gap, caps the buffer at the maximum, holds tiny fragments until the minimum accumulates with a final flush that always sends the rest, and joins with a separator derived from the break preference; Discord, Signal and Slack default to fifteen hundred characters and a one-second idle gap. A human-delay setting adds a randomised pause between block replies after the first, off by default, natural for roughly one to two and a half seconds, or custom bounds, and it applies only to block replies. Media follows its own rules: a plugin that validates the answer before finalising keeps replies deferred until it decides, streamed media must use structured payload fields rather than text commands, media sent early is remembered so a final payload repeating the same URL does not send it twice, and exact duplicate finals are suppressed.

Preview modes

  • Four modes under a channel’s streaming key: off, partial for a single preview replaced with the latest text, block for a preview that grows in appended steps, and progress for a status preview during generation with the final answer at completion. Discord defaults to off, Telegram and Slack to progress, Mattermost and Teams to partial, and preview chunks default to two hundred and eight hundred characters with paragraph breaks.
  • Block as a preview mode does not enable channel block delivery by itself; Teams has no draft-preview block transport, so block there disables native streaming and lands as regular block delivery, and Mattermost rotates the preview between completed text and tool-activity posts. An explicit non-off preview on Discord or Telegram wins over an inherited block-streaming default unless the channel enables block replies explicitly.
  • Telegram sends a message and edits it in place, reuses the preview for the first chunk of a long final, rotates to a new message at the chunk maximum in block mode, keeps tool progress in an editable status draft in progress mode, and skips the preview when block streaming is explicitly on; Discord edits a preview too, with a quiet progress draft by default that hides intermediate tool failures and deletes the draft once the answer lands; Slack streams its native agent card in progress mode, with narration, a live plan card and the final answer in one message, and can use its native streaming API in partial mode when a reply thread exists.

OpenClaw on Telegram and OpenClaw on Slack are the two channels whose defaults put a progress draft in front of every substantial reply.

Tool-progress lines

Preview streaming can include short status lines, searching the web, reading a file, calling a tool, in the same preview message while tools run, and Codex preamble notes use the same path so a short checking-in remark streams into the draft without joining the final answer. Long-running tools emit typed progress, the web fetch tool arming a five-second timer before it says it is fetching. The lines are on by default in partial and block previews and opt-in for the progress draft’s rolling tool log, command text is hidden behind a status label unless you opt into raw, and the progress draft keeps at most eight compact lines of one hundred and twenty characters under an automatic label. OpenClaw on Discord is the channel where the quiet default matters most, and OpenClaw thinking levels covers the reasoning stream that can ride the same preview.

On Diali

On Diali the channel defaults are the upstream ones, a progress draft on Telegram and Slack and final-only on Discord, and the dashboard chat streams the reply as it is generated. Hosted OpenClaw on Diali is the assistant.

  • Blocks or a preview, never token deltas.
  • Paragraph, newline, sentence, whitespace, hard break; never inside a fence.
  • Telegram and Slack show progress by default; Discord stays quiet.
Get started

Stop reading about it, build one

Set up an agent, pick a channel, and have it working inside the app you already keep open.