类 AgentResultEvent

java.lang.Object
io.agentscope.core.event.AgentEvent
io.agentscope.core.event.AgentResultEvent

public class AgentResultEvent extends AgentEvent
Emitted when an agent successfully finishes processing an invocation, carrying the final result message.

This event is emitted as part of the agent event stream (both call() and streamEvents() paths) immediately before AgentEndEvent. Callers of streamEvents() can filter for this event to obtain the final Msg directly from the event stream without subscribing to the Mono<Msg> return value separately.

call() internally uses this event to extract the result from the shared buildAgentStream() core, ensuring both paths run through the same onAgent middleware chain.

  • 构造器详细资料

    • AgentResultEvent

      public AgentResultEvent(Msg result)
    • AgentResultEvent

      public AgentResultEvent(String id, String createdAt, Msg result)
  • 方法详细资料