Skip to main content

Temporal Modal Logic (Rules)

Rules express constraints using modal mu-calculus — a logic that reasons about what's possible, necessary, and how things evolve over time.

OperatorMeaning
[A] φAfter ALL A-transitions, φ holds
<A> φAfter SOME A-transition, φ holds
[-A] φIf A is refused/impossible, φ holds
[<+A>] φCommitted: must do A, and φ holds after

The Diamondbox [<+A>]

The diamondbox operator [<+A>] means:

  • The agent CAN perform action A
  • The agent CANNOT refuse action A
  • After A, the formula φ holds

This is the key operator for expressing commitments.

Temporal Operators (Sugar)

OperatorMeaningDefinition
always(φ)φ holds now and forevergfp(X, φ & []X)
eventually(φ)φ holds now or sometime laterlfp(X, φ | <>X)
until(p, q)p holds until q becomes truelfp(X, q | (p & <>X))

Fixed Points

For complex properties, use fixed points directly:

// Greatest fixed point (νX) - invariants, safety
gfp(X, property & []X)

// Least fixed point (μX) - reachability, liveness
lfp(X, target | <>X)

Boolean Connectives

φ & ψ           // Conjunction (and)
φ | ψ // Disjunction (or)
!φ // Negation (not)
!φ | ψ // Conditional rule: if φ, then ψ
true // Always true
false // Always false

Prefer explicit Boolean conditionals in examples. The parser may accept formula-level implication sugar, but !φ | ψ keeps temporal steps visually separate from proof implication.

State Predicates in Formulas

Rules constrain who can commit based on contract state. Use path-based predicates:

// Check a boolean flag
bool_true(/status/delivered.bool)

// Check text value
text_eq(/status.text, "delivered")

// Authorization based on state plus signature evidence
!<+RELEASE> true | <+RELEASE +signed_by(/parties/buyer.id)> true

// Committed to sign (diamondbox with predicate)
[<+signed_by(/parties/seller.id)>] true

Rules gate who can commit and which labelled transitions are allowed based on state, signatures, and other evidence.