TopoPrimer: The Missing Topological Context in Forecasting Models
Abstract
Most time series foundation models (TSFMs) forecast each series predominantly from its own temporal history, or via implicit cross-attention over co-located series in context. Whether supplying explicit, domain-wide population structure improves TSFM performance remains largely unexplored. Would a series' relative position within the population, or the population’s overall global shape, prove more informative? We introduce TopoPrimer, a framework that provides the global topological structure of the series population as an explicit input to forecasting backbones. TopoPrimer leverages both aspects using two frozen encodings precomputed once per domain: a spectral relational coordinate locating each series within the population, and a persistent-homology fingerprint capturing the population's global topological structure. Both are injected per-token for fully-trained models or through a lightweight adapter for pre-trained backbones. While the relational coordinate drives accuracy when historical data is available, the fingerprint excels in data-scarce regimes. Across four public benchmarks, TopoPrimer improves accuracy on topologically rich domains (up to 7.4\% MSE gains) and outperforms full fine-tuning on Chronos using under 1\% of trainable parameters. On an internal corpus, the fingerprint reduces peak-demand error by 9 to 15\% against the base Transformer, and improves cold-start MAE by 13\% at launch and up to 19\% in subsequent weeks.