Temporal Data Meets LLM -- Explainable Financial Time Series Forecasting

Xinli Yu,Zheng Chen,Yuan Ling,Shujing Dong,Zongyi Liu,Yanbin Lu
2023-06-19
Abstract:This paper presents a novel study on harnessing Large Language Models' (LLMs) outstanding knowledge and reasoning abilities for explainable financial time series forecasting. The application of machine learning models to financial time series comes with several challenges, including the difficulty in cross-sequence reasoning and inference, the hurdle of incorporating multi-modal signals from historical news, financial knowledge graphs, etc., and the issue of interpreting and explaining the model results. In this paper, we focus on NASDAQ-100 stocks, making use of publicly accessible historical stock price data, company metadata, and historical economic/financial news. We conduct experiments to illustrate the potential of LLMs in offering a unified solution to the aforementioned challenges. Our experiments include trying zero-shot/few-shot inference with GPT-4 and instruction-based fine-tuning with a public LLM model Open LLaMA. We demonstrate our approach outperforms a few baselines, including the widely applied classic ARMA-GARCH model and a gradient-boosting tree model. Through the performance comparison results and a few examples, we find LLMs can make a well-thought decision by reasoning over information from both textual news and price time series and extracting insights, leveraging cross-sequence information, and utilizing the inherent knowledge embedded within the LLM. Additionally, we show that a publicly available LLM such as Open-LLaMA, after fine-tuning, can comprehend the instruction to generate explainable forecasts and achieve reasonable performance, albeit relatively inferior in comparison to GPT-4.
Machine Learning,Artificial Intelligence,Computation and Language,Statistical Finance
What problem does this paper attempt to address?
The paper aims to address several key challenges in financial time series forecasting, particularly how to leverage large language models (LLMs) for interpretable financial time series prediction. Specifically: 1. **Cross-Sequence Reasoning and Inference**: In financial time series analysis, cross-sequence reasoning is an important aspect, but existing methods struggle to effectively capture the complex dependencies in time series data. 2. **Multimodal Data Processing**: Financial time series not only include numerical sequences but also multimodal information such as historical news and financial knowledge graphs. Existing methods like statistical inference, recurrent neural networks (RNNs), convolutional neural networks (CNNs), and graph neural networks (GNNs) face difficulties in integrating this complex information. 3. **Interpretability and Transparency**: Most deep learning models are considered "black boxes" and lack the ability to explain their decision-making processes. This is particularly important in the financial domain, where the risks associated with investments and assets are high. The paper addresses these issues through the following methods: - Conducting zero-shot and few-shot reasoning experiments using GPT-4; - Utilizing the open LLM model Open LLaMA for instruction-based fine-tuning; - Introducing the "Chain-of-Thoughts" (COT) technique to enhance model performance. Through these methods, the paper demonstrates the potential of LLMs in handling complex time series data and generating human-readable explanations. It also shows that LLMs outperform traditional ARMA-GARCH models and gradient boosting tree models in terms of prediction accuracy and explanation quality.