- Access the app deployed on DigitalOcean: http://178.128.39.191:8282
Various NLP tasks using Huggingface and Flask. Right now, the app supports only three tasks:
-
Sentiment Analysis: Identify if the sentence's sentiment is Positive or Negative.
-
Extractive Question Answering: For a given Context paragraph ask a Question. You should get an Answer from the paragraph.
-
Text Generation: Provide a Context (start of a sentence) and let the AI complete your story.
Plan is to include more tasks in future. Hugginface's transformers
library makes these things very easy to do.
Contributions are most welcome.
- Clone the repo:
git clone https://github.com/ashishu007/NLP-Tasks.git
- Run with docker-composer
docker-compose up
-
Navigate into the downloaded repo:
cd NLP-Tasks/flask
-
Install the required dependencies:
pip install -r requirements.txt
-
Run the flask-app:
-
Windows Powershell:
$env:FLASK_APP="app.py" flask run
-
Linux:
export FLASK_APP=app.py flask run
-
- Add more tasks
- Improve the user-interface
Huggingface's transformers library has revolutionised the way state-of-the-art NLP models are being used in real-world. Without, this library, the app made here would have taken tremendous amount of work (compared to what it took rn). :)