Transaction fields
Every transaction declares the following:data_model
Set data_model to a declared data model ID when the transaction reads or writes persistent objects. Set it to null only when the transaction performs no application object access and exists solely to produce or consume framework artifacts (transaction outputs and effect intents). Never use null to imply object access without a declared transactional boundary.
Isolation
The isolation level is an implementation guarantee provided by the execution environment:Transaction idempotency
Theidempotency field declares whether the execution environment provides durable keyed commit deduplication for this transaction:
deduplicated_by is the key mechanism for safe retries. When the execution environment sees the same (transaction, key) pair again, it resolves the prior commit and restores any artifacts that committed with it — rather than running the transaction body again. This makes the transaction safe across retries and lets the verifier prove that artifacts produced by the first commit are available on every subsequent attempt.
Transaction step kinds
Steps are declared as an ordered list insidesteps. The step order represents logical program order, which matters for lock-order analysis, transaction-read provenance, and artifact availability.
read
read
Reads fields from one or more objects matching a selector and binds the result to a transaction-local ID.
fields accepts kind: all to read every field, or kind: only with a list. The result is accessible within the same transaction through transaction_read:<result-id> value references. It is not available outside the transaction — export it through an establish_transaction_output step to use it in later program steps.write
write
Writes fields to objects matching a selector. Declares the provenance of the written values through a derivation.
insert
insert
Inserts a new object instance. The object’s identity fields come from the declared values derivation; you do not redeclare them separately. Insertion respects the object’s
identity uniqueness constraint.delete
delete
Deletes objects matching a selector.
lock
lock
Acquires a Lock steps appear in program order; concurrent transactions attempting to acquire the same lock in different orders may deadlock. Use a consistent field-based ordering where you need to model multiple locks in one transaction.
shared or exclusive lock on objects matching a selector. Declares an optional ordering to help lock-order and deadlock analysis.transition
transition
Applies a state machine transition to a persistent object. See State Machines for full details. A transition step also declares
effect_values — one value derivation per side effect declared on the transition.establish_effect_intent
establish_effect_intent
Establishes an effect intent artifact atomically with the transaction commit. The intent captures the specific effect instance — its payload values, fixed by the
values derivation at this step — so the intent is recoverable after a crash without re-deriving the payload.establish_transaction_output
establish_transaction_output
Exports a typed value from the transaction into the enclosing operation’s control. The output is available to program steps after the transaction executes or recovers.
Object selectors
Steps that target objects use a selector to identify which instances to act on:value in an eq predicate can be a value reference (a map with source and path) or a literal scalar (a plain string, bool, or integer).
Derivation
values in write, insert, establish-intent, and establish-output steps declares how the written or exported value is computed:
deterministic does not assert that the source values are replay-stable. The verifier separately determines whether each source is stable relative to the governing key. A derivation is replay-deterministic only when it is deterministic and every source is replay-stable.
Transaction outputs and operation control flow
Information observed inside a transaction (through aread step) is transaction-local and does not escape automatically. To use a read result in later program steps — a branch condition, an effect derivation, a terminal result — you must export it explicitly through establish_transaction_output.
deduplicated_by prevents that.
Artifact replay
When a crash occurs between a transaction commit and a later program step that depends on a transaction artifact (an output or an effect intent), the verifier must establish that the artifact is available on retry. There are two routes: Route A — Reconstruction: the establishing transaction is naturally replayable, and the artifact’s derivation is replay-deterministic. A retry re-executes the transaction and reconstructs the same artifact without requiring it to have been separately stored. Route B — Recovery: the establishing transaction isdeduplicated_by { key } with a replay-stable key. A retry encounters the prior Commit(T,K), resolves it, and restores the exact artifacts from the first successful commit.