Skip to content

Commit

Permalink
Add updated shape from skohub/shapes repo
Browse files Browse the repository at this point in the history
  • Loading branch information
sroertgen committed Apr 23, 2024
1 parent d28480c commit cd4b4d7
Showing 1 changed file with 47 additions and 17 deletions.
64 changes: 47 additions & 17 deletions shapes/skohub.shacl.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
@prefix dct: <http://purl.org/dc/terms/> .
@prefix sdo: <https://schema.org> .
@prefix vann: <http://purl.org/vocab/vann/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

# rdfs:comment holds info with what file under ./tests/invalid/skohub.shacl.ttl
# the constraint is tested
Expand All @@ -17,14 +18,32 @@
:ConceptSchemeShape
a sh:NodeShape ;
sh:targetClass skos:ConceptScheme ;
sh:property [
sh:path dct:title ;
sh:minCount 1;
sh:datatype rdf:langString ;
sh:message "Concept Scheme has no dct:title with a language tag!" ;
sh:severity sh:Violation ;
rdfs:comment "Tested with 01_cs_no_title.ttl" ;
] ;
sh:or (
[
sh:path dct:title ;
sh:minCount 1;
sh:datatype rdf:langString ;
sh:message "Concept Scheme has no dct:title with a language tag!" ;
sh:severity sh:Violation ;
rdfs:comment "Tested with 01_cs_no_title.ttl" ;
]
[
sh:path skos:prefLabel ;
sh:minCount 1;
sh:datatype rdf:langString ;
sh:message "Concept Scheme has no skos:prefLabel with a language tag!" ;
sh:severity sh:Violation ;
rdfs:comment "Tested with 01_cs_no_title.ttl" ;
]
[
sh:path dc:title ;
sh:minCount 1;
sh:datatype rdf:langString ;
sh:message "Concept Scheme has no dc:title with a language tag!" ;
sh:severity sh:Violation ;
rdfs:comment "Tested with 01_cs_no_title.ttl" ;
]
);
sh:property [
sh:path skos:hasTopConcept ;
sh:minCount 1 ;
Expand All @@ -40,15 +59,26 @@
sh:message "The target class for hasTopConcept should be skos:Concept" ;
rdfs:comment "Tested with 03_cs_target_class_hasTopConcept.ttl" ;
] ;
sh:property [
sh:path dct:description ;
sh:datatype rdf:langString ;
sh:severity sh:Warning ;
sh:minCount 1 ;
sh:message: "A description of the Concept Scheme should be provided." ;
rdfs:comment "Tested with 04_cs_no_description.ttl" ;
rdfs:comment "Tested with 05_cs_description_no_langstring.ttl" ;
] ;
sh:or (
[
sh:path dct:description ;
sh:datatype rdf:langString ;
sh:severity sh:Warning ;
sh:minCount 1 ;
sh:message: "A description of the Concept Scheme should be provided." ;
rdfs:comment "Tested with 04_cs_no_description.ttl" ;
rdfs:comment "Tested with 05_cs_description_no_langstring.ttl" ;
]
[
sh:path dc:description ;
sh:datatype rdf:langString ;
sh:severity sh:Warning ;
sh:minCount 1 ;
sh:message: "A description of the Concept Scheme should be provided." ;
rdfs:comment "Tested with 04_cs_no_description.ttl" ;
rdfs:comment "Tested with 05_cs_description_no_langstring.ttl" ;
]
) ;
sh:property [
sh:path dct:license ;
sh:minCount 1 ;
Expand Down

0 comments on commit cd4b4d7

Please sign in to comment.