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:
57 files changed
+259
-220
No files matched your search
@@ -1,3 +1,6 @@
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
# SPDX-FileCopyrightText: Copyright contributors to the vLLM-Omni project
|
||||
|
||||
from collections.abc import Iterable, Mapping, Sequence
|
||||
from math import isqrt
|
||||
from typing import Any
|
||||
@@ -122,9 +125,9 @@ class OmniBagelProcessingInfo(BaseProcessingInfo):
|
||||
if p.is_dir():
|
||||
index_path = p / "model.safetensors.index.json"
|
||||
else:
|
||||
from huggingface_hub import hf_hub_download
|
||||
from vllm_omni.transformers_utils.repo_utils import hf_api
|
||||
|
||||
index_path = Path(hf_hub_download(model_name, "model.safetensors.index.json"))
|
||||
index_path = Path(hf_api().hf_hub_download(model_name, "model.safetensors.index.json"))
|
||||
|
||||
if not index_path.exists():
|
||||
return
|
||||
|
||||
Reference in new issue
Block a user