Offline Evaluation
Start offline runs in Statsig Agent Experimentation to grade every version of a config against a dataset, compare versions with a baseline, and catch regressions before you ship.
An offline run grades AI output for every row of a fixed dataset of test cases, before any user sees that output. Statsig scores each row with the evaluators you choose, then reports each evaluator's score and a run score. Use offline runs to compare config versions and catch regressions before you promote a version to Live. To grade a sample of live production traffic instead, use online evaluation. To try a few prompts side by side without grading, use the Playground.
Choose where to run offline evaluation
Agent Experimentation runs offline evaluation in two places. Choose the one that matches the outputs you want to grade:
| Offline run from a config | Run on the Runs page | |
|---|---|---|
| What it grades | New outputs that each config version generates for every dataset row | Outputs you upload with the run, such as answers from your own agent |
| Use it to | Compare prompt, model, and parameter changes between versions | Grade outputs that you already have, without generating new ones |
| Where results appear | The run's page, listed on the config's Runs tab and on the Runs page | The run's page, listed on the Runs page |
Both kinds of run open the same run page, and you can compare any two finished runs on the same dataset. This page covers offline runs from a config. For runs that grade outputs you upload, go to Runs. To start a run from your own code with Eval(), go to the Node AI SDK.
Set up offline runs on a config
Every version of a config shares one set of evaluators and one dataset, so each version's run grades the same test cases in the same way. Set both on the config's Setup tab, in the Run Setup group. You need a config with at least one version. To create one, go to AI Configs.
Add evaluators
- Go to Agent Experimentation > AI Configs and open the config.
- On the Setup tab, go to the Evaluators section of the Run Setup group.
- Click Add evaluator, then choose one option:
- An evaluator from the list: Click its name. The list shows the evaluators in your company's catalog.
- Create new evaluator: Choose an evaluator type, define the evaluator in the Create evaluator drawer, and click Add evaluator.
- Click Save.
A config's Run Setup holds at most 10 evaluators. Evaluators that you create from a config join your company's catalog. For evaluator types and how to define them, go to Evaluators.
Each evaluator appears as a card. To change an evaluator without leaving the config, click Edit Evaluator on its card, which opens the Edit evaluator drawer. For details, go to Edit an evaluator from a card. The card's menu sets the evaluator's role in this config:
- Set as Critical Evaluator: Fail the run when this evaluator's score for the run is 0. For details, go to What is a critical evaluator.
- Clone Evaluator: Add a copy of the evaluator to this config.
- Remove Evaluator: Remove the evaluator from this config.
Set the run score
Each run of a config gets a run score from 0 to 1 that combines its evaluators' scores. To choose how, go to the Run Score section of the Run Setup group, between Evaluators and Dataset. Every version of the config shares this setting.
- Primary evaluator: The run score is one evaluator's score. This is the default. Click an evaluator's chip to make it the primary evaluator.
- Average: Every evaluator counts equally.
- Weighted: Enter a percentage for each evaluator. The first evaluator's weight takes the remainder, so the weights add up to 100%. Until they do, Save stays disabled with "Run score weights must add up to 100%".
In every mode, a critical evaluator that scores 0 makes the run score 0. Statsig leaves out evaluators that have no score for the run and rescales the other weights. Run scores follow the current setting, so a change also rescores past runs. Click Save to apply it.

The run score appears on each run's page, in the Live Version column of the configs list, on each version in the Start Evaluation and Create Experiment dialogs, and in the Promote to Live dialogs.
Add a dataset
- On the config's Setup tab, go to the Dataset section of the Run Setup group.
- Click Select a Dataset, then choose one option:
- Upload Dataset: Upload a CSV file as a local dataset for this config.
- Browse from Existing Datasets: Pick a global dataset.
- AI Dataset Generation: Generate test cases from a description.
- Click Save.
The button then shows the dataset name with its row count. A local dataset shows as "Custom dataset." For dataset limits, row editing, and the differences between global and local datasets, go to Add a dataset to a config.

Each dataset column is a variable that the version's prompt can reference by name, such as {{question}}. For each row, Statsig fills the variables with the row's values before it calls the model. When a column holds JSON, {{column}} inserts the whole value, and a dotted path such as {{column.items.0.name}} inserts one field. Evaluators can reference columns too, such as {{expected}}.
An offline run from a config generates its own output for each row, so its dataset doesn't need an output column.
Start an offline run
- In the config's header, click Run Evaluators.
- In the Start Evaluation dialog, select the versions to evaluate. Statsig selects every version that can run by default and lists the Live version first. Each version shows the run score of its most recent offline run. To evaluate one version, select only that version.
- Click Start Evaluation.

Statsig starts one run for each selected version and opens the first run's page. The page shows "Loading Results" and how many rows are complete, and updates itself until the run finishes. A run can take a few minutes. Statsig names each run after the config, the version, and the run number, such as Support bot | Version 2 | Run 3.
To stop a version's runs, select the version on the Setup tab and click Stop Running in the header. Statsig stops every unfinished run of that version, and each one shows "This run failed: Stopped before it finished." While the selected version has a run in progress, the Config Setup group shows "Config cannot be edited while evaluators are running." Statsig locks its fields until the run ends, but you can still edit the Run Setup group.
The Start Evaluation dialog disables a version that can't run. Hover over the version to read the reason:
- "Fill in every prompt message before evaluating this version": The version has no prompt messages, or one of them is empty.
- "Anthropic and Google models need a user message. Add one before evaluating this version": The version uses an Anthropic or Google model and has no User message.
Versions with a custom workflow skip these checks. Fix the version and save it to evaluate it.
If the config has unsaved changes, you can't select the version you're editing. When you start runs on other versions, Statsig asks you to discard the unsaved changes first. To include the edited version, save your changes before you click Run Evaluators.
Schedule daily runs
- On the config's Setup tab, go to the Schedule section of the Run Setup group.
- Next to Start offline runs, select Daily.
- Choose the hour, in your time zone, and the versions to run. Statsig selects the Live version by default.
- Click Save.
Every day at that hour, Statsig starts one run for each selected version. Statsig skips a scheduled run when your Included Credits have run out and your company has no API key for a provider that the run calls. To stop daily runs, select Manually and save.
Model calls and Included Credits
For each row, Statsig calls the version's model provider to generate the output. A version with a custom workflow calls your workflow endpoint instead. LLM as a Judge evaluators call the provider set in each evaluator's Evaluation Model. Statsig charges these model calls to your Included Credits unless your company has its own API key for the provider. For details, go to Credits and API keys.
Why Run Evaluators is disabled
Hover over the disabled button to see the reason:
| Message | Cause | Fix |
|---|---|---|
| No evaluation dataset available | The config has no saved dataset, or its dataset has no rows. | Add a dataset that has at least one row, and save. |
| No evaluators configured | The config has no evaluators. | Add an evaluator, and save. |
| Changes must be saved before starting an evaluation | The version you're editing has unsaved changes, and the config has no other version. | Save or discard your changes. |
| Changes must be saved before this version can be used | In the Start Evaluation dialog, the version you're editing has unsaved changes. | Close the dialog, save your changes, and start the run again. |
| Select at least one version | You haven't selected a version in the Start Evaluation dialog. | Select a version. |
| Included Credits have run out | Your Included Credits have run out, and your company has no API key for a provider that the run calls. | Ask an admin to add an API key for the provider in Settings > Product Configuration > General, under AI Provider API Keys. |
| Fill in every prompt message before evaluating this version | No version can run, and the selected version has no prompt messages or an empty one. | Fill in the version's messages, and save. |
| Anthropic and Google models need a user message. Add one before evaluating this version | No version can run, and the selected version uses an Anthropic or Google model without a User message. | Add a User message to the version, and save. |
Statsig also checks each run before it starts. If a check fails, Statsig doesn't start the run and shows the reason, such as "No dataset entries found" or "Empty version messages found". A run that fails after it starts shows "This run failed:" and the reason at the top of its page, and "Error" in the runs table.
Review results on the Runs tab
The config's Runs tab lists the config's offline runs, newest first, with the same columns as the Runs page. The tab opens on the Live version's runs. The rail on the left filters the runs by Version, Evaluator, Score, and Status. With one version picked, the Scores over time chart above the table shows each evaluator's mean score. When you pick more than one version, the chart becomes Scores by run, with the latest 50 finished runs. A config with no runs shows "No runs for this config yet."

Click a run to open its page.
Where config runs appear
Each config has one run group, named after the config, which Statsig creates on the config's first run. The config's runs also appear on Agent Experimentation > Runs, where the Config filter and then Version narrow the table to them. They also appear on the Runs tabs of their dataset and evaluators. Run IDs from before config runs moved to the Runs page still work, including in the Console API.
Review a single run
A run's Run tab shows these results:
- Score: The run score, from 0 to 1, which follows the config's run score setting.
- Offline evaluators chart: Each evaluator's score for the run, which is the mean of its row scores. A score above 0.66 counts as a pass.
- Results table: One row for each dataset row, with the output, the latency, and each evaluator's pass or fail chip. Filter the table with Search rows, and use Columns to show or hide dataset columns.

Click a row in the results table to open its trace. The trace drawer's Evaluators tab shows each evaluator's score, with the judge's reasoning steps for LLM as a Judge evaluators. A row without a trace opens Row Details, which shows the same scores and reasoning. The run's Setup tab shows the dataset and the evaluator versions that the run used. For everything on a run's page, go to Review a run.
To export the results table, click the Download results as CSV icon. The file includes each row's latency and tokens. For its columns, go to Export a run's results.
Compare two versions
To compare two versions, open a run of one version and click Compare. Then, after "relative to," pick a run of the other version as the Baseline. The baseline starts as the newest other finished run on the config's dataset, which can belong to any version.
The comparison shows:
- Score: Both runs' scores.
- Score change chart: For each evaluator, whether the run did Better, Worse, or showed No significant change against the baseline.
- Results table: Both runs' outputs and scores for each row. Click a row to open Compare traces, with both runs' traces side by side.

Statsig compares two runs when both have finished and both used the config's dataset. Each upload, generated dataset, or edit to the dataset starts a new dataset version. When the two runs used different dataset versions, Statsig compares the rows whose input and expected values match, and a note names both dataset versions. For details, go to Compare runs.
Critical evaluator failures
When a critical evaluator's score for a run is 0, the run's page shows the banner "This run failed due to the critical evaluator" with the evaluator's name. The run score is then 0, whatever the run score setting. For details, go to What is a critical evaluator.
Rows that fail to generate
If Statsig can't generate a row's output, for example because the model provider or workflow endpoint returns an error, the results table shows the error in place of the output. The row's evaluators show "Not graded," and its latency shows N/A. Statsig leaves the row out of evaluator scores, the run score, comparisons, and the scores in the CSV download.
An evaluator error is different from a failed row. If a Python evaluator raises an exception on a row, the row scores 0 for that evaluator. If an LLM as a Judge call fails, the row gets no score from that evaluator and stays out of its score. For details, go to Write a Python evaluator.
Find offline run traces on the AI Traces page
Each row of an offline run produces one trace in AI Traces:
- The root span has the config's name. Its child span, named
chatand the model name, such aschat gpt-6.1-terra, records the model call that generated the output. A version with a custom workflow has no child span, because your workflow endpoint makes its own model calls. To show your endpoint's spans under the root span, go to Join a workflow run's trace. - Both spans set
statsig.environmenttoeval, and the Service column showsstatsig-offline-evals. - The root span records the run, dataset, and row in
statsig.eval.run_id,statsig.eval.dataset_id, andstatsig.eval.dataset_row_id. - When a row fails to generate, its spans have an error status.
The AI Traces page lists eval spans along with your app's spans. To hide them, clear eval in the Environment filter. For details, go to Environments.
Click a span to open the trace drawer. The Evaluators tab shows each evaluator's score for the row, with the judge's reasoning for LLM as a Judge evaluators.

Statsig keeps offline run scores out of the online evaluator results on the config's Traces tab, so dataset runs don't change the scores for your production traffic. Online evaluation also skips the spans that your workflow endpoint sends to the same project when they join a row's trace, so an offline run doesn't pay for judge calls twice.
Was this helpful?
For AI agents: a documentation index is available at /llms.txt. Append .md to any page URL for markdown, or send Accept: text/markdown.