File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -209,12 +209,9 @@ def __post_init__(self):
209209
210210 if self .model is None and self .num_speculative_tokens is not None :
211211 # TODO(Shangming): Refactor mtp configuration logic when supporting
212- # mtp acceleration for more models besides deepseek_v3
213- if self .target_model_config and \
214- (self .target_model_config .hf_text_config .model_type \
215- == "deepseek_v3" or
216- self .target_model_config .hf_text_config .model_type in
217- ("mimo" ,"ernie4_5_moe" , "qwen3_next" )):
212+ if (self .target_model_config
213+ and self .target_model_config .hf_text_config .model_type
214+ in ("deepseek_v3" , "mimo" , "ernie4_5_moe" , "qwen3_next" )):
218215 # use the draft model from the same model:
219216 self .model = self .target_model_config .model
220217 # Align the quantization of draft model for cases such as
@@ -224,8 +221,9 @@ def __post_init__(self):
224221 elif self .method in ("ngram" , "[ngram]" ):
225222 self .model = "ngram"
226223 else :
227- raise ValueError ("num_speculative_tokens was provided without "
228- "speculative model." )
224+ raise ValueError (
225+ "num_speculative_tokens was provided but without "
226+ "speculative model." )
229227
230228 # Automatically configure the method for ngram when "model" is used
231229 # instead of "method"
You can’t perform that action at this time.
0 commit comments