Skip to content

Implement canonical switch queries in linear tape transitions - #7735

Open
aliromman wants to merge 1 commit into
CrocSwap:mainfrom
aliromman:codex/consecutive-result-062
Open

aliromman wants to merge 1 commit into
CrocSwap:mainfrom
aliromman:codex/consecutive-result-062

Conversation

@aliromman

@aliromman aliromman commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

A fixed 3,237-location, fourteen-tape program computes the exact canonical padded-rotation switch in at most 1024(h+4) literal transitions, including validation, preparation, output, clearing and every head return. It preserves the five borrowed descriptors, returns one owned Boolean, retires eight private bodies/guards and adds at most 16(h+4) historical cells. This lowers the published quadratic service bound in PR #7593 to linear work on the same ABI. No new kappa or complete CRT caller improvement is claimed.

Read the proof and cost table, fixed graph emitter, receipt, separate sparse interpreter, verifier, source pins and credits.

The graph lowers PR #7734's closed descent. Canonical shrinking counters make zero detection constant and countdowns linear in total. A two-carry scan consumes the low d bits once, then writes both high quotients once. It uses no host-integer instruction, variable-distance move, array lookup, callback or child recursion. Exact input-bit sensitivity makes the standalone linear order sharp; this is not a lower bound for queries with precomputed advice.

T <= 548(h+1)+719 <= 1024(h+4)
K_after <= K_entry+16(h+4)
Evidence Coverage
Two instruction interpreters All 1,566 entries in 49 complete networks through height 3
Historical current-wire row All 544 queries at h=5, s=17, j=6
Wider owned returns 42 queries through height 4096
Complete return state Every input, private cell, guard, output, head, visited span and transition count
Controls 13 invalid domains per interpreter, 3 wrong-semantic graphs, 1 failed-retirement graph, 2 alias rejections

On the same 544 supplied fixtures, a fresh replay of the retained graph uses 1,473,152 transitions; the new graph uses 1,341,888, with a maximum of 2,545 per query. Both counts include service setup and cleanup. Host fixture serialization, actual offsets, transport, payload use and output retirement are excluded from both. These exact service counts are not wall-clock timings, an uninterrupted caller, or a comparison with ROM reuse.

Python 3.12, standard library only:

python3.12 -B scripts/research_package.py --package research/linear-tape-rotation-switch

Both registered commands print:

PASS_LINEAR_TAPE_ROTATION_SWITCH 14 tapes; 1024*(h+4) transitions

Normal and optimized replay, committed bytes/source history/modes, export and sealed read-only Git-free serial replay pass. Hosted CI did not certify this package. The plan job failed in the shared test_current_ci_section_matches_selected_record: the base guide names frontier6030 while the selected record requires make frontier7000-verify. The log reports 760 tests, one failure and 24 skipped; package replay was skipped. This package changes no shared CI file. Local replay remains the scientific evidence. The all-height claim follows from the written carry/counter/ownership invariants and source-loop counts, not fixture timing.

Jerry Chen supplied the ABI and prior proof, builder, primary hardware and cleanup. Those retained modules are called unchanged; new initialization adapts the source. Ali Romman supplied the closed formula. Nick Petalas supplied the endpoint/child formulas in PR #7504. Cinna Davis supplied the canonical compiler in PR #4100. Their notices and predecessor credit remain intact.

The ABI supplies serialized inputs, disjoint blank windows and unique left framing. It does not promise recovery from aliasing, guard corruption or unterminated streams. Actual CRT source/offset production, descriptor conversion, current-wire payload updates, transport, output retirement and complete repeated-query pricing remain open. Historical full suites, selected cold replay, Lean and Docker were not run. All five framework assumptions and the selected frontier remain unchanged.

Base: canonical main e54523517d0f03e58352e647c403a5af3e525a57, priority revision 8. Consumed heads: PR7593 56335a406469fad85e88ff72820d506d8bea6f63, PR7734 57bb6efed1be1dda9eb1a0f622ec2773bc8b0047, and canonical compiler 337d04939571a637aeab54a0f58f54fde811663a. All eleven retained files have exact byte pins. No unmerged source ancestry is asserted. Prepared by Ali Romman with substantial OpenAI Codex assistance in research, implementation, verification and writing. Separate interpretation shares the emitted graph and ABI; no independent human or formal-kernel acceptance is claimed. Apache-2.0. Canonical claim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant