[Rebase] Rebase to vllm v0.24.0 (#4709)

This commit is contained in:
Zhou Taichang authored and GitHub committed 2026-06-30 19:41:06 +08:00
1 parent 9a105bf90d
commit a560ed184d
60 files changed
+789 -203

No files matched your search

@@ -156,14 +156,19 @@ class TestPerRequestRouting:
assert torch.all(audio[0][1] == 0) # this step's row 0 appended
assert torch.all(audio[1] == 1)
def test_runs_without_spans_backward_compat(self):
"""Missing request_token_spans must not crash (equal-split fallback)
and still yields a batch-aligned list."""
def test_runs_with_spans(self):
"""request_token_spans are required for correct per-request routing;
verify that passing them produces a batch-aligned list."""
talker = _make_bare_delay_talker()
hidden = _row_indexed_hidden(2)
info_dicts = [{}, {}]
spans = [(0, 1), (1, 2)]
result = talker.make_omni_output(hidden, runtime_additional_information=info_dicts)
result = talker.make_omni_output(
hidden,
runtime_additional_information=info_dicts,
request_token_spans=spans,
)
audio = _audio_payload(result)
assert isinstance(audio, list)
assert len(audio) == 2
@@ -41,6 +41,7 @@ def _make_minimal_talker(
def _default_raise(**_kwargs):
raise AssertionError("build_prompt_embeds was not stubbed in this test")
model._embedding_dtype = torch.bfloat16
model._prompt_builder = SimpleNamespace(
build_prompt_embeds=build_prompt_embeds if build_prompt_embeds is not None else _default_raise,
)
@@ -89,6 +90,7 @@ def _make_minimal_builder(
)
builder._speaker_cache = None
builder._text_tokenizer = None
builder._embedding_dtype = torch.bfloat16
builder._ref_audio_artifact_cache_max_entries = 256
builder._ref_audio_artifact_cache = OrderedDict()
builder._resampler_cache = OrderedDict()