Deterministic replay
Deterministic replay is re-running a recorded AI agent decision with the same inputs, policy version and configuration to confirm that it produces the same outcome.
Definition
Deterministic replay means re-running a recorded decision with the inputs, policy version, model output and configuration that were in force at the time, and getting the same outcome again. For an AI agent, the decision that matters most sits at the control point: the agent proposed an action, a policy evaluated it, and the result was allow, warn, require_approval or block. If an auditor can replay that evaluation and reach the same result, the record supports the claim that the control worked as described.
Replay matters because an agent's behavior is hard to reconstruct after the fact. A large language model can return a different completion for the same prompt, and the model behind an API can change version. Prompting the model again tests today's model. A faithful replay uses what was recorded. Article 12 of the EU AI Act requires high-risk AI systems to log events so that their functioning is traceable to a degree that suits their intended purpose, and replay is a practical test of whether the logs are complete.
Three parts of an agent decision can be replayed exactly, provided they were recorded: the policy evaluation (same rules, same version, same input fields), the routing of a held action to a reviewer, and any threshold or limit calculation. Model reasoning can be replayed only by reusing the recorded model output. A replay shows how the decision was reached. The tool result, payment confirmation or system receipt recorded after execution shows whether the action took place.
For replay to work, record for each action: the proposed action and its arguments, the policy version and its content hash, the input data the policy read, the model output that led to the proposal, the outcome and the rule that produced it, any human decision, and a timestamp for each step. If one item is missing, the replay becomes an approximation, and the record should say so.
In KLA, a policy version can be replayed against the tenant's recent recorded runs. Each run is re-evaluated and compared with the outcome recorded at the time, runs recorded without their decision inputs are listed as not replayed, and the replay creates no approvals or evidence records. In one of our own QA rounds on synthetic data, a draft policy replayed against 200 recorded runs compared 195, excluded 5 whose fields were masked or missing, and raised the number of approval requests from 37 to 40. We chose this design after judging hand-built test cases with many fields impractical for compliance staff.
Related Terms
Tamper-Evident Lineage
Tamper-evident lineage is an append-only record of an agent's actions and the governance decisions applied to them, whose integrity can be verified independently.
Audit Trail
A chronological record of AI system activities, decisions, and human interactions that enables traceability and accountability.
Data provenance
Data provenance is the record of where a piece of data came from, what produced it, and how it changed before it was used.
