Add cheap generic Tuner through S24 - #6
Merged
Merged
Conversation
Complete S20-S24 with fail-closed TunableRegistry validation, allocation-free champion/challenger selection, Welford evidence, explicit baseline-only/reset mode, context/crossover champions and versioned provenance persistence.
Valessc2
marked this pull request as ready for review
August 18, 2026 23:04
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Scope
Completes the S20-S24 Tuner package on top of current S19
mainwithout moving bot semantics or framework types into SC2AIOptimize.S20 — net benefit
Existing baseline/OFF gate remains candidate zero and continues to require correctness-qualified total-cost evidence.
S21 — TunableRegistry
Adds fail-closed registry validation plus ID/name lookup. Invalid specs and duplicate IDs/names are rejected. Consumer code still owns meaning, storage and safety.
S22 — champion/challenger
Adds allocation-free Welford running statistics, current-champion vs challenger evaluation, explicit
BaselineOnlymode, deterministic reset/evidence reset and conservative confidence separation. Invalid policies/evidence fail closed.S23 — context/crossover
Adds compact numeric workload/hardware/state context lookup and ordered workload-size crossover bands. Unknown/invalid contexts or bands fall back to baseline by default.
S24 — persistence/provenance
Adds a strict versioned standard-library persistence record carrying source revision, SC2 build/data version, compiler, hardware and workload profile identity. Persistence is control-plane/I/O work and deliberately not part of the hot path.
Cheapness
Validation
The exact S20-S24 implementation was built locally under GCC 14.2 with
-Wall -Wextra -Wpedantic -Werror; the standalone tuner test suite passed 1/1. Full repository Linux/Windows CI on this PR is the cross-platform build/test proof.Not claimed
This does not claim target-hardware speedups, calibrated crossover values, bot integration, ladder evidence or V1 certification. Those remain S25-S32 work.