Inspiration

I've been on the receiving end of many text messages where seeing the sender's face or hearing the tone in their voice would've been beneficial in understanding the meaning. This application is meant to help in such situations by giving the recipient of such a message a better understanding of the message's connotation (positive or negative).

What it does

The application takes as input the content of a text message and returns three pieces of information: a prediction ("positive" or "negative") and the probabilities associated with each possible outcome. These three pieces of information are the output of a Naive Bayes Analyzer model from the TextBlob library.

How we built it

The frontend application was developed using React/CSS and deployed to Github Pages. The backend was developed using Python, specifically the Flask/Flask CORS libraries for implementing the backend API and the TextBlob/NLTK libraries for the sentiment analysis functionalities, and it was deployed using Heroku.

Challenges we ran into

Getting the frontend and backend to communicate was especially difficult, as was getting the frontend to properly deploy to Github Pages.

Accomplishments that we're proud of

The last time I created a full end-to-end web application, it took me over two weeks to implement and connect each component, and then another few days to deploy the components and resolve post-deployment issues. However, this time it only took a few hours, so I'm really proud of how far I seem to have come.

What we learned

I learned more about NLP, especially the TextBlob and NLTK libraries. I also learned how to pass text data from a React frontend to a Flask backend (last time I did this type of project, I was dealing with image data instead of text data).

What's next for Text Message Sentiment Analysis

Because of recent events which have taken place in my personal life, I was unable to commit to the full 24-hour coding sprint I had initially hoped to partake in. However, I still really wanted to participate, so I settled on a simpler project which I could complete in a few hours.

This said, I'd really like to improve on this project when I have the time, as the model used doesn't seem to be as effective as I had initially hoped. Specifically, I'm hoping to use a better model for the sentiment analysis task, such as a T5 or even a fine-tuned Llama model.

Share this project:

Updates