Core runtime already emits model_streaming events for provider reasoning:
reasoning_start, reasoning_delta, and reasoning_end. ZCode app-server maps live
reasoning_delta events to agent_thought_chunk, but the local TUI previously
used reasoning events only as a status hint and did not show any transcript
presence for thinking.
The TUI should acknowledge that the model is thinking without forcing raw reasoning content into the default transcript view. The reasoning content should be available when the user explicitly expands the thought block.
reasoning_delta.
reasoning_start alone must not create visible transcript noise.Thinking....reasoning_end or the final stream finish arrives, the placeholder
label changes to Thought.+ when collapsed and - when expanded.TUI transcript parts gain a local-only thought part:
type ThoughtTranscriptPart = {
contentCharCount: number;
status: "thinking" | "thought";
streamProjected?: boolean;
text: string;
type: "thought";
};
text is the user-expandable reasoning content. contentCharCount is retained
as cheap projection metadata for tests and future copy/status affordances.
Reasoning stays an assistant reasoning part and renders as a separate thought
block with a toggle interaction: the local TUI keeps the block collapsed by
default, and expands to show the reasoning text.
thought part on reasoning_delta.thinking to thought on reasoning_end and on stream
finish fallback.+/- markers, expanded reasoning text, and bottom
spacing.