Inspiration

There are numerous problems with how we receive news here in the United States. One of such problems is that the media tends to focus on the negative news, leading to sad and depressing headlines that discourage some from reading the news at all. We wanted to tackle this challenge by leveraging machine learning and natural language processing to perform sentiment analysis on our current events and classifying them as "positive" or "negative"

What it does

This app is designed to pull in news from various news outlets and allow users to only select the topics the user is interested in and to filter out only content that is deemed positive or negative.

How we built it

We used Sveltekit as the full stack framework with TailwindCSS and deployed the app to Vercel. We chose the combination of Svelte and Tailwind for its rapid development capabilities. The sentiment analysis was built using Natural, a general purpose NLP library for Javascript.

The app starts off by pulling in news articles from various news outlets via RSS feeds. It then proceeds to parse and tokenize the headline and description to feed into the sentiment analysis model. The model returns a score between 0 and 1 that we scale up to 0 to 100 and display that information to the user, who can then select filters based on their liking

Challenges we ran into

One of the main challenges we ran into was that the app originally supported a few more news outlets. However, when we deployed the app to Vercel, our serverless function invocation was timing out so we had to limit our application to only 3 news outlets as to allow the data fetching process to complete within the serverless time limit. Additionally much of the group was new to web development and machine learning concepts so it was a learning experience to do so.

Accomplishments that we're proud of

What we learned

What's next for PositivityPost

Built With

Share this project:

Updates