Hugginface transformers downloading models doesnt work!
Author: lucian-student
Pull request: no
Labels: name: bug

### System Info

Basically it just doesn't work any model i use i get this: 

```
2025-10-23 12:44:00.017829: E external/local_xla/xla/stream_executor/cuda/cuda_fft.cc:477] Unable to register cuFFT factory: Attempting to register factory for plugin cuFFT when one has already been registered
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
E0000 00:00:1761223440.296880      80 cuda_dnn.cc:8310] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
E0000 00:00:1761223440.385113      80 cuda_blas.cc:1418] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
2025-10-23 12:44:18.303400: E external/local_xla/xla/stream_executor/cuda/cuda_driver.cc:152] failed call to cuInit: INTERNAL: CUDA error: Failed call to cuInit: UNKNOWN ERROR (303)
INFO:2025-10-23 12:44:19,038:jax._src.xla_bridge:924: Unable to initialize backend 'rocm': module 'jaxlib.xla_extension' has no attribute 'GpuAllocatorConfig'
INFO:2025-10-23 12:44:19,054:jax._src.xla_bridge:924: Unable to initialize backend 'tpu': INTERNAL: Failed to open libtpu.so: libtpu.so: cannot open shared object file: No such file or directory

Copy-and-paste the text below in your GitHub issue and FILL OUT the two last points.

- `transformers` version: 4.53.3
- Platform: Linux-6.6.56+-x86_64-with-glibc2.35
- Python version: 3.11.13
- Huggingface_hub version: 1.0.0.rc2
- Safetensors version: 0.5.3
- Accelerate version: 1.9.0
- Accelerate config: 	not found
- DeepSpeed version: not installed
- PyTorch version (accelerator?): 2.6.0+cu124 (NA)
- Tensorflow version (GPU?): 2.18.0 (False)
- Flax version (CPU?/GPU?/TPU?): 0.10.6 (cpu)
- Jax version: 0.5.2
- JaxLib version: 0.5.1
- Using distributed or parallel set-up in script?: <fill in>

```

```
Version '4.53.3'
```

```
---------------------------------------------------------------------------
HTTPStatusError                           Traceback (most recent call last)
/usr/local/lib/python3.11/dist-packages/huggingface_hub/utils/_http.py in hf_raise_for_status(response, endpoint_name)
    556     try:
--> 557         response.raise_for_status()
    558     except httpx.HTTPStatusError as e:

/usr/local/lib/python3.11/dist-packages/httpx/_models.py in raise_for_status(self)
    828         message = message.format(self, error_type=error_type)
--> 829         raise HTTPStatusError(message, request=request, response=self)
    830 

HTTPStatusError: Client error '404 Not Found' for url 'https://huggingface.co/api/models/Qwen/Qwen3-Embedding-0.6B/tree/main/additional_chat_templates?recursive=false&expand=false'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/404

The above exception was the direct cause of the following exception:

RemoteEntryNotFoundError                  Traceback (most recent call last)
/tmp/ipykernel_37/2822320637.py in <cell line: 0>()
----> 1 tokenizer = AutoTokenizer.from_pretrained('Qwen/Qwen3-Embedding-0.6B', padding_side='left')
      2 #model = AutoModel.from_pretrained('intfloat/multilingual-e5-large-instruct')

/usr/local/lib/python3.11/dist-packages/transformers/models/auto/tokenization_auto.py in from_pretrained(cls, pretrained_model_name_or_path, *inputs, **kwargs)
   1048                     f"Tokenizer class {tokenizer_class_candidate} does not exist or is not currently imported."
   1049                 )
-> 1050             return tokenizer_class.from_pretrained(pretrained_model_name_or_path, *inputs, **kwargs)
   1051 
   1052         # Otherwise we have to be creative.

/usr/local/lib/python3.11/dist-packages/transformers/tokenization_utils_base.py in from_pretrained(cls, pretrained_model_name_or_path, cache_dir, force_download, local_files_only, token, revision, trust_remote_code, *init_inputs, **kwargs)
   1955                                 )
   1956                     else:
-> 1957                         for template in list_repo_templates(
   1958                             pretrained_model_name_or_path,
   1959                             local_files_only=local_files_only,

/usr/local/lib/python3.11/dist-packages/transformers/utils/hub.py in list_repo_templates(repo_id, local_files_only, revision, cache_dir)
    159     if not local_files_only:
    160         try:
--> 161             return [
    162                 entry.path.removeprefix(f"{CHAT_TEMPLATE_DIR}/")
    163                 for entry in list_repo_tree(

/usr/local/lib/python3.11/dist-packages/transformers/utils/hub.py in <listcomp>(.0)
    159     if not local_files_only:
    160         try:
--> 161             return [
    162                 entry.path.removeprefix(f"{CHAT_TEMPLATE_DIR}/")
    163                 for entry in list_repo_tree(

/usr/local/lib/python3.11/dist-packages/huggingface_hub/hf_api.py in list_repo_tree(self, repo_id, path_in_repo, recursive, expand, revision, repo_type, token)
   3050         encoded_path_in_repo = "/" + quote(path_in_repo, safe="") if path_in_repo else ""
   3051         tree_url = f"{self.endpoint}/api/{repo_type}s/{repo_id}/tree/{revision}{encoded_path_in_repo}"
-> 3052         for path_info in paginate(path=tree_url, headers=headers, params={"recursive": recursive, "expand": expand}):
   3053             yield (RepoFile(**path_info) if path_info["type"] == "file" else RepoFolder(**path_info))
   3054 

/usr/local/lib/python3.11/dist-packages/huggingface_hub/utils/_pagination.py in paginate(path, params, headers)
     35     session = get_session()
     36     r = session.get(path, params=params, headers=headers)
---> 37     hf_raise_for_status(r)
     38     yield from r.json()
     39 

/usr/local/lib/python3.11/dist-packages/huggingface_hub/utils/_http.py in hf_raise_for_status(response, endpoint_name)
    569         elif error_code == "EntryNotFound":
    570             message = f"{response.status_code} Client Error." + "\n\n" + f"Entry Not Found for url: {response.url}."
--> 571             raise _format(RemoteEntryNotFoundError, message, response) from e
    572 
    573         elif error_code == "GatedRepo":

RemoteEntryNotFoundError: 404 Client Error. (Request ID: Root=1-68fa2240-68b5fae228e82ffa137fd62f;5f0b9cd4-e975-4d6d-b60b-42eba4e50412)

Entry Not Found for url: https://huggingface.co/api/models/Qwen/Qwen3-Embedding-0.6B/tree/main/additional_chat_templates?recursive=false&expand=false.
additional_chat_templates does not exist on "main"
```

### Who can help?

_No response_

### Information

- [x] The official example scripts
- [ ] My own modified scripts

### Tasks

- [x] An officially supported task in the `examples` folder (such as GLUE/SQuAD, ...)
- [ ] My own task or dataset (give details below)

### Reproduction

tokenizer = AutoTokenizer.from_pretrained('Qwen/Qwen3-Embedding-0.6B', padding_side='left')

### Expected behavior

Expected behaviour is downloading tokenizer.

Comments:
@ManishhDev pasting Copilot answers into chat is not always helpful, and some of that is definitely misleading! In this case this is a bug from a previous version that should be resolved if you `pip install --upgrade transformers` @lucian-student 

> [@ManishhDev](https://github.com/ManishhDev) pasting Copilot answers into chat is not always helpful, and some of that is definitely misleading! In this case this is a bug from a previous version that should be resolved if you `pip install --upgrade transformers` [@lucian-student](https://github.com/lucian-student)

I'm using the transformers 4.57.1 which seems to be the latest version, but the error is still there, Qwen3 really doesn't have additional_chat_templates 

Was just having the same issue on Kaggle, turns out the update and restart kernel does actually work.

I'm currently running with no issues, after running:

`!pip install -U transformers -q`

My current version is: **4.57.1**


All this works fine:

```
import torch
from transformers import AutoTokenizer, AutoModel

model_name = 'Qwen/Qwen3-Embedding-0.6B'
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModel.from_pretrained(model_name).to('cuda')

sentences = ['Whatever your input sentence is...']

inputs = tokenizer(sentences, padding = True, truncation = True, return_tensors = 'pt').to('cuda')

with torch.no_grad():
    outputs = model(**inputs)
    embeddings = outputs.last_hidden_state.mean(dim = 1)

print(embeddings)
```

> Was just having the same issue on Kaggle, turns out the update and restart kernel does actually work.
> 
> I'm currently running with no issues, after running:
> 
> `!pip install -U transformers -q`
> 
> My current version is: **4.57.1**
> 
> All this works fine:
> 
> ```
> import torch
> from transformers import AutoTokenizer, AutoModel
> 
> model_name = 'Qwen/Qwen3-Embedding-0.6B'
> tokenizer = AutoTokenizer.from_pretrained(model_name)
> model = AutoModel.from_pretrained(model_name).to('cuda')
> 
> sentences = ['Whatever your input sentence is...']
> 
> inputs = tokenizer(sentences, padding = True, truncation = True, return_tensors = 'pt').to('cuda')
> 
> with torch.no_grad():
>     outputs = model(**inputs)
>     embeddings = outputs.last_hidden_state.mean(dim = 1)
> 
> print(embeddings)
> ```

bro, i try this. but console tell me that other dependencies does not work 

> > Was just having the same issue on Kaggle, turns out the update and restart kernel does actually work.
> > I'm currently running with no issues, after running:
> > `!pip install -U transformers -q`
> > My current version is: **4.57.1**
> > All this works fine:
> > ```
> > import torch
> > from transformers import AutoTokenizer, AutoModel
> > 
> > model_name = 'Qwen/Qwen3-Embedding-0.6B'
> > tokenizer = AutoTokenizer.from_pretrained(model_name)
> > model = AutoModel.from_pretrained(model_name).to('cuda')
> > 
> > sentences = ['Whatever your input sentence is...']
> > 
> > inputs = tokenizer(sentences, padding = True, truncation = True, return_tensors = 'pt').to('cuda')
> > 
> > with torch.no_grad():
> >     outputs = model(**inputs)
> >     embeddings = outputs.last_hidden_state.mean(dim = 1)
> > 
> > print(embeddings)
> > ```
> 
> bro, i try this. but console tell me that other dependencies does not work

That's odd.... Are you working on Kaggle or any other cloud platforms?
If not, are you working on your local machine within or without a virtual environment?

> > > Was just having the same issue on Kaggle, turns out the update and restart kernel does actually work.
> > > I'm currently running with no issues, after running:
> > > `!pip install -U transformers -q`
> > > My current version is: **4.57.1**
> > > All this works fine:
> > > ```
> > > import torch
> > > from transformers import AutoTokenizer, AutoModel
> > > 
> > > model_name = 'Qwen/Qwen3-Embedding-0.6B'
> > > tokenizer = AutoTokenizer.from_pretrained(model_name)
> > > model = AutoModel.from_pretrained(model_name).to('cuda')
> > > 
> > > sentences = ['Whatever your input sentence is...']
> > > 
> > > inputs = tokenizer(sentences, padding = True, truncation = True, return_tensors = 'pt').to('cuda')
> > > 
> > > with torch.no_grad():
> > >     outputs = model(**inputs)
> > >     embeddings = outputs.last_hidden_state.mean(dim = 1)
> > > 
> > > print(embeddings)
> > > ```
> > 
> > 
> > bro, i try this. but console tell me that other dependencies does not work
> 
> That's odd.... Are you working on Kaggle or any other cloud platforms? If not, are you working on your local machine within or without a virtual environment?

i have try "!pip install -U  transformers -q" last night on kaggle, the problem are still exist. now i use Google Colab, which only provide 5 hours free-gpu a week