TrendRadar
Early detection of viral trends
A machine-learning system that predicts which keywords will go viral, from their very first minutes of activity.
- Context
- Team project · 4 members
- Year
- 2026
- Models
- XGBoost · River ARF
- Learning
- Offline + online
- ROC-AUC
- 0.921
- How well the model ranks keywords that went viral above those that didn’t. 0.5 is chance; 1.0 is perfect.
- Early signal
- 15 min
- All the model sees: a keyword’s first 15 minutes of activity.
- Prediction horizon
- 12 h
- What it predicts: the keyword’s virality over the next 12 hours.
- Tweets
- ~179k
- Tweets the XGBoost model was trained on.
01Context
A team project from the AI & Data Science curriculum focused on predictive modelling and online learning. TrendRadar watches the first minutes of a keyword’s activity on social platforms and estimates how viral it will become.
02Problem
By the time a trend is obviously viral, it’s too late to act on it. And social media behaviour keeps shifting, so a model trained once slowly goes stale.
03Architecture
01Sources
Social connectors
Bluesky · Mastodon
02Window
First 15 minutes
Early activity signal
03Features
Extraction + normalisation
04Model
XGBoost
Tuned with Optuna
ROC-AUC 0.921
05Output
12-hour virality
06Online
River Adaptive Random Forest
06Drift
Concept-drift detection
04Team
Team project (4 members) focused on early viral-trend prediction from social-media activity, combining XGBoost, feature engineering, hyperparameter optimisation, and online learning with concept-drift detection.
05Technical decisions
- 01
Predict from the earliest signal
Predictions come from the opening minutes of activity, so they arrive while a trend is still early enough to act on.
- 02
Gradient-boosted trees, tuned with Optuna
XGBoost handles the offline prediction; Optuna searches hyperparameters and feature configurations.
- 03
Keep learning from new data
A River Adaptive Random Forest learns online from new data and detects concept drift when patterns change.
- 04
Pluggable data connectors
Bluesky and Mastodon connectors are built on a shared base connector, keeping data collection separate from the models.
06Results
- Virality predicted from a keyword’s opening minutes, while the trend is still early
- An online model that adapts as social media behaviour shifts
- A Streamlit application on top of the models
07Stack
- Python
- XGBoost
- scikit-learn
- Optuna
- River
- pandas
- NumPy
- Streamlit
08GitHub
Building something similar?
Start a project