/ Ideas / Probabilistic Programming in OCaml

This is an idea proposed in 2018 as a Cambridge Computer Science Part II project, and has been completed by Hari Chandrasekaran. It was supervised by Tom Kelly, Liang Wang and Anil Madhavapeddy as part of my OCaml Labs project.

Summary

With increasing use of machine learning, it is useful to develop frameworks that support rapid development and functional specification of probabilistic models for inference and reasoning. Probabilistic Programming Languages aim to support concise syntax for specifying models and consequently making inference easier. This can pave way to improvements of the model created, more data gathering and further model refinement in an iterative sense.

PPL enables easier development of statistical models and allows decoupling inference from modelling. There is a lot of recent work on PPLs, and this project seeks to incorporate them into functional languages. This project aims to develop a small PPL with a graph based model for Bayesian inference (similar to the Edward PPL) into the Owl numerical library written in OCaml.

The implementation focusses on modularity, enabling the composability of models and allowing them contain parameters which could be random variables from common probability distributions or deterministic functions or combinations of other random variables. The language would allow the specification of generative models that model the joint probability distribution of latent variables and observed parameters, and inference by conditioning. The initial focus will be on common statistical inference methods such as MCMC. Other inference algorithms such as Hamiltonian Monte Carlo or Variational Inference will be explored as optional extensions to the project.

Background reading

Links

The dissertation is not available online; contact Hari Chandrasekaran directly to obtain a copy.

Related Ideas