Skip to main content

Recoverable PROGRAM authority: implementation design for independent review

2026-10-26. Design only, against /workspace/VRDex db9abbcd59a30d206d85c0dcb2f407150e31dd9e. Read the fixed-R85 recovery assessment first. No source edits, network, AWS, builds, tests, adoption, or A were performed. Conditional PROGRAM/native132 and capacity remain OPEN. This report requires independent peer review before implementation; it is neither adoption nor external launch approval.

Decision and scope​

Recommend one explicit authority rebaseline: four complete, reviewed, Git-retained new originals (design, G0–G12 guards, native-pins obligations, superseding amendment), one exact effective contract, structural required-original membership, and migration of every producer/consumer/fixture. Preserve the genuine R94 original unchanged as historical evidence and the result-sizing authority, subject to the narrowly enumerated superseding amendment. Do not reconstruct or claim equivalence to the unavailable R85 bodies. The three missing hashes remain historical facts in the new amendment, not operative required originals.

The alternatives are: (1) retain the old contract, which cannot qualify without its genuinely unavailable originals; (2) reconstruct a complete 343-MB evidence population, which cannot recover unknown authority prose and is unnecessary for this repair; (3) merely replace constants, which violates R94 retention clauses and leaves generic-audit substitution possible; (4) the bounded rebaseline above, the smallest working option. No product choice is needed.

Exact originals and contract​

Create these four small UTF-8/LF originals under docs/engineering/authority/, committed before any reset-dependent continuation:

Contract keyExact audit IDNew complete original
designprogram-source-design-rebaseline-v1program-source-design-rebaseline-v1.md
guardsprogram-source-guards-rebaseline-v1program-source-guards-rebaseline-v1.md
pinsprogram-native-pins-rebaseline-v1program-native-pins-rebaseline-v1.md
authorityRebaselineprogram-authority-rebaseline-v1program-authority-rebaseline-v1.md
resultSizingprogram-result-sizing-r94-v1Existing tests/fixtures/program-result-sizing-r94-v1.txt, unchanged

The existing R94 reference is exactly {kind:'audit', id:'program-result-sizing-r94-v1', bytes:41830, sha256:'0a7214700021178996f717487ce09b513fa8ebfcb70dca6a2bed863abb7a5c3c'}. For each new original freeze the complete body first, then compute its actual byte length and SHA-256. No invented hashes, zero hashes, estimated lengths, self-hashes, private-only fixed IDs or temporary paths enter the implementation. This report deliberately does not assign hashes to unwritten bodies. The writer must deliver the literal five-row identity/length/hash table for exact-body peer disposition before activation.

Retain the existing contract DATA module and export name. Its final exact object has only design, guards, pins, resultSizing, authorityRebaseline, each holding the corresponding frozen whole-body hash. Add a deeply immutable ordered PROGRAM_AUTHORITY_REFS DATA table in that same module containing the five full refs and their contract keys; freeze every entry and the containing table; do not create a runtime file reader or generator in the DATA leaf. Runtime contract equality rejects missing/extra keys, old three/four-field objects, mixed generations and wrong values. Never support both old and new contracts via fallback. A source test independently hashes the actual Git-tracked original bodies, rather than deriving expected identities only from the exported constants, and proves all five table entries and contract values agree; an edited body requires a fresh review and contract identity.

The complete new bodies must actually specify their obligations, not say “as in missing R85.” The design states the trust boundary, conditional assurance, full front-door dependency graph, exact unchanged workload selection, all bounds and runtime/Root accounting, source/image/native joins, clock/marker/media proof and cleanup. The guards body supplies G0–G12 rows with each premise, original operands, actual enforcing function(s), rejection conditions and independently reviewed source basis. Preserve dependency/cross-binding, native identity/observation, exact argv/defaults, initialized negotiation, construction/feed conservation, raw units, complete coded inventory, demux/probe population, timestamp replay, fixed filter graph, terminal/drain exclusions, stdout/file lineage, and complete ledger/replay accounting. The implementer resolves each row against current source rather than guessing historical G labels. The pins body specifies critical/platform partitions, ELF/aliases/links/mapping/kernel/environment, source/build/provider provenance and full observed-body obligations. None can be replaced by a digest list or a generic “approved” sentence.

The superseding amendment explicitly replaces R94 lines 74–84 and its later preservation/retention requirements only insofar as they require the unavailable R85 design/guards/native-pins originals or their fixed identities, and insofar as they require unavailable historical review originals as current eligibility premises. It records those missing obligations honestly; it does not declare them fulfilled. New complete design/guards/pins, exact-body review/dispositions, adoption, and implementation/semantic reviews supply the current closure instead. Preserve R94 unchanged, including its original status language; later genuine adoption is separate evidence. Retain the entire existing result policy and every other substantive bound. Record the old three hashes verbatim from the recovery assessment, state “historically unavailable; equivalence not established,” identify the exact replacement IDs, and give the new amendment precedence for this finite authority/retention delta only. Do not silently cancel other historical obligations: enumerate any newly discovered missing normative original for peer disposition before claiming a complete closure.

Required membership and finite code changes​

  1. event-marker-program-contract.mjs: freeze the new five-field DATA object and five exact full refs. Add no new packaged file; keep the 134-entry packaging manifest unchanged.
  2. event-marker-program-guards.mjs: replace the R94-only identity loop with a shared structural full-reference check. G0 and G12 must each contain all five full refs among their auditRef/sourceRefs; every G1–G11 description additionally contains the full new guards reference, retaining its specific semantic-review/source operands. Exact kind/ID/bytes/hash is necessary; reject any range property on a mandatory original, including null/empty/full-length ranges. Range citations may supplement separate full refs. Preserve the R94 error/negative coverage where useful, not its obsolete base-value expectation.
  3. event-marker-authority-closure.mjs: expose one mandatory-audit membership checker and call it from requireAuthorityMembership; require all five exact refs in K audits, no duplicates/conflicts/ranged substitutes. Use one full-ref comparison rule and reject duplicates/conflicts before expensive reads. Existing required refs still join. Do not erase reference multiplicity from accounting when deduplicating catalog membership.
  4. event-marker-native-controller.mjs: apply that checker in makeNativeCandidate, makeNativeIntent (also covering both launch producers), and outer replay. The existing exact contract checks remain. Outer replay must reopen/hash each entire source/audit body and match real A's complete K audit set. Constructor stamping alone must not make old/mixed caller data eligible.
  5. event-marker-native-bundle.mjs: use the same membership path; resolve and verify complete fixed authority originals from their checked-in paths during preparation, separately from packaged sourceFiles (whose path whitelist need not expand). Preserve explicit runtime-input materialization, exact source closure and pending state. Validate every fixed original before any output write; a missing or mismatched body must leave both runtime and K outputs unwritten. Supply these audit originals to Root's bounded resolver; do not package them or convert them into runtime code assets.
  6. Migrate tests/fixtures/marker-positive-program.mjs to load all five genuine fixed bodies and include complete refs in proofs/K and originals in the simulated resolver. Its other effects and A remain explicitly simulated; the one-byte S audit cannot stand in for fixed authority. Migrate every actual makeNativeCandidate caller and test helper found by an exhaustive symbol search, including CI and ECS launch/replay fixtures. Update the two literal-contract tests (event-marker-data-separation.test.mjs, event-marker-program-result-sizing.test.mjs) and authority/membership/materializer tests. Preserve R93's historical expected operand object as a historical assertion, and independently assert the explicitly adopted new contract; do not present amended values as proof that R93 itself preserved them.
  7. Update source-marker-qualification.md with historical R85/R94 versus the adopted successor and required-original recovery paths. Add a small source test inventory for the new originals; source/audit review bodies and actual adoption disposition must also be durable Git artifacts outside packaged runtime. Commit review/adoption evidence after its subjects are frozen, without changing those subjects. These genuine exact-body dispositions, adoption and implementation/semantic originals must be required premises through the existing proof/catalog/K closure and real A's matching audit set; durable files or optional attachments alone do not satisfy this obligation. Use their actual complete IDs/lengths/hashes in the existing appropriate audit/source refs and require Root to inspect this complete substantive closure before A. The five fixed refs do not themselves attest later dispositions. Keep each disposition outside the body it reviews and candidate-specific image reviews outside packaged runtime.

No changes to media algorithms, evidence-policy constants, commands, native132 inventory, workload plans, packaging count, clocks, marker interpretation, reader caps, cancellation, cleanup or role classification are authorized by this design. Review an explicit diff inventory before accepting implementation.

Existing image/audit joins and preparation order​

Choose the existing complete audit/K/A plus I/image joins for this bounded repair. Add no mandatory native-image schema, reserved audit role, provenance parser or stage/finalize lifecycle. The checked-in pins body specifies the substantive native/source/build/provider provenance and review obligations using existing catalog/reference structures; it must never contain a future candidate image digest. Keep runtime native object hashes and source/build premises independent of the final image. Candidate-specific actual-image/source/native audit originals and their real semantic reviews are required review premises in the existing external K audit catalog, with full-body reopen/hash and A's exact audit-set match. They document actual image/config/layers, object inventory/ELF/aliases, provider/source originals, Node/FFmpeg identity, source/wheel correspondence and measurement evidence. Root must substantively review their correspondence to the exact candidate and actual image before A. This is not a claim that the current code parses or mechanically verifies a new provenance-document schema.

Reuse the existing materializer: it validates supplied runtime/source/audit inputs and emits runtime files plus a pending K; it need not require a future final image. Reuse workers/restream/install_twitch.py's existing manifest-listed runtime input and hash checks independently of the 134 package entries. Build and observe the runtime-bearing image, obtain the actual image/source/native review, and create the candidate K containing the complete required audit closure through existing interfaces. Earlier K output remains pending and cannot supply final approval. When adding final image-specific audits, keep runtime/source originals byte-identical; if any runtime/source bytes change, rebuild/reobserve and recreate K before A. No final image/K/A/intent hash enters packaged runtime, and K stays outside the runtime tree.

The private external builder currently admits exactly 139 source paths. If runtime injection is needed, a finite additional channel into the existing installer can be designed and reviewed separately during later preparation; it is not a new public protocol or part of this recovery source change. Keep the 134 package entries and 139 builder source entries unchanged, count manifest-listed runtime files separately, and validate their actual image bytes through existing mechanisms. Do not package authority/review bodies or infer conditional-image support from the ordinary builder. This design authorizes no adapter implementation.

Invariants and meaningful verification​

Preserve all existing bounds, including: runtime originals/bootstrap 196608; profile/manifest 65536; runtime/native/closure catalog ceilings 256; context 4096; legacy numeric 196608 normal/262144 final, selected R83 1572864 normal/1638400 final, reserve 65536; selected R94 result 262144, other outer 196608, combined reservation 458752; unchanged A 196608; aggregate 16/32/64 MiB by invocation class. No renewed allowance per child/scene, discounted DATA, forgotten repeated logical charge, incomplete original, or audit-only treatment for runtime-loaded data. Recompute actual new contract/ref bytes and Root storage/read costs. Hard-cap failures remain failures.

Preserve 8-MiB CI auxiliary archive/1-MiB parser, existing Docker-save 2-GiB streaming/1-MiB parser and all member/metadata bounds, 256-KiB shard decompression, all native/source/media-specific caps, Root 134152192 payload +65536 terminal =128 MiB/257 objects, two full reads, 384-MiB local high-water, 512-MiB free-before/128-MiB free-during. Preserve original bytes/SHA/EOF/identity checks and bounded read-before-copy/parse ordering. Preserve 20-second scene, 90-second ordinary, 360-second compressed, 400+20 group work/closure, 160+20 upload/terminal, 600 process, 660 RUNNING +120 PENDING limits, at most two media children, isolated ownership, TERM/KILL, two empty censuses, actual STOPPED/exit, inactive task definition and absent ENI. All unlisted metadata/runtime/deadline/accounting/native/source/marker/media/cleanup bounds remain exactly at baseline; an explicit source diff plus existing suites must establish this, not this abbreviated list alone. Scope verification must establish unchanged 79996 IDs, 83 groups, 294 invocations, native132 identities, 134 packaged source entries and 139 builder source entries; manifest-listed runtime files are counted separately.

Required negatives: remove/mutate each of five refs independently at proof G0/G12, K, resolver and A; wrong ID/kind/length/hash; ranged substitute; optional-K-only attachment; generic S replacement; absent/altered Git body; old/mixed/missing/extra contract; conflicting duplicates; late-body changes despite unchanged refs; stale A; missing mandatory review/adoption/semantic refs or originals in the existing closure; future-image dependencies in packaged runtime. Check containing-table and per-entry immutability, independently hash every actual tracked authority body, and verify that missing/mismatched fixed originals cause zero output writes. Candidate-specific actual-image/source/native correspondence remains a substantive review obligation alongside the existing mechanical K/A/I/image joins; no new provenance-schema test is introduced. Exercise materializer, acquisition, CI/ECS preparation and independent outer replay, not only helper unit tests. Keep full-result/other-outer/combined, declared-small returned-oversized, accounting multiplicity and boundary-adjacent cap negatives intact. Source-only tests establish machinery, never real approval or media capacity.

Review, adoption and paid continuation​

Order: independent review of this design → write/freeze complete four new originals and literal identity table → independent exact-body dispositions → genuine Root authority adoption under existing authorization → implement/migrate → full exact-source/semantic review → existing runtime materialization/installation → rebuilt actual image, measured provenance and source/native review → K with the complete required audit closure → real external prelaunch A for exact K/environment → I/C/Q and actual observed L → independent retrieval/replay. Store the new fixed bodies, reviews and adoption in Git so another reset can recover them. Store dynamically observed actual-image/provider originals durably with their exact refs under the existing retention policy; do not turn a seven-day private object into a permanent fixed authority dependency. No manufactured review/adoption/A, and no inference of A from user authorization or a passing test.

Root reports baseline image 9ff288…, ordinary 42 Python +90 Node passes and 134-source/1854-wheel-file correspondence, with encoded image/provider originals privately retained seven days. Those results are useful baseline evidence, not qualification of changed packaged source. Rebuild/retest ordinary132 and the changed authority/source suites, remeasure all 134 packaged files, the builder's complete declared 139-source closure and wheel contents, verify injected runtime originals in the actual final image, and prepare/review actual conditional dependencies; no whole-image reconstruction is required just to design this repair.

Only after those gates, continue within the existing remaining $20 ceiling: retain the prior $1 ancillary reserve and treat approximately $1.53346 compute as an estimate, not admission or authority to spend the balance. Refresh actual spend/reservations before launch. Perform the bounded unchanged PROGRAM/conditional evidence step only as its exact A permits; it does not qualify native132, four paired captures or capacity. Execute canary-000 first under existing pins, collect all four frozen paired captures and native terminal/cleanup/two-read originals, and release bulk only after the existing complete canary acceptance. No retries, automatic promotion or expanded workload. Stop on evidence, deadline, cleanup or budget failure; keep affected IDs OPEN. The rebaseline removes unavailable fixed-authority dependencies; actual fit, native premises and capacity still require observed evidence.