Simple Question (Direct)
Simple Question
Q11561064
P21
Q290
USER
What is the sex of Risa Shimizu ?
(Q11561064,P21,c(Q290))
action filter_type
action find
entity Q11561064
relation P21
type Q290
['Q11561064', 'P21', {'concept': 'Q290'}]
SELECT DISTINCT ?s WHERE { resource:Q11561064 property:P21 ?s . ?s rdf:type ontology:Q290 }
Risa Shimizu
action filter_type
action find
entity Risa Shimizu
relation gender
type sex
['Risa Shimizu', 'gender', {'concept': 'sex'}]
SELECT DISTINCT ?s WHERE { resource:Risa_Shimizu property:gender ?s . ?s rdf:type ontology:sex }
[]
sex
Q6581072
SYSTEM
female
Q6581072
(Q11561064,P21,c(Q290))
action filter_type
action find
entity Q11561064
relation P21
type Q290
The sex of Risa Shimizu is the [ANSWER]
['Q11561064', 'P21', {'concept': 'Q290'}]
SELECT DISTINCT ?s WHERE { resource:Q11561064 property:P21 ?s . ?s rdf:type ontology:Q290 }
female
The sex of Risa Shimizu is the female
female
action filter_type
action find
entity Risa Shimizu
relation gender
type sex
['Risa Shimizu', 'gender', {'concept': 'sex'}]
SELECT DISTINCT ?s WHERE { resource:Risa_Shimizu property:gender ?s . ?s rdf:type ontology:sex }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q7159889 Q11561064
P27
Q15617994
USER
Which administrative territories do Risa Shimizu or Pedro Quirós Jiménez belong to ?
OR((Q11561064,P27,c(Q15617994)), (Q7159889,P27,c(Q15617994)))
action filter_type
action union
action find
entity Q11561064
relation P27
action find
entity Q7159889
relation P27
type Q15617994
{'OR': [['Q11561064', 'P27', {'concept': 'Q15617994'}], ['Q7159889', 'P27', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?t WHERE { { { resource:Q11561064 property:P27 ?t } UNION { resource:Q7159889 property:P27 ?t } } . ?t rdf:type ontology:Q15617994 }
Pedro Quirós Jiménez Risa Shimizu
action filter_type
action union
action find
entity Risa Shimizu
relation country of citizenship
action find
entity Pedro Quirós Jiménez
relation country of citizenship
type designation for an administrative territorial entity
{'OR': [['Risa Shimizu', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}], ['Pedro Quirós Jiménez', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?t WHERE { { { resource:Risa_Shimizu property:country_of_citizenship ?t } UNION { resource:Pedro_Quirós_Jiménez property:country_of_citizenship ?t } } . ?t rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q17 Q800
SYSTEM
Japan, Costa Rica
Q17 Q800
OR((Q11561064,P27,c(Q15617994)), (Q7159889,P27,c(Q15617994)))
action filter_type
action union
action find
entity Q11561064
relation P27
action find
entity Q7159889
relation P27
type Q15617994
Risa Shimizu or Pedro Quirós Jiménez belong to both [ANSWERS]
{'OR': [['Q11561064', 'P27', {'concept': 'Q15617994'}], ['Q7159889', 'P27', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?t WHERE { { { resource:Q11561064 property:P27 ?t } UNION { resource:Q7159889 property:P27 ?t } } . ?t rdf:type ontology:Q15617994 }
Japan Costa Rica
Risa Shimizu or Pedro Quirós Jiménez belong to both Japan and Costa Rica
Japan Costa Rica
action filter_type
action union
action find
entity Risa Shimizu
relation country of citizenship
action find
entity Pedro Quirós Jiménez
relation country of citizenship
type designation for an administrative territorial entity
{'OR': [['Risa Shimizu', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}], ['Pedro Quirós Jiménez', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?t WHERE { { { resource:Risa_Shimizu property:country_of_citizenship ?t } UNION { resource:Pedro_Quirós_Jiménez property:country_of_citizenship ?t } } . ?t rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Logical Reasoning (All)
Logical|Union|Multiple_Relation
Q5094891 Q17
P530 P17
Q15617994
USER
Which administrative territories have diplomatic relations with Japan or are Chhimmon located in ?
OR((Q17,P530,c(Q15617994)), (Q5094891,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q17
relation P530
action find
entity Q5094891
relation P17
type Q15617994
{'OR': [['Q17', 'P530', {'concept': 'Q15617994'}], ['Q5094891', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?m WHERE { { { resource:Q17 property:P530 ?m } UNION { resource:Q5094891 property:P17 ?m } } . ?m rdf:type ontology:Q15617994 }
Chhimmon Japan
action filter_type
action union
action find
entity Japan
relation diplomatic relation
action find
entity Chhimmon
relation country
type designation for an administrative territorial entity
{'OR': [['Japan', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}], ['Chhimmon', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?m WHERE { { { resource:Japan property:diplomatic_relation ?m } UNION { resource:Chhimmon property:country ?m } } . ?m rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q145 Q801 Q30 Q884 Q711 Q159 Q38 Q227 Q155 Q869
SYSTEM
Some of them are United Kingdom, Israel, United States of America, South Korea, Mongolia, Russia, Italy, Azerbaijan, Brazil, Thailand
Q227 Q142 Q711 Q884 Q159 Q801 Q145 Q155 Q843 Q30 Q869 Q38
OR((Q17,P530,c(Q15617994)), (Q5094891,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q17
relation P530
action find
entity Q5094891
relation P17
type Q15617994
[ANSWERS] have diplomatic relations with Japan or are Chhimmon located in
{'OR': [['Q17', 'P530', {'concept': 'Q15617994'}], ['Q5094891', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?m WHERE { { { resource:Q17 property:P530 ?m } UNION { resource:Q5094891 property:P17 ?m } } . ?m rdf:type ontology:Q15617994 }
Azerbaijan France Mongolia South Korea Russia Israel United Kingdom Brazil Pakistan United States of America Thailand Italy
United Kingdom, Israel, United States of America, South Korea, Mongolia, Russia, Italy, Azerbaijan, Brazil and Thailand have diplomatic relations with Japan or are Chhimmon located in
United Kingdom Israel United States of America South Korea Mongolia Russia Italy Azerbaijan Brazil Thailand
action filter_type
action union
action find
entity Japan
relation diplomatic relation
action find
entity Chhimmon
relation country
type designation for an administrative territorial entity
{'OR': [['Japan', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}], ['Chhimmon', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?m WHERE { { { resource:Japan property:diplomatic_relation ?m } UNION { resource:Chhimmon property:country ?m } } . ?m rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Verification (Boolean) (All)
Verification|one entity, multiple entities (as object) referred indirectly
Q17
P530
Q15617994
USER
Do Japan have diplomatic associations with those ones ?
(Q17,P530,Q145) (Q17,P530,Q801) (Q17,P530,Q30) (Q17,P530,Q884) (Q17,P530,Q711) (Q17,P530,Q159) (Q17,P530,Q38) (Q17,P530,Q227) (Q17,P530,Q155) (Q17,P530,Q869)
action is_in
entity prev_answer
action find
entity Q17
relation P530
['Q17', 'P530', 'Q145'] ['Q17', 'P530', 'Q801'] ['Q17', 'P530', 'Q30'] ['Q17', 'P530', 'Q884'] ['Q17', 'P530', 'Q711'] ['Q17', 'P530', 'Q159'] ['Q17', 'P530', 'Q38'] ['Q17', 'P530', 'Q227'] ['Q17', 'P530', 'Q155'] ['Q17', 'P530', 'Q869']
ASK WHERE { resource:Q17 property:P530 ?t . VALUES ( ?t ) { ( resource:Q227 ) ( resource:Q142 ) ( resource:Q711 ) } }
Japan
action is_in
entity prev_answer
action find
entity Japan
relation diplomatic relation
['Japan', 'diplomatic relation', 'United Kingdom'] ['Japan', 'diplomatic relation', 'Israel'] ['Japan', 'diplomatic relation', 'United States of America'] ['Japan', 'diplomatic relation', 'South Korea'] ['Japan', 'diplomatic relation', 'Mongolia'] ['Japan', 'diplomatic relation', 'Russia'] ['Japan', 'diplomatic relation', 'Italy'] ['Japan', 'diplomatic relation', 'Azerbaijan'] ['Japan', 'diplomatic relation', 'Brazil'] ['Japan', 'diplomatic relation', 'Thailand']
ASK WHERE { resource:Japan property:diplomatic_relation ?t . VALUES ( ?t ) { ( resource:Azerbaijan ) ( resource:France ) ( resource:Mongolia ) } }
[]
designation for an administrative territorial entity
SYSTEM
YES
(Q17,P530,Q145) (Q17,P530,Q801) (Q17,P530,Q30) (Q17,P530,Q884) (Q17,P530,Q711) (Q17,P530,Q159) (Q17,P530,Q38) (Q17,P530,Q227) (Q17,P530,Q155) (Q17,P530,Q869)
action is_in
entity prev_answer
action find
entity Q17
relation P530
[ANSWER]
['Q17', 'P530', 'Q145'] ['Q17', 'P530', 'Q801'] ['Q17', 'P530', 'Q30'] ['Q17', 'P530', 'Q884'] ['Q17', 'P530', 'Q711'] ['Q17', 'P530', 'Q159'] ['Q17', 'P530', 'Q38'] ['Q17', 'P530', 'Q227'] ['Q17', 'P530', 'Q155'] ['Q17', 'P530', 'Q869']
ASK WHERE { resource:Q17 property:P530 ?t . VALUES ( ?t ) { ( resource:Q227 ) ( resource:Q142 ) ( resource:Q711 ) } }
Yes
action is_in
entity prev_answer
action find
entity Japan
relation diplomatic relation
['Japan', 'diplomatic relation', 'United Kingdom'] ['Japan', 'diplomatic relation', 'Israel'] ['Japan', 'diplomatic relation', 'United States of America'] ['Japan', 'diplomatic relation', 'South Korea'] ['Japan', 'diplomatic relation', 'Mongolia'] ['Japan', 'diplomatic relation', 'Russia'] ['Japan', 'diplomatic relation', 'Italy'] ['Japan', 'diplomatic relation', 'Azerbaijan'] ['Japan', 'diplomatic relation', 'Brazil'] ['Japan', 'diplomatic relation', 'Thailand']
ASK WHERE { resource:Japan property:diplomatic_relation ?t . VALUES ( ?t ) { ( resource:Azerbaijan ) ( resource:France ) ( resource:Mongolia ) } }
[]
Comparative Reasoning (Count) (All)
Comparative|Count over More/Less|Single entity type
Q962
P530
Q15617994 Q15617994
USER
How many administrative territories have tactful political relations with more number of administrative territories than Benin ?
(c(Q15617994),P530,c(Q15617994))
action count
action greater
action find_tuple_counts
relation P530
type Q15617994
type Q15617994
action count
action filter_type
action find
entity Q962
relation P530
type Q15617994
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ( COUNT ( ?w ) AS ?g ) WHERE { { SELECT DISTINCT ?w ( COUNT ( ?e ) AS ?x ) WHERE { ?w property:P530 ?e . ?w rdf:type ontology:Q15617994 . ?e rdf:type ontology:Q15617994 } GROUP BY ?w } . { SELECT DISTINCT ( COUNT ( ?b ) AS ?q ) WHERE { resource:Q962 property:P530 ?b . ?b rdf:type ontology:Q15617994 } } . FILTER ( ?x > ?q ) }
Benin
action count
action greater
action find_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type designation for an administrative territorial entity
action count
action filter_type
action find
entity Benin
relation diplomatic relation
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?w ) AS ?g ) WHERE { { SELECT DISTINCT ?w ( COUNT ( ?e ) AS ?x ) WHERE { ?w property:diplomatic_relation ?e . ?w rdf:type ontology:designation_for_an_administrative_territorial_entity . ?e rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?w } . { SELECT DISTINCT ( COUNT ( ?b ) AS ?q ) WHERE { resource:Benin property:diplomatic_relation ?b . ?b rdf:type ontology:designation_for_an_administrative_territorial_entity } } . FILTER ( ?x > ?q ) }
[]
designation for an administrative territorial entity designation for an administrative territorial entity
SYSTEM
66
Q801 Q805 Q419 Q668 Q414 Q142 Q145 Q148 Q37 Q711 Q717 Q252 Q399 Q403 Q258 Q45 Q159 Q43 Q41 Q155 Q796 Q794 Q889 Q884 Q881 Q822 Q241 Q32 Q31 Q30 Q36 Q34 Q928 Q929 Q39 Q38 Q739 Q423 Q733 Q230 Q27 Q28 Q843 Q184 Q228 Q227 Q225 Q222 Q96 Q347 Q17 Q902 Q298 Q114 Q212 Q213 Q218 Q916 Q79 Q77 Q858 Q948 Q1016 Q1011 Q29 Q953
(c(Q15617994),P530,c(Q15617994))
action count
action greater
action find_tuple_counts
relation P530
type Q15617994
type Q15617994
action count
action filter_type
action find
entity Q962
relation P530
type Q15617994
[ANSWER]
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ( COUNT ( ?w ) AS ?g ) WHERE { { SELECT DISTINCT ?w ( COUNT ( ?e ) AS ?x ) WHERE { ?w property:P530 ?e . ?w rdf:type ontology:Q15617994 . ?e rdf:type ontology:Q15617994 } GROUP BY ?w } . { SELECT DISTINCT ( COUNT ( ?b ) AS ?q ) WHERE { resource:Q962 property:P530 ?b . ?b rdf:type ontology:Q15617994 } } . FILTER ( ?x > ?q ) }
Israel Yemen Peru India Argentina France United Kingdom People's Republic of China Lithuania Mongolia Venezuela Indonesia Armenia Serbia South Africa Portugal Russia Turkey Greece Brazil Iraq Iran Afghanistan South Korea Vietnam Lebanon Cuba Luxembourg Belgium United States of America Poland Sweden Philippines Central African Republic Switzerland Italy Colombia North Korea Paraguay Georgia Ireland Hungary Pakistan Belarus Andorra Azerbaijan Bosnia and Herzegovina Albania Mexico Liechtenstein Japan Bangladesh Chile Kenya Ukraine Czech Republic Romania Angola Egypt Uruguay Syria Tunisia Libya Cape Verde Spain Zambia
66
action count
action greater
action find_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type designation for an administrative territorial entity
action count
action filter_type
action find
entity Benin
relation diplomatic relation
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?w ) AS ?g ) WHERE { { SELECT DISTINCT ?w ( COUNT ( ?e ) AS ?x ) WHERE { ?w property:diplomatic_relation ?e . ?w rdf:type ontology:designation_for_an_administrative_territorial_entity . ?e rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?w } . { SELECT DISTINCT ( COUNT ( ?b ) AS ?q ) WHERE { resource:Benin property:diplomatic_relation ?b . ?b rdf:type ontology:designation_for_an_administrative_territorial_entity } } . FILTER ( ?x > ?q ) }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q12490269 Q5094891
P17
Q15617994
USER
Which administrative territories are Chhimmon or Kedonganan located in ?
OR((Q5094891,P17,c(Q15617994)), (Q12490269,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q5094891
relation P17
action find
entity Q12490269
relation P17
type Q15617994
{'OR': [['Q5094891', 'P17', {'concept': 'Q15617994'}], ['Q12490269', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?i WHERE { { VALUES ( ?q ) { ( resource:Q5094891 ) ( resource:Q12490269 ) } . ?q property:P17 ?i } . ?i rdf:type ontology:Q15617994 }
Kedonganan Chhimmon
action filter_type
action union
action find
entity Chhimmon
relation country
action find
entity Kedonganan
relation country
type designation for an administrative territorial entity
{'OR': [['Chhimmon', 'country', {'concept': 'designation for an administrative territorial entity'}], ['Kedonganan', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?i WHERE { { VALUES ( ?q ) { ( resource:Chhimmon ) ( resource:Kedonganan ) } . ?q property:country ?i } . ?i rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q843 Q252
SYSTEM
Pakistan, Indonesia
Q843 Q252
OR((Q5094891,P17,c(Q15617994)), (Q12490269,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q5094891
relation P17
action find
entity Q12490269
relation P17
type Q15617994
Chhimmon or Kedonganan are located in [ANSWERS]
{'OR': [['Q5094891', 'P17', {'concept': 'Q15617994'}], ['Q12490269', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?i WHERE { { VALUES ( ?q ) { ( resource:Q5094891 ) ( resource:Q12490269 ) } . ?q property:P17 ?i } . ?i rdf:type ontology:Q15617994 }
Pakistan Indonesia
Chhimmon or Kedonganan are located in Pakistan and Indonesia
Pakistan Indonesia
action filter_type
action union
action find
entity Chhimmon
relation country
action find
entity Kedonganan
relation country
type designation for an administrative territorial entity
{'OR': [['Chhimmon', 'country', {'concept': 'designation for an administrative territorial entity'}], ['Kedonganan', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?i WHERE { { VALUES ( ?q ) { ( resource:Chhimmon ) ( resource:Kedonganan ) } . ?q property:country ?i } . ?i rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Comparative Reasoning (All)
Comparative|More/Less|Single entity type
Q408
P530
Q1048835 Q15617994
USER
Which political territories have diplomatic relationships with lesser number of administrative territories than Australia ?
(c(Q15617994),P530,c(Q1048835))
action less
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
action count
action filter_type
action find
entity Q408
relation P530
type Q15617994
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?f ) AS ?v ) WHERE { ?j property:P530 ?f . ?j rdf:type ontology:Q1048835 . ?f rdf:type ontology:Q15617994 } GROUP BY ?j } . { SELECT DISTINCT ( COUNT ( ?g ) AS ?p ) WHERE { ?g rdf:type ontology:Q15617994 . resource:Q408 property:P530 ?g } } . FILTER ( ?v < ?p ) }
Australia
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
action count
action filter_type
action find
entity Australia
relation diplomatic relation
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?f ) AS ?v ) WHERE { ?j property:diplomatic_relation ?f . ?j rdf:type ontology:political_territorial_entity . ?f rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?j } . { SELECT DISTINCT ( COUNT ( ?g ) AS ?p ) WHERE { ?g rdf:type ontology:designation_for_an_administrative_territorial_entity . resource:Australia property:diplomatic_relation ?g } } . FILTER ( ?v < ?p ) }
[]
political territorial entity designation for an administrative territorial entity
Q35 Q16 Q40
SYSTEM
Denmark, Canada, Austria
Q1000 Q40 Q781 Q778 Q769 Q685 Q35 Q691 Q16 Q664 Q766
(c(Q15617994),P530,c(Q1048835))
action less
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
action count
action filter_type
action find
entity Q408
relation P530
type Q15617994
[ANSWERS] have diplomatic relationships with lesser number of administrative territories than Australia
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?f ) AS ?v ) WHERE { ?j property:P530 ?f . ?j rdf:type ontology:Q1048835 . ?f rdf:type ontology:Q15617994 } GROUP BY ?j } . { SELECT DISTINCT ( COUNT ( ?g ) AS ?p ) WHERE { ?g rdf:type ontology:Q15617994 . resource:Q408 property:P530 ?g } } . FILTER ( ?v < ?p ) }
Gabon Austria Antigua and Barbuda The Bahamas Grenada Solomon Islands Denmark Papua New Guinea Canada New Zealand Jamaica
Denmark, Canada and Austria have diplomatic relationships with lesser number of administrative territories than Australia
Denmark Canada Austria
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
action count
action filter_type
action find
entity Australia
relation diplomatic relation
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?f ) AS ?v ) WHERE { ?j property:diplomatic_relation ?f . ?j rdf:type ontology:political_territorial_entity . ?f rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?j } . { SELECT DISTINCT ( COUNT ( ?g ) AS ?p ) WHERE { ?g rdf:type ontology:designation_for_an_administrative_territorial_entity . resource:Australia property:diplomatic_relation ?g } } . FILTER ( ?v < ?p ) }
[]
Comparative Reasoning (All)
Comparative|More/Less|Single entity type|Incomplete
Q40
P530
Q1048835 Q15617994
USER
And also tell me about Austria?
(c(Q15617994),P530,c(Q1048835))
action less
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
action count
action filter_type
action find
entity Q40
relation P530
type Q15617994
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?y WHERE { { SELECT DISTINCT ?y ( COUNT ( ?h ) AS ?s ) WHERE { ?y property:P530 ?h . ?y rdf:type ontology:Q1048835 . ?h rdf:type ontology:Q15617994 } GROUP BY ?y } . { SELECT DISTINCT ( COUNT ( ?k ) AS ?w ) WHERE { resource:Q40 property:P530 ?k . ?k rdf:type ontology:Q15617994 } } . FILTER ( ?s < ?w ) }
Austria
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
action count
action filter_type
action find
entity Austria
relation diplomatic relation
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?y WHERE { { SELECT DISTINCT ?y ( COUNT ( ?h ) AS ?s ) WHERE { ?y property:diplomatic_relation ?h . ?y rdf:type ontology:political_territorial_entity . ?h rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?y } . { SELECT DISTINCT ( COUNT ( ?k ) AS ?w ) WHERE { resource:Austria property:diplomatic_relation ?k . ?k rdf:type ontology:designation_for_an_administrative_territorial_entity } } . FILTER ( ?s < ?w ) }
[]
political territorial entity designation for an administrative territorial entity
Q35 Q664 Q1000
SYSTEM
Denmark, New Zealand, Gabon
Q1000 Q781 Q778 Q769 Q685 Q35 Q691 Q664 Q766
(c(Q15617994),P530,c(Q1048835))
action less
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
action count
action filter_type
action find
entity Q40
relation P530
type Q15617994
[ANSWERS]
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?y WHERE { { SELECT DISTINCT ?y ( COUNT ( ?h ) AS ?s ) WHERE { ?y property:P530 ?h . ?y rdf:type ontology:Q1048835 . ?h rdf:type ontology:Q15617994 } GROUP BY ?y } . { SELECT DISTINCT ( COUNT ( ?k ) AS ?w ) WHERE { resource:Q40 property:P530 ?k . ?k rdf:type ontology:Q15617994 } } . FILTER ( ?s < ?w ) }
Gabon Antigua and Barbuda The Bahamas Grenada Solomon Islands Denmark Papua New Guinea New Zealand Jamaica
Denmark New Zealand Gabon
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
action count
action filter_type
action find
entity Austria
relation diplomatic relation
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?y WHERE { { SELECT DISTINCT ?y ( COUNT ( ?h ) AS ?s ) WHERE { ?y property:diplomatic_relation ?h . ?y rdf:type ontology:political_territorial_entity . ?h rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?y } . { SELECT DISTINCT ( COUNT ( ?k ) AS ?w ) WHERE { resource:Austria property:diplomatic_relation ?k . ?k rdf:type ontology:designation_for_an_administrative_territorial_entity } } . FILTER ( ?s < ?w ) }
[]
Quantitative Reasoning (All)
Quantitative|Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P530
Q1048835 Q1048835
USER
Which political territories have diplomatic associations with approximately 3 political territories ?
(c(Q1048835),P530,c(Q1048835))
action approx
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
value 3
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?b ) AS ?h ) WHERE { ?l property:P530 ?b . ?l rdf:type ontology:Q1048835 . ?b rdf:type ontology:Q1048835 } GROUP BY ?l } . FILTER ( ?h = 3 ) }
action approx
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
value 3
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?b ) AS ?h ) WHERE { ?l property:diplomatic_relation ?b . ?l rdf:type ontology:political_territorial_entity . ?b rdf:type ontology:political_territorial_entity } GROUP BY ?l } . FILTER ( ?h = 3 ) }
[]
political territorial entity political territorial entity
Q35 Q16 Q40
SYSTEM
Denmark, Canada, Austria
Q1000 Q40 Q781 Q778 Q769 Q685 Q35 Q691 Q16 Q664 Q766
(c(Q1048835),P530,c(Q1048835))
action approx
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
value 3
[ANSWERS] have diplomatic associations with approximately 3 political territories
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?b ) AS ?h ) WHERE { ?l property:P530 ?b . ?l rdf:type ontology:Q1048835 . ?b rdf:type ontology:Q1048835 } GROUP BY ?l } . FILTER ( ?h = 3 ) }
Gabon Austria Antigua and Barbuda The Bahamas Grenada Solomon Islands Denmark Papua New Guinea Canada New Zealand Jamaica
Denmark, Canada and Austria have diplomatic associations with approximately 3 political territories
Denmark Canada Austria
action approx
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
value 3
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?b ) AS ?h ) WHERE { ?l property:diplomatic_relation ?b . ?l rdf:type ontology:political_territorial_entity . ?b rdf:type ontology:political_territorial_entity } GROUP BY ?l } . FILTER ( ?h = 3 ) }
[]
Clarification
Simple Question|Single Entity|Indirect
Q35
P1376
Q56061
USER
What is the capital of that political territory ?
(c(Q56061),P1376,Q35)
action filter_type
action find_reverse
entity Q35
relation P1376
type Q56061
[{'concept': 'Q56061'}, 'P1376', 'Q35']
SELECT DISTINCT ?j WHERE { ?j property:P1376 resource:Q35 . ?j rdf:type ontology:Q56061 }
Denmark
action filter_type
action find_reverse
entity Denmark
relation capital of
type administrative territorial entity
[{'concept': 'administrative territorial entity'}, 'capital of', 'Denmark']
SELECT DISTINCT ?j WHERE { ?j property:capital_of resource:Denmark . ?j rdf:type ontology:administrative_territorial_entity }
[]
administrative territorial entity
Clarification for simple ques.
Q40
SYSTEM
Did you mean Austria ?
Q35 Q16 Q40
(c(Q56061),P1376,Q35) (c(Q56061),P1376,Q16) (c(Q56061),P1376,Q40)
[ANSWER]
[{'concept': 'Q56061'}, 'P1376', 'Q35'] [{'concept': 'Q56061'}, 'P1376', 'Q16'] [{'concept': 'Q56061'}, 'P1376', 'Q40']
SELECT DISTINCT ?j WHERE { ?j property:P1376 resource:Q35 . ?j rdf:type ontology:Q56061 }
Denmark Canada Austria
Did you mean Austria ?
Austria
[{'concept': 'administrative territorial entity'}, 'capital of', 'Denmark'] [{'concept': 'administrative territorial entity'}, 'capital of', 'Canada'] [{'concept': 'administrative territorial entity'}, 'capital of', 'Austria']
SELECT DISTINCT ?j WHERE { ?j property:capital_of resource:Denmark . ?j rdf:type ontology:administrative_territorial_entity }
[]
Simple Question (Coreferenced)
USER
No, I meant Denmark. Could you tell me the answer for that?
(c(Q56061),P1376,Q35)
Q35
[{'concept': 'Q56061'}, 'P1376', 'Q35']
[{'concept': 'administrative territorial entity'}, 'capital of', 'Denmark']
[]
Q1748
SYSTEM
Copenhagen
Q1748
(c(Q56061),P1376,Q35)
action filter_type
action find_reverse
entity Q35
relation P1376
type Q56061
The capital of that political territory is of [ANSWER]
[{'concept': 'Q56061'}, 'P1376', 'Q35']
SELECT DISTINCT ?j WHERE { ?j property:P1376 resource:Q35 . ?j rdf:type ontology:Q56061 }
Copenhagen
The capital of that political territory is of Copenhagen
Copenhagen
action filter_type
action find_reverse
entity Denmark
relation capital of
type administrative territorial entity
[{'concept': 'administrative territorial entity'}, 'capital of', 'Denmark']
SELECT DISTINCT ?j WHERE { ?j property:capital_of resource:Denmark . ?j rdf:type ontology:administrative_territorial_entity }
[]
Quantitative Reasoning (All)
Quantitative|Min/Max|Mult. entity type
P190
Q56061 Q15617994 Q1048835
USER
Which political territories are twin town of min number of administrative territories and administrative territories ?
(c(Q1048835),P190,c(Q56061)|c(Q15617994))
action argmin
action union
action find_tuple_counts
relation P190
type Q1048835
type Q56061
action find_tuple_counts
relation P190
type Q1048835
type Q15617994
[{'concept': 'Q1048835'}, 'P190', [{'concept': 'Q56061'}, {'concept': 'Q15617994'}]]
SELECT DISTINCT ?a WHERE { { SELECT DISTINCT ( MIN ( ?o ) AS ?m ) { SELECT DISTINCT ?s ( COUNT ( ?h ) AS ?o ) WHERE { VALUES ( ?r ) { ( ontology:Q15617994 ) ( ontology:Q56061 ) } . ?h rdf:type ?r } GROUP BY ?s } } . { SELECT DISTINCT ?a ( COUNT ( ?b ) AS ?w ) WHERE { { ?a property:P190 ?b . ?a rdf:type ontology:Q1048835 . ?b rdf:type ontology:Q56061 } UNION { ?a property:P190 ?b . ?a rdf:type ontology:Q1048835 . ?b rdf:type ontology:Q15617994 } } GROUP BY ?a } . FILTER ( ?w = ?m ) }
action argmin
action union
action find_tuple_counts
relation sister city
type political territorial entity
type administrative territorial entity
action find_tuple_counts
relation sister city
type political territorial entity
type designation for an administrative territorial entity
[{'concept': 'political territorial entity'}, 'sister city', [{'concept': 'administrative territorial entity'}, {'concept': 'designation for an administrative territorial entity'}]]
SELECT DISTINCT ?a WHERE { { SELECT DISTINCT ( MIN ( ?o ) AS ?m ) { SELECT DISTINCT ?s ( COUNT ( ?h ) AS ?o ) WHERE { VALUES ( ?r ) { ( ontology:designation_for_an_administrative_territorial_entity ) ( ontology:administrative_territorial_entity ) } . ?h rdf:type ?r } GROUP BY ?s } } . { SELECT DISTINCT ?a ( COUNT ( ?b ) AS ?w ) WHERE { { ?a property:sister_city ?b . ?a rdf:type ontology:political_territorial_entity . ?b rdf:type ontology:administrative_territorial_entity } UNION { ?a property:sister_city ?b . ?a rdf:type ontology:political_territorial_entity . ?b rdf:type ontology:designation_for_an_administrative_territorial_entity } } GROUP BY ?a } . FILTER ( ?w = ?m ) }
[]
administrative territorial entity designation for an administrative territorial entity political territorial entity
Q763 Q778 Q761735
SYSTEM
Saint Kitts and Nevis, The Bahamas, Montblanc
Q5963 Q1628188 Q15471 Q13010 Q927931 Q910410 Q2101408 Q1312844 Q1391501 Q1853429 Q686837 Q476793 Q919050 Q12590 Q433632 Q842713 Q189952 Q644891 Q1312654 Q496368 Q624967 Q20937 Q496588 Q824651 Q7909 Q815631 Q12339 Q63004 Q1021521 Q1750915 Q752137 Q164867 Q12647 Q376393 Q3741 Q1161455 Q211889 Q820229 Q596761 Q12110 Q487268 Q13424 Q180200 Q1407143 Q1606055 Q787022 Q844784 Q1110343 Q1769167 Q13785 Q574340 Q161945 Q140203 Q485129 Q1614754 Q1613282 Q375925 Q956558 Q12690 Q1915208 Q741765 Q478818 Q737161 Q1410782 Q583280 Q180981 Q695889 Q489839 Q740833 Q1730870 Q12587 Q592747 Q12022 Q500494 Q205681 Q8184 Q1651638 Q188905 Q735759 Q739495 Q15553 Q15558 Q462218 Q937763 Q898563 Q371748 Q641221 Q167436 Q840373 Q12102 Q12101 Q761735 Q192370 Q1993019 Q604810 Q497801 Q1601699 Q385017 Q1917834 Q1632577 Q572800 Q639422 Q1024828 Q492533 Q845424 Q491667 Q622830 Q15968 Q430147 Q15639 Q427505 Q13490 Q465085 Q729958 Q943431 Q122208 Q696797 Q1751908 Q763 Q502975 Q477311 Q15652 Q984529 Q1228759 Q755695 Q1312465 Q5978 Q515016 Q714538 Q668324 Q582995 Q1272870 Q1651692 Q385923 Q12534 Q501674 Q1767561 Q13804 Q741749 Q1628531 Q919046 Q497692 Q837051 Q619692 Q1641746 Q15597 Q1637309 Q5783 Q5785 Q1368982 Q2244278 Q1368868 Q1982975 Q13614 Q6839 Q318314 Q749696 Q983433 Q15622 Q3303729 Q10485 Q1657213 Q1607392 Q904212 Q946068 Q842211 Q201149 Q12335 Q229659 Q13022 Q13159 Q778 Q714613 Q1768489 Q215822
(c(Q1048835),P190,c(Q56061)|c(Q15617994))
action argmin
action union
action find_tuple_counts
relation P190
type Q1048835
type Q56061
action find_tuple_counts
relation P190
type Q1048835
type Q15617994
[ANSWERS] are twin town of min number of administrative territories and administrative territories
[{'concept': 'Q1048835'}, 'P190', [{'concept': 'Q56061'}, {'concept': 'Q15617994'}]]
SELECT DISTINCT ?a WHERE { { SELECT DISTINCT ( MIN ( ?o ) AS ?m ) { SELECT DISTINCT ?s ( COUNT ( ?h ) AS ?o ) WHERE { VALUES ( ?r ) { ( ontology:Q15617994 ) ( ontology:Q56061 ) } . ?h rdf:type ?r } GROUP BY ?s } } . { SELECT DISTINCT ?a ( COUNT ( ?b ) AS ?w ) WHERE { { ?a property:P190 ?b . ?a rdf:type ontology:Q1048835 . ?b rdf:type ontology:Q56061 } UNION { ?a property:P190 ?b . ?a rdf:type ontology:Q1048835 . ?b rdf:type ontology:Q15617994 } } GROUP BY ?a } . FILTER ( ?w = ?m ) }
Hanover region Cangas Sant Adrià de Besòs Arbúcies Cabra Tres Cantos Guimarães Alberic Briviesca Valverde Karrantza Arévalo Molina de Aragón Malgrat de Mar Santa Cruz de La Palma Itajaí Lääne-Viru County Ruente Carlet Wrexham Arafo Gyeonggi Province Oñati Parla Main-Taunus-Kreis Belinho Sant Joan de les Abadesses Tocina São João de Loure Callosa de Segura Tàrrega Rügen Vielha e Mijaran Brieskow-Finkenheerd Special Region of Yogyakarta Macael East Dunbartonshire Tomelloso Malpica de Bergantiños Arenys de Mar Candelaria Cassà de la Selva Harju County Santa Amalia Caudete Autol Vale of Glamorgan Vélez-Rubio Cigales Cavite Las Gabias Torrent Zafra Burgo de Osma-Ciudad de Osma Medina de Pomar Alcaudete Vila Nova de Cerveira Sádaba Sort Torredonjimeno San Fernando São José dos Pinhais Calanda Iznalloz Uncastillo Kirovohrad Oblast Alfaro, La Rioja Torrejón de Ardoz Santa Maria Oliveira do Douro, Vila Nova de Gaia Santa Susanna Las Rozas de Madrid Montgat Padrón Cascavel Enz Cella Ouro Preto Collado Villalba Vilanova de Arousa Vilanova i la Geltrú Cubelles Governador Valadares Graus Valdepeñas San Lorenzo de El Escorial Viveiro João Pessoa Valdemoro Caldes d'Estrac Arenys de Munt Montblanc Tartu County Meliana Markina-Xemein Tolosa Villamanrique de la Condesa Valencia de Don Juan Albaida Benalup-Casas Viejas Alcañiz Pozuelo de Alarcón Luso Andorra Peniscola San Vicente del Raspeig / Sant Vicent del Raspeig Caruaru Santa Margarita de Montbui Teror Sant Feliu de Llobregat Majadahonda Palafrugell Almadén Mochola Granadilla de Abona Olocau Balaguer San Martín de Valdeiglesias Saint Kitts and Nevis Barbastro Amposta Viladecans Cariñena La Unión Fuenmayor Benifairó de la Valldigna Hildesheim Castuera Zapsonj San Adrián Lanjarón Santiago de Figueiró Tudela de Duero Alcúdia Sant Pol de Mar Alhama de Granada Valverde de Júcar Manlleu Chipiona Quintanar de la Orden Consuegra Arganda del Rey Mequinenza La Zubia Huelma Castelldefels Ezcaray Andalusia Cayman Islands Azuaga Tías, Las Palmas Berantevilla Los Alcázares Banyoles Figueres Ipatinga Albalat de la Ribera Güímar Gavà Magdalena del Mar Deggendorf Venta de Baños Madridejos Fraga Lezama San Fernando de Henares Fife Ripoll Zumaia Amer Cañete la Real The Bahamas Serne Utrillas Puertollano
Saint Kitts and Nevis, The Bahamas and Montblanc are twin town of min number of administrative territories and administrative territories
Saint Kitts and Nevis The Bahamas Montblanc
action argmin
action union
action find_tuple_counts
relation sister city
type political territorial entity
type administrative territorial entity
action find_tuple_counts
relation sister city
type political territorial entity
type designation for an administrative territorial entity
[{'concept': 'political territorial entity'}, 'sister city', [{'concept': 'administrative territorial entity'}, {'concept': 'designation for an administrative territorial entity'}]]
SELECT DISTINCT ?a WHERE { { SELECT DISTINCT ( MIN ( ?o ) AS ?m ) { SELECT DISTINCT ?s ( COUNT ( ?h ) AS ?o ) WHERE { VALUES ( ?r ) { ( ontology:designation_for_an_administrative_territorial_entity ) ( ontology:administrative_territorial_entity ) } . ?h rdf:type ?r } GROUP BY ?s } } . { SELECT DISTINCT ?a ( COUNT ( ?b ) AS ?w ) WHERE { { ?a property:sister_city ?b . ?a rdf:type ontology:political_territorial_entity . ?b rdf:type ontology:administrative_territorial_entity } UNION { ?a property:sister_city ?b . ?a rdf:type ontology:political_territorial_entity . ?b rdf:type ontology:designation_for_an_administrative_territorial_entity } } GROUP BY ?a } . FILTER ( ?w = ?m ) }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count|Mult. entity type
Q778 Q4018
P47
Q1048835
USER
How many political territories share the border with The Bahamas or Navarre ?
(Q778,P47,c(Q1048835)) (Q4018,P47,c(Q1048835))
action count
action union
action filter_type
action find
entity Q778
relation P47
type Q1048835
action filter_type
action find
entity Q4018
relation P47
type Q1048835
['Q778', 'P47', {'concept': 'Q1048835'}] ['Q4018', 'P47', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?m ) AS ?y ) WHERE { { resource:Q778 property:P47 ?m . ?m rdf:type ontology:Q1048835 } UNION { ?m rdf:type ontology:Q1048835 . resource:Q4018 property:P47 ?m } }
The Bahamas Navarre
action count
action union
action filter_type
action find
entity The Bahamas
relation shares border with
type political territorial entity
action filter_type
action find
entity Navarre
relation shares border with
type political territorial entity
['The Bahamas', 'shares border with', {'concept': 'political territorial entity'}] ['Navarre', 'shares border with', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?m ) AS ?y ) WHERE { { resource:The_Bahamas property:shares_border_with ?m . ?m rdf:type ontology:political_territorial_entity } UNION { ?m rdf:type ontology:political_territorial_entity . resource:Navarre property:shares_border_with ?m } }
[]
political territorial entity
SYSTEM
2
Q4040 Q3995
(Q778,P47,c(Q1048835)) (Q4018,P47,c(Q1048835))
action count
action union
action filter_type
action find
entity Q778
relation P47
type Q1048835
action filter_type
action find
entity Q4018
relation P47
type Q1048835
[ANSWER]
['Q778', 'P47', {'concept': 'Q1048835'}] ['Q4018', 'P47', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?m ) AS ?y ) WHERE { { resource:Q778 property:P47 ?m . ?m rdf:type ontology:Q1048835 } UNION { ?m rdf:type ontology:Q1048835 . resource:Q4018 property:P47 ?m } }
Aragon Basque Country
2
action count
action union
action filter_type
action find
entity The Bahamas
relation shares border with
type political territorial entity
action filter_type
action find
entity Navarre
relation shares border with
type political territorial entity
['The Bahamas', 'shares border with', {'concept': 'political territorial entity'}] ['Navarre', 'shares border with', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?m ) AS ?y ) WHERE { { resource:The_Bahamas property:shares_border_with ?m . ?m rdf:type ontology:political_territorial_entity } UNION { ?m rdf:type ontology:political_territorial_entity . resource:Navarre property:shares_border_with ?m } }
[]