Skip to main content
TraceLoop OpenLLMetry is an observability framework for LLM applications. Braintrust integrates with TraceLoop via OpenTelemetry to capture LLM calls, workflows, and application traces.

Setup

This integration uses Braintrust’s Python SDK OpenTelemetry configuration. Install Traceloop alongside the Braintrust SDK with OpenTelemetry support and the OpenAI client:
Configure your environment variables:
.env
When setting the bearer token, encode the space between “Bearer” and your API key using %20.

Trace with TraceLoop

Initialize TraceLoop and your traces will automatically be sent to the Braintrust project specified in the x-bt-parent header:
traceloop_braintrust.py

Resources