Question: What is the connection between Weeds (the one that has Mary-Louise Parker as a cast member) to Dave Thomas (the one that has the occupation of film director)?
Choices:
item operated
found
record label
office held by head of state
has part
political ideology
time period
interested in
cast member
head of state
Program:
function: Find
inputs: Mary-Louise Parker
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: Weeds
function: And
dependencies: 1
2
function: Find
inputs: film director
function: Relate
dependencies: 4
inputs: occupation
backward
function: Find
inputs: Dave Thomas
function: And
dependencies: 5
6
function: QueryRelation
dependencies: 3
7
SPARQL: SELECT DISTINCT ?p WHERE { ?e_1 <pred:name> "Weeds" . ?e_1 <cast_member> ?e_3 . ?e_3 <pred:name> "Mary-Louise Parker" . ?e_2 <pred:name> "Dave Thomas" . ?e_2 <occupation> ?e_4 . ?e_4 <pred:name> "film director" . ?e_1 ?p ?e_2 .  }
Answer: cast member