fix(mrl): bind training lineage construction identity - #305
Conversation
|
ⓘ Qodo reviews are paused because your trial has ended. Ask your workspace admin to add credits to resume reviews. Manage billing |
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Superseded by canonical main. The construction-bound |
Summary
Harden canonical MRL-0601
TrainingExampleLineageContractso an existing lineage remains bound to the exactTrainingExampleV1identity present at lineage construction.The canonical contract previously rebuilt its current
examplefor every public view but preserved no construction identity. A post-construction mutation to a different syntactically valid training example could therefore turn one lineage object into a different valid lineage instead of failing closed. Downstream MRL-0602/MRL-0603 checks that rebuiltlineage.exampleand compared that rebuilt identity tolineage.content_sha256could compare two values derived from the same mutated state and therefore fail to detect the drift.Repair
TrainingExampleLineageContractweak-referenceable without adding caller-supplied dataclass fieldsTrainingExampleV1before every public lineage trust/semantic/hash viewRegression coverage
source_sha256to another valid SHA fails closed before semantic, training-example identity, or content-hash outputCanonical base
bf92dd2977d24aa597d2442decabc215f7bd3dbfExact candidate head
a77eef842e4523d1e90ade99839703773b724843Live compare:
behind_by=0, 2 commits ahead, exactly two intended files:src/medscale/mesc/_mrl_training_example_lineage_v1.pytests/test_mesc_mrl_training_example_lineage_v1.pyCurrent exact-head qualification blocker
Fresh automatic workflows terminate before any workflow step executes:
3330188699499231473372:failure,steps=null99231473464:failure,steps=null3330188695499231472978:failure,steps=nullThese are external pre-execution hosted-runner blocker results only. They are not Ruff, formatting, strict mypy, pytest/coverage, MRL machine-state,
medscale check, or CodeQL-analysis results and do not authorize merge.Downstream reconciliation
PR #299 (MRL-0602/MRL-0603/MRL-0605 hardening) must be reconciled after this MRL-0601 hardening becomes canonical so its contamination/transformation builders validate the original construction-bound lineage instead of rebuilding current lineage state and comparing it to another identity derived from that same live state.
PR #295 (MRL-0604/MRL-0606 feature work) remains downstream of that reconciliation and cannot reuse qualification evidence from a pre-reconciliation head.
Boundary
This is fail-closed lineage-metadata integrity hardening only. It reads no source bytes or corpora, accesses no model/provider/network/GPU/runtime, executes no generation or training, and grants no source/data access, training, promotion, deployment, release, or clinical authority.
Fresh exact-head Python 3.11/3.12 CI, Ruff lint/format, strict mypy, full pytest/coverage, MRL machine-state,
medscale check, CodeQL/security qualification, exact intended scope,behind_by=0, mergeability, and zero unresolved material review findings/threads remain required before guarded merge. No force-push, rebase, destructive history rewrite, CI/CodeQL weakening, governance bypass, provider spend, or real-asset access is used.