Python(>=3.6)Node(>=v8)LinuxorWindows(installation forWindowsrequires git andVisual Studio 2015/2017withC++ build toolsinstalled!)
-
Clone this repository or download the latest version.
-
Create and activate a virtual environment:
Linux
cd nlu python -m venv env source ./env/bin/activate
Windows
cd nlu python -m venv env .\env\Scripts\activate.bat -
Install the Python requirements:
pip install -r requirements.txt -
Download and install spacy en_core_web_sm:
python -m spacy download en_core_web_sm -
Download and install DeepPavlov datasets for intent classification:
python -m deeppavlov download model_config.json python -m deeppavlov download intents.json -
Now install the frontend dependencies:
cd ../chatbot npm install
-
Launch DeepPavlov REST API:
cd nlu DP_SETTINGS_PATH=./deeppavlov-settings python -m deeppavlov riseapi model_config.json -p 4949The swagger api docs should be available at http://localhost:4949/.
-
Launch the frontend server:
cd chatbot PORT=3000 npm startYou should be able to access the web chat interface at http://localhost:3000/.
This repository comes with pre-trained models for our chatbot. If you decide to add, remove, or modify the intents and/or the entities, you will have to re-train the models.
python -m deeppavlov train intents.jsonpython -m deeppavlov train ner.jsondocker build -t ehrhart/deeppavlov-restaurants/chatbot . docker run -p 3000:3000 -d ehrhart/deeppavlov-restaurants/chatbot