Skip to content

drOluOla/rasa-wellness-bot

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wellness Check Rasa ChatBot

Python Rasa

This is rasa based chatbot. User is asked several health related questions and at the end the logs are shared back to the user. This project demonstrates how easy it is to create NLP based chatbots with rasa opensource sdk. It mainly consists of a Form and Custom Actions. A beginner friendly scope was kept so that any one looking for getting started, could refer this.

Demo

Setup and Installation

It is recommended to use Python 3.6 or Python 3.7 with rasa framework. Below are the steps to run this project.

  1. Clone master branch of this repository & open root directory in terminal.
  2. Create virtual env with python: python3.7 -m venv ./venv and activate it by source ./venv/bin/activate
  3. Install rasa pip install rasa, with this you can now run rasa commands described below.

Generating Trained Model

Make sure python virtual env is active in terminal. Change directory to backend & run rasa train like below. After training is done, you will find models directory at backend/models this is the result of rasa NLU training & rasa Core training.

cd backend
rasa train

Running Actions Server

After training is done, you need to run server to serve custom actions related computation. Open another terminal instance, activate virtual env and open backend directory.

rasa run actions

Running Rasa Chatbot in Shell

Below command loads the trained model, opens communication to custom actions running server & provides REPL to interact with chatbot.

rasa shell

Once you have developed your bot and you are ready to integrate the bot with the UI, you can start the Rasa server using the below command

rasa run -m models --enable-api --cors "*" --debug

If you have custom actions, you can start the action server using the below command

rasa run actions --cors "*" --debug

Once you have you Rasa server up and running, you can test the bot by running the index.html file in the browser.

Chatbot Screenshots

rasa train

01 rasa-train-success

rasa run actions

02 rasa-run-actions-success

rasa shell - happy flow 1 - affirmed for exercise

03 rasa-shell-happy-flow

rasa shell - happy flow 2 - denied for exercise

04 rasa-shell-happy-flow-no-exercise

rasa shell - sad flow 1 - going out of scope & coming back

05 rasa-shell-sad-path-1

rasa shell - sad flow 2 - going out of scope & denied to proceed

06 rasa-shell-sad-path-2

About

Rasa Wellness Form Chatbot

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • HTML 94.0%
  • Python 6.0%