mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2026-05-06 18:17:55 +08:00
[Model] Fixed stream generator for gpt-oss + spec-decoding (#26027)
Signed-off-by: Aleksandr Samarin <astrlrd@nebius.com>
This commit is contained in:
parent
adae0c1f43
commit
73a99cc2a5
@ -691,11 +691,13 @@ class OpenAIServingChat(OpenAIServing):
|
|||||||
if self.use_harmony:
|
if self.use_harmony:
|
||||||
harmony_parser = harmony_parsers[i]
|
harmony_parser = harmony_parsers[i]
|
||||||
prev_recipient = harmony_parser.current_recipient
|
prev_recipient = harmony_parser.current_recipient
|
||||||
|
delta_text = ""
|
||||||
for token_id in output.token_ids:
|
for token_id in output.token_ids:
|
||||||
harmony_parser.process(token_id)
|
harmony_parser.process(token_id)
|
||||||
|
delta_text += (harmony_parser.last_content_delta
|
||||||
|
or "")
|
||||||
cur_channel = harmony_parser.current_channel
|
cur_channel = harmony_parser.current_channel
|
||||||
cur_recipient = harmony_parser.current_recipient
|
cur_recipient = harmony_parser.current_recipient
|
||||||
delta_text = harmony_parser.last_content_delta or ""
|
|
||||||
else:
|
else:
|
||||||
delta_text = output.text
|
delta_text = output.text
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user