Background and Objectives:Patient-specific seizure prediction based on Electroencephalogram (EEG) is a challenging and significant neuromedicine study, which could potentially safeguard drug-resistant patients from unforeseen risks in their daily lives. However, prevalent seizure prediction frameworks based on convolutional neural networks (CNNs) prioritize local information while overlooking long-range global dependencies and high-order spatial correlations prevalent among brain leads. Methods:To address the limitations above, we propose a novel Spatial–Temporal Hypergraph Attention Transformer (STHAT) framework for extracting the key features in EEG signals. Aimed at the characteristics of epilepsy EEG data, our framework comprises two primary branches: (1) Long-range Temporal Feature Dependencies: This branch aims to capture temporal dependencies within EEG signals by leveraging Swin Transformer and 2D-CNN. Utilizing shifting windows and convolution operations, we encode local and global content dependencies within segmented EEG samples. (2) High-Order Spatial Information Correlations: We construct a raw graph structure using the Pearson correlation coefficient, enabling the extraction of initial node embeddings through graph convolution operations (GCO). Subsequently, a dynamic hypergraph is formed using K-Nearest Neighbors (KNN) and K-means clustering, allowing us to employ a Hypergraph Attention Network (HAN) to capture structural context relationships among brain regions. By integrating information from both branches, we utilize a linear layer to derive the final seizure prediction outcome. Experiment and Results:Extensive evaluations are conducted on the widely used CHB-MIT dataset. Our comprehensive experimental results demonstrate the effectiveness of the proposed framework in achieving superior performance in automatic seizure data prediction, outperforming state-of-the-art algorithms. The STHAT framework effectively exploits both temporal and spatial information within EEG signals, enhancing seizure prediction accuracy.