Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -657,15 +657,15 @@ class HandoffBuilder:
tool injection, and middleware — capabilities only available on ``Agent``.

Outputs:
Each agent's response surfaces as a workflow `output` event as it speaks; there is no
By default, each agent's response surfaces as a workflow `output` event as it speaks; there is no
synthetic terminal event. Consumers iterating events see per-agent ``AgentResponse`` (or
``AgentResponseUpdate`` while streaming) in conversation order. The workflow returns to
idle once the termination condition is met (or the user terminates an interactive run).

Note:
1. Agents in handoff workflows must be ``Agent`` instances and support local tool calls.
2. Because each agent's response is itself Workflow Output, handoff has no separate
"intermediate outputs" channel — every per-agent response is the primary output.
2. Use ``output_from`` and ``intermediate_output_from`` to select participants for Workflow Output
and Intermediate Output. Unselected participant outputs are hidden.
"""

def __init__(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -446,9 +446,10 @@ async def test_group_chat_intermediate_output_from_surface_as_intermediate() ->


def test_handoff_builder_designates_every_participant_as_output() -> None:
"""Handoff has no intermediate channel — every participant's reply is a primary
output. The builder must designate all participants in the workflow's
output designation so each per-agent yield surfaces as type='output'.
"""By default, every Handoff participant's reply is Workflow Output.

The builder must designate all participants so each per-agent yield
surfaces as type='output'.

Structural assertion (vs end-to-end) because Handoff agents require a full
chat-client/middleware stack that we don't want to reproduce in this contract test.
Expand Down
Loading