Abstract
Recurrent Neural Networks, specifically LSTMs, are widely used for time-series forecasting but often function as "black boxes" when handling multi-variable data. This paper introduces the Interpretable Multi-Variable LSTM (IMV-LSTM), an architecture designed to provide transparency by maintaining separate hidden states for each input variable. By incorporating a mixture attention mechanism and an EM-based training framework, IMV-LSTM enables the quantification of both variable and temporal importance. Experimental results across four real-world datasets demonstrate that IMV-LSTM not only offers superior interpretability but also outperforms standard LSTMs and other baselines in predictive accuracy.
Introduction
Standard LSTMs typically blend multiple exogenous variables into a single hidden state vector. This approach creates an "interpretability gap," as the specific contribution of individual variables over time cannot be easily disentangled. Furthermore, it creates a "modeling gap" because variables with different temporal dynamics are forced into a unified representation, potentially degrading performance. While post-hoc analysis or simple temporal attention can offer some insights, they fail to identify which specific variable drove a prediction at a given time step.
Methodology
The IMV-LSTM architecture addresses these gaps by ensuring that information from each input variable remains distinct throughout the recurrence.
Variable-Wise Hidden States
Instead of a single hidden vector, the model maintains a hidden state matrix where each row corresponds to a specific input variable. This allows the model to capture the unique dynamics of each variable independently. Two versions were developed: IMV-Full, which uses the full previous hidden matrix for gate updates, and IMV-Tensor, which utilizes tensor-dot operations to treat variables as parallel LSTMs that interact only at the final attention stage, significantly reducing parameter overhead.
Mixture Attention and EM Training
The model employs a two-stage mixture attention mechanism. It first calculates temporal importance (which past time steps matter for a specific variable) and then determines the overall variable importance for the final prediction. To mitigate noise in raw attention weights, an Expectation-Maximization (EM) framework is used to learn a stable, global importance vector across the dataset.
Experimental Setup
The authors evaluated IMV-LSTM on four diverse real-world datasets:
- PM2.5: Beijing air quality prediction using meteorological data.
- PLANT: Energy production of a photo-voltaic plant based on weather variables.
- SML: Indoor temperature forecasting with 16 exogenous variables.
- NASDAQ: Prediction of the NASDAQ 100 index using 81 corporate stock prices.
Results and Discussion
IMV-LSTM (specifically the Tensor version) consistently outperformed baselines such as ARIMAX, Random Forests, and standard LSTMs, reducing prediction error by up to 80% in some scenarios.
Interpretability and Domain Consistency
The model's attention mechanisms provided insights consistent with domain knowledge. For instance, in the PM2.5 task, wind speed and pressure were correctly identified as primary drivers. In the SML task, the model distinguished between the long-term correlation of outdoor temperature and the immediate impact of indoor humidity.
As shown in the attention value distributions, the model learns to differentiate between significant and non-significant features over time. The EM approach proved crucial for interpretability, "smoothing" noisy raw attention values into a global importance rank that aligns with scientific findings. This robustness allows for reliable feature selection; discarding the bottom 50% of ranked variables often maintained or improved accuracy.
Conclusion
IMV-LSTM represents a significant step toward transparent deep learning for time-series analysis. By separating hidden states and applying structured attention, the model transforms from a black box into a scientific tool capable of explaining its forecasts. Future work may explore higher-order variable interactions and scaling the architecture to handle thousands of input features.
Summary updated