arXiv:2610.07740stat.MLOct 2026

Manuscript Offprint

arXiv:2610.07740

High-dimensional online calibration from harmonic weights

Maxwell Fishelson, Mehryar Mohri

Abstract

We study the online calibration of multidimensional forecasts over an arbitrary convex set Y⊆Rd\mathcal{Y} \subseteq \mathbb{R}^d relative to an arbitrary error norm ∥⋅∥L\|\cdot\|_{\mathcal{L}}. For forecasting dd binary outcomes simultaneously (Y=[0,1]d)(\mathcal{Y} = [0,1]^d), we give the first algorithm that achieves ε\varepsilon-calibration in a number of rounds that is polynomial in dd for every fixed accuracy. It requires dO(1/ε)d^{O(1/\varepsilon)} rounds, exponentially improving the dimension dependence of previous bounds [Per14, FKO +^+25, FGMS25]. For multiclass forecasting (Y=Δd)(\mathcal{Y} = \Delta_d), we obtain the same dO(1/ε)d^{O(1/\varepsilon)} rate, improving the dO~(1/ε2)d^{\widetilde{O}(1/\varepsilon^2)} bounds of Peng [Pen25] and Fishelson et al. [FGMS25].

Our algorithm is simple: on each round, it outputs a harmonically weighted distribution over harmonically smoothed past outcomes. The same algorithm works for every forecast set and norm. More generally, it achieves ε\varepsilon-calibration after exp⁡(O(γ(Y,L)/ε))\exp(O(\gamma(\mathcal{Y},\mathcal{L})/\varepsilon)) rounds, where γ(Y,L)\gamma(\mathcal{Y},\mathcal{L}) is a geometric parameter defined by a matrix discrepancy problem. The harmonic weights are motivated by the fact that the discrete Hilbert transform matrix achieves the optimal discrepancy up to a universal constant, simultaneously for every L\mathcal{L}. This optimality result may be of independent interest.

1 Introduction

Consider a forecaster who reports a probability of rain each day. What should it mean for these probabilities to be reliable? A natural requirement is that, among the days on which the forecaster predicts a 40% chance of rain, it should rain on approximately 40% of them. The same requirement should hold for every probability the forecaster reports. This agreement between forecasts and observed frequencies is called calibration. It gives a way to assess probabilistic predictions over time, since a single day's outcome says little about the reliability of a 40% forecast.

We study calibration in an online setting: on each round, the forecaster makes a prediction, observes the outcome, and uses this feedback to form subsequent predictions. To measure its error, group together the rounds on which it made the same prediction, compare that prediction with the empirical frequency in the group, and average the discrepancies with weights proportional to the group sizes. A forecaster is approximately calibrated when this average error is small. The online question is whether one can guarantee such agreement without assuming a stochastic model for the outcomes. Classical work on randomized forecasting shows that calibration is possible even against adversarial sequences under suitable information timing [FV98, DDF +^{+}24]. Calibration also provides a guarantee for downstream decision makers: agents who respond to calibrated forecasts have vanishing regret [FV97, Per14, KPLST23, RS24, HW24, BHNU26].

∗^{*}Institute for Advanced Study.

†^{\dagger}Google Research and Courant Institute of Mathematical Sciences, New York.

Early calibration algorithms studied the forecasting of a single binary outcome [FV98]. Many forecasting problems, however, require higher-dimensional predictions. In multi-event forecasting, a forecaster predicts several binary events concurrently: for example, whether it will rain in each of dd cities. The forecast is a vector in [0,1]d[0,1]^d, and the outcome records which cities receive rain. Calibration asks that, on rounds sharing the same entire forecast vector, the empirical frequency of each event agree with its predicted probability. We measure the discrepancy in the norm ∥⋅∥∞\|\cdot\|_\infty, which controls all dd events simultaneously.

In multi-class forecasting, the forecaster predicts a single event with dd possible outcomes: for example, assigning a probability to each possible next token in a vocabulary of size dd. Calibration compares the empirical outcome frequencies with the predicted probabilities, here in the norm ∥⋅∥1\|\cdot\|_{1}.

The central difficulty in higher-dimensional forecasting is the dependence on dimension. Standard algorithms discretize the forecast set using an ε\varepsilon-net and predict over this finite set [FV98, Per14, FKO +^{+}25]. Such a grid requires (1/ε)O(d)(1/\varepsilon)^{O(d)} points and yields algorithms with calibration rates that are exponential in dd even for fixed accuracy. This dependence is prohibitive for modern forecasting tasks with many events or classes.

Recent breakthroughs improve the dimension dependence in important settings, at the cost of a worse dependence on accuracy. Peng [Pen25] (FOCS 2025) gives a multi-class calibration algorithm that achieves ε\varepsilon-calibration in dO~(1/ε2)d^{\widetilde{O}(1/\varepsilon^2)} rounds. The TreeCal algorithm of Fishelson et al. [FGMS25] (NeurIPS 2025, oral) generalizes this approach to arbitrary convex forecast sets Y\mathcal{Y} and error norms ∥⋅∥L\|\cdot\|_{\mathcal{L}}, obtaining a sufficient horizon of exp⁡(O~(ρ/ε2))\exp(\widetilde{O}(\rho/\varepsilon^2)), where ρ\rho is a geometric parameter related to online linear optimization rates. This recovers the multi-class bound and gives a dimension-independent horizon of exp⁡(O~(1/ε2))\exp(\widetilde{O}(1/\varepsilon^2)) for Euclidean forecasting ( Y=B2d\mathcal{Y} = B_2^d). Notably, for multi-event forecasting, the resulting bound is exp⁡(O~(d/ε2))\exp(\widetilde{O}(d/\varepsilon^2)), which remains exponential in dimension. Discretization-based methods give the stronger bound (1/ε)O(d)(1/\varepsilon)^{O(d)} in this setting [Per14], but still incur exponential dimension dependence. We improve the dimension and accuracy dependence of these guarantees using a single elementary algorithm.

Our principal results concern the following distributional protocol. On round tt, the forecaster announces a finite distribution μt\mu_t over points in Y\mathcal{Y}, and the adversary chooses yt∈Yy_t \in \mathcal{Y} after seeing it. This interaction repeats for TT rounds. At its conclusion, we evaluate the calibration error by comparing each forecast p∈Yp \in \mathcal{Y} with its associated average outcome. On round tt, the forecast pp receives weight μt(p)\mu_t(p) and the outcome is yty_t, so its weighted average outcome over all rounds is

νp=∑tμt(p)yt∑tμt(p),\nu_{p}=\frac{\sum_{t}\mu_{t}(p)y_{t}}{\sum_{t}\mu_{t}(p)},

whenever its total weight is positive. For an error norm ∥⋅∥L\|\cdot\|_{\mathcal{L}} with unit ball L\mathcal{L}, the L\mathcal{L}-calibration error is

CalL,T=∑p(∑tμt(p))∥νp−p∥L=∑p∥∑tμt(p)(yt−p)∥L,\mathsf{C a l}_{\mathcal{L},T}=\sum_{p}\left(\sum_{t}\mu_{t}(p)\right)\|\nu_{p}-p\|_{\mathcal{L}}=\sum_{p}\left\|\sum_{t}\mu_{t}(p)(y_{t}-p)\right\|_{\mathcal{L}},

where the sum is over distinct forecast points with positive total weight [FGMS25]. Thus CalL,T/T\text{Cal}_{\mathcal{L},T}/T is the average calibration error. We say that an algorithm achieves ε\varepsilon-calibration in TT rounds if CalL,T/T≤ε\text{Cal}_{\mathcal{L},T}/T \leq \varepsilon for every realized transcript (μ0,y0),…,(μT−1,yT−1)(\mu_0, y_0), \ldots, (\mu_{T-1}, y_{T-1}). Our goal is to achieve ε\varepsilon-calibration in as few rounds TT as possible.

In some of the literature, this setting is called pseudo-calibration. We simply refer to it as calibration and call the setting in which the forecaster must sample a single forecast each round sampled calibration. The distributional notion is the more natural formulation, as it suffices for downstream regret guarantees. For sampled calibration, Appendix A obtains the same headline rates in expectation.

Our results. Our algorithm works for every convex forecast set Y\mathcal{Y} and error norm ∥⋅∥L\|\cdot\|_{\mathcal{L}}. We first present its guarantees in three standard forecasting settings, then describe the algorithm and state its general geometric guarantee. For multi-event forecasting, we obtain ε\varepsilon-calibration in dO(1/ε)d^{O(1/\varepsilon)} rounds. This is the first algorithm for multi-event calibration whose horizon is polynomial in dd for each fixed accuracy. For multi-class forecasting we obtain the same horizon, sharpening the accuracy dependence in the bounds of Peng [Pen25] and Fishelson et al. [FGMS25] from dO(ε−2log⁡(1/ε))d^{O(\varepsilon^{-2}\log(1/\varepsilon))} to dO(1/ε)d^{O(1/\varepsilon)}. On the Euclidean unit ball, we improve the horizon of Fishelson et al. [FGMS25] from exp⁡(O(ε−2log⁡(1/ε)))\exp(O(\varepsilon^{-2}\log(1/\varepsilon))) to exp⁡(O(1/ε))\exp(O(1/\varepsilon)), independently of dd, again improving the accuracy dependence in the exponent. Table 1 summarizes the improved rates.

Theorem 1.1 (Principal consequences). A single explicit anytime algorithm, stated formally as Algorithm 1, achieves average calibration error CalL,T/T≤ε\mathrm{Cal}_{\mathcal{L},T}/T \leq \varepsilon whenever

T≥{dO(1/ε)for multi-event forecasting(Y=[0,1]d, L=B∞d),dO(1/ε)for multi-class forecasting(Y=Δd, L=B1d),exp⁡(O(1/ε))for Euclidean forecasting(Y=L=B2d),T\geq\begin{cases}d^{O\left(1/\varepsilon\right)}&{\text{for multi-event forecasting}\left(\mathcal{Y}=[0,1]^{d},\ \mathcal{L}=B_{\infty}^{d}\right),}\\d^{O\left(1/\varepsilon\right)}&{\text{for multi-class forecasting}\left(\mathcal{Y}=\Delta_{d},\ \mathcal{L}=B_{1}^{d}\right),}\\\exp(O(1/\varepsilon))&{\text{for Euclidean forecasting}\left(\mathcal{Y}=\mathcal{L}=B_{2}^{d}\right),}\\\end{cases}

where Bqd={x∈Rd:∥x∥q≤1}B_{q}^{d} = \{x \in \mathbb{R}^{d} : \|x\|_q \leq 1\} is the unit ball of the ℓq\ell_q norm in dd dimensions.

Settingε\varepsilon-net approaches [Per14, FKO+^{+}25]High-dimensional regimeThis work
Multi-event(1/ε)O(d)(1/\varepsilon)^{O(d)}—dO(1/ε)d^{O(1/\varepsilon)}
Multi-class(1/ε)O(d)(1/\varepsilon)^{O(d)}dO(ε−2log⁡(1/ε))d^{O(\varepsilon^{-2}\log(1/\varepsilon))} [Pen25, FGMS25]dO(1/ε)d^{O(1/\varepsilon)}
Euclidean(1/ε)O(d)(1/\varepsilon)^{O(d)}exp⁡(O(ε−2log⁡(1/ε)))\exp(O(\varepsilon^{-2}\log(1/\varepsilon))) [FGMS25]exp⁡(O(1/ε))\exp(O(1/\varepsilon))

Table 1: Rounds sufficient to achieve ε\varepsilon-calibration in the three forecasting settings of Theorem 1.1.

An elementary algorithm. The algorithm has two operations. As it observes outcomes y0,…,yty_{0}, \dots, y_{t}, it stores harmonically weighted average outcomes p0,…,ptp_{0}, \dots, p_{t}. At each round, it outputs a harmonically weighted distribution over previously stored forecasts. Both operations use weights that decay inversely with age, as in 1,13,15,…,12t+11, \frac{1}{3}, \frac{1}{5}, \dots, \frac{1}{2t+1}, normalized to sum to 11.1^{1}

On the first round, we choose pinit∈Yp_{\mathrm{init}} \in \mathcal{Y} and announce μ0=δpinit\mu_{0} = \delta_{p_{\mathrm{init}}}. For subsequent rounds t≥1t \ge 1, we first compute and store a harmonically weighted average of the past outcomes:

pt−1∝∑s≤t−1ys2(t−s)−1.p_{t-1} \propto \sum_{s \le t-1} \frac{y_s}{2(t-s)-1}.

Here ∝\propto means that the sum is normalized by its total weight, 1+13+⋯+12t−11 + \frac{1}{3} + \dots + \frac{1}{2t-1}. Thus pt−1∈Yp_{t-1} \in \mathcal{Y}. We then construct our output μt\mu_t for the round as a distribution supported on the stored forecasts p0,…,pt−1p_0, \dots, p_{t-1}. Let δps\delta_{p_s} denote the Dirac distribution that puts all its mass on psp_s. Using the same harmonically decaying weights, we set

μt∝∑s≤t−1δps2(t−s)−1.\mu_t \propto \sum_{s \le t-1} \frac{\delta_{p_s}}{2(t-s)-1}.

Algorithm 1 gives the formal statement. The procedure is independent of the norm, the horizon, and the target accuracy.

1^{1}Alternatively, one could use weights 1,12,13,…,1t1, \frac{1}{2}, \frac{1}{3}, \dots, \frac{1}{t}. The shift to odd denominators is convenient for the discrete Hilbert transform analysis; both choices give the same rates.

A general geometric guarantee. In fact, the same algorithm admits a general singly exponential horizon bound governed by a matrix discrepancy objective. For nonempty compact convex sets A,B⊆Rd\mathcal{A}, \mathcal{B} \subseteq \mathbb{R}^d and a real T×TT \times T matrix HH, define

ΓA,B(T)(H)=sup⁡a0,…,aT−1∈Ab0,…,bT−1∈B∑t,s=0T−1Hts⟨at,bs⟩.(1)\Gamma_{\mathcal{A},\mathcal{B}}^{(T)}(H)=\sup_{\substack{a_{0},\ldots,a_{T-1}\in\mathcal{A}\\ b_{0},\ldots,b_{T-1}\in\mathcal{B}}}\sum_{t,s=0}^{T-1}H_{ts}\langle a_{t},b_{s}\rangle. \tag{1}

This objective relates to our calibration rates as follows. Let cyc_{y} be the center of mass of Y\mathcal{Y}, and define

Y~=Y−cY.\widetilde{\mathcal{Y}}=\mathcal{Y}-c_{\mathcal{Y}}.

Let L∘\mathcal{L}^{\circ} be the polar of the norm ball L\mathcal{L}:

L∘={r∈Rd:⟨ℓ,r⟩≤1 for every ℓ∈L}.\mathcal{L}^{\circ}=\{r\in\mathbb{R}^{d}:\langle\ell,r\rangle\leq1\mathrm{~f o r~e v e r y~}\ell\in\mathcal{L}\}.

Let KTK_{T} be the shifted discrete Hilbert transform matrix:

(KT)ts=12(t−s)−1(0≤t,s<T).(2)(K_{T})_{t s}=\frac{1}{2(t-s)-1}\qquad(0\leq t,s<T). \tag{2}

The quantity ΓY~,L∘(T)(KT)\Gamma_{\widetilde{\mathcal{Y}},\mathcal{L}^{\circ}}^{(T)}(K_T) governs our calibration rates. As we will see in Section 3, ΓY~,L∘(T)(KT)=OY,L(T)\Gamma_{\widetilde{\mathcal{Y}},\mathcal{L}^{\circ}}^{(T)}(K_T) = O_{\mathcal{Y},\mathcal{L}}(T) for every forecast set Y\mathcal{Y} and norm ball L\mathcal{L}. Thus we define the geometric coefficient

γ(Y,L)=sup⁡T≥1ΓY~,L∘(T)(KT)T.(3)\gamma(\mathcal{Y},\mathcal{L})=\sup_{T\geq1}\frac{\Gamma_{\widetilde{\mathcal{Y}},\mathcal{L}^{\circ}}^{(T)}(K_{T})}{T}. \tag{3}

Our main algorithm obtains the following guarantee.

Theorem 1.2 (General geometric guarantee). Let L\mathcal{L} be any norm unit ball, let Y\mathcal{Y} be a nonempty compact convex forecast set. For an absolute constant CC, Algorithm 1 achieves ε\varepsilon-calibration for every

T≥exp⁡(Cγ(Y,L)ε).T\geq\exp\left(\frac{C\gamma(\mathcal{Y},\mathcal{L})}{\varepsilon}\right).

Why harmonic weights? In Section 2, we consider a generalized version of our algorithm with arbitrary admissible weights encoded by a matrix HH. Its calibration bound is governed by ΓY~,L∘(T)(H)\Gamma_{\widetilde{\mathcal{Y}},\mathcal{L}^{\circ}}^{(T)}(H), so we seek weights that minimize this objective.

Section 4 proves that, for sets A,B\mathcal{A}, \mathcal{B} with 0∈A0 \in \mathcal{A} and B=−B\mathcal{B} = -\mathcal{B}, KTK_T minimizes ΓA,B(T)\Gamma_{\mathcal{A}, \mathcal{B}}^{(T)} up to an absolute constant factor over our class of matrices HT\mathcal{H}_T:

ΓA,B(T)(KT)≤Cmin⁡H∈HTΓA,B(T)(H).\Gamma_{\mathcal{A},\mathcal{B}}^{(T)}(K_{T})\leq C\min_{H\in\mathcal{H}_{T}}\Gamma_{\mathcal{A},\mathcal{B}}^{(T)}(H).

The class HT\mathcal{H}_{T} consists of matrices with nonnegative entries below the diagonal, nonpositive entries on and above the diagonal, and the same total absolute mass as KTK_{T}. We defer the precise definition to Section 4.

Section 3 explains why this choice gives sublinear calibration, with polynomial dimension dependence for many classes of interest. Our core tool is the following bound, proved in Lemma 3.2.

Lemma 1.3 (Finite Hilbert matrix moment bounds). There is an absolute constant CC such that, for every T≥1T \geq 1, every q∈{2,4,8,…}q \in \{2, 4, 8, \ldots\}, and every x∈RTx \in \mathbb{R}^T,

∥KTx∥q≤Cq∥x∥q.\|K_{T}x\|_{q}\leq C q\|x\|_{q}.

Human acknowledgements. The authors thank Jon Schneider and Yuval Dagan for many helpful discussions throughout this work.

AI acknowledgements. The authors utilized Gemini, ChatGPT, and Claude to assist with proving various lemmas and the creation of this manuscript. However, despite the simplicity of the main algorithm, finding such an algorithm was outside of the one-shot capabilities of the current best commercially available models. Here are two experiments demonstrating that GPT-6 Astra Ultra and Claude Fable 5.1 Max are unable to resolve even a simplified version of the problem (orthant calibration) given a massive in-depth prompt detailing all the relevant past work and algorithmic ideas known.

• Prompt: https://maxkfish.com/wp-content/uploads/2026/10/prompt.txt

• GPT: https://chatgpt.com/share/6ac4672a-5968-83e8-8b96-25e4ad40b3ab

• Fable: https://claude.ai/share/2ec24e46-ee20-4cbd-b682-1fee29989d2c

A more detailed account of AI usage will be provided in a future version of the manuscript. We will discuss the algorithmic insights we had that helped us steer our AI usage over the course of 2 years of work.

References (47)