Packages
The Phoenix Python SDK is distributed as three separate packages:arize-phoenix-client
The core client library for interacting with Phoenix programmatically. Use this to:- Manage projects, datasets, and experiments
- Query and annotate traces and spans
- Create and version prompts
- Run evaluations and experiments
arize-phoenix-otel
OpenTelemetry integration for automatic tracing of LLM applications. Use this to:- Enable OpenTelemetry-based instrumentation
- Auto-instrument popular frameworks (OpenAI, LangChain, LlamaIndex, etc.)
- Configure trace export to Phoenix
- Set up batching and performance optimization
arize-phoenix-evals
Evaluation framework for assessing LLM outputs. Use this to:- Run LLM-based evaluations (hallucination, relevance, toxicity, etc.)
- Create custom evaluators
- Compute metrics on datasets
- Integrate evaluations into your workflow
Installation
Install the packages you need:Quick Start
Here’s how the packages work together:Common Workflows
Development Workflow
- Instrument your app with
phoenix.otel.register()to capture traces - Run your application and generate traces automatically
- Review traces in the Phoenix UI or via the client
- Run evaluations to assess quality using
phoenix.evals - Iterate on prompts and configuration
Production Workflow
- Configure OTEL with batching for performance
- Set up continuous evaluation using the evals package
- Monitor metrics via the Phoenix UI
- Use the client for programmatic access to data
- Create datasets from production traces for testing
Environment Variables
Configure the SDK using environment variables:Phoenix server URL (default:
http://localhost:6006)API key for authentication with Phoenix Cloud
Default project name for traces (default:
default)Additional headers to send with requests (comma-separated
key:value pairs)Next Steps
Python Client
Interact with Phoenix programmatically
Python OTEL
Set up OpenTelemetry tracing
Python Evals
Evaluate LLM outputs