From 7c0a916c5d61f99991f632591aa6929a67a5d77e Mon Sep 17 00:00:00 2001 From: MOVZX Date: Sun, 4 Oct 2026 07:33:26 -0400 Subject: [PATCH] recoverssm: --use-replayssm without MTP falls back to the stock GDN path On Qwen4Exp the flag selects RecoverSSM, which needs speculative decoding. With num_speculative_tokens=0 the validator refused to start; it now logs a warning, clears use_replayssm (the no-flag path) and continues, so one launch line serves with and without MTP. Other architectures keep the error. Config tests cover both. Co-Authored-By: Hinata Signed-off-by: MOVZX --- vllm/config/vllm.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/vllm/config/vllm.py b/vllm/config/vllm.py index afd6361bb9..bc569031c0 100644 --- a/vllm/config/vllm.py +++ b/vllm/config/vllm.py @@ -3530,11 +3530,17 @@ class VllmConfig: and not self.cache_config.use_recoverssm ): # Qwen4Exp's GDN and PLE layers have no plain ReplaySSM path; with them the - # flag selects RecoverSSM, which needs speculative decoding. - raise ValueError( - "--use-replayssm on Qwen4Exp selects GDN RecoverSSM and requires " - "speculative decoding (num_speculative_tokens > 0)" + # flag selects RecoverSSM, which needs speculative decoding. Fork (v2.5): + # without speculative decoding there are no drafts to recover from, so the + # flag falls back to the stock path (as if it were not passed) instead of + # refusing to start; one launch line then serves with and without MTP. + logger.warning( + "--use-replayssm on Qwen4Exp selects GDN RecoverSSM, which needs " + "speculative decoding; num_speculative_tokens=0, so the stock GDN " + "path is used (as without --use-replayssm)" ) + self.cache_config.use_replayssm = False + return self if ( self.mamba_config.backend == MambaBackendEnum.FLASHINFER and self.cache_config.replayssm_buffer_len > 16