Question: Which facility that is located in Manhattan (that is the residence of Robert Downey Jr.) has the largest total revenue?
Choices:
Tower of London
National Gallery of Art
Louvre Museum
Metropolitan Museum of Art
Game of Thrones
National Gallery
prison
Museo del Prado
Museum of Modern Art
Bangor
Answer: Metropolitan Museum of Art
SPARQL: SELECT ?e WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "facility" . ?e <located_in_the_administrative_territorial_entity> ?e_1 . ?e_1 <pred:name> "Manhattan" . ?e_2 <residence> ?e_1 . ?e_2 <pred:name> "Robert Downey Jr." .  ?e <total_revenue> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Program:
function: Find
inputs: Robert Downey Jr.
function: Relate
dependencies: 0
inputs: residence
forward
function: Find
inputs: Manhattan
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: located in the administrative territorial entity
backward
function: FilterConcept
dependencies: 4
inputs: facility
function: SelectAmong
dependencies: 5
inputs: total revenue
largest