You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Star2 (2)You must be signed in to star a repository
About
AI-powered electricity demand forecasting for Delhi Power Grid. Predicts demand at 5-min, hourly, and daily resolutions using 7 ML models (0.18% MAPE). Built with FastAPI, Next.js, LightGBM, XGBoost, PyTorch. Deployed on Vercel + Render + Supabase.
Predicts electricity demand at 5-minute, hourly, and daily resolutions using 7 ML models trained on 5+ years of SCADA data from the Delhi SLDC.
Performance
Model
Resolution
MAPE
RMSE
R2
Size
LightGBM (Optuna)
Hourly
0.50%
24.9 MW
0.9983
15.8 MB
LightGBM
5-Minute
0.18%
8.6 MW
0.9997
8.1 MB
XGBoost
Hourly
0.52%
25.3 MW
0.9987
24.5 MB
LightGBM
Hourly
0.62%
30.2 MW
0.9985
~5 MB
LightGBM
Daily
2.65%
96.6 MW
0.90
3.0 MB
SARIMAX
Daily
4.18%
---
---
~2 MB
BiLSTM
Hourly
6.66%
327.2 MW
0.70
0.7 MB
NeuralProphet
Daily
7.68%
---
---
~5 MB
All metrics from walk-forward cross-validation (10-12 folds). Real-time prediction tracking: 0.97% avg MAPE over 29 days.
vs Previous System: 137x better accuracy, 49x smaller models, proper methodology (no data leakage).
SARIMAX/ARIMA now consume the full 93-feature exogenous set and NeuralProphet is fully wired — see docs/classical_models.md for the updated walk-forward eval.
What's New
Event-aware forecasting layer — learns each festival/holiday's measured demand impact (Diwali ≈ −10%, Id-ul-Fitr ≈ +3%) from 10 years of daily history and exposes it as a leakage-free expected_event_effect_pct feature. Validated with walk-forward CV and a recursive day-ahead backtest; shipped behind a flag (FeaturePipeline(..., include_event_effect=...)). → docs/event_aware_forecasting.md
Classical models use the full feature set — SARIMAX and a new ARIMA variant now take all ~93 engineered features as exogenous regressors (scaled, de-collinearized; target-history columns excluded to avoid linear leakage). Wired as optional challengers: train(resolution, extra_models=["sarimax", "arima", "neuralprophet"]). → docs/classical_models.md
NeuralProphet completed & wired — configurable regressors + robust predict; auto-joins the per-resolution ensemble and model registry when trained.
Faster frontend — a shared stale-while-revalidate cache makes tab switches instant (data no longer re-fetches from scratch on every navigation) and chart rendering is lighter. → docs/frontend_performance.md
Features
Data Pipeline
Real-time scraping from Delhi SLDC (5-min SCADA data)
Weather data from Open-Meteo (free, no API key)
Air Quality Index from Open-Meteo AQI
Indian holidays + festivals (Diwali, Holi, IPL, etc.)
Copyright (c) 2026 Rupesh Bharambe. All rights reserved.
About
AI-powered electricity demand forecasting for Delhi Power Grid. Predicts demand at 5-min, hourly, and daily resolutions using 7 ML models (0.18% MAPE). Built with FastAPI, Next.js, LightGBM, XGBoost, PyTorch. Deployed on Vercel + Render + Supabase.