Abstract
The diversity of time series applications and scarcity of domain-specific data highlight the need for time-series models with strong few-shot learning capabilities. In this work, we propose a novel training scheme and a transformer-based architecture, collectively referred to as TimePFN, for multivariate time-series (MTS) forecasting. TimePFN is based on the concept of Prior-data Fitted Networks (PFN), which aims to approximate Bayesian inference. Our approach consists of (1) generating synthetic MTS data through diverse Gaussian process kernels and the linear coregionalization method, and (2) a novel MTS architecture capable of utilizing both temporal and cross-channel dependencies across all input patches. We evaluate TimePFN on several benchmark datasets and demonstrate that it outperforms the existing state-of-the-art models for MTS forecasting in both zero-shot and few-shot settings. Notably, fine-tuning TimePFN with as few as 500 data points nearly matches full dataset training error, and even 50 data points yield competitive results. We also find that TimePFN exhibits strong univariate forecasting performance, attesting to its generalization ability. Overall, this work unlocks the power of synthetic data priors for MTS forecasting and facilitates strong zero- and few-shot forecasting performance.
Introduction
Predicting the future of multivariate time series (MTS)—such as electricity demand across a grid or traffic flow across a city—is notoriously difficult because real-world data is often scarce, noisy, or proprietary. While Large Language Models (LLMs) have shown that "foundation models" can generalize to new tasks without specific training, time series forecasting has lagged behind. Most existing models are either channel-independent (treating each variable separately) or require massive amounts of domain-specific data to learn how different variables interact. TimePFN addresses these gaps by leveraging synthetic data priors and a novel architecture designed for cross-channel dependency.
Methods: Synthetic Priors and Channel-Mixing
TimePFN (Prior-data Fitted Network for time series) is built on two primary pillars: a massive synthetic data engine and a specialized Transformer architecture.
LMC-Synth Data Generation
Instead of relying on scarce real-world data, TimePFN is trained on 1.5 million synthetic examples. The authors use KernelSynth to create diverse univariate patterns (trends, seasonality, noise) by composing Gaussian Process kernels. To introduce multivariate correlations, they apply a Linear Model of Coregionalization (LMC). This technique mixes independent latent functions to create correlated channels, mimicking how real-world variables (like temperature and energy use) often move together.
The TimePFN Architecture
The model enhances the PatchTST framework with two critical innovations:
- Convolutional Filtering: Before patching, the model applies 1D convolutions to extract local features and de-trend the data.
- Channel-Mixing: Unlike models that process channels in isolation, TimePFN feeds tokens from all channels into the transformer simultaneously. This allows the attention mechanism to learn how variables influence one another.
Experimental Evaluation
The model was evaluated on nine widely-used real-world benchmarks, including ETT (Electricity Transformer Temperature), Weather, Solar Energy, ECL (Electricity Consuming Load), Exchange, and Traffic.
Key Results
- Zero-Shot Supremacy: In zero-shot settings, TimePFN outperformed all baselines, including specialized univariate models like Chronos and ForecastPFN.
- Few-Shot Efficiency: With a budget of only 50 data points, TimePFN significantly outperformed DLinear and PatchTST. Fine-tuning on 500 points often matched the performance of state-of-the-art models trained on entire datasets.
- Full Dataset Performance: When fine-tuned on full datasets, TimePFN matched or exceeded the performance of iTransformer and PatchTST, proving that synthetic pre-training provides a superior starting point.
Discussion and Future Work
TimePFN demonstrates that synthetic data is a powerful prior, allowing a model to learn the "physics" of time series—trends and correlations—entirely from mathematically generated data. While the model excels in many scenarios, it currently struggles with sudden, non-periodic spikes (e.g., in Solar Energy) because the Gaussian Process prior does not explicitly model abrupt changepoints. Future work will focus on incorporating "changepoint kernels" into the synthetic generator and exploring variable input/forecasting lengths to increase flexibility for diverse business needs.
Summary updated