End-to-end Conversational bot Create with UI <3

bot
0
0

Introduction

What is Rasa?

Rasa is an open-source machine learning framework for automated text and voice-based conversations. Rasa(chatbot) is helpful in understanding messages, holding conversations, and connecting to messaging channels and APIs.

The very good thing about Rasa is you are not tied to any pre-built models or use cases (like Dialogflow, etc). So, due to this very good reason, you can customize your use cases which can be a market changer. Rasa is a rule-less framework so, you don’t have to worry about putting your data on someone’s server or cloud as in Microsoft LUIS, Dialogflow, or Amazon aLexa.
There are two main components of Rasa: Rasa NLU and Rasa core.

Now let’s understand both of them one by one to understand the clean and proper architecture of RASA.

Let’s first understand what is Rasa NLU? Rasa NLU is an open-source natural language processing tool for intent classification and entity extraction in chatbots. Let’s understand is with an example like

“I need a taxi for 5 people”

and the returned structured data will be like

{
"intent": "taxi_booking",
"entities": {
"service" : "taxi",
"P_COUNT" : 5
}
}


Here what’s happening internally is that by default Rasa NLU is using Bag-of-word(BoW) algorithm to find intents and Conditional Random Field(CRF) to find the entities. But you can also use different algorithms to find the intents and the entities using Rasa by creating a custom pipeline and setting up the algorithms accordingly.

The main reason why open source NLU is used are:

  • All your training data is not dependent on Google, Microsoft, Amazon, or Facebook.
  • Machine Learning is not one-size-fits-all. You can tweak and customize models for your training data.
  • Rasa NLU runs anywhere you want, so you don’t need to make any extra network request for every message.
    Now, let’s understand what is Rasa Core? Rasa Core places a major and the most essential part of generating the reply messages for a chatbot. It considers the output of Rasa NLU (intents and entities) as an input and applies machine learning models to respond with a bot reply.

Building a Rasa chatbot

Previously if you were using the Rasa to build a chatbot than it was a bit complicated to build a chatbot and also there was no UI(user interface) available to test the working and functionality of your Rasa chatbot. But since after the release of Rasa-X its been very easy and interactive for us to get started with the building of Rasa chatbot with UI to interact with the bot, also we can share our bot with our loved ones to help them in every aspect.
Now let’s get started with the building of Rasa chatbot:


Step 1. Install Python Development Environment
Create a directory anywhere on your system and the change to that directory while using it on the terminal/command prompt.
Check if you already have the configured python environment on your system

$ python3 --version 
$ pip3 --version

If the above packages are already installed on your system then it will show you the versions in output. Otherwise,Open terminal or command prompt and try this
For Ubuntu users:

$ sudo apt update
$ sudo apt install python3-dev python3-pip

For macOS users:

$ brew update
$ brew install python

For Windows Users:

Make sure the Microsoft VC++ Compiler is installed, so python can compile any dependencies. You can get the compiler from Visual Studio. Download the installer and select VC++ Build tools in the list.

Install Python 3 (64-bit version) for Windows.

C:> pip3 install -U pip

Step 2. Creating a Virtual Environment

To create a virtual environment in ubuntu/macOS we have tools like virtualenv and virtualwrapper that provide isolated Python environments. To create a virtual environment using them you don’t need any root privileges.

Create a new virtual environment using python interpreter by setting the directory in your current directory as ./venv (you can reset this path as per your project suitability)

For Ubuntu/macOS:

$ python3 -m venv --system-site-packages ./venv

and to activate the environment :

$ source ./venv/bin/activate

For Windows:

C:> python3 -m venv --system-site-packages ./venv

and to activate the environment:

C:> .venv\Scripts\activate

Step 3.Install dependencies for spacy

Install the dependencies for spacy using the below commands:

$ pip install rasa[spacy]
$ python -m spacy download en_core_web_md
$ python -m spacy link en_core_web_md en

Step 4. Install Rasa X to your system

Use the below command in terminal/command prompt to install Rasa X to your system

$ pip install rasa-x --extra-index-url https://pypi.rasa.com/simple

Step 5. Building a simple Rasa X chatbot

After your are done with the installation of all the packages and the dependencies for Rasa X in your virtual environment. Now run the following command in the terminal/command prompt to create the example chatbot provided by Rasa to have a basic understanding of how does the Rasa X chatbot works, So that you could further customize the your Rasa X chatbot accordingly.

$ rasa init --no-prompt

When this will be successfully done. It will create different files and directories in your current directory in the format as shown below:

__init__.py an empty file that helps python find your actions 
actions.py code for your custom actions
config.yml ‘*’ configuration of your NLU and Core models
credentials.yml details for connecting to other services
data/nlu.md ‘*’ your NLU training data
data/stories.md ‘*’ your stories
domain.yml ‘*’ your assistant’s domain
endpoints.yml details for connecting to channels like FB messenger
models/<timestamp>.tar.gz your initial model

Also when this command will run it will train your model for the first time automatically by using the complete data in the structured format as you can see above. You will have a complete description about all these file in the next blog in brief.

Step 6. Chatting with the Rasa X chatbot

When we are done with all the steps above and it’s time for you to start chatting with our very first chatbot made by you. Now to check the working of your chatbot run the following command in the terminal/command prompt

$ rasa x
Sad path conversation for Rasa Chatbot

this command will open your interactive Rasa X chatbot in the browser and if in case it doesn’t open automatically the copy the link from the terminal and paste it in the address bar of the browser and hit enter to start talking to your bot.

Check out this link for details and clarification,

Time to wrap up now. Hope you liked our content on How to build an end-to-end conversational chatbot with Rasa. See you in our next blog, thanks for reading our blog and do leave a comment below to help us improve the content to serve you all of our experience with you. Stay tuned with us for more Rasa Chatbot contents.

Also check out our other playlist Rasa Chatbot, Internet of things, Docker, Python Programming, etc.
Become a member of our social family on youtube here.

So stay tuned and for now Happy Learning.

Ashish Saini
Ashish Saini

I am a software developer for Python/Machine Learning. Also, I’m Rasa Hero at Rasa. Also, I’m a youtuber where I regulary uploads the videos to help this generation learn about the technology just like they are playing games.

16 thoughts on “End-to-end Conversational bot Create with UI <3

  1. it is giving me following error when I run rasa x.
    Im using Mac Catalina. with Pyenv Python version 3.6.5

    Can you tell me what is going wron?

    (rasaenv) rasax$ rasa x
    Traceback (most recent call last):
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasa/cli/x.py”, line 431, in run_locally
    args, project_path, args.data, token=rasa_x_token, config_path=config_path
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasax/community/local.py”, line 192, in main
    rasa_cli_utils.print_success(“Starting Rasa X in local mode… \U0001f680”)
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasa/cli/utils.py”, line 222, in print_success
    print_color(*args, color=bcolors.OKGREEN)
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasa/cli/utils.py”, line 218, in print_color
    print(wrap_with_color(*args, color=color))
    UnicodeEncodeError: ‘ascii’ codec can’t encode character ‘\U0001f680’ in position 38: ordinal not in range(128)

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
    File “/Users/deepak/work/code/rasax/rasaenv/bin/rasa”, line 11, in
    sys.exit(main())
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasa/__main__.py”, line 92, in main
    cmdline_arguments.func(cmdline_arguments)
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasa/cli/x.py”, line 326, in rasa_x
    run_locally(args)
    File “/Users/deepak/work/code/rasax/rasaenv/lib/python3.6/site-packages/rasa/cli/x.py”, line 434, in run_locally
    print(traceback.format_exc())
    UnicodeEncodeError: ‘ascii’ codec can’t encode character ‘\U0001f680’ in position 415: ordinal not in range(128)
    Traceback (most recent call last):
    File “”, line 1, in
    File “/Users/deepak/.pyenv/versions/3.6.5/lib/python3.6/multiprocessing/spawn.py”, line 105, in spawn_main
    exitcode = _main(fd)
    File “/Users/deepak/.pyenv/versions/3.6.5/lib/python3.6/multiprocessing/spawn.py”, line 115, in _main
    self = reduction.pickle.load(from_parent)
    File “/Users/deepak/.pyenv/versions/3.6.5/lib/python3.6/multiprocessing/synchronize.py”, line 111, in __setstate__
    self._semlock = _multiprocessing.SemLock._rebuild(*state)
    FileNotFoundError: [Errno 2] No such file or directory

      1. No I didn’t. All looks fine.

        (rasaenv) deepak@Deepaks-MacBook-Pro rasax % pip install -U rasa-x –extra-index-url https://pypi.rasa.com/simple

        Requirement already up-to-date: rasa-x in ./rasaenv/lib/python3.6/site-packages
        Requirement already up-to-date: requests=2.23 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: pika=1.1.0 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: python-dateutil=2.8 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: sanic-cors=0.10.0.post3 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: isodate=0.6 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: aiohttp=3.6 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: rasa=1.9.5 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: questionary=1.5.1 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: sanic=19.12.2 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: psycopg2-binary=2.8.2 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: sanic-jwt=1.3.2 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: kafka-python=1.4 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: apscheduler=3.6 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: GitPython=3.1.3 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: ujson=1.35 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: ruamel.yaml=0.16 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: jsonschema=3.2 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: alembic=1.0.10 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: setuptools>=41.0.0 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: tensorflow-estimator=2.1.0 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: SQLAlchemy=1.3.17 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: cryptography=2.7 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: attrs=19.3 in ./rasaenv/lib/python3.6/site-packages (from rasa-x)
        Requirement already up-to-date: idna=2.5 in ./rasaenv/lib/python3.6/site-packages (from requests=2.23->rasa-x)
        Requirement already up-to-date: urllib3!=1.25.0,!=1.25.1,=1.21.1 in ./rasaenv/lib/python3.6/site-packages (from requests=2.23->rasa-x)
        Requirement already up-to-date: chardet=3.0.2 in ./rasaenv/lib/python3.6/site-packages (from requests=2.23->rasa-x)
        Requirement already up-to-date: certifi>=2017.4.17 in ./rasaenv/lib/python3.6/site-packages (from requests=2.23->rasa-x)
        Requirement already up-to-date: six>=1.5 in ./rasaenv/lib/python3.6/site-packages (from python-dateutil=2.8->rasa-x)
        Requirement already up-to-date: sanic-plugins-framework>=0.9.0 in ./rasaenv/lib/python3.6/site-packages (from sanic-cors=0.10.0.post3->rasa-x)
        Requirement already up-to-date: typing-extensions>=3.6.5; python_version < "3.7" in ./rasaenv/lib/python3.6/site-packages (from aiohttp=3.6->rasa-x)
        Requirement already up-to-date: multidict=4.5 in ./rasaenv/lib/python3.6/site-packages (from aiohttp=3.6->rasa-x)
        Requirement already up-to-date: idna-ssl>=1.0; python_version < "3.7" in ./rasaenv/lib/python3.6/site-packages (from aiohttp=3.6->rasa-x)
        Requirement already up-to-date: async-timeout=3.0 in ./rasaenv/lib/python3.6/site-packages (from aiohttp=3.6->rasa-x)
        Requirement already up-to-date: yarl=1.0 in ./rasaenv/lib/python3.6/site-packages (from aiohttp=3.6->rasa-x)
        Requirement already up-to-date: twilio=6.26 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: slackclient=2.0.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: absl-py=0.9 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: prompt-toolkit=2.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: rocketchat_API=0.6.31 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: oauth2client==4.1.3 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: cloudpickle=1.2 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: pydot=1.4 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: scipy=1.4.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: terminaltables=3.1.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: colorhash=1.0.2 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: gevent=1.4 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Collecting tqdm=4.31 (from rasa=1.9.5->rasa-x)
        Using cached https://files.pythonhosted.org/packages/4a/1c/6359be64e8301b84160f6f6f7936bbfaaa5e9a4eab6cbc681db07600b949/tqdm-4.45.0-py2.py3-none-any.whl
        Requirement already up-to-date: rasa-sdk=1.10.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: coloredlogs=10.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: async_generator=1.10 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: python-engineio=3.11 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tensorflow-addons=0.7.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: python-telegram-bot=11.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: matplotlib=3.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: networkx=2.4.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: numpy=1.16 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: colorclass=2.2 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: fbmessenger=6.0.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Collecting boto3=1.12 (from rasa=1.9.5->rasa-x)
        Using cached https://files.pythonhosted.org/packages/92/5b/f855226132309de329a80eec355954be31d98e801da761ab127b743f1b87/boto3-1.15.12-py2.py3-none-any.whl
        Requirement already up-to-date: pykwalify=1.7.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: scikit-learn=0.22 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: PyJWT=1.7 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: mattermostwrapper=2.2 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: sklearn-crfsuite=0.3 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tensorflow_hub=0.7 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: jsonpickle=1.3 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: webexteamssdk=1.1.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: redis=3.4 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: packaging=20.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tensorflow=2.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tensorflow-probability=0.7 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: python-socketio=4.4 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: pymongo[srv,tls]=3.8.0 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: regex=2020.6 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: pytz=2019.1 in ./rasaenv/lib/python3.6/site-packages (from rasa=1.9.5->rasa-x)
        Requirement already up-to-date: aiofiles>=0.3.0 in ./rasaenv/lib/python3.6/site-packages (from sanic=19.12.2->rasa-x)
        Requirement already up-to-date: uvloop>=0.5.3; sys_platform != “win32” and implementation_name == “cpython” in ./rasaenv/lib/python3.6/site-packages (from sanic=19.12.2->rasa-x)
        Requirement already up-to-date: httpx==0.9.3 in ./rasaenv/lib/python3.6/site-packages (from sanic=19.12.2->rasa-x)
        Requirement already up-to-date: httptools>=0.0.10 in ./rasaenv/lib/python3.6/site-packages (from sanic=19.12.2->rasa-x)
        Requirement already up-to-date: websockets=7.0 in ./rasaenv/lib/python3.6/site-packages (from sanic=19.12.2->rasa-x)
        Requirement already up-to-date: tzlocal>=1.2 in ./rasaenv/lib/python3.6/site-packages (from apscheduler=3.6->rasa-x)
        Requirement already up-to-date: gitdb=4.0.1 in ./rasaenv/lib/python3.6/site-packages (from GitPython=3.1.3->rasa-x)
        Requirement already up-to-date: ruamel.yaml.clib>=0.1.2; platform_python_implementation == “CPython” and python_version < "3.9" in ./rasaenv/lib/python3.6/site-packages (from ruamel.yaml=0.16->rasa-x)
        Requirement already up-to-date: pyrsistent>=0.14.0 in ./rasaenv/lib/python3.6/site-packages (from jsonschema=3.2->rasa-x)
        Requirement already up-to-date: importlib-metadata; python_version < "3.8" in ./rasaenv/lib/python3.6/site-packages (from jsonschema=3.2->rasa-x)
        Requirement already up-to-date: Mako in ./rasaenv/lib/python3.6/site-packages (from alembic=1.0.10->rasa-x)
        Requirement already up-to-date: python-editor>=0.3 in ./rasaenv/lib/python3.6/site-packages (from alembic=1.0.10->rasa-x)
        Requirement already up-to-date: cffi!=1.11.3,>=1.8 in ./rasaenv/lib/python3.6/site-packages (from cryptography=2.7->rasa-x)
        Requirement already up-to-date: pysocks; python_version >= “3.0” in ./rasaenv/lib/python3.6/site-packages (from twilio=6.26->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: wcwidth in ./rasaenv/lib/python3.6/site-packages (from prompt-toolkit=2.0->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: rsa>=3.1.4 in ./rasaenv/lib/python3.6/site-packages (from oauth2client==4.1.3->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: pyasn1-modules>=0.0.5 in ./rasaenv/lib/python3.6/site-packages (from oauth2client==4.1.3->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: httplib2>=0.9.1 in ./rasaenv/lib/python3.6/site-packages (from oauth2client==4.1.3->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: pyasn1>=0.1.7 in ./rasaenv/lib/python3.6/site-packages (from oauth2client==4.1.3->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: pyparsing>=2.1.4 in ./rasaenv/lib/python3.6/site-packages (from pydot=1.4->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: greenlet>=0.4.14; platform_python_implementation == “CPython” in ./rasaenv/lib/python3.6/site-packages (from gevent=1.4->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: humanfriendly>=4.7 in ./rasaenv/lib/python3.6/site-packages (from coloredlogs=10.0->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: decorator>=4.4.0 in ./rasaenv/lib/python3.6/site-packages (from python-telegram-bot=11.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tornado>=5.1 in ./rasaenv/lib/python3.6/site-packages (from python-telegram-bot=11.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: cycler>=0.10 in ./rasaenv/lib/python3.6/site-packages (from matplotlib=3.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: kiwisolver>=1.0.1 in ./rasaenv/lib/python3.6/site-packages (from matplotlib=3.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: s3transfer=0.3.0 in ./rasaenv/lib/python3.6/site-packages (from boto3=1.12->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: jmespath=0.7.1 in ./rasaenv/lib/python3.6/site-packages (from boto3=1.12->rasa=1.9.5->rasa-x)
        Collecting botocore=1.18.12 (from boto3=1.12->rasa=1.9.5->rasa-x)
        Downloading https://files.pythonhosted.org/packages/14/d5/9d0db656de5bb8c431232d5976526ca5b6ac1e4563f95ce6cd842bbccff4/botocore-1.18.12-py2.py3-none-any.whl (6.7MB)
        100% |################################| 6.7MB 134kB/s
        Requirement already up-to-date: docopt>=0.6.2 in ./rasaenv/lib/python3.6/site-packages (from pykwalify=1.7.0->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: PyYAML>=3.11 in ./rasaenv/lib/python3.6/site-packages (from pykwalify=1.7.0->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: joblib>=0.11 in ./rasaenv/lib/python3.6/site-packages (from scikit-learn=0.22->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tabulate in ./rasaenv/lib/python3.6/site-packages (from sklearn-crfsuite=0.3->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: python-crfsuite>=0.8.3 in ./rasaenv/lib/python3.6/site-packages (from sklearn-crfsuite=0.3->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: protobuf>=3.8.0 in ./rasaenv/lib/python3.6/site-packages (from tensorflow_hub=0.7->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: future in ./rasaenv/lib/python3.6/site-packages (from webexteamssdk=1.1.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: requests-toolbelt in ./rasaenv/lib/python3.6/site-packages (from webexteamssdk=1.1.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: astor>=0.6.0 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: keras-applications>=1.0.8 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: gast==0.2.2 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: wheel>=0.26; python_version >= “3” in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: opt-einsum>=2.3.2 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: wrapt>=1.11.1 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: termcolor>=1.1.0 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: tensorboard=2.1.0 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: keras-preprocessing==1.1.0 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: grpcio>=1.8.6 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: google-pasta>=0.1.6 in ./rasaenv/lib/python3.6/site-packages (from tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: dnspython=1.13.0; extra == “srv” in ./rasaenv/lib/python3.6/site-packages (from pymongo[srv,tls]=3.8.0->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: h11==0.8.* in ./rasaenv/lib/python3.6/site-packages (from httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: rfc3986=1.3 in ./rasaenv/lib/python3.6/site-packages (from httpx==0.9.3->sanic=19.12.2->rasa-x)
        Collecting hstspreload (from httpx==0.9.3->sanic=19.12.2->rasa-x)
        Downloading https://files.pythonhosted.org/packages/f0/16/59b51f8e640f16acad2c0e101fa1e55a87bfd80cff23f77ab23cb8927541/hstspreload-2020.10.6-py3-none-any.whl (965kB)
        100% |################################| 972kB 290kB/s
        Requirement already up-to-date: sniffio==1.* in ./rasaenv/lib/python3.6/site-packages (from httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: h2==3.* in ./rasaenv/lib/python3.6/site-packages (from httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: smmap=3.0.1 in ./rasaenv/lib/python3.6/site-packages (from gitdb=4.0.1->GitPython=3.1.3->rasa-x)
        Requirement already up-to-date: zipp>=0.5 in ./rasaenv/lib/python3.6/site-packages (from importlib-metadata; python_version jsonschema=3.2->rasa-x)
        Requirement already up-to-date: MarkupSafe>=0.9.2 in ./rasaenv/lib/python3.6/site-packages (from Mako->alembic=1.0.10->rasa-x)
        Requirement already up-to-date: pycparser in ./rasaenv/lib/python3.6/site-packages (from cffi!=1.11.3,>=1.8->cryptography=2.7->rasa-x)
        Requirement already up-to-date: h5py in ./rasaenv/lib/python3.6/site-packages (from keras-applications>=1.0.8->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: markdown>=2.6.8 in ./rasaenv/lib/python3.6/site-packages (from tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Collecting google-auth=1.6.3 (from tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Downloading https://files.pythonhosted.org/packages/1f/cf/724b6436967a8be879c8de16b09fd80e0e7b0bcad462f5c09ee021605785/google_auth-1.22.1-py2.py3-none-any.whl (114kB)
        100% |################################| 122kB 1.4MB/s
        Requirement already up-to-date: google-auth-oauthlib=0.4.1 in ./rasaenv/lib/python3.6/site-packages (from tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: werkzeug>=0.11.15 in ./rasaenv/lib/python3.6/site-packages (from tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: contextvars>=2.1; python_version httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: hyperframe=5.2.0 in ./rasaenv/lib/python3.6/site-packages (from h2==3.*->httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: hpack=3.0 in ./rasaenv/lib/python3.6/site-packages (from h2==3.*->httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: cachetools=2.0.0 in ./rasaenv/lib/python3.6/site-packages (from google-auth=1.6.3->tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: requests-oauthlib>=0.7.0 in ./rasaenv/lib/python3.6/site-packages (from google-auth-oauthlib=0.4.1->tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Requirement already up-to-date: immutables>=0.9 in ./rasaenv/lib/python3.6/site-packages (from contextvars>=2.1; python_version sniffio==1.*->httpx==0.9.3->sanic=19.12.2->rasa-x)
        Requirement already up-to-date: oauthlib>=3.0.0 in ./rasaenv/lib/python3.6/site-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib=0.4.1->tensorboard=2.1.0->tensorflow=2.1->rasa=1.9.5->rasa-x)
        Installing collected packages: tqdm, botocore, boto3, hstspreload, google-auth
        Found existing installation: tqdm 4.50.0
        Uninstalling tqdm-4.50.0:
        Successfully uninstalled tqdm-4.50.0
        Found existing installation: botocore 1.18.11
        Uninstalling botocore-1.18.11:
        Successfully uninstalled botocore-1.18.11
        Found existing installation: boto3 1.15.11
        Uninstalling boto3-1.15.11:
        Successfully uninstalled boto3-1.15.11
        Found existing installation: hstspreload 2020.9.29
        Uninstalling hstspreload-2020.9.29:
        Successfully uninstalled hstspreload-2020.9.29
        Found existing installation: google-auth 1.22.0
        Uninstalling google-auth-1.22.0:
        Successfully uninstalled google-auth-1.22.0
        Successfully installed boto3-1.15.12 botocore-1.18.12 google-auth-1.22.1 hstspreload-2020.10.6 tqdm-4.45.0
        You are using pip version 9.0.3, however version 20.2.3 is available.
        You should consider upgrading via the ‘pip install –upgrade pip’ command.

  2. I tried from last two days to built this chatbot but this same error repeats when I tried to install rasa x so please help me out

    Building wheels for collected packages: ujson
    Building wheel for ujson (setup.py) … error
    ERROR: Command errored out with exit status 1:
    command: ‘d:\rasa_chatbot_folder\rasa_myenv\scripts\python.exe’ -u -c ‘import sys, setuptools, tokenize; sys.argv[0] = ‘”‘”‘C:\\Users\\RockyJai\\AppData\\Local\\T
    emp\\pip-install-raz46k4d\\ujson\\setup.py'”‘”‘; __file__='”‘”‘C:\\Users\\RockyJai\\AppData\\Local\\Temp\\pip-install-raz46k4d\\ujson\\setup.py'”‘”‘;f=getattr(tokeni
    ze, ‘”‘”‘open'”‘”‘, open)(__file__);code=f.read().replace(‘”‘”‘\r\n'”‘”‘, ‘”‘”‘\n'”‘”‘);f.close();exec(compile(code, __file__, ‘”‘”‘exec'”‘”‘))’ bdist_wheel -d ‘C:\U
    sers\RockyJai\AppData\Local\Temp\pip-wheel-lqla5gcl’
    cwd: C:\Users\RockyJai\AppData\Local\Temp\pip-install-raz46k4d\ujson\
    Complete output (6 lines):
    Warning: ‘classifiers’ should be a list, got type ‘filter’
    running bdist_wheel
    running build
    running build_ext
    building ‘ujson’ extension
    error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++ Build Tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/
    —————————————-
    ERROR: Failed building wheel for ujson
    Running setup.py clean for ujson
    Failed to build ujson
    Installing collected packages: cryptography, ujson, isodate, attrs, tqdm, multidict, rasa, rasa-x
    Attempting uninstall: cryptography
    Found existing installation: cryptography 3.2.1
    Uninstalling cryptography-3.2.1:
    Successfully uninstalled cryptography-3.2.1
    Attempting uninstall: ujson
    Found existing installation: ujson 3.2.0
    Uninstalling ujson-3.2.0:
    Successfully uninstalled ujson-3.2.0
    Running setup.py install for ujson … error
    ERROR: Command errored out with exit status 1:
    command: ‘d:\rasa_chatbot_folder\rasa_myenv\scripts\python.exe’ -u -c ‘import sys, setuptools, tokenize; sys.argv[0] = ‘”‘”‘C:\\Users\\RockyJai\\AppData\\Local\
    \Temp\\pip-install-raz46k4d\\ujson\\setup.py'”‘”‘; __file__='”‘”‘C:\\Users\\RockyJai\\AppData\\Local\\Temp\\pip-install-raz46k4d\\ujson\\setup.py'”‘”‘;f=getattr(toke
    nize, ‘”‘”‘open'”‘”‘, open)(__file__);code=f.read().replace(‘”‘”‘\r\n'”‘”‘, ‘”‘”‘\n'”‘”‘);f.close();exec(compile(code, __file__, ‘”‘”‘exec'”‘”‘))’ install –record ‘
    C:\Users\RockyJai\AppData\Local\Temp\pip-record-k7aiey3q\install-record.txt’ –single-version-externally-managed –compile –install-headers ‘d:\rasa_chatbot_folder\
    rasa_myenv\include\site\python3.8\ujson’
    cwd: C:\Users\RockyJai\AppData\Local\Temp\pip-install-raz46k4d\ujson\
    Complete output (6 lines):
    Warning: ‘classifiers’ should be a list, got type ‘filter’
    running install
    running build
    running build_ext
    building ‘ujson’ extension
    error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++ Build Tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/
    —————————————-
    Rolling back uninstall of ujson
    Moving to d:\rasa_chatbot_folder\rasa_myenv\lib\site-packages\ujson-3.2.0.dist-info\
    from D:\RASA_chatbot_folder\rasa_myenv\Lib\site-packages\~json-3.2.0.dist-info
    Moving to d:\rasa_chatbot_folder\rasa_myenv\lib\site-packages\ujson.cp38-win_amd64.pyd
    from C:\Users\RockyJai\AppData\Local\Temp\pip-uninstall-5miz0a3m\ujson.cp38-win_amd64.pyd
    ERROR: Command errored out with exit status 1: ‘d:\rasa_chatbot_folder\rasa_myenv\scripts\python.exe’ -u -c ‘import sys, setuptools, tokenize; sys.argv[0] = ‘”‘”‘C:\
    \Users\\RockyJai\\AppData\\Local\\Temp\\pip-install-raz46k4d\\ujson\\setup.py'”‘”‘; __file__='”‘”‘C:\\Users\\RockyJai\\AppData\\Local\\Temp\\pip-install-raz46k4d\\uj
    son\\setup.py'”‘”‘;f=getattr(tokenize, ‘”‘”‘open'”‘”‘, open)(__file__);code=f.read().replace(‘”‘”‘\r\n'”‘”‘, ‘”‘”‘\n'”‘”‘);f.close();exec(compile(code, __file__, ‘”‘
    “‘exec'”‘”‘))’ install –record ‘C:\Users\RockyJai\AppData\Local\Temp\pip-record-k7aiey3q\install-record.txt’ –single-version-externally-managed –compile –install
    -headers ‘d:\rasa_chatbot_folder\rasa_myenv\include\site\python3.8\ujson’ Check the logs for full command output.

    1. I am getting the same error too and is not getting solved in spite of using a conda environment. Were you able to solve it, sir? If so please let me know what steps followed in order to solve the error. Thanks in advance.

Leave a Reply