Keep a distribution, because a mean cannot say who survives

M4.1 defines the tier 2 record and who may act on it, and nothing else: no
collapse transaction, no population advance, no materialization, no habitat
geometry. Those are M4.2 to M4.4 and each needs its own decision.

The named risk for this step is that population averages hide viable outliers,
which is a property of the record rather than of the maths applied to it later,
so it is answered here. Age classes each carry their own count and their own
reserve. A count with a mean reserve cannot tell a provisioned cohort from one
where half the members hold nothing, and nothing downstream can recover what
that discarded. Within a class members are indistinguishable; that is the
declared resolution and a stated loss. No accessor returns a mean, because an
average that is easy to reach becomes the authority.

Totals are summed from the classes rather than stored beside them, following the
archive's rule that a second tally is a thing that can disagree. Lineage is not a
field at all: ancestry is resolved from the genome through the archive, so a
cohort cannot contradict it or invent parentage from membership. Residuals are
integer numerators strictly below one member and are never added to a count.

Ownership is enforced rather than described. One record per habitat and genome
makes no-inventory-spendable-in-two-tiers unrepresentable instead of forbidden,
and replacement is refused under a different worker or an older epoch. That is a
single-process invariant; fencing between workers is M7 and M10. The
approximation bound is carried and never computed, since carrying a bound is not
meeting one.

All nine guards were confirmed load-bearing by removing each and rerunning. An
earlier sweep reporting none of them load-bearing was wrong and discarded: it
wrote to /tmp, which Git Bash and PowerShell resolve differently, so nothing was
ever mutated.

Release 34/34, analysis, ASan 34/34 and clang-format all ran and passed here.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
dingo
2026-09-24 06:14:07 -04:00
co-authored by Claude Opus 5
parent 72ed03f4dd
commit 1c8b292147
11 changed files with 1045 additions and 2 deletions
+39
View File
@@ -115,3 +115,42 @@ The shared bounded controller proposal is exercised only as a measurement driver
It has no perception, no learning and no evolving behavior, and its constants are
inputs rather than results. Population math, cohort collapse and resolution
equivalence remain M4 work.
## Implemented M4.1 cohort record
[ADR-0036](../adr/0036-cohort-state-and-ownership.md) defines the tier 2 record
and who may act on it. It settles nothing else above: there is no conversion
transaction, no population advance, no representative materialization and no
habitat geometry. `PlanCollapse`, `CommitCollapse`, `AdvancePopulation`,
`PlanMaterialize`, `CommitMaterialize` and `TransferPopulation` remain contracts
nothing implements.
A cohort is per genome, so distinct genomes are never averaged into one. Its age
classes each carry their own count and their own reserve, which is how the record
answers the risk that population averages hide viable outliers: a count with a
mean reserve cannot distinguish a provisioned cohort from one where half the
members hold nothing, and nothing later can recover that. Within one class members
are indistinguishable, and that is the declared resolution rather than an
oversight. No accessor returns a mean.
Lineage is not stored. It is resolved from the genome through the archive, so a
cohort cannot claim a parentage the archive would contradict and cannot invent
precise parentage from statistical membership. Totals are derived from the classes
rather than stored beside them.
Fractional members are carried per class as integer numerators over a declared
scale, strictly below one member. An expected fractional density is therefore
never mistaken for an available individual. Funding a residual against biomass,
and the seeded rule that turns one into a member, are M4.3 and M4.4.
`CohortRegistry` enforces that no inventory is spendable in two tiers by admitting
at most one record per habitat and genome, and by refusing a replacement from a
different worker or an older epoch. This is a single-process invariant: epochs
make a stale writer fail locally and are not cross-worker fencing, which is M7 and
M10. The registry holds no lock, lease or quorum, and nothing is serialized.
Approximation error is a declared field that nothing computes or checks yet.
Carrying a bound is not meeting one; M4.5 is where resolution equivalence is
measured. Conservation between a cohort and the rest of the world is the ledger's
property and is not asserted by this type, which holds an inventory without
participating in any transfer.