Files
nimmerworld.eachpath.local/schemas/gate_table.md
T

1.4 KiB

Gate Table

PostgreSQL schema in Phoebe. Registry row per gate; state row per gate.

gate_registry

Field Type Rationale
gate TEXT PK, max 64, dot-namespaced stable wire/registry key
tier TEXT CHECK IN ('T0','T1','T2','T3') declared role label
tier_locked BOOLEAN runtime refuses tier writes when true
why TEXT NOT NULL, max 200 reason attention argues, audit string
mode_overrides JSONB default {} per-mode tier shifts
created_by, created_at TEXT, TIMESTAMPTZ registry provenance

gate_state

Field Type Rationale
gate TEXT PK FK gate_registry identity
window_start TIMESTAMPTZ aggregation boundary
counters JSONB default {} per-gate counters
threshold NUMERIC(4,1) default 5.0 attention value; numeric avoids float drift
last_opened BIGINT (cycle index) starvation counts cycles, not time
last_decision_cycle UUID replay handle
last_l1_rtt_ms, last_l2_rtt_ms INTEGER last completed cycle probes
l1_rtt_ewma, l2_rtt_ewma NUMERIC(10,1) sliding means with hysteresis

Wire identity

ID Assigned at
event_uuid sensor, at impulse
cycle_uuid lemniscate, at cycle open
decision_uuid L1 decision

UUID v7; native UUID type; canonical display = v7 hex string.

Version: 0.2 | Updated: 2026-11-04