Simple Question (Direct)
Simple Question
Q99672
P26
Q502895
USER
Which person is the spouse of Hilda Heinemann ?
(Q99672,P26,c(Q502895))
action filter_type
action find
entity Q99672
relation P26
type Q502895
['Q99672', 'P26', {'concept': 'Q502895'}]
SELECT DISTINCT ?n WHERE { ?n rdf:type ontology:Q502895 . resource:Q99672 property:P26 ?n }
Hilda Heinemann
action filter_type
action find
entity Hilda Heinemann
relation spouse
type common name
['Hilda Heinemann', 'spouse', {'concept': 'common name'}]
SELECT DISTINCT ?n WHERE { ?n rdf:type ontology:common_name . resource:Hilda_Heinemann property:spouse ?n }
[]
common name
Q2573
SYSTEM
Gustav Heinemann
Q2573
(Q99672,P26,c(Q502895))
action filter_type
action find
entity Q99672
relation P26
type Q502895
[ANSWER] is the spouse of Hilda Heinemann
['Q99672', 'P26', {'concept': 'Q502895'}]
SELECT DISTINCT ?n WHERE { ?n rdf:type ontology:Q502895 . resource:Q99672 property:P26 ?n }
Gustav Heinemann
Gustav Heinemann is the spouse of Hilda Heinemann
Gustav Heinemann
action filter_type
action find
entity Hilda Heinemann
relation spouse
type common name
['Hilda Heinemann', 'spouse', {'concept': 'common name'}]
SELECT DISTINCT ?n WHERE { ?n rdf:type ontology:common_name . resource:Hilda_Heinemann property:spouse ?n }
[]
Simple Question (Coreferenced)
Simple Question|Single Entity|Indirect
Q2573
P937
Q56061
USER
Where did that person work ?
(Q2573,P937,c(Q56061))
action filter_type
action find
entity Q2573
relation P937
type Q56061
['Q2573', 'P937', {'concept': 'Q56061'}]
SELECT DISTINCT ?w WHERE { resource:Q2573 property:P937 ?w . ?w rdf:type ontology:Q56061 }
Gustav Heinemann
action filter_type
action find
entity Gustav Heinemann
relation work location
type administrative territorial entity
['Gustav Heinemann', 'work location', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ?w WHERE { resource:Gustav_Heinemann property:work_location ?w . ?w rdf:type ontology:administrative_territorial_entity }
[]
administrative territorial entity
Q1718 Q586
SYSTEM
Düsseldorf, Bonn
Q1718 Q586
(Q2573,P937,c(Q56061))
action filter_type
action find
entity Q2573
relation P937
type Q56061
That person worked in [ANSWERS]
['Q2573', 'P937', {'concept': 'Q56061'}]
SELECT DISTINCT ?w WHERE { resource:Q2573 property:P937 ?w . ?w rdf:type ontology:Q56061 }
Düsseldorf Bonn
That person worked in Düsseldorf and Bonn
Düsseldorf Bonn
action filter_type
action find
entity Gustav Heinemann
relation work location
type administrative territorial entity
['Gustav Heinemann', 'work location', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ?w WHERE { resource:Gustav_Heinemann property:work_location ?w . ?w rdf:type ontology:administrative_territorial_entity }
[]
Clarification
Simple Question|Single Entity|Indirect
Q586
P47
Q1048835
USER
Which political territory has an adjacent border with that administrative territory ?
(c(Q1048835),P47,Q586)
action filter_type
action find
entity Q586
relation P47
type Q1048835
[{'concept': 'Q1048835'}, 'P47', 'Q586']
SELECT DISTINCT ?f WHERE { resource:Q586 property:P47 ?f . ?f rdf:type ontology:Q1048835 }
Bonn
action filter_type
action find
entity Bonn
relation shares border with
type political territorial entity
[{'concept': 'political territorial entity'}, 'shares border with', 'Bonn']
SELECT DISTINCT ?f WHERE { resource:Bonn property:shares_border_with ?f . ?f rdf:type ontology:political_territorial_entity }
[]
political territorial entity
Clarification for simple ques.
Q586
SYSTEM
Did you mean Bonn ?
Q1718 Q586
(c(Q1048835),P47,Q1718) (c(Q1048835),P47,Q586)
[ANSWER]
[{'concept': 'Q1048835'}, 'P47', 'Q1718'] [{'concept': 'Q1048835'}, 'P47', 'Q586']
SELECT DISTINCT ?f WHERE { resource:Q586 property:P47 ?f . ?f rdf:type ontology:Q1048835 }
Düsseldorf Bonn
Did you mean Bonn ?
Bonn
[{'concept': 'political territorial entity'}, 'shares border with', 'Düsseldorf'] [{'concept': 'political territorial entity'}, 'shares border with', 'Bonn']
SELECT DISTINCT ?f WHERE { resource:Bonn property:shares_border_with ?f . ?f rdf:type ontology:political_territorial_entity }
[]
Simple Question (Coreferenced)
USER
Yes
(c(Q1048835),P47,Q586)
[{'concept': 'Q1048835'}, 'P47', 'Q586']
[{'concept': 'political territorial entity'}, 'shares border with', 'Bonn']
[]
Q8596
SYSTEM
Ahrweiler
Q8596
(c(Q1048835),P47,Q586)
action filter_type
action find
entity Q586
relation P47
type Q1048835
Of [ANSWER] has an adjacent border with that administrative territory
[{'concept': 'Q1048835'}, 'P47', 'Q586']
SELECT DISTINCT ?f WHERE { resource:Q586 property:P47 ?f . ?f rdf:type ontology:Q1048835 }
Ahrweiler
Of Ahrweiler has an adjacent border with that administrative territory
Ahrweiler
action filter_type
action find
entity Bonn
relation shares border with
type political territorial entity
[{'concept': 'political territorial entity'}, 'shares border with', 'Bonn']
SELECT DISTINCT ?f WHERE { resource:Bonn property:shares_border_with ?f . ?f rdf:type ontology:political_territorial_entity }
[]
Verification (Boolean) (All)
Verification|3 entities, all direct, 2 are query entities
Q8596 Q1638441 Q4154252
P17
Q1048835
USER
Is Ahrweiler situated in Piratini and Dalnie ?
(Q8596,P17,Q1638441) (Q8596,P17,Q4154252)
action is_in
entity Q8596
action intersection
action find_reverse
entity Q1638441
relation P17
action find_reverse
entity Q4154252
relation P17
['Q8596', 'P17', 'Q1638441'] ['Q8596', 'P17', 'Q4154252']
ASK WHERE { resource:Q8596 property:P17 resource:Q1638441 . resource:Q8596 property:P17 resource:Q4154252 }
Ahrweiler Piratini Dalnie
action is_in
entity Ahrweiler
action intersection
action find_reverse
entity Piratini
relation country
action find_reverse
entity Dalnie
relation country
['Ahrweiler', 'country', 'Piratini'] ['Ahrweiler', 'country', 'Dalnie']
ASK WHERE { resource:Ahrweiler property:country resource:Piratini . resource:Ahrweiler property:country resource:Dalnie }
[]
political territorial entity
SYSTEM
NO
(Q8596,P17,Q1638441) (Q8596,P17,Q4154252)
action is_in
entity Q8596
action intersection
action find_reverse
entity Q1638441
relation P17
action find_reverse
entity Q4154252
relation P17
[ANSWER]
['Q8596', 'P17', 'Q1638441'] ['Q8596', 'P17', 'Q4154252']
ASK WHERE { resource:Q8596 property:P17 resource:Q1638441 . resource:Q8596 property:P17 resource:Q4154252 }
No
action is_in
entity Ahrweiler
action intersection
action find_reverse
entity Piratini
relation country
action find_reverse
entity Dalnie
relation country
['Ahrweiler', 'country', 'Piratini'] ['Ahrweiler', 'country', 'Dalnie']
ASK WHERE { resource:Ahrweiler property:country resource:Piratini . resource:Ahrweiler property:country resource:Dalnie }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count over Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P530
Q1048835 Q1048835
USER
How many political territories have ambassadorial relations with exactly 3 political territories ?
(c(Q1048835),P530,c(Q1048835))
action count
action equal
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
value 3
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?m ) AS ?n ) WHERE { { SELECT DISTINCT ?m ( COUNT ( ?e ) AS ?z ) WHERE { ?m property:P530 ?e . ?e rdf:type ontology:Q1048835 . ?m rdf:type ontology:Q1048835 } GROUP BY ?m } . FILTER ( ?z = 3 ) }
action count
action equal
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 ( COUNT ( ?m ) AS ?n ) WHERE { { SELECT DISTINCT ?m ( COUNT ( ?e ) AS ?z ) WHERE { ?m property:diplomatic_relation ?e . ?e rdf:type ontology:political_territorial_entity . ?m rdf:type ontology:political_territorial_entity } GROUP BY ?m } . FILTER ( ?z = 3 ) }
[]
political territorial entity political territorial entity
SYSTEM
2
Q35 Q664
(c(Q1048835),P530,c(Q1048835))
action count
action equal
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
value 3
[ANSWER]
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?m ) AS ?n ) WHERE { { SELECT DISTINCT ?m ( COUNT ( ?e ) AS ?z ) WHERE { ?m property:P530 ?e . ?e rdf:type ontology:Q1048835 . ?m rdf:type ontology:Q1048835 } GROUP BY ?m } . FILTER ( ?z = 3 ) }
Denmark New Zealand
2
action count
action equal
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 ( COUNT ( ?m ) AS ?n ) WHERE { { SELECT DISTINCT ?m ( COUNT ( ?e ) AS ?z ) WHERE { ?m property:diplomatic_relation ?e . ?e rdf:type ontology:political_territorial_entity . ?m rdf:type ontology:political_territorial_entity } GROUP BY ?m } . FILTER ( ?z = 3 ) }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q4372683 Q2573
P27
Q1048835
USER
Which political territories are Gustav Heinemann or Nenad Popović an inhabitant of ?
OR((Q2573,P27,c(Q1048835)), (Q4372683,P27,c(Q1048835)))
action filter_type
action union
action find
entity Q2573
relation P27
action find
entity Q4372683
relation P27
type Q1048835
{'OR': [['Q2573', 'P27', {'concept': 'Q1048835'}], ['Q4372683', 'P27', {'concept': 'Q1048835'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Q2573 property:P27 ?f } UNION { resource:Q4372683 property:P27 ?f } } . ?f rdf:type ontology:Q1048835 }
Nenad Popović Gustav Heinemann
action filter_type
action union
action find
entity Gustav Heinemann
relation country of citizenship
action find
entity Nenad Popović
relation country of citizenship
type political territorial entity
{'OR': [['Gustav Heinemann', 'country of citizenship', {'concept': 'political territorial entity'}], ['Nenad Popović', 'country of citizenship', {'concept': 'political territorial entity'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Gustav_Heinemann property:country_of_citizenship ?f } UNION { resource:Nenad_Popović property:country_of_citizenship ?f } } . ?f rdf:type ontology:political_territorial_entity }
[]
political territorial entity
Q838261 Q183
SYSTEM
Federal Republic of Yugoslavia, Germany
Q838261 Q183
OR((Q2573,P27,c(Q1048835)), (Q4372683,P27,c(Q1048835)))
action filter_type
action union
action find
entity Q2573
relation P27
action find
entity Q4372683
relation P27
type Q1048835
The [ANSWERS] are Gustav Heinemann or Nenad Popović an inhabitant of
{'OR': [['Q2573', 'P27', {'concept': 'Q1048835'}], ['Q4372683', 'P27', {'concept': 'Q1048835'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Q2573 property:P27 ?f } UNION { resource:Q4372683 property:P27 ?f } } . ?f rdf:type ontology:Q1048835 }
Federal Republic of Yugoslavia Germany
The Federal Republic of Yugoslavia and Germany are Gustav Heinemann or Nenad Popović an inhabitant of
Federal Republic of Yugoslavia Germany
action filter_type
action union
action find
entity Gustav Heinemann
relation country of citizenship
action find
entity Nenad Popović
relation country of citizenship
type political territorial entity
{'OR': [['Gustav Heinemann', 'country of citizenship', {'concept': 'political territorial entity'}], ['Nenad Popović', 'country of citizenship', {'concept': 'political territorial entity'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Gustav_Heinemann property:country_of_citizenship ?f } UNION { resource:Nenad_Popović property:country_of_citizenship ?f } } . ?f rdf:type ontology:political_territorial_entity }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count over Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P530
Q15617994 Q1048835
USER
How many administrative territories have diplomatic relationships with atmost 4 political territories ?
(c(Q1048835),P530,c(Q15617994))
action count
action atmost
action find_reverse_tuple_counts
relation P530
type Q15617994
type Q1048835
value 4
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?k ) WHERE { { SELECT DISTINCT ?e ( COUNT ( ?f ) AS ?a ) WHERE { ?f property:P530 ?e . ?e rdf:type ontology:Q15617994 . ?f rdf:type ontology:Q1048835 } GROUP BY ?e } . FILTER ( ?a <= 4 ) }
action count
action atmost
action find_reverse_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type political territorial entity
value 4
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?k ) WHERE { { SELECT DISTINCT ?e ( COUNT ( ?f ) AS ?a ) WHERE { ?f property:diplomatic_relation ?e . ?e rdf:type ontology:designation_for_an_administrative_territorial_entity . ?f rdf:type ontology:political_territorial_entity } GROUP BY ?e } . FILTER ( ?a <= 4 ) }
[]
designation for an administrative territorial entity political territorial entity
SYSTEM
164
Q702 Q804 Q801 Q800 Q805 Q419 Q668 Q414 Q142 Q55 Q145 Q262 Q148 Q783 Q784 Q265 Q37 Q712 Q711 Q710 Q717 Q837 Q252 Q399 Q398 Q403 Q657 Q258 Q45 Q159 Q43 Q41 Q792 Q790 Q796 Q794 Q954 Q889 Q884 Q958 Q881 Q986 Q822 Q241 Q242 Q244 Q811 Q33 Q32 Q31 Q30 Q924 Q36 Q34 Q928 Q929 Q39 Q739 Q423 Q983 Q851 Q733 Q29999 Q854 Q734 Q819 Q424 Q730 Q1013 Q236 Q230 Q232 Q233 Q238 Q20 Q1045 Q1041 Q27 Q28 Q921 Q1049 Q1027 Q1020 Q189 Q843 Q842 Q184 Q1029 Q1028 Q736 Q786 Q228 Q227 Q225 Q224 Q222 Q221 Q96 Q229 Q347 Q17 Q902 Q1036 Q1037 Q974 Q1032 Q1033 Q1030 Q191 Q965 Q967 Q962 Q963 Q697 Q298 Q695 Q115 Q114 Q117 Q754 Q750 Q212 Q213 Q211 Q217 Q214 Q215 Q218 Q219 Q912 Q917 Q916 Q1007 Q1006 Q1005 Q833 Q977 Q1009 Q1008 Q971 Q970 Q683 Q34020 Q686 Q836 Q574 Q874 Q79 Q77 Q858 Q878 Q774 Q948 Q817 Q810 Q1019 Q1016 Q1011 Q945 Q678 Q29 Q33788 Q869 Q953
(c(Q1048835),P530,c(Q15617994))
action count
action atmost
action find_reverse_tuple_counts
relation P530
type Q15617994
type Q1048835
value 4
[ANSWER]
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?k ) WHERE { { SELECT DISTINCT ?e ( COUNT ( ?f ) AS ?a ) WHERE { ?f property:P530 ?e . ?e rdf:type ontology:Q15617994 . ?f rdf:type ontology:Q1048835 } GROUP BY ?e } . FILTER ( ?a <= 4 ) }
Federated States of Micronesia Panama Israel Costa Rica Yemen Peru India Argentina France Netherlands United Kingdom Algeria People's Republic of China Honduras Dominica Uzbekistan Lithuania Fiji Mongolia Kiribati Venezuela Nepal Indonesia Armenia Bahrain Serbia Chad South Africa Portugal Russia Turkey Greece El Salvador Haiti Iraq Iran Zimbabwe Afghanistan South Korea South Sudan Vietnam Eritrea Lebanon Cuba Belize Barbados Nicaragua Finland Luxembourg Belgium United States of America Tanzania Poland Sweden Philippines Central African Republic Switzerland Colombia North Korea Equatorial Guinea Saudi Arabia Paraguay Kingdom of the Netherlands Sri Lanka Guyana Laos Cambodia Suriname Lesotho Montenegro Georgia Kazakhstan Malta San Marino Norway Somalia Senegal Ireland Hungary Brunei Sudan Mauritius Malawi Iceland Pakistan Oman Belarus Mozambique Morocco Ecuador Dominican Republic Andorra Azerbaijan Bosnia and Herzegovina Croatia Albania Republic of Macedonia Mexico Cyprus Liechtenstein Japan Bangladesh Uganda Rwanda Democratic Republic of the Congo Niger Nigeria Namibia Estonia Burkina Faso Burundi Benin Botswana Nauru Chile Palau Ethiopia Kenya Ghana Trinidad and Tobago Bolivia Ukraine Czech Republic Latvia Republic of Moldova Slovakia Slovenia Romania Bulgaria Mali Bhutan Angola Guinea-Bissau Guinea Gambia Malaysia Djibouti Cameroon Côte d'Ivoire Republic of the Congo Comoros Samoa Niue Vanuatu Myanmar East Timor Turkmenistan Egypt Uruguay Syria United Arab Emirates Guatemala Tunisia Kuwait Jordan Madagascar Libya Cape Verde Togo Tonga Spain New Caledonia Thailand Zambia
164
action count
action atmost
action find_reverse_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type political territorial entity
value 4
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?k ) WHERE { { SELECT DISTINCT ?e ( COUNT ( ?f ) AS ?a ) WHERE { ?f property:diplomatic_relation ?e . ?e rdf:type ontology:designation_for_an_administrative_territorial_entity . ?f rdf:type ontology:political_territorial_entity } GROUP BY ?e } . FILTER ( ?a <= 4 ) }
[]
Comparative Reasoning (Count) (All)
Comparative|Count over More/Less|Single entity type
Q16
P530
Q1048835 Q1048835
USER
How many political territories have diplomatic relations with less number of political territories than Canada ?
(c(Q1048835),P530,c(Q1048835))
action count
action less
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
action count
action filter_type
action find
entity Q16
relation P530
type Q1048835
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?r ) AS ?v ) WHERE { { SELECT DISTINCT ?r ( COUNT ( ?l ) AS ?a ) WHERE { ?r property:P530 ?l . ?r rdf:type ontology:Q1048835 . ?l rdf:type ontology:Q1048835 } GROUP BY ?r } . { SELECT DISTINCT ( COUNT ( ?n ) AS ?k ) WHERE { resource:Q16 property:P530 ?n . ?n rdf:type ontology:Q1048835 } } . FILTER ( ?a < ?k ) }
Canada
action count
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
action count
action filter_type
action find
entity Canada
relation diplomatic relation
type political territorial entity
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?r ) AS ?v ) WHERE { { SELECT DISTINCT ?r ( COUNT ( ?l ) AS ?a ) WHERE { ?r property:diplomatic_relation ?l . ?r rdf:type ontology:political_territorial_entity . ?l rdf:type ontology:political_territorial_entity } GROUP BY ?r } . { SELECT DISTINCT ( COUNT ( ?n ) AS ?k ) WHERE { resource:Canada property:diplomatic_relation ?n . ?n rdf:type ontology:political_territorial_entity } } . FILTER ( ?a < ?k ) }
[]
political territorial entity political territorial entity
SYSTEM
10
Q1000 Q40 Q781 Q778 Q769 Q685 Q35 Q691 Q664 Q766
(c(Q1048835),P530,c(Q1048835))
action count
action less
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
action count
action filter_type
action find
entity Q16
relation P530
type Q1048835
[ANSWER]
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?r ) AS ?v ) WHERE { { SELECT DISTINCT ?r ( COUNT ( ?l ) AS ?a ) WHERE { ?r property:P530 ?l . ?r rdf:type ontology:Q1048835 . ?l rdf:type ontology:Q1048835 } GROUP BY ?r } . { SELECT DISTINCT ( COUNT ( ?n ) AS ?k ) WHERE { resource:Q16 property:P530 ?n . ?n rdf:type ontology:Q1048835 } } . FILTER ( ?a < ?k ) }
Gabon Austria Antigua and Barbuda The Bahamas Grenada Solomon Islands Denmark Papua New Guinea New Zealand Jamaica
10
action count
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
action count
action filter_type
action find
entity Canada
relation diplomatic relation
type political territorial entity
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?r ) AS ?v ) WHERE { { SELECT DISTINCT ?r ( COUNT ( ?l ) AS ?a ) WHERE { ?r property:diplomatic_relation ?l . ?r rdf:type ontology:political_territorial_entity . ?l rdf:type ontology:political_territorial_entity } GROUP BY ?r } . { SELECT DISTINCT ( COUNT ( ?n ) AS ?k ) WHERE { resource:Canada property:diplomatic_relation ?n . ?n rdf:type ontology:political_territorial_entity } } . FILTER ( ?a < ?k ) }
[]
Comparative Reasoning (Count) (All)
Comparative|Count over More/Less|Single entity type|Incomplete
Q664
P530
Q1048835 Q1048835
USER
And what about New Zealand?
(c(Q1048835),P530,c(Q1048835))
action count
action less
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
action count
action filter_type
action find
entity Q664
relation P530
type Q1048835
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?c ) AS ?r ) WHERE { { SELECT DISTINCT ?c ( COUNT ( ?f ) AS ?s ) WHERE { ?c property:P530 ?f . ?c rdf:type ontology:Q1048835 . ?f rdf:type ontology:Q1048835 } GROUP BY ?c } . { SELECT DISTINCT ( COUNT ( ?e ) AS ?p ) WHERE { resource:Q664 property:P530 ?e . ?e rdf:type ontology:Q1048835 } } . FILTER ( ?s < ?p ) }
New Zealand
action count
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
action count
action filter_type
action find
entity New Zealand
relation diplomatic relation
type political territorial entity
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?c ) AS ?r ) WHERE { { SELECT DISTINCT ?c ( COUNT ( ?f ) AS ?s ) WHERE { ?c property:diplomatic_relation ?f . ?c rdf:type ontology:political_territorial_entity . ?f rdf:type ontology:political_territorial_entity } GROUP BY ?c } . { SELECT DISTINCT ( COUNT ( ?e ) AS ?p ) WHERE { resource:New_Zealand property:diplomatic_relation ?e . ?e rdf:type ontology:political_territorial_entity } } . FILTER ( ?s < ?p ) }
[]
political territorial entity political territorial entity
SYSTEM
8
Q1000 Q40 Q781 Q778 Q769 Q685 Q691 Q766
(c(Q1048835),P530,c(Q1048835))
action count
action less
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
action count
action filter_type
action find
entity Q664
relation P530
type Q1048835
[ANSWER]
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?c ) AS ?r ) WHERE { { SELECT DISTINCT ?c ( COUNT ( ?f ) AS ?s ) WHERE { ?c property:P530 ?f . ?c rdf:type ontology:Q1048835 . ?f rdf:type ontology:Q1048835 } GROUP BY ?c } . { SELECT DISTINCT ( COUNT ( ?e ) AS ?p ) WHERE { resource:Q664 property:P530 ?e . ?e rdf:type ontology:Q1048835 } } . FILTER ( ?s < ?p ) }
Gabon Austria Antigua and Barbuda The Bahamas Grenada Solomon Islands Papua New Guinea Jamaica
8
action count
action less
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
action count
action filter_type
action find
entity New Zealand
relation diplomatic relation
type political territorial entity
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?c ) AS ?r ) WHERE { { SELECT DISTINCT ?c ( COUNT ( ?f ) AS ?s ) WHERE { ?c property:diplomatic_relation ?f . ?c rdf:type ontology:political_territorial_entity . ?f rdf:type ontology:political_territorial_entity } GROUP BY ?c } . { SELECT DISTINCT ( COUNT ( ?e ) AS ?p ) WHERE { resource:New_Zealand property:diplomatic_relation ?e . ?e rdf:type ontology:political_territorial_entity } } . FILTER ( ?s < ?p ) }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count over Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P530
Q1048835 Q15617994
USER
How many administrative territories are known to have diplomatic connections with approximately 7 political territories ?
(c(Q15617994),P530,c(Q1048835))
action count
action approx
action find_tuple_counts
relation P530
type Q15617994
type Q1048835
value 7
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?m ) WHERE { FILTER ( ?v = 7 ) . { SELECT DISTINCT ?e ( COUNT ( ?k ) AS ?v ) WHERE { ?e property:P530 ?k . ?e rdf:type ontology:Q15617994 . ?k rdf:type ontology:Q1048835 } GROUP BY ?e } }
action count
action approx
action find_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type political territorial entity
value 7
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?m ) WHERE { FILTER ( ?v = 7 ) . { SELECT DISTINCT ?e ( COUNT ( ?k ) AS ?v ) WHERE { ?e property:diplomatic_relation ?k . ?e rdf:type ontology:designation_for_an_administrative_territorial_entity . ?k rdf:type ontology:political_territorial_entity } GROUP BY ?e } }
[]
political territorial entity designation for an administrative territorial entity
SYSTEM
1
Q38
(c(Q15617994),P530,c(Q1048835))
action count
action approx
action find_tuple_counts
relation P530
type Q15617994
type Q1048835
value 7
[ANSWER]
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?m ) WHERE { FILTER ( ?v = 7 ) . { SELECT DISTINCT ?e ( COUNT ( ?k ) AS ?v ) WHERE { ?e property:P530 ?k . ?e rdf:type ontology:Q15617994 . ?k rdf:type ontology:Q1048835 } GROUP BY ?e } }
Italy
1
action count
action approx
action find_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type political territorial entity
value 7
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ( COUNT ( ?e ) AS ?m ) WHERE { FILTER ( ?v = 7 ) . { SELECT DISTINCT ?e ( COUNT ( ?k ) AS ?v ) WHERE { ?e property:diplomatic_relation ?k . ?e rdf:type ontology:designation_for_an_administrative_territorial_entity . ?k rdf:type ontology:political_territorial_entity } GROUP BY ?e } }
[]
Quantitative Reasoning (All)
Quantitative|Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P530
Q1048835 Q1048835
USER
Which political territories have diplomatic relationships with around 5 political territories ?
(c(Q1048835),P530,c(Q1048835))
action approx
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
value 5
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?x WHERE { FILTER ( ?z = 5 ) . { SELECT DISTINCT ?x ( COUNT ( ?w ) AS ?z ) WHERE { ?x property:P530 ?w . ?x rdf:type ontology:Q1048835 . ?w rdf:type ontology:Q1048835 } GROUP BY ?x } }
action approx
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
value 5
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?x WHERE { FILTER ( ?z = 5 ) . { SELECT DISTINCT ?x ( COUNT ( ?w ) AS ?z ) WHERE { ?x property:diplomatic_relation ?w . ?x rdf:type ontology:political_territorial_entity . ?w rdf:type ontology:political_territorial_entity } GROUP BY ?x } }
[]
political territorial entity political territorial entity
Q183 Q35 Q16
SYSTEM
Germany, Denmark, Canada
Q183 Q35 Q16 Q664
(c(Q1048835),P530,c(Q1048835))
action approx
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
value 5
[ANSWERS] have diplomatic relationships with around 5 political territories
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?x WHERE { FILTER ( ?z = 5 ) . { SELECT DISTINCT ?x ( COUNT ( ?w ) AS ?z ) WHERE { ?x property:P530 ?w . ?x rdf:type ontology:Q1048835 . ?w rdf:type ontology:Q1048835 } GROUP BY ?x } }
Germany Denmark Canada New Zealand
Germany, Denmark and Canada have diplomatic relationships with around 5 political territories
Germany Denmark Canada
action approx
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
value 5
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?x WHERE { FILTER ( ?z = 5 ) . { SELECT DISTINCT ?x ( COUNT ( ?w ) AS ?z ) WHERE { ?x property:diplomatic_relation ?w . ?x rdf:type ontology:political_territorial_entity . ?w rdf:type ontology:political_territorial_entity } GROUP BY ?x } }
[]
Verification (Boolean) (All)
Verification|one entity, multiple entities (as object) referred indirectly
Q408
P530
Q1048835
USER
Do Australia have ambassadorial relations with those ones ?
(Q408,P530,Q183) (Q408,P530,Q35) (Q408,P530,Q16)
action is_in
entity prev_answer
action find
entity Q408
relation P530
['Q408', 'P530', 'Q183'] ['Q408', 'P530', 'Q35'] ['Q408', 'P530', 'Q16']
ASK WHERE { resource:Q408 property:P530 ?i . VALUES ( ?i ) { ( resource:Q183 ) ( resource:Q35 ) ( resource:Q16 ) } }
Australia
action is_in
entity prev_answer
action find
entity Australia
relation diplomatic relation
['Australia', 'diplomatic relation', 'Germany'] ['Australia', 'diplomatic relation', 'Denmark'] ['Australia', 'diplomatic relation', 'Canada']
ASK WHERE { resource:Australia property:diplomatic_relation ?i . VALUES ( ?i ) { ( resource:Germany ) ( resource:Denmark ) ( resource:Canada ) } }
[]
political territorial entity
SYSTEM
YES
(Q408,P530,Q183) (Q408,P530,Q35) (Q408,P530,Q16)
action is_in
entity prev_answer
action find
entity Q408
relation P530
[ANSWER]
['Q408', 'P530', 'Q183'] ['Q408', 'P530', 'Q35'] ['Q408', 'P530', 'Q16']
ASK WHERE { resource:Q408 property:P530 ?i . VALUES ( ?i ) { ( resource:Q183 ) ( resource:Q35 ) ( resource:Q16 ) } }
Yes
action is_in
entity prev_answer
action find
entity Australia
relation diplomatic relation
['Australia', 'diplomatic relation', 'Germany'] ['Australia', 'diplomatic relation', 'Denmark'] ['Australia', 'diplomatic relation', 'Canada']
ASK WHERE { resource:Australia property:diplomatic_relation ?i . VALUES ( ?i ) { ( resource:Germany ) ( resource:Denmark ) ( resource:Canada ) } }
[]
Quantitative Reasoning (All)
Quantitative|Min/Max|Single entity type
P530
Q1048835 Q15617994
USER
Which administrative territories have diplomatic associations with min number of political territories ?
(c(Q15617994),P530,c(Q1048835))
action argmin
action find_tuple_counts
relation P530
type Q15617994
type Q1048835
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ( MIN ( ?n ) AS ?z ) { SELECT DISTINCT ?a ( COUNT ( ?q ) AS ?n ) WHERE { ?a property:P530 ?q . ?a rdf:type ontology:Q15617994 . ?q rdf:type ontology:Q1048835 } GROUP BY ?a } } . { SELECT DISTINCT ?r ( COUNT ( ?d ) AS ?j ) WHERE { ?r rdf:type ontology:Q15617994 . ?d rdf:type ontology:Q1048835 . ?r property:P530 ?d } GROUP BY ?r } . FILTER ( ?j = ?z ) }
action argmin
action find_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type political territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ( MIN ( ?n ) AS ?z ) { SELECT DISTINCT ?a ( COUNT ( ?q ) AS ?n ) WHERE { ?a property:diplomatic_relation ?q . ?a rdf:type ontology:designation_for_an_administrative_territorial_entity . ?q rdf:type ontology:political_territorial_entity } GROUP BY ?a } } . { SELECT DISTINCT ?r ( COUNT ( ?d ) AS ?j ) WHERE { ?r rdf:type ontology:designation_for_an_administrative_territorial_entity . ?d rdf:type ontology:political_territorial_entity . ?r property:diplomatic_relation ?d } GROUP BY ?r } . FILTER ( ?j = ?z ) }
[]
political territorial entity designation for an administrative territorial entity
Q805 Q858 Q842
SYSTEM
Yemen, Syria, Oman
Q805 Q399 Q398 Q790 Q236 Q842 Q858
(c(Q15617994),P530,c(Q1048835))
action argmin
action find_tuple_counts
relation P530
type Q15617994
type Q1048835
[ANSWERS] have diplomatic associations with min number of political territories
[{'concept': 'Q15617994'}, 'P530', {'concept': 'Q1048835'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ( MIN ( ?n ) AS ?z ) { SELECT DISTINCT ?a ( COUNT ( ?q ) AS ?n ) WHERE { ?a property:P530 ?q . ?a rdf:type ontology:Q15617994 . ?q rdf:type ontology:Q1048835 } GROUP BY ?a } } . { SELECT DISTINCT ?r ( COUNT ( ?d ) AS ?j ) WHERE { ?r rdf:type ontology:Q15617994 . ?d rdf:type ontology:Q1048835 . ?r property:P530 ?d } GROUP BY ?r } . FILTER ( ?j = ?z ) }
Yemen Armenia Bahrain Haiti Montenegro Oman Syria
Yemen, Syria and Oman have diplomatic associations with min number of political territories
Yemen Syria Oman
action argmin
action find_tuple_counts
relation diplomatic relation
type designation for an administrative territorial entity
type political territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', {'concept': 'political territorial entity'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ( MIN ( ?n ) AS ?z ) { SELECT DISTINCT ?a ( COUNT ( ?q ) AS ?n ) WHERE { ?a property:diplomatic_relation ?q . ?a rdf:type ontology:designation_for_an_administrative_territorial_entity . ?q rdf:type ontology:political_territorial_entity } GROUP BY ?a } } . { SELECT DISTINCT ?r ( COUNT ( ?d ) AS ?j ) WHERE { ?r rdf:type ontology:designation_for_an_administrative_territorial_entity . ?d rdf:type ontology:political_territorial_entity . ?r property:diplomatic_relation ?d } GROUP BY ?r } . FILTER ( ?j = ?z ) }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q796 Q842
P1532
Q6979593
USER
Which national association football teams play for Oman or Iraq ?
OR((c(Q6979593),P1532,Q842), (c(Q6979593),P1532,Q796))
action filter_type
action union
action find_reverse
entity Q842
relation P1532
action find_reverse
entity Q796
relation P1532
type Q6979593
{'OR': [[{'concept': 'Q6979593'}, 'P1532', 'Q842'], [{'concept': 'Q6979593'}, 'P1532', 'Q796']]}
SELECT DISTINCT ?k WHERE { { { ?k property:P1532 resource:Q796 } UNION { ?k property:P1532 resource:Q842 } } . ?k rdf:type ontology:Q6979593 }
Iraq Oman
action filter_type
action union
action find_reverse
entity Oman
relation country for sport
action find_reverse
entity Iraq
relation country for sport
type national association football team
{'OR': [[{'concept': 'national association football team'}, 'country for sport', 'Oman'], [{'concept': 'national association football team'}, 'country for sport', 'Iraq']]}
SELECT DISTINCT ?k WHERE { { { ?k property:country_for_sport resource:Iraq } UNION { ?k property:country_for_sport resource:Oman } } . ?k rdf:type ontology:national_association_football_team }
[]
national association football team
Q7089559 Q23882681 Q6067941 Q23892328
SYSTEM
Oman women's national football team, Iraq Olympic football team, Iraq women's national football team, Oman national under-23 football team
Q7089559 Q23882681 Q6067941 Q23892328
OR((c(Q6979593),P1532,Q842), (c(Q6979593),P1532,Q796))
action filter_type
action union
action find_reverse
entity Q842
relation P1532
action find_reverse
entity Q796
relation P1532
type Q6979593
[ANSWERS] play for Oman or Iraq
{'OR': [[{'concept': 'Q6979593'}, 'P1532', 'Q842'], [{'concept': 'Q6979593'}, 'P1532', 'Q796']]}
SELECT DISTINCT ?k WHERE { { { ?k property:P1532 resource:Q796 } UNION { ?k property:P1532 resource:Q842 } } . ?k rdf:type ontology:Q6979593 }
Oman women's national football team Iraq Olympic football team Iraq women's national football team Oman national under-23 football team
Oman women's national football team, Iraq Olympic football team, Iraq women's national football team and Oman national under-23 football team play for Oman or Iraq
Oman women's national football team Iraq Olympic football team Iraq women's national football team Oman national under-23 football team
action filter_type
action union
action find_reverse
entity Oman
relation country for sport
action find_reverse
entity Iraq
relation country for sport
type national association football team
{'OR': [[{'concept': 'national association football team'}, 'country for sport', 'Oman'], [{'concept': 'national association football team'}, 'country for sport', 'Iraq']]}
SELECT DISTINCT ?k WHERE { { { ?k property:country_for_sport resource:Iraq } UNION { ?k property:country_for_sport resource:Oman } } . ?k rdf:type ontology:national_association_football_team }
[]