From 5498be5217323a5f5de15f8731fd88b6723d1115 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Tue, 5 Aug 2025 10:22:02 +0300 Subject: [PATCH 01/13] minor editorial change --- shacl12-vocabularies/shacl-shacl.ttl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/shacl12-vocabularies/shacl-shacl.ttl b/shacl12-vocabularies/shacl-shacl.ttl index 31f7e7a5..fc0536f3 100644 --- a/shacl12-vocabularies/shacl-shacl.ttl +++ b/shacl12-vocabularies/shacl-shacl.ttl @@ -23,11 +23,11 @@ shsh: shsh:ListShape a sh:NodeShape ; rdfs:label "List shape"@en ; - rdfs:comment "A shape describing well-formed RDF lists. Currently does not check for non-recursion. This could be expressed using SHACL-SPARQL."@en ; + rdfs:comment "A shape describing well-formed RDF lists. Currently does not check for non-recursion (this could be expressed using SHACL-SPARQL)."@en ; rdfs:seeAlso ; sh:property [ sh:path [ sh:zeroOrMorePath rdf:rest ] ; - rdfs:comment "Each list member (including this node) must be have the shape shsh:ListNodeShape."@en ; + rdfs:comment "Each list member (including this node) must have the shape shsh:ListNodeShape."@en ; sh:hasValue rdf:nil ; sh:node shsh:ListNodeShape ; ] . From 8243c01cb58fc65b2dd2ae261dc9c98e27418709 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Tue, 5 Aug 2025 17:20:52 +0300 Subject: [PATCH 02/13] plantuml version of diagram --- shacl12-core/images/Makefile | 4 +++ shacl12-core/images/SHACL-UML.puml | 47 ++++++++++++++++++++++++++++++ shacl12-core/images/SHACL-UML.svg | 1 + 3 files changed, 52 insertions(+) create mode 100644 shacl12-core/images/Makefile create mode 100644 shacl12-core/images/SHACL-UML.puml create mode 100644 shacl12-core/images/SHACL-UML.svg diff --git a/shacl12-core/images/Makefile b/shacl12-core/images/Makefile new file mode 100644 index 00000000..0a74db0f --- /dev/null +++ b/shacl12-core/images/Makefile @@ -0,0 +1,4 @@ +all: SHACL-UML.svg + +%.svg: %.puml + plantuml -Tsvg $^ diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml new file mode 100644 index 00000000..b29fdd53 --- /dev/null +++ b/shacl12-core/images/SHACL-UML.puml @@ -0,0 +1,47 @@ +@startuml +hide circles +hide empty members +skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html + +class "sh:Shape" as Shape [[#shapes]] { + [[#targetClass sh:targetClass]] : rdfs:Class + [[#targetNode sh:targetNode]] : any + [[#targetObjectsOf sh:targetObjectsOf]] : rdf:Property + [[#targetSubjectsOf sh:targetSubjectsOf]] : rdf:Property + .... + [[#deactivated sh:deactivated]] : xsd:boolean + [[#message sh:message]] : xsd:string or rdf:langString + [[#severity sh:severity]] : sh:Severity +} + +class "sh:NodeShape" as NodeShape [[#node-shapes]] { + [[#constraints Constraint parameters]], for example: + [[#closedConstraintComponent sh:closed]] : xsd:boolean or [[#syntax-rule-closed-datatype sh:ByTypes]] + [[#orConstraintComponent sh:or]], [[#andConstraintComponent sh:and]], [[#xoneConstraintComponent sh:xone]] : rdf:List + [[#notConstraintComponent sh:not]] : [[#shapes sh:Shape]] +} + +class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { + [[#constraints Constraint parameters]], for example: + [[#MinCountConstraintComponent sh:minCount]], [[#MaxCountConstraintComponent sh:maxCount]] : xsd:integer + [[#MinLengthConstraintComponent sh:minLength]], [[#MaxLengthConstraintComponent sh:maxLength]] : xsd:integer + [[#ClassConstraintComponent sh:class]] or [[#DatatypeConstraintComponent sh:datatype]] : rdfs:Resource or\n rdf:List of rdfs:Resources + [[#NodeConstraintComponent sh:node]] : [[#node-shapes sh:NodeShape]] + .... + [[#name sh:name]] : xsd:string or rdf:langString + [[#desription sh:description]] : xsd:string or rdf:langString + [[#syntax-rule-path-defaultValue sh:defaultValue]] : any + [[#syntax-rule-path-defaultValue sh:values]] : any + [[#order sh:order]] : number + [[#property-shapes sh:path]] : rdfs:Resource +} + +class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { + [[#group sh:order]] : number +} + +Shape <|-- NodeShape +Shape <|-- PropertyShape +NodeShape -> PropertyShape : [[#property-shapes sh:property]] * +PropertyShape --> PropertyGroup : [[#group sh:group]] +@enduml diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg new file mode 100644 index 00000000..9998fc2d --- /dev/null +++ b/shacl12-core/images/SHACL-UML.svg @@ -0,0 +1 @@ +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetObjectsOf: rdf:Propertysh:targetSubjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:closed: xsd:boolean orsh:ByTypessh:or,sh:and,sh:xone: rdf:Listsh:not:sh:Shapesh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: rdfs:Resource orrdf:List of rdfs:Resourcessh:node:sh:NodeShapesh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: numbersh:path: rdfs:Resourcesh:PropertyGroupsh:order: numbersh:property*sh:group \ No newline at end of file From 3de3e449a9c93e651479352618c7a259c90c1fa4 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Tue, 5 Aug 2025 18:01:41 +0300 Subject: [PATCH 03/13] add manual `` and `` tags to class names --- shacl12-core/images/SHACL-UML.puml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index b29fdd53..ac3304a1 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -3,7 +3,7 @@ hide circles hide empty members skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html -class "sh:Shape" as Shape [[#shapes]] { +class "sh:Shape" as Shape [[#shapes]] { [[#targetClass sh:targetClass]] : rdfs:Class [[#targetNode sh:targetNode]] : any [[#targetObjectsOf sh:targetObjectsOf]] : rdf:Property @@ -14,14 +14,14 @@ class "sh:Shape" as Shape [[#shapes]] { [[#severity sh:severity]] : sh:Severity } -class "sh:NodeShape" as NodeShape [[#node-shapes]] { +class "sh:NodeShape" as NodeShape [[#node-shapes]] { [[#constraints Constraint parameters]], for example: [[#closedConstraintComponent sh:closed]] : xsd:boolean or [[#syntax-rule-closed-datatype sh:ByTypes]] [[#orConstraintComponent sh:or]], [[#andConstraintComponent sh:and]], [[#xoneConstraintComponent sh:xone]] : rdf:List [[#notConstraintComponent sh:not]] : [[#shapes sh:Shape]] } -class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { +class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { [[#constraints Constraint parameters]], for example: [[#MinCountConstraintComponent sh:minCount]], [[#MaxCountConstraintComponent sh:maxCount]] : xsd:integer [[#MinLengthConstraintComponent sh:minLength]], [[#MaxLengthConstraintComponent sh:maxLength]] : xsd:integer From 01b4b1bebc2eac7bfb6e4fcf5a0d2ea725192274 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Tue, 5 Aug 2025 18:03:18 +0300 Subject: [PATCH 04/13] add manual `` and `` tags to class names --- shacl12-core/images/SHACL-UML.svg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index 9998fc2d..ead7cf11 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetObjectsOf: rdf:Propertysh:targetSubjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:closed: xsd:boolean orsh:ByTypessh:or,sh:and,sh:xone: rdf:Listsh:not:sh:Shapesh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: rdfs:Resource orrdf:List of rdfs:Resourcessh:node:sh:NodeShapesh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: numbersh:path: rdfs:Resourcesh:PropertyGroupsh:order: numbersh:property*sh:group \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetObjectsOf: rdf:Propertysh:targetSubjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:closed: xsd:boolean orsh:ByTypessh:or,sh:and,sh:xone: rdf:Listsh:not:sh:Shapesh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: rdfs:Resource orrdf:List of rdfs:Resourcessh:node:sh:NodeShapesh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: numbersh:path: rdfs:Resourcesh:PropertyGroupsh:order: numbersh:property*sh:group \ No newline at end of file From 138b174a1ad80619133109fe18cb30358b827151 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Wed, 6 Aug 2025 19:51:35 +0300 Subject: [PATCH 05/13] Update shacl12-core/images/SHACL-UML.puml Co-authored-by: Yousouf Taghzouti <48333491+YoucTagh@users.noreply.github.com> --- shacl12-core/images/SHACL-UML.puml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index ac3304a1..ce77425c 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -16,9 +16,9 @@ class "sh:Shape" as Shape [[#shapes]] { class "sh:NodeShape" as NodeShape [[#node-shapes]] { [[#constraints Constraint parameters]], for example: - [[#closedConstraintComponent sh:closed]] : xsd:boolean or [[#syntax-rule-closed-datatype sh:ByTypes]] - [[#orConstraintComponent sh:or]], [[#andConstraintComponent sh:and]], [[#xoneConstraintComponent sh:xone]] : rdf:List - [[#notConstraintComponent sh:not]] : [[#shapes sh:Shape]] + [[#ClosedConstraintComponent sh:closed]] : xsd:boolean or [[#syntax-rule-closed-datatype sh:ByTypes]] + [[#OrConstraintComponent sh:or]], [[#AndConstraintComponent sh:and]], [[#XoneConstraintComponent sh:xone]] : rdf:List + [[#NotConstraintComponent sh:not]] : [[#shapes sh:Shape]] } class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { From b991942f7d1174970e7a51f72b3d12f9a0903da3 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Wed, 6 Aug 2025 19:51:44 +0300 Subject: [PATCH 06/13] Update shacl12-core/images/SHACL-UML.puml Co-authored-by: Yousouf Taghzouti <48333491+YoucTagh@users.noreply.github.com> --- shacl12-core/images/SHACL-UML.puml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index ce77425c..6252a34c 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -29,7 +29,7 @@ class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { [[#NodeConstraintComponent sh:node]] : [[#node-shapes sh:NodeShape]] .... [[#name sh:name]] : xsd:string or rdf:langString - [[#desription sh:description]] : xsd:string or rdf:langString + [[#description sh:description]] : xsd:string or rdf:langString [[#syntax-rule-path-defaultValue sh:defaultValue]] : any [[#syntax-rule-path-defaultValue sh:values]] : any [[#order sh:order]] : number From 72e0ff6ec98a952befd01b9370e1710128d7b0f6 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Thu, 7 Aug 2025 13:01:51 +0300 Subject: [PATCH 07/13] - sh:order: xsd:integer or xsd:decimal - sh:path : predicate or list or blank node and link to #property-paths - add ellipsis as per TallTed - rdf:List -> "list" because SHACL doesn't require the rdf:List type - add sh:nodeKind, sh:ignoredProperties --- shacl12-core/images/SHACL-UML.puml | 17 +++++++++++------ shacl12-core/images/SHACL-UML.svg | 2 +- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index 6252a34c..c9ba5c11 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -6,8 +6,8 @@ skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/ind class "sh:Shape" as Shape [[#shapes]] { [[#targetClass sh:targetClass]] : rdfs:Class [[#targetNode sh:targetNode]] : any - [[#targetObjectsOf sh:targetObjectsOf]] : rdf:Property [[#targetSubjectsOf sh:targetSubjectsOf]] : rdf:Property + [[#targetObjectsOf sh:targetObjectsOf]] : rdf:Property .... [[#deactivated sh:deactivated]] : xsd:boolean [[#message sh:message]] : xsd:string or rdf:langString @@ -16,28 +16,33 @@ class "sh:Shape" as Shape [[#shapes]] { class "sh:NodeShape" as NodeShape [[#node-shapes]] { [[#constraints Constraint parameters]], for example: + [[#NodeKindConstraintComponent sh:nodeKind]] a sh:NodeKind [[#ClosedConstraintComponent sh:closed]] : xsd:boolean or [[#syntax-rule-closed-datatype sh:ByTypes]] - [[#OrConstraintComponent sh:or]], [[#AndConstraintComponent sh:and]], [[#XoneConstraintComponent sh:xone]] : rdf:List + [[#ClosedConstraintComponent sh:ignoredProperties]] : list + [[#OrConstraintComponent sh:or]], [[#AndConstraintComponent sh:and]], [[#XoneConstraintComponent sh:xone]] : list of Shape [[#NotConstraintComponent sh:not]] : [[#shapes sh:Shape]] + ... } class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { [[#constraints Constraint parameters]], for example: [[#MinCountConstraintComponent sh:minCount]], [[#MaxCountConstraintComponent sh:maxCount]] : xsd:integer [[#MinLengthConstraintComponent sh:minLength]], [[#MaxLengthConstraintComponent sh:maxLength]] : xsd:integer - [[#ClassConstraintComponent sh:class]] or [[#DatatypeConstraintComponent sh:datatype]] : rdfs:Resource or\n rdf:List of rdfs:Resources + [[#ClassConstraintComponent sh:class]] or [[#DatatypeConstraintComponent sh:datatype]] : IRI or list of IRIs [[#NodeConstraintComponent sh:node]] : [[#node-shapes sh:NodeShape]] + ... .... [[#name sh:name]] : xsd:string or rdf:langString [[#description sh:description]] : xsd:string or rdf:langString [[#syntax-rule-path-defaultValue sh:defaultValue]] : any [[#syntax-rule-path-defaultValue sh:values]] : any - [[#order sh:order]] : number - [[#property-shapes sh:path]] : rdfs:Resource + [[#order sh:order]] : xsd:integer or xsd:decimal + [[#property-paths sh:path]] : predicate or list or blank node } class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { - [[#group sh:order]] : number + [[#group sh:order]] : xsd:integer or xsd:decimal + ... eg rdfs:label } Shape <|-- NodeShape diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index ead7cf11..0969614d 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetObjectsOf: rdf:Propertysh:targetSubjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:closed: xsd:boolean orsh:ByTypessh:or,sh:and,sh:xone: rdf:Listsh:not:sh:Shapesh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: rdfs:Resource orrdf:List of rdfs:Resourcessh:node:sh:NodeShapesh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: numbersh:path: rdfs:Resourcesh:PropertyGroupsh:order: numbersh:property*sh:group \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file From 1ef89939a8bb9490b48f7cf98f93f69bd07a6597 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Thu, 7 Aug 2025 13:02:48 +0300 Subject: [PATCH 08/13] add to PropertyGroup --- shacl12-core/images/SHACL-UML.puml | 2 +- shacl12-core/images/SHACL-UML.svg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index c9ba5c11..54dcdfb9 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -40,7 +40,7 @@ class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { [[#property-paths sh:path]] : predicate or list or blank node } -class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { +class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { [[#group sh:order]] : xsd:integer or xsd:decimal ... eg rdfs:label } diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index 0969614d..72660b47 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file From 01fe8a27892dd56b8fa0ce364d4591b73f85f673 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Thu, 7 Aug 2025 13:14:42 +0300 Subject: [PATCH 09/13] replace textual diagram with PlantUML SVG diagram --- shacl12-core/images/Class-Diagram-Arrows.png | Bin 16225 -> 0 bytes shacl12-core/images/SHACL-UML.puml | 2 +- shacl12-core/images/SHACL-UML.svg | 2 +- shacl12-core/index.html | 67 ++----------------- 4 files changed, 8 insertions(+), 63 deletions(-) delete mode 100644 shacl12-core/images/Class-Diagram-Arrows.png diff --git a/shacl12-core/images/Class-Diagram-Arrows.png b/shacl12-core/images/Class-Diagram-Arrows.png deleted file mode 100644 index 7145e83f107c60bee374bcad622ce4e4dc8f4b12..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 16225 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 diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index 54dcdfb9..cd5af8b6 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -1,7 +1,7 @@ @startuml hide circles hide empty members -skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html +' skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html ' Hope # anchors will resolve to current HTML page class "sh:Shape" as Shape [[#shapes]] { [[#targetClass sh:targetClass]] : rdfs:Class diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index 72660b47..c58d5ee5 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file diff --git a/shacl12-core/index.html b/shacl12-core/index.html index f2e51773..90282a0b 100644 --- a/shacl12-core/index.html +++ b/shacl12-core/index.html @@ -1115,70 +1115,15 @@

Shapes and Constraints

The following introduction is non-normative.

- The following informal diagram provides an overview of some of the key classes in the SHACL vocabulary. + The following UML diagram provides an overview of some of the key classes and properties in the SHACL vocabulary. Each box represents a class. The content of the boxes under the class name lists some of the properties that instances of these classes may have, together with their value types. - The arrows indicate rdfs:subClassOf triples. + Empty arrowheads indicate inheritance (rdfs:subClassOf) and normal arrowheads indicate RDF relations. +

+
UML class diagram for SHACL showing Shape, NodeShape, PropertyShape, PropertyGroup
+

+ The Turtle serialization of the SHACL vocabulary contains the complete SHACL vocabulary.

-
-
- -
-
-
sh:targetClass : rdfs:Class
- -
sh:targetObjectsOf : rdf:Property
-
sh:targetSubjectsOf : rdf:Property
-
-
-
sh:deactivated : xsd:boolean
-
sh:message : xsd:string or rdf:langString
-
sh:severity : sh:Severity
-
-
-
-
- Class Diagram Arrows -
-
-
- -
-
-
Constraint parameters, for example:
-
sh:closed : xsd:boolean or sh:ByTypes
-
sh:or : rdf:List
-
sh:not : sh:Shape
-
sh:property : sh:PropertyShape
-
-
-
-
- -
-
-
Constraint parameters, for example:
-
sh:minCount, sh:maxCount : xsd:integer
-
sh:class or sh:datatype : rdfs:Resource
-
sh:node : sh:NodeShape
-
-
-
sh:name : xsd:string or rdf:langString
-
sh:description : xsd:string or rdf:langString
- -
sh:group : sh:PropertyGroup
-
-
-
sh:path : rdfs:Resource
-
-
-
-
-
-

- The Turtle serialization of the SHACL vocabulary contains the complete SHACL vocabulary. -

-
From 367e5a18eb07cd0ec8dd4f220b41e93f95d0fd5d Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Thu, 7 Aug 2025 15:54:05 +0300 Subject: [PATCH 10/13] replace with script that embeds SVG content --- shacl12-core/images/SHACL-UML.puml | 3 ++- shacl12-core/images/SHACL-UML.svg | 2 +- shacl12-core/index.html | 20 ++++++++++++++------ 3 files changed, 17 insertions(+), 8 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index cd5af8b6..feea87ea 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -1,7 +1,8 @@ @startuml hide circles hide empty members -' skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html ' Hope # anchors will resolve to current HTML page +skinparam pathHoverColor red ' on cover, highlight blue links as red +' skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html ' links resolve to anchors in current HTML page, when the SVG is embedded class "sh:Shape" as Shape [[#shapes]] { [[#targetClass sh:targetClass]] : rdfs:Class diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index c58d5ee5..2a34e1d6 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file diff --git a/shacl12-core/index.html b/shacl12-core/index.html index 90282a0b..274f5bce 100644 --- a/shacl12-core/index.html +++ b/shacl12-core/index.html @@ -1120,7 +1120,7 @@

Shapes and Constraints

The content of the boxes under the class name lists some of the properties that instances of these classes may have, together with their value types. Empty arrowheads indicate inheritance (rdfs:subClassOf) and normal arrowheads indicate RDF relations.

-
UML class diagram for SHACL showing Shape, NodeShape, PropertyShape, PropertyGroup
+

The Turtle serialization of the SHACL vocabulary contains the complete SHACL vocabulary.

@@ -7921,12 +7921,20 @@

Changes between SHACL 1.0 Core and SHACL 1.2 Core

From 2c4f8b46ad7481c05f974b0fd4c389e2409ea683 Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Fri, 17 Oct 2025 17:05:56 +0300 Subject: [PATCH 11/13] add core-components-list (3 fields), sh:targetWhere, sh:codeIdentifier. Move sh:path to top of PropertyShape --- shacl12-core/images/SHACL-UML.puml | 17 +++++++++++++++-- shacl12-core/images/SHACL-UML.svg | 2 +- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index feea87ea..8b3143c2 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -9,6 +9,7 @@ class "sh:Shape" as Shape [[#shapes]] { [[#targetNode sh:targetNode]] : any [[#targetSubjectsOf sh:targetSubjectsOf]] : rdf:Property [[#targetObjectsOf sh:targetObjectsOf]] : rdf:Property + [[#targetWhere sh:targetWhere]] : sh:NodeShape .... [[#deactivated sh:deactivated]] : xsd:boolean [[#message sh:message]] : xsd:string or rdf:langString @@ -26,6 +27,8 @@ class "sh:NodeShape" as NodeShape [[#node-shapes]] { } class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { + [[#property-paths sh:path]] : predicate or list or blank node + .... [[#constraints Constraint parameters]], for example: [[#MinCountConstraintComponent sh:minCount]], [[#MaxCountConstraintComponent sh:maxCount]] : xsd:integer [[#MinLengthConstraintComponent sh:minLength]], [[#MaxLengthConstraintComponent sh:maxLength]] : xsd:integer @@ -33,12 +36,17 @@ class "sh:PropertyShape" as PropertyShape [[#property-shapes]] { [[#NodeConstraintComponent sh:node]] : [[#node-shapes sh:NodeShape]] ... .... + [[#core-components-list List constraints]] + [[#MemberShapeConstraintComponent sh:memberShape]] : [[#node-shapes sh:NodeShape]] + [[#MinListLengthConstraintComponent sh:minListLength]], [[#MaxListLengthConstraintComponent sh:maxListLength]]: xsd:integer + [[#UniqueMembersConstraintComponent sh:uniqueMembers]] : xsd:boolean + .... [[#name sh:name]] : xsd:string or rdf:langString [[#description sh:description]] : xsd:string or rdf:langString [[#syntax-rule-path-defaultValue sh:defaultValue]] : any [[#syntax-rule-path-defaultValue sh:values]] : any + [[#codeIdentifier sh:codeIdentifier]] : xsd:string [[#order sh:order]] : xsd:integer or xsd:decimal - [[#property-paths sh:path]] : predicate or list or blank node } class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { @@ -49,5 +57,10 @@ class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { Shape <|-- NodeShape Shape <|-- PropertyShape NodeShape -> PropertyShape : [[#property-shapes sh:property]] * -PropertyShape --> PropertyGroup : [[#group sh:group]] + +' These links make the diagram too busy, so omit them for now. They are listed as fields +' PropertyShape -> NodeShape : [[#NodeConstraintComponent sh:node]] +' PropertyShape -> NodeShape : [[#MemberShapeConstraintComponent sh:memberShape]] +' PropertyShape --> PropertyGroup : [[#group sh:group]] +' Shape -> NodeShape : [[#targetWhere sh:targetWhere]] @enduml diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index 2a34e1d6..9e105f76 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...sh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:order: xsd:integer or xsd:decimalsh:path: predicate or list or blank nodesh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:targetWhere: sh:NodeShapesh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapesh:path: predicate or list or blank nodeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...List constraintssh:memberShape:sh:NodeShapesh:minListLength,sh:maxListLength: xsd:integersh:uniqueMembers: xsd:booleansh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:codeIdentifier: xsd:stringsh:order: xsd:integer or xsd:decimalsh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property* \ No newline at end of file From 2770f327712397e9671293c13a907941c689f44d Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Fri, 17 Oct 2025 17:10:30 +0300 Subject: [PATCH 12/13] restore link to PropertyGroup --- shacl12-core/images/SHACL-UML.puml | 2 +- shacl12-core/images/SHACL-UML.svg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/shacl12-core/images/SHACL-UML.puml b/shacl12-core/images/SHACL-UML.puml index 8b3143c2..927667a2 100644 --- a/shacl12-core/images/SHACL-UML.puml +++ b/shacl12-core/images/SHACL-UML.puml @@ -57,10 +57,10 @@ class "sh:PropertyGroup" as PropertyGroup [[#group sh:group]] { Shape <|-- NodeShape Shape <|-- PropertyShape NodeShape -> PropertyShape : [[#property-shapes sh:property]] * +PropertyShape --> PropertyGroup : [[#group sh:group]] ' These links make the diagram too busy, so omit them for now. They are listed as fields ' PropertyShape -> NodeShape : [[#NodeConstraintComponent sh:node]] ' PropertyShape -> NodeShape : [[#MemberShapeConstraintComponent sh:memberShape]] -' PropertyShape --> PropertyGroup : [[#group sh:group]] ' Shape -> NodeShape : [[#targetWhere sh:targetWhere]] @enduml diff --git a/shacl12-core/images/SHACL-UML.svg b/shacl12-core/images/SHACL-UML.svg index 9e105f76..e40b4a38 100644 --- a/shacl12-core/images/SHACL-UML.svg +++ b/shacl12-core/images/SHACL-UML.svg @@ -1 +1 @@ -sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:targetWhere: sh:NodeShapesh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapesh:path: predicate or list or blank nodeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...List constraintssh:memberShape:sh:NodeShapesh:minListLength,sh:maxListLength: xsd:integersh:uniqueMembers: xsd:booleansh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:codeIdentifier: xsd:stringsh:order: xsd:integer or xsd:decimalsh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property* \ No newline at end of file +sh:Shapesh:targetClass: rdfs:Classsh:targetNode: anysh:targetSubjectsOf: rdf:Propertysh:targetObjectsOf: rdf:Propertysh:targetWhere: sh:NodeShapesh:deactivated: xsd:booleansh:message: xsd:string or rdf:langStringsh:severity: sh:Severitysh:NodeShapeConstraint parameters, for example:sh:nodeKinda sh:NodeKindsh:closed: xsd:boolean orsh:ByTypessh:ignoredProperties: listsh:or,sh:and,sh:xone: list of Shapesh:not:sh:Shape...sh:PropertyShapesh:path: predicate or list or blank nodeConstraint parameters, for example:sh:minCount,sh:maxCount: xsd:integersh:minLength,sh:maxLength: xsd:integersh:classorsh:datatype: IRI or list of IRIssh:node:sh:NodeShape...List constraintssh:memberShape:sh:NodeShapesh:minListLength,sh:maxListLength: xsd:integersh:uniqueMembers: xsd:booleansh:name: xsd:string or rdf:langStringsh:description: xsd:string or rdf:langStringsh:defaultValue: anysh:values: anysh:codeIdentifier: xsd:stringsh:order: xsd:integer or xsd:decimalsh:PropertyGroupsh:order: xsd:integer or xsd:decimal... eg rdfs:labelsh:property*sh:group \ No newline at end of file From 8d3d82338b48fef9563fc14c46756b7f01d9fd1a Mon Sep 17 00:00:00 2001 From: Vladimir Alexiev Date: Thu, 23 Oct 2025 14:39:04 +0300 Subject: [PATCH 13/13] fixes #163 --- shacl12-sparql/index.html | 43 +++++++++++++++++++++++---------------- 1 file changed, 25 insertions(+), 18 deletions(-) diff --git a/shacl12-sparql/index.html b/shacl12-sparql/index.html index 5ecb3331..f6dc805b 100644 --- a/shacl12-sparql/index.html +++ b/shacl12-sparql/index.html @@ -930,7 +930,7 @@

Syntax of SPARQL-based Constraints

and this value is either true or false.

- SELECT queries used in the context of property shapes use a special variable named PATH as a placeholder for the path used by the shape. + SELECT queries used in the context of property shapes use a special variable named PATH (spelled in UPPERCASE) as a placeholder for the path used by the shape.

The only legal use of the variable PATH in the SPARQL queries of SPARQL-based constraints @@ -1042,19 +1042,27 @@

Validation with SPARQL-based Constraints

TEXTUAL DEFINITION
- Let $sparql be a value of sh:sparql. - There are no validation results if the SPARQL-based constraint has true - as a value for the property sh:deactivated. - Otherwise, execute the SPARQL query specified by the SPARQL-based constraint $sparql - pre-binding the variable this as described in . - If the shape is a property shape, then prior to execution - substitute the variable PATH where it appears in the predicate - position of a triple pattern - with a valid SPARQL surface syntax string of the SHACL property path - specified via sh:path at the property shape. - There is one validation result for each solution that does not have true as the binding for the variable failure. - These validation results MUST have the property values explained in . - A failure MUST be produced if and only if one of the solutions has true as the binding for failure. +

+ Let $sparql be a value of sh:sparql. + There are no validation results if the SPARQL-based constraint has true + as a value for the property sh:deactivated. + Otherwise, execute the SPARQL query specified by the SPARQL-based constraint $sparql + pre-binding the variable this as described in . +

+

+ If the shape is a property shape, then prior to execution + substitute the variable PATH where it appears in the predicate + position of a triple pattern + with a valid SPARQL surface syntax string of the SHACL property path + specified via sh:path at the property shape. + If sh:path is not a well-formed SHACL property path then return an error, + and as a precaution may also substitute the signal value "BAD-PATH", which will make the SPARQL query invalid. +

+

+ There is one validation result for each solution that does not have true as the binding for the variable failure. + These validation results MUST have the property values explained in . + A failure MUST be produced if and only if one of the solutions has true as the binding for failure. +

@@ -1546,10 +1554,8 @@

Validation with SPARQL-based Constraint Components

  • For SELECT-based validators: If the shape is a property shape, then prior to execution - substitute the variable PATH where it appears in the predicate - position of a triple pattern - with a valid SPARQL surface syntax string of the SHACL property path - specified via sh:path at the property shape. + substitute the variable PATH with a valid SPARQL surface syntax string of the SHACL property path + (see the reference "substitute" for details). Let QS be the solutions produced by executing the SPARQL query.
  • @@ -2261,6 +2267,7 @@

    Security and Privacy Considerations

    SHACL-SPARQL includes all the security issues of SPARQL. + In particular, the substitution of variable PATH constitutes SPARQL string injection, which may pose additional risks.