Skip to content

Commit

Permalink
Merge pull request #24 from LiUSemWeb/dev
Browse files Browse the repository at this point in the history
Add Files to Landing Page
  • Loading branch information
maike95 authored Dec 8, 2023
2 parents e1fbfc0 + 7b3310e commit 8d1fa30
Show file tree
Hide file tree
Showing 46 changed files with 195 additions and 107 deletions.
3 changes: 2 additions & 1 deletion page/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ <h3>Digital Product Passports</h3>
<a href="ontology/dpp-odp/0.1/dpp-odp.pdf">PDF</a>)
</div>
<div>
<a href="pdf/Information_per_R-Strategy.pdf">Information per R-Strategy</a>
<a href="pdf/Information_per_R-Strategy.pdf">Use case specific functional ontology requirements</a>
<a href="pdf/OntologyStories_CQs_SparqlQueries.pdf">Functional requirements verification (SPARQL queries)</a>
</div>
</div>
</div>
Expand Down
Binary file added page/pdf/OntologyStories_CQs_SparqlQueries.pdf
Binary file not shown.
1 change: 0 additions & 1 deletion shacl/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,4 @@ shapes:
shape: shapes/composition-information.ttl
valid:
- files/composition-information_valid1.ttl
- files/composition-information_valid2.ttl
invalid: []
10 changes: 7 additions & 3 deletions shacl/files/composition-information_valid1.ttl
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
@base <https://w3id.org/dppo/ontology/base/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dpp-info: <https://w3id.org/dppo/ontology/dpp-info/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

_:b a dpp-info:CompositionInformation .
_:b a dpp-comp:CompositionInformation ;
dpp-comp:aboutPart [ a dpp-odp:Product ] ;
dpp-comp:aboutWhole [ a dpp-odp:Product ] .
12 changes: 0 additions & 12 deletions shacl/files/composition-information_valid2.ttl

This file was deleted.

22 changes: 4 additions & 18 deletions shacl/files/dpp-information_valid1.ttl
Original file line number Diff line number Diff line change
@@ -1,25 +1,11 @@
@base <https://w3id.org/dppo/ontology/base/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

_:b a dpp-info:DPPInformation ;
dpp-info:hasTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-info:responsibleActor [ a dpp-prov:Actor ] .














dpp-info:startTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-prov:responsibleActor [ a dpp-prov:Actor ] .
16 changes: 8 additions & 8 deletions shacl/files/dpp-information_valid2.ttl
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
@base <https://w3id.org/dppo/ontology/base/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dpp-odp: <https://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-info: <https://w3id.org/dppo/ontology/dpp-info/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

_:b1 a dpp-info:DPPInformation ;
dpp-info:hasTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-info:hasInvalidTime "2023-11-25T11:34:00"^^xsd:dateTime ;
dpp-info:responsibleActor [ a dpp-prov:Actor ] ;
dpp-info:startTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-info:endTime "2023-11-25T11:34:00"^^xsd:dateTime ;
dpp-prov:responsibleActor [ a dpp-prov:Actor ] ;
dpp-info:superceededBy _:b2 .

_:b2 a dpp-info:DPPInformation ;
dpp-info:hasTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-info:responsibleActor [ a dpp-prov:Actor ] .
dpp-info:startTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-prov:responsibleActor [ a dpp-prov:Actor ] .
16 changes: 8 additions & 8 deletions shacl/files/dpp-information_valid3.ttl
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
@base <https://w3id.org/dppo/ontology/base/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dpp: <https://w3id.org/dppo/ontology/dpp/> .
@prefix dpp-odp: <https://w3id.org/dppo/ontology/dpp-odp/> .
@prefix info: <https://w3id.org/dppo/ontology/dpp-info/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

_:b1 a info:DPP_Information ;
info:hasTime "2023-11-24T11:34:00"^^xsd:dateTime ;
info:responsibleActor [ a info:Actor ] ;
info:about [ a dpp-odp:Product ] .
_:b1 a dpp-info:DPPInformation ;
dpp-info:startTime "2023-11-24T11:34:00"^^xsd:dateTime ;
dpp-prov:responsibleActor [ a dpp-prov:Actor ] ;
dpp-info:isAbout [ a dpp-odp:Product ] .
2 changes: 1 addition & 1 deletion shacl/files/dpp_valid1.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .

_:b a dpp-odp:DPP ;
_:dpp a dpp-odp:DPP ;
dpp-info:containsInformation [ a dpp-info:DPPInformation ] ;
dpp-odp:describes [ a dpp-odp:Product ] .
11 changes: 0 additions & 11 deletions shacl/files/product_invalid1.ttl

This file was deleted.

12 changes: 0 additions & 12 deletions shacl/files/product_invalid2.ttl

This file was deleted.

6 changes: 4 additions & 2 deletions shacl/files/product_valid1.ttl
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
@base <https://w3id.org/dppo/ontology/base/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dpp-odp: <https://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

_:b a dpp-odp:Product .
6 changes: 4 additions & 2 deletions shacl/files/product_valid2.ttl
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
@base <https://w3id.org/dppo/ontology/base/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dpp-odp: <https://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

_:b a dpp-odp:Product ;
dpp-odp:hasPart [ a dpp-odp:Product ] .
22 changes: 14 additions & 8 deletions shacl/shapes/composition-information.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,24 @@
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix dpp-odp: <https://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-info: <https://w3id.org/dppo/ontology/dpp-info/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

# CompositionInformation
# - (optional) dpp-info:aboutPart of type dpp-odp:Product
# - (optional) exactly 1 dpp-info:aboutWhole of type dpp-odp:Product
# - exactly 1 dpp-comp:aboutPart of type dpp-odp:Product
# - exactly 1 dpp-comp:aboutWhole of type dpp-odp:Product


<CompositionInformation-Shape>
a sh:NodeShape ;
sh:targetClass dpp-info:CompositionInformation ;
sh:property [ sh:path dpp-info:aboutPart ;
sh:class dpp-odp:Product ] ;
sh:property [ sh:path dpp-info:aboutWhole ;
sh:targetClass dpp-comp:CompositionInformation ;
sh:property [ sh:path dpp-comp:aboutPart ;
sh:class dpp-odp:Product ;
sh:minCount 1 ;
sh:maxCount 1 ] ;
sh:property [ sh:path dpp-comp:aboutWhole ;
sh:minCount 1 ;
sh:maxCount 1 ;
sh:class dpp-odp:Product ] .
36 changes: 19 additions & 17 deletions shacl/shapes/dpp-information.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,42 @@
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

# DPP Information
# - exactly 1 dpp-info:hasTime of type xsd:dateTime
# - (optional) exactly 1 dpp-info:hasInvalidTime of type xsd:dateTime
# - exactly 1 info:responsibleActor of type info:Actor
# - exactly 1 dpp-info:startTime of type xsd:dateTime
# - (optional) exactly 1 dpp-info:endTime of type xsd:dateTime
# - exactly 1 dpp-info:responsibleActor of type dpp-info:Actor
# - (optional) exactly 1 dpp-info:responsibleActor of type info:Actor
# - (optional) exactly 1 dpp-info:isAbout of type dpp-odp:Product

<DPPInformation-Shape>
a sh:NodeShape ;
sh:targetClass dpp-info:DPPInformation ;
sh:property [ sh:path dpp-info:hasTime ;
sh:property [ sh:path dpp-info:startTime ;
sh:minCount 1;
sh:maxCount 1;
sh:datatype xsd:dateTime ] ;
sh:property [ sh:path dpp-info:hasInvalidTime ;
sh:property [ sh:path dpp-info:endTime ;
sh:maxCount 1;
sh:datatype xsd:dateTime ] ;
sh:property [ sh:path dpp-info:responsibleActor ;
sh:minCount 1; sh:maxCount 1 ;
sh:class dpp-prov:Actor ] ;
sh:property [ sh:path dpp-info:superceededBy ;
sh:maxCount 1;
sh:class dpp-info:DPPInformation ] ;
sh:property [ sh:path dpp-info:about ;
sh:maxCount 1;
sh:class dpp-odp:Product ] ;
sh:property [ sh:path dpp-prov:responsibleActor ;
sh:minCount 1;
sh:maxCount 1 ;
sh:class dpp-prov:Actor ] ;
sh:property [ sh:path dpp-info:supersededBy ;
sh:maxCount 1;
sh:class dpp-info:DPPInformation ] ;
sh:property [ sh:path dpp-info:isAbout ;
sh:maxCount 1;
sh:class dpp-odp:Product ] ;
sh:or(
[ sh:path dpp-info:superceededBy ;
[ sh:path dpp-info:supersededBy ;
sh:maxCount 0 ]
[ sh:path dpp-info:hasInvalidTime ;
[ sh:path dpp-info:endTime ;
sh:minCount 1 ]
)
.
7 changes: 5 additions & 2 deletions shacl/shapes/dpp.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

# DPP
# - exactly 1 dpp-odp:describes of type dpp-odp:Product
# - min 1 info:containsInformation of type info:DPPInformation
# - min 1 dpp-info:containsInformation of type info:DPPInformation
# - (optional) dpp-odp:hasPart of type dpp:DPP

<DPP-Shape>
Expand All @@ -17,7 +19,8 @@
sh:minCount 1;
sh:class dpp-info:DPPInformation ] ;
sh:property [ sh:path dpp-odp:describes ;
sh:minCount 1; sh:maxCount 1;
sh:minCount 1;
sh:maxCount 1;
sh:class dpp-odp:Product ] ;
sh:property [ sh:path dpp-odp:hasPart ;
sh:class dpp-odp:DPP ] .
4 changes: 3 additions & 1 deletion shacl/shapes/product.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix dpp-info: <http://w3id.org/dppo/ontology/dpp-info/>.
@prefix dpp-odp: <http://w3id.org/dppo/ontology/dpp-odp/> .
@prefix dpp-prov: <http://w3id.org/dppo/ontology/dpp-prov/> .
@prefix dpp-comp: <http://w3id.org/dppo/ontology/dpp-comp/> .

# Product
# - (optional) dpp-odp:hasPart of type dpp-odp:Product
Expand All @@ -11,5 +14,4 @@
a sh:NodeShape ;
sh:targetClass dpp-odp:Product ;
sh:property [ sh:path dpp-odp:hasPart ;
sh:maxCount 1 ;
sh:class dpp-odp:Product ] .
7 changes: 7 additions & 0 deletions sparql/SPARQL_1.sparql
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# CQ: Does the product contain substances of concern?
# Products that contain substances of concern
SELECT DISTINCT ?product
WHERE {
?product a dpp-odp:Product ;
dpp-odp:hasPart/a/rdfs:subclassOf* dpp-comp:SubstanceOfConcern .
}
11 changes: 11 additions & 0 deletions sparql/SPARQL_10.sparql
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# CQ: What kind of additional information is provided (in terms of data source type)?
# Where to find this additional information?
SELECT ?product ?document ?actor
WHERE {
?dpp a/rdfs:subClassOf* dpp-odp:DPP ;
dpp-odp:describes ?product ;
dpp-odp:contains ?info .
?info a/rdfs:subClassOf* dpp-info:DPPInformation ;
dpp-prov:responsibleActor ?actor ;
dpp-info:externalDocument ?document .
}
24 changes: 24 additions & 0 deletions sparql/SPARQL_11.sparql
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# CQ: What is the meaning of a specific information within a DPP?
"# Find info, the type of the info, comments and whether the piece of information is still valid
SELECT ?dpp ?info ?class ?comment ?valid
WHERE {
?dpp a/rdfs:subClassOf* dpp-odp:DPP ;
dpp-odp:contains ?info .
?info a ?class
?class rdfs:subClassOf+ dpp-info:DPPInformation ;
rdfs:comment ?comment .
OPTIONAL { ?info dpp-info:hasInvalidTime ?invalidTime }
BIND(IF(BOUND(?invalidTime), ""no"", ""yes"") AS ?valid)
}

# Find info, the type of the info, its equivalent classes and whether the piece of information is still valid
SELECT ?dpp ?info ?class ?equivalentClass ?valid
WHERE {
?dpp a/rdfs:subClassOf* dpp-odp:DPP ;
dpp-odp:contains ?info .
?info a ?class .
?class rdfs:subClassOf+ dpp-info:DPPInformation ;
owl:equivalentClass ?equivalentClass .
OPTIONAL { ?info dpp-info:hasInvalidTime ?invalidTime }
BIND(IF(BOUND(?invalidTime), ""no"", ""yes"") AS ?valid)
}"´´
Empty file added sparql/SPARQL_12.sparql
Empty file.
Empty file added sparql/SPARQL_13.sparql
Empty file.
Empty file added sparql/SPARQL_14.sparql
Empty file.
Empty file added sparql/SPARQL_15.sparql
Empty file.
Empty file added sparql/SPARQL_16.sparql
Empty file.
Empty file added sparql/SPARQL_17.sparql
Empty file.
Empty file added sparql/SPARQL_18.sparql
Empty file.
Empty file added sparql/SPARQL_19.sparql
Empty file.
9 changes: 9 additions & 0 deletions sparql/SPARQL_2.sparql
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# CQ: If the product contains at least one substance of concern, how many and what kind of substances of concern?
# Number of distinct substances of concern per product
SELECT ?product (COUNT(DISTINCT ?substance) AS ?count)
WHERE {
?product a dpp-odp:Product ;
dpp-odp:hasPart ?substance .
?substance a/rdfs:subclassOf* dpp-comp:SubstanceOfConcern .
}
GROUP BY ?product
Empty file added sparql/SPARQL_20.sparql
Empty file.
Empty file added sparql/SPARQL_21.sparql
Empty file.
Empty file added sparql/SPARQL_22.sparql
Empty file.
Empty file added sparql/SPARQL_23.sparql
Empty file.
Empty file added sparql/SPARQL_24.sparql
Empty file.
Empty file added sparql/SPARQL_25.sparql
Empty file.
Empty file added sparql/SPARQL_26.sparql
Empty file.
Empty file added sparql/SPARQL_27.sparql
Empty file.
Empty file added sparql/SPARQL_28.sparql
Empty file.
Empty file added sparql/SPARQL_29.sparql
Empty file.
9 changes: 9 additions & 0 deletions sparql/SPARQL_3.sparql
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# CQ: If the product contains at least one substance of concern, how many and what kind of substances of concern?
# Kinds of substances of concern per product (exclude dpp-odp:SubstanceOfConcern)
SELECT ?product ?substance ?kind
WHERE {
?product a dpp-odp:Product ;
dpp-odp:hasPart ?substance .
?substance a ?kind .
?kind rdfs:subClassOf+ dpp-comp:SubstanceOfConcern .
}
Loading

0 comments on commit 8d1fa30

Please sign in to comment.