Emotibot: BERT sentiment analysis with visual feedback

Emotibot: BERT sentiment analysis with visual feedback
Applied Machine Learning

A containerized sentiment-analysis application that classifies text with a BERT model and presents the result through an immediate visual response.

March 16, 2020

Technologies:
BERTFlaskNext.jsReactDocker

Emotibot: BERT sentiment analysis with visual feedback

The experiment

Emotibot explores how a trained language model can turn free-form text into an understandable sentiment result. A BERT model trained on a Twitter dataset classifies the input, and the interface maps the result to a corresponding emoji.

System design

  • React and Next.js provide the user interface.
  • Flask exposes the model through a small API.
  • BERT performs multi-label sentiment classification.
  • Docker keeps the model service and application environment reproducible.

Engineering focus

The main work was preparing the training data, evaluating closely related sentiment labels, and connecting a Python model service to a responsive web interface. Containerization made it easier to run the same model stack during development and deployment.

Result

The project provides a compact demonstration of an end-to-end machine-learning product: training, inference, an API boundary, deployment packaging, and a user-facing explanation of the output.