[Chore] Use upstream Transformers DeepseekV4Config (#61392)
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Kevin H. Luu <khluu000@gmail.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Kevin H. Luu
parent
1c4c319792
commit
b965ee564d
@@ -37,6 +37,7 @@ from vllm.model_executor.models.llama_eagle3 import Eagle3LlamaForCausalLM
|
||||
from vllm.model_executor.models.qwen3_dflash import DFlashQwen3ForCausalLM
|
||||
from vllm.model_executor.models.qwen3_eagle3 import Eagle3Qwen3ForCausalLM
|
||||
from vllm.platforms import current_platform
|
||||
from vllm.transformers_utils.deepseek_v4_utils import get_compress_ratios
|
||||
from vllm.utils.torch_utils import PIN_MEMORY, async_tensor_h2d
|
||||
from vllm.v1.attention.backend import CommonAttentionMetadata
|
||||
from vllm.v1.attention.backends.registry import AttentionBackendEnum
|
||||
@@ -102,9 +103,7 @@ class SpecDecodeBaseProposer:
|
||||
# shape (T, hc_mult * hidden_size). Expand the hidden_states buffer
|
||||
# so target_hidden_states fits; detect DeepseekV4 via draft hf_config.
|
||||
draft_hf_config = self.draft_model_config.hf_config
|
||||
if hasattr(draft_hf_config, "compress_ratios") and hasattr(
|
||||
draft_hf_config, "hc_mult"
|
||||
):
|
||||
if get_compress_ratios(draft_hf_config) and hasattr(draft_hf_config, "hc_mult"):
|
||||
self.hidden_size = self.hidden_size * draft_hf_config.hc_mult
|
||||
|
||||
# Unifying eagle, draft model, and parallel drafting support.
|
||||
|
||||
Reference in New Issue
Block a user