Skip to Content
FrameworksGoogle ADK

Google ADK

Google’s Agent Development Kit (ADK) reaches the Agent Fabric LLM proxy through ADK’s LiteLlm model wrapper. The adapter translates the governed connection into LiteLLM’s own model-string and kwarg conventions for you.

What you get

  • A native google.adk.models.lite_llm.LiteLlm, with the proxy auth and attribution headers set.
  • The openai/ model prefix and LiteLLM kwarg names handled automatically.
  • Supported at connection_kwargs(). ADK’s LiteLlm model makes the HTTP calls itself, so correlation is per client and donkey.last_call is not populated (see Notes).

Install

pip install "donkey-kit[adk]"

Quickstart

from donkey_kit.integrations.adk import model llm = model("gpt-4o")

llm is a real google.adk.models.lite_llm.LiteLlm instance. The model string is prefixed with openai/ before it reaches LiteLLM (openai/gpt-4o), which is the prefix LiteLLM’s OpenAI-compatible route expects — you don’t add it yourself.

Three ways to construct

1. Off a shared Donkey instance:

from donkey_kit import Donkey async with Donkey.from_env() as donkey: llm = donkey.adk.model("gpt-4o")

2. Module-level factory (shortest):

from donkey_kit.integrations.adk import model llm = model("gpt-4o")

3. Governed kwargs, native constructor:

from donkey_kit import Donkey from google.adk.models.lite_llm import LiteLlm async with Donkey.from_env() as donkey: llm = LiteLlm(model="openai/gpt-4o", **donkey.adk.connection_kwargs())

Manual equivalent

from google.adk.models.lite_llm import LiteLlm llm = LiteLlm( model="openai/gpt-4o", api_base=..., # from DONKEY_LLM_PROXY_URL, no /v1 suffix api_key=..., extra_headers=..., # client_id / client_secret header pair )

LiteLLM uses api_base and extra_headers, not base_url / default_headers — connection_kwargs() already translates for you.

Notes

  • Correlation IDs are per-client, not per-run. ADK sends requests through its built-in LiteLLM model layer rather than the SDK’s shared HTTP client, so the correlation ID is set once per client instead of per donkey.run(). Every governance header is still sent on every request. The conformance suite checks this as a documented behaviour.
  • donkey.last_call is unavailable. Because the response is handled by LiteLLM, gateway identity, routing, and usage fields can’t be observed. When every adapter resolved on a Donkey is like this one, donkey.last_call reports status == LastCallStatus.UNAVAILABLE and available == False, and names the resolved adapters in surface.
  • google-adk requires litellm>=1.84 as a floor, not a ceiling — pin your own upper bound if you need one.

See the error taxonomy for how proxy rejections surface through ADK’s LiteLlm model.

Last updated on