nx_proportion_guard.nx
buildroot/runtime/nx_proportion_guard.nx
about
nx_proportion_guard.nx -- FINITE plausibility envelopes for body axes.
nx_canon_proportions.nx already seals the axis vocabulary (NX_AXIS_*, ids 1..32) and the
RATIO canon (this ratio should be phi-ish, within tolerance). What it does not carry is an
ABSOLUTE envelope: a body can satisfy every ratio and still be 3 metres tall. Ratio-only
checking is exactly how an alien figure passes review.
THE LAW THIS ENCODES (operator, 2026-07-30): a human being has a finite range, and even
idealized or fantasy forms have finite proportions -- wider, differently centred, still
bounded. So regimes are DATA and every one of them is closed at both ends:
HUMAN -- population range for an adult female
IDEALIZED -- narrower aesthetic band, strictly INSIDE human-possible
KIN -- monsterkin/fantasy: wider than human, still finite by construction
★THE DESIGN DECISION THAT MAKES THIS A GUARD: an axis with no bound row REFUSES. Treating
"no bound" as "anything goes" is how impossible values get in -- the same shape as a
capability-denied read being mistaken for "unavailable". Missing is not permission.
Callers must REFUSE on a non-zero verdict, never silently clamp: a clamped body is a lie
told to whoever reads the number back.
PROVENANCE (honest): the rows below are literature-typical adult-female ranges entered by
hand, not yet an ingest of a measured anthropometric dataset. They are bounds we can defend
as plausible, not bounds we have measured ourselves -- see the debt filed alongside this
file. Widen or narrow them by MEASUREMENT, never by feel.
license_tier: ORIGINAL No hw writes (Rule 26).
dependencies 2 imports · 2 importers
imports: nx_syscalls.nxnx_canon_proportions.nx
imported by: nx_proportion_guard_gate.nxnx_softtissue.nx
structs
| none |
consts
| 30 | const NX_MAGIC_1400: i64 = 1400 |
| 31 | const NX_MAGIC_1950: i64 = 1950 |
| 32 | const NX_MAGIC_1550: i64 = 1550 |
| 33 | const NX_MAGIC_1850: i64 = 1850 |
| 34 | const NX_MAGIC_1200: i64 = 1200 |
| 35 | const NX_MAGIC_2400: i64 = 2400 |
| 39 | const NX_AXIS_BREAST_PROJECTION: i64 = 33 // chest wall to nipple, mm |
| 41 | const PG_HUMAN: i64 = 0 |
| 42 | const PG_IDEALIZED: i64 = 1 |
| 43 | const PG_KIN: i64 = 2 |
| 44 | const PG_REGIME_N: i64 = 3 |
| 46 | const PG_OK: i64 = 0 |
| 47 | const PG_BELOW: i64 = 1 |
| 48 | const PG_ABOVE: i64 = 2 |
| 49 | const PG_NO_BOUND: i64 = 3 |
| 51 | const PG_MIN: i64 = 0 |
| 52 | const PG_MAX: i64 = 1 |
| 56 | const PG_ABSOLUTE_CEILING_MM: i64 = 3000 |
functions
| 61 | func pg_bound(axis: i64, regime: i64, which: i64) -> i64 |
| 105 | func pg_has_bound(axis: i64, regime: i64) -> i64 |
| 112 | func pg_check(axis: i64, value_mm: i64, regime: i64) -> i64 |
| 122 | func pg_sample(axis: i64, regime: i64, h01: i64) -> i64 |
| 135 | func pg_selftest() -> i64 |