- scoring.py: shared real compression-score formula (mirrors the exact
validator formula, same one used in real_validator_score_test.py) so
every part of the CMS scores consistently instead of each view
reimplementing it.
- db.py: added score column (+ migration for the pre-existing DB), an
alerts table, a calibration_runs table, sortable/filterable item
queries, score-trend and rate-distortion query helpers.
- cq_health.py: parses the live CQ tables directly from app.py's source
and cross-references them against real calibration evidence, flagging
which tiers are backed by data vs. still guesses. Caught and fixed a
real bug while building this: calibration evidence wasn't filtered by
encoder_mode, so NVENC AV1 data was silently getting attributed to the
SVT-AV1 table (different CQ/CRF curve entirely) and vice versa. Also
normalized all scores to the real vmaf_threshold rather than trusting
stored score_est, which for search-log rows is computed against an
inf…