Source : Probabilistic Graphical Models: Principles and Techniques
Energy-based model
Def. 1
For a set of variables
up to a normalization constant
where
When algorithms of sampling (MCMC etc..) are used to generate such a distribution, it is expected that the ground states (meaning the states with a low value of energy) are sampled more often than the others, given the shape of the distribution.
Def. 1bis — Multilinear expansion, QUBO and HUBO
Let
Then
(the
Grouping the terms by order
Its truncation at order
with biases
The two conventions are linked by
Bayesian Networks
Notations
Throughout,
For a variable
Def. 2 — Factorization of a distribution
Let
This equation is called the chain rule for Bayesian networks. The individual factors
It means that we can fully learn the distribution of the system (considered as the set of variables here), just by the knowing the marginals of each node given all its parents).
Def. 3 — Bayesian Network
A Bayesian network is a pair
Def. 4 — Moral graph
Let
- keeping every edge of
and dropping its direction; - adding an edge between any two parents of a common child (“marrying the parents”).
Every family
Def. 5 — DIRAC mode
Let
- the target distribution it is meant to sample;
- a transform of
— a penalty added on top of it, or a factor swapped inside it — yielding the compiled energy; - its realisation on the backend.
A mode is a reference if its target is fixed by causal theory, and a test if its target is defined only as “the physical clamp’s output”. The identity or divergence of a test and its references is an experimental result, never an assumption.
Markov Random Fields
Def. 6 — MRFs
Let
Properties
This is the defining idea, and it comes in three equivalent strengths:
- Local Markov property: a variable is independent of all other variables given its immediate neighbors. That neighbor set is called its Markov blanket — once you condition on it, nothing else in the graph tells you anything more.
- Pairwise Markov property: any two non-adjacent variables are conditionally independent given all the rest.
- Global Markov property: if a set of nodes
separates the graph into two pieces and (every path from to passes through ), then and are conditionally independent given
Hammersley-Clifford theorem
For any strictly positive distribution satisfying the Markov property on
Here
Because
This is exactly the energy-based form used in the Ising model — an Ising model is a pairwise MRF, where cliques are just edges (pairwise potentials) and single nodes (local fields).
Technical detail
The distributions mentionned are usually implemented through tables (CPTs), which purpose in BNs and MRFs is the speedup of the calculations through factorization of probability distribution using independency properties between variables.
Conversely, any distribution of this Gibbs form — a product of clique potentials on
Def. 7 — Job
A job submitted for sampling is the pair
- the coefficient set
of the energy’s multilinear expansion (Def. 1bis) — diagonal , pairwise links , higher orders (if supported) — - the inverse-temperature schedule
at which it is sampled.
Implementing or updating any query means writing exactly these two objects.
Clamping
Let
Let
For example, if:
x = (x1, x2, x3, x4, x5)
S = {2, 5}
a = {a2 = 1, a5 = 0}then only
We denote by
The clamp penalty is
The penalty depends on
where
The object of interest is the free-variable marginal, obtained by summing over the clamped block :
Important clarification:
is not the metric used to validate the conditional distribution. It is an energy penalty function used to construct the clamped model. Validation should compare the resulting clamped distribution against the exact target distribution using KL divergence, total variation distance, query-level error, invalid-state mass, and partition-function checks.
Intervention vs Observation
Conceptual understanding of the difference
Take the confounding structure :
graph LR C((C)) --> X((X)) C((C)) --> Y((Y)) X((X)) --> Y((Y))
Observing X = x: You’re just looking at a subpopulation where X happens to equal x. But C still varies as it normally would among that subpopulation, and since C also drives Y, some of the association you see between X and Y is really just C leaking through — confounding.
Intervening do(X = x):
graph LR C((C)) --> Y((Y)) X((X)) --> Y((Y))
You’ve erased the C → X arrow. X no longer depends on C at all — you set it directly. So C can no longer create a spurious channel to Y through X. Any leftover association between X and Y in the post-surgery graph is now genuinely caused by X.
This is the entire reason the field exists: P(Y|X=x) mixes real causal effect with confounding bias. P(Y|do(X=x)) isolates the real causal effect, by construction, because the graph surgery removes the confounding pathway.
Example :
- Observational: “Among people who happen to smoke, what fraction get sick?” →
P(Y | X = x) - Interventional: “If I forced everyone to smoke, what fraction would get sick?” →
P(Y | do(X = x))
Impact on the distribution
the
- Delete every arrow pointing into X — X’s own structural equation is discarded entirely
- Set X = x as a constant, unconditionally
- Leave every other distribution in the system untouched
if the normal joint distribution was the one defined in the Bayesian Network Section, after
Intervention
Def. 8
Let
Special intervention cases:
- Identity:
gives and . - Hard intervention:
. That is exactly what the do(X=x)represents. All incoming edges ofare deactived and the mechanism is replaced with a parent-freepoint mass . On other cases, interventions are called soft. -smoothing: , replacing every mechanism by its -mixture with the uniform distribution on — see Treating zero-probability entries and corollary for detailed explanation.
Notational convention
- A subscript names the operation that produced a derived global object:
for the soft-intervened model, in strict parallel with (clamping at strength ) and (smoothing at level , the special case ; formally ).
Commentary