BaseAgent
Base class for all agents.
Implements the Template Method pattern to handle the agent execution lifecycle, including context creation, tracing, and callbacks. Subclasses must implement runAsyncImpl to define specific behavior.
Inheritors
Constructors
Properties
List of callbacks to run after the agent executes.
List of callbacks to run before the agent executes.
The description of the agent.
When true, the framework will not route the next user turn back to this agent after the parent transfers control to it; instead the next turn falls back to the root agent. Set this on utility sub-agents the parent calls and returns from (translators, summarizers, classifiers). Leave at the default false for sub-agents that should keep handling follow-up turns directly (e.g. billing, support).
When true, prevents this agent from transferring sideways to a peer agent under the same parent. Typically set together with disallowTransferToParent on one-shot utility agents. Violations are surfaced by the runner as IllegalArgumentException.