Skip to content

Commit

Permalink
verson configs & add 2.0 versions of each
Browse files Browse the repository at this point in the history
  • Loading branch information
elrayle committed Mar 11, 2019
1 parent 688fc27 commit 9fa6e0d
Show file tree
Hide file tree
Showing 90 changed files with 2,745 additions and 1 deletion.
125 changes: 125 additions & 0 deletions qa_agrovoc/2.0/config/authorities/linked_data/agrovoc_ld4l_cache.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
{
"QA_CONFIG_VERSION": "2.0",
"prefixes": {
"skos": "http://www.w3.org/2004/02/skos/core#"
},
"term": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "http://services.ld4l.org/ld4l_services/agrovoc_lookup.jsp?uri={term_uri}",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "term_uri",
"property": "hydra:freetextQuery",
"required": true,
"encode": true
}
]
},
"qa_replacement_patterns": {
"term_id": "term_uri"
},
"term_id": "URI",
"results": {
"label_predicate": "http://www.w3.org/2004/02/skos/core#prefLabel",
"altlabel_predicate": "http://www.w3.org/2004/02/skos/core#altLabel",
"broader_predicate": "http://www.w3.org/2004/02/skos/core#broader",
"narrower_predicate": "http://www.w3.org/2004/02/skos/core#narrower",
"sameas_predicate": "http://www.w3.org/2004/02/skos/core#exactMatch"
}
},
"search": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "http://services.ld4l.org/ld4l_services/agrovoc_batch.jsp?{?query}&{?maxRecords}&{?entity}&{?lang}",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "query",
"property": "hydra:freetextQuery",
"required": true
},
{
"@type": "IriTemplateMapping",
"variable": "entity",
"property": "hydra:freetextQuery",
"required": false,
"default": ""
},
{
"@type": "IriTemplateMapping",
"variable": "maxRecords",
"property": "hydra:freetextQuery",
"required": false,
"default": "20"
},
{
"@type": "IriTemplateMapping",
"variable": "lang",
"property": "hydra:freetextQuery",
"required": false,
"default": "en"
}
]
},
"qa_replacement_patterns": {
"query": "query",
"subauth": "entity"
},
"results": {
"label_predicate": "http://www.w3.org/2004/02/skos/core#prefLabel",
"sort_predicate": "http://vivoweb.org/ontology/core#rank"
},
"context": {
"groups": {
"hierarchy": {
"group_label_i18n": "qa.linked_data.authority.agrovoc_ld4l_cache.hierarchy",
"group_label_default": "Hierarchy"
}
},
"properties": [
{
"property_label_i18n": "qa.linked_data.authority.agrovoc_ld4l_cache.authoritative_label",
"property_label_default": "Authoritative Label",
"ldpath": "skos:prefLabel :: xsd:string",
"selectable": true,
"drillable": false
},
{
"group_id": "hierarchy",
"property_label_i18n": "qa.linked_data.authority.agrovoc_ld4l_cache.narrower",
"property_label_default": "Narrower",
"ldpath": "skos:narrower :: xsd:string",
"selectable": true,
"drillable": true,
"expansion_label_ldpath": "skos:prefLabel ::xsd:string",
"expansion_id_ldpath": "loc:lccn ::xsd:string"
},
{
"group_id": "hierarchy",
"property_label_i18n": "qa.linked_data.authority.agrovoc_ld4l_cache.broader",
"property_label_default": "Broader",
"ldpath": "skos:broader :: xsd:string",
"selectable": true,
"drillable": true,
"expansion_label_ldpath": "skos:prefLabel ::xsd:string",
"expansion_id_ldpath": "loc:lccn ::xsd:string"
}
]
},
"subauthorities": {
"person": "Person",
"organization": "Organization",
"place": "Place",
"intangible": "Intangible",
"geocoordinates": "GeoCoordinates",
"work": "Work"
}
}
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
authority:
service: ld4l_cache
search:
-
query: milk
term:
-
identifier: 'http://aims.fao.org/aos/agrovoc/c_9513'
37 changes: 37 additions & 0 deletions qa_dbpedia/2.0/config/authorities/linked_data/dbpedia_direct.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
"QA_CONFIG_VERSION": "2.0",
"term": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "{term_uri}?locale={lang}",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "term_uri",
"property": "hydra:freetextQuery",
"required": true,
"encode": false
},
{
"@type": "IriTemplateMapping",
"variable": "lang",
"property": "hydra:freetextQuery",
"required": false,
"default": "en"
}
]
},
"qa_replacement_patterns": {
"term_id": "term_uri"
},
"language": ["en"],
"term_id": "URI",
"results": {
"label_predicate": "http://www.w3.org/2000/01/rdf-schema#label",
"sameas_predicate": "http://www.w3.org/2002/07/owl#sameAs"
}
},
"search": {}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
{
"QA_CONFIG_VERSION": "2.0",
"term": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "http://services.ld4l.org/ld4l_services/dbpedia_name_lookup.jsp?uri={term_uri}",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "term_uri",
"property": "hydra:freetextQuery",
"required": true,
"encode": true
}
]
},
"qa_replacement_patterns": {
"term_id": "term_uri"
},
"language": "en",
"term_id": "URI",
"results": {
"label_predicate": "http://dbpedia.org/property/name",
"sameas_predicate": "http://www.w3.org/2002/07/owl#sameAs"
}
},
"search": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "http://services.ld4l.org/ld4l_services/dbpedia_name_batch.jsp?{?entity}&{?query}&{?maxRecords}&{?lang}",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "query",
"property": "hydra:freetextQuery",
"required": true
},
{
"@type": "IriTemplateMapping",
"variable": "entity",
"property": "hydra:freetextQuery",
"required": false,
"default": ""
},
{
"@type": "IriTemplateMapping",
"variable": "maxRecords",
"property": "hydra:freetextQuery",
"required": false,
"default": "20"
},
{
"@type": "IriTemplateMapping",
"variable": "lang",
"property": "hydra:freetextQuery",
"required": false,
"default": "en"
}
]
},
"qa_replacement_patterns": {
"query": "query",
"subauth": "entity"
},
"language": ["en"],
"results": {
"id_predicate": "http://dbpedia.org/property/id",
"label_predicate": "http://dbpedia.org/property/name",
"sort_predicate": "http://vivoweb.org/ontology/core#rank"
},
"subauthorities": {
"person": "Person",
"organization": "Organization",
"place": "Place",
"intangible": "Intangible",
"geocoordinates": "GeoCoordinates",
"work": "Work"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
authority:
service: direct
term:
-
identifier: 'http://dbpedia.org/resource/Barack_Obama'
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
authority:
service: ld4l_cache
search:
-
query: 'Barack Obama'
term:
-
identifier: 'http://dbpedia.org/resource/Barack_Obama'
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
{
"QA_CONFIG_VERSION": "2.0",
"term": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "{term_uri}",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "term_uri",
"property": "hydra:freetextQuery",
"required": true,
"encode": false
}
]
},
"qa_replacement_patterns": {
"term_id": "term_uri"
},
"term_id": "URI",
"results": {
"label_predicate": "http://www.geonames.org/ontology#name",
"altlabel_predicate": "http://www.geonames.org/ontology#countryCode",
"broader_predicate": "http://www.geonames.org/ontology#parentFeature",
"sameas_predicate": "http://www.w3.org/2000/01/rdf-schema#seeAlso"
}
},
"search": {
"url": {
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"@type": "IriTemplate",
"template": "http://api.geonames.org/search?q={query}&maxRows={maximumRecords}&{?username}&type=rdf",
"variableRepresentation": "BasicRepresentation",
"mapping": [
{
"@type": "IriTemplateMapping",
"variable": "query",
"property": "hydra:freetextQuery",
"required": true
},
{
"@type": "IriTemplateMapping",
"variable": "username",
"property": "hydra:freetextQuery",
"required": false,
"default": "YOUR_GEONAMES_USERNAME"
},
{
"@type": "IriTemplateMapping",
"variable": "maximumRecords",
"property": "hydra:freetextQuery",
"required": false,
"default": "10"
}
]
},
"qa_replacement_patterns": {
"query": "query"
},
"language": ["en"],
"results": {
"label_predicate": "http://www.geonames.org/ontology#name",
"altlabel_predicate": "http://www.geonames.org/ontology#countryCode",
"sort_predicate": "http://www.geonames.org/ontology#name"
}
}
}
Loading

0 comments on commit 9fa6e0d

Please sign in to comment.