Question: What is the title of American Beauty (the one whose producer is Grateful Dead)?
Choices:
Into the Storm
American Beauty
Memento
Oklahoma!
Die Hard
Gossip Girl
Galileo
Le Dernier des Mohicans
Helena
Savages
Program:
function: Find
inputs: Grateful Dead
function: Relate
dependencies: 0
inputs: producer
backward
function: Find
inputs: American Beauty
function: And
dependencies: 1
2
function: QueryAttr
dependencies: 3
inputs: title
SPARQL: SELECT DISTINCT ?pv WHERE { ?e <pred:name> "American Beauty" . ?e <producer> ?e_1 . ?e_1 <pred:name> "Grateful Dead" .  ?e <title> ?pv .  }
Answer: American Beauty