Simple Question (Direct)
Simple Question
Q5713705
P937
Q56061
USER
Where did Carl-Gustav Enskog work ?
(Q5713705,P937,c(Q56061))
action filter_type
action find
entity Q5713705
relation P937
type Q56061
['Q5713705', 'P937', {'concept': 'Q56061'}]
SELECT DISTINCT ?x WHERE { resource:Q5713705 property:P937 ?x . ?x rdf:type ontology:Q56061 }
Carl-Gustav Enskog
action filter_type
action find
entity Carl-Gustav Enskog
relation work location
type administrative territorial entity
['Carl-Gustav Enskog', 'work location', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ?x WHERE { resource:Carl-Gustav_Enskog property:work_location ?x . ?x rdf:type ontology:administrative_territorial_entity }
[]
administrative territorial entity
Q1754
SYSTEM
Stockholm
Q1754
(Q5713705,P937,c(Q56061))
action filter_type
action find
entity Q5713705
relation P937
type Q56061
Carl-Gustav Enskog worked in [ANSWER]
['Q5713705', 'P937', {'concept': 'Q56061'}]
SELECT DISTINCT ?x WHERE { resource:Q5713705 property:P937 ?x . ?x rdf:type ontology:Q56061 }
Stockholm
Carl-Gustav Enskog worked in Stockholm
Stockholm
action filter_type
action find
entity Carl-Gustav Enskog
relation work location
type administrative territorial entity
['Carl-Gustav Enskog', 'work location', {'concept': 'administrative territorial entity'}]
SELECT DISTINCT ?x WHERE { resource:Carl-Gustav_Enskog property:work_location ?x . ?x rdf:type ontology:administrative_territorial_entity }
[]
Simple Question (Direct)
Simple Question|Single Entity
Q5713705
P102
Q7210356
USER
Which party is Carl-Gustav Enskog affiliated with ?
(Q5713705,P102,c(Q7210356))
action filter_type
action find
entity Q5713705
relation P102
type Q7210356
['Q5713705', 'P102', {'concept': 'Q7210356'}]
SELECT DISTINCT ?b WHERE { resource:Q5713705 property:P102 ?b . ?b rdf:type ontology:Q7210356 }
Carl-Gustav Enskog
action filter_type
action find
entity Carl-Gustav Enskog
relation member of political party
type political organization
['Carl-Gustav Enskog', 'member of political party', {'concept': 'political organization'}]
SELECT DISTINCT ?b WHERE { resource:Carl-Gustav_Enskog property:member_of_political_party ?b . ?b rdf:type ontology:political_organization }
[]
political organization
Q110857
SYSTEM
Liberal People's Party
Q110857
(Q5713705,P102,c(Q7210356))
action filter_type
action find
entity Q5713705
relation P102
type Q7210356
Carl-Gustav Enskog is affiliated with [ANSWER]
['Q5713705', 'P102', {'concept': 'Q7210356'}]
SELECT DISTINCT ?b WHERE { resource:Q5713705 property:P102 ?b . ?b rdf:type ontology:Q7210356 }
Liberal People's Party
Carl-Gustav Enskog is affiliated with Liberal People's Party
Liberal People's Party
action filter_type
action find
entity Carl-Gustav Enskog
relation member of political party
type political organization
['Carl-Gustav Enskog', 'member of political party', {'concept': 'political organization'}]
SELECT DISTINCT ?b WHERE { resource:Carl-Gustav_Enskog property:member_of_political_party ?b . ?b rdf:type ontology:political_organization }
[]
Simple Question (Coreferenced)
Simple Question|Single Entity|Indirect
Q5713705
P106
Q12737077
USER
What does that person do for a living ?
(Q110857,P106,c(Q12737077))
action filter_type
action find
entity Q5713705
relation P106
type Q12737077
['Q110857', 'P106', {'concept': 'Q12737077'}]
SELECT DISTINCT ?r WHERE { resource:Q5713705 property:P106 ?r . ?r rdf:type ontology:Q12737077 }
Carl-Gustav Enskog
action filter_type
action find
entity Carl-Gustav Enskog
relation occupation
type occupation
["Liberal People's Party", 'occupation', {'concept': 'occupation'}]
SELECT DISTINCT ?r WHERE { resource:Carl-Gustav_Enskog property:occupation ?r . ?r rdf:type ontology:occupation }
[]
occupation
Q82955
SYSTEM
politician
Q82955
(Q110857,P106,c(Q12737077))
action filter_type
action find
entity Q5713705
relation P106
type Q12737077
[ANSWER] that person does for a living
['Q110857', 'P106', {'concept': 'Q12737077'}]
SELECT DISTINCT ?r WHERE { resource:Q5713705 property:P106 ?r . ?r rdf:type ontology:Q12737077 }
politician
Politician that person does for a living
politician
action filter_type
action find
entity Carl-Gustav Enskog
relation occupation
type occupation
["Liberal People's Party", 'occupation', {'concept': 'occupation'}]
SELECT DISTINCT ?r WHERE { resource:Carl-Gustav_Enskog property:occupation ?r . ?r rdf:type ontology:occupation }
[]
Quantitative Reasoning (Count) (All)
Quantitative|Count|Logical operators
Q1754
P206
Q337567 Q15324
USER
How many still waterss or bodies of water are situated in the neighbourhood of Stockholm ?
(Q1754,P206,c(Q337567)) (Q1754,P206,c(Q15324))
action count
action union
action filter_type
action find
entity Q1754
relation P206
type Q337567
action filter_type
action find
entity Q1754
relation P206
type Q15324
['Q1754', 'P206', {'concept': 'Q337567'}] ['Q1754', 'P206', {'concept': 'Q15324'}]
SELECT DISTINCT ( COUNT ( ?t ) AS ?m ) WHERE { { resource:Q1754 property:P206 ?t . ?t rdf:type ontology:Q337567 } UNION { resource:Q1754 property:P206 ?t . ?t rdf:type ontology:Q15324 } }
Stockholm
action count
action union
action filter_type
action find
entity Stockholm
relation located next to body of water
type still waters
action filter_type
action find
entity Stockholm
relation located next to body of water
type body of water
['Stockholm', 'located next to body of water', {'concept': 'still waters'}] ['Stockholm', 'located next to body of water', {'concept': 'body of water'}]
SELECT DISTINCT ( COUNT ( ?t ) AS ?m ) WHERE { { resource:Stockholm property:located_next_to_body_of_water ?t . ?t rdf:type ontology:still_waters } UNION { resource:Stockholm property:located_next_to_body_of_water ?t . ?t rdf:type ontology:body_of_water } }
[]
still waters body of water
SYSTEM
2
Q4176307 Q184492
(Q1754,P206,c(Q337567)) (Q1754,P206,c(Q15324))
action count
action union
action filter_type
action find
entity Q1754
relation P206
type Q337567
action filter_type
action find
entity Q1754
relation P206
type Q15324
[ANSWER]
['Q1754', 'P206', {'concept': 'Q337567'}] ['Q1754', 'P206', {'concept': 'Q15324'}]
SELECT DISTINCT ( COUNT ( ?t ) AS ?m ) WHERE { { resource:Q1754 property:P206 ?t . ?t rdf:type ontology:Q337567 } UNION { resource:Q1754 property:P206 ?t . ?t rdf:type ontology:Q15324 } }
Saltsjön Mälaren
2
action count
action union
action filter_type
action find
entity Stockholm
relation located next to body of water
type still waters
action filter_type
action find
entity Stockholm
relation located next to body of water
type body of water
['Stockholm', 'located next to body of water', {'concept': 'still waters'}] ['Stockholm', 'located next to body of water', {'concept': 'body of water'}]
SELECT DISTINCT ( COUNT ( ?t ) AS ?m ) WHERE { { resource:Stockholm property:located_next_to_body_of_water ?t . ?t rdf:type ontology:still_waters } UNION { resource:Stockholm property:located_next_to_body_of_water ?t . ?t rdf:type ontology:body_of_water } }
[]
Quantitative Reasoning (All)
Quantitative|Min/Max|Single entity type
P417
Q502895 Q12737077
USER
Which people are the patron saints of max number of occupations ?
(c(Q12737077),P417,Q208331)
action argmax
action find_reverse_tuple_counts
relation P417
type Q502895
type Q12737077
[{'concept': 'Q12737077'}, 'P417', 'Q208331']
SELECT DISTINCT ?o WHERE { { SELECT DISTINCT ( MAX ( ?a ) AS ?j ) { SELECT DISTINCT ?u ( COUNT ( ?g ) AS ?a ) WHERE { ?g property:P417 ?u . ?u rdf:type ontology:Q502895 . ?g rdf:type ontology:Q12737077 } GROUP BY ?u } } . { SELECT DISTINCT ?o ( COUNT ( ?c ) AS ?e ) WHERE { ?c property:P417 ?o . ?c rdf:type ontology:Q12737077 . ?o rdf:type ontology:Q502895 } GROUP BY ?o } . FILTER ( ?e = ?j ) }
action argmax
action find_reverse_tuple_counts
relation patron saint
type common name
type occupation
[{'concept': 'occupation'}, 'patron saint', 'Olaf II of Norway']
SELECT DISTINCT ?o WHERE { { SELECT DISTINCT ( MAX ( ?a ) AS ?j ) { SELECT DISTINCT ?u ( COUNT ( ?g ) AS ?a ) WHERE { ?g property:patron_saint ?u . ?u rdf:type ontology:common_name . ?g rdf:type ontology:occupation } GROUP BY ?u } } . { SELECT DISTINCT ?o ( COUNT ( ?c ) AS ?e ) WHERE { ?c property:patron_saint ?o . ?c rdf:type ontology:occupation . ?o rdf:type ontology:common_name } GROUP BY ?o } . FILTER ( ?e = ?j ) }
[]
common name occupation
Q179718
SYSTEM
Catherine of Alexandria
Q179718
(c(Q12737077),P417,Q208331)
action argmax
action find_reverse_tuple_counts
relation P417
type Q502895
type Q12737077
[ANSWER] is the patron saints of max number of occupations
[{'concept': 'Q12737077'}, 'P417', 'Q208331']
SELECT DISTINCT ?o WHERE { { SELECT DISTINCT ( MAX ( ?a ) AS ?j ) { SELECT DISTINCT ?u ( COUNT ( ?g ) AS ?a ) WHERE { ?g property:P417 ?u . ?u rdf:type ontology:Q502895 . ?g rdf:type ontology:Q12737077 } GROUP BY ?u } } . { SELECT DISTINCT ?o ( COUNT ( ?c ) AS ?e ) WHERE { ?c property:P417 ?o . ?c rdf:type ontology:Q12737077 . ?o rdf:type ontology:Q502895 } GROUP BY ?o } . FILTER ( ?e = ?j ) }
Catherine of Alexandria
Catherine of Alexandria is the patron saints of max number of occupations
Catherine of Alexandria
action argmax
action find_reverse_tuple_counts
relation patron saint
type common name
type occupation
[{'concept': 'occupation'}, 'patron saint', 'Olaf II of Norway']
SELECT DISTINCT ?o WHERE { { SELECT DISTINCT ( MAX ( ?a ) AS ?j ) { SELECT DISTINCT ?u ( COUNT ( ?g ) AS ?a ) WHERE { ?g property:patron_saint ?u . ?u rdf:type ontology:common_name . ?g rdf:type ontology:occupation } GROUP BY ?u } } . { SELECT DISTINCT ?o ( COUNT ( ?c ) AS ?e ) WHERE { ?c property:patron_saint ?o . ?c rdf:type ontology:occupation . ?o rdf:type ontology:common_name } GROUP BY ?o } . FILTER ( ?e = ?j ) }
[]