206 research outputs found
Probabilistic Operational Semantics for the Lambda Calculus
Probabilistic operational semantics for a nondeterministic extension of pure
lambda calculus is studied. In this semantics, a term evaluates to a (finite or
infinite) distribution of values. Small-step and big-step semantics are both
inductively and coinductively defined. Moreover, small-step and big-step
semantics are shown to produce identical outcomes, both in call-by- value and
in call-by-name. Plotkin's CPS translation is extended to accommodate the
choice operator and shown correct with respect to the operational semantics.
Finally, the expressive power of the obtained system is studied: the calculus
is shown to be sound and complete with respect to computable probability
distributions.Comment: 35 page
Categories of Timed Stochastic Relations
AbstractStochastic behaviorâthe probabilistic evolution of a system in timeâis essential to modeling the complexity of real-world systems. It enables realistic performance modeling, quality-of-service guarantees, and especially simulations for biological systems. Languages like the stochastic pi calculus have emerged as effective tools to describe and reason about systems exhibiting stochastic behavior. These languages essentially denote continuous-time stochastic processes, obtained through an operational semantics in a probabilistic transition system. In this paper we seek a more descriptive foundation for the semantics of stochastic behavior using categories and monads. We model a first-order imperative language with stochastic delay by identifying probabilistic choice and delay as separate effects, modeling each with a monad, and combining the monads to build a model for the stochastic language
Logical Relations for Monadic Types
Logical relations and their generalizations are a fundamental tool in proving
properties of lambda-calculi, e.g., yielding sound principles for observational
equivalence. We propose a natural notion of logical relations able to deal with
the monadic types of Moggi's computational lambda-calculus. The treatment is
categorical, and is based on notions of subsconing, mono factorization systems,
and monad morphisms. Our approach has a number of interesting applications,
including cases for lambda-calculi with non-determinism (where being in logical
relation means being bisimilar), dynamic name creation, and probabilistic
systems.Comment: 83 page
Running Probabilistic Programs Backwards
Many probabilistic programming languages allow programs to be run under
constraints in order to carry out Bayesian inference. Running programs under
constraints could enable other uses such as rare event simulation and
probabilistic verification---except that all such probabilistic languages are
necessarily limited because they are defined or implemented in terms of an
impoverished theory of probability. Measure-theoretic probability provides a
more general foundation, but its generality makes finding computational content
difficult.
We develop a measure-theoretic semantics for a first-order probabilistic
language with recursion, which interprets programs as functions that compute
preimages. Preimage functions are generally uncomputable, so we derive an
abstract semantics. We implement the abstract semantics and use the
implementation to carry out Bayesian inference, stochastic ray tracing (a rare
event simulation), and probabilistic verification of floating-point error
bounds.Comment: 26 pages, ESOP 2015 (to appear
Abstract Hidden Markov Models: a monadic account of quantitative information flow
Hidden Markov Models, HMM's, are mathematical models of Markov processes with
state that is hidden, but from which information can leak. They are typically
represented as 3-way joint-probability distributions.
We use HMM's as denotations of probabilistic hidden-state sequential
programs: for that, we recast them as `abstract' HMM's, computations in the
Giry monad , and we equip them with a partial order of increasing
security. However to encode the monadic type with hiding over some state
we use rather
than the conventional that suffices for
Markov models whose state is not hidden. We illustrate the
construction with a small
Haskell prototype.
We then present uncertainty measures as a generalisation of the extant
diversity of probabilistic entropies, with characteristic analytic properties
for them, and show how the new entropies interact with the order of increasing
security. Furthermore, we give a `backwards' uncertainty-transformer semantics
for HMM's that is dual to the `forwards' abstract HMM's - it is an analogue of
the duality between forwards, relational semantics and backwards,
predicate-transformer semantics for imperative programs with demonic choice.
Finally, we argue that, from this new denotational-semantic viewpoint, one
can see that the Dalenius desideratum for statistical databases is actually an
issue in compositionality. We propose a means for taking it into account
Recommended from our members
Formally justified and modular Bayesian inference for probabilistic programs
Probabilistic modelling offers a simple and coherent framework to describe the
real world in the face of uncertainty. Furthermore, by applying Bayes' rule
it is possible to use probabilistic models to make inferences about the state of
the world from partial observations. While traditionally probabilistic models
were constructed on paper, more recently the approach of probabilistic
programming enables users to write the models in executable languages resembling
computer programs and to freely mix them with deterministic code.
It has long been recognised that the semantics of programming languages is
complicated and the intuitive understanding that programmers have is often
inaccurate, resulting in difficult to understand bugs and unexpected program
behaviours. Programming languages are therefore studied in a rigorous way using
formal languages with mathematically defined semantics. Traditionally formal
semantics of probabilistic programs are defined using exact inference results,
but in practice exact Bayesian inference is not tractable and approximate
methods are used instead, posing a question of how the results of these
algorithms relate to the exact results. Correctness of such approximate methods
is usually argued somewhat less rigorously, without reference to a formal
semantics.
In this dissertation we formally develop denotational semantics for
probabilistic programs that correspond to popular sampling algorithms often used
in practice. The semantics is defined for an expressive typed lambda calculus
with higher-order functions and inductive types, extended with probabilistic
effects for sampling and conditioning, allowing continuous distributions and
unbounded likelihoods. It makes crucial use of the recently developed formalism
of quasi-Borel spaces to bring all these elements together. We provide semantics
corresponding to several variants of Markov chain Monte Carlo and Sequential
Monte Carlo methods and formally prove a notion of correctness for these
algorithms in the context of probabilistic programming.
We also show that the semantic construction can be directly mapped to an
implementation using established functional programming abstractions called
monad transformers. We develop a compact Haskell library for probabilistic
programming closely corresponding to the semantic construction, giving users a
high level of assurance in the correctness of the implementation. We also
demonstrate on a collection of benchmarks that the library offers performance
competitive with existing systems of similar scope.
An important property of our construction, both the semantics and the
implementation, is the high degree of modularity it offers. All the inference
algorithms are constructed by combining small building blocks in a setup where
the type system ensures correctness of compositions. We show that with basic
building blocks corresponding to vanilla Metropolis-Hastings and Sequential
Monte Carlo we can implement more advanced algorithms known in the literature,
such as Resample-Move Sequential Monte Carlo, Particle Marginal
Metropolis-Hastings, and Sequential Monte Carlo squared. These implementations
are very concise, reducing the effort required to produce them and the scope for
bugs. On top of that, our modular construction enables in some cases
deterministic testing of randomised inference algorithms, further increasing
reliability of the implementation.Engineering and Physical Sciences Research Council, Cambridge Trust, Cambridge-Tuebingen programm
The Expectation Monad in Quantum Foundations
The expectation monad is introduced abstractly via two composable
adjunctions, but concretely captures measures. It turns out to sit in between
known monads: on the one hand the distribution and ultrafilter monad, and on
the other hand the continuation monad. This expectation monad is used in two
probabilistic analogues of fundamental results of Manes and Gelfand for the
ultrafilter monad: algebras of the expectation monad are convex compact
Hausdorff spaces, and are dually equivalent to so-called Banach effect
algebras. These structures capture states and effects in quantum foundations,
and also the duality between them. Moreover, the approach leads to a new
re-formulation of Gleason's theorem, expressing that effects on a Hilbert space
are free effect modules on projections, obtained via tensoring with the unit
interval.Comment: In Proceedings QPL 2011, arXiv:1210.029
Probabilistic Operational Semantics for the Lambda Calculus
Probabilistic operational semantics for a nondeterministic extension of pure \u3bb-calculus is studied. In this semantics, a term evaluates to a (finite or infinite) distribution of values. Small-step and big-step semantics, inductively and coinductively defined, are given. Moreover, small-step and big-step semantics are shown to produce identical outcomes, both in call-by-value and in call-by-name. Plotkin\u2019s CPS translation is extended to accommodate the choice operator and shown correct with respect to the operational semantics. Finally, the expressive power of the obtained system is studied: the calculus is shown to be sound and complete with respect to computable probability distributions
Random-World Semantics and Syntactic Independence for Expressive Languages
We consider three desiderata for a language combining logic and probability: logical expressivity, random-world semantics, and the existence of a useful syntactic condition for probabilistic independence. Achieving these three desiderata simultaneously is nontrivial. Expressivity can be achieved by using a formalism similar to a programming language, but standard approaches to combining programming languages with probabilities sacrifice random-world semantics. Naive approaches to restoring random-world semantics undermine syntactic independence criteria. Our main result is a syntactic independence criterion that holds for a broad class of highly expressive logics under random-world semantics. We explore various examples including Bayesian networks, probabilistic context-free grammars, and an example from Mendelian genetics. Our independence criterion supports a case-factor inference technique that reproduces both variable elimination for BNs and the inside algorithm for PCFGs
- âŠ