← Docs

Replay a failing trajectory

Replay re-executes a real run against a change so you can prove a fix before it ships. You edit the suspect step, re-run it and everything after, and watch the new outcome deterministically, without touching production.

Walkthrough

1

Open the failing trajectory

From your project dashboard, filter the trajectory list to the failing runs and open the one you want to investigate. The trajectory view shows every step in sequence: model calls, tool calls, and decisions.

2

Start a replay

Click Replay on the trajectory. This opens the replay editor with the run's steps loaded in order, so you can pick the step where the reasoning turned.

3

Mutate the suspect step

Change the step that went wrong: swap the model, edit the prompt, or override a decision. Everything from that step onward will be re-executed against your change.

4

Re-execute and watch it stream

Run the replay. The replay worker re-executes the mutated step and every step after it. The new outcome streams in live, no refresh needed, so you see exactly how the run behaves under the change.

5

Compare the outcome

The replay result sits next to the original run. Read the divergence: did the new model or prompt produce the answer you wanted, or push the failure somewhere else? Because replay is deterministic on real captured input, the comparison is trustworthy.

6

Ship the fix

Once a replay proves the change works, ship it to your agent. You stop shipping hopeful prompt edits and waiting to see if they helped. On the next nightly run, the failure cluster this run belonged to shrinks.

Next: Reading the cluster dashboard - see how fixed drift stays fixed and which failure to repair first.