Calendar encoding is not a detail: swapping it shifts holiday error by up to 83% in one model
Synopsis
Time series foundation models now accept covariates, yet how calendar features are encoded has been treated as an implementation detail. Across four models and nine datasets shaped by weekends and holidays, seven calendar encodings were compared in a zero-shot rolling evaluation: encoding choice changed accuracy in every model, with within-model MASE gaps up to 9.9% on non-holidays and 83% on holidays, and the best encoding differed by model. SHAP attribution locates the gains around holidays, where signals cannot be inferred from target history.
Interpretation
How calendar covariates are encoded changes the forecast accuracy of time series foundation models rather than being a detail that can be fixed once. Encoding had been treated as an implementation detail with no systematic comparison, and current benchmarks fix a single encoding per dataset, so it was unclear whether covariate gains came from the information or from its representation. In a zero-shot rolling evaluation over four models and nine datasets, the within-model MASE gap between best and worst encoding ranged from 4.8% to 9.9% on non-holidays and from 44% to 83% on holidays.
Encoding effectiveness and how a model uses it vary by model, and no single encoding is best everywhere. Chronos-2, TabPFN-TS-3 and TiRex-2 performed best with target encodings, while TimesFM-3's best result did not come from a target encoding; TiRex-2 showed little or negative change for encodings with two or more covariates. On holiday windows, covariates improved 26 of 28 model-encoding combinations, with TiRex-2 under one-hot plus binary holiday and cyclic plus binary holiday as the only exceptions.
SHAP attribution separates the contribution of calendar covariates from the autoregressive component and explains why some model-encoding combinations degrade. Prior SHAP analysis covered only Chronos-2 and TabPFN-TS; this work extends it to TiRex-2 and TimesFM-3 and exploits the ability of foundation models to accept arbitrary context lengths, withholding feature groups directly instead of imputing absent features from background data. All models assigned substantially greater weight to calendar features on holidays than on non-holidays; TimesFM-3 weighted them more than Chronos-2 yet performed worse than its own no-covariate variant under both depicted encodings.
Perspective
The evaluation covers four time series foundation models and nine datasets from energy, transportation, traffic and water, each providing one year of hourly test data, all run zero-shot with a rolling evaluation at context length 8192 and a 24-hour horizon. The authors state that none of these datasets are in the pretraining corpora of the models used. The findings apply to forecasting tasks where the target follows calendar effects such as holidays and weekends; the authors explicitly state that no comparable benefit is expected for problems driven mainly by continuous exogenous drivers such as solar irradiance or temperature. The proposed next step is to revisit existing benchmarks by treating encoding as an explicit experimental factor and to explore data-driven encoding selection from the context.
All experiments use a context length of 8192, roughly 49 weeks at hourly resolution; the authors note that a context exceeding one year is of interest because human behavior often follows an annual cycle. All datasets are hourly, and additional resolutions would further validate the results. The authors report that a second run with context length 2048 confirms the findings. In addition, Chronos-2 and TiRex-2 remain at a MASE of about 0.30 even when the ground-truth target is supplied as a known covariate, indicating that the benefit of holiday covariates is limited not only by the information they contain but also by each model's ability to use it.
