Skip to main content

The Block

An ALX Block is a data object with five protocol fields: application-defined JSON content, the parentHashes of its direct parent Blocks, two deterministic hashes, and a protocolVersion. Conforming implementations recompute both hashes from content and parentHashes and compare them with the recorded values.

The Five Fields​

Block defines each field and the parent normalization rules.

type Block = {
blockHash: string;
contentHash: string;
parentHashes: string[];
content: unknown;
protocolVersion: "1";
};

A Complete Block​

A root Block declares no parents; createBlock(content, []) returns the root Block below. The derived Block lists the policy's blockHash in parentHashes.

Root Block
{
"blockHash": "0x6e4a0ec5756a4569b4bfe1fca097a70fb151da446fb26f138f3edce1958a9e37",
"contentHash": "0xf90f01822677e747de0a7173c74fdb0af4079f983489931cec878e3ef4b02f96",
"parentHashes": [],
"content": {
"type": "reference-document",
"title": "Information Security Policy",
"uri": "https://example.org/policies/security.pdf",
"version": "3.1",
"publishedAt": "2026-05-10"
},
"protocolVersion": "1"
}
Derived Block
{
"blockHash": "0xa0c9a3ac4d1cb0a27047ba674befce43f6049c98719722965607798aa507b746",
"contentHash": "0x3fb15a5557b2009dfe24878fffda0ee091e41ec89e78dfa96be63d621c497b5f",
"parentHashes": [
"0x6e4a0ec5756a4569b4bfe1fca097a70fb151da446fb26f138f3edce1958a9e37"
],
"content": {
"type": "agent-output",
"task": "Summarize the security review",
"result": "The review identified three high-priority findings.",
"model": "application-defined",
"createdAt": "2026-07-28T14:30:00Z"
},
"protocolVersion": "1"
}

Content Examples​

ALX treats content as opaque application data. The examples below show content payloads only.

Market inputs and an application-defined assessment. Parent Blocks: the market dataset, a prior analysis, the model output, and the analyst review.

{
"type": "market-analysis",
"symbol": "EXMPL",
"observationDate": "2026-07-28",
"inputs": {
"price": 182.41,
"revenueGrowth": 0.34
},
"assessment": "positive"
}

When to Create a Block​

Create a Block when JSON-serializable content needs deterministic identity, declared parent relationships, or both. A Block with an empty parentHashes array is a root Block; a Block with parents extends a derivation Graph.