A Dynamic Lifelong Learning Network for Real-Time Stock Prediction With Reinforcement Tuning
Talent Mawere1, Selvaraj Rajalakshmi1, Venu Madhav Kuthadi1 & Otlhapile Dinakanyane1 Show affiliations
- Department of Computing and Informatics, School of Pure and Applied Sciences, Botswana International University of Science and Technology, Palapye, Botswana
Journal of Computer Science, Volume 22, Issue 2, pp. 420–434 · doi.org/10.3844/jcssp.2026.420.434
Abstract
Companies and investors require accurate market forecasting to make more informed decisions. Traditional methods for predicting stock market performance have become less useful considering the dynamic and volatile nature that characterizes stock markets today. In this paper, we propose an innovative Dynamic Lifelong Learning Network for stock market prediction. The model incorporates a hybrid convolutional long short-term memory with an attention mechanism for spatiotemporal feature extraction. To address the problem of static batch processing common in most current machine learning techniques in use, we employ reinforcement learning through a Deep Q-Network for real-time adaptation. We then integrated Elastic Weight Consolidation to address the problem of catastrophic forgetting. The model inputs a comprehensive set of structured features, including historical OHLCV data, technical indicators, and macroeconomic variables such as interest rates and the Consumer Price Index. We applied principal component analysis to optimize dimensionality. The model was trained and tested on APPL data extracted from Yahoo Finance for the period 2010-2023. Macroeconomic features were extracted from the Federal Reserve Economic Data for the same period. Ablation studies confirmed the hypothesis that add-on features such as the attention network and RL-EWC improve the prediction capacity of our model by at least 12.35%. Comparison of our model with literature-identified baselines showed that our model performed much better, with an R² of 0.967±0.01 and an MAE of 3.22±0.27. Generalization testing on the SPY ticker, a key representative for the S&P 500 index, shows that the model is robust.
Licence and reuse
Open access. This article is licensed under a Creative Commons Attribution 4.0 International Licence (CC BY 4.0), as printed on the article, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original authors and the source. No permission is needed.
How to reuse this articleResponses (0)
About this article
Mawere, T., Rajalakshmi, S., Kuthadi, V. M. & Dinakanyane, O. (2026). A Dynamic Lifelong Learning Network for Real-Time Stock Prediction With Reinforcement Tuning. Journal of Computer Science, 22(2), 420–434. https://doi.org/10.3844/jcssp.2026.420.434
- Licence
- CC BY 4.0
- Issue
- Volume 22, Issue 2
- Policies
- Editorial independenceUse of generative AIData availabilityAppeals and complaints
- Version
- Version of record
