Skip to content

FormalSLT v0.3.0

Latest

Choose a tag to compare

@Robby955 Robby955 released this 27 Nov 19:42
Immutable release. Only release title and notes can be modified.
a696062

Two predictors have been scored on the same stream. At each reporting time,
you select the one with the smaller observed loss. How large could its
average conditional loss have been over that prefix?

FormalSLT answers this question with a bound that holds on one event across
all positive reporting times. The example below uses a uniform prior over
the two predeclared predictors. Selecting one after seeing the scores incurs
a model-selection term of log 2. The public Brier replay uses the same
half-tilt trajectory theorem with a fixed confidence level and recorded
predictions.

Use the theorem from another Lean package

The downstream example
imports FormalSLT.StochasticDynamics and proves
Downstream.SelectedPredictor.selectedRiskBound. It compares the two
empirical mean losses and specializes the general result to the chosen
predictor. The bound uses its observed loss, an observable quadratic-variation
term, the selection cost, and the confidence level.

Run the example from a checkout of this version with Lean 4.32.2:

make downstream

This builds a separate Lake package against the checkout. The theorem assumes
bounded scores in [0, 1], a finite state space, a specified initial state,
and a sequence of transition kernels that may depend on the observed history.
Its risk is the average of the selected predictor’s one-step conditional
losses along the prefix. A guarantee about future predictions or stationary
risk requires additional assumptions.

Replay the occupancy Brier bound

From the repository root:

lake exe cache get
make replay-uci357-brier

The target reads the tracked protocol, prediction CSV, and certificate.
The verifier recomputes the summaries for the 8,224 monitored observations
and invokes Lean on the certificate arithmetic. The all-sensor logistic
predictor has lower observed Brier loss (about 0.061198) than the
training-prevalence baseline (about 0.165322). The checked upper bound on
the selected predictor’s conditional prefix risk at 95% confidence is
18317/250000 = 0.073268.

The forecast reconstruction is retrospective. The statistical interpretation
requires both candidates’ forecasts to be available before each corresponding
outcome. The archived occupancy data do not establish historical label timing.
The replay instructions
give the expected verifier output and distinguish replaying the shipped
predictions from refitting the models.

Other additions since v0.2.0

  • Predictable-strategy PAC-Bayes bounds allow model and strategy posteriors
    to be chosen after observation and account for each choice separately.
    Model and strategy theorem
  • A computable countable betting mixture evaluates the active experts and a
    closed-form tail at each step.
    Sleeping-expert construction
  • The Brier monitor also supports replay of a Good Judgment Project forecasting
    example and verification of chronological tabular prediction streams.
    Application and CLI

Lean and Mathlib remain pinned to 4.32.2. The four supported topic imports
and the 19 declarations in the v0.2 signature snapshot carry forward.
The API policy describes the scope of patch-level
compatibility. Use the citation metadata when citing
this version and the release checklist for
tag verification and archival packaging.

Release verification

  • Merge commit a696062472c60e9e2c923197892460bf91166bdf
  • Git tree 53afbf1c98d3373b2300a157d00fb5ab992ac1dd
  • Annotated tag object 77d9d5badd8302b110ee690207be4fd2e2f1a3cc

The attached source and documentation archives, release manifest and SHA-256 checksums are from the verified tag workflow. Both Linux and macOS installed the tagged library and built the downstream examples.

The workflow used a single-worker documentation build and checked out the release commit above for installation, documentation, and packaging.