I have a multi-agent system in which I’ve set up most agents to use other agents as tools. I stream processing the run, and print status updates as the run proceeds based on events being streamed back. However, when the run goes more than one agent-as-a-tool deep, it appears no events are streamed back. I’m wondering if there is a way to get those events?
Here’s a simplified example. Suppose there is a Triage agent, and agents A, B, and C. The Triage agent has a handoff to agents A and B. Agent A can also use agent B as a tool. Agent B can use Agent C as a tool. So in summary:
- Triage agent → handoff to A or B
- A → tool use to B
- B → tool use to C
If I prompt the Triage agent with a task that agent B fulfills, I can see events for the Triage agent, agent B, and the tool calls that agent B makes to agent C. As a result I can log a reasonably accurate series of events.
If I prompt the Triage agent with a task agent A handles, I can see events for the Triage agent, agent A, and the tool calls agent A makes to agent B. However, if agent B makes any tool calls to agent C, I do not get any tool call or other events made by agent B to agent C in the streamed response. I tried without streaming and it appears to be the same.
My question is: is there any way to make either agent B’s tool call events to agent C show up in the stream, or is there a way to directly access those events somehow (e.g., use the call_id to get more info)?