Member Junction
    Preparing search index...

    Type Alias AgentExecutionStreamingCallback

    AgentExecutionStreamingCallback: (
        chunk: {
            content: string;
            isComplete: boolean;
            kind?: "final-response";
            modelName?: string;
            stepEntityId?: string;
            stepType?: "prompt" | "action" | "subagent" | "chat";
        },
    ) => void

    Callback function type for streaming content updates during agent execution

    Type Declaration

      • (
            chunk: {
                content: string;
                isComplete: boolean;
                kind?: "final-response";
                modelName?: string;
                stepEntityId?: string;
                stepType?: "prompt" | "action" | "subagent" | "chat";
            },
        ): void
      • Parameters

        • chunk: {
              content: string;
              isComplete: boolean;
              kind?: "final-response";
              modelName?: string;
              stepEntityId?: string;
              stepType?: "prompt" | "action" | "subagent" | "chat";
          }
          • content: string

            The content chunk received

          • isComplete: boolean

            Whether this is the final chunk

          • Optionalkind?: "final-response"

            Content discriminator for chat-client rendering. 'final-response' marks chunks that are deltas of the user-facing final reply — safe for the conversation client to accumulate and render into the message bubble as they arrive. Chunks WITHOUT a kind are raw prompt output (e.g. a Loop agent's streamed JSON turn envelope) and are not rendered by the conversation client. Emitters that compose the final answer as plain prose (outside the turn envelope) set this on their compose stream; future kinds (e.g. inter-turn progress narration) extend this union.

          • OptionalmodelName?: string

            Model name producing this content (for prompt steps)

          • OptionalstepEntityId?: string

            Specific step entity ID producing this content

          • OptionalstepType?: "prompt" | "action" | "subagent" | "chat"

            Which step is producing this content

        Returns void