chore: replace vllm-router fork with upstream release - #3250
Draft
mikasenghaas wants to merge 2 commits into
Draft
chore: replace vllm-router fork with upstream release#3250mikasenghaas wants to merge 2 commits into
mikasenghaas wants to merge 2 commits into
Conversation
Consume vllm-router from PyPI (vllm-project/router, >=0.1.15) instead of the pinned wheel from the PrimeIntellect-ai/router fork (v0.1.26). Upstream now covers everything prime-rl invokes: the consistent_hash policy, --intra-node-data-parallel-size, --vllm-pd-disaggregation, and a typed /inference/v1/generate route that preserves extra request fields. Fork-only features are dropped: the routed-experts merge for P/D disaggregation, JWT auth, and per-run usage metrics. Single-replica router replay still works - the generate route passes return_routed_experts through and forwards response bytes verbatim. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The router subprocess shared the terminal's foreground process group, so Ctrl-C SIGINTed it directly: it died before the engine drained, and the watcher thread saw the exit before the finally block marked shutdown, logging a spurious ERROR and re-signalling the process. Start the router in its own session so only inference_local owns its lifecycle: the engine drains first, then the finally block terminates the router. The watcher now also logs a zero exit as a warning - that is an external shutdown racing ours (e.g. the rl launcher SIGTERMs the whole tree, router first), not a crash. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Summary
vllm-routerfrom PyPI (vllm-project/router,>=0.1.15) instead of the pinned wheel from our PrimeIntellect-ai/router fork (v0.1.26).[tool.uv.sources]wheel URLs and theexclude-newer-packageexemption; the dependency now resolves through the normal registry path.docs/inference.mdto stop calling the router backend "our fork".inference_localterminates the router. Previously the router died instantly with the foreground group and the watcher thread logged a spuriousERROR Router exited with code 0 - shutting downplus a redundant SIGTERM. The watcher also logs a zero exit as a warning now (an external shutdown racing ours, not a crash).Upstream 0.1.15 covers everything prime-rl invokes: the
consistent_hashpolicy,--intra-node-data-parallel-size,--vllm-pd-disaggregation,--request-id-headers,--worker-startup-timeout-secs,--prometheus-port, and a typed/inference/v1/generateroute. Extra request fields (e.g.return_routed_experts) pass through via a serde-flatten catch-all, and response bytes are forwarded verbatim, so single-replica router replay keeps working.Breaking
Fork-only router features are gone with this swap:
trainer.enable_router_replay) with adisaggregateddeployment will not return merged expert traces. Single-replica replay is unaffected.Verification
Ran the reverse-text RL example end-to-end from this branch on 2 GPUs:
vllm_router_rs::server: Starting router on 0.0.0.0:8000 | mode: Regular { worker_urls: ["http://localhost:8100"] } | policy: ConsistentHash./inference/v1/generateroute: 20/20 steps, 128/128 trainable per step, 0.0% errors, reward 0.15 → 0.70.step_20.Ctrl-C shutdown, verified with a standalone
uv run inference --vllm.model Qwen/Qwen3-0.6Band SIGINT to its foreground process group:ERROR Router exited with code 0 - shutting downand re-signalled the process.Received terminate signal, starting graceful shutdown; no ERROR lines, no leftover processes.