Skip to main content

Function: reduceStreamForView()

reduceStreamForView(state, event): ReducedStreamEvent

Defined in: packages/orchestration/src/crew/crew-stream.ts:28

Reduce event onto state and say how to announce it: text that grew the open text segment is a delta naming that segment, which the viewer already has; anything else (a segment opening, a tool call) changes the state. CrewStream announces crew sessions by this rule, and a host streaming any other agent's events can use it too.

Parameters​

state​

StreamSegmentState

event​

BaleybotStreamEvent

Returns​

ReducedStreamEvent