QuestionQ19

VerifiedSecuring and governing agentic workflows

You are troubleshooting a hierarchical multiagent architecture built with Agent Development Kit (ADK), in which a primary orchestrator delegates complex search tasks to specialized subagents. Execution traces show that subagents append their full tool execution histories to the orchestrator’s context window across multiturn exchanges, causing rapid context window bloat, agent drift, and severe tool invocation latency. You need to isolate subagent execution history and prevent context pollution in the orchestrator.

What should you do?

Explanation

Wrapping each specialist in an AgentTool runs it in a separate nested session, so its internal tool events do not accumulate in the orchestrator’s conversation history. Setting include_contents='none' excludes prior conversation history from the specialist’s model requests. Selected findings can be returned or stored in session state for use across turns without retaining the full execution history. (github.com)

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!