BrowserStack AI Evals
Tracing

Filtering

Filter and search traces and sessions in BrowserStack AI Evals by name, user ID, session ID, model, tags, metadata, environment, and date range.

Filtering

Both the Traces and Sessions lists under Logs support a range of filter controls to help you find what you need quickly. You can combine multiple filters, save them as named views, and share filter URLs with teammates.

Available Filters

FilterDescription
NameFilter by trace name (substring match)
User IDFilter by the user ID set on the trace
Session IDFilter by the session ID set on the trace
Custom IDFilter by the custom ID attached to the trace. See Custom trace IDs for how to set one from the SDK.
ModelFilter traces (or sessions) that used a specific model. Matches against all model names used in any observation within the trace.
TagsFilter traces that have all of the specified tags
MetadataFilter by any custom metadata key-value pair attached to the trace
EnvironmentFilter by environment label (e.g., production, staging, development)
Date rangeFilter traces created within a specific time window
ScoresFilter traces by score value

Using Filters

Open Logs in the left sidebar.

Click Filters (or the filter icon) at the top of the trace list to expand the filter panel.

Select or type a value for any filter. Filters are applied immediately as you type.

To filter by metadata, click Filter and select Metadata in Column, then enter the metadata key and value. You can add multiple metadata filters.

To filter by date range, click the Date filter and select a preset (Last hour, Last 24 hours, Last 7 days, Last 30 days) or choose a custom range from the calendar picker.

Active filters are shown as chips in the filter panel. Click the × on any chip to remove that filter.

Saved Table Views

Save the current filters — along with your column layout, sort order, and search — as a named view so you can return to it without re-entering the criteria.

Set up the filters (and columns, sort, or search) you want to keep.

Click Save as next to the Views button, give the view a name, and click Save View.

Click the Views button to open your saved views and click any view to apply it. With a view applied, use Save to update it or Reset to discard your changes.

To rename or delete a view, open the Views list, click the menu on a view, and choose Edit or Delete.

Sharing Filtered Views

The URL in your browser updates whenever you apply filters. Copy the URL to share the exact filtered view with a teammate — they will see the same filters applied when they open the link.

SQL Filter Tab

The filter panel includes a SQL tab where you can express filters as SQL-style predicates instead of using the Basic builder. You type only the predicate itself — the body of a WHERE clause, without the WHERE keyword — for example:

name = 'checkout' AND user_id IN ('alice', 'bob')

On the Traces (and Sessions) list, predicates can be combined with both AND and OR. Filters entered in the SQL tab round-trip to the Basic builder, so you can switch between the two views without losing your criteria.

Operators by column type

Which operators are valid depends on the column's type:

Column typeValid operatorsNotes
String (Name, User ID, Session ID, Custom ID, Environment, Level, ID)=, !=, IN (...), NOT IN (...), LIKE, NOT LIKE, IS NULL, IS NOT NULLLIKE patterns map to substring operators: %x% → contains, x% → starts with, %x → ends with, x → equals. NOT LIKE %x% → does not contain.
Number=, >, <, >=, <=No != — inequality is not supported on numeric columns.
Datetime (timestamp / created-at columns)>, <, >=, <=No = / != — only range comparisons.
Boolean=, !=
Array (model, tags, observation_name, observation_type)=, !=, IN (...), NOT IN (...)See "any of" / "none of" below. There is no SQL form for "all of".
Enum / Status=, !=, IN (...), NOT IN (...)Matched as "any of" / "none of"; values are case-insensitive.

For array and enum columns, = and IN (...) match rows where any value satisfies the condition ("any of"); != and NOT IN (...) match rows where none does ("none of"). On Traces, the array columns match against all observations within a trace. Array columns can hold more than one value per row. For example, a single trace can use several models across its observations, so its model column is a list. Enum columns like status work the same way for matching.

For these columns:

  • = and IN (...) keep a row if at least one of its values matches ("any of"). So model = 'gpt-4o' returns every trace that used gpt-4o in any observation.
  • != and NOT IN (...) keep a row only if none of its values match ("none of"). So model != 'gpt-4o' returns traces that never used gpt-4o.

Array columns (Traces)

ColumnExample predicates
model= 'gpt-4o', IN ('gpt-4o', 'claude-3-5-sonnet'), != 'gpt-4o', NOT IN (...)
tags= 'production', IN (...), != '...', NOT IN (...)
observation_name= '...', IN (...), != '...', NOT IN (...)
observation_type= 'GENERATION', IN (...), != '...', NOT IN (...)

Keyed columns — metadata and scores

Metadata and score columns are key-value, so they require a ->>'key' accessor naming the key to filter on:

ColumnAccessor exampleValid operators
metadatametadata->>'tier' = 'gold'=, !=, LIKE, NOT LIKE, NOT IN (...)
Scores (numeric)scores_avg->>'helpfulness' >= 0.8=, >, <, >=, <=
Scores (categorical)score_categories->>'sentiment' IN ('positive', 'neutral')= / IN (...) → any of, != / NOT IN (...) → none of
Scores (text)score_text->>'note' LIKE '%timeout%'=, !=, LIKE, NOT LIKE, NOT IN (...)

Nest into a JSON object with a dotted key, e.g. metadata->>'request.region'.

Filtering in Sessions

The Sessions list supports the same filters as the Traces list, including date range, session ID, model, tags, and observation type/name. Individual session detail views inherit the date range filter from the sessions list.