ChatterBot icon indicating copy to clipboard operation
ChatterBot copied to clipboard

AttributeError: 'French' object has no attribute 'ISO_639_1'

Open nozyx12 opened this issue 2 years ago • 1 comments

Hey, I have this error when i try to start my program :

Traceback (most recent call last):
  File "D:\DEV\ia\main.py", line 9, in <module>
    chatbot = ChatBot(
              ^^^^^^^^
  File "C:\Users\eziot\AppData\Roaming\Python\Python312\site-packages\chatterbot\chatterbot.py", line 28, in __init__
    self.storage = utils.initialize_class(storage_adapter, **kwargs)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\eziot\AppData\Roaming\Python\Python312\site-packages\chatterbot\utils.py", line 33, in initialize_class
    return Class(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\eziot\AppData\Roaming\Python\Python312\site-packages\chatterbot\storage\sql_storage.py", line 20, in __init__
    super().__init__(**kwargs)
  File "C:\Users\eziot\AppData\Roaming\Python\Python312\site-packages\chatterbot\storage\storage_adapter.py", line 22, in __init__
    self.tagger = Tagger(language=kwargs.get(
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\eziot\AppData\Roaming\Python\Python312\site-packages\chatterbot\tagging.py", line 26, in __init__
    self.nlp = spacy.load(self.language.ISO_639_1.lower())
                          ^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'French' object has no attribute 'ISO_639_1'

Can you help me ?

nozyx12 avatar Nov 28 '23 17:11 nozyx12

image it is my way, hope help you.

WThirteen avatar Apr 11 '24 03:04 WThirteen