Home/AI Agents/openai-agents-python
openai-agents-python logo

openai-agents-python

openai/openai-agents-python

A lightweight, powerful framework for multi-agent workflows

GraphCanon updated 4d · GitHub synced 4d · 39 views this month

29k stars4.5k forksLast push 4d Python MIT

Decision brief

The openai-agents-python is a Python-based framework designed to simplify the creation and management of multiple AI-driven agents in complex workflows. Given its focus on multi-agent coordination and its lightweight, no

Good fit when

  • Use openai-agents-python when you need a lightweight solution that simplifies managing multiple AI agents in a single workflow.
  • Select this framework if your project depends heavily on the integration of OpenAI models as part of the agent ecosystem.

Avoid when

  • Avoid using openai-agents-python when you require a more specialized multi-agent system that is tightly integrated with specific cloud providers beyond OpenAI.
  • Do not choose this tool if your project does not involve Python or requires agents interacting in a simplified manner without complex workflow support.
Hosting:
unknown

Observed Jul 11, 2026 · Source: enrich:decision_facts

Verify the decision

Maintenance and security

Full trust report
Maintenance
Very active (0d since push)
As of 4d
Provenance
Not a fork · Organization account
As of 4d
Security (OSV)
No lockfile
As of 1mo

Public GitHub metadata and optional OSV scans. Signals, not a guarantee. Trust methodology.

Backing

Company context for OpenAI. Display-only - separate from trust and ranking.

Company
OpenAI·GitHub org profile·1mo
Employees
4,500·Wikidata (P1128 employees)·1mo
Funding
$13,000,000,000 (2023-01)·GraphCanon curated seed (public press)·1mo
Commercial model
OSS + managed cloud·GraphCanon curated seed·1mo

Install

pip install openai-agents-python
PyPI

How it fits your stack(17)

Typed graph edges - alternatives, integrations, successors, and dependencies. Ranked by relationship type, not raw GitHub stars.

Alternative

Integrates

Relationship graph

Optional deeper exploration of typed edges and category neighbours.

Similar tools

Same-category neighbours not already linked as typed edges.

Evidence and technical details

Sourced facts, taxonomy, compatibility claims, README excerpt, and machine-readable endpoints.

Overview

Python-based framework for creating and managing multiple AI-driven agents in complex workflows.

Capability facts

Languages
python

Source: github.language+pyproject.toml · Aug 16, 2026

Categories

Graph entities

Compatibility

Sourced claims from the README excerpt - not unsourced marketing copy.

Python runtimePython

Source: README excerpt (regex_v1, Aug 16, 2026)

1. [**Agents**](https://openai.github.io/openai-agents-python/agents): LLMs configured with instructions, tools, guardrails, and handoffs
Source link

Tags

README

OpenAI Agents SDK

The OpenAI Agents SDK is a lightweight yet powerful framework for building multi-agent workflows. It is provider-agnostic, supporting the OpenAI Responses and Chat Completions APIs, as well as 100+ other LLMs.

Image of the Agents Tracing UI

[!NOTE] Looking for the JavaScript/TypeScript version? Check out Agents SDK JS/TS.

Core concepts:

  1. Agents: LLMs configured with instructions, tools, guardrails, and handoffs
  2. Sandbox agents: Agents preconfigured to work with a container to perform work over long time horizons.
  3. Realtime agents: Build powerful voice agents with gpt-realtime-2.1 and full agent features
  4. Voice agents: Build voice pipelines that combine speech-to-text, an agent workflow, and text-to-speech
  5. Agents as tools / Handoffs: Delegating to other agents for specific tasks
  6. Tools: Various Tools let agents take actions (functions, MCP, hosted tools)
  7. Guardrails: Configurable safety checks for input and output validation
  8. Human in the loop: Built-in mechanisms for involving humans across agent runs
  9. Sessions: Automatic conversation history management across agent runs
  10. Tracing: Built-in tracking of agent runs, allowing you to view, debug and optimize your workflows

Explore the examples directory to see the SDK in action, and read our documentation for more details.

Get started

To get started, set up your Python environment (Python 3.10 or newer required), and then install OpenAI Agents SDK package.

venv

python -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
pip install openai-agents

For voice support, install with the optional voice group: pip install 'openai-agents[voice]'. For Redis session support, install with the optional redis group: pip install 'openai-agents[redis]'.

uv

If you're familiar with uv, installing the package would be even easier:

uv init
uv add openai-agents

For voice support, install with the optional voice group: uv add 'openai-agents[voice]'. For Redis session support, install with the optional redis group: uv add 'openai-agents[redis]'.

Run your first agents

The SDK supports four primary ways to run agents. Set the OPENAI_API_KEY environment variable before running any of these examples.

Run a text agent

Use a text Agent for workflows that do not need a persistent realtime connection or a sandbox workspace.

from agents import Agent, Runner

agent = Agent(name="Assistant", instructions="You are a helpful assistant")

result = Runner.run_sync(agent, "Write a haiku about recursion in programming.")
print(result.final_output)

# Code within the code,
# Functions calling themselves,
# Infinite loop's dance.

(For Jupyter notebook users, see hello_world_jupyter.ipynb)

Run a sandbox agent

Use a [SandboxAgent](https:/

For agents

This page has a .md twin and JSON over the API.

Was this helpful?

Anonymous feedback helps us improve pages and translations.