In this repository, we have built a chatbot that can answer questions related to Mucormycosis infection also colloquially called as Black Fungus infection.Mucormycosis is a deadly infection affecting the patients who have recovered from COVID-19 and currently very few people have knowledge about this deadly disease. The technology behind the chat is open source RASA X which internally uses Spacy library to process the Natural Language.The model was trained using DIET classifier in Tensorflow for 100 epochs.Furthermore, we were able to integrate the Chatbot into Telegram and Slack messaging application.Lastly, the application was deployed on Google Cloud Platform
Steps to install the chatbot
- Create a virtual environment with python version 3.6. Rasa works only with python version 3.6,3.7,3.8 only.
- Install rasa x (pip3 install rasa-x --extra-index-url https://pypi.rasa.com/simple).This may take a while.
- Initialize the rasa using the command rasa init.Post rasa init, please run rasa shell to interact with bot.
- Add your own intents in the file nlu.yml and add stories in the file stories.yml.Both of these files are present in data file.
- After adding intents and stories, train the model using command rasa train.
- Once trained successfully, hit the command rasa x to open the Rasa UI interface.
- Converse with the bot and enjoy !
Screenshots:
Steps to integrate the chatbot with Telegram and Slack.
- To integrate the chatbot with Telegram first create a access token from Telegram BotFather and also create username.
- Add the obtained access token and username in the credentials.yml file under telegram section
- Finally add the webhook URL.To add webhook URL use ngrok.To create a URL using ngrok, use command ngrok http 5005
- Run rasa using command rasa run.Additionally, at same time run rasa run actions to start the action server.
- Go to telegram channel where bot is created and converse with bot.
Telegram integration screenshot
Steps to integrate the chatbot into slack.[1]
1.First create the app in slack and integrate the chatbot into the app (app.slack.com/apps)
2.Add the Slack token key, app ID and secret key in the domain.yml file
3.After creating the app in slack, run the command rasa run.
3.Open the slack app, converse with the bot in the apps section of the slack.
Steps to deploy the model into Google cloud platform [2]
1.Create a new VM instance in the GCP.Minimum configuration include 4 GB RAM, Ubuntu 20.04 LTS, 50 GB HDD in GCP.
2.Install the Rasa X in the created VM instance.Set the password for RASA login.
3.Once installed link the RASA in GCP with the GIT hub repository
4.Train the model and then converse with chatbot.
Google Cloud Platform Screenshot
System Requirements :
OS : Ubuntu 20.0.04 LTS
CPU : Intel Core i3 and above.
RAM : 4 GB
Memory : 256 GB SSD.
References :