Inspiration
Financial markets move on information — but the volume of news is overwhelming. We wanted to answer a simple question: can an AI read the news faster and more objectively than a human, and turn it into actionable trading signals? We were inspired by the growing field of quantitative finance and NLP, and wanted to make data-driven trading accessible to everyone, not just hedge funds.
What it does
Sentra AI ingests live financial news headlines for any stock ticker, scores each article using a financial AI model, and aggregates the sentiment into daily buy, hold, or sell signals. Users can explore a real-time dashboard showing sentiment over time, a backtested strategy vs buy-and-hold comparison, and a sortable feed of scored headlines with links to original articles. Parameters like timeframe, signal sensitivity, and starting capital are all adjustable interactively.
How we built it
We split the work across two people. The backend was built in Python using FastAPI — news is fetched from both NewsAPI and Yahoo Finance, scored using ProsusAI/FinBERT via HuggingFace Transformers, aggregated into daily sentiment scores, and converted into signals. A backtesting engine simulates portfolio performance against a buy-and-hold benchmark using real historical price data. The frontend was built in React with Vite and Recharts, consuming the live FastAPI endpoints to render interactive charts, metric cards, and a scored headlines feed.
Challenges we ran into
Yahoo Finance only returns a few days of news regardless of timeframe, so our backtest never had enough signal history. We solved this by combining NewsAPI for historical coverage with yfinance for breaking news and deduplicating by title. We also hit timezone comparison errors when filtering articles by date, and a chart scale mismatch when plotting stock price alongside portfolio value — solved with a dual Y-axis in Recharts. Coordinating two independent codebases under time pressure required clear API contracts and mock data on the frontend from day one. Accomplishments that we're proud of Building a complete end-to-end ML pipeline in under 48 hours — from live news ingestion and AI sentiment scoring through to signal generation, backtesting, and a polished interactive dashboard. We're particularly proud of the dual-source news aggregation, the interactive backtest chart with toggleable lines, and the sensitivity slider that lets users see signals change in real time. WE CANNOT GET THE HOSTING TO WORK ;(. Big Challenge we left far too late.
What we learned
How to build a full ML pipeline from data ingestion to a live web dashboard. How transformer-based models like FinBERT work for domain-specific NLP tasks. How to aggregate sentiment scores into statistically meaningful signals using a threshold rule, and how to backtest a strategy against a benchmark. How to connect a Python backend to a React frontend cleanly using REST APIs, CORS middleware, and a shared API contract.
What's next for Sentra AI
Expanding to more tickers and asset classes beyond equities. Integrating a paid news API for deeper historical coverage to improve backtest accuracy. Adding portfolio-level analysis across multiple tickers simultaneously. Exploring more sophisticated signal generation using weighted sentiment, volume-adjusted scoring, and momentum indicators. Potentially training a custom sentiment model fine-tuned specifically on the tickers and news sources most relevant to retail investors.
Built With
- fastapi
- huggingface-transformers
- javascript
- newsapi
- pandas
- prosusai/finbert
- python
- pytorch
- react
- react-router
- recharts
- uvicorn
- vite
- yfinance
Log in or sign up for Devpost to join the conversation.