Error Installing Chatterbot using Python In Windows 2022

ALL VIEW

Error Installing Chatterbot using Python In Windows 2022

 Chatterbot Error While installing it using pip in python [Windows].

There are many kinds of error occurred while installing the chatterbot in python in which we see some possibilities of solving error technique. Most probably the errors will be shown on the command prompt, read the errors carefully so that we can get the solution easily from it.

Chatterbot in python


Most common errors occur while installing chatterbot:

-Installing build dependencies ... error 
 -ERROR: Failed building wheel for preshed 
 -ERROR: Failed building wheel for spacy 
 -Error: Failed to build thinc murmurhash cymem preshed srsly 
 -Error: Microsoft Visual C++ 14.0 or greater is required. 
 -ETC...


Python and Pip

Before going into that check your python version as well as pip version on windows using these commands

 >>python   
 >>python --version  

or

>>py --verison

And try pip version using

>>pip --version


Virtual environment or virtualenv -is a tool that creates an environment for python which is used for the execution of packages need for the python program.

#Install
>>py -m pip install --user virtualenv
#Create a folder for env
>>py -m venv env
#To activate env
>>env\Scripts\activate
#To deactivate
>>deactivate

After that, some chatterbot package will run using Flask, Django, Conda, Panda whatever your python code needs you may go for that.

And before that, some dependencies will be installed automatically with python but some not so you need to manually download the packages from Unofficial windows binaries for python.

The most common packages need for chatterbot is spacy, preshed, murmurhash, blis, nltk most propably this will automatically be installed if not you need to manually install or update that using these commands

>>pip install <package downloaded> #ends with .whl formate
>>pip install --upgrade <package name> #if already package is installed

NOTE: Carefully download and install the versions of the package which is suitable for your system 32bit or 64bit else it will not accept the package of higher or lower versions and shows an error like the below image.

Environment variables

Environment Variables Path

* And most important thing some systems may run two types of python versions simultaneously because in some systems python comes with the old version and when you install a new version of python you need to make that python version the default one. 

- Search for environment variables it is in the control panel you may see there - Edit System Environment variables-.

-Then select the Environment variables button and choose a select path in user variables for "admin_name" and click edit

-And you can create a new path or edit the old path where the new version of python is located in your system.

so, now you made the default python version on your system.


Environment variables


Error: Microsoft Visual C++ Build Tools

Microsoft visual c++ build tool error

For this error just go to this link and download the c++ build tools and after installing restart the system.


c++ build tools


Some Tips:

* You can try the old version of chatterbot it will work on your system but it will not be an accurate one.
>>pip install chatterbot=1.0.4

*Installing chatterbot on windows will simple for someone where it will install without any error but in some cases, it will be complex for some people because of some small errors and some simple mistakes so always keep an updated version of the system and Softwares.

* This discussed topic is got from social media and some sites try StackOverflow for a detailed description of the error you faced or write your question people will answer you. 

*I recommend you use Ubuntu if you want to use chatterbot without facing errors and this discussed topic not only solves chatterbot errors, also might solve some common errors people face while using python packages.

If you know any other solution for chatterbot error on python on windows please comment below it will be useful for someone.

-Hope this article Helps you 


Do you know what is a blog? Check Out Here

Post a Comment

0 Comments