Question: What is the character role of Mel Gibson (the one that is an ethnic group of Irish Americans) in Hamlet (the one that has Stephen Dillane as a cast member)?
Choices:
Lily Potter
Dick Hallorann
Leonard Nimoy
Bonnie Parker
The High Sparrow
Aldrich Killian
Emanuel Schikaneder
Kitty Kiernan
Carlotta
Prince Hamlet
Program:
function: Find
inputs: Stephen Dillane
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: Hamlet
function: And
dependencies: 1
2
function: Find
inputs: Irish Americans
function: Relate
dependencies: 4
inputs: ethnic group
backward
function: Find
inputs: Mel Gibson
function: And
dependencies: 5
6
function: QueryRelationQualifier
dependencies: 3
7
inputs: cast member
character role
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "Hamlet" . ?e_1 <cast_member> ?e_3 . ?e_3 <pred:name> "Stephen Dillane" . ?e_2 <pred:name> "Mel Gibson" . ?e_2 <ethnic_group> ?e_4 . ?e_4 <pred:name> "Irish Americans" . ?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: Prince Hamlet