Artifactory proxy/repository setup to huggingface.co Hub

Has anyone successfully setup an Artifactory remote proxy to the Hugging Face Hub (https://huggingface.co/)?

I created a GitLFS proxy in our instance of Artifactory however, I keep getting the following message:

$ git clone https://<user>:<token>@sres.web.<co>.com/artifactory/api/lfs/huggingface-lfs-remote/tiiuae/falcon-7b
Cloning into 'falcon-7b'...
fatal: repository 'https://sres.web.<co>.com/artifactory/api/lfs/huggingface-lfs-remote/tiiuae/falcon-7b/' not found

If I clone directly from the Hub though it works (Company doesn’t allow downloading directly from the internet so this is not an option).
git clone https://huggingface.co/tiiuae/falcon-7b

I setup an identical proxy in Artifactory using the Generic repo format and I have no problem using curl to download individual files from the hub.

> curl -H X-JFrog-Art-Api:$(cat ~/.api |grep prod |awk '{print $2}') https://sres.web.<co>.com/artifactory/huggingface/tiiuae/falcon-7b/resolve/main/tokenizer.json > downloads/tokenizer.json
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 2670k  100 2670k    0     0  2046k      0  0:00:01  0:00:01 --:--:-- 2047k

Hi FWord3
We have some amazing news for you!
We recently released our brand new HuggingFace dedicated local and remote repositories which are just the solution you are looking for.
We invite you to take a look at our documentation and to try it out as we have shared this as an open Beta for all our SaaS customers (available from Artifactory Version 7.69.4)

1 Like