Skip to main content
Loop is Braintrust’s AI assistant that helps you query, analyze, and understand your production logs through natural language. Use Loop to search logs semantically, generate filters, identify patterns, extract insights, and analyze individual traces without writing queries.

Open Loop

Select Loop in the bottom right corner of the Logs page to open the chat window. Loop keeps track of your queries in a queue, so you can ask multiple follow-ups while it’s running. Use the Enter key to interrupt the current operation and execute the next query in the queue. Loop is also available when viewing individual traces. Select a trace from the logs table and open it in fullscreen or in a separate page, then select Loop in the bottom right corner. Loop maintains conversation history, letting you edit and re-run earlier messages and make inline model adjustments.

Configure Loop

Select a model

Change the AI model in the dropdown at the bottom of the Loop chat window. Supported models:
  • claude-4.5-sonnet (recommended)
  • claude-4.5-haiku
  • claude-4.5-opus
  • claude-4-sonnet
  • claude-4.1-opus
  • gpt-5.1
  • gpt-5.2
Only models from organization-level AI providers are available to Loop. Administrators can configure AI providers at the organization level and select which models are available to Loop.

Toggle auto-accept

By default, Loop asks for confirmation before executing certain actions. To enable auto-accept, select settings in your Loop chat window and select Auto-accept edits.

Select data sources

Loop can access different parts of your project. Select add context and search for the data sources you want Loop to query, such as specific datasets or experiments.

Analyze logs

Select Loop in the bottom right corner of the Logs page to open the chat window. Use Loop to analyze patterns across all your logs, generate SQL filters from natural language, find similar traces semantically, create datasets from log patterns, and generate scorers based on identified issues. Example queries:
  • “What are the most common errors?”
  • “Show me traces where users were frustrated”
  • “Find requests that took longer than 60 seconds”
  • “Create a dataset from logs with errors”
  • “What user retention trends do you see?”
  • “Find common failure modes”
  • “What patterns do you see in high-latency requests?”

Generate filters

Use Loop to create SQL queries from natural language descriptions:
  1. Select Filter to open the filter editor.
  2. Switch to SQL mode.
  3. Select Generate and describe the filter you want.
Example queries:
  • “Only LLM spans”
  • “From user John Smith”
  • “Logs from the last 5 days where factuality score is less than 0.5”
  • “Traces that took longer than 60 seconds”

Find similar traces

Select rows in the logs table and use Find similar traces. Loop analyzes the selected traces to identify common traits and returns semantically similar traces. This helps you:
  • Discover patterns across different user interactions
  • Find edge cases with similar characteristics
  • Group related issues together
  • Build datasets from similar examples

Analyze individual traces

When viewing a single trace in fullscreen or a separate page, select Loop to analyze that specific trace. Loop can summarize trace execution, identify errors and performance issues, search project logs for similar patterns, and generate custom visualizations.
Ask Loop to summarize or explain what happened in a specific trace:Example queries:
  • “Summarize this trace”
  • “What are the errors that are happening in this trace?”
  • “What was the total latency and where was time spent?”
  • “Explain the tool calls that were made”
Loop on trace pages can search your project logs to find similar patterns or related issues:Example queries:
  • “Find logs where users showed frustration”
  • “Find logs where the agent failed to answer the user’s question”
  • “Are there other traces with similar errors?”
  • “Show me traces with comparable latency patterns”
Generate custom visualizations for your trace data using natural language:Example queries:
  • “Create a view that renders a list of all tools available in this trace and their outputs”
  • “Show a timeline of all LLM calls with their token counts”
Loop on trace pages has a focused set of tools optimized for single-trace analysis. For broader log analysis and dataset generation, use Loop from the main Logs page.

Generate datasets

Create datasets from your logs based on specific criteria: Generate dataset from logs Example queries:
  • “Create a dataset from the most common inputs in the logs”
  • “Generate a dataset from logs with errors”
  • “Build a dataset from high-scoring examples”

Generate scorers

Create scorers based on patterns you identify in logs: Generate scorer from logs Example queries:
  • “Generate a code-based scorer based on project logs”
  • “Write a scorer that detects the errors I just identified”
  • “Create an LLM-as-a-judge scorer for helpfulness based on these logs”

Search documentation

Ask Loop to search through Braintrust documentation for relevant information and guidance: Search docs with loop Example queries:
  • “How do I use the Braintrust SDK?”
  • “What is the difference between a prompt and a scorer?”
  • “How do I configure online scoring?”

Next steps