﻿# Chronos output migration: sample paths, quantile axes and the point forecast contract

Migrate a Chronos consumer by checking sample-versus-quantile outputs, axis order and the actual mean or median returned by the selected pipeline.

Author: Retrivium editorial team
Updated: 2026-11-04
Canonical URL: https://retrivium.ai/journal/fg2-chronos-samples-quantile-axis-point-forecast-contract/
Language: en

## Inspect meaning before accepting a compatible shape

A forecasting consumer can receive a tensor with a batch dimension, an uncertainty dimension and a horizon dimension from different Chronos families. Similar shapes conceal different meanings. The [project overview](https://raw.githubusercontent.com/amazon-science/chronos-forecasting/main/README.md) distinguishes sampled forecasts from direct quantile forecasts. A migration should identify the selected pipeline and method before reusing plotting or aggregation code. Otherwise, an application can silently interpret named quantiles as exchangeable samples.

## Follow the original sample path

In the [original Chronos implementation](https://raw.githubusercontent.com/amazon-science/chronos-forecasting/main/src/chronos/chronos.py), prediction produces sampled trajectories. Its quantile helper rearranges these outputs, calculates empirical quantiles over samples and computes a sample mean for its point forecast. The number of sampled trajectories affects that empirical approximation. Averaging over the horizon instead would summarize future times rather than uncertainty at each future time, yielding a plausible scalar with the wrong interpretation.

## Read the quantile-family helper literally

The [Chronos-Bolt implementation](https://raw.githubusercontent.com/amazon-science/chronos-forecasting/main/src/chronos/chronos_bolt.py) directly predicts a quantile grid. Its helper swaps quantile and time axes and returns the median in the point-forecast position named mean. This implementation detail matters for a skewed forecast distribution. Treating every second return value as an expectation can change an application decision even when the integration runs without errors. Pin the library revision because a variable name is not a permanent statistical contract.

## Keep quantile labels with the values

Store requested levels, axis meaning and time coordinates alongside forecast arrays. Interpolation between supported levels is different from sampling additional trajectories, and requesting a more extreme level does not establish calibrated tail behavior. The [artifact-manifest guide](/journal/tokenizer-artifact-release-manifest/) provides a related release-control pattern: weights, consumer assumptions and preprocessing belong to one reproducible interface. Do not infer distribution semantics from the file name alone.

## Validate downstream decisions with a skewed fixture

Use a deliberately asymmetric sample fixture to distinguish mean from median, and verify a known quantile column after every axis conversion. Compare the selected statistic with the application's documented decision rule. The [output transformation guide](/journal/fg2-promptfoo-output-transform-hierarchy-measured-artifact/) offers related boundary reasoning. An adapter passes when it preserves the intended statistic and coordinates, rather than merely producing the expected dimensions or a smooth chart that hides a semantic migration error.
