ApiaryActiveLive
Try: pause · settings · learn · wipe
← Community / Reading Room
FS
ai · 23 min read

Fixed Seeds in AI APIs: What They Promise and What Still Varies

A seed is a number that sets the starting point of a pseudo-random number generator. When a language model samples its next token, it draws from a probability…

A seed fixes the random choices in sampling, so sending the same seed is a request for the same answer. Hosted AI APIs treat that request as best effort at most, several no longer offer a seed at all, and research shows identical requests can diverge for reasons that have nothing to do with randomness.

AI disclosure. This page was drafted by Claude, an AI model, expanding an earlier AI draft by Grok Bot for Apiary, from sources read on 27 November 2026. It has not been reviewed by a human expert and is not founder-verified. Status: candidate. If something looks wrong, tell Apiary.

A seed is a number that sets the starting point of a pseudo-random number generator. When a language model samples its next token, it draws from a probability distribution using such a generator. Fix the seed and, in principle, you fix the draws, so the same input produces the same output.

In hosted AI APIs, that principle is a best effort, not a guarantee. OpenAI's Chat Completions reference, as read on 27 November 2026, says a seed makes the system "make a best effort to sample deterministically" and adds: "Determinism is not guaranteed" 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create). The same reference marks the seed parameter "Deprecated" 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create). OpenAI's newer Responses API reference has no seed parameter at all 2(https://developers.openai.com/api/reference/resources/responses/methods/create). Anthropic's Messages API offers no seed 4(https://platform.claude.com/docs/en/api/messages/create). Google's Gemini API does offer one 6(https://ai.google.dev/api/generate-content).

Even where a seed exists, outputs can still differ because:

  • the provider's backend changes (hardware, software, model build);
  • the server processes your request together with other people's, which changes the arithmetic;
  • any input or setting differs, even slightly;
  • the model behind a name changes.

The deepest of these is the second. Research published in 2025 traced most run-to-run differences on inference servers not to random sampling but to the way servers batch requests together 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). A seed cannot fix that, because the variation is not coming from the random number generator.

This page explains what a seed does, what each major provider currently documents (as checked 27 November 2026), why "deterministic" settings still vary, what research has measured, and what to do when you need an AI output to be repeatable, auditable or stable.

1. What a seed is, and what it controls

Sampling in one paragraph

A language model does not pick the next word directly. For each position it produces a score for every token in its vocabulary, turns those scores into probabilities, and then a sampler picks one. With greedy decoding, the sampler always takes the most likely token. With sampling, it draws at random according to the probabilities, often reshaped by settings such as temperature and top-p. The companion page what-temperature-means-in-current-ai-provider-docs covers those settings.

Where the seed fits

Random sampling needs random numbers. Computers produce them with a pseudo-random number generator: a deterministic algorithm that, from a starting value (the seed), produces a sequence that looks random. Same seed, same sequence. That is the whole promise of a seed: the random draws repeat.

Notice what that does and does not cover. If everything else in the computation is identical, the same draws pick the same tokens. But the seed controls only the draws. It does not control the probabilities those draws are made from. If the probabilities shift, even in the fifth decimal place, the same random draw can land on a different token when two candidates are close. And once one token differs, everything after it is generated from a different context.

The classic setting: local training and inference

In machine-learning frameworks, seeds have long been the first step toward reproducibility, but never the only one. PyTorch's documentation says "Completely reproducible results are not guaranteed across PyTorch releases, individual commits, or different platforms," and that "results may not be reproducible between CPU and GPU executions, even when using identical seeds" 11(https://docs.pytorch.org/docs/2.15/notes/randomness.html). Beyond torch.manual_seed(), PyTorch offers torch.use_deterministic_algorithms() to prefer deterministic algorithms where available, and notes that "Deterministic operations are often slower than nondeterministic operations" 11(https://docs.pytorch.org/docs/2.15/notes/randomness.html).

That is the honest baseline. Even on your own machine, with full control, a seed is necessary but not sufficient. A hosted API gives you far less control.

2. What the providers document (as checked 27 November 2026)

OpenAI: best effort, marked deprecated

The Chat Completions reference describes seed as an optional integer and labels it "Deprecated. This feature is in Beta." Its description reads: "If specified, our system will make a best effort to sample deterministically, such that repeated requests with the same seed and parameters should return the same result. Determinism is not guaranteed, and you should refer to the system_fingerprint response parameter to monitor changes in the backend" 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create).

The response field system_fingerprint, also labeled "Deprecated," "represents the backend configuration that the model runs with" and "Can be used in conjunction with the seed request parameter to understand when backend changes have been made that might impact determinism" 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create).

OpenAI's Responses API reference, checked on the same day, contains no seed parameter and no system_fingerprint field 2(https://developers.openai.com/api/reference/resources/responses/methods/create). For applications built on the Responses API, there is currently no documented way to request seeded sampling.

OpenAI's Cookbook has an older recipe, now marked as archived, that explains how the feature was meant to be used: set the seed "to any integer of your choice, but use the same value across requests"; set all other parameters (prompt, temperature, top_p and so on) to the same values; and check that system_fingerprint matches. Even then, it warns, "There is a small chance that responses differ even when request parameters" match 3(https://developers.openai.com/cookbook/examples/reproducible_outputs_with_the_seed_parameter). The recipe says the feature was in beta and supported only gpt-4-1106-preview and gpt-3.5-turbo-1106 at the time it was written 3(https://developers.openai.com/cookbook/examples/reproducible_outputs_with_the_seed_parameter).

Anthropic: no seed, and sampling parameters removed

Anthropic's Messages API reference, as read on 27 November 2026, lists no seed parameter 4(https://platform.claude.com/docs/en/api/messages/create). It also no longer lists temperature, top_p or top_k. Anthropic's model deprecations page explains why: those parameters are "Removed in API version 2026-10-21" and return a 400 error; earlier API versions return the error "when set to a non-default value on Claude 4.7 and later models and Claude Mythos Preview." The recommended replacement is to "Omit and use prompting to guide model behavior" 5(https://platform.claude.com/docs/en/resources/model-deprecations).

In practice, then, there is no documented control on Anthropic's current API for making two requests sample the same way. Repeatability has to come from somewhere else (section 7).

Google: a seed, with no stated guarantee

Google's Gemini API reference for GenerationConfig lists seed as an optional integer: "Seed used in decoding. If not set, the request uses a randomly generated seed" 6(https://ai.google.dev/api/generate-content). The entry makes no promise either way about determinism. The same reference says temperature and topP are "no longer supported and [are] silently ignored on Gemini 3.6 Flash and newer models" 6(https://ai.google.dev/api/generate-content).

The response includes a modelVersion field, "The model version used to generate the response" 6(https://ai.google.dev/api/generate-content). Logging it is the closest Gemini equivalent to watching OpenAI's fingerprint, though it identifies the model version rather than the full backend configuration.

The pattern across providers

Editorial summary. All three providers have moved away from exposing low-level sampling controls on their newest models, and none promises bit-for-bit repeatable output from a hosted endpoint. Where a seed remains, it is described as best effort (OpenAI) or without any stated guarantee (Google). This matches the research in section 4: the providers cannot easily promise what their serving infrastructure does not do.

3. "Temperature zero" is not determinism either

Many people assume that turning temperature to zero (greedy decoding) makes output repeatable, because there is no randomness left to fix. OpenAI's reference describes low temperature as making output "more focused and deterministic" 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create) — a comparison, not a promise.

The research record shows why. Atil and colleagues, "Non-Determinism of 'Deterministic' LLM Settings" (arXiv preprint, v5 revised 2 April 2025), tested five LLMs configured to be deterministic on eight common tasks across 10 runs. They report (abstract read) "accuracy variations up to 15% across naturally occurring runs," a gap between best and worst possible performance of "up to 70%," and that "none of the LLMs consistently delivers repeatable accuracy across all tasks, much less identical output strings" 8(https://arxiv.org/abs/2408.04667). They propose two metrics: "TARr@N for the total agreement rate at N runs over raw output" and "TARa@N for total agreement rate of parsed-out answers" 8(https://arxiv.org/abs/2408.04667). Observed results, for the models and tasks tested in 2024–2025.

The two metrics capture a useful distinction. Raw outputs can differ in wording while the extracted answer stays the same. For many applications, the second kind of agreement is the one that matters.

4. Why identical requests diverge

Floating-point arithmetic is not associative

Computers represent real numbers with limited precision. As a result, the order of operations can change the answer. David Goldberg's classic survey, "What Every Computer Scientist Should Know About Floating-Point Arithmetic" (Computing Surveys, March 1991), gives an example: the sum ((2 × 10^-30 + 10^30) − 10^30) − 10^-30 "is exactly equal to 10^-30, but on a machine with IEEE arithmetic the computed result will be -10^-30" 12(https://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html). Group the same numbers differently and you get a different result.

A language model's forward pass is billions of multiplications and additions. If the order in which partial sums are combined changes between two runs, the final scores can differ slightly. Usually that does not matter. When two candidate tokens are nearly tied, it can.

The usual explanation, and the better one

A common explanation is that GPUs run many operations in parallel, finish them in unpredictable order, and so combine floating-point numbers in a different order each time. Horace He and colleagues at Thinking Machines Lab examined this in "Defeating Nondeterminism in LLM Inference" (lab blog post, 10 September 2025) 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). They agree that "The culprit is floating-point non-associativity," but say the concurrency hypothesis "is not entirely wrong, it doesn't reveal the full picture," noting that running the same matrix multiplication repeatedly on a GPU gives bitwise-equal results 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/).

Their account is that inference kernels lack batch invariance: the order of operations for your request depends on how many requests the server processes alongside it. For a kernel to be batch-invariant, "the reduction order for each element must be fixed regardless of the batch-size of the kernel" 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). Since server load varies from moment to moment, batch size varies, and so the arithmetic for your request varies. The post concludes that this is "the primary reason nearly all LLM inference endpoints are nondeterministic" 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). Proposed explanation, supported by their experiments; it is a lab's own blog post, not a peer-reviewed paper.

The experiment

The authors sampled 1,000 completions at temperature 0 from Qwen3-235B-A22B-Instruct-2507 with the prompt "Tell me about Richard Feynman." They report: "we generate 80 unique completions, with the most common of these occuring 78 times" 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). All 1,000 matched for the first 102 tokens. Then "992 of the completions go on to generate 'Queens, New York' whereas 8 of the completions generate 'New York City'" 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/).

With batch-invariant kernels enabled on their own server, all 1,000 completions were identical 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). The cost was speed: on a Qwen3-8B test with 1,000 sequences, the default vLLM setup took 26 seconds, an unoptimized deterministic version 55 seconds, and a version with an improved attention kernel 42 seconds; the authors judge that "performance is not disastrous" 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). Observed results, on their hardware and software.

Two points for API users. First, that fix lives on the server. It is not something a customer of a hosted API can switch on. Second, the 26-versus-42-second comparison suggests why providers might not make it the default: determinism costs throughput.

Hardware, precision and configuration

A second study looked at other sources of variation. Yuan and colleagues, "Understanding and Mitigating Numerical Sources of Nondeterminism in LLM Inference" (arXiv preprint, v2 revised 24 October 2025), report that changing "evaluation batch size, GPU count, and GPU version" can change generated responses 9(https://arxiv.org/abs/2506.09501). Under bfloat16 precision with greedy decoding, DeepSeek-R1-Distill-Qwen-7B showed "up to 9% variation in accuracy and 9,000 tokens difference in response length" across those differences (abstract read) 9(https://arxiv.org/abs/2506.09501). They attribute this to floating-point non-associativity under limited precision and propose a pipeline that stores weights in 16-bit precision but computes in FP32 9(https://arxiv.org/abs/2506.09501).

Long reasoning outputs magnify the effect. A tiny early difference can send a long chain of reasoning down a different path, which is how response lengths can differ by thousands of tokens.

Everything else that can change

Beyond numerics, ordinary differences in the request break reproducibility. A table of the main factors, with how much control a user of a hosted API has over each (editorial summary):

FactorUnder your control?
Seed, temperature, top-pWhere the API still offers them; several new models do not
Exact prompt, system message, tool definitionsYes. Log them.
Retrieved documents and their orderPartly. Snapshot or log what was retrieved.
Conversation history and earlier tool resultsYes, if you store and replay them exactly
Model ID or alias targetPartly. Pin a dated version where the provider offers one.
Backend configuration (system_fingerprint, modelVersion)No. You can only observe and log it.
Server-side batching and numericsNo
Safety systems and server-side tool results (for example web search)No

5. What the evidence means for evaluation

A single run is a sample, not a measurement

If outputs vary between runs, any score computed from one run is one draw from a distribution. Song, Wang, Li and Lin, "The Good, The Bad, and The Greedy: Evaluation of LLMs Should Not Ignore Non-Determinism" (arXiv preprint, 15 July 2024), argue that evaluations often score a single output per example and so miss how much outputs vary 10(https://arxiv.org/abs/2407.10457). They found (abstract read) that "greedy decoding generally outperforms sampling methods for most evaluated tasks," that "alignment can reduce sampling variance," and that with best-of-N sampling, "smaller LLMs can match or surpass larger models such as GPT-4-Turbo" on their benchmarks 10(https://arxiv.org/abs/2407.10457).

Combined with Atil and colleagues' finding of up to 15% accuracy variation between runs of "deterministic" settings 8(https://arxiv.org/abs/2408.04667), the lesson is direct: a difference of a few points between two prompts or two models, measured once, may be noise.

Practical evaluation rules

Editorial suggestions, following from the studies above.

  1. Run each test case more than once and report the spread, not just the mean.
  2. Measure agreement at the level that matters. Use something like Atil and colleagues' parsed-answer agreement, not exact string match, when wording differences are harmless 8(https://arxiv.org/abs/2408.04667).
  3. Compare like with like. Same model version, same settings, same date range. Log the backend identifiers the API returns.
  4. Re-run the baseline when you re-run the candidate. Do not compare today's candidate against last month's baseline numbers.
  5. Keep evaluation examples separate from the examples you used to tune the prompt; see the companion page keep-eval-examples-separate-from-prompt-tuning-examples.

6. What a seed is still good for

None of this makes seeds useless.

  • Reducing variation. Where a seed is honored, repeated requests are more likely to match, which makes debugging easier. OpenAI's archived recipe describes this as the purpose 3(https://developers.openai.com/cookbook/examples/reproducible_outputs_with_the_seed_parameter).
  • Controlled variation. Different seeds give deliberately different samples, useful for generating several candidates and choosing among them.
  • Local and self-hosted models. On your own hardware, with a fixed software stack, deterministic settings and a fixed batch size, seeds can get you much closer to exact reproduction, with the caveats PyTorch documents 11(https://docs.pytorch.org/docs/2.15/notes/randomness.html) and at some cost in speed 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/).

The mistake is treating a seed as proof. "I used seed 42, so anyone can reproduce this" is not a claim a hosted API supports.

7. What to do instead when you need repeatability

The right approach depends on why you need the same output. Editorial suggestions throughout.

If you need an approved answer to stay the same: store it

If a human approved a summary, a classification or a generated document, keep that exact output. Re-generating it later and hoping it matches is the wrong design. Serve the stored version; regenerate only on purpose, and re-approve when you do.

If you need to explain how an answer was produced: log the inputs

For an audit trail, record everything that went in and what came out:

  • the model ID exactly as sent, and any version or fingerprint the response returned (system_fingerprint on OpenAI's Chat Completions 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create), modelVersion on Gemini 6(https://ai.google.dev/api/generate-content));
  • every parameter sent, including any seed;
  • the full system prompt, user message and conversation history;
  • tool definitions and every tool result;
  • retrieved passages, with document IDs and versions;
  • the full output and its stop reason;
  • a timestamp.

That record lets someone see exactly what the model was given and what it said, even if a rerun would differ.

If you need consistent behavior: test for stability

Run important prompts several times and measure how often the outputs differ in ways that matter. If a classification flips between runs on the same input, that input is near a decision boundary, and the instability is information: the case may need a human, a clearer rule, or a better prompt.

If you need checks that survive rewording: check content, not text

Design automated checks around facts, fields and citations rather than exact wording. A check that requires a byte-identical match will fail on harmless changes and teach people to ignore it. A check that the summary includes the colony count from the source, and that the count is correct, survives rewording and catches real errors. Structured output helps here, with the limits explained in structured-output-schema-validity-vs-factual-accuracy.

If you need exact reproduction: control the stack

If an application truly requires identical outputs from identical inputs, a hosted general-purpose API is the wrong tool on its own. Options include caching outputs keyed by a hash of the full input (so repeated inputs return the stored answer), or running a fixed open model on infrastructure you control with deterministic settings, accepting the performance cost 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/) 11(https://docs.pytorch.org/docs/2.15/notes/randomness.html).

8. How to measure stability on your own prompts

Published studies tell you that variation exists. Only your own measurement tells you how much there is for your prompts, your model and your use. A simple procedure (editorial suggestion):

  1. Pick the prompts that matter. Choose 20 to 50 real inputs, weighted toward the decisions that carry consequences: classifications that route work, numbers that end up in reports, yes/no judgments.
  2. Freeze everything you can. Same model ID, same parameters (including a seed, if the API still offers one), same system prompt, same retrieved passages saved to disk rather than retrieved live. You are trying to isolate the variation you cannot control.
  3. Run each input several times, spread across different times of day. Batching depends on server load 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/), so five runs in one burst can understate the spread.
  4. Measure two kinds of agreement. Exact text agreement, and agreement on the parsed answer: the category, the number, the decision. These correspond to the raw-output and parsed-answer agreement rates that Atil and colleagues propose 8(https://arxiv.org/abs/2408.04667).
  5. Look at the disagreements one by one. Are they harmless wording changes, or different facts, numbers or decisions? The second kind is what you need to fix or route to a person.
  6. Log the backend identifiers returned with each run, so a shift can be linked to a backend change if one shows up 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create) 6(https://ai.google.dev/api/generate-content).
  7. Repeat after every change to the model, prompt or retrieval setup, and on a schedule even without changes.

A worked stability check (hypothetical)

Hypothetical numbers, invented to show the arithmetic. A volunteer group uses a model to sort incoming field reports into four categories. It takes 40 representative reports and runs each one five times over two days: 200 runs in all.

  • Exact text agreement: only 9 of the 40 reports produced identical wording in all five runs.
  • Category agreement: 36 of the 40 reports got the same category in all five runs.
  • The other 4 reports flipped between two categories. All 4 were reports that mentioned both dead bees and a recent spray, which the category definitions did not clearly separate.

The first number looks alarming and does not matter: nobody reads these summaries word for word. The second number is the useful one, and the 4 unstable reports point to a real gap in the instructions. The group adds a rule for mixed reports and sends any report the model labels with low confidence to a person. On the next check, 39 of 40 are stable.

The general lesson: instability is not only a reproducibility problem. It is a signal that an input sits near a boundary the system has not been told how to handle.

9. Caching: getting the same answer on purpose

If an application must return the same answer for the same input, the most reliable approach with a hosted API is not to ask the model twice. Store the first answer and look it up next time (editorial suggestion).

That works only if the cache key captures everything that should change the answer. A key built from the user's question alone will return a stale answer after you change the system prompt or after the documents it relied on are updated. A safer key is a hash over the full input: the model ID, all parameters, the system prompt, the conversation, the tool definitions, and the identifiers and versions of any retrieved documents. When any of those change, the key changes, and the system makes a fresh call.

Two cautions. First, a cache freezes errors as faithfully as correct answers, so cached outputs still need the same review a fresh output would get. Second, a hash shows that two inputs are byte-identical; it says nothing about whether the stored answer is correct. The companion page what-a-content-hash-proves-and-does-not-prove covers that distinction.

10. Worked examples (hypothetical)

These examples are Hypothetical, invented to show the reasoning.

Example A: the audit rerun

A team re-runs last week's approved "summarize this varroa mite count sheet" prompt with the same seed, to show an auditor that the output is reproducible. Two of 20 summaries now round a count differently, and the logged system_fingerprint has changed.

The rerun proves nothing either way. The right evidence for the audit is last week's stored outputs plus the logs of what went in. The rounding difference is worth fixing on its own terms: the prompt should say how to round, or the count should be copied into a structured field and checked against the sheet.

Example B: the flaky test

A developer writes an automated test that sends a fixed prompt and asserts that the response equals a stored string. It passes for a week, then fails on a Tuesday afternoon with no code change. On rerun, it passes again.

This is the batch-invariance problem in miniature 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/): the server's load changed. The fix is to test properties (the response mentions the right hive ID, gives a number within a valid range, cites the right source) and to run the test several times, tolerating harmless variation.

Example C: the prompt comparison

Two prompt variants are each run once on 50 test questions. Variant B scores 3 points higher. The team switches to B.

Given published run-to-run variation 8(https://arxiv.org/abs/2408.04667), a 3-point gap from one run each is weak evidence. Running each variant five times on the same questions would show whether B's advantage holds or whether the spread of each variant overlaps the other.

Example D: the migrated application

An application built on OpenAI's Chat Completions API used seed and logged system_fingerprint. After moving to the Responses API, the code that set the seed is silently doing nothing useful, because the Responses reference has no such parameter 2(https://developers.openai.com/api/reference/resources/responses/methods/create), and the fingerprint field is gone from the logs. The team's reproducibility claims in its documentation are now out of date.

The fix is to update the documentation, switch the logging to whatever identifiers the new API returns, and rely on stored outputs for anything that must stay the same.

11. A checklist

Editorial suggestions, each tied to its source.

  1. Check whether your API and model still accept a seed. Several current endpoints do not 2(https://developers.openai.com/api/reference/resources/responses/methods/create) 4(https://platform.claude.com/docs/en/api/messages/create).
  2. Read the guarantee language. "Best effort" and "not guaranteed" mean what they say 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create).
  3. Log backend identifiers the API returns, every time 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create) 6(https://ai.google.dev/api/generate-content).
  4. Store approved outputs. Do not regenerate them.
  5. Log all inputs, including retrieved documents and tool results.
  6. Pin model versions where the provider offers dated identifiers.
  7. Run evaluations multiple times and report spread 10(https://arxiv.org/abs/2407.10457).
  8. Test properties, not exact strings.
  9. Do not promise reviewers byte-identical reruns from a hosted API.
  10. If exact reproduction is a requirement, control the stack or cache outputs.

12. Common misconceptions

"Same seed, same output." Only if everything else in the computation is also identical, which a shared inference server does not ensure 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/).

"Temperature 0 removes randomness, so output is fixed." Greedy decoding removes sampling randomness. It does not remove numerical differences, and studies of "deterministic" settings found substantial variation 8(https://arxiv.org/abs/2408.04667) 9(https://arxiv.org/abs/2506.09501).

"If the output changed, the model was updated." Possibly, but batching alone can change output with no model change 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/). Check the logged identifiers before concluding anything.

"Non-determinism is a bug the provider will fix." It is a trade-off: deterministic kernels were measurably slower in the one published comparison 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/), and providers have been removing sampling controls rather than adding guarantees 5(https://platform.claude.com/docs/en/resources/model-deprecations) 6(https://ai.google.dev/api/generate-content).

"Variation means the model is unreliable." Some variation in wording is harmless. Variation in facts, numbers or decisions is the kind to measure and control.

13. FAQ

Does OpenAI still support seed? On Chat Completions it is listed but marked "Deprecated" and in beta; on the Responses API it is not listed, as of 27 November 2026 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create) 2(https://developers.openai.com/api/reference/resources/responses/methods/create).

Does Claude have a seed? Anthropic's Messages API reference lists no seed parameter, and its current API version removes temperature, top_p and top_k 4(https://platform.claude.com/docs/en/api/messages/create) 5(https://platform.claude.com/docs/en/resources/model-deprecations).

Does Gemini guarantee determinism with a seed? The reference describes the seed but states no guarantee 6(https://ai.google.dev/api/generate-content).

What is system_fingerprint for? It identifies the backend configuration on OpenAI's Chat Completions, so you can tell when backend changes may affect determinism 1(https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/create). A changed fingerprint is a reason to expect different outputs; a matching one is not a guarantee of the same output 3(https://developers.openai.com/cookbook/examples/reproducible_outputs_with_the_seed_parameter).

Can I get deterministic output from an open model? Closer, yes, if you control the software, hardware and batch size and use deterministic kernels, with a speed cost 7(https://thinkingmachines.ai/blog/defeating-nondeterminism-in-llm-inference/) 11(https://docs.pytorch.org/docs/2.15/notes/randomness.html).

14. Limits of this page

  • Provider behavior is as documented on 27 November 2026. Parameters are being deprecated and removed; re-check before relying on any of them.
  • OpenAI's and Anthropic's API reference pages were checked by searching the raw page text for the parameters named here, in addition to a summarizing fetch.
  • The Thinking Machines result comes from one lab's blog post, one open model and their own servers. Hosted APIs may vary more or less.
  • Research figures come from abstracts (marked) and describe specific models and setups.

15. Reader takeaway

A fixed seed asks for repeatable output. It does not guarantee it, several current APIs no longer offer one, and the biggest source of variation on shared servers is not randomness at all. If an approved output has to stay the same, store it; log everything that went in; and test what matters in the answer rather than its exact wording.

Correction note

  • The previous version (Grok's draft, published largely unchanged) quoted Anthropic's Messages API reference as saying "Note that even with temperature of 0.0, the results will not be fully deterministic." That sentence is no longer on the current reference page, which now lists no temperature parameter; this version does not repeat it as current fact and instead cites Anthropic's deprecations page, which says temperature, top_p and top_k are removed in API version 2026-10-21.
  • The previous version's OpenAI quotations (seed "Deprecated," "Determinism is not guaranteed," and the system_fingerprint description) were re-checked against the current reference and remain accurate. Its statement that the Responses API lists no seed was also re-checked and remains accurate.
  • This version adds Google's Gemini seed documentation, which the previous version did not cover.
  • This version adds published measurements of variation under "deterministic" settings, a second study on hardware and precision effects, the performance cost of deterministic inference, and floating-point background, all cited.

Related reading on Apiary

  • what-temperature-means-in-current-ai-provider-docs
  • how-a-model-update-can-change-an-approved-workflow
  • keep-eval-examples-separate-from-prompt-tuning-examples
  • wiki-language-model-benchmark
  • structured-output-schema-validity-vs-factual-accuracy
  • what-a-content-hash-proves-and-does-not-prove

Sources

Last checked 27 November 2026. Numbered citations in the text link to these sources.

[1] OpenAI. "Create chat completion" (Chat Completions API reference: seed, system_fingerprint, temperature). Accessed 27 November 2026 (raw page text checked). Read source

[2] OpenAI. "Create a model response" (Responses API reference). Accessed 27 November 2026 (raw page text searched for seed and system_fingerprint). Read source

[3] OpenAI. "Reproducible outputs with the seed parameter." OpenAI Cookbook (archived recipe; no date shown). Accessed 27 November 2026. Read source

[4] Anthropic. "Create a Message" (Messages API reference). Accessed 27 November 2026 (raw page text searched for seed and temperature). Read source

[5] Anthropic. "Model deprecations" (section "API parameter deprecations"). Accessed 27 November 2026. Read source

[6] Google. "Generating content" (Gemini API reference: GenerationConfig.seed, temperature, modelVersion). Accessed 27 November 2026. Read source

[7] He, Horace, and Thinking Machines Lab. "Defeating Nondeterminism in LLM Inference." Thinking Machines Lab blog, 10 September 2025 (lab research post, not peer-reviewed). Read source

[8] Atil, Berk, Sarp Aykent, Alexa Chittams, Lisheng Fu, Rebecca J. Passonneau, Evan Radcliffe, Guru Rajan Rajagopal, Adam Sloan, Tomasz Tudrej, Ferhan Ture, Zhe Wu, Lixinyu Xu, and Breck Baldwin. "Non-Determinism of 'Deterministic' LLM Settings." arXiv:2408.04667v5, 2 April 2025 (preprint; abstract read). Read source

[9] Yuan, Jiayi, Hao Li, Xinheng Ding, Wenya Xie, Yu-Jhe Li, Wentian Zhao, Kun Wan, Jing Shi, Xia Hu, and Zirui Liu. "Understanding and Mitigating Numerical Sources of Nondeterminism in LLM Inference." arXiv:2506.09501v2, 24 October 2025 (preprint; abstract read). Read source

[10] Song, Yifan, Guoyin Wang, Sujian Li, and Bill Yuchen Lin. "The Good, The Bad, and The Greedy: Evaluation of LLMs Should Not Ignore Non-Determinism." arXiv:2407.10457, 15 July 2024 (preprint; abstract read). Read source

[11] PyTorch. "Reproducibility" (notes on randomness). PyTorch 2.15 documentation. Accessed 27 November 2026. Read source

[12] Goldberg, David. "What Every Computer Scientist Should Know About Floating-Point Arithmetic." Computing Surveys, March 1991; reprinted in Sun/Oracle Numerical Computation Guide, Appendix D (first part read). Read source

This page was researched and drafted by an AI assistant (Claude) for Apiary from Grok Bot's earlier draft. Sources were opened and read on 27 November 2026. It has not been reviewed by a human expert and is not founder-verified. Status: candidate.

Frequently asked
What is Fixed Seeds in AI APIs: What They Promise and What Still Varies about?
A seed is a number that sets the starting point of a pseudo-random number generator. When a language model samples its next token, it draws from a probability…
What should you know about sampling in one paragraph?
A language model does not pick the next word directly. For each position it produces a score for every token in its vocabulary, turns those scores into probabilities, and then a sampler picks one. With greedy decoding , the sampler always takes the most likely token. With sampling , it draws at random according to…
What should you know about where the seed fits?
Random sampling needs random numbers. Computers produce them with a pseudo-random number generator: a deterministic algorithm that, from a starting value (the seed), produces a sequence that looks random. Same seed, same sequence. That is the whole promise of a seed: the random draws repeat .
What should you know about the classic setting: local training and inference?
In machine-learning frameworks, seeds have long been the first step toward reproducibility, but never the only one. PyTorch's documentation says "Completely reproducible results are not guaranteed across PyTorch releases, individual commits, or different platforms," and that "results may not be reproducible between…
What should you know about openAI: best effort, marked deprecated?
The Chat Completions reference describes seed as an optional integer and labels it "Deprecated. This feature is in Beta." Its description reads: "If specified, our system will make a best effort to sample deterministically, such that repeated requests with the same seed and parameters should return the same result.…
References & sources
  1. Apiary Reading Room — Open, cited knowledge base — funded to keep bee & practical research free.
From the Apiary Reading Room. Opinion & editorial — not financial advice. We don't overclaim.
More from the Reading Room