Research

Customising time series foundational models (TSFMs)

VIDUSHI AGARWAL AND ANGIE ZHANG

Out of the box, Chronos-2 beat a retailer's statistical baseline by ~6 percentage points of wMAPE. Fine-tuning with covariates added another 2–3 points. This is how we did it, and where foundation models still fall short.

Introduction

Every retail and CPG enterprise we have spoken to face the same problem: their current forecasting systems are manual, fragmented and forecast improvements are capped due to sparse historical data and volatile demand shocks.

One of our customers faced exactly this challenge. With only a year of reliable history per SKU, their traditional ML forecasting system had reached a ceiling on accuracy.

We replaced their traditional forecasting model with Chronos-2, an agentic, transformer-based model and fine-tuned it on the retailer’s proprietary demand data and operational context. This blog post covers why we chose the Chronos-2 model, our process for fine-tuning and the uplift we achieved in forecast accuracy.

The five walls every retail and CPG forecasting team hits

Most retail, e-commerce and CPG forecasting stacks are built with the same traditional forecasting method: a statistical model with hand-tuned multipliers layered on top to embed additional demand signals that the model can’t capture (e.g., weekend bumps, holiday spikes).

Five structural problems underlie this statistical approach, causing forecast improvements to plateau.

  1. Sparse data: Sparse historical data restricts the model's ability to learn robust demand patterns

  2. Cold starts: New or recently launched SKUs have don’t have any historical data for the model to learn from

  3. SKUs with different sales volumes: Approximately 80% of SKUs carry 20% of demand. Tuning the model based on the average gets the forecast wrong for both the head and tail SKUs

  4. Inability to scale: Hand-tuning multipliers for each demand driver (e.g., promotions, celebrations) is manual, difficult to maintain and impossible to scale

  5. Fragmentation: Forecasts remain siloed across the planning value chain, limiting shared learning and ability to dynamically respond to demand shocks

We saw these problems first-hand at our customer. They used a traditional statistical forecast model, with hand-tuned multipliers layered on top, including seasonal effects and promotional events. Their stalling forecast accuracy improvement was orthogonal to their model choice. The only solution was changing the starting point.

Leveraging a pre-trained foundation model as the starting point

To break through the five walls, we shifted the starting point from a statistical model to a pre-trained time-series foundation model.

A useful analogy is to compare is to compare this model to a Large Language Model such as Claude or ChatGPT. These pre-trained models already know how to generate text, emails and respond to questions before it has even seen your company’s documents. Similarly, a pre-trained time-series model (e.g., Google’s TimesFM2.5, TimeGPT, and Amazon’s Chronos 2) studies demand patterns across industries to understand the general shape of demand before it has seen a single one of your SKUs.

We selected Chronos-2 as our foundational model due to its rich library of covariates, multivariate inference and cross-series capabilities.

Diving into Chronos-2 architecture

Chronos-2 is a pre-trained 120-million parameter, encoder-only transformer model built on the T5 architecture. It is pre-trained on billions of real-world and synthetic time series data across different industries e.g. retail, energy, web and search trends, weather, transport and finance.

The breadth of the pre-training is what lets the model to forecast a new SKU with little or no history, learning from time-series priors (e.g., momentum, seasonality). Instead of relying on manually tuned multipliers, the foundation model natively supports covariates, enabling fine-tuning to learn how demand responds to specific demand drivers. The small size of the 120M parameter model means that it is cost-efficient to iterate and run.

The forecast is produced in three stages:

  1. Scale and Tokenize: First, the historical target series (e.g., sales) and any known covariates (e.g., price, promotions, or holidays) are scaled and tokenized. Scaling removes differences in magnitude (e.g., the model reads 1, 2, 1 the same way it reads 5, 10, 5). This way, the model learns patterns rather than absolute values. Patching groups consecutive timesteps into tokens allows for efficient processing by the transformer.

  2. Attention mechanisms: The transformer model then alternates between two complementary attention mechanisms. Time attention learns temporal dependencies within a single series, capturing trends, seasonality, momentum, and lag effects from a product's own history. Group attention learns across related time series, enabling similar SKUs to share information and improving performance on sparse, low-volume, or newly launched products.

  3. Quantile heads and unscale: Finally, the model predicts a distribution of future demand using quantile heads, producing multiple confidence intervals rather than a single point estimate. These predictions are then transformed back to the original scale, providing forecasts in real-world units together with an estimate of uncertainty.

Immediate forecast improvement using the Chronos-2 model

A key capability of foundation models is in-context learning, the ability to perform new tasks at inference time without additional training. The model answers from the priors in pre-training.

Zero-shot refers to the model making predictions using only patterns learned during pre-training, with no visibility into the target dataset. This enables immediate forecasting for new products or time series without additional training.

Few-shot refers to providing the model with a small set of examples from the target dataset). This lightweight adaptation improves accuracy while requiring far less data and training than traditional machine learning approaches.

We ran a series of few-shot experiments to evaluate Chronos-2. Out of the box, with none of the customer’s proprietary data, Chronos-2 already cleared their baseline statistical model by ~6 percentage points of overall wMAPE. A few targeted few-shot adaptations further closed the gap. Few-shot Chronos-2 reached parity with the best in-house tuned model, with zero supervised training.

Fine-tuning Chronos-2 for additional uplift

While Chronos-2 can get you to your best statistical model’s accuracy with no training, fine-tuning drives further performance gains. It does this by encoding an enterprise’s specific context and business objectives through alternations in the model weights. There are three key levers involved in fine-tuning the Chronos-2 model:

  1. Adding covariates to replace the hand-tuned multiplier

  2. Sampling to correct for a tail-heavy scale-invariant world

  3. Creating a loss-function to align with the business objective

Lever 1: Integrating covariates to replace the hand-tuned multiplier

Foundation models can only extrapolate patterns they observe from historical demand. Covariates extend this capability by providing known future signals. During fine-tuning, the model learns how demand responds to each covariate, allowing it to project these relationships into the forecast horizon.

The challenge is determining which covariates should be explicitly provided to the model and which it can infer from historical demand.

One practical measure of covariate usefulness is the Pearson correlation coefficient between sales and the covariate. Higher correlation generally indicates greater predictive value.

Our experiments identified four key covariates that were useful to incorporate into the Chronos-2 model:

  • Temporal: We found that the model could already infer temporal trends from the target series. However, calendar semantics such as weekends and specific dates needed to be provided explicitly.

  • Seasonality: We experimented with explicit calendar features (e.g., payday) which improved the model's ability to capture demand spikes. Weekend indicators provided smaller gains because weekly seasonality was already largely encoded in pre-training.

  • One-off regimes: These remained difficult to predict even with covariates due to the limited signal per series. We tried oversampling the regime-specific verticals which helped a little.

  • Business interventions: We experimented with price changes, promotions, and planned marketing events as covariates.

Adding these covariates during fine-tuning enabled the model to better capture demand inflection points than the no-covariate baseline, improving wMAPE by 2–3 percentage points.

Lever 2: Optimize Sampling strategy to correct for tail-heavy SKUs

One of the biggest challenges when forecasting with Chronos-2 is that the model normalizes each time series to learn the shape of demand rather than its absolute scale. Because retail demand is highly tail-heavy, roughly 80% of SKUs account for only 20% of demand, training batches become dominated by sparse, low-volume products. As a result, the model spends much of its capacity learning flat or intermittent demand patterns, leading to systematic under-forecasting.

To address this imbalance, we biased training batches toward higher-demand products while still maintaining representation from the long tail. We evaluated 2 sampling strategies

  • Demand weighted sampling: Series are sampled with probability proportional to demand, using a temperature parameter to control how strongly high-demand SKUs are prioritized.

  • Stratified sampling: SKUs are divided into head, torso, and tail demand buckets, with each bucket sampled at approximately equal probability.

Both methods performed similarly, suggesting that the primary benefit comes from reducing tail overrepresentation rather than the precise weighting scheme.

One of the key benefits of the transformer architecture is its ability to learn relationships across related time series in the same batch. Grouping correlated SKUs, such as products in the same vertical, demand tier, or seasonal regime, allows the model to transfer information between them, improving forecasts for cold-start products or products with limited historical data.

Lever 3: Create Custom loss function to align with the business objective

Chronos is pre-trained using the pinball (quantile) loss, which predicts an entire demand distribution, rather than a single median forecast. By producing multiple confidence intervals simultaneously (e.g. P50, P90), the model can naturally balance the trade-off between over- and under-forecasting.

This allowed us to create a custom loss function that aligned with the downstream business objective. This lever produced one of the most effective improvements during fine-tuning.

  • Calibrating inventory risk: Inventory planning is asymmetric where under-forecasting is often more costly to the business than over-forecasting due to lost sales. Rather than using the median prediction (P50), we can calibrate the loss function to optimize under-bias with minimal impact on overall accuracy.

  • Optimizing for the planning window: Not every day in the forecast horizon should be treated equally (e.g., certain weeks in the month drive replenishment decisions). Instead of minimizing daily error across the full 28-day horizon, we optimized the loss directly on the key replenishment week, aligning with the downstream planning decision.

Putting the fine-tuned model into production

Campfire is Hyde’s training platform for time-series foundation models. It makes this fine-tuning process practical to run as a production system rather than a one-off research exercise. The platform allows for the orchestration, checkpointing, and infrastructure work to be conducted easily. On top of that, Hyde's forward-deployed engineers work directly with a team's data to set up the training recipe, the sampling strategy, the optimizations, and the evaluation harness, and to stand up inference.

For our customer, we imposed two production pipelines, fine-tuned on Hyde’s Campfire platform. They both fine-tune for 3-5 epochs with e-5 order of learning rate from a Chronos-2 base checkpoint, and both run on sovereign GPUs with train-serve parity by construction: the same feature code, covariates, context length, and grouping at training and at serving.

Hyde’s fine-tuned Chronos-2 model delivered significant forecast accuracy improvements on the best-performing statistical model. In 6 weeks, our Forward Deployed Engineers improved wMAPE by a significant percentage.

Limitations and future work

Our deployment surfaced several areas where foundation models still have significant room to improve for forecasting.

  • No pathway for static metadata — In the current transformer architecture, every input dimension is a time series, with no native slot for time-invariant vector like product or store attributes. Cross-attention enables signal sharing across SKUs, but this cross-learning is constrained by the manually curated batch composition.

  • Learning one-off regimes: While oversampling improved performance modestly, reliably learning these rare, high-impact demand events remains an open problem due to data limitations.

  • Repairing leaky covariates: Synthetic gap-filling could remove the leakage from missing pricing data, but only if it preserves the true relationship between price and demand.

  • Reconciling planning horizons: Reconciling forecasts at different levels of granularity to ensure reconciliation remains an open modelling challenge.

  • Optimizing for operational outcomes: Fine-tuning minimizes forecast error, while the business cares about service levels, stock-outs, and holding costs. A cost-aware or reinforcement-learning objective could optimize against delayed operational rewards rather than the forecasting metrics that merely approximate them.

Beyond retail and CPG

None of the three fine-tuning levers above are retail-specific: they're the general shape of adapting a pre-trained time-series foundation model to any domain with sparse, skewed, regime-sensitive series. Some examples include:

  • Energy and utilities: grid or feeder-level load forecasting

  • B2B SaaS: usage forecasting

  • Workforce and staffing: store- or site-level staffing forecasts

The same recipe applies wherever a business has many related time series and the same five walls. The pre-trained backbone already knows what demand-like series generally look like. Fine-tuning with the right covariates, the right sampling, and a loss that matches the actual business objective provides additional uplift.

Read the blog

COMPLIANCE

Talk to an engineer

© 2026 Hyde Inc. All rights reserved.

Site

Company

Connect

Read the blog

COMPLIANCE

© 2026 Hyde Inc. All rights reserved.

Site

Company

Connect

Talk to an engineer