# Friday, April 17, 2015 1 PTR: A Probabilistic Transaction Logic Julian Fogel A logic for reasoning about action under uncertainty. A mathematically sound.

## Presentation on theme: "Friday, April 17, 2015 1 PTR: A Probabilistic Transaction Logic Julian Fogel A logic for reasoning about action under uncertainty. A mathematically sound."— Presentation transcript:

Friday, April 17, 2015 1 PTR: A Probabilistic Transaction Logic Julian Fogel A logic for reasoning about action under uncertainty. A mathematically sound foundation for building software that requires such reasoning

Friday, April 17, 2015 2 Applications  Uncertainty in workflow  Unreliable circuits  AI planning  Game theory

Friday, April 17, 2015 3 Uncertainty in Workflow

Friday, April 17, 2015 4 Unreliable Circuits

Friday, April 17, 2015 5 AI Planning

Friday, April 17, 2015 6 Game Theory

Friday, April 17, 2015 7 Logic = Syntax + Semantics + Reasoning  Syntax: a formal language – just meaningless symbols  Semantics: giving meaning to symbols – truth in a structure ⊧  Reasoning: what else is true given what is known – logical implication ⇒, entailment ⊦

Friday, April 17, 2015 8 Semantics  Possible worlds, initial state  Actions and transactions, paths  Path distribution

Friday, April 17, 2015 9 Possible Worlds Example One propositional variable H, which is true when the coin is heads. Two possible worlds: H and H. H: the coin is not heads in this state (it’s tails) H: the coin is heads in this state HH Coin is hidden, and even chance of it being heads or tails: P W assigns probability 0.5 to each state. P W (H) = 0.5 and P W (H) = 0.5. H H 0.5

Friday, April 17, 2015 10 Possible Worlds Definitions  Propositional symbols: Each symbol can be either True or False  State: a particular assignment of True or False to the propositional symbols  P W : A probability distribution over states [Fagin and Halpern 90]

Friday, April 17, 2015 11 Path Example One atomic action symbol F: flip a fair coin H H H HHH HH 0.5 P A ( F,H) One transaction symbol F2: flip a fair coin twice H HH H 0.25 P T ( F2,H) H H H H 0.25 H HH H H HH H P T ( F2,H) H H H H 0.25 H HH H

Friday, April 17, 2015 12 Path Definitions  Atomic action symbols: trigger transitions between two states  Transaction symbols: allows intermediate states [Bonner and Kifer 94]  Path: sequence of states (W 1,…,W n )  P A and P T : probability distributions over paths

Friday, April 17, 2015 13 Path Distribution Example H HH H 0.125 H H H H H HH H H HH H H H H H H HH H Given P w, P A, and P T as in the previous examples, the path distribution P shown here makes the transaction formula F2 true.

Friday, April 17, 2015 14 Path Distribution: The Heart of PTR  Given the initial probabilistic knowledge about the world encoded in P w, P A, and P T, a PTR formula is true or false (succeeds or fails) on a path distribution P.  If a formula succeeds on a path distribution, then it executes along one of the paths that have non-zero probability.

Friday, April 17, 2015 15 Formulas  Probabilistic state formula: Pr (Q)  c where Q is an ordinary propositional formula  Transaction Formula: –Atomic action or transaction symbol –Serial conjunction  –Disjunction  –Negation  –Pre/postcondition [  ]-  -[  ] where  and  are probabilistic state formulas

Friday, April 17, 2015 16 Pre/postcondition Example H HH H 0.0625 H H H H H HH H H HH H 0.1875 H H H H H HH H Some Successful Transactions F2 [ Pr (H)=0.25]- F2 -[ Pr (H)=0.5] [ Pr (  H)  0.7]- F2 F2 -[ Pr (  H  H)  1.0] Some Failed Transactions [ Pr (H)=0.25]- F2 -[ Pr (H)=0.55] [ Pr (  H)  0.8]- F2 [ Pr (  (H   H))>0]- F2 F2 -[ Pr (  (H   H))<0]

Friday, April 17, 2015 17 Pre/postcondition  Precondition: constrains the distribution of the initial state of a transaction, describes what must be known before  can execute  Postcondition: constrains the distribution of the final state of a transaction, describes something known to be true after the transaction  executes [  ]-  -[  ]

Friday, April 17, 2015 18 Serial Conjunction Example H HH H H H H H H HH H H HH H H H H H H HH H H H H H H H H H Assume that P W ( H ) = 1. The path distribution P to the left makes transaction formula (F2  F) true. 0.125

Friday, April 17, 2015 19 Serial Conjunction  First execute  followed by   Both conjuncts need to succeed  Probabilities along paths are combined like a cross-product, then normalized 

Friday, April 17, 2015 20 Disjunction  Execute one of  or  nondeterministically  Succeeds if either disjunct succeeds  Useful in defining other connectives such as conditional and biconditional  Not parallel execution 

Friday, April 17, 2015 21 Negation  Succeeds on any path distribution on which  fails  Mainly useful in defining other connectives, or in conjunction with them 

Friday, April 17, 2015 22 A Small Example A B C Actions: OA, OB, MC Propositions: a, b, mc Transaction: MIX K={MIX  OA  (OB  MC)} Query: MIX-[Pr( mc )  0.8 ]

Friday, April 17, 2015 23 P A ( MC ) to from mab 0.990.01000000 mab0.850.15000000 mab00000000 0001.00000 mab00000000 000001.000 mab00000000 00000001.0

Friday, April 17, 2015 24 P A ( OA ), P A ( OB ), P W to from ma 0.00100.999 ma00.0010.999 ma00.9890.011 P W (MAB) = 1

Friday, April 17, 2015 25 P T ( MIX ) path P T ( MIX ) description mab mab 0.83140285 success mab mab 0.14671815 mixing fails mab mab 0.010879 valve A fails mab mab 0.010879 valve B fails mab mab 0.000121 both valves fail 0.989,, 0.85, 0.989,, 0.15, 0.989, 0.011, 1,, 0.989, 1, 0.011,, 1, We can verify that for any path distribution P, S and P make MIX  OA  (OB  MC) true, and that if P is set to P T (MIX) then S and P make MIX-[Pr( mc )  0.8 ] true.

Friday, April 17, 2015 26 Proposed Directions  Adding observations to the logic  Proof theory  Allowing concurrent transactions  PTR logic programming  Investigating applications  Comparison with other probabilistic logics

Download ppt "Friday, April 17, 2015 1 PTR: A Probabilistic Transaction Logic Julian Fogel A logic for reasoning about action under uncertainty. A mathematically sound."

Similar presentations