Skip to content

Latest commit

 

History

History
51 lines (40 loc) · 1.82 KB

File metadata and controls

51 lines (40 loc) · 1.82 KB

Find products for a given set of features combined

Description

A consumer is looking for a product and has a quite specific idea about what he wants, products that present a set of features.

The corresponding information need for the benchmark dataset is about a randomly selected product type from the product hierarchy (one level above leaf level), two different randomly selected product features that correspond to the chosen product type and that should be present simultaneously and a number between 1 and 500 for a numeric property.

Sample

"Look for products of type sheeny with product features stroboscopes and gadgeteers, and a productPropertyNumeric1 greater than 450".

Expected Outcome

Given the sample dataset bsbm-1000products, the product labels the user should obtain if restricted to the first 5 ordered alphabetically are:

"auditoriums reducing pappies" and "driveled".

SPARQL Query to Perform

SELECT DISTINCT ?product ?label
WHERE {
	?product rdfs:label ?label .
	?product a %ProductType% .
	?product bsbm:productFeature %ProductFeature1% .
	?product bsbm:productFeature %ProductFeature2% .
	?product bsbm:productPropertyNumeric1 ?value1 .
	FILTER (?value1 > %x%)
}
ORDER BY ?label
LIMIT 5

SPARQL Query for the Sample Query

PREFIX bsbm: <http://www4.wiwiss.fu-berlin.de/bizer/bsbm/v01/vocabulary/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT DISTINCT ?product ?label
WHERE {
	?product rdfs:label ?label .
	?product a/rdfs:subClassOf? ?sheenyType .
	?sheenyType rdfs:label "sheeny" .
	?product bsbm:productFeature [ rdfs:label "stroboscopes" ] .
	?product bsbm:productFeature [ rdfs:label "gadgeteers" ] .
	?product bsbm:productPropertyNumeric1 ?value1 .
	FILTER (?value1 > 450)
}
ORDER BY ?label
LIMIT 5