Repository navigation
Description
Scientific / DDD finding
The Draft longitudinal_cwc_v1 adapter on PR #372 dropped the opaque evidence identity that the Analysis Run boundary uses to prevent one cutoff-visible source observation from being replayed as extra scientific weight. LongitudinalClusterScore carried only snapshot_id, cluster_key, predictor/outcome coordinates, and availability time.
That omission allows one observation already available at the historical cutoff to be replayed more than once. Because the numerical owner stacks within-cluster residual rows and builds cluster means from admitted rows, replay can change row weighting, cluster means, within/between slopes, contextual effect, and row_count. This is pseudo-replication.
Leakage-safe identity population
The surviving Analysis Run vehicle #416 establishes the current historical-replay rule: availability admission precedes duplicate/domain admission. A row with AvailableTime > knowledge_cutoff was not part of the historical evidence population and must not perturb an earlier replay even if its identity duplicates a visible row. Duplicate identity is therefore rejected among cutoff-visible evidence, not across future-unavailable rows.
This corrects the first #592 test formulation, which conservatively rejected even a future-unavailable duplicate. That formulation conflicted with #416's leakage-safe census semantics and has been repaired ordinary-forward rather than hidden by history rewrite.
Required / implemented repair
Keep numerical CWC arithmetic in psychometric_core; repair only the Analysis Run adapter boundary.
- carry one bounded opaque
evidence_idon everyLongitudinalClusterScore; - validate it with the existing analysis-engine identifier contract;
- exclude future-unavailable rows before evidence-identity admission;
- reject a repeated identity among cutoff-visible evidence with
AnalysisEngineError::DuplicateEvidencebefore scientific composition; - do not infer identity from predictor/outcome/cluster/time tuples: numerically identical but distinct evidence remains admissible;
- retain immutable
snapshot_id, availability provenance, cross-snapshot refusal, cutoff binding, and causal-refusal contracts; - preserve the raw
MAX_EVIDENCE_UNITSoperational bound before filtering; - maintain public regression coverage for visible duplicate refusal, future-unavailable duplicate historical invariance, distinct-identity equal-value positive control, accessor/constructor validation;
- currentize feat(analysis): bind CWC within/between slopes to an analysis-run profile #372 / scientific: establish longitudinal CWC recovery acceptance evidence #501 scientific acceptance authority after repair; this integrity fix does not constitute full scientific: establish longitudinal CWC recovery acceptance evidence #501 Monte Carlo acceptance.
Ordinary-forward lineage
- RED
e66a90f3c6be7c04ecc9a310baf955b16dbd6f76: introduces explicit evidence identity and visible duplicate/equal-value contracts; it also initially over-constrained future-unavailable duplicates. - Repair
138be1fb8ad3ae47a18d7e05645d2ca2830cd341: addsevidence_idand duplicate detection, initially before cutoff admission. - Fixture migration
66cffe0c88f2c8e54881f6018a776c62daaf788c→418222f232dfc1eb8d6fa27d841e2302148ccf55. - Doctoring
104e2b1620ee0b7d42d1990d1fa14caaf5da46afrecords the first repair state. - Supplemental RED
bb8cb21ac40fc9f1a2d86612e8cbaaac5ccecb67: proves a future-unavailable duplicate must not change the historical artifact or terminal result. - Causal repair
6b07a4eafa3c009e36299aeca6e87a5b45201d56: moves identity admission inside the cutoff-visible branch while retaining cross-snapshot validation and raw cardinality bounds.
Ownership / acceptance
This is TEPP Analysis Run evidence/provenance composition, not a new static psychometric estimator. No source copy from fast-mlsirm, no LLM numerical authority, no skip/xfail, and no tuple-based heuristic deduplication.
A successor may close this issue only after the valid identity + cutoff-order delta, tests, provenance contract, and exact-head evidence are preserved on the surviving Analysis Run vehicle.
Activity
chore(longitudinal): preserve analysis profile shared surfaces
chore(longitudinal): restack CWC evidence contracts on analysis profile
fix(longitudinal): restore surviving #416 tree after restack