How to Point Hugging Face at Chainsaw

Beginner 15 minutes Developers / DevOps Engineers Getting Started

Route Hugging Face model and dataset downloads through your Chainsaw proxy with the HF_ENDPOINT environment variable.

Overview

Point the Hugging Face client at your Chainsaw instance so model and dataset downloads route through the firewall. This page covers the HF_ENDPOINT environment variable.

Replace chain305.com with your own Chainsaw deployment host and swap CLIENT_ID / CLIENT_SECRET for credentials issued from the Access page in the dashboard. The @default segment is the org slug — confirm yours under Settings → Organization → Slug. Legacy non-org-scoped URLs return HTTP 400 with error CHW-4314.

Prerequisites

  • A running Chainsaw instance (see Tutorial 01)
  • Client credentials (Client ID and Secret)
  • The Hugging Face client / huggingface_hub installed

Clear Local Caches (First-Time Setup)

rm -rf ~/.cache/huggingface/

Environment Variable

export HF_ENDPOINT=https://CLIENT_ID:CLIENT_SECRET@chain305.com/chainproxy/repository/@default/huggingface/

Large model weights (LFS) and git clone against Hugging Face repos route through the proxy transparently — no extra client config beyond HF_ENDPOINT. Both git smart-HTTP and the LFS object protocol are passthrough’d as of the 2026-05 HF fix.

Verify

Download a small model, then confirm with chainsaw doctor verify-hook and the Traffic page in the dashboard.

Next Steps