Skip to content

[V_delta] Restore daqmetadatareader.tab_separated_file_parameter as optional#51

Merged
stevevanhooser merged 1 commit into
mainfrom
claude/v_delta-50-restore-tsv-hook
May 21, 2026
Merged

[V_delta] Restore daqmetadatareader.tab_separated_file_parameter as optional#51
stevevanhooser merged 1 commit into
mainfrom
claude/v_delta-50-restore-tsv-hook

Conversation

@stevevanhooser
Copy link
Copy Markdown
Contributor

Closes #50.

Summary

Restores tab_separated_file_parameter in V_delta/stable/daqmetadatareader.json as an optional pass-through field. v1 corpora populate this field as a "lazy hook" for TSV-per-epoch metadata sources; dropping it at the V_delta boundary forces synthesis of a daqmetadatareader_tsv subclass at migration time that does not currently exist. Preserving the v1 hook is the smaller, safer change.

What changed

  • schemas/V_delta/stable/daqmetadatareader.json — add the field declaration with mustBeNonEmpty: false, mustBeScalar: true, queryable: true. Documentation points at the lazy-hook intent and the future-subclass cleanup direction.
  • schemas/V_delta/conversions/from_did_v1/daqmetadatareader.md — new conversion markdown documenting the full field mapping (reader_class rename + TSV-hook identity pass-through + metadata_names new field) and the rationale for keeping the hook.
  • schemas/V_delta/conversions/from_did_v1/_index.md — add the daqmetadatareader row with status applied-in-tooling.

Companion did-matlab work

The migrator at did-matlab/src/did/+did2/+convert/+migrators/daqmetadatareader.m builds newBlock from scratch and silently drops tab_separated_file_parameter. A follow-up PR on vh-lab/did-matlab extends the migrator to preserve a populated value and extends tests with the round-trip case. That PR will reference this one.

Test plan

JSON syntax validated locally. The actual schema-validation pass runs in CI here. Roundtrip tests against real corpora live in did-matlab's tests/+did2/+unittest/testCorpus*.m; the companion did-matlab PR will assert the field survives migration.

Future cleanup (out of scope)

Once V_delta is canonical and [did2 #14] / [did2 #15] migration docs land, we can revisit whether to deprecate tab_separated_file_parameter in favour of a proper daqmetadatareader_tsv subclass. That's a future-release concern; this PR keeps v1 → V_delta a clean roundtrip in the meantime.


Generated by Claude Code

…tional

Closes #50.

The v1 daqmetadatareader schema carried two fields:
- ndi_daqmetadatareader_class
- tab_separated_file_parameter

V_delta renamed the first to reader_class (already in place) but
dropped tab_separated_file_parameter entirely. The TSV hook is a
"lazy" design (the clean pattern is a daqmetadatareader_tsv
subclass) but it is in use in real v1 corpora, and synthesizing a
subclass document per migrated v1 doc is meaningfully bigger work
than preserving the hook.

Restore the field as an optional V_delta field (mustBeNonEmpty:
false, default empty). Migrator preserves a populated value;
absent v1 source yields an absent V_delta field. New
V_delta-shaped documents that need TSV reading can populate the
field directly; a future cleanup that introduces a proper
daqmetadatareader_tsv subclass can deprecate the hook then.

Changes:
- schemas/V_delta/stable/daqmetadatareader.json: add the field
  declaration with documentation pointing at the lazy-hook
  intent and the future-subclass cleanup direction.
- schemas/V_delta/conversions/from_did_v1/daqmetadatareader.md:
  new conversion markdown documenting the field mapping
  (reader_class rename + TSV hook identity passthrough +
  metadata_names new field) and the rationale for keeping the
  hook in V_delta.
- schemas/V_delta/conversions/from_did_v1/_index.md: add the
  daqmetadatareader row with status applied-in-tooling.

The companion did-matlab change (preserve the field through
the migrator) lives on a separate PR -- the migrator currently
builds the property block from scratch and silently drops any
field it does not know about, so the schema change alone does
not roundtrip the value.
@stevevanhooser stevevanhooser merged commit dde5e5f into main May 21, 2026
4 checks passed
@stevevanhooser stevevanhooser deleted the claude/v_delta-50-restore-tsv-hook branch May 21, 2026 11:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[V_delta] Restore daqmetadatareader.tab_separated_file_parameter as optional

2 participants