Support using different attention backend for draft decoding.#14843
Merged
hnyls2002 merged 11 commits intosgl-project:mainfrom Dec 19, 2025
Merged
Support using different attention backend for draft decoding.#14843hnyls2002 merged 11 commits intosgl-project:mainfrom
hnyls2002 merged 11 commits intosgl-project:mainfrom
Conversation
Allow DeepseekV3 model use EAGLE3.
Contributor
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
b8zhong
reviewed
Dec 10, 2025
Collaborator
b8zhong
left a comment
There was a problem hiding this comment.
Can this be a flag instead? Maybe --speculative-attention-backend
Collaborator
Author
|
@hnyls2002 wdyt? I was discussing with @hnyls2002 and we ended up using env var. Personally both approach sound good to me |
Collaborator
zhyncs
approved these changes
Dec 11, 2025
Collaborator
Author
|
Thanks for the review! Added a flag |
Collaborator
|
/tag-and-rerun-ci |
Collaborator
|
/tag-and-rerun-ci |
xiaobaicxy
added a commit
to xiaobaicxy/sglang
that referenced
this pull request
Dec 19, 2025
* 'main' of https://github.com/sgl-project/sglang: (136 commits) fix: unreachable error check in retraction (sgl-project#15433) [sgl-kernel] chore: update deepgemm version (sgl-project#13402) [diffusion] multi-platform: support diffusion on amd and fix encoder loading on MI325 (sgl-project#13760) [amd] Add deterministic all-reduce kernel for AMD (ROCm) (sgl-project#15340) [diffusion] refactor: refactor _build_req_from_sampling to use shallow_asdict (sgl-project#13782) Add customized sampler registration (sgl-project#15423) Update readme (sgl-project#15425) Fix Mindspore model import warning (sgl-project#15287) [Feature] Xiaomi `MiMo-V2-Flash` day0 support (sgl-project#15207) [diffusion] profiling: add bench_serving.py and VBench (sgl-project#15410) [DLLM] Fix dLLM regression (sgl-project#15371) [Deepseek V3.2] Fix Deepseek MTP in V1 mode (sgl-project#15429) chore: update CI_PERMISSIONS (sgl-project#15431) [DLLM] Add CI for diffusion LLMs (sgl-project#14723) Support using different attention backend for draft decoding. (sgl-project#14843) feat(dsv32): better error handling for DeepSeek-v3.2 encoder (sgl-project#14353) tiny fix lint on main (sgl-project#15424) multimodal: precompute hash for MultimodalDataItem (sgl-project#14354) [AMD] Clear pre-built AITER kernels and warmup to prevent segfaults and test timeouts (sgl-project#15318) [Performance] optimize NSA backend metadata computation for multi-step speculative decoding (sgl-project#14781) ...
Prozac614
pushed a commit
to Prozac614/sglang
that referenced
this pull request
Dec 23, 2025
jiaming1130
pushed a commit
to zhuyijie88/sglang
that referenced
this pull request
Dec 25, 2025
YChange01
pushed a commit
to YChange01/sglang
that referenced
this pull request
Jan 13, 2026
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.
Motivation + Modifications
Support using different attention backend for drafter decoding by setting SGLANG_DRAFT_ATTN_BACKEND or --speculative-draft-attention-backend.
e.g. Use trtllm_mla for main deepseek target model and use trtllm_mha or flashinfer for eagle heads. In local test, using trtllm_mla + trtllm_mha for drafting can provide up to 15% better TPOT than using flashinfer only.
Also allow DeepseekV3 model to use EAGLE3.
Tests
Checklist