Having the same issue with ‘sentence-transformers/all-mpnet-base-v2’. I saw there was an earlier thread on this too
  
    
    
    Batch transform inference job - downloading model from the Hugging Face Hub on start up Amazon SageMaker
  
  
    I try to run 

However I get this error: 
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: [https://huggingface.co/api/models/cardiffnlp/twitter-roberta-base-sentiment] 
It looks like an instance created by AWS SageMaker (client) is not allowed to download the model. Something specific I need to add in the role I use with AWS Sagemaker? 
or there is an issue with a token in 
model_info = _api.model_info(repo_id=model_id, revision=revision, token=use_auth_token) 
Thanks, 
Kate
  


Weirdly, I’m only getting it when trying to run batch on sagemaker
where I do it locally it works fine eg
model = AutoModel.from_pretrained(‘sentence-transformers/paraphrase-distilroberta-base-v2’)
and
model = AutoModel.from_pretrained(‘sentence-transformers/all-mpnet-base-v2’)
Checking the cloud log

This is an experimental beta features, which allows downloading model from the Hugging Face Hub on start up. It loads the model defined in the env var HF_MODEL_ID

Then immediately followed by the 403 error