You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(conformal): add adaptive conformal methods and finite-sample correction #89
today ConformalIntervals (foundationforecast/core/conformal.py) has two methods: conformal_error (quantiles of absolute calibration errors per horizon step) and conformal_distribution (point forecast ± an empirical distribution of calibration errors). both use a fixed set of n_windows and no finite-sample correction; we kept the first release simple.
ask: add as new method values (or a follow-up class if the state doesn't fit):
finite-sample corrected quantile level, ceil((n + 1) * level) / n, so coverage holds with few windows (usually n_windows is small).
adaptive conformal (ACI, Gibbs & Candès 2021): update the miscoverage level online so coverage tracks drift.
open: how to carry the adaptive state across forecast calls, since the api is stateless today.
tests: extend the parametrized tests/models/test_models.py so every model runs the new methods. docs: describe each method, plus an empirical coverage check (e.g. rolling-origin on m4 hourly) so we back the claims.
Hi @AzulGarza! Now that #92 is merged and PID / ConformalMethod are available, I’d like to clarify the intended scope for the remaining ACI work in #89.
I see two possible approaches:
Stateless replay, following PID’s current design: Add ACI(ConformalMethod) and reconstruct the adaptive miscoverage state from the chronological calibration windows on each forecast() call. Track alpha separately per series, horizon step and requested level, respecting feedback availability when step_size < h. This would fit the existing ConformalIntervals(method=...) API.
A persistent online session: Introduce an explicit object that retains adaptive state and pending forecasts across calls, with an update(observations) operation when actuals arrive. This would also require defining reset/serialization behavior and handling delayed or duplicate observations.
My preference would be to start with replay-based ACI, consistent with PID, and document clearly that restarting calibration on each call does not preserve a continuous ACI trajectory or automatically inherit its long-run coverage guarantee.
hey @viventriglia! agreed, 1 is more coherent with the design we already have for PID. yeah, i see the limitation of not having the long-run coverage guarantee, but getting it would take more work and more design, as you mentioned. let's do 1. let me know how we can help!
Activity
viventriglia commentedon Nov 19, 2026
Hi @AzulGarza! Now that #92 is merged and
PID/ConformalMethodare available, I’d like to clarify the intended scope for the remaining ACI work in #89.I see two possible approaches:
ACI(ConformalMethod)and reconstruct the adaptive miscoverage state from the chronological calibration windows on eachforecast()call. Trackalphaseparately per series, horizon step and requested level, respecting feedback availability whenstep_size < h. This would fit the existingConformalIntervals(method=...)API.update(observations)operation when actuals arrive. This would also require defining reset/serialization behavior and handling delayed or duplicate observations.My preference would be to start with replay-based ACI, consistent with PID, and document clearly that restarting calibration on each call does not preserve a continuous ACI trajectory or automatically inherit its long-run coverage guarantee.
AzulGarza commentedon Nov 19, 2026
hey @viventriglia! agreed, 1 is more coherent with the design we already have for PID. yeah, i see the limitation of not having the long-run coverage guarantee, but getting it would take more work and more design, as you mentioned. let's do 1. let me know how we can help!