v0.9.* agentic-runtime
The theme of V0.9 is agentic-runtime. This release focuses on ADK’s message protocol, Agent runtime control, and multi-turn runtime capabilities. While preserving the *schema.Message default path, it introduces AgenticMessage along with corresponding generic abstractions, laying the groundwork for richer model-native Agent protocols, server-side tool calls, and runtime interrupt and resume.
1. AgenticMessage and ADK Support
V0.9 introduces schema.AgenticMessage for expressing richer Agentic message structures beyond the traditional schema.Message.
AgenticMessageadopts a content block model, supporting structured fragments such as text, reasoning content, tool calls, tool results, server-side tools, MCP tools, and multimodal content.[]ContentBlockmore completely preserves block ordering from different model protocol responses; new block types also better align with structures like tool use, reasoning, and streaming metadata in protocols such as OpenAI Responses API, Claude, and Gemini.components/modelintroduces a newAgenticModelcomponent for integrating model implementations that useAgenticMessageas input/output.- ADK provides typed agent, typed event, typed runner, and typed
ChatModelAgentsupport for theAgenticMessagepath, enabling AgenticModel to participate in ADK’s Agent lifecycle.
2. ChatModelAgent Capability Enhancements
V0.9 delivers systematic enhancements to ChatModelAgent’s runtime control, model call reliability, and middleware extension points.
Cancel
- New Agent Cancel capability for externally terminating a running Agent.
- Supports safe point cancellation, recursive cancellation, cancel timeout escalation, and checkpoint persistence during cancellation.
- Interrupts occurring during cancellation are unified under cancel semantics; callers can distinguish between active cancellation and normal business failures through
CancelError.
Model Retry
- Retry has been expanded from simple error retry to
ShouldRetry(ctx, RetryContext) -> RetryDecision. - Retry decisions can read model output, reject unsatisfactory output, modify the next input, append model options, and override backoff.
Model Failover
- New Model Failover capability for switching to a backup model after a model call failure.
- Failover decisions can read the failed attempt’s output, error, original input, and attempt number, and select the next model to use.
- Supports rewriting input for backup models; also supports preferentially reusing the last successfully called model, reducing the cost of starting from the fixed primary model each time.
Middleware Enhancements
ChatModelAgentMiddlewareaddsAfterAgentfor executing cleanup logic after Agent completes successfully.- Summarization, reduction, skill, filesystem, plan-task, patch-tool-calls, and other middleware have been generified to support the
AgenticMessagepath. - Summarization middleware adds
TypedMiddleware.Summarize, consolidating synchronous summarization capability from standalone functions into the middleware. - Filesystem middleware enhances multimodal reading capabilities and adds PDF page validation.
- New
agentsmdmiddleware for loading and injectingAGENTS.md-style project instructions. ChatModelAgentStateaddsToolInfosandDeferredToolInfosas the primary path for middleware to adjust the model-visible tool set.ToolInfosrepresents tools directly visible to the current model call;DeferredToolInfosrepresents candidate tools that the model can discover on-demand through tool search mechanisms.- Tool search middleware supports three tool loading approaches: using model-native tool search capability to load from deferred tools on demand; providing a fixed-schema
ToolSearchToolper model protocol requirements, allowing the model to search deferred tools through this entry point; using Eino’s customtool_searchtool independently of model-side protocols to retrieve tools and append matches to regularToolInfos. - Compose adds
AgenticToolsNode;ToolsNodegains tool name and argument alias support.
3. TurnLoop
V0.9 introduces TurnLoop for elevating one-shot Agent runs to continuously running, externally-driven turn-level runtimes.
- Multi-turn oriented:
TurnLoopcontinuously receives external input, with each turn independently planning input, constructing Agents, and consuming events — suitable for long-lived interactive Agents. - Input merging support:
GenInputdecides at turn boundaries which inputs to consume this turn and which to keep waiting, enabling applications to implement batching, deduplication, and merging of consecutive user inputs. - Preemption support:
Pushwith preempt options atomically writes new input and requests cancellation of the current turn, allowing high-priority input to interrupt a running Agent. - Declarative checkpoint/resume support: during recovery, applications don’t need to manually restore the input queue;
TurnLoopdistinguishes between interrupted input, unhandled input, and newly arrived input after recovery — applications only need to declare how these inputs re-enter subsequent turns.