Visitar URL original
adk-python/docs/guides at main · google/adk-python · GitHub
Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

ADK Developer Guides

This directory contains specific developer guides for the ADK Python implementation. For the official ADK documentation, visit adk.dev.

Index

A2A

  • A2aAgentExecutor - Serving an ADK agent behind an A2A server, translating incoming requests into runs and ADK events into task updates.
  • A2aRemoteAgentConfig - Controlling the outbound call a RemoteA2aAgent makes to another agent.
  • AgentCardBuilder - Deriving the agent card a client reads before sending work, from an agent or workflow you already have.
  • to_a2a - Putting an ADK agent on the network as a Starlette application that speaks the Agent2Agent protocol.

Agents

  • BaseAgent - The foundational base class for custom agents, container orchestrators, and lifecycle callbacks.
  • Context - The runtime interface for state, artifacts, memory, credentials, and dynamic execution.
  • Creating Agents with Configurations - Building and wiring multi-agent graphs from external YAML configuration files.
  • InvocationContext - The runtime dependency container and execution state for a single invocation turn.
  • LlmAgent - The primary conversational reasoning agent orchestrating models, tools, and workflows.
  • LlmAgent Single-Turn Mode - Guide on using LlmAgent in single-turn mode.
  • LlmAgent Task Mode - Guide on using LlmAgent in task mode.
  • ManagedAgent - Guide on using ManagedAgent with server-side tools.
  • RemoteA2aAgent Task Mode - Guide on using RemoteA2aAgent in task mode.

Apps

  • App - The top-level container binding a root agent to app-wide plugins and configuration.

Artifacts

  • BaseArtifactService - Storing binary payloads outside the conversation history, with versioning and user-scoped filenames.

Auth

CLI

  • ServiceRegistry - Mapping a URI scheme to a factory, so your own session, memory, or artifact store can be selected by URI.
  • get_fast_api_app - Serving every agent in a directory over ADK's HTTP API, with room for your own routes, middleware, and lifespan.

Code Executors

  • BaseCodeExecutor - Executing model-generated code safely across local, container, GKE, and managed sandbox backends.

Environment

Errors

  • ADK exceptions - The exception types ADK raises on its own behalf, and which part of the framework each one comes from.

Evaluation

  • AgentEvaluator - Measuring agent quality from inside a pytest suite by replaying recorded conversations and scoring each answer and tool call.
  • BaseEvalService and LocalEvalService - Running evaluations that return results as data rather than as a test that passed or failed.
  • Efficiency metrics - Reference-free metrics reporting what a run consumed: tool calls, model calls and tokens.
  • EvalConfig and the eval config file - The schema of the file that says which metrics score a run and how strict each one is.
  • Evaluator - The interface behind the built-in metrics, and how to score a rule that is specific to your agent.

Events

Examples

  • Example and ExampleTool - Showing the model worked input and output pairs so that it gets the shape of its own answers right.

Features

  • Feature flags - Turning behavior that is not yet stable on or off with the ADK_ENABLE and ADK_DISABLE environment variables.

Flows

Integrations

  • BigQueryToolset - Exploring and querying BigQuery, and the write_mode setting that decides what the agent may change.
  • CrewaiTool - Wrapping a CrewAI tool so an ADK agent can call it.
  • DaytonaEnvironment - Running agent code in a Daytona hosted sandbox instead of on your machine.
  • E2BEnvironment - Running agent code in an E2B hosted sandbox, and what happens when the sandbox expires.
  • FirestoreSessionService - A durable multi-process session store built on Firestore documents and transactions.
  • GCSToolset and GCSAdminToolset - Giving an agent access to Cloud Storage objects and buckets, read-only until you say otherwise.
  • LangchainTool - Wrapping a LangChain tool so an ADK agent can call it.
  • Model Armor - Screening user input and model output with Google Cloud Model Armor.
  • MongoDbToolset - Vector and hybrid search over a MongoDB database, with the query text embedded on the way through.
  • RedisSessionService - Sharing sessions across processes through Redis, including the expiry every other backend lacks.

Labs

Live

  • Live tools - Asynchronous background execution and response scheduling for Gemini Live agents.
  • CascadeLive - A live-composing model wrapping a text reasoner in speech-to-text and text-to-speech transforms.
  • LiveRequestQueue - Streaming content, realtime audio, and stream control signals to live agents.

Memory

  • BaseMemoryService - Storing finished sessions and recalling them from later conversations.

Models

  • BaseLlm and LLMRegistry - The model interface, how a model name resolves to an implementation, and how to plug in your own.
  • FallbackModel - Wrapping an ordered list of models and moving to the next one when a call fails.
  • ServiceTier - Choosing serving tiers for Interactions API calls, including deferred execution on off-peak capacity.

Optimization

  • AgentOptimizer and Sampler - Rewriting an agent's instruction automatically, scoring candidate prompts against an evaluation set and keeping the better one.

Planners

  • BasePlanner - Guiding model execution with structured planning instructions, thinking configurations, and Plan-Re-Act thought tagging.

Plugins

Runners

Security

Sessions

  • Session and BaseSessionService - The session lifecycle, state scoping, and choosing a session service.
  • State - Session state and the app:, user:, and temp: prefixes that decide what is shared and what is stored.

Skills

  • Skill, Frontmatter, and Resources - The SKILL.md file format, and the folder of instructions, reference documents, and scripts an agent pulls in only when it is relevant.
  • SkillRegistry - The interface behind a searchable catalog of skills that an agent discovers at runtime.

Telemetry

  • TelemetryConfig - What ADK puts in its OpenTelemetry traces, and whether the text of prompts and replies is copied onto exported spans.

Tools

  • FunctionTool - Wrapping Python functions and generators as agent tools with argument validation, progress streaming, and confirmation.
  • ModelConsultTool and ModelConsultContextConfig - Escalating hard decisions mid-generation to a stronger advisor model, with per-turn and session budgets.
  • Node as tool - Exposing workflows and deterministic nodes as agent tools with isolated runtime branching and resume support.
  • to_mcp_server - Expose an ADK agent as an MCP server so any MCP host can drive it as a single tool (the MCP counterpart of to_a2a).

Utils

  • inject_session_state - Substituting session state values and artifact contents into an instruction string.

Workflows

  • BaseNode - The foundational base class and configuration settings for all workflow nodes.
  • Node and @node - Wrapping functions, agents, and tools as workflow steps, overriding node settings per graph, and subclassing Node.
  • Workflow - Graph-based orchestration of complex, multi-step agent interactions.
  • Workflow Graphs - Understanding nodes, edges, and graph structures in workflows.
  • Function Nodes - Wrapping Python functions and generators as workflow nodes.
  • JoinNode - Synchronizing parallel execution paths in workflows.
  • RetryConfig - Configuring retry policies for resilient workflow nodes.
  • ParallelWorker - Processing lists of items concurrently in workflows.
  • Dynamic Nodes - Scheduling and executing nodes dynamically at runtime.