You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I traced the current A2A client flow on the main branch. A2aAgent currently exposes only hook()/hooks(). A2A client events are routed through ClientEventContext, where PreReasoningEvent, ReasoningChunkEvent, and PostReasoningEvent are dispatched to the Hook list. The MiddlewareBase/MiddlewareChain path used by ReActAgent is not involved.
To keep the change small and backward compatible, I propose an initial implementation that:
Adds MiddlewareBase configuration to A2aAgent.
Routes the remote reasoning event stream through MiddlewareBase.onReasoning().
Keeps the existing Hook API and legacy stream behavior unchanged.
Adds focused tests for event ordering and Hook compatibility.
I will not change onActing(), onModelCall(), onSystemPrompt(), or add a new streamEvents() API in this initial change unless that is required.
Could you please confirm whether this scope and the proposed compatibility approach are acceptable?
Activity
wmh123wmh1 commentedon Sep 3, 2026
Hi maintainers, I would like to work on #2612.
I traced the current A2A client flow on the main branch.
A2aAgentcurrently exposes onlyhook()/hooks(). A2A client events are routed throughClientEventContext, wherePreReasoningEvent,ReasoningChunkEvent, andPostReasoningEventare dispatched to the Hook list. TheMiddlewareBase/MiddlewareChainpath used byReActAgentis not involved.To keep the change small and backward compatible, I propose an initial implementation that:
MiddlewareBaseconfiguration toA2aAgent.MiddlewareBase.onReasoning().I will not change
onActing(),onModelCall(),onSystemPrompt(), or add a newstreamEvents()API in this initial change unless that is required.Could you please confirm whether this scope and the proposed compatibility approach are acceptable?