1
0
Fork 0
mirror of https://github.com/p-e-w/heretic.git synced 2026-12-03 18:42:57 +07:00

[GH-ISSUE #155] feature model ministral #91

Closed
opened 2026-11-01 04:17:26 +07:00 by bsakaguchi · 3 comments
Owner

Originally created by @kalle07 on GitHub (Feb 14, 2026).
Original GitHub issue: https://github.com/p-e-w/heretic/issues/155

(myenv) e:\heretic>heretic mistralai/Ministral-3-8B-Instruct-2512
█░█░█▀▀░█▀▄░█▀▀░▀█▀░█░█▀▀ v1.2.0
█▀█░█▀▀░█▀▄░█▀▀░░█░░█░█░░
▀░▀░▀▀▀░▀░▀░▀▀▀░░▀░░▀░▀▀▀ https://github.com/p-e-w/heretic

Detected 1 CUDA device(s):

  • GPU 0: NVIDIA GeForce RTX 4060 Ti

Loading model mistralai/Ministral-3-8B-Instruct-2512...
tokenizer_config.json: 21.2kB [00:00, ?B/s]
╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮
│ C:\Users...\AppData\Local\Programs\Python\Python310\lib\runpy.py:196 in │
│ _run_module_as_main │
│ │
│ 193 │ main_globals = sys.modules["main"].dict │
│ 194 │ if alter_argv: │
│ 195 │ │ sys.argv[0] = mod_spec.origin │
│ ❱ 196 │ return _run_code(code, main_globals, None, │
│ 197 │ │ │ │ │ "main", mod_spec) │
│ 198 │
│ 199 def run_module(mod_name, init_globals=None, │
│ │
│ C:\Users...\AppData\Local\Programs\Python\Python310\lib\runpy.py:86 in _run_code │
│ │
│ 83 │ │ │ │ │ loader = loader, │
│ 84 │ │ │ │ │ package = pkg_name, │
│ 85 │ │ │ │ │ spec = mod_spec) │
│ ❱ 86 │ exec(code, run_globals) │
│ 87 │ return run_globals │
│ 88 │
│ 89 def _run_module_code(code, init_globals=None, │
│ │
│ in :5 │
│ │
│ 2 from heretic.main import main │
│ 3 if name == 'main': │
│ 4 │ sys.argv[0] = sys.argv[0].removesuffix('.exe') │
│ ❱ 5 │ sys.exit(main()) │
│ 6 │
│ │
│ e:\heretic\myenv\lib\site-packages\heretic\main.py:891 in main │
│ │
│ 888 │ install() │
│ 889 │ │
│ 890 │ try: │
│ ❱ 891 │ │ run() │
│ 892 │ except BaseException as error: │
│ 893 │ │ # Transformers appears to handle KeyboardInterrupt (or BaseException) │
│ 894 │ │ # internally in some places, which can re-raise a different error in the handler │
│ │
│ e:\heretic\myenv\lib\site-packages\heretic\main.py:312 in run │
│ │
│ 309 │ │ elif choice is None or choice == "": │
│ 310 │ │ │ return │
│ 311 │ │
│ ❱ 312 │ model = Model(settings) │
│ 313 │ print() │
│ 314 │ print_memory_usage() │
│ 315 │
│ │
│ e:\heretic\myenv\lib\site-packages\heretic\model.py:68 in init │
│ │
│ 65 │ │ print() │
│ 66 │ │ print(f"Loading model [bold]{settings.model}[/]...") │
│ 67 │ │ │
│ ❱ 68 │ │ self.tokenizer = AutoTokenizer.from_pretrained( │
│ 69 │ │ │ settings.model, │
│ 70 │ │ │ trust_remote_code=settings.trust_remote_code, │
│ 71 │ │ ) │
│ │
│ e:\heretic\myenv\lib\site-packages\transformers\models\auto\tokenization_auto.py:1153 in │
│ from_pretrained │
│ │
│ 1150 │ │ │ │ tokenizer_class_candidate = config_tokenizer_class │
│ 1151 │ │ │ │ tokenizer_class = tokenizer_class_from_name(tokenizer_class_candidate) │
│ 1152 │ │ │ if tokenizer_class is None: │
│ ❱ 1153 │ │ │ │ raise ValueError( │
│ 1154 │ │ │ │ │ f"Tokenizer class {tokenizer_class_candidate} does not exist or is n │
│ 1155 │ │ │ │ ) │
│ 1156 │ │ │ return tokenizer_class.from_pretrained(pretrained_model_name_or_path, *input │
╰──────────────────────────────────────────────────────────────────────────────────────────────────╯
ValueError: Tokenizer class TokenizersBackend does not exist or is not currently imported.

Originally created by @kalle07 on GitHub (Feb 14, 2026). Original GitHub issue: https://github.com/p-e-w/heretic/issues/155 (myenv) e:\heretic>heretic mistralai/Ministral-3-8B-Instruct-2512 █░█░█▀▀░█▀▄░█▀▀░▀█▀░█░█▀▀ v1.2.0 █▀█░█▀▀░█▀▄░█▀▀░░█░░█░█░░ ▀░▀░▀▀▀░▀░▀░▀▀▀░░▀░░▀░▀▀▀ https://github.com/p-e-w/heretic Detected 1 CUDA device(s): * GPU 0: NVIDIA GeForce RTX 4060 Ti Loading model mistralai/Ministral-3-8B-Instruct-2512... tokenizer_config.json: 21.2kB [00:00, ?B/s] ╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮ │ C:\Users\...\AppData\Local\Programs\Python\Python310\lib\runpy.py:196 in │ │ _run_module_as_main │ │ │ │ 193 │ main_globals = sys.modules["__main__"].__dict__ │ │ 194 │ if alter_argv: │ │ 195 │ │ sys.argv[0] = mod_spec.origin │ │ ❱ 196 │ return _run_code(code, main_globals, None, │ │ 197 │ │ │ │ │ "__main__", mod_spec) │ │ 198 │ │ 199 def run_module(mod_name, init_globals=None, │ │ │ │ C:\Users\...\AppData\Local\Programs\Python\Python310\lib\runpy.py:86 in _run_code │ │ │ │ 83 │ │ │ │ │ __loader__ = loader, │ │ 84 │ │ │ │ │ __package__ = pkg_name, │ │ 85 │ │ │ │ │ __spec__ = mod_spec) │ │ ❱ 86 │ exec(code, run_globals) │ │ 87 │ return run_globals │ │ 88 │ │ 89 def _run_module_code(code, init_globals=None, │ │ │ │ in <module>:5 │ │ │ │ 2 from heretic.main import main │ │ 3 if __name__ == '__main__': │ │ 4 │ sys.argv[0] = sys.argv[0].removesuffix('.exe') │ │ ❱ 5 │ sys.exit(main()) │ │ 6 │ │ │ │ e:\heretic\myenv\lib\site-packages\heretic\main.py:891 in main │ │ │ │ 888 │ install() │ │ 889 │ │ │ 890 │ try: │ │ ❱ 891 │ │ run() │ │ 892 │ except BaseException as error: │ │ 893 │ │ # Transformers appears to handle KeyboardInterrupt (or BaseException) │ │ 894 │ │ # internally in some places, which can re-raise a different error in the handler │ │ │ │ e:\heretic\myenv\lib\site-packages\heretic\main.py:312 in run │ │ │ │ 309 │ │ elif choice is None or choice == "": │ │ 310 │ │ │ return │ │ 311 │ │ │ ❱ 312 │ model = Model(settings) │ │ 313 │ print() │ │ 314 │ print_memory_usage() │ │ 315 │ │ │ │ e:\heretic\myenv\lib\site-packages\heretic\model.py:68 in __init__ │ │ │ │ 65 │ │ print() │ │ 66 │ │ print(f"Loading model [bold]{settings.model}[/]...") │ │ 67 │ │ │ │ ❱ 68 │ │ self.tokenizer = AutoTokenizer.from_pretrained( │ │ 69 │ │ │ settings.model, │ │ 70 │ │ │ trust_remote_code=settings.trust_remote_code, │ │ 71 │ │ ) │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\models\auto\tokenization_auto.py:1153 in │ │ from_pretrained │ │ │ │ 1150 │ │ │ │ tokenizer_class_candidate = config_tokenizer_class │ │ 1151 │ │ │ │ tokenizer_class = tokenizer_class_from_name(tokenizer_class_candidate) │ │ 1152 │ │ │ if tokenizer_class is None: │ │ ❱ 1153 │ │ │ │ raise ValueError( │ │ 1154 │ │ │ │ │ f"Tokenizer class {tokenizer_class_candidate} does not exist or is n │ │ 1155 │ │ │ │ ) │ │ 1156 │ │ │ return tokenizer_class.from_pretrained(pretrained_model_name_or_path, *input │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ ValueError: Tokenizer class TokenizersBackend does not exist or is not currently imported.
Author
Owner

@0xA50C1A1 commented on GitHub (Feb 14, 2026):

Try this one https://huggingface.co/unsloth/Ministral-3-8B-Instruct-2512

<!-- gh-comment-id:3902410013 --> @0xA50C1A1 commented on GitHub (Feb 14, 2026): Try this one https://huggingface.co/unsloth/Ministral-3-8B-Instruct-2512
Author
Owner

@kalle07 commented on GitHub (Feb 15, 2026):

thx, but after install protobuf

(myenv) e:\heretic>heretic unsloth/Ministral-3-3B-Instruct-2512
█░█░█▀▀░█▀▄░█▀▀░▀█▀░█░█▀▀  v1.2.0
█▀█░█▀▀░█▀▄░█▀▀░░█░░█░█░░
▀░▀░▀▀▀░▀░▀░▀▀▀░░▀░░▀░▀▀▀  https://github.com/p-e-w/heretic

Detected 1 CUDA device(s):
* GPU 0: NVIDIA GeForce RTX 4060 Ti

Loading model unsloth/Ministral-3-3B-Instruct-2512...
╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮
│ C:\Users\...\AppData\Local\Programs\Python\Python310\lib\runpy.py:196 in                    │
│ _run_module_as_main                                                                              │
│                                                                                                  │
│   193 │   main_globals = sys.modules["__main__"].__dict__                                        │
│   194 │   if alter_argv:                                                                         │
│   195 │   │   sys.argv[0] = mod_spec.origin                                                      │
│ ❱ 196 │   return _run_code(code, main_globals, None,                                             │
│   197 │   │   │   │   │    "__main__", mod_spec)                                                 │
│   198                                                                                            │
│   199 def run_module(mod_name, init_globals=None,                                                │
│                                                                                                  │
│ C:\Users\...\AppData\Local\Programs\Python\Python310\lib\runpy.py:86 in _run_code           │
│                                                                                                  │
│    83 │   │   │   │   │      __loader__ = loader,                                                │
│    84 │   │   │   │   │      __package__ = pkg_name,                                             │
│    85 │   │   │   │   │      __spec__ = mod_spec)                                                │
│ ❱  86 │   exec(code, run_globals)                                                                │
│    87 │   return run_globals                                                                     │
│    88                                                                                            │
│    89 def _run_module_code(code, init_globals=None,                                              │
│                                                                                                  │
│ in <module>:5                                                                                    │
│                                                                                                  │
│   2 from heretic.main import main                                                                │
│   3 if __name__ == '__main__':                                                                   │
│   4 │   sys.argv[0] = sys.argv[0].removesuffix('.exe')                                           │
│ ❱ 5 │   sys.exit(main())                                                                         │
│   6                                                                                              │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\heretic\main.py:891 in main                                   │
│                                                                                                  │
│   888 │   install()                                                                              │
│   889 │                                                                                          │
│   890 │   try:                                                                                   │
│ ❱ 891 │   │   run()                                                                              │
│   892 │   except BaseException as error:                                                         │
│   893 │   │   # Transformers appears to handle KeyboardInterrupt (or BaseException)              │
│   894 │   │   # internally in some places, which can re-raise a different error in the handler   │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\heretic\main.py:312 in run                                    │
│                                                                                                  │
│   309 │   │   elif choice is None or choice == "":                                               │
│   310 │   │   │   return                                                                         │
│   311 │                                                                                          │
│ ❱ 312 │   model = Model(settings)                                                                │
│   313 │   print()                                                                                │
│   314 │   print_memory_usage()                                                                   │
│   315                                                                                            │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\heretic\model.py:68 in __init__                               │
│                                                                                                  │
│    65 │   │   print()                                                                            │
│    66 │   │   print(f"Loading model [bold]{settings.model}[/]...")                               │
│    67 │   │                                                                                      │
│ ❱  68 │   │   self.tokenizer = AutoTokenizer.from_pretrained(                                    │
│    69 │   │   │   settings.model,                                                                │
│    70 │   │   │   trust_remote_code=settings.trust_remote_code,                                  │
│    71 │   │   )                                                                                  │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\models\auto\tokenization_auto.py:1156 in         │
│ from_pretrained                                                                                  │
│                                                                                                  │
│   1153 │   │   │   │   raise ValueError(                                                         │
│   1154 │   │   │   │   │   f"Tokenizer class {tokenizer_class_candidate} does not exist or is n  │
│   1155 │   │   │   │   )                                                                         │
│ ❱ 1156 │   │   │   return tokenizer_class.from_pretrained(pretrained_model_name_or_path, *input  │
│   1157 │   │                                                                                     │
│   1158 │   │   # Otherwise we have to be creative.                                               │
│   1159 │   │   # if model is an encoder decoder, the encoder tokenizer class is used by default  │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:2113 in               │
│ from_pretrained                                                                                  │
│                                                                                                  │
│   2110 │   │   │   else:                                                                         │
│   2111 │   │   │   │   logger.info(f"loading file {file_path} from cache at {resolved_vocab_fil  │
│   2112 │   │                                                                                     │
│ ❱ 2113 │   │   return cls._from_pretrained(                                                      │
│   2114 │   │   │   resolved_vocab_files,                                                         │
│   2115 │   │   │   pretrained_model_name_or_path,                                                │
│   2116 │   │   │   init_configuration,                                                           │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:2359 in               │
│ _from_pretrained                                                                                 │
│                                                                                                  │
│   2356 │   │                                                                                     │
│   2357 │   │   # Instantiate the tokenizer.                                                      │
│   2358 │   │   try:                                                                              │
│ ❱ 2359 │   │   │   tokenizer = cls(*init_inputs, **init_kwargs)                                  │
│   2360 │   │   except import_protobuf_decode_error():                                            │
│   2361 │   │   │   logger.info(                                                                  │
│   2362 │   │   │   │   "Unable to load tokenizer model from SPM, loading from TikToken will be   │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\models\llama\tokenization_llama_fast.py:154 in   │
│ __init__                                                                                         │
│                                                                                                  │
│   151 │   │   if add_prefix_space is not None:                                                   │
│   152 │   │   │   kwargs["from_slow"] = True                                                     │
│   153 │   │                                                                                      │
│ ❱ 154 │   │   super().__init__(                                                                  │
│   155 │   │   │   vocab_file=vocab_file,                                                         │
│   156 │   │   │   tokenizer_file=tokenizer_file,                                                 │
│   157 │   │   │   clean_up_tokenization_spaces=clean_up_tokenization_spaces,                     │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_fast.py:178 in __init__       │
│                                                                                                  │
│   175 │   │   │   kwargs.setdefault("pad_to_multiple_of", _padding["pad_to_multiple_of"])        │
│   176 │   │                                                                                      │
│   177 │   │   # We call this after having initialized the backend tokenizer because we update    │
│ ❱ 178 │   │   super().__init__(**kwargs)                                                         │
│   179 │   │   self._tokenizer.encode_special_tokens = self.split_special_tokens                  │
│   180 │   │                                                                                      │
│   181 │   │   added_tokens_decoder_hash = {hash(repr(token)) for token in self.added_tokens_de   │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:1469 in __init__      │
│                                                                                                  │
│   1466 │   │   │   # we reconstruct that into a single dict while loading them.                  │
│   1467 │   │   │   self.chat_template = {template["name"]: template["template"] for template in  │
│   1468 │   │                                                                                     │
│ ❱ 1469 │   │   super().__init__(**kwargs)                                                        │
│   1470 │   │                                                                                     │
│   1471 │   │   self.extra_special_tokens = kwargs.pop("extra_special_tokens", {})                │
│   1472 │   │   self._set_model_specific_special_tokens(special_tokens=self.extra_special_tokens  │
│                                                                                                  │
│ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:902 in __init__       │
│                                                                                                  │
│    899 │   │   │   if key in self.SPECIAL_TOKENS_ATTRIBUTES:                                     │
│    900 │   │   │   │   if key == "additional_special_tokens":                                    │
│    901 │   │   │   │   │   assert isinstance(value, (list, tuple)), f"Value {value} is not a li  │
│ ❱  902 │   │   │   │   │   assert all(isinstance(t, (str, AddedToken)) for t in value), (        │
│    903 │   │   │   │   │   │   "One of the tokens is not a string or an AddedToken"              │
│    904 │   │   │   │   │   )                                                                     │
│    905 │   │   │   │   │   setattr(self, key, value)                                             │
╰──────────────────────────────────────────────────────────────────────────────────────────────────╯
AssertionError: One of the tokens is not a string or an AddedToken
<!-- gh-comment-id:3903734626 --> @kalle07 commented on GitHub (Feb 15, 2026): thx, but after install protobuf ``` (myenv) e:\heretic>heretic unsloth/Ministral-3-3B-Instruct-2512 █░█░█▀▀░█▀▄░█▀▀░▀█▀░█░█▀▀ v1.2.0 █▀█░█▀▀░█▀▄░█▀▀░░█░░█░█░░ ▀░▀░▀▀▀░▀░▀░▀▀▀░░▀░░▀░▀▀▀ https://github.com/p-e-w/heretic Detected 1 CUDA device(s): * GPU 0: NVIDIA GeForce RTX 4060 Ti Loading model unsloth/Ministral-3-3B-Instruct-2512... ╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮ │ C:\Users\...\AppData\Local\Programs\Python\Python310\lib\runpy.py:196 in │ │ _run_module_as_main │ │ │ │ 193 │ main_globals = sys.modules["__main__"].__dict__ │ │ 194 │ if alter_argv: │ │ 195 │ │ sys.argv[0] = mod_spec.origin │ │ ❱ 196 │ return _run_code(code, main_globals, None, │ │ 197 │ │ │ │ │ "__main__", mod_spec) │ │ 198 │ │ 199 def run_module(mod_name, init_globals=None, │ │ │ │ C:\Users\...\AppData\Local\Programs\Python\Python310\lib\runpy.py:86 in _run_code │ │ │ │ 83 │ │ │ │ │ __loader__ = loader, │ │ 84 │ │ │ │ │ __package__ = pkg_name, │ │ 85 │ │ │ │ │ __spec__ = mod_spec) │ │ ❱ 86 │ exec(code, run_globals) │ │ 87 │ return run_globals │ │ 88 │ │ 89 def _run_module_code(code, init_globals=None, │ │ │ │ in <module>:5 │ │ │ │ 2 from heretic.main import main │ │ 3 if __name__ == '__main__': │ │ 4 │ sys.argv[0] = sys.argv[0].removesuffix('.exe') │ │ ❱ 5 │ sys.exit(main()) │ │ 6 │ │ │ │ e:\heretic\myenv\lib\site-packages\heretic\main.py:891 in main │ │ │ │ 888 │ install() │ │ 889 │ │ │ 890 │ try: │ │ ❱ 891 │ │ run() │ │ 892 │ except BaseException as error: │ │ 893 │ │ # Transformers appears to handle KeyboardInterrupt (or BaseException) │ │ 894 │ │ # internally in some places, which can re-raise a different error in the handler │ │ │ │ e:\heretic\myenv\lib\site-packages\heretic\main.py:312 in run │ │ │ │ 309 │ │ elif choice is None or choice == "": │ │ 310 │ │ │ return │ │ 311 │ │ │ ❱ 312 │ model = Model(settings) │ │ 313 │ print() │ │ 314 │ print_memory_usage() │ │ 315 │ │ │ │ e:\heretic\myenv\lib\site-packages\heretic\model.py:68 in __init__ │ │ │ │ 65 │ │ print() │ │ 66 │ │ print(f"Loading model [bold]{settings.model}[/]...") │ │ 67 │ │ │ │ ❱ 68 │ │ self.tokenizer = AutoTokenizer.from_pretrained( │ │ 69 │ │ │ settings.model, │ │ 70 │ │ │ trust_remote_code=settings.trust_remote_code, │ │ 71 │ │ ) │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\models\auto\tokenization_auto.py:1156 in │ │ from_pretrained │ │ │ │ 1153 │ │ │ │ raise ValueError( │ │ 1154 │ │ │ │ │ f"Tokenizer class {tokenizer_class_candidate} does not exist or is n │ │ 1155 │ │ │ │ ) │ │ ❱ 1156 │ │ │ return tokenizer_class.from_pretrained(pretrained_model_name_or_path, *input │ │ 1157 │ │ │ │ 1158 │ │ # Otherwise we have to be creative. │ │ 1159 │ │ # if model is an encoder decoder, the encoder tokenizer class is used by default │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:2113 in │ │ from_pretrained │ │ │ │ 2110 │ │ │ else: │ │ 2111 │ │ │ │ logger.info(f"loading file {file_path} from cache at {resolved_vocab_fil │ │ 2112 │ │ │ │ ❱ 2113 │ │ return cls._from_pretrained( │ │ 2114 │ │ │ resolved_vocab_files, │ │ 2115 │ │ │ pretrained_model_name_or_path, │ │ 2116 │ │ │ init_configuration, │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:2359 in │ │ _from_pretrained │ │ │ │ 2356 │ │ │ │ 2357 │ │ # Instantiate the tokenizer. │ │ 2358 │ │ try: │ │ ❱ 2359 │ │ │ tokenizer = cls(*init_inputs, **init_kwargs) │ │ 2360 │ │ except import_protobuf_decode_error(): │ │ 2361 │ │ │ logger.info( │ │ 2362 │ │ │ │ "Unable to load tokenizer model from SPM, loading from TikToken will be │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\models\llama\tokenization_llama_fast.py:154 in │ │ __init__ │ │ │ │ 151 │ │ if add_prefix_space is not None: │ │ 152 │ │ │ kwargs["from_slow"] = True │ │ 153 │ │ │ │ ❱ 154 │ │ super().__init__( │ │ 155 │ │ │ vocab_file=vocab_file, │ │ 156 │ │ │ tokenizer_file=tokenizer_file, │ │ 157 │ │ │ clean_up_tokenization_spaces=clean_up_tokenization_spaces, │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_fast.py:178 in __init__ │ │ │ │ 175 │ │ │ kwargs.setdefault("pad_to_multiple_of", _padding["pad_to_multiple_of"]) │ │ 176 │ │ │ │ 177 │ │ # We call this after having initialized the backend tokenizer because we update │ │ ❱ 178 │ │ super().__init__(**kwargs) │ │ 179 │ │ self._tokenizer.encode_special_tokens = self.split_special_tokens │ │ 180 │ │ │ │ 181 │ │ added_tokens_decoder_hash = {hash(repr(token)) for token in self.added_tokens_de │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:1469 in __init__ │ │ │ │ 1466 │ │ │ # we reconstruct that into a single dict while loading them. │ │ 1467 │ │ │ self.chat_template = {template["name"]: template["template"] for template in │ │ 1468 │ │ │ │ ❱ 1469 │ │ super().__init__(**kwargs) │ │ 1470 │ │ │ │ 1471 │ │ self.extra_special_tokens = kwargs.pop("extra_special_tokens", {}) │ │ 1472 │ │ self._set_model_specific_special_tokens(special_tokens=self.extra_special_tokens │ │ │ │ e:\heretic\myenv\lib\site-packages\transformers\tokenization_utils_base.py:902 in __init__ │ │ │ │ 899 │ │ │ if key in self.SPECIAL_TOKENS_ATTRIBUTES: │ │ 900 │ │ │ │ if key == "additional_special_tokens": │ │ 901 │ │ │ │ │ assert isinstance(value, (list, tuple)), f"Value {value} is not a li │ │ ❱ 902 │ │ │ │ │ assert all(isinstance(t, (str, AddedToken)) for t in value), ( │ │ 903 │ │ │ │ │ │ "One of the tokens is not a string or an AddedToken" │ │ 904 │ │ │ │ │ ) │ │ 905 │ │ │ │ │ setattr(self, key, value) │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ AssertionError: One of the tokens is not a string or an AddedToken ```
Author
Owner

@kalle07 commented on GitHub (Feb 15, 2026):

seems works after install transformers 5.1.0

<!-- gh-comment-id:3904609592 --> @kalle07 commented on GitHub (Feb 15, 2026): seems works after install transformers 5.1.0
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
p-e-w/heretic#91
No description provided.