Arize Phoenix Documentation
Learn more about Arize Phoenix’s observability and evaluation features.
Instrumentation setup
Initialize Arize Phoenix and wrap the tracer withRestateTracerProvider to correlate AI spans with Restate’s execution journal. Here is an example of how to do it for the OpenAI Agents SDK:
__main__.py
Run the example
Run the example
Prerequisites: Arize Phoenix account and API key, OpenAI API key, Restate installed.Get the example:Add your API keys to an Start the agent service:Start Restate:Replace your-account-name with the name of your Phoenix account.Go to the Restate UI at
.env file:http://localhost:9070, register the service at http://localhost:9080, click on the handler to go to the playground, and send the default request.Other Agent SDKsThis example uses the OpenAI Agents SDK in combination with Restate and Arize Phoenix.
You can use any other AI agent framework, in a similar way by swapping out the OpenInference library for the one for your framework.
Visit the Arize Phoenix Integration docs for more details.
If you get stuck, please reach out to us via Discord or Slack.
What you see in Arize Phoenix
Once you send a request, you can inspect the trace in Arize Phoenix. You see the agentic steps (LLM calls, tool invocations) alongside regular workflow steps (e.g. currency conversion, reimbursement), with inputs, outputs, model configuration, and token usage for each LLM call. Restate manages the execution, starts the parent span, and exports the full journal as OpenTelemetry traces. The AI-specific spans and metadata get attached under Restate’s parent span.
Restate’s Tracer Provider flattens the Arize Phoenix spans to make them appear consistently structured with the Restate spans in the UI.
We are working on a next iteration of the integration which will respect the Arize Phoenix span nesting and puts the Restate spans at the right depths inside them.