feat(rollout): support deterministic concurrent rollouts - #1611
Closed
Le8r0nJames wants to merge 1 commit into
Closed
feat(rollout): support deterministic concurrent rollouts#1611Le8r0nJames wants to merge 1 commit into
Le8r0nJames wants to merge 1 commit into
Conversation
Derive stable per-request sampling seeds for OpenAI proxy sessions and preserve canonical sample order while grouped rollouts run concurrently. Forward request seeds and deterministic-inference configuration to SGLang. Sort completed rollout tasks deterministically without shuffling, and warn when backend or rollout-staleness settings cannot provide the documented end-to-end determinism contract.
Le8r0nJames
marked this pull request as ready for review
August 17, 2026 09:47
Le8r0nJames
requested review from
HwVanICI,
fishcrap,
garrett4wade,
geshi001,
guozhihao-224,
nuzant,
rchardx and
sitabulaixizawaluduo
as code owners
August 17, 2026 09:47
Collaborator
|
Thank you for your contribution. A similar submission has already been made. Please go to another PR for review and submit your comments. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR makes OpenAI-proxy rollouts reproducible without serializing grouped
samples or limiting SGLang to one running request.
It:
and request index, while preserving explicitly supplied seeds;
sample_idxthrough grouped workflow contexts and merges concurrentsamples in canonical order;
to SGLang as
sampling_seed;selected attention backend is not documented as supported;
deterministic mode;
max_head_offpolicyness > 0, because end-to-end deterministic trainingrequires synchronous rollout generation.
The feature remains opt-in. Existing rollout behavior is unchanged when
deterministic_samplingis disabled.Related Issue
N/A — no public issue is currently linked.
Type of Change
Checklist
Contributing Guide
pre-commit run --all-files)./docs/build_all.sh)main/review-prcommand/create-prBreaking Change Details (if applicable):
N/A.
Additional Context
SGLang deterministic inference provides batch-invariant execution for the
documented
flashinfer,fa3, andtritonattention backends. AReaL stillneeds stable request seeds and canonical host-side ordering so concurrent
grouped samples remain reproducible.
For end-to-end deterministic training, users should configure:
max_head_offpolicyness=0does not serialize requests within a rollout batch.Grouped samples and prompt workflows remain concurrent; it only disables
cross-step rollout/training staleness.
Validation performed:
prompt produced identical 1,280 rollout records and bitwise-identical
non-timing training scalars;
reference exactly, confirming that deterministic task ordering and disabling
shuffle are sufficient for the validated synchronous, no-rejection path.
Automatic seed derivation currently applies to OpenAI-proxy sessions. Callers
that issue semantically concurrent sibling requests within one session should
provide explicit stable seeds if they require a fixed request-to-seed mapping.