Repository navigation
[PyTorch-MPS] Document verified model support - #859
Conversation
994a675 to
676fdfe
Compare
676fdfe to
c6b41fa
Compare
c6b41fa to
79c1ff7
Compare
0ae344b to
67aa993
Compare
1ac6ec3 to
40c42e8
Compare
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Newly admitted model configurations can fail automatic cache sizing because the memory estimator assumes an intermediate_size field.
Review effort: Balanced
Findings: 1
Open (2)
What changed in this PR
Broadens the opt-in PyTorch MPS backend beyond Qwen3 using upstream model selection.
Changes:
- Replaces the model-name restriction with capability and attention-head checks.
- Documents verified MPS support for Qwen3, Hunyuan Dense, and OLMo 2.
| File | Description |
|---|---|
vllm_metal/pytorch_backend/worker.py |
Adds capability-based model admission checks. |
vllm_metal/envs.py |
Updates the backend comment only. |
docs/supported_models.md |
Adds MPS support columns, leaving unverified entries blank. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
Thanks! Please fix Copilot's findings: |
249e9a6 to
e8c4dfd
Compare
99a3ead to
da18035
Compare
ac9ce1e to
edd4c6e
Compare
|
Thanks! Blocked on #858 (stacked), so setting to draft. Please rebase onto main once it lands and reopen for re-review. |
|
Thanks! Blocked on #858 (stacked), so setting to draft. Please rebase onto main once it lands and reopen for re-review. |
edd4c6e to
edf8667
Compare
edf8667 to
418933b
Compare
e870c85 to
fbd5835
Compare
Signed-off-by: Ranran <ranranhaoranzhang@gmail.com>
Signed-off-by: Ranran <ranranhaoranzhang@gmail.com>
Signed-off-by: Ranran <ranranhaoranzhang@gmail.com>
ac10bfd to
5eeb73b
Compare
ricky-chaoju
left a comment
There was a problem hiding this comment.
Hunyuan on MPS needs --generation-config vllm here: its generation_config.json sets repetition_penalty 1.05, so even temperature=0 requests get a 400. Might be worth a note in the table.
|
@WindChimeRan I have an exam later today, so I'll take a look at #880 tonight. |
Signed-off-by: Ranran <ranranhaoranzhang@gmail.com>
|
Thanks! reproduced red->greed locally with the notes. @ricky-chaoju No worry on the review. Omni works will mainly depend on PR1 (already merged) |
Stacked on #859. Add opt-in MPS support for dense LFM2/LFM2.5 through upstream `Lfm2ForCausalLM` and MRv2. - Reuse vLLM's Torch ShortConv implementation through its pluggable-layer hook. - Reuse scheduler-owned state copying/clearing and the existing cache allocation. - Mark LFM support in the PyTorch MPS model column. LFM2.5-1.2B FP16 matched 24/24 CPU-reference greedy tokens; prefix reuse and chunked prefill pass. BF16 normalization rounding changed 18/512 fixed-history greedy choices versus eager (ΔNLL +0.00203). Validation: 3,857 non-slow tests passed; lint and types pass. Cache stress completed with 11 preemptions and 80 cached-prefix tokens. No new kernels or dependencies. Explicit async scheduling passes concurrent HTTP, cancellation and stop-token checks in FP16. BF16 batch/preemption rounding can change near-tied greedy choices. ## Benchmark | Model | Path | Output tok/s ↑ | Mean TTFT (ms) ↓ | Mean TPOT (ms) ↓ | | --- | --- | ---: | ---: | ---: | | LFM2.5-1.2B-Instruct | MLX | 806.8 | 255.8 | 30.7 | | | PyTorch MPS | 573.0 (-29.0%) | 549.9 | 43.1 | M5 Pro 64 GiB; stack `c517256`, vLLM 0.30 / PyTorch 2.13 / MLX 0.32.1. Same unquantized checkpoint and BF16 weights/KV per pair; greedy Sonnet 1024/128, 100 requests, 10/s, C32; context/batch limit 2048, 2,340 allocator blocks with 16-token attention blocks, prefix cache off, **async on both paths**. Two fresh-server runs per path in reversed order; identical token counts and no preemptions. Percentages are throughput changes versus MLX. --------- Signed-off-by: Ranran <ranranhaoranzhang@gmail.com>


Builds on #858, which adds verified Qwen3 support. Document verified Hunyuan Dense and OLMo2 support through upstream's
automodel selection, without model-specific attention patches like #664.Both checkpoints matched 24/24 CPU transformers reference greedy tokens.
Benchmark
M5 Pro 64 GiB; stack
c517256, vLLM 0.30 / PyTorch 2.13 / MLX 0.32.1. Same unquantized checkpoint and BF16 weights/KV per pair; greedy Sonnet 1024/128, 100 requests, 10/s, C32; context/batch limit 2048, 2,340 allocator blocks with 16-token attention blocks, prefix cache off, async on both paths. Two fresh-server runs per path in reversed order; identical token counts and no preemptions. Percentages are throughput changes versus MLX.