Patching groups adjacent time-series points into fixed-length, usually nonoverlapping segments; each segment becomes one token for an embedding layer or transformer. Grouping preserves local relationships while reducing the token count, making forecasting models lighter and faster. section 6.1.1 section 7.1.1
Apply patching by making three architectural choices:
- Choose a patch length suited to the series frequency; Moirai uses length 8 for yearly and quarterly data, while minute-level data uses 32, 64, or 128. section 6.1.1
- Replace individual time-step tokens with grouped tokens so each token carries information from multiple neighboring observations. section 6.1.1
- Balance specialization against simplicity: frequency-specific lengths require multiple embedding layers, whereas Moirai-MoE uses one fixed length and one input projection. section 6.2.1
Forecasting 256 future steps with TimesFM
With 32-step input patches and 128-step output patches, TimesFM needs two autoregressive steps to forecast 256 future steps; matching the output to the input length would require eight. section 7.1.1
Figure 6.2 The process of patching. Typically, each data point (circle) is a token that’s sent to the embedding layer. With patching, we group data points, and each patch becomes a token that is sent to the embedding layer.
Compare individual-point tokenization with grouped patches: each patch becomes one token sent to the embedding layer. section 6.1.1
