-
Notifications
You must be signed in to change notification settings - Fork 1
/
excel_vocab_import_xl.pr
53 lines (52 loc) · 2.41 KB
/
excel_vocab_import_xl.pr
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
prefix : <http://purl.org/iow/Glossary#>
prefix grddl: <http://www.w3.org/2003/g/data-view#>
prefix owl: <http://www.w3.org/2002/07/owl#>
prefix skosxl: <http://www.w3.org/2008/05/skos-xl#>
prefix coda: <http://art.uniroma2.it/coda/contracts/>
prefix xsd: <http://www.w3.org/2001/XMLSchema#>
prefix fn: <http://www.w3.org/2005/xpath-functions#>
prefix skos: <http://www.w3.org/2004/02/skos/core#>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
prefix dct: <http://purl.org/dc/terms/>
prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
prefix sesame: <http://www.openrdf.org/schema/sesame#>
prefix dc: <http://purl.org/dc/elements/1.1/>
rule it.uniroma2.art.Sheet2RDFAnnotation id:row {
nodes = {
@Memoized
subject uri(coda:randIdGen('concept')) col0_Term/value .
col0_Term_lit_value literal@en col0_Term/value .
@Memoized
col0_Term_value uri(coda:randIdGen('xLabel', {lexicalForm = $col0_Term_lit_value})) col0_Term/value .
col1_Abbreviation_lit_value literal@en col1_Abbreviation/value .
@Memoized
col1_Abbreviation_value uri(coda:randIdGen('xLabel', {lexicalForm = $col1_Abbreviation_lit_value})) col1_Abbreviation/value .
col2_Definition_value literal@en col2_Definition/value .
col3_Theme1_value uri col3_Theme1/value .
col4_Theme2_value uri col4_Theme2/value .
col5_Theme3_value uri col5_Theme3/value .
col6_Theme4_value uri col6_Theme4/value .
col7_Theme5_value uri col7_Theme5/value .
col8_Comments_value literal col8_Comments/value .
}
graph = {
$subject rdf:type :Terms .
$subject rdf:type skos:Concept .
$subject skos:inScheme :epa-abg .
$subject skos:topConceptOf: :epa-abg .
OPTIONAL { $subject skosxl:prefLabel $col0_Term_value .
$col0_Term_value rdf:type skosxl:Label .
$col0_Term_value skosxl:literalForm $col0_Term_lit_value . }
OPTIONAL { $subject skosxl:altLabel $col1_Abbreviation_value .
$col1_Abbreviation_value rdf:type skosxl:Label .
$col1_Abbreviation_value skosxl:literalForm $col1_Abbreviation_lit_value . }
OPTIONAL { $subject skos:definition $col2_Definition_value . }
OPTIONAL { $subject skos:broader $col3_Theme1_value .
$col3_Theme1_value rdf:type skos:Concept . }
OPTIONAL { $subject skos:broader $col4_Theme2_value . }
OPTIONAL { $subject skos:broader $col5_Theme3_value . }
OPTIONAL { $subject skos:broader $col6_Theme4_value . }
OPTIONAL { $subject skos:broader $col7_Theme5_value . }
OPTIONAL { $subject rdfs:comment $col8_Comments_value . }
}
}