[Bugfix] Fix modelscope usage (#52431)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
This commit is contained in:
Cyrus Leung
2026-08-15 02:40:24 -07:00
committed by GitHub
parent 42156466db
commit 5cecfc0137
2 changed files with 3 additions and 5 deletions
+2 -3
View File
@@ -48,15 +48,14 @@ def modelscope_list_repo_files(
api = HubApi()
api.login(token)
# same as huggingface_hub.list_repo_files
files = [
return [
file["Path"]
for file in api.get_model_files(
model_id=repo_id, revision=revision, recursive=True
)
if file["Type"] == "blob"
]
return files
def _maybe_json_dict(path: str | PathLike) -> dict[str, str]: