GuidesFramework quickstartsGoogle ADK

Google ADK

The Google Agent Development Kit (ADK, the google-adk Python package) is Google’s framework for building single- and multi-agent systems on Gemini and other models. Neens ingests its traces through standard OpenTelemetry with zero Neens-specific code — you instrument ADK once at startup and point an OTLP exporter at Neens.

At a glance

LanguagePython
Instrumentationopeninference-instrumentation-google-adk (OpenInference Google ADK instrumentor — community-maintained by Arize)
EndpointPOST /v1/traces (OTLP/HTTP)
AuthAuthorization: Bearer nk_live_… agent key

Instrument your agent

Install the instrumentation

The OpenInference instrumentor wraps the ADK runner, agents, LLM calls and tools and emits them as OpenTelemetry spans.

pip install openinference-instrumentation-google-adk opentelemetry-sdk opentelemetry-exporter-otlp

This assumes you already have ADK itself installed (pip install google-adk).

Point the exporter at Neens

from openinference.instrumentation.google_adk import GoogleADKInstrumentor
from opentelemetry import trace
from opentelemetry.sdk.trace import TracerProvider
from opentelemetry.sdk.trace.export import BatchSpanProcessor
from opentelemetry.exporter.otlp.proto.http.trace_exporter import OTLPSpanExporter
 
exporter = OTLPSpanExporter(
    endpoint="https://<your-neens-host>/v1/traces",
    headers={"Authorization": "Bearer nk_live_your_key_here"},
)
 
provider = TracerProvider()
provider.add_span_processor(BatchSpanProcessor(exporter))
trace.set_tracer_provider(provider)
 
# Instrument once, before you build your agents or runner.
GoogleADKInstrumentor().instrument(tracer_provider=provider)

Run your agent

Run your agent as usual through a runner. The ADK session_id you pass to the runner is what groups the turns of one conversation:

import asyncio
 
from google.adk.agents import Agent
from google.adk.runners import InMemoryRunner
from google.genai import types
 
def get_weather(city: str) -> dict:
    """Returns the current weather for a city."""
    return {"status": "success", "report": f"It is sunny in {city}."}
 
agent = Agent(
    name="weather_agent",
    model="gemini-2.5-flash",
    instruction="Use the available tools to answer.",
    tools=[get_weather],
)
 
async def main():
    runner = InMemoryRunner(agent=agent, app_name="weather_app")
    await runner.session_service.create_session(
        app_name="weather_app", user_id="user-123", session_id="conv-42"
    )
    async for event in runner.run_async(
        user_id="user-123",
        session_id="conv-42",
        new_message=types.Content(role="user", parts=[types.Part(text="Weather in Paris?")]),
    ):
        if event.is_final_response():
            print(event.content.parts[0].text)
 
asyncio.run(main())

Spans export to Neens in the background. In a short-lived script, call provider.shutdown() before exit so the last batch is flushed.

What Neens captures

The instrumentor emits spans for each runner invocation, every agent (including sub-agents an orchestrator hands off to), every LLM call (model, token counts, prompt/response messages), and every tool call — so you see the full agent trajectory. It stamps the ADK session id on each span as session.id, so Neens groups every turn of one ADK session into one conversation automatically (see Traces & sessions).

Alternative: ADK’s built-in tracing. ADK also emits its own OpenTelemetry spans once a global tracer provider is registered (the same TracerProvider setup above, without the instrumentor). Neens reads those too — it ingests OTel-GenAI and OpenInference attributes alike — but the OpenInference instrumentor captures richer prompt/response and tool payloads, so we recommend it for consistency with the other Neens framework quickstarts.

Neens speaks standard OTLP — this is not a Neens SDK fork. Any OpenTelemetry-instrumented ADK app exports to Neens by pointing its exporter at the endpoint above, including agents deployed to Vertex AI Agent Engine or Cloud Run. See Send traces for the full attribute reference, size limits, and response codes.

Verify

Open Traces in Neens; your ADK runs appear within a few seconds. Continue to Traces & sessions.