-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproducts.rml.ttl
210 lines (209 loc) · 7.37 KB
/
products.rml.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
@prefix rr: <http://www.w3.org/ns/r2rml#>.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
@prefix fnml: <http://semweb.mmlab.be/ns/fnml#>.
@prefix fno: <https://w3id.org/function/ontology#>.
@prefix d2rq: <http://www.wiwiss.fu-berlin.de/suhl/bizer/D2RQ/0.1#>.
@prefix void: <http://rdfs.org/ns/void#>.
@prefix dc: <http://purl.org/dc/terms/>.
@prefix foaf: <http://xmlns.com/foaf/0.1/>.
@prefix rml: <http://semweb.mmlab.be/ns/rml#>.
@prefix ql: <http://semweb.mmlab.be/ns/ql#>.
@prefix : <http://mapping.example.com/>.
@prefix owl: <http://www.w3.org/2002/07/owl#>.
@prefix xsd: <http://www.w3.org/2001/XMLSchema#>.
@prefix grel: <http://users.ugent.be/~bjdmeest/function/grel.ttl#>.
@prefix schema: <https://schema.org/>.
@prefix dbo: <http://dbpedia.org/ontology/>.
@prefix fo: <https://www.bbc.co.uk/ontologies/fo/>.
@prefix rev: <http://purl.org/stuff/rev#>.
@prefix wd: <https://www.wikidata.org/wiki/>.
@prefix food: <http://data.lirmm.fr/ontologies/food#>.
@prefix ex: <http://example.org/>.
@prefix essglobal: <http://purl.org/essglobal/vocab/>.
@prefix ken: <https://w3id.org/um/ken4256/>.
:rules_000 a void:Dataset;
void:exampleResource :map_recipe_000.
:map_recipe_000 rml:logicalSource :source_000.
:source_000 a rml:LogicalSource;
rml:source "products.json";
rml:iterator "$.products[*]";
rml:referenceFormulation ql:JSONPath.
:map_recipe_000 a rr:TriplesMap;
rdfs:label "recipe".
:s_000 a rr:SubjectMap.
:map_recipe_000 rr:subjectMap :s_000.
:s_000 rr:template "https://w3id.org/um/ken4256/product/{code}".
:pom_000 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_000.
:pm_000 a rr:PredicateMap.
:pom_000 rr:predicateMap :pm_000.
:pm_000 rr:constant rdf:type.
:pom_000 rr:objectMap :om_000.
:om_000 a rr:ObjectMap;
rr:constant "https://schema.org/Product";
rr:termType rr:IRI.
:pom_001 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_001.
:pm_001 a rr:PredicateMap.
:pom_001 rr:predicateMap :pm_001.
:pm_001 rr:constant rdfs:label.
:pom_001 rr:objectMap :om_001.
:om_001 a rr:ObjectMap;
rml:reference "product_name";
rr:termType rr:Literal.
:pom_002 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_002.
:pm_002 a rr:PredicateMap.
:pom_002 rr:predicateMap :pm_002.
:pm_002 rr:constant ken:mainCategory.
:pom_002 rr:objectMap :om_002.
:om_002 a rr:ObjectMap;
rr:template "https://w3id.org/um/ken4256/category/{main_category}";
rr:termType rr:IRI.
:pom_003 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_003.
:pm_003 a rr:PredicateMap.
:pom_003 rr:predicateMap :pm_003.
:pm_003 rr:constant fo:shopping_category.
:pom_003 rr:objectMap :om_003.
:om_003 a rr:ObjectMap;
rr:template "https://w3id.org/um/ken4256/category/{categories}";
rr:termType rr:IRI.
:pom_004 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_004.
:pm_004 a rr:PredicateMap.
:pom_004 rr:predicateMap :pm_004.
:pm_004 rr:constant essglobal:isAvailableAt.
:pom_004 rr:objectMap :om_004.
:om_004 a rr:ObjectMap;
rr:template "https://w3id.org/um/ken4256/country/{countries}";
rr:termType rr:IRI.
:pom_005 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_005.
:pm_005 a rr:PredicateMap.
:pom_005 rr:predicateMap :pm_005.
:pm_005 rr:constant fo:ingredients.
:pom_005 rr:objectMap :om_005.
:om_005 a rr:ObjectMap;
rr:template "https://w3id.org/um/ken4256/ingredient/{ingredients}";
rr:termType rr:IRI.
:pom_006 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_006.
:pm_006 a rr:PredicateMap.
:pom_006 rr:predicateMap :pm_006.
:pm_006 rr:constant food:nutritionScoreFrPer100g.
:pom_006 rr:objectMap :om_006.
:om_006 a rr:ObjectMap;
rr:template "https://w3id.org/um/ken4256/nutriscore/{nutriscore_grade}";
rr:termType rr:IRI.
:pom_007 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_007.
:pm_007 a rr:PredicateMap.
:pom_007 rr:predicateMap :pm_007.
:pm_007 rr:constant schema:calories.
:pom_007 rr:objectMap :om_007.
:om_007 a rr:ObjectMap;
rml:reference "energy_kcal_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_008 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_008.
:pm_008 a rr:PredicateMap.
:pom_008 rr:predicateMap :pm_008.
:pm_008 rr:constant schema:fiberContent.
:pom_008 rr:objectMap :om_008.
:om_008 a rr:ObjectMap;
rml:reference "fat_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_009 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_009.
:pm_009 a rr:PredicateMap.
:pom_009 rr:predicateMap :pm_009.
:pm_009 rr:constant schema:unsaturatedFatContent.
:pom_009 rr:objectMap :om_009.
:om_009 a rr:ObjectMap;
rml:reference "saturated_fat_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_010 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_010.
:pm_010 a rr:PredicateMap.
:pom_010 rr:predicateMap :pm_010.
:pm_010 rr:constant schema:transFatContent.
:pom_010 rr:objectMap :om_010.
:om_010 a rr:ObjectMap;
rml:reference "trans_fat_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_011 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_011.
:pm_011 a rr:PredicateMap.
:pom_011 rr:predicateMap :pm_011.
:pm_011 rr:constant schema:cholesterolContent.
:pom_011 rr:objectMap :om_011.
:om_011 a rr:ObjectMap;
rml:reference "cholesterol_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_012 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_012.
:pm_012 a rr:PredicateMap.
:pom_012 rr:predicateMap :pm_012.
:pm_012 rr:constant schema:carbohydrateContent.
:pom_012 rr:objectMap :om_012.
:om_012 a rr:ObjectMap;
rml:reference "carbohydrates_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_013 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_013.
:pm_013 a rr:PredicateMap.
:pom_013 rr:predicateMap :pm_013.
:pm_013 rr:constant schema:sugarContent.
:pom_013 rr:objectMap :om_013.
:om_013 a rr:ObjectMap;
rml:reference "sugars_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_014 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_014.
:pm_014 a rr:PredicateMap.
:pom_014 rr:predicateMap :pm_014.
:pm_014 rr:constant schema:fiberContent.
:pom_014 rr:objectMap :om_014.
:om_014 a rr:ObjectMap;
rml:reference "fiber_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_015 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_015.
:pm_015 a rr:PredicateMap.
:pom_015 rr:predicateMap :pm_015.
:pm_015 rr:constant schema:proteinContent.
:pom_015 rr:objectMap :om_015.
:om_015 a rr:ObjectMap;
rml:reference "proteins_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_016 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_016.
:pm_016 a rr:PredicateMap.
:pom_016 rr:predicateMap :pm_016.
:pm_016 rr:constant food:saltPer100g.
:pom_016 rr:objectMap :om_016.
:om_016 a rr:ObjectMap;
rml:reference "salt_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.
:pom_017 a rr:PredicateObjectMap.
:map_recipe_000 rr:predicateObjectMap :pom_017.
:pm_017 a rr:PredicateMap.
:pom_017 rr:predicateMap :pm_017.
:pm_017 rr:constant schema:sodiumContent.
:pom_017 rr:objectMap :om_017.
:om_017 a rr:ObjectMap;
rml:reference "sodium_100g";
rr:termType rr:Literal;
rr:datatype xsd:decimal.