[Bugfix] Declare SupportsEagle3 on KimiLinearForCausalLM (#52171)
Signed-off-by: Nick Iusiumbeli <nickuspro@gmail.com>
Nick Iusiumbeli committed
Aug 13, 2026 at 19:22 UTC
83d4c6196ad90f98515c6be113cb2e957b60a832
2 files changed
+10
-1
tests/models/kimi_k3/test_eagle3.py
+9
@@ -10,6 +10,7 @@ from vllm.model_executor.models.interfaces import supports_eagle3
10
from vllm.models.kimi_k3.nvidia import model as kimi_model
11
from vllm.models.kimi_k3.nvidia.model import (
12
KimiK3ForConditionalGeneration,
13
+ KimiLinearForCausalLM,
14
KimiLinearModel,
15
)
16
@@ -25,6 +26,14 @@ def test_kimi_k3_advertises_eagle3_support():
26
assert supports_eagle3(KimiK3ForConditionalGeneration)
27
28
29
+def test_kimi_linear_advertises_eagle3_support():
30
+ # The text-only architecture serves the same inner KimiLinearModel, which
31
+ # already carries the EagleModelMixin tap machinery - only the interface
32
+ # declaration was missing, so EAGLE3-family speculative decoding (dspark)
33
+ # was rejected at startup with "Model does not support EAGLE3 interface".
34
+ assert supports_eagle3(KimiLinearForCausalLM)
35
+
36
+
37
def test_kimi_k3_uses_shared_eagle3_layer_configuration():
38
target = object.__new__(KimiK3ForConditionalGeneration)
39
torch.nn.Module.__init__(target)
vllm/models/kimi_k3/nvidia/model.py
+1
-1
@@ -1477,7 +1477,7 @@ class KimiLinearModel(nn.Module, EagleModelMixin, SupportsQuant):
1477
1478
1479
class KimiLinearForCausalLM(
1480
- nn.Module, HasInnerState, SupportsPP, MixtureOfExperts, IsHybrid
1480
+ nn.Module, HasInnerState, SupportsPP, MixtureOfExperts, IsHybrid, SupportsEagle3
1481
):
1482
def __init__(self, *, vllm_config: VllmConfig, prefix: str = ""):
1483
super().__init__()