5 · Compose

For Both Executive and Technical Readers

When the answer needs two models, the seam between them must be certified.

d-separation at the seam. If it holds, the hand-off is licensed.

Step 5 runs only on the composition path, when Route returned two or more models whose union covers the query. Compose checks whether the interface between them (the shared variables S) is safe to condition on by classifying the bridge by its graphical role and verifying d-separation holds after conditioning.

Composition failure is silent in most architectures. Here it is explicit: the CompositionCertificate either certifies the seam or names the failure mode.

Two models and their interface in. A composition certificate or refusal out.

IN IdentificationCertificate from Step 4
IN Two or more .bayes models with shared interface S
OUT CompositionCertificate or RefusalObject

Composition Certificate fraud + portfolio-risk · worked example
Models joinedfraud.bayes, portfolio-risk.bayes
Interface variableAccount Status, the node the two models share
Bridge classMediator
d-separation holdsYes
CertifiedYes

Conditioning on a collider opens a path. That is not a merge, it is confounding.

All five compositional requirements must hold: identical parameterisation at the interface, consistent joint distribution, Mediator bridge classification, d-separation post-conditioning, and for Rung 3, d-separation post-abduction. All five are necessary. None is sufficient alone.

Three classes. One is safe. One is invalid. One requires investigation.

Mediator: conditioning on S blocks the path. Hand-off is licensed.

Collider: conditioning on S opens a spurious path. Hand-off is invalid. Compose refuses.

Hidden common cause: unmeasured variable causes nodes in both models. Compose refuses unless modelled with a U-node.

Composability defines the rules. Compose enforces them.

Composability →, defines the five requirements and bridge classification schema.
Pipeline →, Compose is Step 5, runs only on the composition path.