skillfed

openinference-instrumentation-openai-agents

OpenInference OpenAI Agents Instrumentation

openinference-instrumentation-openai-agents v2.0.0 1.0M downloads/30d#4,487 on PyPI1,147
Permissive license Apache-2.0 Active released

What it is and what it does

This package automatically instruments the OpenAI Agents SDK to capture execution traces compatible with OpenTelemetry. When you run an agent, it records spans for each agent invocation, tool call, and (if using realtime audio) conversation turn with transcripts and audio URIs. The traces can be exported to observability platforms like Arize Phoenix or Arize AX for visualization and analysis.

The instrumentation wraps agent internals to intercept function calls without requiring code changes to your agent logic. It supports tool namespaces, captures LLM model names and invocation parameters, and includes optional audio redaction via environment variables for privacy-sensitive deployments. Requires Python 3.10–3.14 and openai-agents 0.11.0 or later.

Use it for:

  • Debug agent behavior by viewing the full span tree of tool calls, LLM invocations, and intermediate outputs in Phoenix.
  • Monitor production agent runs in real-time to detect failures, latency spikes, or unexpected tool execution patterns.
  • Trace realtime audio conversations to correlate user input transcripts, LLM responses, and tool invocations in a single view.
  • Redact sensitive audio or input data in traces using environment variables while preserving structural observability.
  • Export agent telemetry to Arize AX for model performance analysis and drift detection across agent deployments.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Auto-instruments OpenAI Agents SDK to emit OpenTelemetry-compatible traces for observing agent runs, tool calls, and realtime audio sessions.

Yes. The package is actively maintained, has no known vulnerabilities, and low install friction. Install it if you use OpenAI Agents and need observability into agent execution, tool calls, or realtime audio sessions. The instrumentation is automatic and non-invasive, and integrates cleanly with standard OpenTelemetry collectors.

Install

openinference-instrumentation-openai-agents on PyPI

pip

pip install openinference-instrumentation-openai-agents

uv

uv add openinference-instrumentation-openai-agents

poetry

poetry add openinference-instrumentation-openai-agents

Installing openinference-instrumentation-openai-agents

Before you install

Low friction install with active maintenance—released 7 days ago with no known vulnerabilities. Depends on standard OpenTelemetry and OpenInference libraries, all widely used.

License in practice

Apache-2.0 permissive license allows use in commercial and private projects with minimal restrictions.

Quickstart

pip install openinference-instrumentation-openai-agents

from openinference.instrumentation.openai_agents import OpenAIAgentsInstrumentor
from opentelemetry.sdk import trace as trace_sdk

tracer_provider = trace_sdk.TracerProvider()
OpenAIAgentsInstrumentor().instrument(tracer_provider=tracer_provider)

Requires openai-agents>=0.11.0 and Python >=3.10, <3.15. OPENAI_API_KEY environment variable must be set.

Verify before relying

  • Whether realtime audio tracing works without additional Phoenix or AX setup beyond the tracer provider
  • Performance overhead of instrumentation on agent execution latency
  • Compatibility with custom agent implementations or non-standard OpenAI Agents patterns

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (<3.15,>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 7 — openinference-instrumentation, openinference-semantic-conventions, opentelemetry-api, opentelemetry-instrumentation, opentelemetry-semantic-conventions, typing-extensions, wrapt
Maintenance actively maintained — 7 days since the last release
Last repo commit
First released
Downloads 1,024,178/month — #4,487 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: openinference_instrumentation_openai_agents-2.0.0-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14

Tags

openai agents tracingopentelemetry instrumentationagent observabilityllm trace collectionopenai sdk monitoringdistributed tracing agentsrealtime audio tracing
observabilityopentelemetryagent-tracing

More Monitoring packages

tqdm

Wraps any iterable to display a real-time…

copyleft · top 100 on PyPI

opentelemetry-semantic-conventions

Provides generated Python code for…

permissive · top 100 on PyPI

opentelemetry-sdk

Provides the reference implementation of the…

permissive · top 100 on PyPI

opentelemetry-api

Provides the abstract API and interfaces for…

permissive · top 100 on PyPI

opentelemetry-exporter-otlp-proto-http

Exports OpenTelemetry observability data to an…

permissive · top 1,000 on PyPI

opentelemetry-instrumentation

Provides automatic instrumentation commands and…

permissive · top 1,000 on PyPI

openinference-instrumentation-openai

Auto-instruments OpenAI Python SDK calls to…

permissive · top 5,000 on PyPI

paid-python

Paid is a Python SDK for integrating billing,…

unclear · top 15,000 on PyPI

openinference-instrumentation-crewai

Automatically instruments CrewAI agent…

permissive · top 15,000 on PyPI

openinference-instrumentation-agno

Auto-instruments Agno Agent applications to…

permissive · top 15,000 on PyPI

openinference-semantic-conventions

Defines semantic conventions and standardized…

permissive · top 5,000 on PyPI

openinference-instrumentation-claude-agent-sdk

Auto-instruments Claude Agent SDK calls to emit…

permissive · top 15,000 on PyPI

openai-agents

A framework for building multi-agent LLM…

permissive · top 1,000 on PyPI

openinference-instrumentation-google-genai

Automatically instruments Google GenAI SDK…

permissive · top 15,000 on PyPI

openinference-instrumentation-google-adk

Auto-instruments Google ADK applications to…

permissive · top 15,000 on PyPI

openinference-instrumentation-pydantic-ai

Auto-instruments PydanticAI agents to emit…

permissive · top 15,000 on PyPI

Further reading