Clear Sky Science · en
X2-AQFormer: unveiling dynamic drivers in multi-day hourly air pollution forecasting
Why Cleaner Air Forecasts Matter to You
City air pollution is not just an abstract health statistic—it affects whether children can safely play outside, how hospitals prepare for asthma attacks, and when commuters should leave their cars at home. European rules are about to tighten the limits on common pollutants such as nitrogen oxides and coarse particles (PM10), leaving cities with little room for error. This study introduces a new forecasting approach that not only predicts pollution levels several days ahead, but also explains why the air is expected to get better or worse, helping officials and the public make smarter, more trustworthy decisions.

A Smarter Way to See Tomorrow’s Air
The researchers focus on two key pollutants in Stockholm: nitrogen oxides (linked mainly to traffic) and PM10 (larger particles from road dust and other sources). Traditional models simulate how pollution moves and reacts in the atmosphere based on physics, but they often show systematic errors and depend on perfect input data. Modern machine-learning systems can correct many of these errors and capture complex patterns, yet they usually behave like “black boxes” whose inner reasoning is opaque. The authors set out to build a forecasting system that keeps the accuracy of advanced deep learning while clearly revealing which factors—such as wind, traffic-related patterns, or incoming weather fronts—drive its predictions over the coming hours and days.
A Transparent Brain for Air Quality
At the heart of the study is X2-AQFormer, a deep-learning model based on a Transformer architecture originally designed for handling long sequences, such as sentences. The model ingests a blend of information: recent pollution measurements at four monitoring sites, detailed weather forecasts, and outputs from an existing physics-based air quality system that simulates pollution over the region and within street canyons. Instead of predicting only the next hour and then stepping forward repeatedly, X2-AQFormer directly produces a whole 72-hour sequence of hourly forecasts for both nitrogen oxides and PM10. Its special “attention” mechanism acts like a spotlight, dynamically weighting which inputs matter most for each future hour, and these weights can be read out to show how the model is thinking.
Better Forecasts Where People Breathe
To test the new approach, the authors compared it with several strong competitors: the operational deterministic forecast used in Stockholm, standard Transformer-based neural networks, and widely used tree-based methods such as XGBoost and RandomForest. Across all four sites—three busy street canyons and one urban background station—X2-AQFormer consistently delivered more accurate forecasts, especially beyond the first few hours. Over one to three days, it reduced typical error measures by around one third compared with the deterministic model, and outperformed other deep-learning baselines by up to about 11 percent. Notably, it was particularly good at correcting the systematic underestimation of PM10 and overestimation of nitrogen oxides seen in the physics-based forecasts, and it detected episodes of very high pollution with the best balance of catching dangerous peaks without triggering too many false alarms.

Seeing the Hidden Drivers of Dirty and Clean Air
Because X2-AQFormer’s attention scores are built in, the team could track how different influences rise and fall over time. For nitrogen oxides on a busy street, recent measurements and the multi-day deterministic forecasts were the main drivers, while at the citywide background site, wind, cloud cover, and temperature became much more important, reflecting the role of regional air movements. For PM10 near traffic, the model leaned on past particle levels and weather conditions that control road dust resuspension, while at the background site it largely “trusted” the deterministic forecasts. The researchers also zoomed in on specific rain events: even though rainfall appeared unimportant on average, the model sharply increased the weight it gave to precipitation just before and during extended showers, mirroring how wet roads suppress dust. Over the 72-hour horizon, the system smoothly handed off influence from 1-day to 2-day to 3-day forecasts, showing an intuitive relay pattern in how it uses incoming information.
Turning Insight into Simpler, Stronger Tools
The interpretability of X2-AQFormer is not just academic; it points directly to ways of simplifying and improving real-world systems. By ranking input factors according to their contribution, the authors showed that for nitrogen oxides they could throw away roughly 70 percent of the features and still match—or slightly improve—performance, making a lighter and easier-to-maintain model. PM10 required a broader mix of inputs, underlining its more complex behavior. Overall, the study proposes a practical "Predict-Validate-Interpret-Optimize" workflow, in which cities can build accurate forecasts, rigorously test them, open up their inner logic, and then streamline them for daily use. For policymakers and citizens, this means cleaner air forecasts that are not only sharper, but also more transparent and trustworthy.
Citation: Zhang, Z., Schlesinger, D., Johansson, C. et al. X2-AQFormer: unveiling dynamic drivers in multi-day hourly air pollution forecasting. npj Clean Air 2, 17 (2026). https://doi.org/10.1038/s44407-026-00058-5
Keywords: air pollution forecasting, urban air quality, explainable AI, transformer models, NOx and PM10