Repository navigation
resolvers: populate PRONOM PUID, LoC FDD, and subformat metadata (#1618) - #1624
Merged
Merged
Conversation
…gle#1618) Populate RegularFileType::metadata for files identified by native resolvers using the key-value store introduced in google#1618: - pronom_puid: UK National Archives PRONOM PUID (271 unique PUIDs) - loc_fdd: US Library of Congress FDD identifier (132 unique FDDs) - subformat: finer-grained variant already distinguished by existing verifiers (437 subformats across 129 content types, 183 with subformat-level PUID/FDD overrides) No new parsing or matching logic is added; resolver ContentType decisions remain identical. Note on future optimization: subformats are currently stored as static string descriptors for simplicity. If needed later, they can be represented internally as a typed enum tree with optional/lazy string materialization so subformat identification avoids any string handling when metadata is not requested.
Collaborator
|
So, this is populating the metadata k/v store with "info you find along the way", and then we'll figure out in another PR how/when to show them to CLI clients, right? And: this info would be already part of the what clients of the underlying magika-lib would have access to, right? |
reyammer
self-requested a review
November 13, 2026 14:11
reyammer
approved these changes
Nov 13, 2026
This was referenced Nov 14, 2026
ia0
approved these changes
Nov 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #1618: populate
RegularFileType::metadatafor files identified by native resolvers using the new key-value store:pronom_puid: UK National Archives PRONOM PUID (271 unique PUIDs)loc_fdd: US Library of Congress FDD identifier (132 unique FDDs)subformat: finer-grained variant already distinguished by existing verifiers (437 subformats across 129 content types, 183 with subformat-level PUID/FDD overrides)No new parsing or matching logic is added; resolver
ContentTypedecisions remain identical.Note on future optimization: subformats are currently stored as static string descriptors for simplicity. If needed later, they can be represented internally as a typed enum tree with optional/lazy string materialization so subformat identification avoids any string handling when metadata is not requested.
Testing
rustup run nightly cargo fmt --check(rust/lib,rust/cli)cargo clippy --all-targets -- --deny=warnings(rust/libdefault +pipeline,serde,rust/cli)cargo test(rust/libdefault +pipelineincluding new metadata/subformat tests,rust/cli)RUSTDOCFLAGS=--deny=warnings rustup run nightly cargo doc --no-deps --features=_docuv run scripts/sync_kb.py --self-test --check,check_copyright.py,check_documentation.py