# Record
**Author:** @cameron.stream (`did:plc:gfrmhdmjvxn2sjedzboeudef`)

## `knowledge-probabilistic-programming`
**Collection:** `site.standard.document`
**AT URI:** `at://did:plc:gfrmhdmjvxn2sjedzboeudef/site.standard.document/knowledge-probabilistic-programming`

**Title:** Probabilistic Programming
**Published:** Tue, 21 Jul 2026 00:14:00 GMT
**Updated:** Tue, 21 Jul 2026 00:14:00 GMT
**Description:** Expressing generative models as programs and separating model structure from inference machinery.
**Publication:** `at://did:plc:gfrmhdmjvxn2sjedzboeudef/site.standard.publication/3mr4py6clps2f`
**Path:** /probabilistic-programming
**Tags:** knowledge, concept, statistics, probabilistic-programming, julia, bayesian-inference

**Content:**
```json
{
  "text": "Probabilistic programming is a method for expressing probabilistic models as executable programs and applying reusable inference algorithms to them. A probabilistic program describes how latent variables and observations are generated; an inference system then estimates the distribution of unknown quantities conditioned on observed data.\n\n## Model and inference\n\nOrdinary statistical code often combines a particular model with a hand-written estimation procedure. A probabilistic programming system separates those concerns. The model specifies random choices, deterministic computation, and observations. The runtime can then apply Markov chain Monte Carlo, variational inference, sequential Monte Carlo, enumeration, or another supported method.\n\nThis separation is not absolute. Some models are poorly matched to some inference algorithms, and efficient inference still depends on geometry, parameterization, and compiler support. The advantage is that model structure and inference machinery can be recombined rather than rebuilt together every time.\n\n## Traces and conditioning\n\nDuring execution, a probabilistic program produces a **trace** containing its random choices and their addresses. Conditioning marks some values as observed and asks for the distribution of the remaining choices. Dynamic control flow can change which choices exist in a trace, which is one reason probabilistic-program semantics require more machinery than ordinary numerical code.\n\n## Systems\n\n[Stan](https://mc-stan.org/) uses a specialized modeling language and gradient-based inference. [Gen](https://www.gen.dev/) emphasizes programmable inference and generative functions. [Turing.jl](https://turinglang.org/) embeds probabilistic models in Julia, allowing models to use Julia's language features, compiler, and automatic-differentiation ecosystem.\n\nProbabilistic programming is closely associated with [Bayesian inference](https://cameron.stream/knowledge/bayesian-inference), although probabilistic programs can also support simulation, likelihood-based methods, and other forms of uncertainty-aware computation. [Cameron](https://cameron.stream/knowledge/cameron) has contributed to Turing.jl.\n\n## Sources\n\n- [Turing.jl](https://turinglang.org/)\n- [Stan](https://mc-stan.org/)\n- [Gen](https://www.gen.dev/)",
  "$type": "site.standard.content.markdown",
  "version": "1.0"
}
```

---
*Fetched from https://enoki.us-east.host.bsky.network via `com.atproto.repo.getRecord`*