FAIRDataTeam / fair-semantic-model

Semantic model for the FAIR metadata in a SHACL serialization
MIT License
0 stars 1 forks source link

Distribution shape malformed? #2

Open SvenLieber opened 4 years ago

SvenLieber commented 4 years ago

I think the Distribution shape in distribution.ttl is broken.

Both the SHACL Playground and SHACL-JS throw the error Cannot find validator for constraint component http://www.w3.org/ns/shacl#MinCountConstraintComponent.

The error seems to be in the first property shape. According to SHACL-SHACL a sh:PropertyShape needs to have exactly one sh:path predicate. However, the first property shape of Distribution does not have a sh:path predicate, instead it defines two optional paths using an sh:or-construct with other property shapes.

A possible solution would be to define an alternative path using sh:path [ sh:alternativePath (dcat:accessURL dcat:downloadURL) ] ;. However, then there could be only one sh:name and sh:description.

Another solution would be to not use sh:and in the node shape and instead link via sh:property to each property shape. Then there could also be an sh:or for the property shapes of dcat:accessURL and dcat:downloadURL.

kburger commented 4 years ago

Thank you for this detailed feedback! This is for sure an issue we'll have to look into, and your suggested solutions make perfect sense. Linking via sh:property makes sense to me.

For completeness sake, this repository was meant as a sketch for what a FAIR Data Point shape collection could look like, and by no means is near final or stable version. That said, we appreciate feedback like this a lot.