TREEcg / specification

RDF vocabulary and hypermedia specification to publish your Linked Data using search trees
https://w3id.org/tree/specification
27 stars 12 forks source link

Clear out tree:shape definition #75

Open sandervd opened 1 year ago

sandervd commented 1 year ago

The range of tree:shape is set to shacl:NodeShape. However if a stream contains is mixed (multiple datatypes), this can cause some confusion: Is it allowed to link to a SHACL shape with multiple NodeShapes? Or should multiple tree:shape references be added, practically splitting out the SHACL file?

pietercolpaert commented 1 year ago

Cardinality is undefined, so yes, it can have multiple node shapes. By default in RDF, this means there will be an AND between these nodeshapes: each member will have to validate all nodeshapes.

If there needs to be an OR, can’t you use this: https://www.w3.org/TR/shacl/#OrConstraintComponent ?

Mind that my knowledge of SHACL is a bit shaky

sandervd commented 1 year ago

As an alternative to the current implementation I would suggest to drop the range of tree:shape, and instead define tree:shape as a subproperty of sh:shapesGraph.

pietercolpaert commented 10 months ago

Revising what I said here: now that I fully dove into SHACL, I believe just referring to a sh:NodeShape is the most clear. You can indeed use the logical components of SHACL to make choices there.

I’d even propose to make tree:shape refer to exactly one sh:NodeShape.

pietercolpaert commented 2 months ago

From the call of 2024-04-24:

2 separate pull requests to be prepared: