Bug in Google Colab Assemble Everything (PyTorch)
Hugging Face Forums [Unofficial]
April 2, 2026
Description :
Notebook link : section6_pt.ipynb - Colab
Error: When executing the 2nd cell of the notebook, the following error:
TypeError Traceback (most recent call last)
/tmp/ipykernel_6268/743095204.py in <cell line: 0>() 2 3 checkpoint = "tblard/tf-allocine" ----> 4 tokenizer = AutoTokenizer.from_pretrained(checkpoint) 5 6 sequence = "J'ai attendu un cours d’HuggingFace toute ma vie."
3 frames
/usr/local/lib/python3.12/dist-packages/transformers/models/camembert/tokenization_camembert.py in __init__(self, bos_token, eos_token, sep_token, cls_token, unk_token, pad_token, mask_token, additional_special_tokens, add_prefix_space, vocab_file, vocab, **kwargs)
117 self._vocab = vocab
118 unk_index = next((i for i, (tok, _) in enumerate(self._vocab) if tok == str(unk_token)), 0)
--> 119 self._tokenizer = Tokenizer(Unigram(self._vocab, unk_id=unk_index, byte_fallback=False))
120 else:
121 self._vocab = [
TypeError: argument 'vocab': 'str' object cannot be converted to 'PyTuple'
- Model concerned : tblard/tf-allocine
Would it be possible to have a correction of the notebook in order to be able to run and test the code without errors?
Discussion in the ATmosphere