Probabilistic query evaluation through provenance
Lax392996.ProbabilisticEvaluation · concepts/Lax392996/ProbabilisticEvaluation.lean · lax-392996
No public endorsements yet.
Loading review…
Sign in with ORCIDNatural Language Statement
Theorem
For a probability assignment on a finite set of variables, a source query , a -instance and a tuple , the marginal probability that appears in the answer of on a random world of equals the probability of the annotation of in the annotated answer : . This is the paper's Theorem 12, the justification of intensional probabilistic query evaluation: evaluate the query once over Boolean-function annotations and take the probability of the resulting function.
Concept map
Lean source view on GitHub
| 1 | import Lax392996.SemiringsWithMonus |
| 2 | import Lax392996.BooleanFunctions |
| 3 | import Lax392996.Databases |
| 4 | import Lax392996.AnnotatedDatabases |
| 5 | import Lax392996.RelationalAlgebra |
| 6 | import Lax392996.MultisetSemantics |
| 7 | import Lax392996.AnnotatedSemantics |
| 8 | import Lax392996.ProbabilisticDatabases |
| 9 | |
| 10 | /-! |
| 11 | --- |
| 12 | title: Probabilistic query evaluation through provenance |
| 13 | type: theorem |
| 14 | --- |
| 15 | For a probability assignment on a finite set of variables, a source |
| 16 | query , a -instance and a tuple , the |
| 17 | marginal probability that appears in the answer of on a random |
| 18 | world of equals the probability of the annotation of in the |
| 19 | annotated answer : |
| 20 | |
| 21 | . This is the paper's Theorem 12, |
| 22 | the justification of intensional probabilistic query evaluation: evaluate |
| 23 | the query once over Boolean-function annotations and take the probability |
| 24 | of the resulting function. |
| 25 | -/ |
| 26 | |
| 27 | namespace Lax392996.ProbabilisticEvaluation |
| 28 | |
| 29 | open Lax392996.SemiringsWithMonus Lax392996.BooleanFunctions Lax392996.Databases |
| 30 | open Lax392996.AnnotatedDatabases Lax392996.RelationalAlgebra Lax392996.MultisetSemantics |
| 31 | open Lax392996.AnnotatedSemantics Lax392996.ProbabilisticDatabases |
| 32 | |
| 33 | /-- **Theorem 12.** The marginal probability of a tuple is the probability |
| 34 | of its disjunctive annotation in the annotated answer. -/ |
| 35 | axiom theorem_12 : ∀ {X : Type} [Fintype X] [DecidableEq X] {T : Type} [ValueType T] |
| 36 | (P : ProbAssignment X) {n : ℕ} (q : Query T n) (hq : q.source) |
| 37 | (Î : AnnotatedDatabase T (BoolFunc X)) (t : Tuple T n), |
| 38 | ProbAssignment.marginalProb P q Î t |
| 39 | = ProbAssignment.funcProb P (tupleAnnotation (Query.evaluateAnnotated q hq Î) t) |
| 40 | |
| 41 | end Lax392996.ProbabilisticEvaluation |
| 42 |
Discussion
Ask a question or add context. Endorsements and structured flags are kept in the review panel above.
0 comments