Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-huggingface-hub for
openSUSE:Factory checked in at 2026-07-17 18:50:40
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-huggingface-hub (Old)
and /work/SRC/openSUSE:Factory/.python-huggingface-hub.new.24530 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-huggingface-hub"
Fri Jul 17 18:50:40 2026 rev:8 rq:1366430 version:1.24.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-huggingface-hub/python-huggingface-hub.changes
2026-07-15 16:54:34.156828432 +0200
+++
/work/SRC/openSUSE:Factory/.python-huggingface-hub.new.24530/python-huggingface-hub.changes
2026-07-17 18:52:09.854701101 +0200
@@ -1,0 +2,11 @@
+Fri Jul 17 14:40:14 UTC 2026 - Martin Pluskal <[email protected]>
+
+- update to 1.24.0:
+ * Jobs can now be given an optional name, via the --name flag on the
+ CLI and the name parameter of run_job, run_uv_job, create_scheduled_job
+ and create_scheduled_uv_job; existing jobs can be named with
+ hf jobs labels <job_id> --name
+ * Fix xet download rate reporting to show the summed rather than the
+ per-file speed
+
+-------------------------------------------------------------------
Old:
----
huggingface_hub-1.23.0.tar.gz
New:
----
huggingface_hub-1.24.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-huggingface-hub.spec ++++++
--- /var/tmp/diff_new_pack.7akBte/_old 2026-07-17 18:52:11.562758899 +0200
+++ /var/tmp/diff_new_pack.7akBte/_new 2026-07-17 18:52:11.566759034 +0200
@@ -18,7 +18,7 @@
%{?sle15_python_module_pythons}
Name: python-huggingface-hub
-Version: 1.23.0
+Version: 1.24.0
Release: 0
Summary: Client library for interaction with the huggingface hub
License: Apache-2.0
++++++ huggingface_hub-1.23.0.tar.gz -> huggingface_hub-1.24.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/huggingface_hub-1.23.0/PKG-INFO
new/huggingface_hub-1.24.0/PKG-INFO
--- old/huggingface_hub-1.23.0/PKG-INFO 2026-07-09 16:49:15.996345500 +0200
+++ new/huggingface_hub-1.24.0/PKG-INFO 2026-07-17 11:53:43.926415700 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 2.4
Name: huggingface_hub
-Version: 1.23.0
+Version: 1.24.0
Summary: Client library to download and publish models, datasets and other
repos on the huggingface.co hub
Home-page: https://github.com/huggingface/huggingface_hub
Author: Hugging Face, Inc.
@@ -171,7 +171,17 @@
</p>
<p align="center">
- <i>The official Python client for the Huggingface Hub.</i>
+ <i>The official CLI and Python client for the Hugging Face Hub.</i>
+ <br/>
+ <a href="#what-is-huggingface_hub">About</a>
+ ·
+ <a href="https://huggingface.co/docs/huggingface_hub">Documentation</a>
+ ·
+ <a
href="https://huggingface.co/docs/huggingface_hub/en/installation">Install</a>
+ ·
+ <a href="https://huggingface.co/docs/huggingface_hub/en/guides/cli">CLI
Guide</a>
+ ·
+ <a
href="https://github.com/huggingface/huggingface_hub/blob/main/CONTRIBUTING.md">Contributing</a>
</p>
<p align="center">
@@ -189,36 +199,82 @@
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_fr.md">Français</a>
|
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_hi.md">हिंदी</a>
|
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_ko.md">한국어</a>
|
- <a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_cn.md">中文
(简体)</a>
+ <a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_cn.md">中文
(简体)</a> |
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_kn.md">ಕನ್ನಡ</a>
- <p>
+ </p>
</h4>
----
+## Quick start
+
+Install the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli) with the
standalone installer:
+
+```bash
+# On macOS and Linux.
+curl -LsSf https://hf.co/cli/install.sh | bash
+```
+
+```powershell
+# On Windows.
+powershell -ExecutionPolicy ByPass -c "irm https://hf.co/cli/install.ps1 | iex"
+```
+
+Log in, then start working with the Hub:
+
+```bash
+# Log in (use --token $HF_TOKEN in non-interactive environments)
+hf auth login
+
+# Find models served by Inference Providers
+hf models ls --warm
+
+# Download a model
+hf download Qwen/Qwen3-0.6B
+
+# Upload files to your own repo
+hf upload username/my-cool-model ./model.safetensors
-**Documentation**: <a href="https://hf.co/docs/huggingface_hub"
target="_blank">https://hf.co/docs/huggingface_hub</a>
+# Sync a local folder to a storage bucket
+hf buckets sync ./checkpoints hf://buckets/username/my-bucket
-**Source Code**: <a href="https://github.com/huggingface/huggingface_hub"
target="_blank">https://github.com/huggingface/huggingface_hub</a>
+# Run a job on Hugging Face infrastructure
+hf jobs run python:3.12 python -c "print('Hello from the cloud!')"
----
+# Discover everything else
+hf --help
+```
-## Welcome to the huggingface_hub library
+The Hub uses tokens to authenticate applications (see
[docs](https://huggingface.co/docs/hub/security-tokens)). Check out the [CLI
guide](https://huggingface.co/docs/huggingface_hub/en/guides/cli) for a tour of
the main features.
-The `huggingface_hub` library allows you to interact with the [Hugging Face
Hub](https://huggingface.co/), a platform democratizing open-source Machine
Learning for creators and collaborators. Discover pre-trained models and
datasets for your projects or play with the thousands of machine learning apps
hosted on the Hub. You can also create and share your own models, datasets and
demos with the community. The `huggingface_hub` library provides a simple way
to do all these things with Python.
+## What is `huggingface_hub`?
-## Key features
+The `huggingface_hub` library allows you to interact with the [Hugging Face
Hub](https://huggingface.co/), a platform democratizing open-source Machine
Learning for creators and collaborators. Discover pre-trained models and
datasets for your projects, play with the thousands of machine learning apps
hosted on the Hub, or create and share your own models, datasets and demos with
the community. Everything ships in one package with two interfaces: the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli) for your
terminal and the `huggingface_hub` library for Python — both designed to work
well for humans and AI agents. Use them to:
- [Download
files](https://huggingface.co/docs/huggingface_hub/en/guides/download) from the
Hub.
- [Upload files](https://huggingface.co/docs/huggingface_hub/en/guides/upload)
to the Hub.
- [Manage your
repositories](https://huggingface.co/docs/huggingface_hub/en/guides/repository).
- [Run
Inference](https://huggingface.co/docs/huggingface_hub/en/guides/inference) on
deployed models.
+- [Run Jobs](https://huggingface.co/docs/huggingface_hub/en/guides/jobs) on
Hugging Face infrastructure.
- [Search](https://huggingface.co/docs/huggingface_hub/en/guides/search) for
models, datasets and Spaces.
- [Share Model
Cards](https://huggingface.co/docs/huggingface_hub/en/guides/model-cards) to
document your models.
- [Engage with the
community](https://huggingface.co/docs/huggingface_hub/en/guides/community)
through PRs and comments.
+- Do all of the above from the terminal with the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli).
+
+## Built for humans and AI agents
+
+The `hf` CLI is designed for people and coding agents alike: the same commands
adapt their output when run by an agent. If you use Claude Code, Codex, Cursor,
or another coding agent, install the `hf` CLI Skill — a command reference
generated from your installed CLI:
+
+```bash
+# for Codex, Cursor, OpenCode, Pi and other agents that load skills from
`.agents/skills`
+hf skills add
+# includes the above + Claude Code
+hf skills add --claude
+```
-## Installation
+Learn more in the [Hugging Face CLI for AI agents
guide](https://huggingface.co/docs/hub/agents-cli) and the [announcement blog
post](https://huggingface.co/blog/hf-cli-for-agents).
-Install the `huggingface_hub` package with
[pip](https://pypi.org/project/huggingface-hub/):
+## Use the Python library
+
+Install the `huggingface_hub` package with
[pip](https://pypi.org/project/huggingface-hub/) (this also installs the `hf`
CLI):
```bash
pip install huggingface_hub
@@ -238,8 +294,6 @@
To learn more about installation and optional dependencies, check out the
[installation
guide](https://huggingface.co/docs/huggingface_hub/en/installation).
-## Quick start
-
### Download files
Download a single file
@@ -247,7 +301,7 @@
```py
from huggingface_hub import hf_hub_download
-hf_hub_download(repo_id="tiiuae/falcon-7b-instruct", filename="config.json")
+hf_hub_download(repo_id="zai-org/GLM-5.2", filename="config.json")
```
Or an entire repository
@@ -255,21 +309,11 @@
```py
from huggingface_hub import snapshot_download
-snapshot_download("stabilityai/stable-diffusion-2-1")
+snapshot_download("sentence-transformers/all-MiniLM-L6-v2")
```
Files will be downloaded in a local cache folder. More details in [this
guide](https://huggingface.co/docs/huggingface_hub/en/guides/manage-cache).
-### Login
-
-The Hugging Face Hub uses tokens to authenticate applications (see
[docs](https://huggingface.co/docs/hub/security-tokens)). To log in your
machine, run the following CLI:
-
-```bash
-hf auth login
-# or using an environment variable
-hf auth login --token $HUGGINGFACE_TOKEN
-```
-
### Create a repository
```py
@@ -304,16 +348,16 @@
)
```
-For details in the [upload
guide](https://huggingface.co/docs/huggingface_hub/en/guides/upload).
+More details in the [upload
guide](https://huggingface.co/docs/huggingface_hub/en/guides/upload).
-## Integrating to the Hub.
+## Integrating with the Hub.
We're partnering with cool open source ML libraries to provide free model
hosting and versioning. You can find the existing integrations
[here](https://huggingface.co/docs/hub/libraries).
The advantages are:
- Free model or dataset hosting for libraries and their users.
-- Built-in file versioning, even with very large files, thanks to a git-based
approach.
+- Built-in file versioning, even with very large files, made possible by
[Xet](https://huggingface.co/docs/hub/xet/index), the Hub's chunk-deduplicated
storage backend.
- In-browser widgets to play with the uploaded models.
- Anyone can upload a new model for your library, they just need to add the
corresponding tag for the model to be discoverable.
- Fast downloads! We use Cloudfront (a CDN) to geo-replicate downloads so
they're blazing fast from anywhere on the globe.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/huggingface_hub-1.23.0/README.md
new/huggingface_hub-1.24.0/README.md
--- old/huggingface_hub-1.23.0/README.md 2026-07-09 16:49:06.000000000
+0200
+++ new/huggingface_hub-1.24.0/README.md 2026-07-17 11:53:37.000000000
+0200
@@ -9,7 +9,17 @@
</p>
<p align="center">
- <i>The official Python client for the Huggingface Hub.</i>
+ <i>The official CLI and Python client for the Hugging Face Hub.</i>
+ <br/>
+ <a href="#what-is-huggingface_hub">About</a>
+ ·
+ <a href="https://huggingface.co/docs/huggingface_hub">Documentation</a>
+ ·
+ <a
href="https://huggingface.co/docs/huggingface_hub/en/installation">Install</a>
+ ·
+ <a href="https://huggingface.co/docs/huggingface_hub/en/guides/cli">CLI
Guide</a>
+ ·
+ <a
href="https://github.com/huggingface/huggingface_hub/blob/main/CONTRIBUTING.md">Contributing</a>
</p>
<p align="center">
@@ -27,36 +37,82 @@
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_fr.md">Français</a>
|
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_hi.md">हिंदी</a>
|
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_ko.md">한국어</a>
|
- <a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_cn.md">中文
(简体)</a>
+ <a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_cn.md">中文
(简体)</a> |
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_kn.md">ಕನ್ನಡ</a>
- <p>
+ </p>
</h4>
----
+## Quick start
+
+Install the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli) with the
standalone installer:
+
+```bash
+# On macOS and Linux.
+curl -LsSf https://hf.co/cli/install.sh | bash
+```
+
+```powershell
+# On Windows.
+powershell -ExecutionPolicy ByPass -c "irm https://hf.co/cli/install.ps1 | iex"
+```
+
+Log in, then start working with the Hub:
+
+```bash
+# Log in (use --token $HF_TOKEN in non-interactive environments)
+hf auth login
+
+# Find models served by Inference Providers
+hf models ls --warm
+
+# Download a model
+hf download Qwen/Qwen3-0.6B
+
+# Upload files to your own repo
+hf upload username/my-cool-model ./model.safetensors
-**Documentation**: <a href="https://hf.co/docs/huggingface_hub"
target="_blank">https://hf.co/docs/huggingface_hub</a>
+# Sync a local folder to a storage bucket
+hf buckets sync ./checkpoints hf://buckets/username/my-bucket
-**Source Code**: <a href="https://github.com/huggingface/huggingface_hub"
target="_blank">https://github.com/huggingface/huggingface_hub</a>
+# Run a job on Hugging Face infrastructure
+hf jobs run python:3.12 python -c "print('Hello from the cloud!')"
----
+# Discover everything else
+hf --help
+```
-## Welcome to the huggingface_hub library
+The Hub uses tokens to authenticate applications (see
[docs](https://huggingface.co/docs/hub/security-tokens)). Check out the [CLI
guide](https://huggingface.co/docs/huggingface_hub/en/guides/cli) for a tour of
the main features.
-The `huggingface_hub` library allows you to interact with the [Hugging Face
Hub](https://huggingface.co/), a platform democratizing open-source Machine
Learning for creators and collaborators. Discover pre-trained models and
datasets for your projects or play with the thousands of machine learning apps
hosted on the Hub. You can also create and share your own models, datasets and
demos with the community. The `huggingface_hub` library provides a simple way
to do all these things with Python.
+## What is `huggingface_hub`?
-## Key features
+The `huggingface_hub` library allows you to interact with the [Hugging Face
Hub](https://huggingface.co/), a platform democratizing open-source Machine
Learning for creators and collaborators. Discover pre-trained models and
datasets for your projects, play with the thousands of machine learning apps
hosted on the Hub, or create and share your own models, datasets and demos with
the community. Everything ships in one package with two interfaces: the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli) for your
terminal and the `huggingface_hub` library for Python — both designed to work
well for humans and AI agents. Use them to:
- [Download
files](https://huggingface.co/docs/huggingface_hub/en/guides/download) from the
Hub.
- [Upload files](https://huggingface.co/docs/huggingface_hub/en/guides/upload)
to the Hub.
- [Manage your
repositories](https://huggingface.co/docs/huggingface_hub/en/guides/repository).
- [Run
Inference](https://huggingface.co/docs/huggingface_hub/en/guides/inference) on
deployed models.
+- [Run Jobs](https://huggingface.co/docs/huggingface_hub/en/guides/jobs) on
Hugging Face infrastructure.
- [Search](https://huggingface.co/docs/huggingface_hub/en/guides/search) for
models, datasets and Spaces.
- [Share Model
Cards](https://huggingface.co/docs/huggingface_hub/en/guides/model-cards) to
document your models.
- [Engage with the
community](https://huggingface.co/docs/huggingface_hub/en/guides/community)
through PRs and comments.
+- Do all of the above from the terminal with the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli).
+
+## Built for humans and AI agents
+
+The `hf` CLI is designed for people and coding agents alike: the same commands
adapt their output when run by an agent. If you use Claude Code, Codex, Cursor,
or another coding agent, install the `hf` CLI Skill — a command reference
generated from your installed CLI:
+
+```bash
+# for Codex, Cursor, OpenCode, Pi and other agents that load skills from
`.agents/skills`
+hf skills add
+# includes the above + Claude Code
+hf skills add --claude
+```
-## Installation
+Learn more in the [Hugging Face CLI for AI agents
guide](https://huggingface.co/docs/hub/agents-cli) and the [announcement blog
post](https://huggingface.co/blog/hf-cli-for-agents).
-Install the `huggingface_hub` package with
[pip](https://pypi.org/project/huggingface-hub/):
+## Use the Python library
+
+Install the `huggingface_hub` package with
[pip](https://pypi.org/project/huggingface-hub/) (this also installs the `hf`
CLI):
```bash
pip install huggingface_hub
@@ -76,8 +132,6 @@
To learn more about installation and optional dependencies, check out the
[installation
guide](https://huggingface.co/docs/huggingface_hub/en/installation).
-## Quick start
-
### Download files
Download a single file
@@ -85,7 +139,7 @@
```py
from huggingface_hub import hf_hub_download
-hf_hub_download(repo_id="tiiuae/falcon-7b-instruct", filename="config.json")
+hf_hub_download(repo_id="zai-org/GLM-5.2", filename="config.json")
```
Or an entire repository
@@ -93,21 +147,11 @@
```py
from huggingface_hub import snapshot_download
-snapshot_download("stabilityai/stable-diffusion-2-1")
+snapshot_download("sentence-transformers/all-MiniLM-L6-v2")
```
Files will be downloaded in a local cache folder. More details in [this
guide](https://huggingface.co/docs/huggingface_hub/en/guides/manage-cache).
-### Login
-
-The Hugging Face Hub uses tokens to authenticate applications (see
[docs](https://huggingface.co/docs/hub/security-tokens)). To log in your
machine, run the following CLI:
-
-```bash
-hf auth login
-# or using an environment variable
-hf auth login --token $HUGGINGFACE_TOKEN
-```
-
### Create a repository
```py
@@ -142,16 +186,16 @@
)
```
-For details in the [upload
guide](https://huggingface.co/docs/huggingface_hub/en/guides/upload).
+More details in the [upload
guide](https://huggingface.co/docs/huggingface_hub/en/guides/upload).
-## Integrating to the Hub.
+## Integrating with the Hub.
We're partnering with cool open source ML libraries to provide free model
hosting and versioning. You can find the existing integrations
[here](https://huggingface.co/docs/hub/libraries).
The advantages are:
- Free model or dataset hosting for libraries and their users.
-- Built-in file versioning, even with very large files, thanks to a git-based
approach.
+- Built-in file versioning, even with very large files, made possible by
[Xet](https://huggingface.co/docs/hub/xet/index), the Hub's chunk-deduplicated
storage backend.
- In-browser widgets to play with the uploaded models.
- Anyone can upload a new model for your library, they just need to add the
corresponding tag for the model to be discoverable.
- Fast downloads! We use Cloudfront (a CDN) to geo-replicate downloads so
they're blazing fast from anywhere on the globe.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub/__init__.py
new/huggingface_hub-1.24.0/src/huggingface_hub/__init__.py
--- old/huggingface_hub-1.23.0/src/huggingface_hub/__init__.py 2026-07-09
16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub/__init__.py 2026-07-17
11:53:37.000000000 +0200
@@ -46,7 +46,7 @@
from typing import TYPE_CHECKING
-__version__ = "1.23.0"
+__version__ = "1.24.0"
# Alphabetical order of definitions is ensured in tests
# WARNING: any comment added in this dictionary definition will be lost when
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub/_jobs_api.py
new/huggingface_hub-1.24.0/src/huggingface_hub/_jobs_api.py
--- old/huggingface_hub-1.23.0/src/huggingface_hub/_jobs_api.py 2026-07-09
16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub/_jobs_api.py 2026-07-17
11:53:37.000000000 +0200
@@ -518,11 +518,17 @@
secrets: dict[str, Any] | None,
flavor: JobHardware | str | None,
timeout: int | float | str | None,
+ name: str | None = None,
labels: dict[str, str] | None = None,
volumes: list[Volume] | None = None,
expose: list[int] | None = None,
ssh: bool = False,
) -> dict[str, Any]:
+ if name is not None:
+ if labels is not None and "name" in labels:
+ raise ValueError("`name` and the `name` key in `labels` cannot
both be provided.")
+ labels = {**(labels or {}), "name": name}
+
# prepare job spec to send to HF Jobs API
job_spec: dict[str, Any] = {
"command": command,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub/_snapshot_download.py
new/huggingface_hub-1.24.0/src/huggingface_hub/_snapshot_download.py
--- old/huggingface_hub-1.23.0/src/huggingface_hub/_snapshot_download.py
2026-07-09 16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub/_snapshot_download.py
2026-07-17 11:53:37.000000000 +0200
@@ -25,6 +25,7 @@
XET_BYTES_BAR_FORMAT,
XET_TRANSFER_BAR_FORMAT,
_finish_transfer_bar,
+ _set_aggregate_rate_postfix,
_update_transfer_bar,
)
from .utils.tqdm import _create_progress_bar
@@ -480,10 +481,11 @@
_update_transfer_bar(transfer_progress, int(n or 0))
def set_postfix_str(self, postfix: str, refresh: bool = False) -> None:
- reconstruct_progress.set_postfix_str(postfix, refresh=refresh)
+ # Discard the caller's per-file rate; report the summed rate
across all files instead.
+ _set_aggregate_rate_postfix(reconstruct_progress)
def set_transfer_postfix_str(self, postfix: str, refresh: bool =
False) -> None:
- transfer_progress.set_postfix_str(postfix, refresh=refresh)
+ _set_aggregate_rate_postfix(transfer_progress)
# Pass the commit_hash as revision to hf_hub_download to skip network call
if:
# - file is cached
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub/cli/jobs.py
new/huggingface_hub-1.24.0/src/huggingface_hub/cli/jobs.py
--- old/huggingface_hub-1.23.0/src/huggingface_hub/cli/jobs.py 2026-07-09
16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub/cli/jobs.py 2026-07-17
11:53:37.000000000 +0200
@@ -161,6 +161,14 @@
),
]
+NameOpt = Annotated[
+ str | None,
+ Option(
+ "--name",
+ help="Name the Job. Stored as the `name` label. Names do not have to
be unique.",
+ ),
+]
+
TimeoutOpt = Annotated[
str | None,
Option(
@@ -315,7 +323,7 @@
"run",
context_settings={"ignore_unknown_options": True},
examples=[
- "hf jobs run python:3.12 python -c 'print(\"Hello!\")'",
+ "hf jobs run --name hello-world python:3.12 python -c
'print(\"Hello!\")'",
"hf jobs run --detach python:3.12 python script.py",
"hf jobs run -e FOO=foo python:3.12 python script.py",
"hf jobs run --secrets HF_TOKEN python:3.12 python script.py",
@@ -327,6 +335,7 @@
command: CommandArg,
env: EnvOpt = None,
secrets: SecretsOpt = None,
+ name: NameOpt = None,
label: LabelsOpt = None,
volume: JobVolumesOpt = None,
env_file: EnvFileOpt = None,
@@ -349,7 +358,7 @@
command=command,
env=env_map,
secrets=secrets_map,
- labels=_parse_labels_map(label),
+ labels=_parse_labels_map(label, name=name),
volumes=_parse_and_sync_job_volumes(volume, api=api,
namespace=namespace),
flavor=flavor,
timeout=timeout,
@@ -358,6 +367,8 @@
namespace=namespace,
)
out.result("Job started", id=job.id, url=job.url)
+ if name is None:
+ out.hint(f"Name this Job with `hf jobs labels
{job.owner.name}/{job.id} --name NAME`.")
if isinstance(job.status.expose_urls, list):
urls = "\n".join(f" {url}" for url in job.status.expose_urls)
out.hint(f"Exposed ports are reachable at (requires an HF token with
read access to the job):\n{urls}")
@@ -801,27 +812,36 @@
@jobs_cli.command(
"labels",
examples=[
+ "hf jobs labels <job_id> --name training-v2",
"hf jobs labels <job_id> --label env=prod --label team=ml",
"hf jobs labels <job_id> --clear",
],
)
def jobs_labels(
job_id: JobIdArg,
+ name: NameOpt = None,
label: LabelsOpt = None,
clear: Annotated[bool, Option("--clear", help="Remove all labels from the
job.")] = False,
namespace: NamespaceOpt = None,
token: TokenOpt = None,
) -> None:
- """Update labels on a Job. Replaces all existing labels."""
- if not label and not clear:
- raise CLIError("Please set at least one label with --label. To remove
all labels, pass --clear.")
- if label and clear:
+ """Update labels on a Job. Passing --label replaces all existing labels;
passing --name alone keeps them."""
+ if not label and name is None and not clear:
+ raise CLIError(
+ "Please set a name with --name or at least one label with --label.
To remove all labels, pass --clear."
+ )
+ if (label or name is not None) and clear:
raise CLIError(
- "Cannot set labels and clear them at the same time. Please use
either --label or --clear, not both."
+ "Cannot set a name or labels and clear them at the same time.
Please use --name/--label or --clear, not both."
)
job_id, namespace = _parse_namespace_from_job_id(job_id, namespace)
- labels = _parse_labels_map(label) or {}
api = get_hf_api(token=token)
+ if name is not None and not label:
+ # Naming a Job should not wipe its existing labels: fetch them and
merge the name in.
+ current_labels = api.inspect_job(job_id=job_id,
namespace=namespace).labels or {}
+ labels = {**current_labels, "name": name}
+ else:
+ labels = _parse_labels_map(label, name=name) or {}
job = api.update_job_labels(job_id=job_id, labels=labels,
namespace=namespace)
out.result("Labels updated", id=job.id)
@@ -880,7 +900,7 @@
"run",
context_settings={"ignore_unknown_options": True},
examples=[
- "hf jobs uv run my_script.py",
+ "hf jobs uv run --name my-script my_script.py",
"hf jobs uv run --detach my_script.py",
"hf jobs uv run ml_training.py --flavor a10g-small",
"hf jobs uv run --with transformers train.py",
@@ -894,6 +914,7 @@
flavor: FlavorOpt = None,
env: EnvOpt = None,
secrets: SecretsOpt = None,
+ name: NameOpt = None,
label: LabelsOpt = None,
volume: JobVolumesOpt = None,
env_file: EnvFileOpt = None,
@@ -920,7 +941,7 @@
image=image,
env=env_map,
secrets=secrets_map,
- labels=_parse_labels_map(label),
+ labels=_parse_labels_map(label, name=name),
volumes=_parse_and_sync_job_volumes(volume, api=api,
namespace=namespace),
flavor=flavor,
timeout=timeout,
@@ -929,6 +950,8 @@
namespace=namespace,
)
out.result("Job started", id=job.id, url=job.url)
+ if name is None:
+ out.hint(f"Name this Job with `hf jobs labels
{job.owner.name}/{job.id} --name NAME`.")
if isinstance(job.status.expose_urls, list):
urls = "\n".join(f" {url}" for url in job.status.expose_urls)
out.hint(f"Exposed ports are reachable at (requires an HF token with
read access to the job):\n{urls}")
@@ -949,7 +972,7 @@
@scheduled_app.command(
"run",
context_settings={"ignore_unknown_options": True},
- examples=['hf jobs scheduled run "0 0 * * *" python:3.12 python
script.py'],
+ examples=['hf jobs scheduled run "0 0 * * *" --name daily-script
python:3.12 python script.py'],
)
def scheduled_run(
schedule: ScheduleArg,
@@ -959,6 +982,7 @@
concurrency: ConcurrencyOpt = None,
env: EnvOpt = None,
secrets: SecretsOpt = None,
+ name: NameOpt = None,
label: LabelsOpt = None,
volume: JobVolumesOpt = None,
env_file: EnvFileOpt = None,
@@ -982,7 +1006,7 @@
concurrency=concurrency,
env=env_map,
secrets=secrets_map,
- labels=_parse_labels_map(label),
+ labels=_parse_labels_map(label, name=name),
volumes=_parse_and_sync_job_volumes(volume, api=api,
namespace=namespace),
flavor=flavor,
timeout=timeout,
@@ -990,7 +1014,11 @@
namespace=namespace,
)
out.result("Scheduled Job created", id=scheduled_job.id)
- out.hint(f"Use `hf jobs scheduled inspect {scheduled_job.id}` to view its
details.")
+ if name is None:
+ out.hint(
+ f"Name this scheduled Job with `hf jobs scheduled labels
{scheduled_job.owner.name}/{scheduled_job.id} --name NAME`."
+ )
+ out.hint(f"Use `hf jobs scheduled inspect
{scheduled_job.owner.name}/{scheduled_job.id}` to view its details.")
@scheduled_app.command("list | ls | ps", examples=["hf jobs scheduled ls"])
@@ -1158,27 +1186,38 @@
@scheduled_app.command(
"labels",
examples=[
+ "hf jobs scheduled labels <id> --name daily-script",
"hf jobs scheduled labels <id> --label env=prod --label team=ml",
"hf jobs scheduled labels <id> --clear",
],
)
def scheduled_labels(
scheduled_job_id: ScheduledJobIdArg,
+ name: NameOpt = None,
label: LabelsOpt = None,
clear: Annotated[bool, Option("--clear", help="Remove all labels from the
scheduled job.")] = False,
namespace: NamespaceOpt = None,
token: TokenOpt = None,
) -> None:
- """Update labels on a scheduled Job. Replaces all existing labels."""
- if not label and not clear:
- raise CLIError("Please set at least one label with --label. To remove
all labels, pass --clear.")
- if label and clear:
+ """Update labels on a scheduled Job. Passing --label replaces all existing
labels; passing --name alone keeps them."""
+ if not label and name is None and not clear:
+ raise CLIError(
+ "Please set a name with --name or at least one label with --label.
To remove all labels, pass --clear."
+ )
+ if (label or name is not None) and clear:
raise CLIError(
- "Cannot set labels and clear them at the same time. Please use
either --label or --clear, not both."
+ "Cannot set a name or labels and clear them at the same time.
Please use --name/--label or --clear, not both."
)
scheduled_job_id, namespace =
_parse_namespace_from_job_id(scheduled_job_id, namespace)
- labels = _parse_labels_map(label) or {}
api = get_hf_api(token=token)
+ if name is not None and not label:
+ # Naming a scheduled Job should not wipe its existing labels: fetch
them and merge the name in.
+ current_labels = (
+ api.inspect_scheduled_job(scheduled_job_id=scheduled_job_id,
namespace=namespace).job_spec.labels or {}
+ )
+ labels = {**current_labels, "name": name}
+ else:
+ labels = _parse_labels_map(label, name=name) or {}
scheduled_job = api.update_scheduled_job_labels(
scheduled_job_id=scheduled_job_id, labels=labels, namespace=namespace
)
@@ -1193,7 +1232,7 @@
"run",
context_settings={"ignore_unknown_options": True},
examples=[
- 'hf jobs scheduled uv run "0 0 * * *" script.py',
+ 'hf jobs scheduled uv run "0 0 * * *" --name daily-script script.py',
'hf jobs scheduled uv run "0 0 * * *" script.py --with pandas',
],
)
@@ -1207,6 +1246,7 @@
flavor: FlavorOpt = None,
env: EnvOpt = None,
secrets: SecretsOpt = None,
+ name: NameOpt = None,
label: LabelsOpt = None,
volume: JobVolumesOpt = None,
env_file: EnvFileOpt = None,
@@ -1234,7 +1274,7 @@
image=image,
env=env_map,
secrets=secrets_map,
- labels=_parse_labels_map(label),
+ labels=_parse_labels_map(label, name=name),
volumes=_parse_and_sync_job_volumes(volume, api=api,
namespace=namespace),
flavor=flavor,
timeout=timeout,
@@ -1242,27 +1282,33 @@
namespace=namespace,
)
out.result("Scheduled Job created", id=job.id)
- out.hint(f"Use `hf jobs scheduled inspect {job.id}` to view its details.")
+ if name is None:
+ out.hint(f"Name this scheduled Job with `hf jobs scheduled labels
{job.owner.name}/{job.id} --name NAME`.")
+ out.hint(f"Use `hf jobs scheduled inspect {job.owner.name}/{job.id}` to
view its details.")
### UTILS
-def _parse_labels_map(labels: list[str] | None) -> dict[str, str] | None:
+def _parse_labels_map(labels: list[str] | None, *, name: str | None = None) ->
dict[str, str] | None:
"""Parse label key-value pairs from CLI arguments.
Args:
labels: List of label strings in KEY=VALUE format. If KEY only, then
VALUE is set to empty string.
Returns:
- Dictionary mapping label keys to values, or None if no labels provided.
+ Dictionary mapping label keys to values, or None if no labels or name
provided.
"""
- if not labels:
+ if not labels and name is None:
return None
labels_map: dict[str, str] = {}
- for label_var in labels:
+ for label_var in labels or []:
key, value = label_var.split("=", 1) if "=" in label_var else
(label_var, "")
labels_map[key] = value
+ if name is not None:
+ if "name" in labels_map:
+ raise CLIError("--name and --label name=... cannot both be
provided.")
+ labels_map["name"] = name
return labels_map
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub/file_download.py
new/huggingface_hub-1.24.0/src/huggingface_hub/file_download.py
--- old/huggingface_hub-1.23.0/src/huggingface_hub/file_download.py
2026-07-09 16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub/file_download.py
2026-07-17 11:53:37.000000000 +0200
@@ -908,7 +908,7 @@
the local cache.
etag_timeout (`float`, *optional*, defaults to `10`):
When fetching ETag, how many seconds to wait for the server to send
- data before giving up which is passed to `requests.request`.
+ data before giving up, which is passed to `httpx.request`.
token (`str`, `bool`, *optional*):
A token to be used for the download.
- If `True`, the token is read from the HuggingFace config
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/huggingface_hub-1.23.0/src/huggingface_hub/hf_api.py
new/huggingface_hub-1.24.0/src/huggingface_hub/hf_api.py
--- old/huggingface_hub-1.23.0/src/huggingface_hub/hf_api.py 2026-07-09
16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub/hf_api.py 2026-07-17
11:53:37.000000000 +0200
@@ -11808,6 +11808,7 @@
secrets: dict[str, Any] | None = None,
flavor: JobHardware | str | None = None,
timeout: int | float | str | None = None,
+ name: str | None = None,
labels: dict[str, str] | None = None,
volumes: list[Volume] | None = None,
expose: list[int] | None = None,
@@ -11841,6 +11842,10 @@
Max duration for the Job: int with s (seconds, default), m
(minutes), h (hours) or d (days).
Example: `300` or `"5m"` for 5 minutes.
+ name (`str`, *optional*):
+ A name for the Job. Stored as the `name` label. Cannot be
passed together with a `name` key in
+ `labels`. Names do not have to be unique.
+
labels (`dict[str, str]`, *optional*):
Labels to attach to the job (key-value pairs).
@@ -11906,6 +11911,7 @@
secrets=secrets,
flavor=flavor,
timeout=timeout,
+ name=name,
labels=labels,
volumes=volumes,
expose=expose,
@@ -12434,6 +12440,7 @@
secrets: dict[str, Any] | None = None,
flavor: JobHardware | str | None = None,
timeout: int | float | str | None = None,
+ name: str | None = None,
labels: dict[str, str] | None = None,
volumes: list[Volume] | None = None,
expose: list[int] | None = None,
@@ -12474,6 +12481,10 @@
Max duration for the Job: int with s (seconds, default), m
(minutes), h (hours) or d (days).
Example: `300` or `"5m"` for 5 minutes.
+ name (`str`, *optional*):
+ A name for the Job. Stored as the `name` label. Cannot be
passed together with a `name` key in
+ `labels`. Names do not have to be unique.
+
labels (`dict[str, str]`, *optional*):
Labels to attach to the job (key-value pairs).
@@ -12566,6 +12577,7 @@
secrets=secrets,
flavor=flavor,
timeout=timeout,
+ name=name,
labels=labels,
volumes=volumes,
expose=expose,
@@ -12586,6 +12598,7 @@
secrets: dict[str, Any] | None = None,
flavor: JobHardware | str | None = None,
timeout: int | float | str | None = None,
+ name: str | None = None,
labels: dict[str, str] | None = None,
volumes: list[Volume] | None = None,
expose: list[int] | None = None,
@@ -12628,6 +12641,10 @@
Max duration for the Job: int with s (seconds, default), m
(minutes), h (hours) or d (days).
Example: `300` or `"5m"` for 5 minutes.
+ name (`str`, *optional*):
+ A name for the scheduled Job. Stored as the `name` label.
Cannot be passed together with a `name`
+ key in `labels`. Names do not have to be unique.
+
labels (`dict[str, str]`, *optional*):
Labels to attach to the job (key-value pairs).
@@ -12685,6 +12702,7 @@
secrets=secrets,
flavor=flavor,
timeout=timeout,
+ name=name,
labels=labels,
volumes=volumes,
expose=expose,
@@ -12968,6 +12986,7 @@
secrets: dict[str, Any] | None = None,
flavor: JobHardware | str | None = None,
timeout: int | float | str | None = None,
+ name: str | None = None,
labels: dict[str, str] | None = None,
volumes: list[Volume] | None = None,
expose: list[int] | None = None,
@@ -13017,6 +13036,10 @@
Max duration for the Job: int with s (seconds, default), m
(minutes), h (hours) or d (days).
Example: `300` or `"5m"` for 5 minutes.
+ name (`str`, *optional*):
+ A name for the scheduled Job. Stored as the `name` label.
Cannot be passed together with a `name`
+ key in `labels`. Names do not have to be unique.
+
labels (`dict[str, str]`, *optional*):
Labels to attach to the job (key-value pairs).
@@ -13093,6 +13116,7 @@
secrets=secrets,
flavor=flavor,
timeout=timeout,
+ name=name,
labels=labels,
volumes=volumes,
expose=expose,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub/utils/_xet_progress_reporting.py
new/huggingface_hub-1.24.0/src/huggingface_hub/utils/_xet_progress_reporting.py
---
old/huggingface_hub-1.23.0/src/huggingface_hub/utils/_xet_progress_reporting.py
2026-07-09 16:49:06.000000000 +0200
+++
new/huggingface_hub-1.24.0/src/huggingface_hub/utils/_xet_progress_reporting.py
2026-07-17 11:53:37.000000000 +0200
@@ -47,6 +47,16 @@
bar.refresh()
+def _set_aggregate_rate_postfix(bar) -> None:
+ """Show a shared bar's own throughput as its rate.
+
+ When many files feed one bar (snapshot download), each file only knows its
own per-item rate — a
+ fraction of the total. Deriving the rate from the shared bar's aggregated
byte count reports the
+ true combined speed instead of whichever single file reported last.
+ """
+ bar.set_postfix_str(_format_speed_postfix(bar.format_dict.get("rate")),
refresh=False)
+
+
class XetDownloadProgressReporter:
"""Dual progress bars for Xet downloads: network transfer and file
reconstruction.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/src/huggingface_hub.egg-info/PKG-INFO
new/huggingface_hub-1.24.0/src/huggingface_hub.egg-info/PKG-INFO
--- old/huggingface_hub-1.23.0/src/huggingface_hub.egg-info/PKG-INFO
2026-07-09 16:49:15.000000000 +0200
+++ new/huggingface_hub-1.24.0/src/huggingface_hub.egg-info/PKG-INFO
2026-07-17 11:53:43.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 2.4
Name: huggingface_hub
-Version: 1.23.0
+Version: 1.24.0
Summary: Client library to download and publish models, datasets and other
repos on the huggingface.co hub
Home-page: https://github.com/huggingface/huggingface_hub
Author: Hugging Face, Inc.
@@ -171,7 +171,17 @@
</p>
<p align="center">
- <i>The official Python client for the Huggingface Hub.</i>
+ <i>The official CLI and Python client for the Hugging Face Hub.</i>
+ <br/>
+ <a href="#what-is-huggingface_hub">About</a>
+ ·
+ <a href="https://huggingface.co/docs/huggingface_hub">Documentation</a>
+ ·
+ <a
href="https://huggingface.co/docs/huggingface_hub/en/installation">Install</a>
+ ·
+ <a href="https://huggingface.co/docs/huggingface_hub/en/guides/cli">CLI
Guide</a>
+ ·
+ <a
href="https://github.com/huggingface/huggingface_hub/blob/main/CONTRIBUTING.md">Contributing</a>
</p>
<p align="center">
@@ -189,36 +199,82 @@
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_fr.md">Français</a>
|
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_hi.md">हिंदी</a>
|
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_ko.md">한국어</a>
|
- <a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_cn.md">中文
(简体)</a>
+ <a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_cn.md">中文
(简体)</a> |
<a
href="https://github.com/huggingface/huggingface_hub/blob/main/i18n/README_kn.md">ಕನ್ನಡ</a>
- <p>
+ </p>
</h4>
----
+## Quick start
+
+Install the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli) with the
standalone installer:
+
+```bash
+# On macOS and Linux.
+curl -LsSf https://hf.co/cli/install.sh | bash
+```
+
+```powershell
+# On Windows.
+powershell -ExecutionPolicy ByPass -c "irm https://hf.co/cli/install.ps1 | iex"
+```
+
+Log in, then start working with the Hub:
+
+```bash
+# Log in (use --token $HF_TOKEN in non-interactive environments)
+hf auth login
+
+# Find models served by Inference Providers
+hf models ls --warm
+
+# Download a model
+hf download Qwen/Qwen3-0.6B
+
+# Upload files to your own repo
+hf upload username/my-cool-model ./model.safetensors
-**Documentation**: <a href="https://hf.co/docs/huggingface_hub"
target="_blank">https://hf.co/docs/huggingface_hub</a>
+# Sync a local folder to a storage bucket
+hf buckets sync ./checkpoints hf://buckets/username/my-bucket
-**Source Code**: <a href="https://github.com/huggingface/huggingface_hub"
target="_blank">https://github.com/huggingface/huggingface_hub</a>
+# Run a job on Hugging Face infrastructure
+hf jobs run python:3.12 python -c "print('Hello from the cloud!')"
----
+# Discover everything else
+hf --help
+```
-## Welcome to the huggingface_hub library
+The Hub uses tokens to authenticate applications (see
[docs](https://huggingface.co/docs/hub/security-tokens)). Check out the [CLI
guide](https://huggingface.co/docs/huggingface_hub/en/guides/cli) for a tour of
the main features.
-The `huggingface_hub` library allows you to interact with the [Hugging Face
Hub](https://huggingface.co/), a platform democratizing open-source Machine
Learning for creators and collaborators. Discover pre-trained models and
datasets for your projects or play with the thousands of machine learning apps
hosted on the Hub. You can also create and share your own models, datasets and
demos with the community. The `huggingface_hub` library provides a simple way
to do all these things with Python.
+## What is `huggingface_hub`?
-## Key features
+The `huggingface_hub` library allows you to interact with the [Hugging Face
Hub](https://huggingface.co/), a platform democratizing open-source Machine
Learning for creators and collaborators. Discover pre-trained models and
datasets for your projects, play with the thousands of machine learning apps
hosted on the Hub, or create and share your own models, datasets and demos with
the community. Everything ships in one package with two interfaces: the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli) for your
terminal and the `huggingface_hub` library for Python — both designed to work
well for humans and AI agents. Use them to:
- [Download
files](https://huggingface.co/docs/huggingface_hub/en/guides/download) from the
Hub.
- [Upload files](https://huggingface.co/docs/huggingface_hub/en/guides/upload)
to the Hub.
- [Manage your
repositories](https://huggingface.co/docs/huggingface_hub/en/guides/repository).
- [Run
Inference](https://huggingface.co/docs/huggingface_hub/en/guides/inference) on
deployed models.
+- [Run Jobs](https://huggingface.co/docs/huggingface_hub/en/guides/jobs) on
Hugging Face infrastructure.
- [Search](https://huggingface.co/docs/huggingface_hub/en/guides/search) for
models, datasets and Spaces.
- [Share Model
Cards](https://huggingface.co/docs/huggingface_hub/en/guides/model-cards) to
document your models.
- [Engage with the
community](https://huggingface.co/docs/huggingface_hub/en/guides/community)
through PRs and comments.
+- Do all of the above from the terminal with the [`hf`
CLI](https://huggingface.co/docs/huggingface_hub/en/guides/cli).
+
+## Built for humans and AI agents
+
+The `hf` CLI is designed for people and coding agents alike: the same commands
adapt their output when run by an agent. If you use Claude Code, Codex, Cursor,
or another coding agent, install the `hf` CLI Skill — a command reference
generated from your installed CLI:
+
+```bash
+# for Codex, Cursor, OpenCode, Pi and other agents that load skills from
`.agents/skills`
+hf skills add
+# includes the above + Claude Code
+hf skills add --claude
+```
-## Installation
+Learn more in the [Hugging Face CLI for AI agents
guide](https://huggingface.co/docs/hub/agents-cli) and the [announcement blog
post](https://huggingface.co/blog/hf-cli-for-agents).
-Install the `huggingface_hub` package with
[pip](https://pypi.org/project/huggingface-hub/):
+## Use the Python library
+
+Install the `huggingface_hub` package with
[pip](https://pypi.org/project/huggingface-hub/) (this also installs the `hf`
CLI):
```bash
pip install huggingface_hub
@@ -238,8 +294,6 @@
To learn more about installation and optional dependencies, check out the
[installation
guide](https://huggingface.co/docs/huggingface_hub/en/installation).
-## Quick start
-
### Download files
Download a single file
@@ -247,7 +301,7 @@
```py
from huggingface_hub import hf_hub_download
-hf_hub_download(repo_id="tiiuae/falcon-7b-instruct", filename="config.json")
+hf_hub_download(repo_id="zai-org/GLM-5.2", filename="config.json")
```
Or an entire repository
@@ -255,21 +309,11 @@
```py
from huggingface_hub import snapshot_download
-snapshot_download("stabilityai/stable-diffusion-2-1")
+snapshot_download("sentence-transformers/all-MiniLM-L6-v2")
```
Files will be downloaded in a local cache folder. More details in [this
guide](https://huggingface.co/docs/huggingface_hub/en/guides/manage-cache).
-### Login
-
-The Hugging Face Hub uses tokens to authenticate applications (see
[docs](https://huggingface.co/docs/hub/security-tokens)). To log in your
machine, run the following CLI:
-
-```bash
-hf auth login
-# or using an environment variable
-hf auth login --token $HUGGINGFACE_TOKEN
-```
-
### Create a repository
```py
@@ -304,16 +348,16 @@
)
```
-For details in the [upload
guide](https://huggingface.co/docs/huggingface_hub/en/guides/upload).
+More details in the [upload
guide](https://huggingface.co/docs/huggingface_hub/en/guides/upload).
-## Integrating to the Hub.
+## Integrating with the Hub.
We're partnering with cool open source ML libraries to provide free model
hosting and versioning. You can find the existing integrations
[here](https://huggingface.co/docs/hub/libraries).
The advantages are:
- Free model or dataset hosting for libraries and their users.
-- Built-in file versioning, even with very large files, thanks to a git-based
approach.
+- Built-in file versioning, even with very large files, made possible by
[Xet](https://huggingface.co/docs/hub/xet/index), the Hub's chunk-deduplicated
storage backend.
- In-browser widgets to play with the uploaded models.
- Anyone can upload a new model for your library, they just need to add the
corresponding tag for the model to be discoverable.
- Fast downloads! We use Cloudfront (a CDN) to geo-replicate downloads so
they're blazing fast from anywhere on the globe.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/huggingface_hub-1.23.0/tests/test_xet_progress_reporting.py
new/huggingface_hub-1.24.0/tests/test_xet_progress_reporting.py
--- old/huggingface_hub-1.23.0/tests/test_xet_progress_reporting.py
2026-07-09 16:49:06.000000000 +0200
+++ new/huggingface_hub-1.24.0/tests/test_xet_progress_reporting.py
2026-07-17 11:53:37.000000000 +0200
@@ -1,5 +1,7 @@
from huggingface_hub.utils._xet_progress_reporting import (
_finish_transfer_bar,
+ _format_speed_postfix,
+ _set_aggregate_rate_postfix,
_set_monotonic_total,
_update_transfer_bar,
)
@@ -17,6 +19,21 @@
pass
+class _RateBar:
+ """Stub bar exposing a tqdm-like ``format_dict['rate']`` and recording its
postfix."""
+
+ def __init__(self, rate):
+ self._rate = rate
+ self.postfix = None
+
+ @property
+ def format_dict(self):
+ return {"rate": self._rate}
+
+ def set_postfix_str(self, postfix: str, refresh: bool = False) -> None:
+ self.postfix = postfix
+
+
class TestXetProgressBarHelpers:
def test_set_monotonic_total_never_decreases(self):
bar = _RecordingBar(total=100)
@@ -42,3 +59,16 @@
bar.n = 2_000_000
_finish_transfer_bar(bar)
assert bar.total == 2_000_000
+
+ def test_aggregate_rate_postfix_reports_bar_own_summed_rate(self):
+ # Regression: shared snapshot bar must show its own aggregated
throughput, not a per-file rate.
+ # https://github.com/huggingface/huggingface_hub/issues/4519
+ bar = _RateBar(rate=234_000_000) # bytes/s summed across all files
+ _set_aggregate_rate_postfix(bar)
+ assert "MB/s" in bar.postfix
+ assert bar.postfix == _format_speed_postfix(234_000_000)
+
+ def test_aggregate_rate_postfix_handles_unknown_rate(self):
+ bar = _RateBar(rate=None)
+ _set_aggregate_rate_postfix(bar)
+ assert "???" in bar.postfix