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

@@ -42,10 +42,10 @@ _QUALITY_CONFIG = QualityTestConfig(
def _resolve_fl2va_model_ref() -> str:
from huggingface_hub import snapshot_download
from vllm_omni.transformers_utils.repo_utils import hf_api
repo_root = Path(
snapshot_download(
hf_api().snapshot_download(
repo_id=_MINIMAX_H3_REPO,
revision=_MINIMAX_H3_REVISION,
allow_patterns=["FL2VA/**"],
@@ -253,13 +253,13 @@ def test_resolve_fl2va_model_ref(tmp_path, monkeypatch):
fl2va_root.mkdir()
(fl2va_root / "model_index.json").write_text("{}", encoding="utf-8")
def fake_snapshot_download(*, repo_id, revision, allow_patterns):
def fake_snapshot_download(self, *, repo_id, revision, allow_patterns):
assert repo_id == _MINIMAX_H3_REPO
assert revision == _MINIMAX_H3_REVISION
assert allow_patterns == ["FL2VA/**"]
return str(tmp_path)
monkeypatch.setattr("huggingface_hub.snapshot_download", fake_snapshot_download)
monkeypatch.setattr("huggingface_hub.HfApi.snapshot_download", fake_snapshot_download)
assert _resolve_fl2va_model_ref() == str(fl2va_root)