Repository navigation
[Misc] Add AR and diffusion MoE backend acceptance tests - #9061
shunwendongan wants to merge 2 commits into
Conversation
Signed-off-by: wu kui <wukui1030660585@163.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
This PR appears to belong to: docs/design/module/diffusion/index.md. Module owners: @david6666666 @Isotr0py @princepride Routing: @david6666666 via module named in the PR description; @Isotr0py via module named in the PR description; @princepride via module named in the PR description @shunwendongan, please review your own changes and leave a short self-review comment describing what you checked. PRs without author self-review may not be assigned a reviewer. Please take a look when you have a chance. If you would like an automated review, mention @vllm-omni-review-bot in a comment. |
|
Self-review: I checked the four changed test files and verified that the AR test exercises deploy-selected linear, attention, and MoE implementations by a real worker with scheduler-visible prefill/decode events. The diffusion test follows deploy configuration into the native Triton MoE forward and compares the output with an independent reference. The PR does not modify production code, CI configuration, model checkpoints, or public defaults. Local GPU, CPU, static checks, and the GitHub build/pre-commit checks are documented in the PR description. |
Add AR and diffusion MoE backend acceptance tests
Contributor intent
What outcome do i want to achieve?
Complete the AR MoE and Diffusion MoE acceptance tests requested by the
maintainer after #8092
and submit them as an independent follow-up contribution.
What is the highest-leverage variable for that outcome? I think
Executable coverage of deploy-selected backend routing: real worker startup,
scheduler-visible prefill/decode, and actual linear, attention, and MoE
implementations rather than configuration-only assertions.
How will this work move that variable?
Add a local tiny random-weight Qwen3 MoE deploy test that starts a real Omni
AR stage and serves a token-ID request, plus a native SenseNova-U1 MoE block
test that follows deploy configuration into the real Triton expert forward
and compares it with an independent expert-loop reference.
Whose customer or user needs does this address, and what are those needs?
It addresses vLLM-Omni maintainers and users who need deploy backend choices
to reach the intended runtime implementation and to catch routing or
prefill/decode regressions before model-specific deployment work.
Purpose
This is the MoE follow-up to the dense FLUX runtime coverage in
#9051. It adds coverage
for the two MoE follow-up targets from the #8092 maintainer feedback. The
deploy/YAML propagation fixes and dense FLUX tests remain in #9051; this
independent branch changes tests only.
This change adds executable runtime coverage for:
decode;
worker; and
selection.
After this change:
tests/engine/test_backend_runtime.pycreates a local tinyQwen3MoeForCausalLMconfig, usesload_format: dummy, starts a realAsyncOmniRunnerworker, sends 17 prompt token IDs, and verifies four outputtokens plus scheduler-computed prefill/decode events and implementation
probes;
tests/engine/backend_runtime_worker.pysupplies a test-only worker classthat adapts only the stock model's Omni metadata signature and observes the
real backend calls;
tests/helpers/runtime.pyadds a tokenizer-free token-ID request helper forthis acceptance test; and
tests/diffusion/models/sensenova_u1/test_sensenova_u1_moe_cuda.pydrivesthe existing native SenseNova-U1 MoE block from a deploy-selected
VllmConfig, observes the real router GEMM and MoE-kernelapplycalls,verifies that the selected expert implementation is
TritonExperts, andchecks an independent FP32 expert-loop reference.
No production code, CI YAML, model checkpoint, tokenizer, or new runtime
dependency is added. The tests use random tiny weights and establish runtime
and numerical wiring only; they make no trained-model quality, image-quality,
throughput, latency, or performance claim. The diffusion test is a native MoE
block forward test, not a complete SenseNova pipeline startup/request test.
Design documents and user guides are unchanged because the tests exercise
existing configuration projection, AR scheduling, and native diffusion model
contracts without changing production behavior, public options, or defaults.
The one-token prefill-tail assertion follows the existing computed-token
phase rule; it does not introduce a new scheduler policy.
Test Plan
vLLM Version:
0.31.0vLLM-Omni Commit:
8174297afc59ea2060547ea3b705cd0a0630924c(base:abff966489bd8011009d84d828417ce0c55af872)Hardware: WSL2 Ubuntu 24.04.4, NVIDIA GeForce RTX 3080 10 GiB, compute
capability 8.6, driver 616.56, CUDA runtime 13.0, Python 3.12.3.
Packages: PyTorch
2.13.0+cu130, Triton3.7.1, Transformers5.14.1,pytest
9.1.1.Environment policy: existing
/home/shunwendongan/codex-work/vllm-omni-backend-runtime/venvand HF cache only;
HF_HUB_OFFLINE=1andTRANSFORMERS_OFFLINE=1were set.No new model or package was downloaded.
Test Result
GPU acceptance tests on the current branch:
Commands:
The passing AR test asserts
default_unquantized_gemm,TritonAttentionImpl.forward,TritonExperts.apply, a spawned worker PID, finite hidden states, four outputtokens, and scheduler events
(0,16,prefill),(16,1,prefill),(17,1,decode),(18,1,decode),(19,1,decode).The diffusion log records one router GEMM call and one MoE-kernel
applycall with
TritonExpertsselected, withrelative error
0.004687030799686909against the independent reference and0.7783500552177429after swapping gate/up weights.CPU and static checks:
CPU command:
The CPU summary above was observed in the terminal; a separate log for that
187-test run was not retained. Both GPU final-run logs and exit codes were
retained. The AR log prints the temporary probe JSON path, not its contents;
the implementation/event claims above are checked by assertions in the passing
test. That temporary JSON is no longer available.
The repository's existing Buildkite L4 and Diffusion Model Test jobs already
collect these paths, so no CI YAML change is needed. Draft PR admission still
uses the project's normal
readylabel or maintainer trigger; this localevidence is not an assertion that GitHub/Buildkite has already run.
The monolithic pre-commit aggregate was not completed: its Linux actionlint
environment was not cached. Applicable checks were instead run using existing
cached entrypoints, without installing packages. The repository's actual
tools/pre_commit/mypy.py 3.10wrapper passed all four changed Python files inthe existing isolated lint environment with the hook's declared dependencies,
including
types-PyYAML; no error-code suppression was needed. YAML,shellcheck, markdownlint, TTS-ratchet, and Buildkite-schema hooks do not match
the four changed Python paths.
References