-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathmetadata.ttl
58 lines (56 loc) · 2.22 KB
/
metadata.ttl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# baseURI: http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/metadata
# imports: http://onto.fel.cvut.cz/ontologies/s-pipes-lib
# imports: http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/identification
@prefix : <http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/metadata/> .
@prefix doc: <http://onto.fel.cvut.cz/ontologies/documentation/> .
@prefix kbss-module: <http://onto.fel.cvut.cz/ontologies/lib/module/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix sk-id: <http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/identification/> .
@prefix sk-meta: <http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/metadata/> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix sm: <http://topbraid.org/sparqlmotion#> .
@prefix sml: <http://topbraid.org/sparqlmotionlib#> .
@prefix sp: <http://spinrdf.org/sp#> .
@prefix spif: <http://spinrdf.org/spif#> .
@prefix spin: <http://spinrdf.org/spin#> .
@prefix spl: <http://spinrdf.org/spl#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
sk-id:identify-concepts
sm:next sk-meta:construct-labels ;
.
<http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/metadata>
a owl:Ontology ;
rdfs:comment "Collection of SPipes modules related to SKOS concept metadata description from OWL ontology" ;
owl:imports <http://onto.fel.cvut.cz/ontologies/s-pipes-lib> ;
owl:imports <http://onto.fel.cvut.cz/ontologies/s-pipes/skosify-example-0.1/identification> ;
.
sk-meta:bind-prefered-label-property
a sml:BindWithConstant ;
sm:next sk-meta:construct-labels ;
sm:outputVariable "prefLabelProperty" ;
sml:value [
a sp:coalesce ;
sp:arg1 [
sp:varName "prefLabelProperty" ;
] ;
sp:arg2 rdfs:label ;
] ;
rdfs:label "Bind preferred label property" ;
.
sk-meta:construct-labels
a sml:ApplyConstruct ;
sml:constructQuery [
a sp:Construct ;
sp:text """CONSTRUCT {
?concept skos:prefLabel ?label .
} WHERE {
?concept a skos:Concept .
?concept ?prefLabelProperty ?label .
}
""" ;
] ;
sml:replace true ;
rdfs:label "Construct concept labels" ;
.