Spectre.GAM.GovernedAct.Integrity (Spectre v0.4.0)

Copy Markdown View Source

Whole-history invariants for a folded Governed Act ledger.

Spectre.GAM.GovernedAct.Fold rejects invalid transitions while replaying each event and batch. This module checks properties that only become meaningful once a complete prefix and an explicit observation time are available: foundation completeness, unresolved causal debt, expired dispatches and conservation of Meter accounts.

The module is pure. It is shared by audit and can be reused by recovery diagnostics without making either path trust a live runtime process.

Summary

Functions

Validates a complete folded prefix at trusted observation time.

Functions

validate(state, observed_at)

@spec validate(Spectre.GAM.GovernedAct.State.t(), non_neg_integer()) ::
  :ok | {:error, term()}

Validates a complete folded prefix at trusted observation time.