Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

about spacy module #3

Open
chinukgf opened this issue Feb 2, 2023 · 5 comments
Open

about spacy module #3

chinukgf opened this issue Feb 2, 2023 · 5 comments

Comments

@chinukgf
Copy link

chinukgf commented Feb 2, 2023

not loading the specified model
error
error
spacy.load("en_core_web_sm")

@ghost
Copy link

ghost commented Apr 11, 2023

Same I also have that problem. Author can you please let us know how to run the file.

@gkrishna1986
Copy link

Make sure you actually have the right spacy model installed. For example, install en_core_web_sm with the python -m spacy download en_core_web_sm command in the terminal.

Next, fix this error:

File "C:\Users\USER\AppData\Local\Programs\Python\Python37\lib\site-packages\chatterbot\tagging.py", line 13, in init

self.nlp = spacy.load(self.language.ISO_639_1.lower())

That is,

Open the C:\Users\USER\AppData\Local\Programs\Python\Python37\lib\site-packages\chatterbot\tagging.py file

Go to Line 13

Replace

self.nlp = spacy.load(self.language.ISO_639_1.lower())
with

if self.language.ISO_639_1.lower() == 'en':
self.nlp = spacy.load('en_core_web_sm')
else:
self.nlp = spacy.load(self.language.ISO_639_1.lower())

@gkrishna1986
Copy link

pip install jinja2==3.0.0

install the above package, it worked for me , i can run the project successfully

@rithikmathew
Copy link

can you help

File "D:\all\CRCE Bot\venv\lib\site-packages\spacy\util.py", line 471, in load_model
raise IOError(Errors.E941.format(name=name, full=OLD_MODEL_SHORTCUTS[name])) # type: ignore[index]
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")

For more details on the available models, see the models directory: https://spacy.io/models and if you want to create a blank model, use spacy.blank: nlp = spacy.blank("en")

@abhishek-0440
Copy link

pip install jinja2==3.0.0

install the above package, it worked for me , i can run the project successfully

Which python version and pip version you used and have you used any virtual environment??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants