@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / a964e5e6c3
Fork 0

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

[Bugfix] Allow `--skip-tokenizer-init` with `echo and return_token_ids` (#26238)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>

Cyrus Leung committed Oct 5, 2025 at 13:38 UTC a964e5e6c35e8f22bd7663dcf93d1c801421a029
2 files changed +3 -2
tests/entrypoints/openai/test_token_in_token_out.py
+1 -1
@@ -54,7 +54,7 @@ async def test_token_in_token_out_and_logprobs(server):
54 prompt=token_ids,
55 max_tokens=20,
56 temperature=0,
57 - echo=False,
57 + echo=True,
58 extra_body={
59 "return_token_ids": True,
60 },
vllm/entrypoints/openai/serving_completion.py
+2 -1
@@ -691,5 +691,6 @@ class OpenAIServingCompletion(OpenAIServing):
691 truncate_prompt_tokens=request.truncate_prompt_tokens,
692 add_special_tokens=request.add_special_tokens,
693 cache_salt=request.cache_salt,
694 - needs_detokenization=bool(request.echo),
694 + needs_detokenization=bool(request.echo
695 + and not request.return_token_ids),
696 )