Skip to main content

Prerequisites

Install the Tracia SDK:
Set your API keys as environment variables:
.env
The Python SDK uses LiteLLM under the hood. LiteLLM is included as a dependency and handles all provider communication.

OpenAI

Anthropic

Google

Multi-Turn Conversations

Include previous messages to maintain conversation context:

With Tracing Metadata

Add tags and user identifiers for filtering in the Tracia dashboard:

Streaming

Enable streaming to receive responses in real-time:
See Streaming for more details.

Async Usage

Use arun_local() for async contexts:

Without Tracing

Disable tracing when you don’t need observability: