# 404 when instantiating private model/tokenizer

**URL:** <https://discuss.huggingface.co/t/404-when-instantiating-private-model-tokenizer/4172>\
**Category:** Intermediate\
**Created:** [March 5, 2021, 6:24am UTC](https://discuss.huggingface.co/t/404-when-instantiating-private-model-tokenizer/4172 "2021-03-05T06:24:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jodiak](https://avatars.discourse-cdn.com/v4/letter/j/8797f3/32.png) [@jodiak](https://discuss.huggingface.co/u/jodiak)\
**Post date:** [March 5, 2021, 6:24am UTC](https://discuss.huggingface.co/t/404-when-instantiating-private-model-tokenizer/4172/1 "2021-03-05T06:24:21Z")

</div>

I think I might be missing something obvious, but when I attempt to load my private model checkpoint with the Auto\* classes and `use_auth=True` I’m getting a 404 response. I couldn’t find anything in the docs about the token/auth setup for the library so I’m not sure what’s wrong.

```python
from transformers import AutoTokenizer, AutoModelWithLMHead

tokenizer = AutoTokenizer.from_pretrained("jodiak/mymodel", use_auth=True)

model = AutoModelWithLMHead.from_pretrained("jodiak/mymodel", use_auth=True)
# 404 Client Error: Not Found for url: https://huggingface.co/jodiak/model/resolve/main/config.json

```

I’ve verified that I can load this directory locally and also that the path in model hub is correct. Any help here is appreciated.

---

<div class="post-metadata">

**Author:** ![Narsil](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/narsil/32/40029_2.png) [@Narsil](https://discuss.huggingface.co/u/Narsil)\
**Post date:** [March 5, 2021, 1:32pm UTC](https://discuss.huggingface.co/t/404-when-instantiating-private-model-tokenizer/4172/2 "2021-03-05T13:32:10Z")

</div>

Hi @jodiak, did you do the login phase ?

[https://huggingface.co/transformers/model\_sharing.html?highlight=login#basic-steps](https://huggingface.co/transformers/model_sharing.html?highlight=login#basic-steps)

That should create a `~/.huggingface/token` file (that is being used to see your private model).
