KB-52CC

Mega Gate — Channel Proof Obligations

12 min read Revision 1

Mega Gate — Channel Proof Obligations

Date: 2026-06-18 · Workstream: LEGO-PILOT-SLICE-0-B2-MEGA-GATE-BUNDLE-2026-06-18 (Deliverable 6 of 20) · Editorial revision: rev1 Class: design-only / proof obligations / decision-support · READ-ONLY · NON-ENACTING · NON-AUTHORIZING · NOT remediation · NOT technical design · NOT implementation · NO blocker resolved · NO runtime touched.

Metadata convention. Editorial revision (rev1) only. AgentData storage revision and content_length are authoritative in AgentData metadata at read time; not pinned in this body.

Proof-obligations lock. This packet states what each channel must prove before an eventual TD/build — as obligations, not as proofs performed. It runs no check, installs nothing, wires nothing, selects no channel. RECOMMENDATION_ONLY — NOT AUTHORITY — OWNER_GATE_REQUIRED — FUTURE_TECHNICAL_DESIGN_REQUIRED. Stating an obligation is not meeting it; nothing is verified here.


0. Status and non-authorization

STATUS: PASS — engineering / design-only. This is a complete design-only set of per-channel proof obligations: what each candidate (and each risky/future-gated channel) must demonstrate — liveness, observability, governance, rollback, no-lane-coupling — before any TD or build, and which obligations are read-only-provable vs. which require an out-of-band or write-gated act.

Engineering PASS ≠ authority PASS. A PASS means the obligations are complete on paper. It is not an Owner authorization to run any check, install, wire, promote, or build. Default disposition: HOLD.

Pipeline position (downstream-only). Deliverable 6 of the Mega Gate Bundle; it makes the channel recommendation (Deliverables 4/5) actionable by stating the evidence a chosen channel must produce — so an Owner channel decision is not "on paper only." It proves nothing.

Non-authorization (explicit). As Deliverable 4 §0 (no channel selected/wired; no pg_cron install; no contract promotion; no worker enable; no scheduler/contract spec; no runtime check run). v0.1/FIX7 V3 not overwritten; v0.2 not authority.

Evidence basis — INHERITED_EVIDENCE. No runtime queried. The provability of each obligation is bounded by the carried tool-boundary caveats. AgentData metadata authoritative at read time. CAV-3/CAV-4/CAV-5 carried.

Reading discipline (Codex caveat, honored). All sources read directly from AgentData KB, bounded/sequential, by the main process — no parallel/background reader-agents, no sub-agents, no local-prose inference. /tmp = decode-scratch only, never SSOT.


1. Purpose

Answer the macro's second question for the channel lane: what evidence is needed for each channel before a build? The packet answers:

  1. What must each channel prove? — §5 per-channel obligations.
  2. Which obligations are read-only-provable? — §5 column.
  3. Which require an out-of-band or write-gated act? — §5 column.
  4. What is the shared evidence floor for any channel? — §5 floor.

The one rule, above all detail. A channel decision is acceptable only when the chosen channel's obligations are met with evidence, not asserted. This packet states the obligations; meeting them is a future, separately-gated step (read-only where possible, write-gated where a build is required).


2. Sources read

All 25 required sources read first-hand from AgentData KB, by the main process, sequentially; none SOURCE_NOT_READ (full list in Deliverable 20 §2). Used principally: the channel decision packet §6–§13 (per-channel evidence requirements, observability, rollback); R2a §2/§5/§6/§9 (the tool-boundary; the snapshot; the GUC layers); Điều 32 §2.1; the interface packet S7/S8; operating-rules (AP-CLOSE; read-only inventory rule).


3. Accepted baseline (carried, not re-derived)

  • Tool-boundary (CAV-3/CAV-4, carried): no crontab -l / systemctl / docker exec / docker inspect tool exists; read_file is allowlisted to /opt/incomex/docs, /opt/incomex/dot/specs, /var/log/nginx; /opt/incomex/dot/bin + env files unreadable; container logs tail-only (≤500 lines). Host cron is provable only via the DB-captured wf_host_crontab_snapshot.
  • GUC layer (CAV-5, carried): the persisted GUC layer is empty (pg_settings app.%=0, pg_db_role_setting=0); the transient session layer is unreadable — out-of-band only.
  • Shared evidence floor (carried, channel decision §12): regardless of channel, B2 must append the same S7 run-evidence (rows scanned/passed/failed per stage, runner id, channel id, rule-set version/hash, start/end, per-failure audit records). S7 records; it does not decide. The channel id in S7 is what makes a later channel swap auditable.
  • Blockers — all OPEN. Tool/packet lock carried.

4. Analysis — provability classes

Each obligation falls into one of three provability classes, bounded by the carried caveats:

  • R/O — read-only-provable now (in a future Owner-gated read-only pass): catalog reads + DB-captured snapshots (e.g. the host-cron entry in wf_host_crontab_snapshot; the agent-api contract row + persisted master-switch state; pg_extension for pg_cron; queue heartbeat for the worker).
  • OOB — out-of-band: Owner-controlled, not readable by the available tools (the transient GUC; deep container/host liveness beyond the snapshot).
  • WG — write-gated: provable only after a build/enable (the producer actually firing on the chosen channel; the queue actually draining; the extension actually installed).

The classification matters because an Owner channel decision should not be blocked on WG/OOB obligations it cannot meet read-only — those are met after selection, behind their own gates.


5. Per-channel proof obligations

Shared evidence floor (every channel, before any build is accepted). B2 must, once built, append S7 run-evidence including the channel id, rows scanned/passed/failed per stage, runner id, rule-set version/hash, start/end timestamps, and per-failure audit records (records-not-decides). This is a build-time obligation (WG); it is stated here, not met here.

Channel Proof obligation (before TD/build) Provability class Read-only-provable?
host cron (1) a cron entry bound to the inspector present in wf_host_crontab_snapshot; (2) the entry invokes a governed producer, not a manual script (Điều 32 §2.1); (3) per-run S7 evidence confirming the producer ran (counts/ids/timestamps/rule-set hash); (4) the producer is genuinely idempotent (re-firing must not double-stamp) (1) R/O (snapshot); (2) R/O+design; (3)(4) WG (need the producer) Partly — entry presence is read-only; "did it run" / idempotency need a built producer
agent-api executor (:8090) (1) a dot_agent_api_contract row binding the inspector DOT to :8090; (2) the master-switch state read (must be intentionally, Owner-gated, flipped before REAL_RUN); (3) dispatch records + per-run S7 evidence; (4) proof the binding does not entangle the KG-lane contract (per-DOT, AC-7) (1) R/O (contract row); (2) R/O persisted + OOB transient (CAV-5); (3) WG; (4) R/O+design Partly — contract row + persisted switch read-only; transient switch OOB; dispatch needs a run
pg_cron (1) an infra decision + approval to install the extension; (2) pg_extension shows pg_cron installed; (3) the cron.job catalog entry bound to the inspector; (4) per-run S7 evidence; (5) a tested extension-removal/rollback path (1) DEC; (2) R/O after install (WG to install); (3)(4) WG; (5) WG No — install is a write; only post-install pg_extension read is read-only
job_queue worker (1) the worker + job substrate enabled and proven to drain (a live heartbeat, not a config flag); (2) job_queue rows consumed end-to-end on a sample; (3) per-run S7 evidence; (4) an explicit guard against the undrained-queue failure mode (event_outbox 215k precedent) (1) WG (enable) + R/O (heartbeat read); (2)(3) WG; (4) design+WG No — enabling/draining are writes; only heartbeat read is read-only
manual one-shot n/a — rejected as a standing channel (no standing artifact to prove; Điều 32 §2.1 violation; fused-INSERT vehicle). The only legitimate residual one-shot is B5, a separate Owner-gated backlog pass. n/a n/a

Reading of the obligations (recommendation-only). The two candidate channels are the only ones with a read-only-provable first obligation (host-cron entry in the snapshot; agent-api contract row + persisted switch). pg_cron and job_queue require a write (install / enable) before almost anything is provable — consistent with their risky/future-gated disposition. This does not select a channel; it shows that an Owner channel decision among the candidates can be partly validated read-only, with the rest (the producer actually firing) met after the build, behind its own gate.

Idempotency obligation (all channels). Because no candidate channel is transactional with the inspect_* writes, every channel carries the same producer-side obligation: the producer must be genuinely idempotent (set only an unset column; never double-stamp; never re-stamp), so re-firing the channel is safe. This is a producer/contract obligation (Deliverable 9 / the B2 contract), surfaced here because the channel's non-transactionality is what makes it load-bearing.


6. Owner-gated future work

Future work Gate required Forbidden now?
Run the read-only checks that prove a candidate's first obligation (snapshot / contract row / persisted switch / pg_extension) Owner authorizes a read-only pass Yes
Confirm the transient GUC / master-switch out-of-band (agent-api) Owner out-of-band (CAV-5) — read-only Yes (not done here)
Install pg_cron / enable the queue worker (to make their obligations provable) Điều 32 + infra/extension or master-switch approval Yes
Build the producer so "did it run" / idempotency / S7-evidence obligations can be met Điều 32 + S2 + channel decision + staging Yes

7. What remains unresolved

  • No obligation is met here. This packet states obligations; meeting them is a separate, gated step.
  • The read-only-provable obligations still need an Owner-gated read-only pass (Macro-1 / Option E) to actually verify.
  • WG/OOB obligations cannot be met read-only — the producer firing, the queue draining, the extension installing, and the transient GUC are all post-decision, behind their own gates.
  • No channel selected — this packet states obligations for whichever the Owner chooses; it selects none. CHANNEL_AUTHORITY_DRIFT guarded.
  • Blockers — all OPEN, none resolved: CONS-002, CONS-003, CELL-003/004/007, HOLD-1, HOLD-2, RISK-BYPASS, GOV-016/017, GOV-REUSE-001, Điều 39 runtime-EMPTY, Điều 35 production-readiness FAIL.
  • FUTURE_TECHNICAL_DESIGN_REQUIRED (NOT written here): the exact read-only queries, the install/enable/wiring mechanics, the S7-evidence writer, any command sequence.

8. Ready for GPT/Codex review

Yes — as a design-only proof-obligations packet, not a proof.

Core rule, kept above all detail: every channel must prove (not assert) its liveness/observability/governance/rollback/no-coupling before any build; the two candidates have read-only-provable first obligations, the risky channels need a write first, and all channels share the producer-idempotency + S7-channel-id-evidence obligations. Nothing is proved here; no channel is selected.

Default disposition: HOLD. Engineering PASS = a complete obligation set on paper; it is not an Owner authorization to run a check, install, wire, promote, or build. No PASS authorizes writes. All blockers remain OPEN.

Back to Knowledge Hub knowledge/dev/laws-new/newlaws/consolidation/mega-gate-channel-proof-obligations-2026-06-18.md