No traces after adding braintrust/setup to the Gemfile
No traces after adding braintrust/setup to the Gemfile
Verify that your app loads Bundler before application code:Rails applications do this during boot. Add it explicitly for Sinatra, Rack, and custom Ruby processes that do not load Bundler before application code.You can also require the setup file directly from an application initializer:
No traces from a short-lived script
No traces from a short-lived script
For scripts that exit immediately after an AI call, force OpenTelemetry to flush before the process exits:
braintrust/setup also registers an exit hook by default. If BRAINTRUST_FLUSH_ON_EXIT=false is set, remove that setting or flush manually.An integration is not being auto-instrumented
An integration is not being auto-instrumented
Confirm that the provider gem is installed and loaded in the process. Auto-instrumentation only patches integrations that are available when setup runs.You can instrument a provider explicitly after requiring it:If you use integration filters, check
BRAINTRUST_INSTRUMENT_ONLY, BRAINTRUST_INSTRUMENT_EXCEPT, braintrust exec --only, and braintrust exec --except.Traces are written to the wrong project
Traces are written to the wrong project
Set the default project in the environment:Or pass it when initializing the SDK:
Debug setup and API errors
Debug setup and API errors
Enable SDK debug logging:The SDK logs setup failures, auto-instrumentation decisions, and API request errors to help identify missing API keys, login failures, or provider loading issues.
Set a pass threshold for a score
Set a pass threshold for a score
The Ruby SDK doesn’t support the For EU organizations, set
__pass_threshold scorer metadata that the TypeScript and Python SDKs use. To set a threshold without the UI, create a scorer function with the threshold in its metadata through POST /v1/function. Set name to the score name your Ruby scorer returns. Braintrust matches the score to the scorer by name or slug and marks each score in the experiment view as passing or failing.BRAINTRUST_API_URL to https://api-eu.braintrust.dev.