KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Updating the Knowledge Compilation Map Simone Bova (TU Wien) - - PowerPoint PPT Presentation
Updating the Knowledge Compilation Map Simone Bova (TU Wien) - - PowerPoint PPT Presentation
K NOWLEDGE C OMPILATION M AP U PDATES E XTENSIONS Updating the Knowledge Compilation Map Simone Bova (TU Wien) Dagstuhl Seminar on Recent Trends in Knowledge Compilation September 1722 , 2017, Dagstuhl (Germany) K NOWLEDGE C OMPILATION M AP U
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Outline
Knowledge Compilation Map Updates Extensions
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Outline
Knowledge Compilation Map Updates Extensions
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation
Represent knowledge so to facilitate reasoning.
Example Represent DNFs by OBDDs to count models. (x ∧ y) ∨ (x ∧ z) ∨ (w ∧ y) ∨ (w ∧ z) ≡
⊥ ⊤ z x y w
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation
Represent knowledge so to facilitate reasoning.
Example Represent DNFs by OBDDs to count models. (x ∧ y) ∨ (x ∧ z) ∨ (w ∧ y) ∨ (w ∧ z) ≡
⊥ ⊤ z x y w
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation
Represent knowledge so to facilitate reasoning.
Example Represent DNFs by OBDDs to count models. (x ∧ y) ∨ (x ∧ z) ∨ (w ∧ y) ∨ (w ∧ z) ≡
16 12 = (8 + 16)/2 9 = (6 + 12)/2
⊥ ⊤ z x y w
8 = (0 + 16)/2 6 = (0 + 12)/2
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation
Represent propositional knowledge so to facilitate reasoning.
Find a class R of circuits expressing a class of Boolean functions
- Represent propositional knowledge. . .
such that certain logical tasks on the circuits in R are computationally feasible.
- . . . so to facilitate reasoning.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Logical Tasks on Circuits
Given circuits C and C′ in a circuit class R. Counting: Count the models of C. Entailment: Decide if C entails C′. . . . . . . Negation: Find a circuit in R computing ¬C. Conjunction: Find a circuit in R computing C ∧ C′. Disjunction: Find a circuit in R computing C ∨ C′. . . . . . . A task is computationally feasible on R if it is polytime tractable wrt the input size ie, wrt the size of the circuits in R.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness vs Tractability
Tradeoff succinctness/tractability in choosing a representation language: Truthtables: Tractable, but useless because too verbose. Circuits: Succinct, but useless because too hard. Darwiche and Marquis (2002) systematically investigate a hierarchy of representation languages wrt their succinctness/tractability tradeoffs:
- A. Darwiche and P. Marquis.
A Knowledge Compilation Map.
- J. Artif. Intell. Res., 17, 229-264, 2002.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Representation Languages
NNF CNF PI FBDD IP DNNF DNF dDNNF OBDD MODS
Figure: Inclusions.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Representation Languages
Negation Normal Forms (NNF) Boolean circuits having unbounded fanin AND and OR gates with negations pushed to the input gates. Decomposable NNFs (DNNF) NNFs where each AND gate has subcircuits using disjoint sets of variables. Deterministic DNNFs (dDNNF) DNNFs where each OR gate has pairwise inconsistent subcircuits. Prime Implicate Forms (PI) CNFs where entailed clauses are already entailed by a single clause in the CNF and no clause in the CNF is entailed by another. Models, MODS DNFs where each disjunct uses the same variables. Free Binary Decision Diagrams, FBDDs: Read-once branching programs.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Determinism and Decomposability
x3 x4 ⊥ x1 x2 ⊥ x1 x4 ∨ ∨ ∨ ∨ ⊤ x3 x1 x2 x1 ∧ ∧ ∧ ∧ ∧ ∧ ∧ ∧
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Counting via Determinism and Decomposability
x3 x4 ⊥ x1 x2 ⊥ x1 x4 + + + ⊤ x3 x1 x2 x1 + × × × × × × × ×
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Representation Languages
Negation Normal Forms (NNF) Boolean circuits having unbounded fanin AND and OR gates with negations pushed to the input gates. Decomposable NNFs (DNNF) NNFs where each AND gate has subcircuits using disjoint sets of variables. Deterministic DNNFs (dDNNF) DNNFs where each OR gate has pairwise inconsistent subcircuits. Prime Implicate Forms (PI) CNFs where entailed clauses are already entailed by a single clause in the CNF and no clause in the CNF is entailed by another. Models, MODS DNFs where each disjunct uses the same variables. Free Binary Decision Diagrams, FBDDs: Deterministic read-once branching programs.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness Relation
Let S, T ⊆ NNF. S is (polysize) compilable into T (or T is at least as succinct as S) if there exists a polynomial p: N → N such that for all C ∈ S there exists D ∈ T equivalent to C such that size(D) ≤ p(size(C)). Write S T if S is compilable into T, and S T otherwise.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation in Practice
Want to count models of circuit C (offline) modulo a sequence of partial assignments g1, g2, g3, . . . (online): C|g1, C|g2, C|g3, . . . Ow, lookup in the KC map a maximally succinct language supporting counting mod assignments. Represent C by a form C∗ in the chosen language: C∗, C∗|g1, C∗|g2, C∗|g3, . . . High compilation cost is eventually amortized by low querying costs: t0 t1 · · · tj · · · · · · · · · ti · · · ti+1 · · · C|g1 · · · C|gj · · · · · · · · · C|gi · · · C|gi+1 · · · · · · · · · C∗ C∗|g1 C∗|g2 · · · C∗|gi C∗|gi+1 C∗|gi+2
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Outline
Knowledge Compilation Map Updates Extensions
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness Relation
Darwiche and Marquis (2002) summarize the status of the succinctness relation also appealing to previous work including
- Quine (1959),
- Chandra and Markowsky (1978),
- Bryant (1986),
- Wegener (1987),
- Gergov and Meinel (1994),
- Gogic, Kautz, Papadimitriou, and Selman (1995),
- Selman and Kautz (1996),
- Cadoli and Donini (1997), and
- Darwiche (1999).
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness Relation
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
Let S and T be languages in the diagram. If (S, T) in transitive closure of →, then S T. Else:
- If S T, then S
?
T (unknown).
- Else S T.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness Relation
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
Figure: S T means S T unknown. S → T means S T unless PH collapses.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness Relation | 2002–2016
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
Let S and T be languages in the diagram. If (S, T) in transitive closure of →, then S T. Else:
- If S T, then S
?
T.
- If S → T, then S T unless PH collapses.
- Else S T.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness | Updates | 1 | PI DNNF
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
Figure: S → T means S T.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness | Updates | 2 | DNNF dDNNF
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
Figure: S → T means S T.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness | Updates
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation Meets Communication Complexity
Theorem (B, Capelli, Mengel, and Slivovsky) Let D be a DNNF (resp, dDNNF) computing a function F. The size of D is an upper bound on the size of a smallest rectangle cover (resp, disjoint rectange cover) of F.∗ A Z-rectangle is a function R(Z) of the form R ≡ S(X) ∧ T(Y) for functions S and T with X and Y forming a partition of Z. {Ri}i∈I is a rectangle cover of a Boolean function F(Z) if each Ri is a Z-rectangle and F ≡
i∈I Ri.
A rectangle cover {Ri}i∈I is disjoint if Ri ∧ Rj ≡ ⊥ (i = j ∈ I).
∗Balanced.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Rectangle | R(x, y, z, w) ≡ S(x, y) ∧
× T(z, w)
R(x, y, z, w) ¯ x¯ y¯ z¯ w ¯ x¯ y¯ zw ¯ x¯ yz¯ w ¯ x¯ yzw ¯ xy¯ z¯ w ¯ xy¯ zw 1 ¯ xyz¯ w 1 ¯ xyzw x¯ y¯ z¯ w x¯ y¯ zw 1 x¯ yz¯ w 1 x¯ yzw xy¯ z¯ w xy¯ zw xyz¯ w xyzw ≡ ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y ¯ xy 1 1 x¯ y 1 1 xy
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Rectangle Cover | F ≡ R1 ∨ R2 ∨ R3
F(x, y, z, w) = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y 1 1 ¯ xy 1 1 1 x¯ y 1 1 1 xy 1 1 ≡ R1 = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y 1 1 ¯ xy 1 1 x¯ y xy ∨ R2 = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y ¯ xy 1 1 x¯ y 1 1 xy ∨ R3 = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y ¯ xy x¯ y 1 1 xy 1 1
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Disjoint Rectangle Cover | F ≡ R1
+
∨ R′
2 +
∨ R′′
2 +
∨ R3
F(x, y, z, w) = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y 1 1 ¯ xy 1 1 1 x¯ y 1 1 1 xy 1 1 ≡ R1 = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y 1 1 ¯ xy 1 1 x¯ y xy
+
∨ R′
2
= ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y ¯ xy 1 x¯ y xy
+
∨ R′′
2
= ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y ¯ xy x¯ y 1 xy
+
∨ R3 = ¯ z¯ w ¯ zw z¯ w zw ¯ x¯ y ¯ xy x¯ y 1 1 xy 1 1
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Knowledge Compilation Meets Communication Complexity
Theorem (B, Capelli, Mengel, and Slivovsky) Let D be a DNNF (resp, dDNNF) computing a function F. The size of D is an upper bound on the size of a smallest rectangle cover (resp, disjoint rectange cover) of F.† Details? Ask 2F + 2S.
†Balanced.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness | Updates | 1 | PI DNNF
Fn =
xy∈En(x ∨ y) where En are edges of size n member of expander family.
Theorem (Jukna and Schnitger; B, Capelli, Mengel, and Slivovsky) A rectangle cover of the function Fn has size at least 2Ω(n).‡ Corollary The DNNF size of Fn is 2Ω(n). Proposition The PI size of Fn is O(n2). Corollary PI DNNF.
‡Balanced.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness | Updates | 2 | DNNF dDNNF
Sn(X) = Rn(X) ∨ Cn(X) where Rn (resp, Cn) is the sum modulo 2 of the sums modulo 3 of the rows (resp, columns) of X = (xij)i,j∈[n]. Theorem (Sauerhoff) A disjoint rectangle cover of the function Sn has size 2Ω(n).§ Corollary The dDNNF size of Sn is 2Ω(n). Proposition The DNNF size of Sn is O(n2). Corollary DNNF dDNNF.
§Balanced.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Succinctness | Updates
MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI MODS DNNF OBDD dDNNF FBDD DNF CNF NNF IP PI
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | 2002–2016
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes Reads: ? — Unknown. No — Does not support unless P = NP. No — Does not support. Yes — Supports.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | Updates
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes Reads: ? — Unknown. No — Does not support unless P = NP. No — Does not support. Yes — Supports.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | Updates | 1
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes S∗
n = (x ∧
Rn
- small OBDD
) ∨ (¬x ∧ Cn
- small OBDD
)
- small FBDD
∃xS∗
n ≡
Sn
- large dDNNF [BCMS16]
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | Updates | 2
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes G = (V, E) expander graph of degree 3. G is c-edge-colorable for c ∈ {3, 4} by Vizing theorem, ie, E = c
i=1 Ei such that {x, y} ∩ {z, w} = ∅ for all {xy, zw} ⊆ Ei.
Then: F =
c
- i=1
- xy∈Ei
(x ∨ y)
- small OBDD
- large DNNF [BCMS16]
Still No (conditional) for ∧2 and ∧3.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | Updates | 3
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes Sn = Rn
- small OBDD
∨ Cn
- small OBDD
- large dDNNF [BCMS16]
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | Updates | 4
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes F
- CNF with large DNNF [BCMS16]
≡ ¬ ¬F
- small DNF hence small DNNF
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Transformations | Questions
∃X ∃x ∧c ∧n ∨c ∨n ¬ DNNF Yes Yes No No Yes Yes No dDNNF No No No No No No ? FBDD No No No No No No Yes OBDD No Yes No No No No Yes Question Does dDNNF have polysize (resp, polytime) negation? If not, then dDNNF and dDNNF¬ are separated.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Understanding (Semantic) Determinism
Let F(X) = 1 iff the n × n Boolean matrix X has a full row or a full column.¶ Both F and ¬F have large decDNNF size (since F has large FBDD size). F/dDNNF ¬F/dDNNF ¬/dDNNF IP/dDNNF DNF/dDNNF small small ?
- →
small large No
- →
large small No
- large
large ?
- ¶Lineage of ∃x∀yE(x, y) ∨ ∃y∀xE(x, y) over Kn.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Queries | 2002-2017
≡ dDNNF ? FBDD ? Observation (Wegener) Equivalence of FBDDs is not coNP-hard unless NP=RP.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Outline
Knowledge Compilation Map Updates Extensions
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Traces of Counting Algorithms
Two techniques for (CNF) model counting:
- exhaustive DPLL with caching and components (practical);
- dynamic-programming based on syntactic structure (theoretical).
Traces of such counting algorithms are respectively: Decision DNNFs (decDNNF) FBDDs with decomposable ANDs; Structured dDNNFs (sdDNNF) dDNNFs with ANDs “respecting a vtree”. Lower bounds on traces’ size imply lower bounds on algorithms’ runtime.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Structured Determinism
A structured deterministic NNF. . . . . . with its variable tree. x3 x4 ⊥ x1 x2 ⊥ x1 x4 ∨ ∨ ∨ ∨ ⊤ x3 x1 x2 x1 ∧ ∧ ∧ ∧ ∧ ∧ ∧ ∧ x1 x2 x3 x4
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Traces of Counting Algorithms
SDD FBDD OBDD sdDNNF decDNNF
Figure: Inclusions.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Sentential Decision Diagrams (SDD)
An SDD respecting vtree T with left/right subtrees Tl(X) and Tr(Y) has form
m
- i=1
(Pi ∧ Si) where:
- the Pi’s are SDDs respecting Tl(X) and distinguishing cases on X;
- the Si’s are SDDs respecting Tr(Y).
Literals are SDDs respecting any vtree containing their variable. ⊥ and ⊤ are SDDs respecting any vtree.
Exhaustively and disjointly.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Counting Techniques | Separations
SDD FBDD decDNNF OBDD sdDNNF
Let S and T be languages in the diagram. If (S, T) in transitive closure of →, then S T. Else:
- If S T, then S
?
T.
- Else S T.
Unstructured/decision simulates structured/determinism?
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS
Literature
- P. Beame, J. Li, S. Roy, and D. Suciu.
Lower Bounds for Exact Model Counting and Applications in Probabilistic Databases. In Proc. of UAI 2013, pp. 52–61. AUAI, 2013.
- S. Bova.
SDDs are Exponentially More Succinct than OBDDs. In Proc. of AAAI 2016, pp. 929–935. AAAI, 2016.
- S. Bova, F. Capelli, S. Mengel, and F. Slivovsky.
On Compiling CNFs into Structured Deterministic DNNFs. In Proc. of SAT 2015, pp. 199–214. Springer, 2015.
- S. Bova, F. Capelli, S. Mengel, and F. Slivovsky.
Knowledge Compilation Meets Communication Complexity. In Proc. of IJCAI 2016, pp. 1008–1014. IJCAI/AAAI, 2016.
- F. Capelli.
Understanding the Complexity of ♯SAT Using Knowledge Compilation. In Proc. of LICS 2017, pp. 1–10. LICS, 2017.
- A. Darwiche and P. Marquis.
A Knowledge Compilation Map.
- J. Artif. Intell. Res., 17, 229-264, 2002.
KNOWLEDGE COMPILATION MAP UPDATES EXTENSIONS