-
Notifications
You must be signed in to change notification settings - Fork 9
openDS term data schema #196
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
base: master
Are you sure you want to change the base?
Conversation
A JSON schema to describe the openDS terms as FDO.
samleeflang
left a comment
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 think the start is there but I would make some changes:
- Don't mix schema.org and dcterms terms, there is a lot of overlap but I would say we pick one and stick with it
- Keep to naming convention
- BelongToClass probably needs to change but that impacts some other fields as well
- Used dcterms properties to be consistent with the rest of the digital objects. Removed schema.org properties. - Fixed naming style to be consistent with the rest. - Followed ISO standards and examples for dcterms:created and dcterms:modified. - Removed contributor, seemed not needed for now. We can use Creator as an Agent object. This should be sufficient for now. - Removed mapping. As mentioned in the pull request when we add a mapping to other standards, we would need to update the term, which might get tricky. - Added const spdx URl for license. - To handle "repeatable" and "required" properties, using existing terms is better, so we are using "owl:cardinality", "owl:minCardinality", and "owl:maxCardinality". - If a term can be required for one class but optional for another, this introduces complexity because JSON Schema doesn't easily support conditional logic like this. This might need to addressed in the application layer.
samleeflang
left a comment
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.
Might be best to present this in the exploration meeting, I have difficulty grasping how this would function in the landscape? What will the identifiers look like, do we need changes to the terms (for example add version)? How does this fit with semantic best practise (we use owl terms but don't implement owl)?
data-model/fdo-type/term/term.json
Outdated
| "dcterms:creator": { | ||
| "type": "object", | ||
| "description": "Contains information about the creator/proposer/requester of the term. This is an ods:Agent object", | ||
| "$ref": "https://schemas.dissco.tech/schemas/fdo-type/shared-model/0.4.0/agent.json", |
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.
I am not sure about the use of a openDS object here. The example would look a bit differently as the orcid should also be there as an identifier.
data-model/fdo-type/term/term.json
Outdated
| "const": "https://spdx.org/licenses/CC0-1.0.json", | ||
| "description": "The licence for the term, required to be always public domain" | ||
| }, | ||
| "ods:belongsToClass": { |
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.
Wondering if rdfs:range does not cover this? This doesn't feel like we should be the ones creating this term
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.
check if rdfs:range. can this do array?
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.
we are using rdfs:range. updated.
changes in this version: - updated Regex for the Handle - removed rdf:Type - used ods:hasAgent instead of dcterms:creator - added skos:note and skos:example - removed owl cardinality. we use json schema required for this - added hasVersion for more provenance metadata - used rdfs:range instead of new term belongsToClass - added langiage in prefLabel
|
updated schema
|
samleeflang
left a comment
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.
Couple comments. General points:
- Can a term reference itself? We use odsTerms here which are described by this object. So the object is using a term which is defined by itself. Not sure if that is an issue or not.
- I think we need a lot more required attributes
Changes (based on the PR and meeting feedback) - updated required properties - added hasAgents (this is another object we will call from this) - removed dcterms:hasVersion. Even though this is semantically diff than ods:version we do not need this now. - added "@type" - Regarding self reference. yes, that was answered in the PR comment. Yes, this is common in RDF/ontology and data typing world. self referencing/recursive definition. For example in RDF schema (https://www.w3.org/2000/01/rdf-schema) rdfs:Class is the class of all classes, and it is itself an instance of rdfs:Class.
Added optional ods:hasControlledValues array to define controlled vocabulary values that a term accepts (e.g., topicDiscipline can have values: Botany, Geology, etc.). Each controlled value gets its own PID following pattern hdl:20.500.1025/term/value. This complements skos:inScheme usage and maintains FAIR/FDO compliance while avoiding misuse of skos:member outside of collections. skos:narrower: Implies hierarchical relationships where the controlled values are "narrower concepts" of the term itself. But that's not quite right - "Botany" isn't a narrower concept of "topicDiscipline", it's a value that topicDiscipline can take. skos:related: Too vague and doesn't capture the specific "this term accepts these values" relationship
samleeflang
left a comment
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.
Have some comments, mainly about the examples.
| "ods:fdoType": "https://doi.org/21.T11148/bbad8c4e101e8af01115", | ||
| "ods:status": "ods:Active", | ||
| "ods:version": 1, | ||
| "ods:hasAgents": [], |
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.
This should have a creator and/or modifier
| { | ||
| "@id": "https://hdl.handle.net/20.500.1025/topicDiscipline", | ||
| "@type": "ods:Term", | ||
| "ods:fdoType": "https://doi.org/21.T11148/bbad8c4e101e8af01115", |
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.
This points to the digital media fdoType record. Is there already a FDO type for this otherwise we need to add it later and don't forget to update the examples
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.
created a new type 21.T11148/770bce19da07e2e1106c
| "skos:definition": "Add def here.", | ||
| "dcterms:created": "2025-01-15T09:00:00.000Z", | ||
| "dcterms:modified": "2025-01-15T09:00:00.000Z", | ||
| "rdfs:range": [ |
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.
Hmm this points to itself at the moment, it should point to DigitalSpecimen
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.
fixed
| "ods:hasAgents": [], | ||
| "dcterms:title": "ods:topicDiscipline", | ||
| "skos:prefLabel": "Topic Discipline", | ||
| "skos:definition": "Add def here.", |
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.
Maybe take over the existing definition here:
"Overarching classification of the scientific discipline to which the objects within the collection belong or are related"
| "skos:prefLabel": "Topic Discipline", | ||
| "skos:definition": "Add def here.", | ||
| "dcterms:created": "2025-01-15T09:00:00.000Z", | ||
| "dcterms:modified": "2025-01-15T09:00:00.000Z", |
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.
Would be better to have a time difference with dcterms:created. If we have modified in here we should also have an agent with a role Modifier
| "skos:note": "Used in multiple schemas including the Digital Specimen FDO.", | ||
| "skos:example": "https://data.biodiversitydata.nl/naturalis/specimen/RGM.234626", | ||
| "dcterms:created": "2025-07-30T10:00:00Z", | ||
| "dcterms:modified": "2025-07-30T10:00:00Z", |
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.
If we have a modified I would expect a modifier
data-model/fdo-type/term/term.json
Outdated
| }, | ||
| "ods:fdoType": { | ||
| "type": "string", | ||
| "description": "The DOI to the FDO type of the object", |
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.
The FDO types are currently handles so this should be a handle string. See https://schemas.dissco.tech/schemas/fdo-type/virtual-collection/0.1.0/virtual-collection.json
| { | ||
| "@id": "https://hdl.handle.net/20.500.1025/physicalSpecimenID", | ||
| "@type": "ods:Term", | ||
| "ods:fdoType": "https://doi.org/21.T11148/bbad8c4e101e8af01115", |
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.
Needs to be updated when we have an fdoType handle (also better to put this as a handle as it is not a DOI)
Fixed hasAgents, added modifier role added correct fdoType PID.
samleeflang
left a comment
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.
Check the comments, but there are still some basic issue with this PR.
Please validate that the properties you use to describe are valid JSON Schema properties. You can just check the standard https://json-schema.org/.
Validate the examples against the schema.
This can easily be done through something like https://www.jsonschemavalidator.net/
You will immediately see there are issue with the validation of the examples.
data-model/fdo-type/term/term.json
Outdated
| "type": "string" | ||
| } | ||
| }, | ||
| "skos:member": { |
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.
Formatting is off here and on other places in this file. Clear formatting helps with readability.
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.
ah yes, this can be removed. ods:hasControlledvalue does the same purpose justification is that the proper use of skos:member is related to skos:Collections. we are not using that. i added some notes in DEX-106.
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.
and formatting fixed.
data-model/fdo-type/term/term.json
Outdated
| "examples": [ | ||
| "Digital Specimen" | ||
| ], | ||
| "@language": { |
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.
This isn't a valid JsonSchema property
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.
I will remove this.
data-model/fdo-type/term/term.json
Outdated
| "type": "string" | ||
| } | ||
| }, | ||
| "skos:member": { |
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.
I don't understand how this works and I don't see it used in the examples. Wouldn't all these terms be of the dissco vocabulary?
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.
this can be removed. ods:hasControlledvalue does the same purpose justification is that the proper use of skos:member is related to skos:Collections. we are not using that. i added some notes in DEX-106. and yes. each term will be a dissco vocab. ods:topicDiscipline example has this.
data-model/fdo-type/term/term.json
Outdated
| "skos:definition", | ||
| "ods:hasAgents", | ||
| "ods:status", | ||
| "rdfs:range" |
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.
Would range always be there? If I got a ods:DigitalSpecimen which is the class than it won't have a range correct?
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.
yes, this does not need to be required.
| "https://hdl.handle.net/20.500.1025/DigitalSpecimen" | ||
| ], | ||
| "owl:deprecated": false, | ||
| "ods:hasAgents": [ |
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.
Agent lacks the ods:hasIdentifier object for the orchid see any of the other examples:
"dcterms:creator": {
"@id": "https://orcid.org/0000-0002-5669-2769",
"@type": "schema:Person",
"schema:name": "John Doe",
"ods:hasIdentifiers": [
{
"@id": "https://orcid.org/0000-0002-5669-2769",
"@type": "ods:Identifier",
"dcterms:title": "ORCID",
"dcterms:type": "URL",
"dcterms:identifier": "https://orcid.org/0000-0002-5669-2769",
"ods:isPartOfLabel": false,
"ods:gupriLevel": "GloballyUniqueStablePersistentResolvable",
"ods:identifierStatus": "Preferred"
}
]
},
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.
I will update the example.
| { | ||
| "@type": "schema:Role", | ||
| "schema:roleName": "modifier", | ||
| "schema:startDate": "2025-01-17T09:00:00.000Z", |
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.
We haven't really used the start/endDate of role yet and I am not sure how it will work. I would remove them here. Remove these and add the hasIdentifier part
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.
| "skos:definition": "The physical specimen identifier of the object. The main identifier of the object is used (which can be indicated by the user through the DataMapping). If the ods:physicalSpecimenIDType is Resolvable or Global, this identifier is the same as the `ods:normalisedPhysicalSpecimenID`.", | ||
| "skos:note": "Used in multiple schemas including the Digital Specimen FDO.", | ||
| "skos:example": "https://data.biodiversitydata.nl/naturalis/specimen/RGM.234626", | ||
| "dcterms:created": "2025-07-30T10:00:00Z", |
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.
This object lacks the required field "dcterms:modified"
| { | ||
| "@id": "https://hdl.handle.net/20.500.1025/topicDiscipline", | ||
| "@type": "ods:Term", | ||
| "ods:fdoType": "https://doi.org/21.T11148/770bce19da07e2e1106c", |
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.
This should be a handle
data-model/fdo-type/term/term.json
Outdated
| "description": "The Handle to the FDO type of the object", | ||
| "pattern": "^https:\/\/hdl\\.handle\\.net\/[\\w.]+\/(.){3}-(.){3}-(.){3}", | ||
| "examples": [ | ||
| "https://hdl.handle.net/21.T11148/2ac65a933b7a0361b651" |
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.
This is still the VirtualCollection, better to point to the FDOType for the Term here
- Updated regex patterns for FDO type - removed skos:member as this is same as hasControlledvalue - removed rdfs:range from required - added skos:example in required - removed @langauge as this is not valid JSON
- updated fdoType link to the correct Handle - updated regex - updated hasAgents to have hasIdentifier.
A JSON schema to describe the openDS terms as FDO.
The first version of this schema is focused on creating the basic structure of the object. Feedback from RFC will be incorporated in different stages. There are a few decisions regarding RDF, JSON-LD we have to make.