Skip to content

almazkun/django-sentimental

Repository files navigation

django-sentimental

Django website with ML model for Sentiment Analysis

Demo website

https://sentiment.akun.dev

Installation

  1. Clone the repository
  2. Install the requirements
    pipenv install
    pipenv shell
  1. Run the server
    python manage.py runserver
  1. Open the browser and go to http://127.0.0.1:8000/

Usage

  1. Enter the text in the text area.
  2. Click on the "Analyze".

Deploy

  1. Install docker: https://docs.docker.com/engine/install/ubuntu/
  2. Download image:
    docker pull docker pull ghcr.io/almazkun/sentimental:latest
  1. Create and populate the .env file:
    touch .env
    echo "DJANGO_SECRET_KEY=your_secret_key" >> .env
    echo "DJANGO_DEBUG=your_debug" >> .env
    echo "DJANGO_ALLOWED_HOSTS=localhost" >> .env
    echo "DJANGO_CSRF_TRUSTED_ORIGINS=http://localhost:8000" >> .env
    echo "SENTIMENT_MODEL_PATH=./model.pkl" >> .env
  1. Run the container:
    docker run --rm -d -p 80:8000 -env-file .env ghcr.io/almazkun/sentimental:latest
  1. Open the browser and go to http://localhost/

About

Django website with ML model for Sentiment Analysis

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages