top down ground proof procedure
play

Top-down Ground Proof Procedure Idea: search backward from a query - PowerPoint PPT Presentation

Top-down Ground Proof Procedure Idea: search backward from a query to determine if it is a logical consequence of KB . An answer clause is of the form: yes a 1 a 2 . . . a m The SLD Resolution of this answer clause on atom a i with


  1. Top-down Ground Proof Procedure Idea: search backward from a query to determine if it is a logical consequence of KB . An answer clause is of the form: yes ← a 1 ∧ a 2 ∧ . . . ∧ a m The SLD Resolution of this answer clause on atom a i with the clause: a i ← b 1 ∧ . . . ∧ b p is the answer clause yes ← a 1 ∧· · ·∧ a i − 1 ∧ b 1 ∧ · · · ∧ b p ∧ a i +1 ∧ · · · ∧ a m . � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 1

  2. Derivations An answer is an answer clause with m = 0. That is, it is the answer clause yes ← . A derivation of query “? q 1 ∧ . . . ∧ q k ” from KB is a sequence of answer clauses γ 0 , γ 1 , . . . , γ n such that ◮ γ 0 is the answer clause yes ← q 1 ∧ . . . ∧ q k , ◮ γ i is obtained by resolving γ i − 1 with a clause in KB , and ◮ γ n is an answer. � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 2

  3. Top-down definite clause interpreter To solve the query ? q 1 ∧ . . . ∧ q k : ac := “ yes ← q 1 ∧ . . . ∧ q k ” repeat select atom a i from the body of ac ; choose clause C from KB with a i as head; replace a i in the body of ac by the body of C until ac is an answer. � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 3

  4. Nondeterministic Choice Don’t-care nondeterminism If one selection doesn’t lead to a solution, there is no point trying other alternatives. select Don’t-know nondeterminism If one choice doesn’t lead to a solution, other choices may. choose � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 4

  5. Example: successful derivation a ← b ∧ c . a ← e ∧ f . b ← f ∧ k . c ← e . d ← k . e . f ← j ∧ e . f ← c . j ← c . Query: ? a γ 0 : yes ← a γ 4 : yes ← e γ 1 : yes ← e ∧ f γ 5 : yes ← γ 2 : yes ← f γ 3 : yes ← c � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 5

  6. Example: failing derivation a ← b ∧ c . a ← e ∧ f . b ← f ∧ k . c ← e . d ← k . e . f ← j ∧ e . f ← c . j ← c . Query: ? a γ 0 : yes ← a γ 4 : yes ← e ∧ k ∧ c γ 1 : yes ← b ∧ c γ 5 : yes ← k ∧ c γ 2 : yes ← f ∧ k ∧ c γ 3 : yes ← c ∧ k ∧ c � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 6

  7. Search Graph for SLD Resolution yes ← a ^ d yes ← h ^ d yes ← b ^ c ^ d yes ← g ^ d yes ← m ^ d yes ← m ^ d yes ← j ^ c ^ d yes ← f ^ d a ← b ∧ c . a ← g . yes ← k ^ c ^ d a ← h . b ← j . yes ← m ^ d yes ← p ^ d b ← k . d ← m . yes ← m ^ c ^ d d ← p . f ← m . yes ← d f ← p . g ← m . yes ← m yes ← p g ← f . k ← m . h ← m . p . yes ← ? a ∧ d � D. Poole and A. Mackworth 2008 c Artificial Intelligence, Lecture 5.3, Page 7

Recommend


More recommend