<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Sampling and Soundness: Can We Have Both?</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Carla Gomes</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Jo¨ rg Hoffmann</string-name>
          <email>joerg.hoffmann@deri.at</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Ashish Sabharwal</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Bart Selman</string-name>
          <email>selman@cs.cornell.edu</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Cornell University</institution>
          ,
          <addr-line>Ithaca, NY, USA, gomes</addr-line>
          ,
          <country country="US">USA</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>University of Innsbruck, DERI Institute</institution>
          ,
          <country country="AT">Austria</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>Recent research on model counting in CNF formulas has shown that a certain sampling method can yield results that are sound with a provably high probability. The key idea is to iteratively restrict the search space, and to randomly choose which part to consider. The expected value of this sampled count is equal to the real count. If one minimizes over several trials, and purposefully underestimates the outcome of each trial by a constant factor, then the probability that the sampled count exceeds the real count decreases exponentially in the number of trials. This method has proven to be quite successful for many CNF formulas. The big question is: Can we devise similar methods for reasoning in the Semantic Web? Is it possible to obtain provably high-quality results based on sampling?</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>
        Recent research on model counting in propositional CNFs [
        <xref ref-type="bibr" rid="ref1 ref2">2, 1</xref>
        ] has shown that a
certain sampling method can yield results that are sound with a provably high probability.
The method proceeds thus: s times, iteratively throw a constraint cutting the space of
potential models in half; uniformly choose one of the halfs to continue with; count the
remaining models exactly once that is feasible, and multiply the result with 2s.
      </p>
      <p>Here, the “constraints” can be as simple as fixing the value of some variables to true
or false. The constraints can also be more complicated, e.g., requiring the values of two
variables to be the same, or requiring them to be different. In principle, any constraint is
possible as long as the number of value assignments that satisfy the constraint (in
isolation) is equal to the number of value assignments that don’t. One chooses the “half to
consider” by throwing either the constraint itself, or its negation, adding that
conjunctively to the CNF formula. Once enough constraints are added, counting the models of
the formula exactly is easy.1 Since the half to be considered is chosen randomly, the
expected value of the obtained count is equal to the real count.</p>
      <p>One execution of the above method is one “trial” to count the models. Of course, the
outcome of each trial may be wrong. However, with a simple trick one can ensure that
the likelihood of over-estimating the true count decreases rapidly. Instead of
multiplying the number of remaining models with 2s, multiply only with 2s−α, where α is fixed.
Minimize the outcome over t trials. Then, the probability that the minimum count
exceeds the real count is less than 2−αt. This can be proved exploiting Markov’s
inequality, stating that, for any k and for any random variable X , P r[X &gt; kE[X ]] &lt; 1/k. The
outcome of the count in any single trial plays the role of X ; therefore, any single trial
exceeds the real count with a probability less than 2−α, from which the claim follows.
1 This depends on the kind of constraint; it holds, e.g., if variable values are being fixed.</p>
      <p>The confidence in the lower bound holds irrespectively of how the constraints are
chosen. But of course, this choice is important: if the constraint does not cut the real
models, i.e., the models of the overall formula, in half, then the sampled count is
erroneous. So one should heuristically choose constraints that are likely to cut the real
models in about half. If bad choices are made, then the variance of the outcome will be
high, and the lower bound will be overly generous. It has been shown that very good
lower bounds can be quickly obtained in many hard CNF formulas, if constraints are
chosen based on heuristic information gathered with local search techniques.
2</p>
      <p>Application to the Semantic Web
Can we devise similar methods for reasoning in the Semantic Web? Is it possible to
obtain provably high-quality outcomes based on sampling? We cannot even try to answer
this question comprehensively. We list some things that spring to mind.</p>
      <p>If the task to be performed involves counting, or can be formulated as such, then it
seems pretty clear that the sampling method can be adapted. For example, say one has
an RDF database, and wants to count how many triples comply with a given query. In
such situations, the main conceptual issue that needs to be clarified is if/how the notion
of “constraints” can be adapted: How to cut the set of all (potential) RDF triples in
half? Apart from that, severe technical challenges may have to be overcome as to how
to “throw” a constraint, and how to efficiently count the “remaining models”.</p>
      <p>It is a priori less clear if/how situations of a “yes/no” nature can be tackled. What
if we want to check whether some logical statement φ follows from a huge database of
facts and axioms? A straightforward adaptation would throw “constraints” as additional
axioms or facts. Of course, this raises a big issue regarding how to make sure that the
additional constraints actually make the reasoning more efficient. If the implication does
not hold in the enriched database, we know that it does not hold in the original one.
Otherwise, potentially one can upper-bound the probability that the implication does
not hold, by exploiting the correspondence between proving an implication, proving
unsatisfiability, and proving upper bounds on the number of models. For that purpose,
the sampling method would first need to be adapted to derive upper bounds instead.</p>
      <p>An alternative adaptation would be to instead throw “constraints” removing parts
of the database, and check whether the remaining parts imply φ. But can we draw any
conclusions from that? In the general case, no: the constraints might be of a form so
that those parts of the database responsible for implying φ are on different sides of the
constraint. Even if that never happens, the probability of retaining the responsible parts
decreases exponentially with the number of constraints thrown. Are there interesting
special cases where these difficulties do not appear, or at least do not matter in practice?</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <given-names>Carla</given-names>
            <surname>Gomes</surname>
          </string-name>
          , Jo¨rg Hoffmann, Ashish Sabharwal, and
          <string-name>
            <given-names>Bart</given-names>
            <surname>Selman</surname>
          </string-name>
          .
          <article-title>From sampling to model counting</article-title>
          .
          <source>In Proc. IJCAI'07</source>
          , pages
          <fpage>2293</fpage>
          -
          <lpage>2299</lpage>
          ,
          <year>2007</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <given-names>Carla</given-names>
            <surname>Gomes</surname>
          </string-name>
          , Ashish Sabharwal, and
          <string-name>
            <given-names>Bart</given-names>
            <surname>Selman</surname>
          </string-name>
          .
          <article-title>Model counting: A new strategy for obtaining good bounds</article-title>
          .
          <source>In Proc. AAAI'07</source>
          , pages
          <fpage>54</fpage>
          -
          <lpage>61</lpage>
          ,
          <year>2007</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>