Improving Financial Forecasting with a Synergistic LLM-Transformer Architecture: A Hybrid Approach to Stock Price Prediction
Preprint
Abstract
This study proposes a novel hybrid deep learning framework that integrates a Large Language Model (LLM) with a Transformer architecture for stock price forecasting. The research addresses a critical theoretical gap in existing approaches that empirically combine textual and numerical data without a formal understanding of their interaction mechanisms. We conceptualise a prompt-based LLM as a mathematically defined signal generator, capable of extracting directional market sentiment and an associated confidence score from financial news. These signals are then dynamically fused with structured historical price features through a noise-robust gating mechanism, enabling the Transformer to adaptively weigh semantic and quantitative information. Empirical evaluations demonstrate that the proposed Hybrid LLM-Transformer model significantly outperforms a Vanilla Transformer baseline, reducing the Root Mean Squared Error (RMSE) by 5.28% (p = 0.003). Moreover, ablation and robustness analyses confirm the model's stability under noisy conditions and its capacity to maintain interpretability through confidence-weighted attention. The findings provide both theoretical and empirical support for a paradigm shift from empirical observation to formalised modelling of LLM-Transformer interactions, paving the way toward explainable, noise-resilient, and semantically enriched financial forecasting systems.Keywords
All Related Versions
This publication has 8 references indexed in Scilit:
- Multi-Modal Deep Reinforcement Learning Framework for Interference-Limited RIS-Assisted UAV Wireless Network2025
- LLM-Augmented Linear Transformer–CNN for Enhanced Stock Price PredictionMathematics, 2025
- Across-time risk-aware strategies for outperforming a benchmarkEuropean Journal of Operational Research, 2023
- Towards fake news refuter identification: Mixture of Chi-Merge grounded CNN approachExpert Systems with Applications, 2023
- Transformer-Based Deep Learning Model for Stock Price Prediction: A Case Study on Bangladesh Stock MarketInternational Journal of Computational Intelligence and Applications, 2023
- Harnessing LLMs for Temporal Data - A Study on Explainable Financial Time Series Forecasting2023
- Mining actionable combined patterns of high utility and frequency2015
- Critical Mass of What? Exploring Community Growth in WikiProjectsProceedings of the International AAAI Conference on Web and Social Media, 2014