Inspiration
The type of news ingested by people have great effects on them. Negative sentimental and toxic news can lead to hysteria and sometimes lead to depression. This is why a lot of people warn people to avoid the news. So in searching for ideas, I came up with a situation where users can search a global headline and view the prevalent sentiment, emotion contained in each reporting by several news source and select reporting that give clarity
What it does
NewsLens is an AI-powered truth compass—cutting through global headlines to expose bias and sentiment in how the same global event is reported. NewsLens scans the news to decode its intent. Because in a world flooded with narratives, clarity is power.
How we built it
I first built the app using Nextjs; A user interface to collect user input(news headlines) & display the global headline reported by various sources alongside the prevalent emotions and bias and used Nextjs server functions for backend code. Then I installed JSdom & rss-parser and created server functions to scrape news from different sources through RSS by searching for global headlines and store them in my MongoDb database using the packages. Afterwards, I used xenova/transformers to create embeddings for vector search for all the news articles I had scraped and stored in my database and store the embeddings. I moved on to create a search index for vector search on MongoDb. Finally I used hugging face free API to analyze each headline searched by the user and get the prevalent emotion, sentiment and bias in each news.
Challenges we ran into
My major challenge is that I google would not accept my Nigerian card. I contacted a google chat agent who did not provide any help and this kept my project stalling for weeks. So I couldn't utilize google cloud tools and after waiting, I used other free tools I could find. Like xenova/transformers to generate embeddings and hugging face free API to get bias and sentiments. Likewise I could not find any free news API to get news from different sources all over the world.
Accomplishments that we're proud of
Irrespective of all the limitations, I completed the application and NewsLens can analyze news for bias and sentiments.
What we learned
MongoDb vector search is powerful and a modern way to search documents semantically as well as find similar documents which makes it a great tool for building with AI.
What's next for newslens
I hope to get access to news API's and google Vertex AI because I believe there is more scanning I can do with Google vertex so I can add several features like adding a filter to filter our news based on sentiments, emotions and toxicity. Also using Vertex, I can analyze several sources and display to the users how those headlines are reported by western and non western sources, sources with left and right wing affiliations etc
Log in or sign up for Devpost to join the conversation.