Skip to content

Hugging Face Acceleration

Hugging Face uses the same URL-prefix proxy as GitHub — prepend your HubProxy host to the full original URL.

Type Example
Model / dataset files huggingface.co/{user}/{repo}/resolve/...
Spaces huggingface.co/spaces/{user}/{repo}/...
LFS CDN cdn-lfs.hf.co/{user}/{repo}/...

Regex patterns are in githubExps in src/handlers/github.go.

Terminal window
curl -L -O "https://example.com/https://huggingface.co/bert-base-uncased/resolve/main/config.json"
curl -L -O "https://example.com/huggingface.co/bert-base-uncased/resolve/main/pytorch_model.bin"
curl -L -O "https://example.com/https://cdn-lfs.hf.co/user/model-repo/abc123..."

Same as GitHub Acceleration:

  • No HTML browsing
  • [server].fileSize cap
  • Same as GitHub: supports Range resume and multi-connection downloads — see Transfer Capabilities
  • [access] allow/deny lists apply