FinanceGuard AI is a distributed system for sentiment analysis of financial news. It monitors configurable assets (Stocks, Crypto), analyzes news sentiment using FinBERT, and triggers notifications on significant market events.
The system consists of two microservices:
-
Sentinel Service:
- Aggregates news via RSS (Google News, Yahoo Finance) and yfinance
- Prevents duplicates via hashing and SQLite caching
- Sends Telegram notifications
-
API Service:
- Hosts the ML model (
ProsusAI/finbert) via FastAPI - Asynchronous sentiment analysis of news titles
- Hosts the ML model (
- Python 3.11
- FastAPI / Uvicorn
- Transformers / PyTorch (FinBERT)
- Docker & Docker Compose
- SQLite (Persistence)
Prerequisites: Docker and Docker Compose.
-
Clone repository and create
.envfile:cp .env.example .env # Customize .env (Telegram Token etc.) -
Start containers:
docker-compose up --build -d
-
Monitor logs:
docker-compose logs -f
Configuration is handled via environment variables in .env:
WATCHLIST: Assets to monitorSCAN_INTERVAL_MINUTES: Scan intervalSENTIMENT_THRESHOLD: Alert threshold (0.0 - 1.0)