Learning by Answer Sets Chiaki Sakama Wakayama University
Learning by Answer Sets Chiaki Sakama Wakayama University, Japan Presented at AAAI Spring Symposium on Answer Set Programming, March 2001
Nonmonotonic LP (NMLP) vs. Inductive LP (ILP) NMLP ILP Goal Commonsense Reasoning Inductive Learning Language LP with NAF (ELP, EDP, etc) Clausal Theory (Horn, PDP)
Purpose of Research NMLP and ILP have different goals and complement each other. Combine techniques of two fields in the context of nonmonotonic ILP.
Problem Setting A background KB is a functionfree & categorical ELP P. n Given a positive example L as a ground literal s. t. P ≠L , compute a rule R satisfying: P {R} L. n Given a negative example L as a ground literal s. t. P =L, compute a rule R satisfying: P {R} ≠ L. n
Definitions A literal L or an NAF formula not L is called an LP-literal. n Let Lit be the set of all ground literals and S⊆Lit, then define S+= S ∪ { not L | L Lit\S }. n n For an LP-literal K, |K|=K if K is a literal; |K|=L if K=not L.
Definitions Given two ground LP-literals L 1 and L 2, n L 1~L 2 if L 1 and L 2 have the same predicate and the same constants. n L 1 in a ground rule R is relevant to L 2 if (i) L 1~L 2 or (ii) L 1 shares a constant with L 3 (in R) which is relevant to L 2. n L 1 is involved in a program P if |L 1| appears in the ground instance of P.
Computing Hypotheses using Answer Sets Let S be the answer set of P. Then, P {R} L and P ≠ L imply S ≠ R. Consider the integrity constraint where ⊆S+ and every element in is relevant to the example L and is involved in P {L}.
Computing Hypotheses using Answer Sets (cont. ) As S does not satisfy the constraint, S |≠ . By S|≠L, not L is in S+ and also in . Shifting L to the head, we get L ’ where ’= \{ not L }. Finally, construct a rule R* s. t. R* = L ’ for some substitution .
Example P: bird(x) penguin(x), bird(tweety) , penguin(polly). L: flies(tweety). Initially, P|≠flies(tweety). S+={bird(t), bird(p), peng(p), not peng(t), not flies(p), not¬ bird(_), not¬ peng(_), not¬ flies(_) } ( _ means t or p).
Example (cont. ) Picking up LP-literals which are relevant to L and are involved in P ∪{L}: bird(t), not peng(t), not flies(t). Shifting L=flies(t) to the head: flies(t) bird(t), not peng(t). Replacing tweety by x: R*= flies(x) bird(x), not peng(x).
Remarks With an additional condition on L, R* is shown to be correct. n When P is a function-free stratified program, R* is efficiently constructed from S+. n Existing procedures for ASP are used for computing R*. n
Further Issues In the paper, n a similar procedure for learning from negative examples is provided; n applications to learning from multiple examples, and learning from noncategorical programs are presented.
- Slides: 12