Traceability
Two traceability tables connect every final canonical rate back to its raw MRF source.
Why Traceability
Customer disputes, regulatory compliance, and data debugging all require knowing exactly where a rate came from. Traceability makes it possible to answer: "Which MRF file did this rate come from, and which record in that file?"
Two Traceability Tables
| Table | What It Contains | Built By |
|---|---|---|
prod_traceability_to_raw_data | Maps canonical_rate → source MRF file, raw record ID, ingestion date | build_traceability_to_raw_data() in orchestrator |
prod_traceability_formulas | Documents computation formula for derived rates (e.g., "81% × $22,800 hospital gross charge") | build_traceability_formulas_table() in orchestrator |
Walk-Through: Tracing a Rate
prod_traceability_to_raw_data on (roid, canonical_rate_subversion).aetna_machine_readable_2024_11.json, row_id 4829301, ingested 2024-11-08.Traceability for Derived Rates
For percentage-to-dollar transforms and other derived rates, prod_traceability_formulas stores the full computation formula so the derivation is auditable:
canonical_rate_type:'transform: hospital_perc_of_total_billed_charges_gc_hosp_perc_to_dol'formula:0.81 × 22800 = 18468
This makes it possible to explain not just "the rate came from the hospital MRF" but "the hospital MRF reported 81% of charges, and the gross charge used was $22,800."
Traceability tables need the final merged canonical rates across all sub-versions before they can record which sub-version and raw record each canonical rate came from. They cannot be built until after the orchestrator merge step completes.