# Temporal and Heterogeneous Graph Neural Network for Financial Time Series Prediction

arXiv: https://arxiv.org/abs/2305.08740 · HTML: https://mlsanity.com/paper/2305.08740/

## Key facts

- Cited by 30 papers in the map (data through 14 Oct 2026).
- Builds on 13 of its 46 references that are in the map.
- First posted on arXiv 9 May 2023.

## Builds on (most cited first, 13 of 13)

- [Attention Is All You Need](https://mlsanity.com/paper/1706.03762/) (2017)
- [Adam: A Method for Stochastic Optimization](https://mlsanity.com/paper/1412.6980/) (2014)
- [Learning Phrase Representations using RNN Encoder-Decoder for Statistical Machine Translation](https://mlsanity.com/paper/1406.1078/) (2014)
- [A Comprehensive Survey on Graph Neural Networks](https://mlsanity.com/paper/1901.00596/) (2019)
- [A Survey on Knowledge Graphs: Representation, Acquisition and Applications](https://mlsanity.com/paper/2002.00388/) (2020)
- [Do Transformers Really Perform Bad for Graph Representation?](https://mlsanity.com/paper/2106.05234/) (2021)
- [Temporal Relational Ranking for Stock Prediction](https://mlsanity.com/paper/1809.09441/) (2018)
- [Motifs in Temporal Networks](https://mlsanity.com/paper/1612.09259/) (2016)
- [HATS: A Hierarchical Graph Attention Network for Stock Movement Prediction](https://mlsanity.com/paper/1908.07999/) (2019)
- [REST: Relational Event-driven Stock Trend Forecasting](https://mlsanity.com/paper/2102.07372/) (2021)
- [Classification-based Financial Markets Prediction using Deep Neural Networks](https://mlsanity.com/paper/1603.08604/) (2016)
- [Image Cropping with Composition and Saliency Aware Aesthetic Score Map](https://mlsanity.com/paper/1911.10492/) (2019)
- [Learning from Web Data with Self-Organizing Memory Module](https://mlsanity.com/paper/1906.12028/) (2019)

## Built on by (most cited first, 30 of 30)

- [R&D-Agent-Quant: A Multi-Agent Framework for Data-Centric Factors and Model Joint Optimization](https://mlsanity.com/paper/2505.15155/) (2025)
- [Semi-supervised Credit Card Fraud Detection via Attribute-Driven Graph Representation](https://mlsanity.com/paper/2412.18287/) (2024)
- [FinTSB: A Comprehensive and Practical Benchmark for Financial Time Series Forecasting](https://mlsanity.com/paper/2502.18834/) (2025)
- [SSD-TS: Exploring the Potential of Linear State Space Models for Diffusion Models in Time Series Imputation](https://mlsanity.com/paper/2410.13338/) (2024)
- [Multi-relational Graph Diffusion Neural Network with Parallel Retention for Stock Trends Classification](https://mlsanity.com/paper/2401.05430/) (2024)
- [Text2TimeSeries: Enhancing Financial Forecasting through Time Series Prediction Updates with Event-Driven Insights from Large Language Models](https://mlsanity.com/paper/2407.03689/) (2024)
- [A Systematic Literature Review of Spatio-Temporal Graph Neural Network Models for Time Series Forecasting and Classification](https://mlsanity.com/paper/2410.22377/) (2024)
- [DGDNN: Decoupled Graph Diffusion Neural Network for Stock Movement Prediction](https://mlsanity.com/paper/2401.01846/) (2024)
- [CaT-GNN: Enhancing Credit Card Fraud Detection via Causal Temporal Graph Neural Networks](https://mlsanity.com/paper/2402.14708/) (2024)
- [MANA-Net: Mitigating Aggregated Sentiment Homogenization with News Weighting for Enhanced Market Prediction](https://mlsanity.com/paper/2409.05698/) (2024)
- [Evaluating Financial Relational Graphs: Interpretation Before Prediction](https://mlsanity.com/paper/2410.07216/) (2024)
- [NGAT: A Node-level Graph Attention Network for Long-term Stock Prediction](https://mlsanity.com/paper/2507.02018/) (2025)
- [MCI-GRU: Stock Prediction Model Based on Multi-Head Cross-Attention and Improved GRU](https://mlsanity.com/paper/2410.20679/) (2024)
- [Methods for Acquiring and Incorporating Knowledge into Stock Price Prediction: A Survey](https://mlsanity.com/paper/2308.04947/) (2023)
- [Scalable Transformer for High Dimensional Multivariate Time Series Forecasting](https://mlsanity.com/paper/2408.04245/) (2024)
- [PhysicsAgentABM: Physics-Guided Generative Agent-Based Modeling](https://mlsanity.com/paper/2602.06030/) (2026)
- [Model Inversion Attacks on Homogeneous and Heterogeneous Graph Neural Networks](https://mlsanity.com/paper/2310.09800/) (2023)
- [ScaDyG:A New Paradigm for Large-scale Dynamic Graph Learning](https://mlsanity.com/paper/2501.16002/) (2025)
- [Hermes: A Multi-Scale Spatial-Temporal Hypergraph Network for Stock Time Series Forecasting](https://mlsanity.com/paper/2509.23668/) (2025)
- [Graph Convolutional Network For Semi-supervised Node Classification With Subgraph Sketching](https://mlsanity.com/paper/2404.12724/) (2024)
- [HeteroBA: A Structure-Manipulating Backdoor Attack on Heterogeneous Graphs](https://mlsanity.com/paper/2505.21140/) (2025)
- [EP-GAT: Energy-based Parallel Graph Attention Neural Network for Stock Trend Classification](https://mlsanity.com/paper/2507.08184/) (2025)
- [Generative Dynamic Graph Representation Learning for Conspiracy Spoofing Detection](https://mlsanity.com/paper/2510.05562/) (2025)
- [Empirical Mode Decomposition and Graph Transformation of the MSCI World Index: A Multiscale Topological Analysis for Graph Neural Network Modeling](https://mlsanity.com/paper/2512.12526/) (2025)
- [HeteroHBA: A Generative Structure-Manipulating Backdoor Attack on Heterogeneous Graphs](https://mlsanity.com/paper/2512.24665/) (2025)
- [GAPNet: Plug-in Jointly Learning Task-Specific Graph for Dynamic Stock Relation](https://mlsanity.com/paper/2602.00888/) (2026)
- [Relational Probing: LM-to-Graph Adaptation for Financial Prediction](https://mlsanity.com/paper/2604.10212/) (2026)
- [Empowering Credit Risk Detection in Weixin Pay with Billion-Scale Deep Graph Learning](https://mlsanity.com/paper/2608.02168/) (2026)
- [Trojaning the Alignment: Stealthy Backdoor Attacks against Graph Foundation Models](https://mlsanity.com/paper/2608.20991/) (2026)
- [Nystr"om Attention Matches Full Attention for Cross-Sectional Stock Prediction](https://mlsanity.com/paper/2609.08106/) (2026)

## Abstract (arXiv)

The price movement prediction of stock market has been a classical yet challenging problem, with the attention of both economists and computer scientists. In recent years, graph neural network has significantly improved the prediction performance by employing deep learning on company relations. However, existing relation graphs are usually constructed by handcraft human labeling or nature language processing, which are suffering from heavy resource requirement and low accuracy. Besides, they cannot effectively response to the dynamic changes in relation graphs. Therefore, in this paper, we propose a temporal and heterogeneous graph neural network-based (THGNN) approach to learn the dynamic relations among price movements in financial time series. In particular, we first generate the company relation graph for each trading day according to their historic price. Then we leverage a transformer encoder to encode the price movement information into temporal representations. Afterward, we propose a heterogeneous graph attention network to jointly optimize the embeddings of the financial time series data by transformer encoder and infer the probability of target movements. Finally, we conduct extensive experiments on the stock market in the United States and China. The results demonstrate the effectiveness and superior performance of our proposed methods compared with state-of-the-art baselines. Moreover, we also deploy the proposed THGNN in a real-world quantitative algorithm trading system, the accumulated portfolio return obtained by our method significantly outperforms other baselines.
