diff --git a/docs/adr/0108-cellular-checkpoint-profile.md b/docs/adr/0108-cellular-checkpoint-profile.md index 9956883..ee03b80 100644 --- a/docs/adr/0108-cellular-checkpoint-profile.md +++ b/docs/adr/0108-cellular-checkpoint-profile.md @@ -46,7 +46,7 @@ together, and ADR-0107 additionally produces corpses and a heat transfer. mixed inventories ([ADR-0109](0109-cellular-region-conservation-closure.md)). Restore performs full validation and requires byte-identical canonical re-encoding before readiness. -- Cap the envelope at 8 MiB, with at most 256 living cells, 4,096 provisioned +- Cap the envelope at 16 MiB ([ADR-0110](0110-cellular-checkpoint-payload-bound.md)), with at most 256 living cells, 4,096 provisioned patches and 65,536 retained organisms/corpses. Validate lengths and counts before allocation. The existing archive and habitat codecs are nested with their formats and checksums; the manifest SHA-256 remains the integrity diff --git a/docs/adr/0110-cellular-checkpoint-payload-bound.md b/docs/adr/0110-cellular-checkpoint-payload-bound.md new file mode 100644 index 0000000..bb039e9 --- /dev/null +++ b/docs/adr/0110-cellular-checkpoint-payload-bound.md @@ -0,0 +1,29 @@ +# ADR-0110: Cellular checkpoint payload bound + +## Status + +Accepted engineering correction to ADR-0108 (2026-10-10). The payload bound is +raised before profile-4 code is admitted; biological and retention rules do not +change. + +## Context + +The complete profile-4 closure includes the maximum lineage archive and one +retained corpse record for each dead organism. With the specified 65,536 +organism/corpse bound, the corpse records plus maximum archive and habitat exceed +ADR-0108's original 8 MiB payload cap. Enforcing that cap would make the stated +retention limit unreachable and force an undocumented corpse/history policy. + +## Decision + +Raise the maximum canonical `cellular-lives-v1` payload from 8 MiB to 16 MiB. +Keep the limits of 256 living cells, 4,096 provisioned patches and 65,536 +retained organisms/corpses. Enforce the 16 MiB bound in the C++ decoder, object +store, manifest parser and PostgreSQL migration before allocating or publishing. +Profiles 1–3 keep their existing caps. + +## Consequences + +ADR-0108 and `schemas/cellular-lives-v1.md` use 16 MiB. The owning region and +CI tests must exercise the maximum-size arithmetic and reject payloads above +the bound. Each profile-4 snapshot may rewrite up to 16 MiB. diff --git a/docs/adr/README.md b/docs/adr/README.md index a7dc439..e8655b9 100644 --- a/docs/adr/README.md +++ b/docs/adr/README.md @@ -10,6 +10,7 @@ - [ADR-0107: Cellular starvation and corpse transfer trial](0107-cellular-starvation-and-corpse-transfer.md) - accepted M11.3 death closure transfers body/reserve to a corpse and accumulated heat to the region heat owner. - [ADR-0108: Cellular life checkpoint profile](0108-cellular-checkpoint-profile.md) - accepted additive profile-4 state-closure direction; codec, SQL admission and recovery remain open. - [ADR-0109: Cellular region-wide conservation closure](0109-cellular-region-conservation-closure.md) - corrects profile-4 accounting to conserved region totals per channel while retaining patch provenance. +- [ADR-0110: Cellular checkpoint payload bound](0110-cellular-checkpoint-payload-bound.md) - raises profile-4's maximum object size so the complete retained archive and corpse limits fit. - [ADR-0058: Region durability contract](0058-region-durability-contract.md) - accepted M7.1 full checkpoint batches and explicit state closure; storage implementation follows. diff --git a/docs/engineering/M11_3_DELIVERY_PLAN.md b/docs/engineering/M11_3_DELIVERY_PLAN.md index d2ed7ca..ed09b1d 100644 --- a/docs/engineering/M11_3_DELIVERY_PLAN.md +++ b/docs/engineering/M11_3_DELIVERY_PLAN.md @@ -74,8 +74,8 @@ No new dependency or renderer is required. If the selected spatial, checkpoint, or publication design conflicts with accepted architecture, stop that affected implementation and resolve the contract first. -ADR-0108/0109 and `schemas/cellular-lives-v1.md` define an additive profile-4 -state closure with region-wide channel conservation while preserving profile 3. +ADR-0108/0109/0110 and `schemas/cellular-lives-v1.md` define an additive profile-4 +state closure with region-wide channel conservation and a realizable 16 MiB bound while preserving profile 3. This is a contract only: codec/restore, SQL allowlisting, a cellular region owner and crash-recovery evidence are still required before the first hands-on cellular probe. @@ -155,7 +155,7 @@ scoped change before starting the next segment. in-memory cellular owner, applies shared-habitat ticks atomically, records starvation corpses/deaths and enforces region-wide conservation. Checkpoint encoding, durable publication and online session execution remain open. -- 11.3d contract: ADR-0108/0109 and `schemas/cellular-lives-v1.md` define a separate +- 11.3d contract: ADR-0108/0109/0110 and `schemas/cellular-lives-v1.md` define a separate profile-4 checkpoint closure for lives, habitat, corpses, heat and lineage. No profile-4 code or durable tick publication is implemented yet. diff --git a/docs/engineering/VALIDATION.md b/docs/engineering/VALIDATION.md index 2c79a49..50bdeea 100644 --- a/docs/engineering/VALIDATION.md +++ b/docs/engineering/VALIDATION.md @@ -6022,7 +6022,7 @@ remain pending. ## 2026-10-10 — M11.3d profile-4 closure contract (implementation pending) -ADR-0108/0109 and `schemas/cellular-lives-v1.md` specify an additive complete +ADR-0108/0109/0110 and `schemas/cellular-lives-v1.md` specify an additive complete cellular checkpoint with region-wide channel conservation while preserving profile 3. This is documentation only; no codec, SQL admission or recovery behavior is implemented or validated by diff --git a/schemas/cellular-lives-v1.md b/schemas/cellular-lives-v1.md index 83e5f62..0699a59 100644 --- a/schemas/cellular-lives-v1.md +++ b/schemas/cellular-lives-v1.md @@ -45,7 +45,7 @@ is unsupported until an identity-remapping contract exists. | Component | Maximum | |---|---:| -| Total payload | 8 MiB | +| Total payload | 16 MiB (ADR-0110) | | Living cells | 256 | | Provisioned food patches | 4,096 | | Retained organisms and corpses | 65,536 |