Skip to main content

oak-forecast

The shared forecasting instrument for the OakQuant platform. Overlap-aware evaluation, baseline boards, purged walk-forward, a trials ledger, and deflation for multiple testing — with no idea what it is scoring.

pip install oak-forecast

Why it exists

Every domain on this platform that makes a dated, settleable prediction has to be judged the same way. That machinery was built inside the investments domain, because that is where the first question was asked — but it was never about equities. Measured by AST on 2026-09-16, with comments and docstrings stripped so the scan read code rather than its own explanation:

adapt/evaluate    11 files    equity identifiers: 0    equity imports: 0

Zero. Every mention of "stock" in it was prose telling the origin story. So the extraction was a move, not a rewrite, and the acceptance test said so out loud: adapt evaluate --gate0 had to produce a byte-identical report before and after — identical modulo generated_at, which a control run proved is the only leaf that differs between two runs of unchanged code.

The parts

module what it answers
corpus the settled bets, with the label window measured, not assumed
overlap effective sample size — why n is not the denominator
bootstrap date-block resampling; the interval that gets quoted
purge purged, embargoed walk-forward; the leak in a naive harness
baselines what an improvement has to beat before it is one
trials how many times we have already looked
deflate pricing that search into the significance
report the assembled answer, and the gate
host the two things the host programme supplies

The seam

⚠️ Nothing in this package may know what it is scoring, and that is enforced by a purity gauge over the whole package rather than by convention.

Two things legitimately do depend on the host: where its frozen corpus lives, and what its candidate models are. Those are registrations, not imports:

from oak_forecast.evaluate import register_fixture_provider, register_predictor_provider

register_fixture_provider(lambda: "tests/fixtures/my_corpus.json.gz")
register_predictor_provider(lambda: {"my_model": build_my_model})

A missing registration raises. It does not quietly score nothing — a purged re-score with no candidates in it exits 0 and reads exactly like "nothing to worry about", which is the shape of every silent loss this platform has shipped.

Honesty commitments

  1. Every number carries its denominator and its interval.
  2. Pre-register before searching — record(name=..., hypothesis=...) refuses a trial with no hypothesis.
  3. A null result is a deliverable.
  4. A gate that cannot say "not applicable" trains everyone to ignore it; a gate that says "not applicable" must not be read as a pass.

Apache-2.0.

Metadata

Release files for oak-forecast 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for oak-forecast 0.2.0
File Size Uploaded
oak_forecast-0.2.0.tar.gz 75.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for oak-forecast 0.2.0
File Interpreter ABI Platform
oak_forecast-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 143.8 kB

Release files / oak_forecast-0.2.0.tar.gz

Download URL oak_forecast-0.2.0.tar.gz
Size 75.1 kB
Tags Source
SHA-256 checksum
How to use checksums
e59280f85b8680e38be0903f1650a65335fcb5841224bde31c427906b666758a
BLAKE2b-256 checksum
How to use checksums
1bbd0a604209ba57e02fcadfed89d86746ec4d1dd00936816be332950342032d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / oak_forecast-0.2.0-py3-none-any.whl

Download URL oak_forecast-0.2.0-py3-none-any.whl
Size 68.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9dfdcac7c9e4dc642ce763aa0a45a27a39b434e60dd28c98b6a0289ebf86d7e0
BLAKE2b-256 checksum
How to use checksums
633977b0ca8b2f283665a22e283d93c9ee641e3eaf41ef3e5edf006b55d88601
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page