integration of abductive reasoning and constraint optimization in sciff
DESCRIPTION
Integration of abductive reasoning and constraint optimization in SCIFF. Marco Gavanelli – Università di Ferrara, Italy Marco Alberti – Universidade nova de Lisboa, Portugal Evelina Lamma – Università di Ferrara, Italy. Abductive Logic Programming. ALP = < KB, A, IC > - PowerPoint PPT PresentationTRANSCRIPT
Marco Gavanelli – Università di Ferrara, ItalyMarco Alberti – Universidade nova de Lisboa,
PortugalEvelina Lamma – Università di Ferrara, Italy
Abductive Logic ProgrammingALP = < KB, A, IC >
KB = logic program (set of clauses)A = atoms without definitions, can be
assumedIC = Integrity constraints (usually,
implications)
KB ╞═ G KB ╞═ ICReasoning from effects to causes
Abductive Constraint Logic ProgrammingE.g., ALP+CLP(FD),
KB = { p(X) :- a(X), 1 ≤ X ≤ 2. }
G = p(X)
0={a(1)} 1={a(2)} 2={a(1), a(2)}
KB |= p(1)
KB |= p(2)
KB |= p(1)
KB |= p(2)
Optimization in ALPFind the best explanation, plan, … w.r.t. some
given objective functionSyntax:
min( X : p(X,Y) ) = Mmeans
M = min{ X : p(X,Y) }
Use the minimize predicate of CLP(FD)Operational semantics
p(X,Y)
X=3
X≤3
X≤3
X≤3
ok!
ImplementationDepends on the implementation of ALPCHR [Abdennadher&Christiansen,
Christiansen&Dahl, Alberti et al., Badea et al.] can call all the predicates of the host (CLP)
language -> also minimize!p(X) :- a(X), 1 ≤ X ≤ 2.
min( X : p(X)) = M0={a(1)} 1={a(2)} 2={a(1),
a(2)}
KB |= p(1)
KB |= p(2)
KB |= p(1)
KB |= p(2)
ok!
Semantics of optimizationSemantics of optimization in CLP [Fages,
Marriot&Stuckey]
min( X : p(X,Y) )
Naïve abductive semantics:
min( X : p(X,Y) )
p(X,Y) not( p(X1,Y1), X1 < X )
KB ╞═ p(X,Y) not( p(X1,Y1), X1 < X )
Naïve declarative semanticsKB = { p(X) :- a(X), 1 ≤ X ≤ 2. }
?- min(X : p(X)) = MKB |= p(X) not( p(X1), X1 < X )
KB{a(1)}|= p(1) not(p(X1),X1<1)
M=1KB{a(2)} |=
p(2) not(p(X1),X1<2)
M=2
KB{a(1), a(2)} |= p(1) not(p(X1),X1<1)
M=1
What is wrong?We are not optimizing w.r.t. the set :
We want the minimum to be among all the possible sets .
Let us consider programs stratified both w.r.t. negation and optimization
KB ╞═ min( X : p(X,Y) )
3-valued completionp(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).
not
H
True
False
3-valued completionp(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).
not
H
True
False
True
p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).
3-valued completion
not
H
False
p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).p(1) :- not q(1).
3-valued completion for abducibles
not
1 2
3 4
Tp for optimization (simplified)Given the atom
min( X : p(X) ) = MSuppose that all atoms from the grounding of p(X)
are either true or falsethen min( X : p(X) )=M is true iff:
there exists some value v such thatp(v) is truethere is no v’<v s.t. p(v’) is true with the same there is no v’’<v s.t. p(v’’) is true with another
.(false otherwise)
Example: Game Theory
[Gavanelli et al. ECAI 2008]
Interactions?a(Ma,Xa),b(Mb,Xb)-
>Xa=Xb=f(Ma,Mb).
max(Vb : a(Ma,Xa),min(Xb : b(Mb,Xb), ) = Vb
)
5 10 4 3
a(0) a(1)
b(0) b(0)b(1) b(1)
max
min
• true iff for each possible , there is no better value• Thus, the only option is ={a(1),b(1)}• Second player plays also the move of the first!
SolutionAdd the set of literals Am that
can be abduced “inside” min in the syntax:
minAm ( X : p(X) )Suppose that all atoms from the grounding of p(X) are either true or false
then minAm ( X : p(X) )=M is true iff:there exists some value v such that
p(v) is truethere is no v’<v s.t. p(v’) is true with the
same there is no v’’<v s.t. p(v’’) is true with
another ’’ ∆’’ ∩ (A \ ∆ ) ⊆ Am , ∆’’ ∩ (A \ Am ) = ∆ ∩ (A \ Am )
Am
’’
Interactions?max{a,b}(Vb : a(Ma,Xa),
min{b}(Xb : b(Mb,Xb),
) = Vb )Now min{b} is
true in {a(0),b(o)} and {a(1),b(1)}
false in {a(1), b(0)} {a(0),b(1)}
5 10 4 3
a(0) a(1)
b(0) b(0)b(1) b(1)
max
min
Am={b}
’’
a(0)
b(0)
b(1)’’
a(1)
b(1)
b(0)
Am={b}
Interactions?max{a,b}(Vb : a(Ma,Xa),
min{b}(Xb : b(Mb,Xb),
) = Vb
)Now min{b} is
true in {a(0),b(o)} and {a(1),b(1)}
false in {a(1), b(0)} {a(0),b(1)}
max{a,b} is true for {a(0),b(o)}
5 3
a(0) a(1)
b(0) b(1)
max
min
Am={b}
a(0)
b(0)
a(1)
b(1)
Am={b}
SoundnessSoundness of success: if
P ├─∆ G
with abductive answer (∆, σ), thenP |= ∆σ Gσ
Soundness of failure: if the SCIFFopt derivation for a goal G finitely fails, then
P GProved for SCIFF, but should hold for most
(sound) abductive procedures
LimitationsWe do not currently consider the following casesOptimization goals in the conditions of
integrity constraints:min( X : p(X,Y) ) -> …
Conjunctions of optimization atomsmin( X : p(X) ), max( X : p(X) )
min( X : p(X),X>0 ), min( Y : q(Y),Y>0 ) p(X),q(X) -> false
Protected variables
ConclusionsFirst declarative semantics for abductive
logic programming (ALP) with optimization (for finding the optimal )
Proof of soundness of ALP+optimizationProved for SCIFF, should hold for all (sound)
abductive proceduresDirectly usable in abductive proof-procedures
implemented in CHR
Thank you for your attention!
Questions?