Deterministic AI Runtime: Guarantees, Boundaries, and Replay
A deterministic AI runtime is an execution environment that converts probabilistic model proposals into authorized, explicit, and replay-verifiable state transitions.
That definition is deliberately narrower than “reliable AI.” It does not promise the same words from every model call. It does not prove that a plan is good. It does not turn an LLM into a pure function. The runtime’s job starts where generated intent approaches a consequential system.
The search question “what is a deterministic AI runtime?” therefore has a precise answer:
Given the same recorded inputs, policy version, runtime version, and prior state, the runtime can reconstruct why each transition was allowed or denied, identify the effects that actually occurred, and detect where replay diverges. Model variation remains inside the proposal boundary.
This is not another name for a prompt framework. It is a control architecture with a testable guarantee surface.
Determinism needs a named boundary
“Deterministic” is meaningless until the system names what must repeat.
For an AI runtime, the right boundary is not the model’s token stream. It is the path from a proposed action to a committed effect:
observation
-> model proposal
-> normalized action candidate
-> authorization decision
-> state transition
-> effect observation
-> evidence record
The model may produce two different proposals from the same prompt. That is allowed. Once a proposal crosses into the runtime, however, the runtime must apply fixed rules to a fixed artifact. The same candidate, state revision, policy revision, and runtime revision should lead to the same admission decision. If any of those inputs change, the decision is a new decision—not a replay of the old one.
Temporal’s workflow documentation provides a useful precedent. It defines deterministic workflow code in terms of producing the same workflow API calls in the same sequence for the same input, while moving API calls, LLM invocations, database queries, and other non-deterministic operations outside the replay path. A deterministic AI runtime needs the same separation, adapted to model-proposed actions rather than pretending inference itself is replay-safe.
The guarantee matrix
A useful runtime publishes both guarantees and non-guarantees.
| Surface | Runtime guarantee | Runtime does not guarantee |
|---|---|---|
| Model output | every proposal is treated as untrusted input with an identity | identical tokens, reasoning, or plan quality |
| Execution boundary | no consequential effect bypasses normalization and admission | that every integration correctly exposes all effects |
| Authorization | a decision is evaluated against explicit subject, action, resource, state, and policy versions | that the policy expresses wise business intent |
| State | accepted work follows declared transitions with preconditions | that an external system will always respond or be reversible |
| Effects | attempts and observed outcomes receive stable identities | exactly-once behavior from an endpoint that lacks idempotency or reconciliation |
| Evidence | decisions, transitions, and artifacts are linked durably | truth of evidence produced by a defective evaluator |
| Replay | the runtime can compare recomputed decisions with recorded history and identify divergence | re-executing irreversible external effects safely |
This matrix prevents a common category error: confusing deterministic governance with deterministic intelligence.
The execution boundary is a protocol
The runtime boundary is the last point at which a proposal is still data rather than authority.
Before that point, the model may draft a shell command, SQL migration, API request, patch, or deployment plan. After that point, something changes outside the model context. A serious runtime therefore refuses raw “tool calls” as sufficient execution units. It first constructs an action envelope:
{
"action_id": "act_01...",
"subject": "agent:release-reviewer",
"operation": "repository.apply_patch",
"resource": "repo:payments@rev_7c1",
"payload_digest": "sha256:...",
"expected_state": "reviewed",
"requested_transition": "reviewed -> candidate",
"policy_revision": "policy:42",
"expires_at": "2026-08-09T12:05:00Z"
}
The envelope does not prove that the patch is correct. It makes the proposed effect addressable. Canonical serialization matters here because hashes and signatures require invariant bytes; RFC 8785 defines one JSON canonicalization scheme for that purpose. Canonical bytes still do not create canonical meaning, so schema and semantic normalization must happen before hashing.
The boundary should fail closed when identity, state freshness, policy, or destination cannot be established. “The model seemed confident” is not a fallback authorization mode.
Authorization is evaluated, not remembered
Permission cannot live in a system prompt. A sentence such as “you may deploy after tests pass” is context, not an enforceable grant.
Authorization belongs to the execution path and should evaluate at least:
(subject, operation, resource, payload, current state, policy revision, time)
NIST’s Zero Trust Architecture is relevant because it rejects implicit trust based on location or ownership and treats authentication and authorization as discrete functions before access to a resource is established. An AI runtime applies the same discipline to generated action: neither a trusted model nor an earlier approval implicitly authorizes the current effect.
This produces four practical rules:
- Bind approval to an artifact. Approval of a plan does not approve a later, modified payload.
- Check current state. A valid action against revision
Amay be invalid after revisionBappears. - Expire authority. Long-lived ambient permission converts stale context into capability.
- Record denials. A denied transition is part of execution history, not disposable noise.
Authorization answers whether this exact transition may be attempted now. Validation answers whether the result satisfies its contract. They are separate decisions.
State transitions are the runtime’s unit of work
Chats produce messages. Runtimes move systems between named states.
A minimal transition model might be:
PROPOSED -> NORMALIZED -> AUTHORIZED -> DISPATCHED
-> DENIED
DISPATCHED -> SUCCEEDED | FAILED | OUTCOME_UNKNOWN
SUCCEEDED -> VERIFIED -> COMMITTED
-> REJECTED
OUTCOME_UNKNOWN is essential. A network timeout after dispatch does not prove failure; retrying blindly can duplicate a side effect. The runtime needs a reconciliation path: query by idempotency key, inspect destination state, or require an operator decision. Where the target supports compare-and-swap, idempotency keys, or transactional writes, the runtime should use them. Where it does not, the non-guarantee must remain visible.
Transitions also need preconditions. AUTHORIZED -> DISPATCHED should fail if the authorization has expired or the subject revision changed. SUCCEEDED -> VERIFIED should fail if the evaluator examined a different artifact. The runtime is deterministic when these transition rules are explicit, versioned, and evaluated from recorded state—not when it merely emits detailed logs after the fact.
Evidence is not the same as telemetry
A trace helps operators understand a run. Evidence lets another system check a claim.
OpenTelemetry defines traces and spans for causal work across services. W3C PROV defines provenance around entities, activities, agents, and derivation. Both are useful foundations, but a deterministic AI runtime needs a durable evidence graph that survives beyond sampled diagnostic telemetry.
For each consequential transition, preserve at least:
- prior-state identity and resulting-state identity;
- normalized action digest and schema version;
- policy decision, policy revision, and decision inputs;
- dispatch identity, idempotency key, and destination;
- observed result, including
OUTCOME_UNKNOWN; - evaluator identity, version, subject digest, and verdict;
- runtime and adapter versions;
- parent/child links for delegated work.
The key invariant is simple:
A claim marked
verifiedmust resolve to evaluator evidence for the exact artifact revision being claimed.
A span saying “tests passed” is not enough. The test report must identify what was tested, and that identity must match the committed result.
Replay means decision replay before effect replay
The word “replay” is often used carelessly. There are three different operations:
- Decision replay: recompute normalization, authorization, and transition decisions from recorded inputs.
- Simulation replay: run adapters against mocks or a sandbox to compare planned effects.
- Effect replay: invoke external systems again.
Only the first is a default requirement for a deterministic AI runtime. The second is valuable when the environment can be controlled. The third may be dangerous or impossible.
A replay verifier should stop at the first mismatch and report the boundary:
recorded policy: policy:42
current policy: policy:42
recorded decision: allow
recomputed decision: deny
first divergence: adapter normalization v3 -> v4
That result is more useful than claiming the whole run is “reproducible.” It shows exactly which guarantee failed. Temporal compares commands generated during replay with event history and reports nondeterminism when they do not match. AI runtimes need an equivalent check for normalized actions and policy/state decisions, while excluding live LLM calls and external effects from the deterministic replay core.
A concrete acceptance test
A product should not call itself a deterministic AI runtime only because it uses temperature zero, stores prompts, or logs tool calls. A stronger acceptance test is whether it can demonstrate all of these:
- every consequential action crosses one enforceable boundary;
- the exact candidate artifact is immutable or content-addressed before authorization;
- authorization is evaluated against current state and a named policy revision;
- state transitions have explicit preconditions and terminal outcomes;
- ambiguous external outcomes remain
unknownuntil reconciled; - evidence binds the final claim to the exact final artifact;
- replay can recompute decisions without repeating model calls or real effects;
- runtime, policy, schema, and adapter changes produce visible replay divergence;
- the system publishes its non-guarantees.
If one of these is missing, the system may still be a useful agent framework, orchestrator, or observability layer. It simply has a smaller guarantee surface.
The practical definition
A deterministic AI runtime does not remove probability from AI. It decides where probability is allowed to matter.
Exploration, drafting, ranking, and proposal generation may remain stochastic. Authority, state transitions, effect identity, and evidence cannot remain implicit. The runtime turns those surfaces into versioned decisions over named artifacts.
That is the boundary I care about: not “the model said the same thing twice,” but “the system can prove what it allowed, what changed, what it observed, and where replay stopped matching history.”
Related reading
- What Is an AI Engineering Runtime?
- Why AI Authorization Must Happen Before the Tool Call
- How to Join AI Agent Traces to Real Artifacts
- AI Agents Need an Unknown Tool Outcome State