Regime-aware financial volatility forecasting via in-context learning
Authors: Saba Asaad, Shayan Mohajer Hamidi, Ali Bereyhi
Organizations: Department of Electrical and Computer Engineering, University of Toronto, Toronto, Canada · Department of Electrical Engineering, Stanford University, Stanford, CA, USA
This work introduces a regime-aware in-context learning framework that leverages large language models (LLMs) for financial volatility forecasting under nonstationary market conditions. The proposed approach deploys pretrained LLMs to reason over historical volatility patterns and adjust their predictions without parameter fine-tuning. We develop an oracle-guided refinement procedure that constructs regime-aware demonstrations from training data. An LLM is then deployed as an in-context learner that predicts the next-step volatility from the input sequence using demonstrations sampled conditional to the estimated market label. This conditional sampling strategy enables the LLM to adapt its predictions to regime-dependent volatility dynamics through contextual reasoning alone. Experiments with multiple financial datasets show that the proposed regime-aware in-context learning framework outperforms both classical volatility forecasting approaches and direct one-shot learning, especially during high-volatility periods.
Figures & tables
Figure 1: Illustration of the proposed prompt-based volatility forecasting framework. (1) A fixed pretrained LLM is first prompted with recent log returns and realized variance to produce an initial estimate. (2) Oracle feedback is build from the ground truth and used iteratively to refine predictions. (3) A regime-labeled demonstration pool is constructed from refined predictions. (4) Demonstrations are selected conditional to estimated volatility regime and provided as in-context examples to generate a forecast of the next-day realized variance.
Dataset
Method
MAE(↓)
RMSE(↓)
MAElow(↓)
MAEhigh(↓)
×104
S&P500
Rolling mean
1.41
4.87
0.73
4.13
HAR
1.17
5.36
0.25
4.85
GARCH(1,1)
1.34
4.80
0.71
3.86
GJR-GARCH
1.33
4.64
0.72
3.76
One-shot learning
1.72
6.68
0.87
5.09
Random selection
1.22
4.77
0.65
3.12
Table 1: Volatility forecasting performance across multiple assets in terms of RMSE and MAE. The results are normalized to 10−4 . Low- and high-volatility regimes are defined using the 80th percentile of realized variance. Regime-aware in-context learning enhances the performance, due to better estimate in high regime.
Financial volatility is regime dependent, yet incorporating regime information into neural networks can also destabilize training. This paper asks where such information should enter a neural cross-sectional volatility forecasting model. We study five-day realized-volatility forecasts for 1,027 U.S. equities using a rolling walk-forward evaluation framework in which information, model capacity, hyperparameter tuning, and random seeds are matched across architectures. We propose RG-ResMoE, a regime-gated residual mixture-of-experts architecture in which regime information is used only for expert routing rather than for direct forecasting. The base predictor models volatility from stock features, while a gating network uses regime state variables to route residual corrections. RG-ResMoE consistently outperforms a capacity-matched MLP in both forecasting accuracy and training stability in the main U.S. study. Similar gains are observed on an independent Japanese panel. The integration pathway is decisive: appending the same regime variables directly to the forecasting input degrades both predictive performance and training stability, whereas restricting them to the routing gate improves accuracy and Value-at-Risk calibration. Hard routing consistently underperforms soft routing. The results suggest that, in compact neural volatility forecasting models, the primary value of mixture-of-experts models lies less in increasing model capacity than in controlling how nonstationary regime information influences prediction.
Junyi Ye, Gargi Vijay Borde
School of Computing, Montclair State University · Montclair, New Jersey, USA
Volatility forecasts are commonly evaluated with aggregate accuracy metrics such as RMSE and MAE, but these metrics can hide conditional failures that matter for risk management. This paper proposes a model-agnostic audit framework for evaluating whether volatility forecasts remain reliable across latent market regimes. We learn time-series representations of market-state windows, cluster them into regimes using only training information, assign regimes out of sample, and compare aggregate forecast behavior with regime-conditional bias, tail-underprediction, and underprediction-sensitive economic losses. Applied to daily volatility forecasting across cryptocurrency and ETF assets, the audit shows that models with competitive aggregate accuracy can still exhibit substantial regime-specific bias and severe tail underprediction. The results suggest that volatility forecasting should be evaluated not only by average error, but also by where and how forecasts become unreliable. Our framework shifts forecast evaluation from asking which model is most accurate on average to identifying the market regimes in which apparently accurate forecasts fail conditionally. Reproducibility: https://github.com/arthurchagas1/Latent-Regime-Bias-Auditing-for-Volatility-Forecasting
Arthur Chagas, Pedro Bento, Yan Aquino +3
Department of Computer Science Universidade Federal de Minas Gerais – UFMG Belo Horizonte, Brazil
The problem of time-series forecasting in non-stationary and complex environments is a challenging task in machine learning, especially with heterogeneous numerical and textual data present. Traditional statistical models like AutoRegressive Integrated Moving Average (ARIMA) are based on the assumptions of linearity and stationarity, whereas recurrent neural networks like Long Short-Term Memory (LSTM) models do not necessarily represent distributional properties in highly volatile settings. This paper proposes a hybrid model that combines Generative Adversarial Networks (GANs) with Natural Language Processing (NLP)-based sentiment analysis to enable sentiment-conditioned time-series prediction. The model integrates adversarial learning on numerical sequences with contextual sentiment representations derived from unstructured text, enabling them to be jointly modelled to capture temporal dynamics and exogenous information. These results demonstrate the promise of hybrid generative and language-aware methods to enhance prediction robustness in non-stationary environments.
Alexis Lazanas, Spyridon Karpouzis
Department of Mechanical Engineering and Aeronautics, University of Patras, Rion-Patras, Greece · FICC Market Risk, BNP Paribas CIB, London, United Kingdom