What to build
Plate audits today carry row/column integer indices per field but not the human-readable well identifier ("A03") that BigQuery well_id expects, and no plate_id at all. Populate both.
Scope
Extend the plate audit shape (see src/zarrmony/writers/plate.py and the plate block written by _convert_plate in src/zarrmony/api.py):
- Top-level
plate.plate_id — extract the plate identifier from the source metadata:
- CZI:
ImageDocument/Metadata/Information/Image/Dimensions/S/Scenes/Scene[@Name] or plate-level Plate element (varies by version).
- Opera Phenix / other HCS plate readers: their plate metadata surface.
- Fail-safe: omit the key when not extractable.
- Per-field
well_id string — add the concatenated well identifier (e.g. "A03", "B12") to each entry in fields[]. Derive from existing row/column indices via the same helper that _WELL_KEY_RE inverts. Alphabetic row letter + zero-padded column matches BigQuery's expected format.
Where the values land
Under the ADR-0007-locked plate audit shape (schema-3 fields + plate). Also surface plate_id in inspect().plate_layout so pre-flight ingest can read it without a full conversion.
Acceptance criteria
Blocked by
What to build
Plate audits today carry row/column integer indices per field but not the human-readable well identifier (
"A03") that BigQuerywell_idexpects, and noplate_idat all. Populate both.Scope
Extend the plate audit shape (see
src/zarrmony/writers/plate.pyand theplateblock written by_convert_plateinsrc/zarrmony/api.py):plate.plate_id— extract the plate identifier from the source metadata:ImageDocument/Metadata/Information/Image/Dimensions/S/Scenes/Scene[@Name]or plate-levelPlateelement (varies by version).well_idstring — add the concatenated well identifier (e.g."A03","B12") to each entry infields[]. Derive from existing row/column indices via the same helper that_WELL_KEY_REinverts. Alphabetic row letter + zero-padded column matches BigQuery's expected format.Where the values land
Under the ADR-0007-locked plate audit shape (schema-3
fields+plate). Also surfaceplate_idininspect().plate_layoutso pre-flight ingest can read it without a full conversion.Acceptance criteria
plate.plate_idpopulated in the convert audit on a representative CZI plate fixture.fields[]carrieswell_idin"<row-letter><col-number>"format matching BigQuery's convention.inspect().plate_layout.plate_idpopulated when available.plate_id→ key omitted (nonull, no empty string).plate_id, plate fixture without.AUDIT_SCHEMA_VERSIONbumped.Blocked by