SPARQL with fulltext search -based Reconciliation

For detailed example and screenshots see Reconciling universities against the New York Time RDF data

SPARQL fulltext search extensions are provided by a number of vendors (e.g. LARQ and Virtuoso). Giving the absence of standardisation, each vendor uses its own proprietary syntax to express full-text search queries. Currently, we support LARQ, Virtuoso and BigOWLIM (limited support see the related issue).

The examples below show a sample SPARQL queries

LARQ query with labeling property is: rdfs:label
Input: label="Galway"

	PREFIX rdfs:<http://www.w3.org/2000/01/rdf-schema#> 
	PREFIX pf:<http://jena.hpl.hp.com/ARQ/property#> 
	SELECT ?entity ?label (MAX(?score) AS ?score1) 
	WHERE{
		?entity <http://www.w3.org/2000/01/rdf-schema#label> ?label.
		(?label ?score) pf:textMatch 'Galway'.
	}GROUP BY ?entity ?label
	ORDER BY DESC(?score1) LIMIT 3
		
Virtuoso query with labeling property is: rdfs:label and skos:prefLabel and type is restricted to either dbo:PopulatedPlace or yago:Locations
Input: label="Galway", type= {"<http://dbpedia.org/ontology/PopulatedPlace>","<http://dbpedia.org/class/yago/Locations>"}

	SELECT DISTINCT ?entity ?label ?score1
	WHERE{
		?entity ?p ?label.
		?label <bif:contains> "'Galway'" OPTION(score ?score1). 
		FILTER (?p=<http://www.w3.org/2000/01/rdf-schema#label> || 
		        ?p=<http://www.w3.org/2004/02/skos/core#prefLabel>). 
		?entity a ?type.
		FILTER (?type IN (<http://dbpedia.org/ontology/PopulatedPlace>, 
		                   <http://dbpedia.org/class/yago/Locations>)).
		FILTER isIRI(?entity). 
	} ORDER BY desc(?score1) LIMIT 6
		
Property autocompletion using LARQ
Input: "nam"

	PREFIX pf: 
	SELECT DISTINCT ?p ?label1 ?score1 ?label2 ?score2 
	WHERE{
		[] ?p ?v.
		{
			OPTIONAL {
				?p  ?label1.
				(?label1 ?score1) pf:textMatch 'nam*'. 
			}
			OPTIONAL {
				?p  ?label2. 
			(?label2 ?score2) pf:textMatch 'nam*'. 
			}
			FILTER (bound(?label1) || bound(?label2))
		}
	} ORDER BY desc(?score1) LIMIT 10