Google ADK for Java 1.0: New Architecture, External Tools, and Human-in-the-Loop Workflows
#AI

Google ADK for Java 1.0: New Architecture, External Tools, and Human-in-the-Loop Workflows

Backend Reporter
3 min read

Google's Agent Development Kit for Java reaches 1.0 with a new app and plugin architecture, external tools support including Google Maps and web content fetching, event compaction for context management, and native A2A protocol integration.

Google's Agent Development Kit (ADK) for Java has reached version 1.0, introducing a comprehensive set of features designed to enhance agent development, improve context management, and enable seamless integration with external tools and services.

Featured image

The release brings several architectural improvements, starting with a new app and plugin system. The App class serves as a top-level container for agentic applications, hosting the root agent, managing global configurations, and handling plugin integration. This provides a structured foundation for building complex agent systems.

Plugins extend the framework's capabilities through a base Plugin class. Out-of-the-box plugins include LoggingPlugin for structured logging of agent executions and tool calls, ContextFilterPlugin for managing the context window by filtering out older conversation turns, and GlobalInstructionPlugin for dynamically applying consistent instructions across all agents.

External Tools Integration

A significant enhancement in ADK 1.0 is the expanded support for external tools. The framework now integrates with several new services:

  • GoogleMapsTool: Provides access to Google Maps data for location-based queries and navigation
  • UrlContextTool: Fetches and summarizes web content directly, enabling agents to incorporate real-time information from the internet
  • ContainerCodeExecutor and VertexAICodeExecutor: Enable robust code execution either locally using Docker containers or in the cloud via Vertex AI
  • ComputerUseTool: Can drive web browsers or computers, though this requires Playwright integration

These tools make agents more capable of interacting with external systems and services, expanding their utility beyond conversational interfaces.

Context Engineering and Event Compaction

Managing context size is crucial for long-running agent sessions. ADK 1.0 introduces event compaction as a fundamental context engineering practice. This feature helps prevent context windows from growing beyond token limits while reducing latency and costs in extended conversations.

The event compaction API provides fine-grained control over how events are managed:

  • Configurable compaction intervals
  • Token threshold settings
  • Overlap size adjustments
  • Event retention limits
  • Customizable summarizer selection

This allows developers to balance between retaining important conversation history and maintaining optimal performance.

Human-in-the-Loop Workflows

ADK 1.0 includes built-in support for human-in-the-loop workflows, enabling agents to pause before critical actions and request approval. When an agent needs confirmation, it can access its ToolContext and call requestConfirmation(). This automatically intercepts the execution flow, pausing the LLM until human input is received.

After confirmation, ADK automatically cleans up intermediate events and explicitly injects the confirmed function call into the subsequent LLM request context. This ensures the model understands the action was approved without creating feedback loops or confusion about the agent's state.

Agent2Agent Protocol Support

The framework natively supports the Agent2Agent (A2A) protocol, enabling different agents to communicate and collaborate even across different languages or frameworks. ADK integrates the official A2A Java SDK Client, making it straightforward to participate in multi-agent ecosystems.

To expose ADK agents via the A2A Protocol, developers create an A2A AgentExecutor. This wraps ADK agents and exposes them via a JSON-RPC REST endpoint, instantly making them accessible to the wider A2A ecosystem.

Java vs Python: The ADK Debate

The release has sparked discussion about the relative merits of the Java and Python versions of ADK. When ADK for Java was first announced, Guillaume Laforge, its main contributor, clarified on Reddit that "new features, new experiments usually start in Python, and are progressively ported to Java."

Some developers have expressed concerns about Google's track record with maintaining Java libraries. Redditor Qubit99 discouraged developers from using the Java ADK over the Python version, citing maintenance concerns.

However, others point to Java's advantages. José Carlos Sancho noted on X.com that Java's type safety is a significant advantage for catching orchestration bugs early, potentially making Java agents more stable at scale than their Python counterparts.

Getting Started

ADK for Java 1.0 is available for download from GitHub. The framework provides a solid foundation for building production-ready agent applications with enterprise-grade features like structured logging, context management, and human oversight.

As agent development continues to evolve, tools like ADK that provide robust architectural patterns and integration capabilities will become increasingly important for organizations looking to deploy AI agents at scale.

Author photo

Comments

Loading comments...