Skip to main content

Module protocol

Module protocol 

Source
Expand description

Inputs and outputs of the eight kernel exports (see docs/kernel-protocol.md).

Structs§

DeriveIdsInput
Input to derive_ids.
DeriveIdsOutput
Output of derive_ids.
HashAtSeq
A (seq, state_hash) pair, from the journal or from a re-fold.
KernelError
A kernel failure. code is one of the closed set the kernel defines; the host branches on it, never on message.
KernelResult
Every export returns this shape: {"ok":true,"value":…} or {"ok":false,"error":…}.
KernelVersion
Output of kernel_version.
PrepareEventInput
Input to prepare_event.
ReduceStepInput
Input to reduce_step.
RefoldCheckInput
Input to refold_check.
RefoldCheckOutput
matches: false carries the first divergent seq and both hashes.
StateHashInput
Input to compute_state_hash.
StateHashOutput
Output of compute_state_hash.
ValidateEventOutput
Output of validate_event.

Enums§

Prepared
Output of prepare_event: what the host does next.
ReducerEvent
What the reducer sees. The kernel translates journal headers into these; the reducer never sees seq, random or lifecycle noise except where it needs them.