Simple Question (Direct)
Simple Question
Q1324230
P47
Q20667921
USER
Which french administrative divisions are bordered by Tuzaguet ?
(Q1324230,P47,c(Q20667921))
action filter_type
action find
entity Q1324230
relation P47
type Q20667921
['Q1324230', 'P47', {'concept': 'Q20667921'}]
SELECT DISTINCT ?u WHERE { resource:Q1324230 property:P47 ?u . ?u rdf:type ontology:Q20667921 }
Tuzaguet
action filter_type
action find
entity Tuzaguet
relation shares border with
type type of french administrative division
['Tuzaguet', 'shares border with', {'concept': 'type of french administrative division'}]
SELECT DISTINCT ?u WHERE { resource:Tuzaguet property:shares_border_with ?u . ?u rdf:type ontology:type_of_french_administrative_division }
[]
type of french administrative division
Q1324947 Q680437 Q1326647
SYSTEM
Saint-Laurent-de-Neste, Montoussé, Cantaous
Q1324947 Q680437 Q636110 Q1326647 Q1447277 Q1092959
(Q1324230,P47,c(Q20667921))
action filter_type
action find
entity Q1324230
relation P47
type Q20667921
[ANSWERS] are bordered by Tuzaguet
['Q1324230', 'P47', {'concept': 'Q20667921'}]
SELECT DISTINCT ?u WHERE { resource:Q1324230 property:P47 ?u . ?u rdf:type ontology:Q20667921 }
Saint-Laurent-de-Neste Montoussé Anères Cantaous Escala Bizous
Saint-Laurent-de-Neste, Montoussé and Cantaous are bordered by Tuzaguet
Saint-Laurent-de-Neste Montoussé Cantaous
action filter_type
action find
entity Tuzaguet
relation shares border with
type type of french administrative division
['Tuzaguet', 'shares border with', {'concept': 'type of french administrative division'}]
SELECT DISTINCT ?u WHERE { resource:Tuzaguet property:shares_border_with ?u . ?u rdf:type ontology:type_of_french_administrative_division }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q1324947
P1376
Q20667921
USER
Which french administrative division has Saint-Laurent-de-Neste has its first city ?
(Q1324947,P1376,c(Q20667921))
action filter_type
action find
entity Q1324947
relation P1376
type Q20667921
['Q1324947', 'P1376', {'concept': 'Q20667921'}]
SELECT DISTINCT ?k WHERE { resource:Q1324947 property:P1376 ?k . ?k rdf:type ontology:Q20667921 }
Saint-Laurent-de-Neste
action filter_type
action find
entity Saint-Laurent-de-Neste
relation capital of
type type of french administrative division
['Saint-Laurent-de-Neste', 'capital of', {'concept': 'type of french administrative division'}]
SELECT DISTINCT ?k WHERE { resource:Saint-Laurent-de-Neste property:capital_of ?k . ?k rdf:type ontology:type_of_french_administrative_division }
[]
type of french administrative division
Q737325
SYSTEM
canton of Saint-Laurent-de-Neste
Q737325
(Q1324947,P1376,c(Q20667921))
action filter_type
action find
entity Q1324947
relation P1376
type Q20667921
The [ANSWER] has Saint-Laurent-de-Neste has its first city
['Q1324947', 'P1376', {'concept': 'Q20667921'}]
SELECT DISTINCT ?k WHERE { resource:Q1324947 property:P1376 ?k . ?k rdf:type ontology:Q20667921 }
canton of Saint-Laurent-de-Neste
The canton of Saint-Laurent-de-Neste has Saint-Laurent-de-Neste has its first city
canton of Saint-Laurent-de-Neste
action filter_type
action find
entity Saint-Laurent-de-Neste
relation capital of
type type of french administrative division
['Saint-Laurent-de-Neste', 'capital of', {'concept': 'type of french administrative division'}]
SELECT DISTINCT ?k WHERE { resource:Saint-Laurent-de-Neste property:capital_of ?k . ?k rdf:type ontology:type_of_french_administrative_division }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q1324947
P36
Q20667921
USER
Which french administrative division contains Saint-Laurent-de-Neste as its capital ?
(c(Q20667921),P36,Q1324947)
action filter_type
action find_reverse
entity Q1324947
relation P36
type Q20667921
[{'concept': 'Q20667921'}, 'P36', 'Q1324947']
SELECT DISTINCT ?l WHERE { ?l rdf:type ontology:Q20667921 . ?l property:P36 resource:Q1324947 }
Saint-Laurent-de-Neste
action filter_type
action find_reverse
entity Saint-Laurent-de-Neste
relation capital
type type of french administrative division
[{'concept': 'type of french administrative division'}, 'capital', 'Saint-Laurent-de-Neste']
SELECT DISTINCT ?l WHERE { ?l rdf:type ontology:type_of_french_administrative_division . ?l property:capital resource:Saint-Laurent-de-Neste }
[]
type of french administrative division
Q737325
SYSTEM
canton of Saint-Laurent-de-Neste
Q737325
(c(Q20667921),P36,Q1324947)
action filter_type
action find_reverse
entity Q1324947
relation P36
type Q20667921
The [ANSWER] contains Saint-Laurent-de-Neste as its capital
[{'concept': 'Q20667921'}, 'P36', 'Q1324947']
SELECT DISTINCT ?l WHERE { ?l rdf:type ontology:Q20667921 . ?l property:P36 resource:Q1324947 }
canton of Saint-Laurent-de-Neste
The canton of Saint-Laurent-de-Neste contains Saint-Laurent-de-Neste as its capital
canton of Saint-Laurent-de-Neste
action filter_type
action find_reverse
entity Saint-Laurent-de-Neste
relation capital
type type of french administrative division
[{'concept': 'type of french administrative division'}, 'capital', 'Saint-Laurent-de-Neste']
SELECT DISTINCT ?l WHERE { ?l rdf:type ontology:type_of_french_administrative_division . ?l property:capital resource:Saint-Laurent-de-Neste }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q1324230
P19
Q502895
USER
Who was born at Tuzaguet ?
(c(Q502895),P19,Q1324230)
action filter_type
action find_reverse
entity Q1324230
relation P19
type Q502895
[{'concept': 'Q502895'}, 'P19', 'Q1324230']
SELECT DISTINCT ?d WHERE { ?d property:P19 resource:Q1324230 . ?d rdf:type ontology:Q502895 }
Tuzaguet
action filter_type
action find_reverse
entity Tuzaguet
relation place of birth
type common name
[{'concept': 'common name'}, 'place of birth', 'Tuzaguet']
SELECT DISTINCT ?d WHERE { ?d property:place_of_birth resource:Tuzaguet . ?d rdf:type ontology:common_name }
[]
common name
Q16025705
SYSTEM
Léopold Dasque
Q16025705
(c(Q502895),P19,Q1324230)
action filter_type
action find_reverse
entity Q1324230
relation P19
type Q502895
[ANSWER] was born at Tuzaguet
[{'concept': 'Q502895'}, 'P19', 'Q1324230']
SELECT DISTINCT ?d WHERE { ?d property:P19 resource:Q1324230 . ?d rdf:type ontology:Q502895 }
Léopold Dasque
Léopold Dasque was born at Tuzaguet
Léopold Dasque
action filter_type
action find_reverse
entity Tuzaguet
relation place of birth
type common name
[{'concept': 'common name'}, 'place of birth', 'Tuzaguet']
SELECT DISTINCT ?d WHERE { ?d property:place_of_birth resource:Tuzaguet . ?d rdf:type ontology:common_name }
[]
Simple Question (Coreferenced)
Simple Question|Single Entity|Indirect
Q1324230
P17
Q15617994
USER
Which administrative territory does that french administrative division belong to ?
(Q16025705,P17,c(Q15617994))
action filter_type
action find
entity Q1324230
relation P17
type Q15617994
['Q16025705', 'P17', {'concept': 'Q15617994'}]
SELECT DISTINCT ?d WHERE { resource:Q1324230 property:P17 ?d . ?d rdf:type ontology:Q15617994 }
Tuzaguet
action filter_type
action find
entity Tuzaguet
relation country
type designation for an administrative territorial entity
['Léopold Dasque', 'country', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ?d WHERE { resource:Tuzaguet property:country ?d . ?d rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q142
SYSTEM
France
Q142
(Q16025705,P17,c(Q15617994))
action filter_type
action find
entity Q1324230
relation P17
type Q15617994
That french administrative division belongs to the [ANSWER]
['Q16025705', 'P17', {'concept': 'Q15617994'}]
SELECT DISTINCT ?d WHERE { resource:Q1324230 property:P17 ?d . ?d rdf:type ontology:Q15617994 }
France
That french administrative division belongs to the France
France
action filter_type
action find
entity Tuzaguet
relation country
type designation for an administrative territorial entity
['Léopold Dasque', 'country', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ?d WHERE { resource:Tuzaguet property:country ?d . ?d rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q660904 Q1324947
P17
Q15617994
USER
Which administrative territories are Saint-Laurent-de-Neste or Bonnevaux situated in ?
OR((Q1324947,P17,c(Q15617994)), (Q660904,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q1324947
relation P17
action find
entity Q660904
relation P17
type Q15617994
{'OR': [['Q1324947', 'P17', {'concept': 'Q15617994'}], ['Q660904', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?a WHERE { { VALUES ( ?s ) { ( resource:Q1324947 ) ( resource:Q660904 ) } . ?s property:P17 ?a } . ?a rdf:type ontology:Q15617994 }
Bonnevaux Saint-Laurent-de-Neste
action filter_type
action union
action find
entity Saint-Laurent-de-Neste
relation country
action find
entity Bonnevaux
relation country
type designation for an administrative territorial entity
{'OR': [['Saint-Laurent-de-Neste', 'country', {'concept': 'designation for an administrative territorial entity'}], ['Bonnevaux', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?a WHERE { { VALUES ( ?s ) { ( resource:Saint-Laurent-de-Neste ) ( resource:Bonnevaux ) } . ?s property:country ?a } . ?a rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q142
SYSTEM
France
Q142
OR((Q1324947,P17,c(Q15617994)), (Q660904,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q1324947
relation P17
action find
entity Q660904
relation P17
type Q15617994
Saint-Laurent-de-Neste or Bonnevaux are situated in [ANSWER]
{'OR': [['Q1324947', 'P17', {'concept': 'Q15617994'}], ['Q660904', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?a WHERE { { VALUES ( ?s ) { ( resource:Q1324947 ) ( resource:Q660904 ) } . ?s property:P17 ?a } . ?a rdf:type ontology:Q15617994 }
France
Saint-Laurent-de-Neste or Bonnevaux are situated in France
France
action filter_type
action union
action find
entity Saint-Laurent-de-Neste
relation country
action find
entity Bonnevaux
relation country
type designation for an administrative territorial entity
{'OR': [['Saint-Laurent-de-Neste', 'country', {'concept': 'designation for an administrative territorial entity'}], ['Bonnevaux', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?a WHERE { { VALUES ( ?s ) { ( resource:Saint-Laurent-de-Neste ) ( resource:Bonnevaux ) } . ?s property:country ?a } . ?a rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Verification (Boolean) (All)
Verification|3 entities, 2 direct, 2(direct) are query entities, subject is indirect
Q142 Q12950 Q20876306
P35
Q502895
USER
Is Alain Poher and Carles Maristany i Benito the head of state of Q142 ?
(Q142,P35,Q12950) (Q142,P35,Q20876306)
action is_in
entity Q142
action intersection
action find_reverse
entity Q12950
relation P35
action find_reverse
entity Q20876306
relation P35
['Q142', 'P35', 'Q12950'] ['Q142', 'P35', 'Q20876306']
ASK WHERE { resource:Q142 property:P35 resource:Q12950 . resource:Q142 property:P35 resource:Q20876306 }
France Alain Poher Carles Maristany i Benito
action is_in
entity France
action intersection
action find_reverse
entity Alain Poher
relation head of state
action find_reverse
entity Carles Maristany i Benito
relation head of state
['France', 'head of state', 'Alain Poher'] ['France', 'head of state', 'Carles Maristany i Benito']
ASK WHERE { resource:France property:head_of_state resource:Alain_Poher . resource:France property:head_of_state resource:Carles_Maristany_i_Benito }
[]
common name
SYSTEM
YES and NO respectively
(Q142,P35,Q12950) (Q142,P35,Q20876306)
action is_in
entity Q142
action intersection
action find_reverse
entity Q12950
relation P35
action find_reverse
entity Q20876306
relation P35
[ANSWER]
['Q142', 'P35', 'Q12950'] ['Q142', 'P35', 'Q20876306']
ASK WHERE { resource:Q142 property:P35 resource:Q12950 . resource:Q142 property:P35 resource:Q20876306 }
YES and NO respectively
action is_in
entity France
action intersection
action find_reverse
entity Alain Poher
relation head of state
action find_reverse
entity Carles Maristany i Benito
relation head of state
['France', 'head of state', 'Alain Poher'] ['France', 'head of state', 'Carles Maristany i Benito']
ASK WHERE { resource:France property:head_of_state resource:Alain_Poher . resource:France property:head_of_state resource:Carles_Maristany_i_Benito }
[]
Quantitative Reasoning (All)
Quantitative|Min/Max|Mult. entity type
P417
Q1445650 Q502895 Q15617994
USER
Which administrative territories have max number of holidays and people as their patron saint ?
(c(Q15617994),P417,c(Q1445650)|c(Q502895))
action argmax
action union
action find_tuple_counts
relation P417
type Q15617994
type Q1445650
action find_tuple_counts
relation P417
type Q15617994
type Q502895
[{'concept': 'Q15617994'}, 'P417', [{'concept': 'Q1445650'}, {'concept': 'Q502895'}]]
SELECT DISTINCT ?q WHERE { { SELECT DISTINCT ( MAX ( ?p ) AS ?i ) { SELECT DISTINCT ?h ( COUNT ( ?r ) AS ?p ) WHERE { { ?h property:P417 ?r . ?r rdf:type ontology:Q1445650 . ?h rdf:type ontology:Q15617994 } UNION { ?h rdf:type ontology:Q15617994 . ?r rdf:type ontology:Q502895 . ?h property:P417 ?r } } GROUP BY ?h } } . { SELECT DISTINCT ?q ( COUNT ( ?w ) AS ?t ) WHERE { { ?q property:P417 ?w . ?q rdf:type ontology:Q15617994 . ?w rdf:type ontology:Q1445650 } UNION { ?q rdf:type ontology:Q15617994 . ?w rdf:type ontology:Q502895 . ?q property:P417 ?w } } GROUP BY ?q } . FILTER ( ?t = ?i ) }
action argmax
action union
action find_tuple_counts
relation patron saint
type designation for an administrative territorial entity
type holiday
action find_tuple_counts
relation patron saint
type designation for an administrative territorial entity
type common name
[{'concept': 'designation for an administrative territorial entity'}, 'patron saint', [{'concept': 'holiday'}, {'concept': 'common name'}]]
SELECT DISTINCT ?q WHERE { { SELECT DISTINCT ( MAX ( ?p ) AS ?i ) { SELECT DISTINCT ?h ( COUNT ( ?r ) AS ?p ) WHERE { { ?h property:patron_saint ?r . ?r rdf:type ontology:holiday . ?h rdf:type ontology:designation_for_an_administrative_territorial_entity } UNION { ?h rdf:type ontology:designation_for_an_administrative_territorial_entity . ?r rdf:type ontology:common_name . ?h property:patron_saint ?r } } GROUP BY ?h } } . { SELECT DISTINCT ?q ( COUNT ( ?w ) AS ?t ) WHERE { { ?q property:patron_saint ?w . ?q rdf:type ontology:designation_for_an_administrative_territorial_entity . ?w rdf:type ontology:holiday } UNION { ?q rdf:type ontology:designation_for_an_administrative_territorial_entity . ?w rdf:type ontology:common_name . ?q property:patron_saint ?w } } GROUP BY ?q } . FILTER ( ?t = ?i ) }
[]
holiday common name designation for an administrative territorial entity
Q36
SYSTEM
Poland
Q36
(c(Q15617994),P417,c(Q1445650)|c(Q502895))
action argmax
action union
action find_tuple_counts
relation P417
type Q15617994
type Q1445650
action find_tuple_counts
relation P417
type Q15617994
type Q502895
[ANSWER] have max number of holidays and people as their patron saint
[{'concept': 'Q15617994'}, 'P417', [{'concept': 'Q1445650'}, {'concept': 'Q502895'}]]
SELECT DISTINCT ?q WHERE { { SELECT DISTINCT ( MAX ( ?p ) AS ?i ) { SELECT DISTINCT ?h ( COUNT ( ?r ) AS ?p ) WHERE { { ?h property:P417 ?r . ?r rdf:type ontology:Q1445650 . ?h rdf:type ontology:Q15617994 } UNION { ?h rdf:type ontology:Q15617994 . ?r rdf:type ontology:Q502895 . ?h property:P417 ?r } } GROUP BY ?h } } . { SELECT DISTINCT ?q ( COUNT ( ?w ) AS ?t ) WHERE { { ?q property:P417 ?w . ?q rdf:type ontology:Q15617994 . ?w rdf:type ontology:Q1445650 } UNION { ?q rdf:type ontology:Q15617994 . ?w rdf:type ontology:Q502895 . ?q property:P417 ?w } } GROUP BY ?q } . FILTER ( ?t = ?i ) }
Poland
Poland have max number of holidays and people as their patron saint
Poland
action argmax
action union
action find_tuple_counts
relation patron saint
type designation for an administrative territorial entity
type holiday
action find_tuple_counts
relation patron saint
type designation for an administrative territorial entity
type common name
[{'concept': 'designation for an administrative territorial entity'}, 'patron saint', [{'concept': 'holiday'}, {'concept': 'common name'}]]
SELECT DISTINCT ?q WHERE { { SELECT DISTINCT ( MAX ( ?p ) AS ?i ) { SELECT DISTINCT ?h ( COUNT ( ?r ) AS ?p ) WHERE { { ?h property:patron_saint ?r . ?r rdf:type ontology:holiday . ?h rdf:type ontology:designation_for_an_administrative_territorial_entity } UNION { ?h rdf:type ontology:designation_for_an_administrative_territorial_entity . ?r rdf:type ontology:common_name . ?h property:patron_saint ?r } } GROUP BY ?h } } . { SELECT DISTINCT ?q ( COUNT ( ?w ) AS ?t ) WHERE { { ?q property:patron_saint ?w . ?q rdf:type ontology:designation_for_an_administrative_territorial_entity . ?w rdf:type ontology:holiday } UNION { ?q rdf:type ontology:designation_for_an_administrative_territorial_entity . ?w rdf:type ontology:common_name . ?q property:patron_saint ?w } } GROUP BY ?q } . FILTER ( ?t = ?i ) }
[]
Verification (Boolean) (All)
Verification|2 entities, one direct and one indirect, subject is indirect
Q36 Q156237
P206
Q355304
USER
Is Western Bug situated nearby that administrative territory ?
(Q36,P206,Q156237)
action is_in
entity Q156237
action find
entity Q36
relation P206
['Q36', 'P206', 'Q156237']
ASK WHERE { resource:Q36 property:P206 resource:Q156237 }
Poland Western Bug
action is_in
entity Western Bug
action find
entity Poland
relation located next to body of water
['Poland', 'located next to body of water', 'Western Bug']
ASK WHERE { resource:Poland property:located_next_to_body_of_water resource:Western_Bug }
[]
watercourse
SYSTEM
YES
(Q36,P206,Q156237)
action is_in
entity Q156237
action find
entity Q36
relation P206
[ANSWER]
['Q36', 'P206', 'Q156237']
ASK WHERE { resource:Q36 property:P206 resource:Q156237 }
Yes
action is_in
entity Western Bug
action find
entity Poland
relation located next to body of water
['Poland', 'located next to body of water', 'Western Bug']
ASK WHERE { resource:Poland property:located_next_to_body_of_water resource:Western_Bug }
[]
Verification (Boolean) (All)
Verification|2 entities, both direct
Q737325 Q904297
P36
Q20667921
USER
Is Le Tremblois called the capital of canton of Saint-Laurent-de-Neste ?
(Q737325,P36,Q904297)
action is_in
entity Q904297
action find
entity Q737325
relation P36
['Q737325', 'P36', 'Q904297']
ASK WHERE { resource:Q737325 property:P36 resource:Q904297 }
canton of Saint-Laurent-de-Neste Le Tremblois
action is_in
entity Le Tremblois
action find
entity canton of Saint-Laurent-de-Neste
relation capital
['canton of Saint-Laurent-de-Neste', 'capital', 'Le Tremblois']
ASK WHERE { resource:canton_of_Saint-Laurent-de-Neste property:capital resource:Le_Tremblois }
[]
type of french administrative division
SYSTEM
NO
(Q737325,P36,Q904297)
action is_in
entity Q904297
action find
entity Q737325
relation P36
[ANSWER]
['Q737325', 'P36', 'Q904297']
ASK WHERE { resource:Q737325 property:P36 resource:Q904297 }
No
action is_in
entity Le Tremblois
action find
entity canton of Saint-Laurent-de-Neste
relation capital
['canton of Saint-Laurent-de-Neste', 'capital', 'Le Tremblois']
ASK WHERE { resource:canton_of_Saint-Laurent-de-Neste property:capital resource:Le_Tremblois }
[]
Logical Reasoning (All)
Logical|Union|Multiple_Relation
Q207903 Q36
P206 P974
Q355304
USER
Which watercourses are situated nearby Poland or are the tributaries of Neris ?
OR((Q36,P206,c(Q355304)), (Q207903,P974,c(Q355304)))
action filter_type
action union
action find
entity Q36
relation P206
action find
entity Q207903
relation P974
type Q355304
{'OR': [['Q36', 'P206', {'concept': 'Q355304'}], ['Q207903', 'P974', {'concept': 'Q355304'}]]}
SELECT DISTINCT ?v WHERE { { { resource:Q36 property:P206 ?v } UNION { resource:Q207903 property:P974 ?v } } . ?v rdf:type ontology:Q355304 }
Neris Poland
action filter_type
action union
action find
entity Poland
relation located next to body of water
action find
entity Neris
relation tributary
type watercourse
{'OR': [['Poland', 'located next to body of water', {'concept': 'watercourse'}], ['Neris', 'tributary', {'concept': 'watercourse'}]]}
SELECT DISTINCT ?v WHERE { { { resource:Poland property:located_next_to_body_of_water ?v } UNION { resource:Neris property:tributary ?v } } . ?v rdf:type ontology:watercourse }
[]
watercourse
Q10398614 Q2415452 Q156237 Q13133846 Q2142065 Q2987814 Q2579643 Q5602 Q577026 Q670437
SYSTEM
Some of them are Šešuva, Narach River, Western Bug, Oksna, Divoká Orlice, Servač, Stracha River, Lusatian Neisse, Opava, Musė
Q552 Q2142065 Q2415452 Q661684 Q2567836 Q2590393 Q5602 Q13032327 Q4176549 Q582675 Q2579643 Q1331973 Q3497125 Q577026 Q840694 Q10398614 Q2615808 Q548 Q156237 Q2662487 Q756302 Q13032265 Q670437 Q661778 Q2987814 Q392760 Q13133846 Q828869
OR((Q36,P206,c(Q355304)), (Q207903,P974,c(Q355304)))
action filter_type
action union
action find
entity Q36
relation P206
action find
entity Q207903
relation P974
type Q355304
[ANSWERS] are situated nearby Poland or are the tributaries of Neris
{'OR': [['Q36', 'P206', {'concept': 'Q355304'}], ['Q207903', 'P974', {'concept': 'Q355304'}]]}
SELECT DISTINCT ?v WHERE { { { resource:Q36 property:P206 ?v } UNION { resource:Q207903 property:P974 ?v } } . ?v rdf:type ontology:Q355304 }
Oder Divoká Orlice Narach River Vilnia River Lietauka Ashmyanka River Lusatian Neisse Kužec Białka Jizera Stracha River Olza Ilija Opava Dunajec Šešuva Vokė Vistula Western Bug Žeimena Poprad Dzvinasa Musė Usha Servač Šventoji River Oksna Noteć
Šešuva, Narach River, Western Bug, Oksna, Divoká Orlice, Servač, Stracha River, Lusatian Neisse, Opava and Musė are situated nearby Poland or are the tributaries of Neris
Šešuva Narach River Western Bug Oksna Divoká Orlice Servač Stracha River Lusatian Neisse Opava Musė
action filter_type
action union
action find
entity Poland
relation located next to body of water
action find
entity Neris
relation tributary
type watercourse
{'OR': [['Poland', 'located next to body of water', {'concept': 'watercourse'}], ['Neris', 'tributary', {'concept': 'watercourse'}]]}
SELECT DISTINCT ?v WHERE { { { resource:Poland property:located_next_to_body_of_water ?v } UNION { resource:Neris property:tributary ?v } } . ?v rdf:type ontology:watercourse }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count over Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P403
Q15324 Q355304
USER
How many bodies of water do exactly 10 watercourses flow into ?
(c(Q355304),P403,c(Q15324))
action count
action equal
action find_reverse_tuple_counts
relation P403
type Q15324
type Q355304
value 10
[{'concept': 'Q355304'}, 'P403', {'concept': 'Q15324'}]
SELECT DISTINCT ( COUNT ( ?p ) AS ?c ) WHERE { { SELECT DISTINCT ?p ( COUNT ( ?u ) AS ?d ) WHERE { ?u property:P403 ?p . ?p rdf:type ontology:Q15324 . ?u rdf:type ontology:Q355304 } GROUP BY ?p } . FILTER ( ?d = 10 ) }
action count
action equal
action find_reverse_tuple_counts
relation mouth of the watercourse
type body of water
type watercourse
value 10
[{'concept': 'watercourse'}, 'mouth of the watercourse', {'concept': 'body of water'}]
SELECT DISTINCT ( COUNT ( ?p ) AS ?c ) WHERE { { SELECT DISTINCT ?p ( COUNT ( ?u ) AS ?d ) WHERE { ?u property:mouth_of_the_watercourse ?p . ?p rdf:type ontology:body_of_water . ?u rdf:type ontology:watercourse } GROUP BY ?p } . FILTER ( ?d = 10 ) }
[]
body of water watercourse
SYSTEM
2
Q1323629 Q140290
(c(Q355304),P403,c(Q15324))
action count
action equal
action find_reverse_tuple_counts
relation P403
type Q15324
type Q355304
value 10
[ANSWER]
[{'concept': 'Q355304'}, 'P403', {'concept': 'Q15324'}]
SELECT DISTINCT ( COUNT ( ?p ) AS ?c ) WHERE { { SELECT DISTINCT ?p ( COUNT ( ?u ) AS ?d ) WHERE { ?u property:P403 ?p . ?p rdf:type ontology:Q15324 . ?u rdf:type ontology:Q355304 } GROUP BY ?p } . FILTER ( ?d = 10 ) }
Gulf St Vincent Bay of Plenty
2
action count
action equal
action find_reverse_tuple_counts
relation mouth of the watercourse
type body of water
type watercourse
value 10
[{'concept': 'watercourse'}, 'mouth of the watercourse', {'concept': 'body of water'}]
SELECT DISTINCT ( COUNT ( ?p ) AS ?c ) WHERE { { SELECT DISTINCT ?p ( COUNT ( ?u ) AS ?d ) WHERE { ?u property:mouth_of_the_watercourse ?p . ?p rdf:type ontology:body_of_water . ?u rdf:type ontology:watercourse } GROUP BY ?p } . FILTER ( ?d = 10 ) }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q899316 Q904297
P47
Q20667921
USER
Which french administrative divisions share border with Le Tremblois or Villiers-sur-Seine ?
OR((c(Q20667921),P47,Q904297), (c(Q20667921),P47,Q899316))
action filter_type
action union
action find_reverse
entity Q904297
relation P47
action find_reverse
entity Q899316
relation P47
type Q20667921
{'OR': [[{'concept': 'Q20667921'}, 'P47', 'Q904297'], [{'concept': 'Q20667921'}, 'P47', 'Q899316']]}
SELECT DISTINCT ?i WHERE { { { ?i property:P47 resource:Q904297 } UNION { ?i property:P47 resource:Q899316 } } . ?i rdf:type ontology:Q20667921 }
Villiers-sur-Seine Le Tremblois
action filter_type
action union
action find_reverse
entity Le Tremblois
relation shares border with
action find_reverse
entity Villiers-sur-Seine
relation shares border with
type type of french administrative division
{'OR': [[{'concept': 'type of french administrative division'}, 'shares border with', 'Le Tremblois'], [{'concept': 'type of french administrative division'}, 'shares border with', 'Villiers-sur-Seine']]}
SELECT DISTINCT ?i WHERE { { { ?i property:shares_border_with resource:Le_Tremblois } UNION { ?i property:shares_border_with resource:Villiers-sur-Seine } } . ?i rdf:type ontology:type_of_french_administrative_division }
[]
type of french administrative division
Q1374704 Q663446 Q250691 Q834756 Q1033597 Q270845 Q252465 Q621815 Q781315 Q254268
SYSTEM
Some of them are Gumery, Noyen-sur-Seine, Melz-sur-Seine, Germigney, Courceroy, Hermé, Fontaine-Fourches, Apremont, Noiron, Lieucourt
Q428643 Q834756 Q1374704 Q1033597 Q254268 Q834768 Q663446 Q270845 Q781315 Q252465 Q250691 Q621815
OR((c(Q20667921),P47,Q904297), (c(Q20667921),P47,Q899316))
action filter_type
action union
action find_reverse
entity Q904297
relation P47
action find_reverse
entity Q899316
relation P47
type Q20667921
[ANSWERS] share border with Le Tremblois or Villiers-sur-Seine
{'OR': [[{'concept': 'Q20667921'}, 'P47', 'Q904297'], [{'concept': 'Q20667921'}, 'P47', 'Q899316']]}
SELECT DISTINCT ?i WHERE { { { ?i property:P47 resource:Q904297 } UNION { ?i property:P47 resource:Q899316 } } . ?i rdf:type ontology:Q20667921 }
Vadans, Haute-Saône Germigney Gumery Courceroy Lieucourt Champvans Noyen-sur-Seine Hermé Noiron Fontaine-Fourches Melz-sur-Seine Apremont
Gumery, Noyen-sur-Seine, Melz-sur-Seine, Germigney, Courceroy, Hermé, Fontaine-Fourches, Apremont, Noiron and Lieucourt share border with Le Tremblois or Villiers-sur-Seine
Gumery Noyen-sur-Seine Melz-sur-Seine Germigney Courceroy Hermé Fontaine-Fourches Apremont Noiron Lieucourt
action filter_type
action union
action find_reverse
entity Le Tremblois
relation shares border with
action find_reverse
entity Villiers-sur-Seine
relation shares border with
type type of french administrative division
{'OR': [[{'concept': 'type of french administrative division'}, 'shares border with', 'Le Tremblois'], [{'concept': 'type of french administrative division'}, 'shares border with', 'Villiers-sur-Seine']]}
SELECT DISTINCT ?i WHERE { { { ?i property:shares_border_with resource:Le_Tremblois } UNION { ?i property:shares_border_with resource:Villiers-sur-Seine } } . ?i rdf:type ontology:type_of_french_administrative_division }
[]
Quantitative Reasoning (All)
Quantitative|Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P1376
Q7275 Q20667921
USER
Which states have exactly 1 french administrative division as their capital ?
(c(Q20667921),P1376,c(Q7275))
action equal
action find_reverse_tuple_counts
relation P1376
type Q7275
type Q20667921
value 1
[{'concept': 'Q20667921'}, 'P1376', {'concept': 'Q7275'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?n ) AS ?t ) WHERE { ?n property:P1376 ?l . ?l rdf:type ontology:Q7275 . ?n rdf:type ontology:Q20667921 } GROUP BY ?l } . FILTER ( ?t = 1 ) }
action equal
action find_reverse_tuple_counts
relation capital of
type state
type type of french administrative division
value 1
[{'concept': 'type of french administrative division'}, 'capital of', {'concept': 'state'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?n ) AS ?t ) WHERE { ?n property:capital_of ?l . ?l rdf:type ontology:state . ?n rdf:type ontology:type_of_french_administrative_division } GROUP BY ?l } . FILTER ( ?t = 1 ) }
[]
state type of french administrative division
Q3456417 Q842091 Q112558
SYSTEM
Republic of Saint-Malo, Duchy of Normandy, Republic of Saugeais
Q3456417 Q842091 Q112558
(c(Q20667921),P1376,c(Q7275))
action equal
action find_reverse_tuple_counts
relation P1376
type Q7275
type Q20667921
value 1
[ANSWERS] have exactly 1 french administrative division as their capital
[{'concept': 'Q20667921'}, 'P1376', {'concept': 'Q7275'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?n ) AS ?t ) WHERE { ?n property:P1376 ?l . ?l rdf:type ontology:Q7275 . ?n rdf:type ontology:Q20667921 } GROUP BY ?l } . FILTER ( ?t = 1 ) }
Republic of Saint-Malo Duchy of Normandy Republic of Saugeais
Republic of Saint-Malo, Duchy of Normandy and Republic of Saugeais have exactly 1 french administrative division as their capital
Republic of Saint-Malo Duchy of Normandy Republic of Saugeais
action equal
action find_reverse_tuple_counts
relation capital of
type state
type type of french administrative division
value 1
[{'concept': 'type of french administrative division'}, 'capital of', {'concept': 'state'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?n ) AS ?t ) WHERE { ?n property:capital_of ?l . ?l rdf:type ontology:state . ?n rdf:type ontology:type_of_french_administrative_division } GROUP BY ?l } . FILTER ( ?t = 1 ) }
[]