Abstract
Air pollution poses a major environmental and public health challenge in Metropolitan Lima, Peru, where complex topography, coastal meteorological conditions, and intense urbanization generate highly dynamic patterns of pollutant concentrations. Accurate multi-horizon forecasting is therefore essential for supporting environmental monitoring and early-warning systems. This study proposes a hybrid deep learning framework, called VMD-Attention-BiLSTM, for forecasting hourly PM2.5, PM10, and NO2 concentrations using a decade of hourly air quality observations (2015–2024) collected by the National Meteorology and Hydrology Service of Peru (SENAMHI). The proposed methodology integrates a strictly causal preprocessing pipeline—including forward-only imputation, spatial-corroborated percentile-95 outlier detection, and pollutant-calibrated Variational Mode Decomposition (VMD)—with a Bidirectional Long Short-Term Memory (BiLSTM) network enhanced by a Bahdanau-style attention mechanism. All transformations are fitted exclusively on the training partitions of a five-fold TimeSeriesSplit cross-validation to prevent information leakage. A systematic benchmark of 1008 imputation experiments was conducted to justify the choice of causal linear interpolation over Kalman Filter alternatives. Model performance was evaluated at 24-, 48-, and 72-h forecasting horizons. The optimized framework achieved competitive predictive performance across the evaluated horizons, yielding best RMSE values of 9.04, 19.93, and 9.41 µg/m3 for PM2.5, PM10, and NO2 at 24 h, degrading to 9.79, 24.56, and 11.02 µg/m3 at 72 h. All metrics are reported on the original concentration scale. VMD sensitivity analysis revealed that the optimal mode count is pollutant-dependent ( for particulate matter; for NO2). Furthermore, the ablation study showed that the complete VMD-Attention-BiLSTM configuration provided competitive and frequently improved performance relative to the baseline and partial configurations, with the magnitude of the improvement varying according to pollutant and forecasting horizon. The obtained results indicate that integrating signal decomposition with attention-based bidirectional learning can provide complementary benefits for forecasting under highly non-stationary urban conditions, particularly at shorter forecasting horizons. The proposed framework provides a reproducible and scalable solution for intelligent air-quality forecasting and serves as a valuable decision-support tool for environmental monitoring and public health protection in complex metropolitan environments.