Hugging Face · Cache and environment

Download one file from Python

Download a single file and get its local path.

from huggingface_hub import hf_hub_download

path = hf_hub_download(repo_id="bert-base-uncased", filename="config.json")

Official Hugging Face documentation

More cache and environment commands

All cache and environment commands · Hugging Face cheatsheet

Was this page helpful?