Add vLLM-Omni library info to Hugging Face Hub requests (#5381)

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Co-authored-by: Hongsheng Liu <liuhongsheng4@huawei.com>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
authored and GitHub committed 2026-09-08 10:08:38 -06:00
1 parent 7a80b79698
commit fdaf4e31bd
57 files changed
+259 -220

No files matched your search

@@ -1,5 +1,5 @@
# SPDX-License-Identifier: Apache-2.0
# SPDX-FileCopyrightText: Copyright contributors to the vLLM project
# SPDX-FileCopyrightText: Copyright contributors to the vLLM-Omni project
"""Best-effort HuggingFace Hub prefetch for multi-subfolder pipelines.
@@ -297,7 +297,7 @@ def prefetch_subfolders(
logger.info("Prefetching %s subfolders: %s", model, subfolders)
try:
from huggingface_hub import snapshot_download
from vllm_omni.transformers_utils.repo_utils import hf_api
except ImportError: # pragma: no cover - huggingface_hub is a hard dep
logger.debug("huggingface_hub unavailable; skipping prefetch of %s", model)
return
@@ -334,7 +334,7 @@ def prefetch_subfolders(
for attempt in range(1, _PREFETCH_MAX_ATTEMPTS + 1):
try:
with _repo_prefetch_lock(model):
snapshot_download(
hf_api().snapshot_download(
repo_id=model,
revision=revision,
allow_patterns=allow_patterns,