A demo app using Flask and IBM Watson APIs to do sentiment analysis on hotel reviews.
- Download hotel reviews dataset from https://www.kaggle.com/datafiniti/hotel-reviews and place 7282_1.csv in data directoy
- Install Elasticsearch from https://www.elastic.co/guide/en/elasticsearch/reference/current/install-elasticsearch.html
- Run bin/elasticsearch
- Register for IBM Watson API https://cloud.ibm.com/
- Enter API authentication details in code/app.py
- Install Python library requirements:
- pandas
- numpy
- json
- json2html
- flask
- ibm-watson
- elasticsearch-py
-
Run
python code/app.py
-
Go to
http://localhost:5000/
-
Enter a hotel name and view an "Overview" of review tones or "Detailed" hotel information.