glossarist 2.8.18 → 2.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop_todo.yml +175 -8
- data/Rakefile +4 -0
- data/config.yml +2 -3
- data/data/concept-model/README.md +35 -0
- data/data/concept-model/SOURCE.json +5 -0
- data/data/concept-model/glossarist.context.jsonld +209 -0
- data/data/concept-model/glossarist.ttl +960 -0
- data/data/concept-model/shapes/glossarist.shacl.ttl +575 -0
- data/glossarist.gemspec +2 -0
- data/lib/glossarist/asset_reference.rb +2 -0
- data/lib/glossarist/bibliographic_reference.rb +13 -0
- data/lib/glossarist/cli/export_command.rb +130 -7
- data/lib/glossarist/cli.rb +11 -2
- data/lib/glossarist/concept_document.rb +13 -0
- data/lib/glossarist/concept_reference.rb +6 -0
- data/lib/glossarist/concept_store.rb +2 -3
- data/lib/glossarist/dataset_register.rb +2 -2
- data/lib/glossarist/figure_reference.rb +0 -4
- data/lib/glossarist/formula_reference.rb +0 -4
- data/lib/glossarist/non_verbal_reference.rb +10 -0
- data/lib/glossarist/rdf/gloss_detailed_definition.rb +6 -1
- data/lib/glossarist/rdf/gloss_localized_concept.rb +65 -0
- data/lib/glossarist/rdf/lutaml_ext.rb +33 -0
- data/lib/glossarist/rdf.rb +2 -0
- data/lib/glossarist/reference.rb +33 -0
- data/lib/glossarist/table_reference.rb +0 -4
- data/lib/glossarist/tasks/shacl.rake +30 -0
- data/lib/glossarist/tasks/sync.rake +14 -0
- data/lib/glossarist/tasks/sync_model.rb +92 -0
- data/lib/glossarist/transforms/concept_to_gloss_transform.rb +3 -2
- data/lib/glossarist/utilities/uuid.rb +5 -1
- data/lib/glossarist/validation/rules/related_concept_cycle_rule.rb +15 -1
- data/lib/glossarist/validation/shacl_validator.rb +97 -0
- data/lib/glossarist/validation.rb +1 -0
- data/lib/glossarist/version.rb +1 -1
- data/lib/glossarist.rb +1 -0
- metadata +41 -2
|
@@ -0,0 +1,575 @@
|
|
|
1
|
+
# Glossarist SHACL Shapes
|
|
2
|
+
#
|
|
3
|
+
# Validation shapes for the Glossarist ontology.
|
|
4
|
+
# Validates instance data against the ontology constraints.
|
|
5
|
+
#
|
|
6
|
+
# Requires: SHACL vocabulary (http://www.w3.org/ns/shacl#)
|
|
7
|
+
|
|
8
|
+
@prefix gloss: <https://www.glossarist.org/ontologies/> .
|
|
9
|
+
@prefix sh: <http://www.w3.org/ns/shacl#> .
|
|
10
|
+
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
|
|
11
|
+
@prefix xl: <http://www.w3.org/2008/05/skos-xl#> .
|
|
12
|
+
@prefix dcterms: <http://purl.org/dc/terms/> .
|
|
13
|
+
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
|
|
14
|
+
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
|
|
15
|
+
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
|
|
16
|
+
|
|
17
|
+
# ══════════════════════════════════════════════════════════════════════════
|
|
18
|
+
# Concept shapes
|
|
19
|
+
# ══════════════════════════════════════════════════════════════════════════
|
|
20
|
+
|
|
21
|
+
gloss:ConceptShape a sh:NodeShape ;
|
|
22
|
+
sh:targetClass gloss:Concept ;
|
|
23
|
+
sh:class skos:Concept ;
|
|
24
|
+
sh:property [
|
|
25
|
+
sh:path gloss:identifier ;
|
|
26
|
+
sh:datatype xsd:string ;
|
|
27
|
+
sh:minCount 1 ;
|
|
28
|
+
sh:maxCount 1 ;
|
|
29
|
+
] ;
|
|
30
|
+
sh:property [
|
|
31
|
+
sh:path gloss:uri ;
|
|
32
|
+
sh:datatype xsd:anyURI ;
|
|
33
|
+
sh:maxCount 1 ;
|
|
34
|
+
] ;
|
|
35
|
+
sh:property [
|
|
36
|
+
sh:path gloss:hasLocalization ;
|
|
37
|
+
sh:class gloss:LocalizedConcept ;
|
|
38
|
+
] ;
|
|
39
|
+
sh:property [
|
|
40
|
+
sh:path gloss:hasStatus ;
|
|
41
|
+
sh:class skos:Concept ;
|
|
42
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/conceptstatus> ;
|
|
43
|
+
sh:maxCount 1 ;
|
|
44
|
+
] ;
|
|
45
|
+
sh:property [
|
|
46
|
+
sh:path gloss:hasRelatedConcept ;
|
|
47
|
+
sh:class gloss:RelatedConcept ;
|
|
48
|
+
] ;
|
|
49
|
+
sh:property [
|
|
50
|
+
sh:path gloss:hasDate ;
|
|
51
|
+
sh:class gloss:ConceptDate ;
|
|
52
|
+
] ;
|
|
53
|
+
sh:property [
|
|
54
|
+
sh:path gloss:hasSource ;
|
|
55
|
+
sh:class gloss:ConceptSource ;
|
|
56
|
+
] ;
|
|
57
|
+
sh:property [
|
|
58
|
+
sh:path gloss:hasDomain ;
|
|
59
|
+
sh:class gloss:Reference ;
|
|
60
|
+
] ;
|
|
61
|
+
sh:property [
|
|
62
|
+
sh:path gloss:tag ;
|
|
63
|
+
sh:datatype xsd:string ;
|
|
64
|
+
] .
|
|
65
|
+
|
|
66
|
+
gloss:LocalizedConceptShape a sh:NodeShape ;
|
|
67
|
+
sh:targetClass gloss:LocalizedConcept ;
|
|
68
|
+
sh:class skos:Concept ;
|
|
69
|
+
sh:property [
|
|
70
|
+
sh:path gloss:isLocalizationOf ;
|
|
71
|
+
sh:class gloss:Concept ;
|
|
72
|
+
sh:minCount 1 ;
|
|
73
|
+
sh:maxCount 1 ;
|
|
74
|
+
] ;
|
|
75
|
+
sh:property [
|
|
76
|
+
sh:path gloss:language ;
|
|
77
|
+
sh:datatype xsd:string ;
|
|
78
|
+
sh:maxCount 1 ;
|
|
79
|
+
] ;
|
|
80
|
+
sh:property [
|
|
81
|
+
sh:path gloss:hasDesignation ;
|
|
82
|
+
sh:class gloss:Designation ;
|
|
83
|
+
] ;
|
|
84
|
+
sh:property [
|
|
85
|
+
sh:path gloss:hasDefinition ;
|
|
86
|
+
sh:class gloss:DetailedDefinition ;
|
|
87
|
+
] ;
|
|
88
|
+
sh:property [
|
|
89
|
+
sh:path gloss:hasNote ;
|
|
90
|
+
sh:class gloss:DetailedDefinition ;
|
|
91
|
+
] ;
|
|
92
|
+
sh:property [
|
|
93
|
+
sh:path gloss:hasExample ;
|
|
94
|
+
sh:class gloss:DetailedDefinition ;
|
|
95
|
+
] ;
|
|
96
|
+
sh:property [
|
|
97
|
+
sh:path gloss:hasEntryStatus ;
|
|
98
|
+
sh:class skos:Concept ;
|
|
99
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/entstatus> ;
|
|
100
|
+
sh:maxCount 1 ;
|
|
101
|
+
] ;
|
|
102
|
+
sh:property [
|
|
103
|
+
sh:path gloss:hasRelatedConcept ;
|
|
104
|
+
sh:class gloss:RelatedConcept ;
|
|
105
|
+
] ;
|
|
106
|
+
sh:property [
|
|
107
|
+
sh:path gloss:hasDate ;
|
|
108
|
+
sh:class gloss:ConceptDate ;
|
|
109
|
+
] ;
|
|
110
|
+
sh:property [
|
|
111
|
+
sh:path gloss:hasSource ;
|
|
112
|
+
sh:class gloss:ConceptSource ;
|
|
113
|
+
] ;
|
|
114
|
+
sh:property [
|
|
115
|
+
sh:path gloss:hasReference ;
|
|
116
|
+
sh:class gloss:Reference ;
|
|
117
|
+
] ;
|
|
118
|
+
sh:property [
|
|
119
|
+
sh:path gloss:classification ;
|
|
120
|
+
sh:datatype xsd:string ;
|
|
121
|
+
sh:maxCount 1 ;
|
|
122
|
+
] ;
|
|
123
|
+
sh:property [
|
|
124
|
+
sh:path gloss:domain ;
|
|
125
|
+
sh:datatype xsd:anyURI ;
|
|
126
|
+
sh:maxCount 1 ;
|
|
127
|
+
] ;
|
|
128
|
+
sh:property [
|
|
129
|
+
sh:path gloss:script ;
|
|
130
|
+
sh:datatype xsd:string ;
|
|
131
|
+
sh:maxCount 1 ;
|
|
132
|
+
] ;
|
|
133
|
+
sh:property [
|
|
134
|
+
sh:path gloss:conversionSystem ;
|
|
135
|
+
sh:datatype xsd:string ;
|
|
136
|
+
sh:maxCount 1 ;
|
|
137
|
+
] ;
|
|
138
|
+
sh:property [
|
|
139
|
+
sh:path gloss:release ;
|
|
140
|
+
sh:datatype xsd:string ;
|
|
141
|
+
sh:maxCount 1 ;
|
|
142
|
+
] ;
|
|
143
|
+
sh:property [
|
|
144
|
+
sh:path gloss:lineageSimilarity ;
|
|
145
|
+
sh:datatype xsd:integer ;
|
|
146
|
+
sh:maxCount 1 ;
|
|
147
|
+
] ;
|
|
148
|
+
sh:property [
|
|
149
|
+
sh:path gloss:reviewType ;
|
|
150
|
+
sh:datatype xsd:string ;
|
|
151
|
+
sh:maxCount 1 ;
|
|
152
|
+
sh:in ( "editorial" "substantive" ) ;
|
|
153
|
+
] .
|
|
154
|
+
|
|
155
|
+
gloss:ConceptCollectionShape a sh:NodeShape ;
|
|
156
|
+
sh:targetClass gloss:ConceptCollection ;
|
|
157
|
+
sh:class skos:Collection ;
|
|
158
|
+
sh:property [
|
|
159
|
+
sh:path skos:member ;
|
|
160
|
+
sh:class gloss:Concept ;
|
|
161
|
+
] ;
|
|
162
|
+
sh:property [
|
|
163
|
+
sh:path dcterms:title ;
|
|
164
|
+
sh:datatype xsd:string ;
|
|
165
|
+
sh:maxCount 1 ;
|
|
166
|
+
] .
|
|
167
|
+
|
|
168
|
+
# ══════════════════════════════════════════════════════════════════════════
|
|
169
|
+
# Designation shapes
|
|
170
|
+
# ══════════════════════════════════════════════════════════════════════════
|
|
171
|
+
|
|
172
|
+
gloss:DesignationShape a sh:NodeShape ;
|
|
173
|
+
sh:targetClass gloss:Designation ;
|
|
174
|
+
sh:class xl:Label ;
|
|
175
|
+
sh:property [
|
|
176
|
+
sh:path xl:literalForm ;
|
|
177
|
+
sh:minCount 1 ;
|
|
178
|
+
sh:maxCount 1 ;
|
|
179
|
+
] ;
|
|
180
|
+
sh:property [
|
|
181
|
+
sh:path gloss:normativeStatus ;
|
|
182
|
+
sh:class skos:Concept ;
|
|
183
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/norm> ;
|
|
184
|
+
sh:maxCount 1 ;
|
|
185
|
+
] ;
|
|
186
|
+
sh:property [
|
|
187
|
+
sh:path gloss:hasTermType ;
|
|
188
|
+
sh:class skos:Concept ;
|
|
189
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/termtype> ;
|
|
190
|
+
sh:maxCount 1 ;
|
|
191
|
+
] ;
|
|
192
|
+
sh:property [
|
|
193
|
+
sh:path gloss:hasRelatedConcept ;
|
|
194
|
+
sh:class gloss:RelatedConcept ;
|
|
195
|
+
] ;
|
|
196
|
+
sh:property [
|
|
197
|
+
sh:path gloss:hasSource ;
|
|
198
|
+
sh:class gloss:ConceptSource ;
|
|
199
|
+
] ;
|
|
200
|
+
sh:property [
|
|
201
|
+
sh:path gloss:hasPronunciation ;
|
|
202
|
+
sh:class gloss:Pronunciation ;
|
|
203
|
+
] ;
|
|
204
|
+
sh:property [
|
|
205
|
+
sh:path gloss:language ;
|
|
206
|
+
sh:datatype xsd:string ;
|
|
207
|
+
sh:maxCount 1 ;
|
|
208
|
+
] ;
|
|
209
|
+
sh:property [
|
|
210
|
+
sh:path gloss:script ;
|
|
211
|
+
sh:datatype xsd:string ;
|
|
212
|
+
sh:maxCount 1 ;
|
|
213
|
+
] ;
|
|
214
|
+
sh:property [
|
|
215
|
+
sh:path gloss:conversionSystem ;
|
|
216
|
+
sh:datatype xsd:string ;
|
|
217
|
+
sh:maxCount 1 ;
|
|
218
|
+
] ;
|
|
219
|
+
sh:property [
|
|
220
|
+
sh:path gloss:isInternational ;
|
|
221
|
+
sh:datatype xsd:boolean ;
|
|
222
|
+
sh:maxCount 1 ;
|
|
223
|
+
] ;
|
|
224
|
+
sh:property [
|
|
225
|
+
sh:path gloss:isAbsent ;
|
|
226
|
+
sh:datatype xsd:boolean ;
|
|
227
|
+
sh:maxCount 1 ;
|
|
228
|
+
] ;
|
|
229
|
+
sh:property [
|
|
230
|
+
sh:path gloss:register ;
|
|
231
|
+
sh:datatype xsd:string ;
|
|
232
|
+
sh:maxCount 1 ;
|
|
233
|
+
] .
|
|
234
|
+
|
|
235
|
+
gloss:ExpressionShape a sh:NodeShape ;
|
|
236
|
+
sh:targetClass gloss:Expression ;
|
|
237
|
+
sh:property [
|
|
238
|
+
sh:path gloss:hasGrammarInfo ;
|
|
239
|
+
sh:class gloss:GrammarInfo ;
|
|
240
|
+
] .
|
|
241
|
+
|
|
242
|
+
gloss:AbbreviationShape a sh:NodeShape ;
|
|
243
|
+
sh:targetClass gloss:Abbreviation ;
|
|
244
|
+
sh:property [
|
|
245
|
+
sh:path gloss:isAcronym ;
|
|
246
|
+
sh:datatype xsd:boolean ;
|
|
247
|
+
sh:maxCount 1 ;
|
|
248
|
+
] ;
|
|
249
|
+
sh:property [
|
|
250
|
+
sh:path gloss:isInitialism ;
|
|
251
|
+
sh:datatype xsd:boolean ;
|
|
252
|
+
sh:maxCount 1 ;
|
|
253
|
+
] ;
|
|
254
|
+
sh:property [
|
|
255
|
+
sh:path gloss:isTruncation ;
|
|
256
|
+
sh:datatype xsd:boolean ;
|
|
257
|
+
sh:maxCount 1 ;
|
|
258
|
+
] .
|
|
259
|
+
|
|
260
|
+
gloss:SymbolShape a sh:NodeShape ;
|
|
261
|
+
sh:targetClass gloss:Symbol .
|
|
262
|
+
|
|
263
|
+
gloss:LetterSymbolShape a sh:NodeShape ;
|
|
264
|
+
sh:targetClass gloss:LetterSymbol ;
|
|
265
|
+
sh:property [
|
|
266
|
+
sh:path gloss:text ;
|
|
267
|
+
sh:datatype xsd:string ;
|
|
268
|
+
sh:maxCount 1 ;
|
|
269
|
+
] .
|
|
270
|
+
|
|
271
|
+
gloss:GraphicalSymbolShape a sh:NodeShape ;
|
|
272
|
+
sh:targetClass gloss:GraphicalSymbol ;
|
|
273
|
+
sh:property [
|
|
274
|
+
sh:path gloss:text ;
|
|
275
|
+
sh:datatype xsd:string ;
|
|
276
|
+
sh:maxCount 1 ;
|
|
277
|
+
] ;
|
|
278
|
+
sh:property [
|
|
279
|
+
sh:path gloss:image ;
|
|
280
|
+
sh:datatype xsd:anyURI ;
|
|
281
|
+
sh:maxCount 1 ;
|
|
282
|
+
] .
|
|
283
|
+
|
|
284
|
+
gloss:PrefixShape a sh:NodeShape ;
|
|
285
|
+
sh:targetClass gloss:Prefix .
|
|
286
|
+
|
|
287
|
+
gloss:SuffixShape a sh:NodeShape ;
|
|
288
|
+
sh:targetClass gloss:Suffix .
|
|
289
|
+
|
|
290
|
+
# ══════════════════════════════════════════════════════════════════════════
|
|
291
|
+
# Supporting class shapes
|
|
292
|
+
# ══════════════════════════════════════════════════════════════════════════
|
|
293
|
+
|
|
294
|
+
gloss:PronunciationShape a sh:NodeShape ;
|
|
295
|
+
sh:targetClass gloss:Pronunciation ;
|
|
296
|
+
sh:property [
|
|
297
|
+
sh:path gloss:pronunciationContent ;
|
|
298
|
+
sh:datatype xsd:string ;
|
|
299
|
+
sh:minCount 1 ;
|
|
300
|
+
sh:maxCount 1 ;
|
|
301
|
+
] ;
|
|
302
|
+
sh:property [
|
|
303
|
+
sh:path gloss:pronunciationLanguage ;
|
|
304
|
+
sh:datatype xsd:string ;
|
|
305
|
+
sh:maxCount 1 ;
|
|
306
|
+
] ;
|
|
307
|
+
sh:property [
|
|
308
|
+
sh:path gloss:pronunciationScript ;
|
|
309
|
+
sh:datatype xsd:string ;
|
|
310
|
+
sh:maxCount 1 ;
|
|
311
|
+
] ;
|
|
312
|
+
sh:property [
|
|
313
|
+
sh:path gloss:pronunciationCountry ;
|
|
314
|
+
sh:datatype xsd:string ;
|
|
315
|
+
sh:maxCount 1 ;
|
|
316
|
+
] ;
|
|
317
|
+
sh:property [
|
|
318
|
+
sh:path gloss:pronunciationSystem ;
|
|
319
|
+
sh:datatype xsd:string ;
|
|
320
|
+
sh:maxCount 1 ;
|
|
321
|
+
] .
|
|
322
|
+
|
|
323
|
+
gloss:DetailedDefinitionShape a sh:NodeShape ;
|
|
324
|
+
sh:targetClass gloss:DetailedDefinition ;
|
|
325
|
+
sh:property [
|
|
326
|
+
sh:path rdf:value ;
|
|
327
|
+
sh:minCount 1 ;
|
|
328
|
+
sh:maxCount 1 ;
|
|
329
|
+
] ;
|
|
330
|
+
sh:property [
|
|
331
|
+
sh:path gloss:hasSource ;
|
|
332
|
+
sh:class gloss:ConceptSource ;
|
|
333
|
+
] .
|
|
334
|
+
|
|
335
|
+
gloss:ConceptSourceShape a sh:NodeShape ;
|
|
336
|
+
sh:targetClass gloss:ConceptSource ;
|
|
337
|
+
sh:property [
|
|
338
|
+
sh:path gloss:sourceType ;
|
|
339
|
+
sh:class skos:Concept ;
|
|
340
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/srctype> ;
|
|
341
|
+
sh:maxCount 1 ;
|
|
342
|
+
] ;
|
|
343
|
+
sh:property [
|
|
344
|
+
sh:path gloss:sourceStatus ;
|
|
345
|
+
sh:class skos:Concept ;
|
|
346
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/srcstatus> ;
|
|
347
|
+
sh:maxCount 1 ;
|
|
348
|
+
] ;
|
|
349
|
+
sh:property [
|
|
350
|
+
sh:path gloss:sourceOrigin ;
|
|
351
|
+
sh:class gloss:Citation ;
|
|
352
|
+
sh:maxCount 1 ;
|
|
353
|
+
] ;
|
|
354
|
+
sh:property [
|
|
355
|
+
sh:path gloss:modification ;
|
|
356
|
+
sh:datatype xsd:string ;
|
|
357
|
+
sh:maxCount 1 ;
|
|
358
|
+
] .
|
|
359
|
+
|
|
360
|
+
gloss:ConceptDateShape a sh:NodeShape ;
|
|
361
|
+
sh:targetClass gloss:ConceptDate ;
|
|
362
|
+
sh:property [
|
|
363
|
+
sh:path gloss:dateValue ;
|
|
364
|
+
sh:datatype xsd:dateTime ;
|
|
365
|
+
sh:minCount 1 ;
|
|
366
|
+
sh:maxCount 1 ;
|
|
367
|
+
] ;
|
|
368
|
+
sh:property [
|
|
369
|
+
sh:path gloss:dateType ;
|
|
370
|
+
sh:class skos:Concept ;
|
|
371
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/datetype> ;
|
|
372
|
+
sh:minCount 1 ;
|
|
373
|
+
sh:maxCount 1 ;
|
|
374
|
+
] ;
|
|
375
|
+
sh:property [
|
|
376
|
+
sh:path gloss:eventDescription ;
|
|
377
|
+
sh:datatype xsd:string ;
|
|
378
|
+
sh:maxCount 1 ;
|
|
379
|
+
] .
|
|
380
|
+
|
|
381
|
+
gloss:NonVerbalRepresentationShape a sh:NodeShape ;
|
|
382
|
+
sh:targetClass gloss:NonVerbalRepresentation ;
|
|
383
|
+
sh:property [
|
|
384
|
+
sh:path gloss:representationType ;
|
|
385
|
+
sh:datatype xsd:string ;
|
|
386
|
+
sh:minCount 1 ;
|
|
387
|
+
sh:maxCount 1 ;
|
|
388
|
+
sh:in ( "image" "table" "formula" ) ;
|
|
389
|
+
] ;
|
|
390
|
+
sh:property [
|
|
391
|
+
sh:path gloss:representationRef ;
|
|
392
|
+
sh:datatype xsd:anyURI ;
|
|
393
|
+
sh:minCount 1 ;
|
|
394
|
+
sh:maxCount 1 ;
|
|
395
|
+
] ;
|
|
396
|
+
sh:property [
|
|
397
|
+
sh:path gloss:hasSource ;
|
|
398
|
+
sh:class gloss:ConceptSource ;
|
|
399
|
+
] .
|
|
400
|
+
|
|
401
|
+
gloss:ReferenceShape a sh:NodeShape ;
|
|
402
|
+
sh:targetClass gloss:Reference ;
|
|
403
|
+
sh:or (
|
|
404
|
+
[ sh:property [ sh:path gloss:source ; sh:minCount 1 ] ]
|
|
405
|
+
[ sh:property [ sh:path gloss:refId ; sh:minCount 1 ] ]
|
|
406
|
+
) ;
|
|
407
|
+
sh:property [
|
|
408
|
+
sh:path gloss:source ;
|
|
409
|
+
sh:datatype xsd:string ;
|
|
410
|
+
sh:maxCount 1 ;
|
|
411
|
+
] ;
|
|
412
|
+
sh:property [
|
|
413
|
+
sh:path gloss:refId ;
|
|
414
|
+
sh:datatype xsd:string ;
|
|
415
|
+
sh:maxCount 1 ;
|
|
416
|
+
] ;
|
|
417
|
+
sh:property [
|
|
418
|
+
sh:path gloss:refVersion ;
|
|
419
|
+
sh:datatype xsd:string ;
|
|
420
|
+
sh:maxCount 1 ;
|
|
421
|
+
] ;
|
|
422
|
+
sh:property [
|
|
423
|
+
sh:path gloss:refLink ;
|
|
424
|
+
sh:datatype xsd:anyURI ;
|
|
425
|
+
sh:maxCount 1 ;
|
|
426
|
+
] ;
|
|
427
|
+
sh:property [
|
|
428
|
+
sh:path gloss:refType ;
|
|
429
|
+
sh:datatype xsd:string ;
|
|
430
|
+
sh:maxCount 1 ;
|
|
431
|
+
] ;
|
|
432
|
+
sh:property [
|
|
433
|
+
sh:path gloss:urn ;
|
|
434
|
+
sh:datatype xsd:anyURI ;
|
|
435
|
+
sh:maxCount 1 ;
|
|
436
|
+
] ;
|
|
437
|
+
sh:property [
|
|
438
|
+
sh:path gloss:term ;
|
|
439
|
+
sh:datatype xsd:string ;
|
|
440
|
+
sh:maxCount 1 ;
|
|
441
|
+
] ;
|
|
442
|
+
sh:property [
|
|
443
|
+
sh:path gloss:hasLocality ;
|
|
444
|
+
sh:class gloss:Locality ;
|
|
445
|
+
sh:maxCount 1 ;
|
|
446
|
+
] .
|
|
447
|
+
|
|
448
|
+
gloss:LocalityShape a sh:NodeShape ;
|
|
449
|
+
sh:targetClass gloss:Locality ;
|
|
450
|
+
sh:property [
|
|
451
|
+
sh:path gloss:localityType ;
|
|
452
|
+
sh:datatype xsd:string ;
|
|
453
|
+
sh:minCount 1 ;
|
|
454
|
+
sh:maxCount 1 ;
|
|
455
|
+
] ;
|
|
456
|
+
sh:property [
|
|
457
|
+
sh:path gloss:referenceFrom ;
|
|
458
|
+
sh:datatype xsd:string ;
|
|
459
|
+
sh:maxCount 1 ;
|
|
460
|
+
] ;
|
|
461
|
+
sh:property [
|
|
462
|
+
sh:path gloss:referenceTo ;
|
|
463
|
+
sh:datatype xsd:string ;
|
|
464
|
+
sh:maxCount 1 ;
|
|
465
|
+
] .
|
|
466
|
+
|
|
467
|
+
gloss:CitationShape a sh:NodeShape ;
|
|
468
|
+
sh:targetClass gloss:Citation ;
|
|
469
|
+
sh:property [
|
|
470
|
+
sh:path gloss:hasCitationRef ;
|
|
471
|
+
sh:class gloss:CitationRef ;
|
|
472
|
+
sh:maxCount 1 ;
|
|
473
|
+
] ;
|
|
474
|
+
sh:property [
|
|
475
|
+
sh:path gloss:hasCitationLocality ;
|
|
476
|
+
sh:class gloss:Locality ;
|
|
477
|
+
sh:maxCount 1 ;
|
|
478
|
+
] ;
|
|
479
|
+
sh:property [
|
|
480
|
+
sh:path gloss:citationLink ;
|
|
481
|
+
sh:datatype xsd:anyURI ;
|
|
482
|
+
sh:maxCount 1 ;
|
|
483
|
+
] ;
|
|
484
|
+
sh:property [
|
|
485
|
+
sh:path gloss:citationOriginal ;
|
|
486
|
+
sh:datatype xsd:string ;
|
|
487
|
+
sh:maxCount 1 ;
|
|
488
|
+
] ;
|
|
489
|
+
sh:property [
|
|
490
|
+
sh:path gloss:hasCustomLocality ;
|
|
491
|
+
sh:class gloss:CustomLocality ;
|
|
492
|
+
] .
|
|
493
|
+
|
|
494
|
+
gloss:CitationRefShape a sh:NodeShape ;
|
|
495
|
+
sh:targetClass gloss:CitationRef ;
|
|
496
|
+
sh:property [
|
|
497
|
+
sh:path gloss:citationRefSource ;
|
|
498
|
+
sh:datatype xsd:string ;
|
|
499
|
+
sh:maxCount 1 ;
|
|
500
|
+
] ;
|
|
501
|
+
sh:property [
|
|
502
|
+
sh:path gloss:citationRefId ;
|
|
503
|
+
sh:datatype xsd:string ;
|
|
504
|
+
sh:maxCount 1 ;
|
|
505
|
+
] ;
|
|
506
|
+
sh:property [
|
|
507
|
+
sh:path gloss:citationRefVersion ;
|
|
508
|
+
sh:datatype xsd:string ;
|
|
509
|
+
sh:maxCount 1 ;
|
|
510
|
+
] .
|
|
511
|
+
|
|
512
|
+
gloss:ConceptRefShape a sh:NodeShape ;
|
|
513
|
+
sh:targetClass gloss:ConceptRef ;
|
|
514
|
+
sh:property [
|
|
515
|
+
sh:path gloss:conceptRefSource ;
|
|
516
|
+
sh:datatype xsd:string ;
|
|
517
|
+
sh:maxCount 1 ;
|
|
518
|
+
] ;
|
|
519
|
+
sh:property [
|
|
520
|
+
sh:path gloss:conceptRefId ;
|
|
521
|
+
sh:datatype xsd:string ;
|
|
522
|
+
sh:maxCount 1 ;
|
|
523
|
+
] .
|
|
524
|
+
|
|
525
|
+
gloss:CustomLocalityShape a sh:NodeShape ;
|
|
526
|
+
sh:targetClass gloss:CustomLocality ;
|
|
527
|
+
sh:property [
|
|
528
|
+
sh:path gloss:customLocalityName ;
|
|
529
|
+
sh:datatype xsd:string ;
|
|
530
|
+
sh:minCount 1 ;
|
|
531
|
+
sh:maxCount 1 ;
|
|
532
|
+
] ;
|
|
533
|
+
sh:property [
|
|
534
|
+
sh:path gloss:customLocalityValue ;
|
|
535
|
+
sh:datatype xsd:string ;
|
|
536
|
+
sh:minCount 1 ;
|
|
537
|
+
sh:maxCount 1 ;
|
|
538
|
+
] .
|
|
539
|
+
|
|
540
|
+
gloss:RelatedConceptShape a sh:NodeShape ;
|
|
541
|
+
sh:targetClass gloss:RelatedConcept ;
|
|
542
|
+
sh:property [
|
|
543
|
+
sh:path gloss:relationshipType ;
|
|
544
|
+
sh:class skos:Concept ;
|
|
545
|
+
sh:minCount 1 ;
|
|
546
|
+
sh:maxCount 1 ;
|
|
547
|
+
] ;
|
|
548
|
+
sh:property [
|
|
549
|
+
sh:path gloss:relationshipRef ;
|
|
550
|
+
sh:class gloss:ConceptRef ;
|
|
551
|
+
sh:maxCount 1 ;
|
|
552
|
+
] ;
|
|
553
|
+
sh:property [
|
|
554
|
+
sh:path gloss:relationshipContent ;
|
|
555
|
+
sh:datatype xsd:string ;
|
|
556
|
+
sh:maxCount 1 ;
|
|
557
|
+
] .
|
|
558
|
+
|
|
559
|
+
gloss:GrammarInfoShape a sh:NodeShape ;
|
|
560
|
+
sh:targetClass gloss:GrammarInfo ;
|
|
561
|
+
sh:property [
|
|
562
|
+
sh:path gloss:gender ;
|
|
563
|
+
sh:class skos:Concept ;
|
|
564
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/gender> ;
|
|
565
|
+
] ;
|
|
566
|
+
sh:property [
|
|
567
|
+
sh:path gloss:number ;
|
|
568
|
+
sh:class skos:Concept ;
|
|
569
|
+
sh:valuesFrom <https://www.glossarist.org/ontologies/number> ;
|
|
570
|
+
] ;
|
|
571
|
+
sh:property [
|
|
572
|
+
sh:path gloss:partOfSpeech ;
|
|
573
|
+
sh:datatype xsd:string ;
|
|
574
|
+
sh:maxCount 1 ;
|
|
575
|
+
] .
|
data/glossarist.gemspec
CHANGED
|
@@ -34,8 +34,10 @@ Gem::Specification.new do |spec|
|
|
|
34
34
|
spec.add_dependency "lutaml-model", "~> 0.8.15"
|
|
35
35
|
spec.add_dependency "lutaml-store", "~> 0.2.0"
|
|
36
36
|
spec.add_dependency "paint", "~> 2.3"
|
|
37
|
+
spec.add_dependency "rdf-turtle", "~> 3.3"
|
|
37
38
|
spec.add_dependency "relaton", ">= 2.0.0", "< 3"
|
|
38
39
|
spec.add_dependency "rubyzip", ">= 2.3", "< 3"
|
|
40
|
+
spec.add_dependency "shacl", "~> 0.4"
|
|
39
41
|
spec.add_dependency "sts", "~> 0.5.6"
|
|
40
42
|
spec.add_dependency "table_tennis", "~> 0.0"
|
|
41
43
|
spec.add_dependency "tbx", "~> 0.1"
|
|
@@ -1,7 +1,20 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
module Glossarist
|
|
4
|
+
# A reference to a bibliographic entry (an external document), distinct from
|
|
5
|
+
# a ConceptReference (a cross-reference to another concept in the same or
|
|
6
|
+
# another registry).
|
|
7
|
+
#
|
|
8
|
+
# BibliographicReference is produced by ReferenceExtractor from AsciiDoc
|
|
9
|
+
# <<anchor>> xrefs and from model-level source citations. It participates
|
|
10
|
+
# in the {Reference} protocol so validation rules iterating mixed reference
|
|
11
|
+
# collections can call `cite?` / `local?` / `external?` without
|
|
12
|
+
# type-checking. All three predicates default to false (a bibliographic
|
|
13
|
+
# reference is never an inline `{{cite:id}}` mention, never a concept
|
|
14
|
+
# cross-ref).
|
|
4
15
|
class BibliographicReference
|
|
16
|
+
include Reference
|
|
17
|
+
|
|
5
18
|
attr_reader :anchor, :location
|
|
6
19
|
|
|
7
20
|
def initialize(anchor:, location: nil)
|