Provenance backfill
ADMINISTRATOR Coarse heuristic that materialisesvessel_particulars_provenance rows for vessels whose particulars were extracted before v2.31.0.19.Endpoint
POST /api/admin/backfill/vessel-particulars-provenance
Body: { dryRun?: boolean = true }Heuristic
Reads vessel_particulars.source_doc_ids[] (JSON array column added by migration 0100). For each (vessel_id, source_document_id) pair, writes a provenance_quality='backfilled' row keyed by a coarse field_path set (e.g. general.imo, general.dwt, equipment.*, tanks.*).
Coarse only
Backfilled rows are intentionally less precise than extracted rows. They guarantee some source-doc trace exists; they do not guarantee per-field accuracy. For per-field accuracy, the operator must re-trigger Run 1 / Run 2 extraction on the source doc.
When to run
- After the v2.31.0.19 deploy (one-time backfill of all pre-existing vessels)
- After a UCS cascade that renamed
field_pathsegments - After importing data from a source-doc set that bypassed the extractor (shouldn't happen, but)