mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2026-06-02 05:11:18 +08:00
[Misc] Fix speculative config repr string (#15860)
Signed-off-by: Shangming Cai <caishangming@linux.alibaba.com>
This commit is contained in:
parent
79455cf421
commit
656fd72976
@ -2359,12 +2359,10 @@ class SpeculativeConfig:
|
|||||||
return self.num_speculative_tokens
|
return self.num_speculative_tokens
|
||||||
|
|
||||||
def __repr__(self) -> str:
|
def __repr__(self) -> str:
|
||||||
if self.prompt_lookup_max is not None and self.prompt_lookup_max > 0:
|
method = self.method
|
||||||
draft_model = "ngram"
|
model = None if method == "ngram" else self.draft_model_config.model
|
||||||
else:
|
|
||||||
draft_model = self.draft_model_config.model
|
|
||||||
num_spec_tokens = self.num_speculative_tokens
|
num_spec_tokens = self.num_speculative_tokens
|
||||||
return f"SpeculativeConfig({draft_model=}, {num_spec_tokens=})"
|
return f"SpeculativeConfig({method=}, {model=}, {num_spec_tokens=})"
|
||||||
|
|
||||||
|
|
||||||
@dataclass
|
@dataclass
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user