A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 14, 05:30 UTC
[gpt-oss][Bugfix]Fix streamableparser for missing handling of certain token_ids (#24306)
Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com>
Chauncey committed
Sep 6, 2025 at 01:26 UTC
23a6c5280e93ca8796f12b18d0e1dba4f3d1331d
1 file changed
+3
-3
vllm/entrypoints/context.py
+3
-3
@@ -238,11 +238,11 @@ class StreamingHarmonyContext(HarmonyContext):
238
# (finished=True), then the next token processed will mark the
239
# beginning of a new message
240
self.first_tok_of_message = output.finished
241
- tok = output.outputs[0].token_ids[0]
242
- self.parser.process(tok)
241
+ for tok in output.outputs[0].token_ids:
242
+ self.parser.process(tok)
243
self._update_num_output_tokens(output.outputs[0].token_ids)
244
# Check if the current token is part of reasoning content
245
- self._update_num_reasoning_tokens([tok])
245
+ self._update_num_reasoning_tokens(output.outputs[0].token_ids)
246
self.last_tok = tok
247
else:
248
# Handle the case of tool output in direct message format