Prerequisite
Have an virtual environment ready with Python 3.10 installed.
- Clone this repo
- Install the depdencies with
pip install -r requirements.txt
- In a terminal window, start the server with
python rest_api.py
- In another terminal winddow, test the API with
python run_api.py
- The result in the terminal shows the input message, and a dictionary with the intent and confidence score
- To change the input text, simply the value of the variable
sample_text
in therun_api.py
file on line 10. Then, we can send this new text to the REST API usingpython run_api.py
and see the prediction for the new text.
The entire experimental protocal and thought process to create the classifier is available in the notebook glia_text_classif_sklearn.ipynb
.