SEM: Bundled Structural Equation Model (V2) #
A SEM V α is a CausalGraph V together with a Mechanism for every
vertex. Replaces the old CausalDynamics (which conflated the implicit
graph topology with the precondition-list mechanism content into a
single List CausalLaw).
IsDeterministic and IsBool are Prop mixin classes that consumers
can require — mirroring the mathlib pattern where typeclass mixins
mark properties of a structure value (IsMarkovKernel etc.).
Phase A scope: structure + mixins only. Forward propagation, intervention,
and counterfactual queries live in SEM/Basic.lean.
A structural equation model: a causal graph with a mechanism at
every vertex over a per-vertex value type α.
Replaces the old CausalDynamics. The graph topology is now
explicit (graph.parents v) and separate from mechanism content
(mech v); the value type is parameterized (α : V → Type*)
instead of hardcoded Bool.
- graph : CausalGraph V
The underlying causal graph (parent finsets per vertex).
The mechanism at each vertex: parent values ↦ distribution over
α v.
Instances For
The SEM is fully deterministic: every vertex's mechanism is Dirac.
- mech_det (v : V) : (M.mech v).IsDeterministic
Instances
Project per-vertex Mechanism.IsDeterministic from SEM.IsDeterministic.