All projects

Mood Analyser

Reads a journal entry and scores its sentiment and top six emotions, with a tracker that keeps the history.

Client
Self directed
Duration
4 days
Stack
Python, Transformers, VADER, Streamlit, SQLite, Matplotlib
Mood Analyser architecture: Streamlit app and SQLite MoodTracker sharing VADER and a DistilBERT emotion modelMood Analyser architecture: Streamlit app and SQLite MoodTracker sharing VADER and a DistilBERT emotion model
System architecture.

A self reflection tool: write how your day went and get back a sentiment score and the emotions underneath it.

It ships two ways: a Streamlit app for instant analysis and charts, and a SQLite backed tracker class that saves every entry for later review.

How it works

  1. Score the text

    VADER gives an overall sentiment score; a DistilBERT model trained on Google’s GoEmotions scores every emotion, and the app keeps the top six.

  2. Chart it

    Models load once and stay cached. A bar chart labels each emotion with its percentage and matches the light or dark theme.

  3. Track it

    The tracker stores date, entry, sentiment score and label, dominant emotion and all emotion scores in SQLite.

Sentiment and emotion analysis flow: VADER polarity scores and a text classification pipelineSentiment and emotion analysis flow: VADER polarity scores and a text classification pipeline
How a request flows through the system.

View the code on GitHub