Simple Question (Direct)
Simple Question
Q3147510
P27
Q15617994
USER
Which administrative territory is the native country of Ibrahim Rachidi ?
(Q3147510,P27,c(Q15617994))
action filter_type
action find
entity Q3147510
relation P27
type Q15617994
['Q3147510', 'P27', {'concept': 'Q15617994'}]
SELECT DISTINCT ?k WHERE { resource:Q3147510 property:P27 ?k . ?k rdf:type ontology:Q15617994 }
Ibrahim Rachidi
action filter_type
action find
entity Ibrahim Rachidi
relation country of citizenship
type designation for an administrative territorial entity
['Ibrahim Rachidi', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ?k WHERE { resource:Ibrahim_Rachidi property:country_of_citizenship ?k . ?k rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
designation for an administrative territorial entity
Q142
SYSTEM
France
Q142
(Q3147510,P27,c(Q15617994))
action filter_type
action find
entity Q3147510
relation P27
type Q15617994
[ANSWER] is the native country of Ibrahim Rachidi
['Q3147510', 'P27', {'concept': 'Q15617994'}]
SELECT DISTINCT ?k WHERE { resource:Q3147510 property:P27 ?k . ?k rdf:type ontology:Q15617994 }
France
France is the native country of Ibrahim Rachidi
France
action filter_type
action find
entity Ibrahim Rachidi
relation country of citizenship
type designation for an administrative territorial entity
['Ibrahim Rachidi', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ?k WHERE { resource:Ibrahim_Rachidi property:country_of_citizenship ?k . ?k rdf:type ontology:designation_for_an_administrative_territorial_entity }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q3147510
P641
Q349
USER
What was the sport that Ibrahim Rachidi was a part of ?
(Q3147510,P641,c(Q349))
action filter_type
action find
entity Q3147510
relation P641
type Q349
['Q3147510', 'P641', {'concept': 'Q349'}]
SELECT DISTINCT ?u WHERE { resource:Q3147510 property:P641 ?u . ?u rdf:type ontology:Q349 }
Ibrahim Rachidi
action filter_type
action find
entity Ibrahim Rachidi
relation sport
type sport
['Ibrahim Rachidi', 'sport', {'concept': 'sport'}]
SELECT DISTINCT ?u WHERE { resource:Ibrahim_Rachidi property:sport ?u . ?u rdf:type ontology:sport }
[]
sport
Q2736
SYSTEM
association football
Q2736
(Q3147510,P641,c(Q349))
action filter_type
action find
entity Q3147510
relation P641
type Q349
The sport that Ibrahim Rachidi was a part of was the [ANSWER]
['Q3147510', 'P641', {'concept': 'Q349'}]
SELECT DISTINCT ?u WHERE { resource:Q3147510 property:P641 ?u . ?u rdf:type ontology:Q349 }
association football
The sport that Ibrahim Rachidi was a part of was the association football
association football
action filter_type
action find
entity Ibrahim Rachidi
relation sport
type sport
['Ibrahim Rachidi', 'sport', {'concept': 'sport'}]
SELECT DISTINCT ?u WHERE { resource:Ibrahim_Rachidi property:sport ?u . ?u rdf:type ontology:sport }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q3147510
P54
Q1194951
USER
What is Ibrahim Rachidi a member of ?
(Q3147510,P54,c(Q1194951))
action filter_type
action find
entity Q3147510
relation P54
type Q1194951
['Q3147510', 'P54', {'concept': 'Q1194951'}]
SELECT DISTINCT ?s WHERE { resource:Q3147510 property:P54 ?s . ?s rdf:type ontology:Q1194951 }
Ibrahim Rachidi
action filter_type
action find
entity Ibrahim Rachidi
relation member of sports team
type national sports team
['Ibrahim Rachidi', 'member of sports team', {'concept': 'national sports team'}]
SELECT DISTINCT ?s WHERE { resource:Ibrahim_Rachidi property:member_of_sports_team ?s . ?s rdf:type ontology:national_sports_team }
[]
national sports team
Q497637
SYSTEM
Comoros national football team
Q497637
(Q3147510,P54,c(Q1194951))
action filter_type
action find
entity Q3147510
relation P54
type Q1194951
Ibrahim Rachidi a member of is the [ANSWER]
['Q3147510', 'P54', {'concept': 'Q1194951'}]
SELECT DISTINCT ?s WHERE { resource:Q3147510 property:P54 ?s . ?s rdf:type ontology:Q1194951 }
Comoros national football team
Ibrahim Rachidi a member of is the Comoros national football team
Comoros national football team
action filter_type
action find
entity Ibrahim Rachidi
relation member of sports team
type national sports team
['Ibrahim Rachidi', 'member of sports team', {'concept': 'national sports team'}]
SELECT DISTINCT ?s WHERE { resource:Ibrahim_Rachidi property:member_of_sports_team ?s . ?s rdf:type ontology:national_sports_team }
[]
Simple Question (Ellipsis)
only subject is changed, parent and predicate remains same
Q2039473
Q1194951
USER
And what about Ari Heikkinen?
(Q2039473,P54,c(Q1194951))
action filter_type
action find
entity Q2039473
relation P54
type Q1194951
['Q2039473', 'P54', {'concept': 'Q1194951'}]
SELECT DISTINCT ?p WHERE { resource:Q2039473 property:P54 ?p . ?p rdf:type ontology:Q1194951 }
Ari Heikkinen
action filter_type
action find
entity Ari Heikkinen
relation member of sports team
type national sports team
['Ari Heikkinen', 'member of sports team', {'concept': 'national sports team'}]
SELECT DISTINCT ?p WHERE { resource:Ari_Heikkinen property:member_of_sports_team ?p . ?p rdf:type ontology:national_sports_team }
[]
national sports team
Q186532
SYSTEM
Finland national football team
Q186532
(Q2039473,P54,c(Q1194951))
action filter_type
action find
entity Q2039473
relation P54
type Q1194951
[ANSWER]
['Q2039473', 'P54', {'concept': 'Q1194951'}]
SELECT DISTINCT ?p WHERE { resource:Q2039473 property:P54 ?p . ?p rdf:type ontology:Q1194951 }
Finland national football team
Finland national football team
action filter_type
action find
entity Ari Heikkinen
relation member of sports team
type national sports team
['Ari Heikkinen', 'member of sports team', {'concept': 'national sports team'}]
SELECT DISTINCT ?p WHERE { resource:Ari_Heikkinen property:member_of_sports_team ?p . ?p rdf:type ontology:national_sports_team }
[]
Verification (Boolean) (All)
Verification|2 entities, one direct and one indirect, object is indirect
Q186532 Q926549
P54
Q502895
USER
Is Juho Mäkelä a member of that national sports team ?
(Q926549,P54,Q186532)
action is_in
entity Q186532
action find
entity Q926549
relation P54
['Q926549', 'P54', 'Q186532']
ASK WHERE { resource:Q926549 property:P54 resource:Q186532 }
Finland national football team Juho Mäkelä
action is_in
entity Finland national football team
action find
entity Juho Mäkelä
relation member of sports team
['Juho Mäkelä', 'member of sports team', 'Finland national football team']
ASK WHERE { resource:Juho_Mäkelä property:member_of_sports_team resource:Finland_national_football_team }
[]
common name
SYSTEM
YES
(Q926549,P54,Q186532)
action is_in
entity Q186532
action find
entity Q926549
relation P54
[ANSWER]
['Q926549', 'P54', 'Q186532']
ASK WHERE { resource:Q926549 property:P54 resource:Q186532 }
Yes
action is_in
entity Finland national football team
action find
entity Juho Mäkelä
relation member of sports team
['Juho Mäkelä', 'member of sports team', 'Finland national football team']
ASK WHERE { resource:Juho_Mäkelä property:member_of_sports_team resource:Finland_national_football_team }
[]
Logical Reasoning (All)
Logical|Union|Multiple_Relation
Q1336813 Q3147510
P19 P937
Q515
USER
Which cities are the birthplace of Ibrahim Rachidi or did Emil Schlee work ?
OR((Q3147510,P19,c(Q515)), (Q1336813,P937,c(Q515)))
action filter_type
action union
action find
entity Q3147510
relation P19
action find
entity Q1336813
relation P937
type Q515
{'OR': [['Q3147510', 'P19', {'concept': 'Q515'}], ['Q1336813', 'P937', {'concept': 'Q515'}]]}
SELECT DISTINCT ?g WHERE { { { resource:Q1336813 property:P937 ?g } UNION { resource:Q3147510 property:P19 ?g } } . ?g rdf:type ontology:Q515 }
Emil Schlee Ibrahim Rachidi
action filter_type
action union
action find
entity Ibrahim Rachidi
relation place of birth
action find
entity Emil Schlee
relation work location
type city
{'OR': [['Ibrahim Rachidi', 'place of birth', {'concept': 'city'}], ['Emil Schlee', 'work location', {'concept': 'city'}]]}
SELECT DISTINCT ?g WHERE { { { resource:Emil_Schlee property:work_location ?g } UNION { resource:Ibrahim_Rachidi property:place_of_birth ?g } } . ?g rdf:type ontology:city }
[]
city
Q23482 Q6602 Q1721
SYSTEM
Marseille, Strasbourg, Wiesbaden
Q23482 Q6602 Q1721
OR((Q3147510,P19,c(Q515)), (Q1336813,P937,c(Q515)))
action filter_type
action union
action find
entity Q3147510
relation P19
action find
entity Q1336813
relation P937
type Q515
[ANSWERS] are the birthplace of Ibrahim Rachidi or did Emil Schlee work
{'OR': [['Q3147510', 'P19', {'concept': 'Q515'}], ['Q1336813', 'P937', {'concept': 'Q515'}]]}
SELECT DISTINCT ?g WHERE { { { resource:Q1336813 property:P937 ?g } UNION { resource:Q3147510 property:P19 ?g } } . ?g rdf:type ontology:Q515 }
Marseille Strasbourg Wiesbaden
Marseille, Strasbourg and Wiesbaden are the birthplace of Ibrahim Rachidi or did Emil Schlee work
Marseille Strasbourg Wiesbaden
action filter_type
action union
action find
entity Ibrahim Rachidi
relation place of birth
action find
entity Emil Schlee
relation work location
type city
{'OR': [['Ibrahim Rachidi', 'place of birth', {'concept': 'city'}], ['Emil Schlee', 'work location', {'concept': 'city'}]]}
SELECT DISTINCT ?g WHERE { { { resource:Emil_Schlee property:work_location ?g } UNION { resource:Ibrahim_Rachidi property:place_of_birth ?g } } . ?g rdf:type ontology:city }
[]
Logical Reasoning (All)
Logical|Union|Single_Relation
Q20015660 Q2039473
P27
Q15617994
USER
Which administrative territories are the countries of citizenship of Ari Heikkinen or Daniel Teglia ?
OR((Q2039473,P27,c(Q15617994)), (Q20015660,P27,c(Q15617994)))
action filter_type
action union
action find
entity Q2039473
relation P27
action find
entity Q20015660
relation P27
type Q15617994
{'OR': [['Q2039473', 'P27', {'concept': 'Q15617994'}], ['Q20015660', 'P27', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:Q15617994 . { { resource:Q2039473 property:P27 ?w } UNION { resource:Q20015660 property:P27 ?w } } }
Daniel Teglia Ari Heikkinen
action filter_type
action union
action find
entity Ari Heikkinen
relation country of citizenship
action find
entity Daniel Teglia
relation country of citizenship
type designation for an administrative territorial entity
{'OR': [['Ari Heikkinen', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}], ['Daniel Teglia', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:designation_for_an_administrative_territorial_entity . { { resource:Ari_Heikkinen property:country_of_citizenship ?w } UNION { resource:Daniel_Teglia property:country_of_citizenship ?w } } }
[]
designation for an administrative territorial entity
Q33 Q414
SYSTEM
Finland, Argentina
Q33 Q414
OR((Q2039473,P27,c(Q15617994)), (Q20015660,P27,c(Q15617994)))
action filter_type
action union
action find
entity Q2039473
relation P27
action find
entity Q20015660
relation P27
type Q15617994
[ANSWERS] are the countries of citizenship of Ari Heikkinen or Daniel Teglia
{'OR': [['Q2039473', 'P27', {'concept': 'Q15617994'}], ['Q20015660', 'P27', {'concept': 'Q15617994'}]]}
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:Q15617994 . { { resource:Q2039473 property:P27 ?w } UNION { resource:Q20015660 property:P27 ?w } } }
Finland Argentina
Finland and Argentina are the countries of citizenship of Ari Heikkinen or Daniel Teglia
Finland Argentina
action filter_type
action union
action find
entity Ari Heikkinen
relation country of citizenship
action find
entity Daniel Teglia
relation country of citizenship
type designation for an administrative territorial entity
{'OR': [['Ari Heikkinen', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}], ['Daniel Teglia', 'country of citizenship', {'concept': 'designation for an administrative territorial entity'}]]}
SELECT DISTINCT ?w WHERE { ?w rdf:type ontology:designation_for_an_administrative_territorial_entity . { { resource:Ari_Heikkinen property:country_of_citizenship ?w } UNION { resource:Daniel_Teglia property:country_of_citizenship ?w } } }
[]
Verification (Boolean) (All)
Verification|one entity, multiple entities (as object) referred indirectly
Q2751419
P17
Q841509
USER
Are Islamic marital jurisprudence present in those administrative territories ?
(Q2751419,P17,Q33) (Q2751419,P17,Q414)
action is_in
entity prev_answer
action find
entity Q2751419
relation P17
['Q2751419', 'P17', 'Q33'] ['Q2751419', 'P17', 'Q414']
ASK WHERE { resource:Q2751419 property:P17 ?d . VALUES ( ?d ) { ( resource:Q33 ) ( resource:Q414 ) } }
Islamic marital jurisprudence
action is_in
entity prev_answer
action find
entity Islamic marital jurisprudence
relation country
['Islamic marital jurisprudence', 'country', 'Finland'] ['Islamic marital jurisprudence', 'country', 'Argentina']
ASK WHERE { resource:Islamic_marital_jurisprudence property:country ?d . VALUES ( ?d ) { ( resource:Finland ) ( resource:Argentina ) } }
[]
significant other
SYSTEM
NO
(Q2751419,P17,Q33) (Q2751419,P17,Q414)
action is_in
entity prev_answer
action find
entity Q2751419
relation P17
[ANSWER]
['Q2751419', 'P17', 'Q33'] ['Q2751419', 'P17', 'Q414']
ASK WHERE { resource:Q2751419 property:P17 ?d . VALUES ( ?d ) { ( resource:Q33 ) ( resource:Q414 ) } }
No
action is_in
entity prev_answer
action find
entity Islamic marital jurisprudence
relation country
['Islamic marital jurisprudence', 'country', 'Finland'] ['Islamic marital jurisprudence', 'country', 'Argentina']
ASK WHERE { resource:Islamic_marital_jurisprudence property:country ?d . VALUES ( ?d ) { ( resource:Finland ) ( resource:Argentina ) } }
[]
Verification (Boolean) (All)
Verification|2 entities, both direct
Q142 Q1011
P530
Q15617994
USER
Does Cape Verde have diplomatic relationships with France ?
(Q142,P530,Q1011)
action is_in
entity Q1011
action find
entity Q142
relation P530
['Q142', 'P530', 'Q1011']
ASK WHERE { resource:Q142 property:P530 resource:Q1011 }
France Cape Verde
action is_in
entity Cape Verde
action find
entity France
relation diplomatic relation
['France', 'diplomatic relation', 'Cape Verde']
ASK WHERE { resource:France property:diplomatic_relation resource:Cape_Verde }
[]
designation for an administrative territorial entity
SYSTEM
YES
(Q142,P530,Q1011)
action is_in
entity Q1011
action find
entity Q142
relation P530
[ANSWER]
['Q142', 'P530', 'Q1011']
ASK WHERE { resource:Q142 property:P530 resource:Q1011 }
Yes
action is_in
entity Cape Verde
action find
entity France
relation diplomatic relation
['France', 'diplomatic relation', 'Cape Verde']
ASK WHERE { resource:France property:diplomatic_relation resource:Cape_Verde }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count|Logical operators
Q33
P1071
Q838948 Q2235308
USER
How many works of art and ship types have Finland as their final assembly location ?
(c(Q838948),P1071,Q33) (c(Q2235308),P1071,Q33)
action count
action union
action filter_type
action find_reverse
entity Q33
relation P1071
type Q838948
action filter_type
action find_reverse
entity Q33
relation P1071
type Q2235308
[{'concept': 'Q838948'}, 'P1071', 'Q33'] [{'concept': 'Q2235308'}, 'P1071', 'Q33']
SELECT DISTINCT ( COUNT ( ?h ) AS ?u ) WHERE { { ?h property:P1071 resource:Q33 . ?h rdf:type ontology:Q2235308 } UNION { ?h property:P1071 resource:Q33 . ?h rdf:type ontology:Q838948 } }
Finland
action count
action union
action filter_type
action find_reverse
entity Finland
relation location of final assembly
type work of art
action filter_type
action find_reverse
entity Finland
relation location of final assembly
type ship type
[{'concept': 'work of art'}, 'location of final assembly', 'Finland'] [{'concept': 'ship type'}, 'location of final assembly', 'Finland']
SELECT DISTINCT ( COUNT ( ?h ) AS ?u ) WHERE { { ?h property:location_of_final_assembly resource:Finland . ?h rdf:type ontology:ship_type } UNION { ?h property:location_of_final_assembly resource:Finland . ?h rdf:type ontology:work_of_art } }
[]
work of art ship type
SYSTEM
1 works of art and 1 ship types
Q19776419 Q24027465
(c(Q838948),P1071,Q33) (c(Q2235308),P1071,Q33)
action count
action union
action filter_type
action find_reverse
entity Q33
relation P1071
type Q838948
action filter_type
action find_reverse
entity Q33
relation P1071
type Q2235308
[ANSWER]
[{'concept': 'Q838948'}, 'P1071', 'Q33'] [{'concept': 'Q2235308'}, 'P1071', 'Q33']
SELECT DISTINCT ( COUNT ( ?h ) AS ?u ) WHERE { { ?h property:P1071 resource:Q33 . ?h rdf:type ontology:Q2235308 } UNION { ?h property:P1071 resource:Q33 . ?h rdf:type ontology:Q838948 } }
My Stuff Agenoria
1 works of art and 1 ship types
action count
action union
action filter_type
action find_reverse
entity Finland
relation location of final assembly
type work of art
action filter_type
action find_reverse
entity Finland
relation location of final assembly
type ship type
[{'concept': 'work of art'}, 'location of final assembly', 'Finland'] [{'concept': 'ship type'}, 'location of final assembly', 'Finland']
SELECT DISTINCT ( COUNT ( ?h ) AS ?u ) WHERE { { ?h property:location_of_final_assembly resource:Finland . ?h rdf:type ontology:ship_type } UNION { ?h property:location_of_final_assembly resource:Finland . ?h rdf:type ontology:work_of_art } }
[]
Quantitative Reasoning (All)
Quantitative|Atleast/ Atmost/ Approx. the same/Equal|Single entity type
P530
Q15617994 Q1048835
USER
Which political territories have diplomatic relations with approximately 119 administrative territories ?
(c(Q1048835),P530,c(Q15617994))
action approx
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
value 119
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ?t WHERE { { SELECT DISTINCT ?t ( COUNT ( ?x ) AS ?v ) WHERE { ?t property:P530 ?x . ?t rdf:type ontology:Q1048835 . ?x rdf:type ontology:Q15617994 } GROUP BY ?t } . FILTER ( ?v = 119 ) }
action approx
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
value 119
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ?t WHERE { { SELECT DISTINCT ?t ( COUNT ( ?x ) AS ?v ) WHERE { ?t property:diplomatic_relation ?x . ?t rdf:type ontology:political_territorial_entity . ?x rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?t } . FILTER ( ?v = 119 ) }
[]
designation for an administrative territorial entity political territorial entity
Q183 Q408
SYSTEM
Germany, Australia
Q183 Q408
(c(Q1048835),P530,c(Q15617994))
action approx
action find_tuple_counts
relation P530
type Q1048835
type Q15617994
value 119
[ANSWERS] have diplomatic relations with approximately 119 administrative territories
[{'concept': 'Q1048835'}, 'P530', {'concept': 'Q15617994'}]
SELECT DISTINCT ?t WHERE { { SELECT DISTINCT ?t ( COUNT ( ?x ) AS ?v ) WHERE { ?t property:P530 ?x . ?t rdf:type ontology:Q1048835 . ?x rdf:type ontology:Q15617994 } GROUP BY ?t } . FILTER ( ?v = 119 ) }
Germany Australia
Germany and Australia have diplomatic relations with approximately 119 administrative territories
Germany Australia
action approx
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type designation for an administrative territorial entity
value 119
[{'concept': 'political territorial entity'}, 'diplomatic relation', {'concept': 'designation for an administrative territorial entity'}]
SELECT DISTINCT ?t WHERE { { SELECT DISTINCT ?t ( COUNT ( ?x ) AS ?v ) WHERE { ?t property:diplomatic_relation ?x . ?t rdf:type ontology:political_territorial_entity . ?x rdf:type ontology:designation_for_an_administrative_territorial_entity } GROUP BY ?t } . FILTER ( ?v = 119 ) }
[]
Quantitative Reasoning (All)
Quantitative|Min/Max|Single entity type
P530
Q1048835 Q1048835
USER
Which political territories have diplomatic relationships with max number of political territories ?
(c(Q1048835),P530,Q766)
action argmax
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
[{'concept': 'Q1048835'}, 'P530', 'Q766']
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?e ) AS ?s ) WHERE { ?j property:P530 ?e . ?j rdf:type ontology:Q1048835 . ?e rdf:type ontology:Q1048835 } GROUP BY ?j } . FILTER ( ?s = ?f ) . { SELECT DISTINCT ( MAX ( ?x ) AS ?f ) { SELECT DISTINCT ?b ( COUNT ( ?p ) AS ?x ) WHERE { ?b property:P530 ?p . ?b rdf:type ontology:Q1048835 . ?p rdf:type ontology:Q1048835 } GROUP BY ?b } } }
action argmax
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
[{'concept': 'political territorial entity'}, 'diplomatic relation', 'Jamaica']
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?e ) AS ?s ) WHERE { ?j property:diplomatic_relation ?e . ?j rdf:type ontology:political_territorial_entity . ?e rdf:type ontology:political_territorial_entity } GROUP BY ?j } . FILTER ( ?s = ?f ) . { SELECT DISTINCT ( MAX ( ?x ) AS ?f ) { SELECT DISTINCT ?b ( COUNT ( ?p ) AS ?x ) WHERE { ?b property:diplomatic_relation ?p . ?b rdf:type ontology:political_territorial_entity . ?p rdf:type ontology:political_territorial_entity } GROUP BY ?b } } }
[]
political territorial entity political territorial entity
Q408
SYSTEM
Australia
Q408
(c(Q1048835),P530,Q766)
action argmax
action find_tuple_counts
relation P530
type Q1048835
type Q1048835
[ANSWER] have diplomatic relationships with max number of political territories
[{'concept': 'Q1048835'}, 'P530', 'Q766']
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?e ) AS ?s ) WHERE { ?j property:P530 ?e . ?j rdf:type ontology:Q1048835 . ?e rdf:type ontology:Q1048835 } GROUP BY ?j } . FILTER ( ?s = ?f ) . { SELECT DISTINCT ( MAX ( ?x ) AS ?f ) { SELECT DISTINCT ?b ( COUNT ( ?p ) AS ?x ) WHERE { ?b property:P530 ?p . ?b rdf:type ontology:Q1048835 . ?p rdf:type ontology:Q1048835 } GROUP BY ?b } } }
Australia
Australia have diplomatic relationships with max number of political territories
Australia
action argmax
action find_tuple_counts
relation diplomatic relation
type political territorial entity
type political territorial entity
[{'concept': 'political territorial entity'}, 'diplomatic relation', 'Jamaica']
SELECT DISTINCT ?j WHERE { { SELECT DISTINCT ?j ( COUNT ( ?e ) AS ?s ) WHERE { ?j property:diplomatic_relation ?e . ?j rdf:type ontology:political_territorial_entity . ?e rdf:type ontology:political_territorial_entity } GROUP BY ?j } . FILTER ( ?s = ?f ) . { SELECT DISTINCT ( MAX ( ?x ) AS ?f ) { SELECT DISTINCT ?b ( COUNT ( ?p ) AS ?x ) WHERE { ?b property:diplomatic_relation ?p . ?b rdf:type ontology:political_territorial_entity . ?p rdf:type ontology:political_territorial_entity } GROUP BY ?b } } }
[]
Quantitative Reasoning (All)
Quantitative|Atleast/ Atmost/ Approx. the same/Equal|Mult. entity type
P609
Q515 Q83620 Q34442
USER
Which cities serves as the terminus locations of atmost 1 thoroughfares and roads ?
(c(Q83620)|c(Q34442),P609,c(Q515))
action atmost
action union
action find_reverse_tuple_counts
relation P609
type Q515
type Q83620
action find_reverse_tuple_counts
relation P609
type Q515
type Q34442
value 1
[[{'concept': 'Q83620'}, {'concept': 'Q34442'}], 'P609', {'concept': 'Q515'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ?r ( COUNT ( ?f ) AS ?k ) WHERE { { ?r rdf:type ontology:Q515 . ?f rdf:type ontology:Q83620 . ?f property:P609 ?r } UNION { ?f property:P609 ?r . ?r rdf:type ontology:Q515 . ?f rdf:type ontology:Q34442 } } GROUP BY ?r } . FILTER ( ?k <= 1 ) }
action atmost
action union
action find_reverse_tuple_counts
relation terminus location
type city
type thoroughfare
action find_reverse_tuple_counts
relation terminus location
type city
type road
value 1
[[{'concept': 'thoroughfare'}, {'concept': 'road'}], 'terminus location', {'concept': 'city'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ?r ( COUNT ( ?f ) AS ?k ) WHERE { { ?r rdf:type ontology:city . ?f rdf:type ontology:thoroughfare . ?f property:terminus_location ?r } UNION { ?f property:terminus_location ?r . ?r rdf:type ontology:city . ?f rdf:type ontology:road } } GROUP BY ?r } . FILTER ( ?k <= 1 ) }
[]
city thoroughfare road
Q1899 Q1731 Q42622
SYSTEM
Kyiv, Dresden, Suzhou
Q8652 Q349982 Q601254 Q425996 Q756581 Q320950 Q869037 Q16506 Q363479 Q1027604 Q2092257 Q16959 Q68481 Q851155 Q181276 Q249007 Q341777 Q5869 Q16520 Q541071 Q360374 Q6602 Q535534 Q819620 Q193724 Q987487 Q180470 Q210365 Q533157 Q1630623 Q158245 Q2079 Q217698 Q379160 Q18575 Q1000069 Q612646 Q42622 Q71227 Q1641736 Q185684 Q373101 Q426868 Q278877 Q147738 Q502981 Q1008696 Q373023 Q954611 Q1761 Q373687 Q162880 Q682544 Q187136 Q404529 Q954569 Q304848 Q16666 Q34750 Q570768 Q321778 Q513417 Q11506 Q200603 Q946780 Q1899 Q1009095 Q57756 Q1731 Q360643 Q58401 Q587388
(c(Q83620)|c(Q34442),P609,c(Q515))
action atmost
action union
action find_reverse_tuple_counts
relation P609
type Q515
type Q83620
action find_reverse_tuple_counts
relation P609
type Q515
type Q34442
value 1
[ANSWERS] serve as the terminus locations of atmost 1 thoroughfares and roads
[[{'concept': 'Q83620'}, {'concept': 'Q34442'}], 'P609', {'concept': 'Q515'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ?r ( COUNT ( ?f ) AS ?k ) WHERE { { ?r rdf:type ontology:Q515 . ?f rdf:type ontology:Q83620 . ?f property:P609 ?r } UNION { ?f property:P609 ?r . ?r rdf:type ontology:Q515 . ?f rdf:type ontology:Q34442 } } GROUP BY ?r } . FILTER ( ?k <= 1 ) }
Miami Hegang Dubí Deyang Františkovy Lázně Trutnov Takasago České Budějovice Shangrao Uherský Ostroh Rožmitál pod Třemšínem Ürümqi Fuzhou Kasai Szolnok Wuwei Čáslav Lhasa Busan Hulín Anqing Strasbourg Hohhot Seiyo Slavkov u Brna Ostrov Huangshan City Beihai Tianshui Hostivice Písek Leipzig Weifang Kunszentmárton Tucson Lovosice Veselí nad Lužnicí Suzhou Shiyan Pohořelice Hefei Rizhao Leshan Český Těšín Saint Helier Miyako Rožnov pod Radhoštěm Weihai Jeseník Dublin Binzhou Dezhou Mikulov Luoyang Xuchang Vyškov Daqing Nanjing Fuxin Wuhai Hodonín Vsetín Denpasar Yawatahama Lanžhot Kyiv Otrokovice Lianyungang Dresden Suzhou, Anhui Shijiazhuang Mohelnice
Kyiv, Dresden and Suzhou serve as the terminus locations of atmost 1 thoroughfares and roads
Kyiv Dresden Suzhou
action atmost
action union
action find_reverse_tuple_counts
relation terminus location
type city
type thoroughfare
action find_reverse_tuple_counts
relation terminus location
type city
type road
value 1
[[{'concept': 'thoroughfare'}, {'concept': 'road'}], 'terminus location', {'concept': 'city'}]
SELECT DISTINCT ?r WHERE { { SELECT DISTINCT ?r ( COUNT ( ?f ) AS ?k ) WHERE { { ?r rdf:type ontology:city . ?f rdf:type ontology:thoroughfare . ?f property:terminus_location ?r } UNION { ?f property:terminus_location ?r . ?r rdf:type ontology:city . ?f rdf:type ontology:road } } GROUP BY ?r } . FILTER ( ?k <= 1 ) }
[]
Clarification
Quantitative|Count|Single entity type|Indirect
P190
Q56061
USER
How many administrative territories are partner towns of that city ?
(Q1899,P190,c(Q56061))
['Q1899', 'P190', {'concept': 'Q56061'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?y ) WHERE { resource:Q4512420 property:P190 ?z . ?z rdf:type ontology:Q56061 }
['Kyiv', 'sister city', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?y ) WHERE { resource:Kyiv property:sister_city ?z . ?z rdf:type ontology:administrative_territorial_entity }
[]
administrative territorial entity
Quantitative|Count|Single entity type|Clarification
Q1731
SYSTEM
Did you mean Dresden ?
(Q1899,P190,c(Q56061)) (Q1731,P190,c(Q56061)) (Q42622,P190,c(Q56061))
[ANSWER]
['Q1899', 'P190', {'concept': 'Q56061'}] ['Q1731', 'P190', {'concept': 'Q56061'}] ['Q42622', 'P190', {'concept': 'Q56061'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?y ) WHERE { resource:Q4512420 property:P190 ?z . ?z rdf:type ontology:Q56061 }
Did you mean Dresden ?
Dresden
['Kyiv', 'sister city', {'concept': 'administrative territorial entity'}] ['Dresden', 'sister city', {'concept': 'administrative territorial entity'}] ['Suzhou', 'sister city', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?y ) WHERE { resource:Kyiv property:sister_city ?z . ?z rdf:type ontology:administrative_territorial_entity }
[]
Quantitative Reasoning (Count) (All)
USER
No, I meant Kyiv. Could you tell me the answer for that?
(Q1899,P190,c(Q56061))
Q1899
['Q1899', 'P190', {'concept': 'Q56061'}]
['Kyiv', 'sister city', {'concept': 'administrative territorial entity'}]
[]
SYSTEM
32
Q1757 Q994 Q727 Q9248 Q472 Q1754 Q1770 Q1297 Q5168 Q40840 Q23436 Q1520 Q1524 Q3711 Q1780 Q1781 Q25331 Q1741 Q1489 Q2044 Q206954 Q1726 Q21197 Q7880 Q216 Q172 Q270 Q8678 Q239 Q956 Q2280 Q3640
(Q1899,P190,c(Q56061))
[ANSWER]
['Q1899', 'P190', {'concept': 'Q56061'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?y ) WHERE { resource:Q4512420 property:P190 ?z . ?z rdf:type ontology:Q56061 }
Helsinki Tbilisi Amsterdam Baku Sofia Stockholm Tallinn Chicago Makhachkala Tampere Edinburgh Astana Athens Belgrade Bratislava Budapest Odense Vienna Mexico City Florence Kastoria Munich Chișinău Toulouse Vilnius Toronto Warsaw Rio de Janeiro Brussels Beijing Minsk Ankara
32
['Kyiv', 'sister city', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ( COUNT ( ?z ) AS ?y ) WHERE { resource:Kyiv property:sister_city ?z . ?z rdf:type ontology:administrative_territorial_entity }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q1731
P190
Q56061
USER
Which administrative territories are the sister cities of Dresden ?
(Q1731,P190,c(Q56061))
action filter_type
action find
entity Q1731
relation P190
type Q56061
['Q1731', 'P190', {'concept': 'Q56061'}]
SELECT DISTINCT ?h WHERE { resource:Q1731 property:P190 ?h . ?h rdf:type ontology:Q56061 }
Dresden
action filter_type
action find
entity Dresden
relation sister city
type administrative territorial entity
['Dresden', 'sister city', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ?h WHERE { resource:Dresden property:sister_city ?h . ?h rdf:type ontology:administrative_territorial_entity }
[]
administrative territorial entity
Q2044 Q34370 Q384
SYSTEM
Florence, Rotterdam, Skopje
Q34713 Q384 Q2044 Q16567 Q34370 Q8385 Q6225 Q182428 Q3844
(Q1731,P190,c(Q56061))
action filter_type
action find
entity Q1731
relation P190
type Q56061
[ANSWERS] are the sister cities of Dresden
['Q1731', 'P190', {'concept': 'Q56061'}]
SELECT DISTINCT ?h WHERE { resource:Q1731 property:P190 ?h . ?h rdf:type ontology:Q56061 }
Salzburg Skopje Florence Columbus Rotterdam Ostrava Coventry Silistra Brazzaville
Florence, Rotterdam and Skopje are the sister cities of Dresden
Florence Rotterdam Skopje
action filter_type
action find
entity Dresden
relation sister city
type administrative territorial entity
['Dresden', 'sister city', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ?h WHERE { resource:Dresden property:sister_city ?h . ?h rdf:type ontology:administrative_territorial_entity }
[]