OSError: [E050] Can't find model 'en_core_web_sm'.
Traceback (most recent call last):
File "F:\country stuff.py", line 11, in
and here is the code if you want it
from chatterbot import ChatBot from chatterbot.trainers import ChatterBotCorpusTrainer
bot = ChatBot('iris')
trainer = ChatterBotCorpusTrainer(bot)
trainer.train("chatterbot.corpus.english.greetings", "chatterbot.corpus.english.conversations")
while True: user_input = input("You: ") response = bot.get_response(user_input) print("Bot: ", response)
I got a similar error that this issue meet:
File "/home/shihai/py_venv/309/lib64/python3.9/site-packages/spacy/util.py", line 438, in load_model
OSError: [E941] Can't find model 'en'. It looks like you're trying to load a model from a shortcut, which is obsolete as of spaCy v3.0. To load the model, use its full name instead:
nlp = spacy.load("en_core_web_sm")
https://github.com/gunthercox/ChatterBot/issues/2287#issuecomment-1399571995
follow this installation, fixed the library with updated Spacy (will fix your issue)