Question: What is the character role of John Cleese in Die Another Day (the one that has John Cleese as a cast member)?
Choices:
Bigweld
William Stryker
Lancelot
Johnny English
Treebeard
Q
Reverend Lovejoy
Sam Lane
Sweeney Todd
Raiden
Program:
function: Find
inputs: John Cleese
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: Die Another Day
function: And
dependencies: 1
2
function: Find
inputs: John Cleese
function: QueryRelationQualifier
dependencies: 3
4
inputs: cast member
character role
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "Die Another Day" . ?e_1 <cast_member> ?e_3 . ?e_3 <pred:name> "John Cleese" . ?e_2 <pred:name> "John Cleese" . ?e_1 <cast_member> ?e_2 . [ <pred:fact_h> ?e_1 ; <pred:fact_r> <cast_member> ; <pred:fact_t> ?e_2 ] <character_role> ?qpv .  }
Answer: Q