From agno-framework
Integrate Agno agents with observability platforms, A2A protocol, and external services. Covers OpenTelemetry, Langfuse, Arize Phoenix, Agent-to-Agent protocol, and Discord bots. Trigger this skill when: adding observability to agents, setting up tracing, integrating with Langfuse or similar platforms, or asking "how do I monitor my agents?"
How this skill is triggered — by the user, by Claude, or both
Slash command
/agno-framework:agno-integrationsThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Connect agents to observability platforms, external services, and other agent systems. Install with `pip install agno`.
Connect agents to observability platforms, external services, and other agent systems. Install with pip install agno.
import os
from opentelemetry import trace
from opentelemetry.sdk.trace import TracerProvider
from opentelemetry.exporter.otlp.proto.http.trace_exporter import OTLPSpanExporter
from opentelemetry.sdk.trace.export import SimpleSpanProcessor
from openinference.instrumentation.agno import AgnoInstrumentor
# Configure Langfuse OTLP endpoint
os.environ["OTEL_EXPORTER_OTLP_ENDPOINT"] = "https://cloud.langfuse.com/api/public/otel"
os.environ["OTEL_EXPORTER_OTLP_HEADERS"] = (
f"Authorization=Basic {os.environ['LANGFUSE_AUTH']}"
)
# Set up tracing
provider = TracerProvider()
provider.add_span_processor(
SimpleSpanProcessor(OTLPSpanExporter())
)
trace.set_tracer_provider(provider)
# Instrument Agno
AgnoInstrumentor().instrument()
# Now all agent runs are automatically traced
from agno.agent import Agent
agent = Agent(
model="openai:gpt-4o",
markdown=True,
)
agent.print_response("Hello!", stream=True)
from opentelemetry import trace
from opentelemetry.sdk.trace import TracerProvider
from opentelemetry.exporter.otlp.proto.grpc.trace_exporter import OTLPSpanExporter
from opentelemetry.sdk.trace.export import SimpleSpanProcessor
from openinference.instrumentation.agno import AgnoInstrumentor
provider = TracerProvider()
provider.add_span_processor(
SimpleSpanProcessor(
OTLPSpanExporter(endpoint="http://localhost:6006/v1/traces")
)
)
trace.set_tracer_provider(provider)
AgnoInstrumentor().instrument()
pip install "agno[opentelemetry]"
pip install openinference-instrumentation-agno
pip install opentelemetry-exporter-otlp
Agno supports the A2A protocol for inter-agent communication across systems:
from agno.agent import Agent
from agno.tools.a2a import A2ATools
# Connect to a remote A2A-compatible agent
agent = Agent(
model="openai:gpt-4o",
tools=[A2ATools(url="http://remote-agent:8000/a2a")],
instructions=["Use the remote agent for specialized tasks."],
)
agent.print_response("Ask the remote agent to analyze this data.", stream=True)
Connect to MCP servers for external tool access:
from agno.agent import Agent
from agno.tools.mcp import MCPTools
agent = Agent(
model="openai:gpt-4o",
tools=[MCPTools(url="http://localhost:3000/mcp")],
)
agent.print_response("Use the MCP tools to help me.", stream=True)
from agno.agent import Agent
from agno.tools.slack import SlackTools
agent = Agent(
model="openai:gpt-4o",
tools=[SlackTools()],
instructions=["Help manage Slack messages and channels."],
)
from agno.agent import Agent
from agno.tools.github import GithubTools
agent = Agent(
model="openai:gpt-4o",
tools=[GithubTools()],
instructions=["Help manage GitHub issues and PRs."],
)
from agno.agent import Agent
from agno.tools.gmail import GmailTools
agent = Agent(
model="openai:gpt-4o",
tools=[GmailTools()],
instructions=["Help manage emails."],
)
Log agent events programmatically:
from agno.agent import Agent
def on_run_complete(run_response):
print(f"Run {run_response.run_id} completed")
if run_response.metrics:
print(f" Tokens: {run_response.metrics.total_tokens}")
print(f" Duration: {run_response.metrics.time_to_first_token}s")
agent = Agent(
model="openai:gpt-4o",
markdown=True,
)
response = agent.run("Hello!")
on_run_complete(response)
AgnoInstrumentor().instrument() — it must be called before agent runsagno[opentelemetry] is required for tracingFor advanced observability patterns and integration guides, read references/api-patterns.md.
npx claudepluginhub ajshedivy/agno-cookbook --plugin agno-frameworkDesigns observability for multi-agent systems with per-agent metrics, aggregate stats, agent cards, and event streams to monitor execution, track costs, log activities, and debug workflows.
Agent-to-Agent (A2A) protocol implementation patterns for Google ADK - exposing agents via A2A, consuming external agents, multi-agent communication, and protocol configuration. Use when building multi-agent systems, implementing A2A protocol, exposing agents as services, consuming remote agents, configuring agent cards, or when user mentions A2A, agent-to-agent, multi-agent collaboration, remote agents, or agent orchestration.