Simple Question (Direct)
Simple Question
Q200850
P19
Q13220204
USER
Which administrative country subdivision was János Kádár born in ?
(Q200850,P19,c(Q13220204))
action filter_type
action find
entity Q200850
relation P19
type Q13220204
['Q200850', 'P19', {'concept': 'Q13220204'}]
SELECT DISTINCT ?y WHERE { resource:Q200850 property:P19 ?y . ?y rdf:type ontology:Q13220204 }
János Kádár
action filter_type
action find
entity János Kádár
relation place of birth
type second-level administrative country subdivision
['János Kádár', 'place of birth', {'concept': 'second-level administrative country subdivision'}]
SELECT DISTINCT ?y WHERE { resource:János_Kádár property:place_of_birth ?y . ?y rdf:type ontology:second-level_administrative_country_subdivision }
[]
second-level administrative country subdivision
Q1647
SYSTEM
Rijeka
Q1647
(Q200850,P19,c(Q13220204))
action filter_type
action find
entity Q200850
relation P19
type Q13220204
János Kádár was born in [ANSWER]
['Q200850', 'P19', {'concept': 'Q13220204'}]
SELECT DISTINCT ?y WHERE { resource:Q200850 property:P19 ?y . ?y rdf:type ontology:Q13220204 }
Rijeka
János Kádár was born in Rijeka
Rijeka
action filter_type
action find
entity János Kádár
relation place of birth
type second-level administrative country subdivision
['János Kádár', 'place of birth', {'concept': 'second-level administrative country subdivision'}]
SELECT DISTINCT ?y WHERE { resource:János_Kádár property:place_of_birth ?y . ?y rdf:type ontology:second-level_administrative_country_subdivision }
[]
Simple Question (Coreferenced)
Simple Question|Single Entity|Indirect
Q200850
P488
Q7278
USER
Which political party has that person as its chairperson ?
(c(Q7278),P488,Q1647)
action filter_type
action find_reverse
entity Q200850
relation P488
type Q7278
[{'concept': 'Q7278'}, 'P488', 'Q1647']
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:Q7278 . ?w property:P488 resource:Q200850 }
János Kádár
action filter_type
action find_reverse
entity János Kádár
relation chairperson
type political party
[{'concept': 'political party'}, 'chairperson', 'Rijeka']
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:political_party . ?w property:chairperson resource:János_Kádár }
[]
political party
Q537649
SYSTEM
Communist Party of Hungary
Q537649
(c(Q7278),P488,Q1647)
action filter_type
action find_reverse
entity Q200850
relation P488
type Q7278
The [ANSWER] has that person as its chairperson
[{'concept': 'Q7278'}, 'P488', 'Q1647']
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:Q7278 . ?w property:P488 resource:Q200850 }
Communist Party of Hungary
The Communist Party of Hungary has that person as its chairperson
Communist Party of Hungary
action filter_type
action find_reverse
entity János Kádár
relation chairperson
type political party
[{'concept': 'political party'}, 'chairperson', 'Rijeka']
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:political_party . ?w property:chairperson resource:János_Kádár }
[]
Verification (Boolean) (All)
Verification|2 entities, both direct
Q537649 Q200850
P488
Q502895
USER
Was János Kádár the chairperson of Communist Party of Hungary ?
(Q537649,P488,Q200850)
action is_in
entity Q200850
action find
entity Q537649
relation P488
['Q537649', 'P488', 'Q200850']
ASK WHERE { resource:Q537649 property:P488 resource:Q200850 }
Communist Party of Hungary János Kádár
action is_in
entity János Kádár
action find
entity Communist Party of Hungary
relation chairperson
['Communist Party of Hungary', 'chairperson', 'János Kádár']
ASK WHERE { resource:Communist_Party_of_Hungary property:chairperson resource:János_Kádár }
[]
common name
SYSTEM
YES
(Q537649,P488,Q200850)
action is_in
entity Q200850
action find
entity Q537649
relation P488
[ANSWER]
['Q537649', 'P488', 'Q200850']
ASK WHERE { resource:Q537649 property:P488 resource:Q200850 }
Yes
action is_in
entity János Kádár
action find
entity Communist Party of Hungary
relation chairperson
['Communist Party of Hungary', 'chairperson', 'János Kádár']
ASK WHERE { resource:Communist_Party_of_Hungary property:chairperson resource:János_Kádár }
[]
Verification (Boolean) (All)
Verification|3 entities, all direct, 2 are query entities
Q1647 Q45999 Q224
P17
Q15617994
USER
Is Rijeka present in Eichhorst and Croatia ?
(Q1647,P17,Q45999) (Q1647,P17,Q224)
action is_in
entity Q1647
action intersection
action find_reverse
entity Q45999
relation P17
action find_reverse
entity Q224
relation P17
['Q1647', 'P17', 'Q45999'] ['Q1647', 'P17', 'Q224']
ASK WHERE { resource:Q1647 property:P17 resource:Q224 . resource:Q1647 property:P17 resource:Q45999 }
Rijeka Eichhorst Croatia
action is_in
entity Rijeka
action intersection
action find_reverse
entity Eichhorst
relation country
action find_reverse
entity Croatia
relation country
['Rijeka', 'country', 'Eichhorst'] ['Rijeka', 'country', 'Croatia']
ASK WHERE { resource:Rijeka property:country resource:Croatia . resource:Rijeka property:country resource:Eichhorst }
[]
designation for an administrative territorial entity
SYSTEM
NO and YES respectively
(Q1647,P17,Q45999) (Q1647,P17,Q224)
action is_in
entity Q1647
action intersection
action find_reverse
entity Q45999
relation P17
action find_reverse
entity Q224
relation P17
[ANSWER]
['Q1647', 'P17', 'Q45999'] ['Q1647', 'P17', 'Q224']
ASK WHERE { resource:Q1647 property:P17 resource:Q224 . resource:Q1647 property:P17 resource:Q45999 }
NO and YES respectively
action is_in
entity Rijeka
action intersection
action find_reverse
entity Eichhorst
relation country
action find_reverse
entity Croatia
relation country
['Rijeka', 'country', 'Eichhorst'] ['Rijeka', 'country', 'Croatia']
ASK WHERE { resource:Rijeka property:country resource:Croatia . resource:Rijeka property:country resource:Eichhorst }
[]
Verification (Boolean) (All)
Verification|3 entities, all direct, 2 are query entities
Q537649 Q200850 Q5553359
P488
Q502895
USER
Does János Kádár and Tage Andersen lead Communist Party of Hungary ?
(Q537649,P488,Q200850) (Q537649,P488,Q5553359)
action is_in
entity Q537649
action intersection
action find_reverse
entity Q200850
relation P488
action find_reverse
entity Q5553359
relation P488
['Q537649', 'P488', 'Q200850'] ['Q537649', 'P488', 'Q5553359']
ASK WHERE { resource:Q537649 property:P488 resource:Q200850 . resource:Q537649 property:P488 resource:Q5553359 }
Communist Party of Hungary János Kádár Tage Andersen
action is_in
entity Communist Party of Hungary
action intersection
action find_reverse
entity János Kádár
relation chairperson
action find_reverse
entity Tage Andersen
relation chairperson
['Communist Party of Hungary', 'chairperson', 'János Kádár'] ['Communist Party of Hungary', 'chairperson', 'Tage Andersen']
ASK WHERE { resource:Communist_Party_of_Hungary property:chairperson resource:János_Kádár . resource:Communist_Party_of_Hungary property:chairperson resource:Tage_Andersen }
[]
common name
SYSTEM
YES and NO respectively
(Q537649,P488,Q200850) (Q537649,P488,Q5553359)
action is_in
entity Q537649
action intersection
action find_reverse
entity Q200850
relation P488
action find_reverse
entity Q5553359
relation P488
[ANSWER]
['Q537649', 'P488', 'Q200850'] ['Q537649', 'P488', 'Q5553359']
ASK WHERE { resource:Q537649 property:P488 resource:Q200850 . resource:Q537649 property:P488 resource:Q5553359 }
YES and NO respectively
action is_in
entity Communist Party of Hungary
action intersection
action find_reverse
entity János Kádár
relation chairperson
action find_reverse
entity Tage Andersen
relation chairperson
['Communist Party of Hungary', 'chairperson', 'János Kádár'] ['Communist Party of Hungary', 'chairperson', 'Tage Andersen']
ASK WHERE { resource:Communist_Party_of_Hungary property:chairperson resource:János_Kádár . resource:Communist_Party_of_Hungary property:chairperson resource:Tage_Andersen }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q889338 Q1647
P17
Q15617994
USER
Which administrative territories are Rijeka or Chhaprabhatha located in ?
OR((Q1647,P17,c(Q15617994)), (Q889338,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q1647
relation P17
action find
entity Q889338
relation P17
type Q15617994
{'OR': [['Q1647', 'P17', {'concept': 'Q15617994'}], ['Q889338', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?v WHERE { { ?j property:P17 ?v . VALUES ( ?j ) { ( resource:Q1647 ) ( resource:Q889338 ) } } . ?v rdf:type ontology:Q15617994 }
Chhaprabhatha Rijeka
action filter_type
action union
action find
entity Rijeka
relation country
action find
entity Chhaprabhatha
relation country
type designation for an administrative territorial entity
{'OR': [['Rijeka', 'country', {'concept': 'designation for an administrative territorial entity'}], ['Chhaprabhatha', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?v WHERE { { ?j property:country ?v . VALUES ( ?j ) { ( resource:Rijeka ) ( resource:Chhaprabhatha ) } } . ?v rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q224 Q668
SYSTEM
Croatia, India
Q224 Q668
OR((Q1647,P17,c(Q15617994)), (Q889338,P17,c(Q15617994)))
action filter_type
action union
action find
entity Q1647
relation P17
action find
entity Q889338
relation P17
type Q15617994
Rijeka or Chhaprabhatha are located in [ANSWERS]
{'OR': [['Q1647', 'P17', {'concept': 'Q15617994'}], ['Q889338', 'P17', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?v WHERE { { ?j property:P17 ?v . VALUES ( ?j ) { ( resource:Q1647 ) ( resource:Q889338 ) } } . ?v rdf:type ontology:Q15617994 }
Croatia India
Rijeka or Chhaprabhatha are located in Croatia and India
Croatia India
action filter_type
action union
action find
entity Rijeka
relation country
action find
entity Chhaprabhatha
relation country
type designation for an administrative territorial entity
{'OR': [['Rijeka', 'country', {'concept': 'designation for an administrative territorial entity'}], ['Chhaprabhatha', 'country', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?v WHERE { { ?j property:country ?v . VALUES ( ?j ) { ( resource:Rijeka ) ( resource:Chhaprabhatha ) } } . ?v rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Clarification
Quantitative|Count|Logical operators|Indirect
P530
Q1048835 Q15617994
USER
How many political territories and administrative territories have diplomatic relationships with that administrative territory ?
(Q224,P530,c(Q1048835)) (Q224,P530,c(Q15617994)) (Q224,P530,c(Q1048835)) (Q224,P530,c(Q15617994)) (Q668,P530,c(Q1048835)) (Q668,P530,c(Q15617994))
['Q224', 'P530', {'concept': 'Q1048835'}] ['Q224', 'P530', {'concept': 'Q15617994'}] ['Q224', 'P530', {'concept': 'Q1048835'}] ['Q224', 'P530', {'concept': 'Q15617994'}] ['Q668', 'P530', {'concept': 'Q1048835'}] ['Q668', 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?x ) WHERE { { { resource:Q224 property:P530 ?z } UNION { resource:Q224 property:P530 ?y } UNION { resource:Q224 property:P530 ?z } UNION { resource:Q224 property:P530 ?y } UNION { resource:Q1488929 property:P530 ?z } UNION { resource:Q1488929 property:P530 ?y } } . ?z rdf:type ontology:Q1048835 . ?y rdf:type ontology:Q15617994 }
['Croatia', 'diplomatic relation', {'concept': 'political territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'political territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}] ['India', 'diplomatic relation', {'concept': 'political territorial entity'}] ['India', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?x ) WHERE { { { resource:Croatia property:diplomatic_relation ?z } UNION { resource:Croatia property:diplomatic_relation ?y } UNION { resource:Croatia property:diplomatic_relation ?z } UNION { resource:Croatia property:diplomatic_relation ?y } UNION { resource:India property:diplomatic_relation ?z } UNION { resource:India property:diplomatic_relation ?y } } . ?z rdf:type ontology:political_territorial_entity . ?y rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
political territorial entity designation for an administrative territorial entity
Quantitative|Count|Mult. entity type|Clarification
Q668
SYSTEM
Did you mean India ?
[ANSWER]
SELECT DISTINCT ( COUNT ( ?z ) AS ?x ) WHERE { { { resource:Q224 property:P530 ?z } UNION { resource:Q224 property:P530 ?y } UNION { resource:Q224 property:P530 ?z } UNION { resource:Q224 property:P530 ?y } UNION { resource:Q1488929 property:P530 ?z } UNION { resource:Q1488929 property:P530 ?y } } . ?z rdf:type ontology:Q1048835 . ?y rdf:type ontology:Q15617994 }
Did you mean India ?
India
SELECT DISTINCT ( COUNT ( ?z ) AS ?x ) WHERE { { { resource:Croatia property:diplomatic_relation ?z } UNION { resource:Croatia property:diplomatic_relation ?y } UNION { resource:Croatia property:diplomatic_relation ?z } UNION { resource:Croatia property:diplomatic_relation ?y } UNION { resource:India property:diplomatic_relation ?z } UNION { resource:India property:diplomatic_relation ?y } } . ?z rdf:type ontology:political_territorial_entity . ?y rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Quantitative Reasoning (Count) (All)
USER
No, I meant Croatia. Could you tell me the answer for that?
(Q224,P530,c(Q1048835)) (Q224,P530,c(Q15617994)) (Q224,P530,c(Q1048835)) (Q224,P530,c(Q15617994)) (Q668,P530,c(Q1048835)) (Q668,P530,c(Q15617994))
Q224
['Q224', 'P530', {'concept': 'Q1048835'}] ['Q224', 'P530', {'concept': 'Q15617994'}] ['Q224', 'P530', {'concept': 'Q1048835'}] ['Q224', 'P530', {'concept': 'Q15617994'}] ['Q668', 'P530', {'concept': 'Q1048835'}] ['Q668', 'P530', {'concept': 'Q15617994'}]
['Croatia', 'diplomatic relation', {'concept': 'political territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'political territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}] ['India', 'diplomatic relation', {'concept': 'political territorial entity'}] ['India', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
[]
SYSTEM
2 political territories and 1 administrative territories
Q408 Q38 Q183
(Q224,P530,c(Q1048835)) (Q224,P530,c(Q15617994)) (Q224,P530,c(Q1048835)) (Q224,P530,c(Q15617994)) (Q668,P530,c(Q1048835)) (Q668,P530,c(Q15617994))
[ANSWER]
['Q224', 'P530', {'concept': 'Q1048835'}] ['Q224', 'P530', {'concept': 'Q15617994'}] ['Q224', 'P530', {'concept': 'Q1048835'}] ['Q224', 'P530', {'concept': 'Q15617994'}] ['Q668', 'P530', {'concept': 'Q1048835'}] ['Q668', 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?x ) WHERE { { { resource:Q224 property:P530 ?z } UNION { resource:Q224 property:P530 ?y } UNION { resource:Q224 property:P530 ?z } UNION { resource:Q224 property:P530 ?y } UNION { resource:Q1488929 property:P530 ?z } UNION { resource:Q1488929 property:P530 ?y } } . ?z rdf:type ontology:Q1048835 . ?y rdf:type ontology:Q15617994 }
Australia Italy Germany
2 political territories and 1 administrative territories
['Croatia', 'diplomatic relation', {'concept': 'political territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'political territorial entity'}] ['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}] ['India', 'diplomatic relation', {'concept': 'political territorial entity'}] ['India', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?x ) WHERE { { { resource:Croatia property:diplomatic_relation ?z } UNION { resource:Croatia property:diplomatic_relation ?y } UNION { resource:Croatia property:diplomatic_relation ?z } UNION { resource:Croatia property:diplomatic_relation ?y } UNION { resource:India property:diplomatic_relation ?z } UNION { resource:India property:diplomatic_relation ?y } } . ?z rdf:type ontology:political_territorial_entity . ?y rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Quantitative Reasoning (All)
Quantitative|Min/Max|Single entity type
P530
Q1048835 Q15617994
USER
Which political territories holds diplomatic relationship with max number of administrative territories ?
(c(Q15617994),P530,Q766)
action argmax
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
[{'concept': 'Q15617994'}, 'P530', 'Q766']
SELECT DISTINCT ?x WHERE { { SELECT DISTINCT ( MAX ( ?q ) AS ?s ) { SELECT DISTINCT ?z ( COUNT ( ?y ) AS ?q ) WHERE { ?z property:P530 ?y . ?z rdf:type ontology:Q1048835 . ?y rdf:type ontology:Q15617994 } GROUP BY ?z } } . FILTER ( ?c = ?s ) . { SELECT DISTINCT ?x ( COUNT ( ?v ) AS ?c ) WHERE { ?x property:P530 ?v . ?x rdf:type ontology:Q1048835 . ?v rdf:type ontology:Q15617994 } GROUP BY ?x } }
action argmax
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', 'Jamaica']
SELECT DISTINCT ?x WHERE { { SELECT DISTINCT ( MAX ( ?q ) AS ?s ) { SELECT DISTINCT ?z ( COUNT ( ?y ) AS ?q ) WHERE { ?z property:diplomatic_relation ?y . ?z rdf:type ontology:political_territorial_entity . ?y rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?z } } . FILTER ( ?c = ?s ) . { SELECT DISTINCT ?x ( COUNT ( ?v ) AS ?c ) WHERE { ?x property:diplomatic_relation ?v . ?x rdf:type ontology:political_territorial_entity . ?v rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?x } }
[]
political territorial entity designation for an administrative territorial entity
Q183
SYSTEM
Germany
Q183
(c(Q15617994),P530,Q766)
action argmax
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
[ANSWER] holds diplomatic relationship with max number of administrative territories
[{'concept': 'Q15617994'}, 'P530', 'Q766']
SELECT DISTINCT ?x WHERE { { SELECT DISTINCT ( MAX ( ?q ) AS ?s ) { SELECT DISTINCT ?z ( COUNT ( ?y ) AS ?q ) WHERE { ?z property:P530 ?y . ?z rdf:type ontology:Q1048835 . ?y rdf:type ontology:Q15617994 } GROUP BY ?z } } . FILTER ( ?c = ?s ) . { SELECT DISTINCT ?x ( COUNT ( ?v ) AS ?c ) WHERE { ?x property:P530 ?v . ?x rdf:type ontology:Q1048835 . ?v rdf:type ontology:Q15617994 } GROUP BY ?x } }
Germany
Germany holds diplomatic relationship with max number of administrative territories
Germany
action argmax
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
[{'concept': 'designation for an administrative territorial entity'}, 'diplomatic relation', 'Jamaica']
SELECT DISTINCT ?x WHERE { { SELECT DISTINCT ( MAX ( ?q ) AS ?s ) { SELECT DISTINCT ?z ( COUNT ( ?y ) AS ?q ) WHERE { ?z property:diplomatic_relation ?y . ?z rdf:type ontology:political_territorial_entity . ?y rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?z } } . FILTER ( ?c = ?s ) . { SELECT DISTINCT ?x ( COUNT ( ?v ) AS ?c ) WHERE { ?x property:diplomatic_relation ?v . ?x rdf:type ontology:political_territorial_entity . ?v rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?x } }
[]
Logical Reasoning (All)
Logical|Union|Multiple_Relation
Q11533108 Q224
P530 P27
Q15617994
USER
Which administrative territories have diplomatic relationships with Croatia or do Eiichi Hayashi belong to ?
OR((Q224,P530,c(Q15617994)), (Q11533108,P27,c(Q15617994)))
action filter_type
action union
action find
entity Q224
relation P530
action find
entity Q11533108
relation P27
type Q15617994
{'OR': [['Q224', 'P530', {'concept': 'Q15617994'}], ['Q11533108', 'P27', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Q224 property:P530 ?f } UNION { resource:Q11533108 property:P27 ?f } } . ?f rdf:type ontology:Q15617994 }
Eiichi Hayashi Croatia
action filter_type
action union
action find
entity Croatia
relation diplomatic relation
action find
entity Eiichi Hayashi
relation country of citizenship
type designation for an administrative territorial entity
{'OR': [['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}], ['Eiichi Hayashi', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Croatia property:diplomatic_relation ?f } UNION { resource:Eiichi_Hayashi property:country_of_citizenship ?f } } . ?f rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q17 Q38
SYSTEM
Japan, Italy
Q17 Q38
OR((Q224,P530,c(Q15617994)), (Q11533108,P27,c(Q15617994)))
action filter_type
action union
action find
entity Q224
relation P530
action find
entity Q11533108
relation P27
type Q15617994
[ANSWERS] have diplomatic relationships with Croatia or do Eiichi Hayashi belong to
{'OR': [['Q224', 'P530', {'concept': 'Q15617994'}], ['Q11533108', 'P27', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Q224 property:P530 ?f } UNION { resource:Q11533108 property:P27 ?f } } . ?f rdf:type ontology:Q15617994 }
Japan Italy
Japan and Italy have diplomatic relationships with Croatia or do Eiichi Hayashi belong to
Japan Italy
action filter_type
action union
action find
entity Croatia
relation diplomatic relation
action find
entity Eiichi Hayashi
relation country of citizenship
type designation for an administrative territorial entity
{'OR': [['Croatia', 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}], ['Eiichi Hayashi', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?f WHERE { { { resource:Croatia property:diplomatic_relation ?f } UNION { resource:Eiichi_Hayashi property:country_of_citizenship ?f } } . ?f rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Logical Reasoning (All)
Logical|Intersection|Multiple_Relation
Q6581097 Q537649
P21 P102
Q502895
USER
Which people belong to the political party named Communist Party of Hungary and have the gender as male ?
AND((c(Q502895),P102,Q537649), (c(Q502895),P21,Q6581097))
action filter_type
action intersection
action find_reverse
entity Q537649
relation P102
action find_reverse
entity Q6581097
relation P21
type Q502895
{'AND': [[{'concept': 'Q502895'}, 'P102', 'Q537649'], [{'concept': 'Q502895'}, 'P21', 'Q6581097']]}
SELECT DISTINCT ?e WHERE { ?e rdf:type ontology:Q502895 . ?e property:P102 resource:Q537649 . ?e property:P21 resource:Q6581097 }
male Communist Party of Hungary
action filter_type
action intersection
action find_reverse
entity Communist Party of Hungary
relation member of political party
action find_reverse
entity male
relation gender
type common name
{'AND': [[{'concept': 'common name'}, 'member of political party', 'Communist Party of Hungary'], [{'concept': 'common name'}, 'gender', 'male']]}
SELECT DISTINCT ?e WHERE { ?e rdf:type ontology:common_name . ?e property:member_of_political_party resource:Communist_Party_of_Hungary . ?e property:gender resource:male }
[]
common name
Q1042495 Q207631 Q1128999 Q151646 Q1055579 Q177917 Q598216
SYSTEM
Gyula Kállai, Mátyás Rákosi, József Lengyel, Béla Kun, Horváth Márton, Imre Nagy, György Lázár
Q1042495 Q207631 Q1128999 Q151646 Q1055579 Q177917 Q598216
AND((c(Q502895),P102,Q537649), (c(Q502895),P21,Q6581097))
action filter_type
action intersection
action find_reverse
entity Q537649
relation P102
action find_reverse
entity Q6581097
relation P21
type Q502895
[ANSWERS] belong to the political party named Communist Party of Hungary and have the gender as male
{'AND': [[{'concept': 'Q502895'}, 'P102', 'Q537649'], [{'concept': 'Q502895'}, 'P21', 'Q6581097']]}
SELECT DISTINCT ?e WHERE { ?e rdf:type ontology:Q502895 . ?e property:P102 resource:Q537649 . ?e property:P21 resource:Q6581097 }
Gyula Kállai Mátyás Rákosi József Lengyel Béla Kun Horváth Márton Imre Nagy György Lázár
Gyula Kállai, Mátyás Rákosi, József Lengyel, Béla Kun, Horváth Márton, Imre Nagy and György Lázár belong to the political party named Communist Party of Hungary and have the gender as male
Gyula Kállai Mátyás Rákosi József Lengyel Béla Kun Horváth Márton Imre Nagy György Lázár
action filter_type
action intersection
action find_reverse
entity Communist Party of Hungary
relation member of political party
action find_reverse
entity male
relation gender
type common name
{'AND': [[{'concept': 'common name'}, 'member of political party', 'Communist Party of Hungary'], [{'concept': 'common name'}, 'gender', 'male']]}
SELECT DISTINCT ?e WHERE { ?e rdf:type ontology:common_name . ?e property:member_of_political_party resource:Communist_Party_of_Hungary . ?e property:gender resource:male }
[]
Comparative Reasoning (All)
Comparative|More/Less|Single entity type
Q497224
P1303
Q34379 Q502895
USER
Which musical instruments do more number of people know to play than Kayamb ?
(c(Q502895),P1303,c(Q34379))
action greater
action find_reverse_tuple_counts
relation P1303
type Q34379
type Q502895
action count
action filter_type
action find
entity Q497224
relation P1303
type Q34379
[{'concept': 'Q502895'}, 'P1303', {'concept': 'Q34379'}]
SELECT DISTINCT ?h WHERE { { SELECT DISTINCT ?h ( COUNT ( ?j ) AS ?f ) WHERE { ?j property:P1303 ?h . ?j rdf:type ontology:Q502895 . ?h rdf:type ontology:Q34379 } GROUP BY ?h } . { SELECT DISTINCT ( COUNT ( ?i ) AS ?t ) WHERE { resource:Q497224 property:P1303 ?i . ?i rdf:type ontology:Q34379 } } . FILTER ( ?f > ?t ) }
Kayamb
action greater
action find_reverse_tuple_counts
relation instrument
type musical instrument
type common name
action count
action filter_type
action find
entity Kayamb
relation instrument
type musical instrument
[{'concept': 'common name'}, 'instrument', {'concept': 'musical instrument'}]
SELECT DISTINCT ?h WHERE { { SELECT DISTINCT ?h ( COUNT ( ?j ) AS ?f ) WHERE { ?j property:instrument ?h . ?j rdf:type ontology:common_name . ?h rdf:type ontology:musical_instrument } GROUP BY ?h } . { SELECT DISTINCT ( COUNT ( ?i ) AS ?t ) WHERE { resource:Kayamb property:instrument ?i . ?i rdf:type ontology:musical_instrument } } . FILTER ( ?f > ?t ) }
[]
musical instrument common name
Q5994 Q81982 Q862501
SYSTEM
piano, harpsichord, ondes Martenot
Q80284 Q46185 Q201129 Q424017 Q80019 Q2563510 Q5994 Q3574843 Q81982 Q182718 Q206987 Q189737 Q8338 Q8371 Q8355 Q213461 Q3382191 Q862501 Q213100 Q537750 Q626035 Q742180 Q1300012 Q1444 Q220971 Q128309 Q726306 Q483994 Q1343007 Q11404
(c(Q502895),P1303,c(Q34379))
action greater
action find_reverse_tuple_counts
relation P1303
type Q34379
type Q502895
action count
action filter_type
action find
entity Q497224
relation P1303
type Q34379
[ANSWERS] more number of people know to play than Kayamb
[{'concept': 'Q502895'}, 'P1303', {'concept': 'Q34379'}]
SELECT DISTINCT ?h WHERE { { SELECT DISTINCT ?h ( COUNT ( ?j ) AS ?f ) WHERE { ?j property:P1303 ?h . ?j rdf:type ontology:Q502895 . ?h rdf:type ontology:Q34379 } GROUP BY ?h } . { SELECT DISTINCT ( COUNT ( ?i ) AS ?t ) WHERE { resource:Q497224 property:P1303 ?i . ?i rdf:type ontology:Q34379 } } . FILTER ( ?f > ?t ) }
viola bass guitar lyre acoustic bass guitar double bass steel-string acoustic guitar piano tonbak harpsichord Nyckelharpa vibraphone timpani trumpet cello violin harmonium upright piano ondes Martenot tabla Djembe glockenspiel viola d'amore toy piano organ marimba drum kit erhu Kazoo electronic keyboard drum
Piano, harpsichord and ondes Martenot more number of people know to play than Kayamb
piano harpsichord ondes Martenot
action greater
action find_reverse_tuple_counts
relation instrument
type musical instrument
type common name
action count
action filter_type
action find
entity Kayamb
relation instrument
type musical instrument
[{'concept': 'common name'}, 'instrument', {'concept': 'musical instrument'}]
SELECT DISTINCT ?h WHERE { { SELECT DISTINCT ?h ( COUNT ( ?j ) AS ?f ) WHERE { ?j property:instrument ?h . ?j rdf:type ontology:common_name . ?h rdf:type ontology:musical_instrument } GROUP BY ?h } . { SELECT DISTINCT ( COUNT ( ?i ) AS ?t ) WHERE { resource:Kayamb property:instrument ?i . ?i rdf:type ontology:musical_instrument } } . FILTER ( ?f > ?t ) }
[]
Comparative Reasoning (All)
Comparative|More/Less|Single entity type|Incomplete
Q726306
P1303
Q34379 Q502895
USER
And how about erhu?
(c(Q502895),P1303,c(Q34379))
action greater
action find_reverse_tuple_counts
relation P1303
type Q34379
type Q502895
action count
action filter_type
action find
entity Q726306
relation P1303
type Q34379
[{'concept': 'Q502895'}, 'P1303', {'concept': 'Q34379'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?g ) AS ?e ) WHERE { ?g property:P1303 ?l . ?l rdf:type ontology:Q34379 . ?g rdf:type ontology:Q502895 } GROUP BY ?l } . FILTER ( ?e > ?v ) . { SELECT DISTINCT ( COUNT ( ?h ) AS ?v ) WHERE { resource:Q726306 property:P1303 ?h . ?h rdf:type ontology:Q34379 } } }
erhu
action greater
action find_reverse_tuple_counts
relation instrument
type musical instrument
type common name
action count
action filter_type
action find
entity erhu
relation instrument
type musical instrument
[{'concept': 'common name'}, 'instrument', {'concept': 'musical instrument'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?g ) AS ?e ) WHERE { ?g property:instrument ?l . ?l rdf:type ontology:musical_instrument . ?g rdf:type ontology:common_name } GROUP BY ?l } . FILTER ( ?e > ?v ) . { SELECT DISTINCT ( COUNT ( ?h ) AS ?v ) WHERE { resource:erhu property:instrument ?h . ?h rdf:type ontology:musical_instrument } } }
[]
musical instrument common name
Q5994 Q81982 Q80284
SYSTEM
piano, harpsichord, viola
Q80284 Q46185 Q80019 Q2563510 Q5994 Q81982 Q206987 Q189737 Q8338 Q8371 Q8355 Q213461 Q3382191 Q213100 Q742180 Q1444 Q220971 Q128309 Q1343007 Q11404
(c(Q502895),P1303,c(Q34379))
action greater
action find_reverse_tuple_counts
relation P1303
type Q34379
type Q502895
action count
action filter_type
action find
entity Q726306
relation P1303
type Q34379
[ANSWERS]
[{'concept': 'Q502895'}, 'P1303', {'concept': 'Q34379'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?g ) AS ?e ) WHERE { ?g property:P1303 ?l . ?l rdf:type ontology:Q34379 . ?g rdf:type ontology:Q502895 } GROUP BY ?l } . FILTER ( ?e > ?v ) . { SELECT DISTINCT ( COUNT ( ?h ) AS ?v ) WHERE { resource:Q726306 property:P1303 ?h . ?h rdf:type ontology:Q34379 } } }
viola bass guitar double bass steel-string acoustic guitar piano harpsichord vibraphone timpani trumpet cello violin harmonium upright piano tabla viola d'amore organ marimba drum kit electronic keyboard drum
piano harpsichord viola
action greater
action find_reverse_tuple_counts
relation instrument
type musical instrument
type common name
action count
action filter_type
action find
entity erhu
relation instrument
type musical instrument
[{'concept': 'common name'}, 'instrument', {'concept': 'musical instrument'}]
SELECT DISTINCT ?l WHERE { { SELECT DISTINCT ?l ( COUNT ( ?g ) AS ?e ) WHERE { ?g property:instrument ?l . ?l rdf:type ontology:musical_instrument . ?g rdf:type ontology:common_name } GROUP BY ?l } . FILTER ( ?e > ?v ) . { SELECT DISTINCT ( COUNT ( ?h ) AS ?v ) WHERE { resource:erhu property:instrument ?h . ?h rdf:type ontology:musical_instrument } } }
[]