-
Notifications
You must be signed in to change notification settings - Fork 3
Save schema version in JSON-LD files #75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Save schema version in JSON-LD files #75
Conversation
pipeline/src/base.py
Outdated
| data["@context"] = {"@vocab": "https://openminds.ebrains.eu/vocab/"} | ||
| else: | ||
| data["@context"] = {"@vocab": "https://openminds.om-i.org/props/"} | ||
| data["@context"]["s"] = "https://schema.org/" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor point, but the prefix 'schema' is the most commonly used for schema.org.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, I'll make that change
Co-authored-by: Raphael-Gazzotti <[email protected]>
|
I see this proposal as a reasonable workaround. However, I am unsure whether we should rely on schema.org for this or if some basic metadata about the metadata model itself could be included directly by using the schemas / instances of openMINDS (e.g., pointing to metadataModel/metadataModelVersion instances). This is open for discussion, as that approach would likely be heavier than the current proposal. Additionally, we could consider including a URI for the version instead of just a string, though that is a minor detail. @openMetadataInitiative/openminds-developers, what do you all think about this? |
This was my first plan, but I couldn't find a suitable set of URIs to use. Do you have a suggestion? |
* pipeline: missed a couple of needed changes bug-fix: in avoiding infinite recursion, it is whether we've seen "self" and the "property" before that matters, not whether we've seen the value before. update property name to the one used in "latest" Fix openMetadataInitiative#73 - Infinite recursion in validate() Add Python 3.14 to the matrix for running CI tests
|
The alternative to the approach implemented here is to require the user to specify which version of openMINDS should be used by |
|
After discussion in the openMINDS dev meeting, we have decided to go with the approach in #77 |
With backwards incompatible changes being introduced into openMINDS v5, it becomes necessary to include information about which openMINDS version is being used in the JSON-LD files that are exported.
Ideally, this information would only appear once per file; I can't see any way to achieve that given the JSON-LD spec, so instead the schema version information is given per-node.
For reading a JSON-LD file without schema version information (e.g., produced with an older version of openMINDS-Python), the version will be assumed to be either v3 or v4, depending on which namespace is used).