From 501b52fd90cd06fa331fb83a6d3c3cbccec74285 Mon Sep 17 00:00:00 2001 From: Cinna Davis <1337isnot1337@users.noreply.github.com> Date: Thu, 22 Oct 2026 10:50:30 -0500 Subject: [PATCH 1/3] Checkpoint changed scalar-graph experiment and unchanged paid profile --- .../scalar-trace-compression/CHECKPOINT.md | 24 ++++++++ research/scalar-trace-compression/explore.py | 61 +++++++++++++++++++ 2 files changed, 85 insertions(+) create mode 100644 research/scalar-trace-compression/CHECKPOINT.md create mode 100644 research/scalar-trace-compression/explore.py diff --git a/research/scalar-trace-compression/CHECKPOINT.md b/research/scalar-trace-compression/CHECKPOINT.md new file mode 100644 index 0000000000..960540415a --- /dev/null +++ b/research/scalar-trace-compression/CHECKPOINT.md @@ -0,0 +1,24 @@ +# Native scalar trace compression checkpoint + +Scientific base: b58ad9ef4d4e861b0eaa5dba41742bdc072dca51, selected +conditional kappa 0.00302015. Prepared for Cinna Davis with substantial +OpenAI Codex assistance; Apache-2.0. + +Question: can a changed scalar graph reduce the complete native paid +moment, rather than repacking the frozen path invoice? + +The initial logical ADD-combination experiment starts with PR4470's exact +`research/joint-helper-lattice/native_joint.py` construction. Both orientations +have 70 combinations, including 28 zero sums. Rebuilding monotone transports +leaves the complete paid profile unchanged: +`{1:2237,2:388,3:494,4:147,5:36,8:8}`. This experiment therefore gives no K gain. +The endpoint and scalar-prefix replay remain pending at this checkpoint. + +Next: test three-gate scalar identities that change the contact graph, bind +any candidate to all 632 arbitrary-input endpoints in both orientations, then +recompute its actual paid moment. Discard candidates failing the physical +common-frame condition or complete paid improvement. A smaller scalar word +alone does not justify a higher-K claim. + +Credit Cinna Davis's PR4441/4447/4470 lineage, zxv, Jacob Alan Sussman, the +retained native/Clifford/geometry authors and their unchanged source notices. diff --git a/research/scalar-trace-compression/explore.py b/research/scalar-trace-compression/explore.py new file mode 100644 index 0000000000..b9e8c27b04 --- /dev/null +++ b/research/scalar-trace-compression/explore.py @@ -0,0 +1,61 @@ +"""Logical ADD merging across exactly commuting instructions; exploratory.""" +from pathlib import Path +import sys,importlib.util,json +from collections import Counter +from fractions import Fraction +ROOT=Path(__file__).resolve().parents[2] +sys.dont_write_bytecode=True +spec=importlib.util.spec_from_file_location('joint_trace_source',ROOT/'research/joint-helper-lattice/native_joint.py');J=importlib.util.module_from_spec(spec);spec.loader.exec_module(J) +c,programs,*_=J.construct() + +def roles(e): + if e[0]=='warp':return {tuple(e[1])} + if e[0]=='scalar': + g=e[1];return {tuple(r) for r in g[1:] if isinstance(r,list) and r and r[0] in ('L','C','W')} + return set() +def add(e):return e[0]=='scalar' and e[1][0]=='add' and all(r[0]=='L' for r in e[1][1:3]) +def commutes(a,b): + if a[0]=='phase' or b[0]=='phase':return False + if b[0] in ('climb','center'):return b[0]=='climb' + if b[0]=='scalar' and b[1][0]=='add': + _,ad,asrc,*_=a[1];_,bd,bsrc,*_=b[1] + return ad!=bsrc and asrc!=bd + return not(roles(a)&roles(b)) +for d,p in programs.items(): + out=[];moves=[] + for i,e in enumerate(p): + if e[0]=='climb':continue + if add(e): + for j in range(len(out)-1,-1,-1): + old=out[j] + if add(old) and old[1][1:3]==e[1][1:3]: + q=Fraction(*old[1][3:5])+Fraction(*e[1][3:5]);moves.append([i,j,str(q)]) + if q:old[1][3:5]=[q.numerator,q.denominator] + else:out.pop(j) + break + if not commutes(e,old):break + else:out.append(e);continue + if moves and moves[-1][0]==i:continue + out.append(e) + print(d,'before',len(p),'after',len(out),'merged',len(moves),'zero',sum(q=='0' for _,_,q in moves),flush=True) + Path('/tmp/scalar-trace-'+d+'.json').write_text(json.dumps(out)) + def synthesize(program): + cur=c['start'][:];out=[] + def climb(r,f): + a=cur[r] + if a==f:return + if not J.F.span(c['frames'][a]) Date: Thu, 22 Oct 2026 11:07:55 -0500 Subject: [PATCH 2/3] Certify 116 native scalar deletions with unchanged Gaussian moment --- .../scalar-trace-compression/CHECKPOINT.md | 10 +- research/scalar-trace-compression/PROOF.md | 78 ++++ research/scalar-trace-compression/README.md | 62 ++++ research/scalar-trace-compression/RESULT.json | 57 +++ .../scalar-trace-compression/SOURCES.json | 336 ++++++++++++++++++ research/scalar-trace-compression/TASK.json | 90 +++++ research/scalar-trace-compression/VERIFY.json | 72 ++++ research/scalar-trace-compression/explore.py | 61 ---- research/scalar-trace-compression/verify.py | 275 ++++++++++++++ 9 files changed, 979 insertions(+), 62 deletions(-) create mode 100644 research/scalar-trace-compression/PROOF.md create mode 100644 research/scalar-trace-compression/README.md create mode 100644 research/scalar-trace-compression/RESULT.json create mode 100644 research/scalar-trace-compression/SOURCES.json create mode 100644 research/scalar-trace-compression/TASK.json create mode 100644 research/scalar-trace-compression/VERIFY.json delete mode 100644 research/scalar-trace-compression/explore.py create mode 100644 research/scalar-trace-compression/verify.py diff --git a/research/scalar-trace-compression/CHECKPOINT.md b/research/scalar-trace-compression/CHECKPOINT.md index 960540415a..0bcdab9bd5 100644 --- a/research/scalar-trace-compression/CHECKPOINT.md +++ b/research/scalar-trace-compression/CHECKPOINT.md @@ -12,7 +12,7 @@ The initial logical ADD-combination experiment starts with PR4470's exact have 70 combinations, including 28 zero sums. Rebuilding monotone transports leaves the complete paid profile unchanged: `{1:2237,2:388,3:494,4:147,5:36,8:8}`. This experiment therefore gives no K gain. -The endpoint and scalar-prefix replay remain pending at this checkpoint. +The endpoint and scalar-prefix replay were pending at that initial checkpoint. Next: test three-gate scalar identities that change the contact graph, bind any candidate to all 632 arbitrary-input endpoints in both orientations, then @@ -22,3 +22,11 @@ alone does not justify a higher-K claim. Credit Cinna Davis's PR4441/4447/4470 lineage, zxv, Jacob Alan Sussman, the retained native/Clifford/geometry authors and their unchanged source notices. + +Final checkpoint: the registered candidate also applies 18 noncommuting triangle +identities per orientation. Two complete native interpreters pass all 632 +columns and physical frames. It removes 116 scalar macros and 914 primitive +allowance units, with the Gaussian profile exactly unchanged. A separate +exploratory rewrite of 526 signed swaps into deferred routes also left the +profile unchanged; that new primitive is not part of the certified program. +RESULT.json and PROOF.md are the final evidence. No higher K was found. diff --git a/research/scalar-trace-compression/PROOF.md b/research/scalar-trace-compression/PROOF.md new file mode 100644 index 0000000000..141cf4c9e7 --- /dev/null +++ b/research/scalar-trace-compression/PROOF.md @@ -0,0 +1,78 @@ +# Exact logical rewrites and their physical execution + +Prepared for Cinna Davis with substantial OpenAI Codex assistance; Apache-2.0. + +## Equal elementary matrices + +An ADD a += alpha*b has matrix I+alpha E_ab. Two ADDs commute if the first +destination is not the second source and the first source is not the second +destination. Repeated ordered pairs combine by adding their coefficients; +a zero sum deletes both instructions. + +The scan records writes to each source, reads of each target and other touching +events. It combines gates only across instructions commuting with the repeated +ADD. Phases and touching warps, scales and non-ADDs are barriers. Transports +preserve logical values and are rebuilt afterwards. Stale history after a +deletion may reject legal combinations but cannot admit an illegal one. +There are 70 combinations, including 28 cancellations: 42+2*28=98 removed +ADDs in each orientation. + +## Noncommuting triangles + +For three distinct roles, execute each line left to right: + +``` +a += alpha*b; b += beta*c; a -= alpha*b + = b += beta*c; a -= alpha*beta*c. + +a += alpha*b; c += beta*a; a -= alpha*b + = c += beta*a; c += alpha*beta*b. +``` + +In the first identity the net changes are -alpha*beta*c on a and beta*c on b. +The second restores a and adds beta*a+alpha*beta*b to c, using original input +values. Both hold for arbitrary rational coefficients and independent inputs. +No zero helper, Gaussian commutation or order-two complex phase is assumed. + +Intervening instructions must touch none of the three roles. Their order is +preserved; modified regions cannot be reused. Lookahead is bounded at 180 +instructions, with no optimality claim. There are 18 accepted triangles per +orientation: four of the first kind and fourteen of the second forward, with +counts reversed backward. Each removes one ADD, giving 116 removed macros. + +## Physical execution and complete accounting + +A field at frame f stores C_f times its logical value. A transport changes +this reference while preserving that value; an ADD requires exactly common +physical operand frames, under the retained native contract. + +A triangle's first contact space must lie in the middle space, which must lie +in the last. Both replacement ADDs use the middle frame. Every transport is +rebuilt from its actual preceding reference; a non-nested or empty paid edge +is rejected. All warps, center episodes, residual adapters and terminal frames +are retained. Logical equality alone is not the physical certificate. + +Both retained native interpreters execute the actual candidate on all 632 +arbitrary persistent columns. Owned C0 is arbitrary before its permitted clear +and clears at return. Exact rational rows retain free noncommuting warp words +and the correct dual signs. The interpreters agree on every endpoint, physical +frame, paid rank and scalar invoice. A wrong paid rank is rejected. Separate +dense rational multiplication checks the triangle and rejects a wrong sign; +source-byte changes fail authentication before imports. + +The candidate Gaussian edge set is contained in the source edge set. Their +operators, absolute phases and all-width interpretation reuse existing source +recipes; no new lowering is claimed. Helper boundaries are unchanged. Formal +prefix maxima remain 457 forward and 169 backward, below the retained envelope. +The source primitive lowerer, including coefficient preparation, gives exactly +914 fewer real allowance units in each orientation. + +## Why K is unchanged + +For every real C the recursive moment depends on the target profile T and +paid profile P through sums of r^(1-C). Both profiles are exactly unchanged. +Substituting into an unchanged complete controller therefore gives the old +moment function at every C, not just at sampled exponents. Fixed scalar work +can affect constants; it does not establish a new exponent saving here. +This is a constructive local simplification, not a global lower bound on +changed scalar circuits, native words or integer multiplication. diff --git a/research/scalar-trace-compression/README.md b/research/scalar-trace-compression/README.md new file mode 100644 index 0000000000..c85993d704 --- /dev/null +++ b/research/scalar-trace-compression/README.md @@ -0,0 +1,62 @@ +# A changed native scalar graph, with an unchanged recursive moment + +**Constructive scalar saving; no higher K.** Exact commuting ADD combinations +and three-gate triangle identities remove **116 scalar macros and 914 real +primitive allowance units per native invocation**, in each orientation of the +selected PR4470 word. All 632 persistent inputs remain arbitrary. + +| Orientation | Real primitive allowance before | After | Saving | +| --- | ---: | ---: | ---: | +| Forward | 158120 | 157206 | 914 | +| Inverse transpose | 158168 | 157254 | 914 | + +The complete Gaussian paid profile remains +`{1:2237,2:388,3:494,4:147,5:36,8:8}`. All 408 helper boundaries and every +main boundary remain those of PR4470. The recursive moment and selected +conditional K=0.00302015 therefore do not improve. These are fixed scalar +circuit savings, not measured runtime gains or a new bottleneck breakthrough. + +This addresses PR4470's changed-scalar-order next question: a real dependency +rewrite is possible, but these rewrites do not remove a binding Gaussian +contact. Other scalar circuits are not excluded. The deferred signed-route +experiment also preserved the paid profile; CHECKPOINT.md labels its limits. + +## Reproduce + +```sh +python3.12 -B scripts/research_package.py --package research/scalar-trace-compression +``` + +The registered standard-library replay authenticates 53 live input files, +reconstructs both words, and uses two retained exact interpreters on all 632 +arbitrary-input columns in both orientations. It checks every common frame, +paid rank, free warp word and owned center return. Every surviving Gaussian +edge has an existing source phase recipe; no new edge needs lowering. The +formal prefix bounds remain 457 forward and 169 backward. + +RESULT.json binds the algorithmically generated program's deterministic hash. +Normal replay compares that receipt without writing; `verify.py --write` is +an authoring command. PROOF.md gives the identities and execution conditions. + +## Scope and credit + +This author-checked local result does not install the changed circuit into +the selected supplier or rerun the selected cold replay, compiler or outer +transfer. Its unchanged paid moment provides no higher K. Retained native, +all-column, ownership, phase, precision, tape, analytic and recovery hypotheses +remain source assumptions. No independent human or formal-kernel review is +claimed. + +Credit Cinna Davis's PR4441/4447/4470 native and controller lineage, zxv, +Jacob Alan Sussman and the retained scalar, Clifford, geometry, precision and +outer contributors. The construction and two interpreters are reused with +credit, not newly independently implemented here. Prepared for Cinna Davis +with substantial OpenAI Codex assistance; Apache-2.0. + +## Open next questions + +Find a changed scalar circuit avoiding a genuinely binding Gaussian contact. +Start with a role whose next larger frame is forced by one ADD, replace that +dependency by an exact costed circuit, then replay every endpoint and reprice +both orientations. The current rewrite supplies no such paid-profile change. +New center recipes and changed warp words remain separate routes. diff --git a/research/scalar-trace-compression/RESULT.json b/research/scalar-trace-compression/RESULT.json new file mode 100644 index 0000000000..7608d6f078 --- /dev/null +++ b/research/scalar-trace-compression/RESULT.json @@ -0,0 +1,57 @@ +{ + "directions": { + "backward": { + "all_632_columns_two_interpreters": true, + "cancelled_pairs": 28, + "combined_pairs": 70, + "new_physical_transport_edges": 0, + "owned_center_cleared": true, + "paid": { + "1": 2237, + "2": 388, + "3": 494, + "4": 147, + "5": 36, + "8": 8 + }, + "prefix_l1": "169", + "primitive_allowance_after": 157254, + "primitive_allowance_before": 158168, + "program_sha256": "ee2de4b1130594985b1a46772f83ccc6244d92aed829082a182f3a2918490935", + "removed_scalar_macros": 116, + "second_scalar_allowance": 157254, + "triangles": { + "source_update": 14, + "target_update": 4 + } + }, + "forward": { + "all_632_columns_two_interpreters": true, + "cancelled_pairs": 28, + "combined_pairs": 70, + "new_physical_transport_edges": 0, + "owned_center_cleared": true, + "paid": { + "1": 2237, + "2": 388, + "3": 494, + "4": 147, + "5": 36, + "8": 8 + }, + "prefix_l1": "457", + "primitive_allowance_after": 157206, + "primitive_allowance_before": 158120, + "program_sha256": "dbc4309e24089fb38e1844bfac5f25f320aadf0588831107ee3d43e76b4bafa2", + "removed_scalar_macros": 116, + "second_scalar_allowance": 157206, + "triangles": { + "source_update": 4, + "target_update": 14 + } + } + }, + "new_kappa": null, + "paid_moment_changed": false, + "status": "PASS_CHANGED_NATIVE_SCALAR_GRAPH" +} diff --git a/research/scalar-trace-compression/SOURCES.json b/research/scalar-trace-compression/SOURCES.json new file mode 100644 index 0000000000..2ff4ee8e01 --- /dev/null +++ b/research/scalar-trace-compression/SOURCES.json @@ -0,0 +1,336 @@ +{ + "schema_version": 1, + "base_commit": "b58ad9ef4d4e861b0eaa5dba41742bdc072dca51", + "files": [ + { + "path": "certificates/selected-result.json", + "usage": "provenance", + "git_blob": "c35482cd9035843b15a634cc8276a7e1e40e8395", + "sha256": "6fe0a099b89aa2aed796a13c3a21dafc63f3388ebf397464e44e0451893b9375" + }, + { + "path": "docs/research/agent-task-catalog.json", + "usage": "provenance", + "git_blob": "f126dd2e2dad2b669e75d1d0d0bd05c600725602", + "sha256": "f7a48bfa2659b88378282a8eee7d9fe52cdf505594124c4d1686b58510fffd72" + }, + { + "path": "research/fresh-helper-boundary/ARITHMETIC-RESULT.json", + "usage": "input", + "git_blob": "686c36fb19680db327f797ebdfe612487d8c53f8", + "sha256": "5d25fec9ac4b036c93846a50dccfa4af030e2982f5cec02e28702193bf157cf7" + }, + { + "path": "research/fresh-helper-boundary/CHANGES.json", + "usage": "input", + "git_blob": "45744fedd0e28967aa72586048b8bc0c72f419a9", + "sha256": "cde73b8ff5b3c0d06e69e2293b991b24fd14a16dd4ccab7ff6b3439074a94624" + }, + { + "path": "research/fresh-helper-boundary/NATIVE-RESULT.json.gz", + "usage": "input", + "git_blob": "e6fdb31624e4eb8c7c770bb4422cd07ea99ab152", + "sha256": "37d0848458b289eb50271c47adef6e74014ae30be6363d09394b2337b566b839" + }, + { + "path": "research/fresh-helper-boundary/RESULT.json", + "usage": "input", + "git_blob": "e26608e20be115d28f8853a8c1a12bebfc8e8ec3", + "sha256": "34163eeeef1cd712de457d7fd3b0435f98a12ac456b82256b078f33225456fbd" + }, + { + "path": "research/fresh-helper-boundary/SOURCES.json", + "usage": "input", + "git_blob": "0b40275502f4263a19905f4fb50e346a3629c712", + "sha256": "01998e9b86222d10811fc0114dcd5c946ff9e95025a7cacd00e67a3eefe543d0" + }, + { + "path": "research/fresh-helper-boundary/arithmetic.py", + "usage": "input", + "git_blob": "4822f04ae09d84a16e8fa8656a533e23fd4068f0", + "sha256": "212bae96d0ddcbc25076afe2589a47736c66b77420057f28c44c937ad087fc07" + }, + { + "path": "research/fresh-helper-boundary/native.py", + "usage": "input", + "git_blob": "1b36f6cb5f205c33bf48811e0b1b3621c55e8154", + "sha256": "9b55a2d3c3972148fae9d112e745d9244968166bd89bd900c938f429fc76ab29" + }, + { + "path": "research/fresh-helper-boundary/verify.py", + "usage": "input", + "git_blob": "e434dbf7c68afa0390a307fd15f32348b0e87207", + "sha256": "4c18851214400cf955e10565d89357029d9e765140233831472ce23f0c3ee7bf" + }, + { + "path": "research/fresh-helper-thinned/PROOF.md", + "usage": "input", + "git_blob": "bf68dc2b987cb7de6431ff5e3514b60af48720a5", + "sha256": "9883b3329fef7624d3471e27bb55258cd9dc18bb6d37779a3939de99add87347" + }, + { + "path": "research/fresh-helper-thinned/README.md", + "usage": "input", + "git_blob": "344616d6654a96085dd45cf2c3189ef283deeac1", + "sha256": "70c1c872c2327c3f71918e218d5f1ecb7a00037771a5dd1b8ae415b84cc90dc2" + }, + { + "path": "research/fresh-helper-thinned/RESULT.json", + "usage": "input", + "git_blob": "e223acd07a6b1f4f1c9f2778b8ea64d4b7a2be55", + "sha256": "8e7db2fed5f4be6a7f944bc59e7942ccbcc3e6c36130b5671331540c183ada21" + }, + { + "path": "research/fresh-helper-thinned/SOURCES.json", + "usage": "input", + "git_blob": "4089ad37114540b23846596e2a641c4a4bd608e2", + "sha256": "5aec5df5096ee8a3e90618d311640b4bdfba42be5bc4bc5fab55e8be858ab2cb" + }, + { + "path": "research/fresh-helper-thinned/verify.py", + "usage": "input", + "git_blob": "9ba85a59aa5dcc5cdaec85ee18607cb050530c55", + "sha256": "c841265ccee9b6f79045ad818ce9d27cfd7ee1f60047525a75d491f0dd8b997a" + }, + { + "path": "research/higher-moment-strictification/README.md", + "usage": "input", + "git_blob": "0a736ca89e1eafb73a30e1f2589cc45e6b5f76c3", + "sha256": "ebe80b68ff026ce90f71f274c31744f4c0b36132d15ebb7e39cf2d5df4df270d" + }, + { + "path": "research/higher-moment-strictification/verify.py", + "usage": "input", + "git_blob": "4b24a5096154736ce060474eb8c72dc64c303699", + "sha256": "0ce7e7137422d5ffeda22085c81fa88471bbe963100fdad62e659f1e3bf89326" + }, + { + "path": "research/joint-helper-lattice/PATCH.json", + "usage": "input", + "git_blob": "51304a6601061ed4e698f910b09135ef109555e3", + "sha256": "296d0e8c58cc70febe042c681ef30d6bb469818c0835fbcaac8aa8d330f5b727" + }, + { + "path": "research/joint-helper-lattice/native_joint.py", + "usage": "input", + "git_blob": "0315f80e2fdef5e0eef13e3e9b8f72066238164d", + "sha256": "50869b1bcad7493e6b4cb2a4cd5d2fd9a193a5921100483fa2c3f2c999ddfd46" + }, + { + "path": "research/kappa-0023-productive-jobs/dependencies/kappa-next-regime/bit-compression/carrier-reuse/reference/joint_pair_dag.py", + "usage": "input", + "git_blob": "8b40135a84e7f0f0cd44bed69655801310b916a7", + "sha256": "8a0de761642d21919e969475c3f13e5d01a4bae7343c1e1f37c586d94b676a85" + }, + { + "path": "research/kappa-0023-productive-jobs/dependencies/kappa-next-regime/direct-decoder/sources/DATA-PHASES.json", + "usage": "input", + "git_blob": "d9a4f84211182ca200c081ea061d724c8a2cfb70", + "sha256": "c5916ff312678f12aba403847643fbbc29f643acec60bdf836fa56cd3e8251fa" + }, + { + "path": "research/kappa-causal-continuation/buffer-borrowing/verify_buffers.py", + "usage": "input", + "git_blob": "5a55034ec9e6185d981e16c28e1e2e455069e2cb", + "sha256": "106b4d5e052427230df452f0c901d5390a0583782960b80a8af94d9a984022c7" + }, + { + "path": "research/kappa-function-composition/complex/prune_native.py", + "usage": "input", + "git_blob": "8c3e11b2408fa96eefa3ebe7952d1b11b90b772b", + "sha256": "f2b37c183a10922eabc8e0436b426a08866430e96bd0adc7e178951c7fbb5257" + }, + { + "path": "research/kappa-rebuild/architecture/mixed_target_probe.py", + "usage": "input", + "git_blob": "4fc05ab08138218ba9f09e5c89b649afae7c914e", + "sha256": "011c3c9d0cf81103dc84d709a0e36793eb7c5ae3f23c85eac27650ef13afa04a" + }, + { + "path": "research/kappa-rebuild/bit/BIT-ALLSIZE-PARAMETERS.json", + "usage": "input", + "git_blob": "fbe6da7241357d89cf5c55b2e7ce2d0d046be32a", + "sha256": "edb273f59a27356ad89f38791590c3c806b228c3510eb508e01e89f2caba95ef" + }, + { + "path": "research/kappa-rebuild/bit/BIT-P3-NATIVE-BINDING.json", + "usage": "input", + "git_blob": "e8c5e4f077fea0bef355e6c3013c7f252d3606cf", + "sha256": "9ece46fdfda6182e757e9a3b1f513fb3d029d730f3bafdcd6ed59180a14175b0" + }, + { + "path": "research/kappa-rebuild/bit/DELAYED-COVER-BRIDGE.md", + "usage": "input", + "git_blob": "a58774e237c9362869a60a22bda35be09fb85872", + "sha256": "9731b93026717f5fa15851e3633cbb4bdc76eba2bffb9d6b4a3b69f7dd502443" + }, + { + "path": "research/kappa-rebuild/bit/MIXED-PRODUCTIVE-BIT.json", + "usage": "input", + "git_blob": "6a139eedbc1015c13df6f2a4333e1a89b5edd18d", + "sha256": "2f69a19f417c0e0d141c180f9b2fae3d358391b9a230f5848ee07c45450e70bf" + }, + { + "path": "research/kappa-rebuild/bit/bit_native_binding.py", + "usage": "input", + "git_blob": "f4c4082d89969ea311219d9af8013082d599f6f1", + "sha256": "bf6374225f388e7531fa6475cc255bd430100ff62c38d582c41601f0739de7b7" + }, + { + "path": "research/kappa-rebuild/bit/complex_controller_factor.py", + "usage": "input", + "git_blob": "cb0cff7c8be5f38f2ee52201d9d0907f9dfd7947", + "sha256": "1de9aaf918e6a4f2f5448754c1f3c3da3b85e6257849ebd097af09859c4e5497" + }, + { + "path": "research/kappa-rebuild/bit/mixed_productive_bit.py", + "usage": "input", + "git_blob": "9c7a8bd5d3ae4c19952648c815031858d6627b96", + "sha256": "b32291b0db7fc0d332ec444c70746ab0fb03351d2e50546f8bcb64060e3ff95e" + }, + { + "path": "research/kappa-rebuild/complex/FULL-IDENTITY.md", + "usage": "input", + "git_blob": "f97a23d7d21bd7f79c9d0cb14d8c6b44fddd3f23", + "sha256": "c4aa88c4943ef041e9542c519b7600ecf26ed6caff92558fdb07ac88ace64c17" + }, + { + "path": "research/kappa-rebuild/complex/full-identity-certificates/RESULT.json", + "usage": "input", + "git_blob": "c6edcbdc43bf36bb11201235027d0ec170d07fc8", + "sha256": "943d5fad2fc529f470df05a35446e07ecaef7344abfce450d2c2eb2c9b3798f6" + }, + { + "path": "research/kappa-rebuild/complex/full-identity-certificates/THREE-base-FULL-IDENTITY-CANONICAL.json.gz", + "usage": "input", + "git_blob": "4a8c4ed26e53a72362d571c972e65aff546be784", + "sha256": "6418ec3da24d548a57f5c3fe5b9062c26c9478e638504a61c387f5cfb5f4ed61" + }, + { + "path": "research/kappa-rebuild/complex/full-identity-certificates/THREE-base-FULL-IDENTITY-NATIVE.json.gz", + "usage": "input", + "git_blob": "b46d44c6ee624968dd57be928b0c15d9d45f3b2c", + "sha256": "c54b0a3e129d28e6dbf74fa731fc3bb70fe3c6705f07256750fbecddcc842d39" + }, + { + "path": "research/kappa-rebuild/complex/native_extensions.py", + "usage": "input", + "git_blob": "7f84894efc309546a903d314c7ac1473e7f594a8", + "sha256": "50ad007d9c386393657e86c99a96ae0a63a8fbc52872579b185002cc626e88e3" + }, + { + "path": "research/kappa-rebuild/complex/power_two_balance.py", + "usage": "input", + "git_blob": "a55ae0ce78a1861965f899a82604b276260f636c", + "sha256": "76929bb3887911ccf100c4593574b8a1c82ee64e96f939a8aca196869438b424" + }, + { + "path": "research/kappa-rebuild/complex/rebuild_native.py", + "usage": "input", + "git_blob": "78a7b1b0e6e43a1347fb361f45c6e0eaff8dd27b", + "sha256": "f94c527cc02215de49350d477618188c4c0da48bc8fb05b4e37b24c482cad7d5" + }, + { + "path": "research/kappa-rebuild/transfer-audit/p3_native_audit.py", + "usage": "input", + "git_blob": "0f3a4067a4b4e20d0e6ca0f84f41851c5168f76d", + "sha256": "5504a55a50546418d10c522984438cdeedb44993f7c1dab7bd4aa1ae0515d902" + }, + { + "path": "research/missing-join-frame/NATIVE.json.gz", + "usage": "input", + "git_blob": "2f41b11d02726a60da449aaa6c603716c0310ead", + "sha256": "96718b257db24f4f62d3b86b36cdd514e67d2cb99947ddd7bdcb9b55a2c17841" + }, + { + "path": "research/missing-join-frame/PATCH.json", + "usage": "input", + "git_blob": "f96d295d40014d4dd503f58eb3cdabcbb4b8e101", + "sha256": "9ab5328245ff02c9d0be21d39bcc375f50bc5d7909e9f7b9a3a9a6f812f5bd6e" + }, + { + "path": "research/missing-join-frame/PROOF.md", + "usage": "input", + "git_blob": "d240cd8e14e6d30e0e2c3d0ddcc7efa68349e24e", + "sha256": "50061c25d379ff5733135dbed53e8721bbd4dbee6766d1609d8a2ecdebb7dc06" + }, + { + "path": "research/missing-join-frame/RESULT.json", + "usage": "input", + "git_blob": "e653fb4358ded67ff1539151f4b670ad9a242fb1", + "sha256": "25f2cbcde988847ff86f44e804982069863ec99ff68097f16e9bb7a1a17c4cd0" + }, + { + "path": "research/missing-join-frame/verify.py", + "usage": "input", + "git_blob": "188135f81c9937af8232a06dc1e7b8b28260e6a8", + "sha256": "21429dd9c1b9c93ebb57e5fbb8ef674d0e4146ac8c25cc7c097c3352c02366a4" + }, + { + "path": "research/pr4359-p7-padding/P7-FACTOR.json", + "usage": "input", + "git_blob": "04c7ef620e760cc8f1764bbf0ccd7f32c6a5bd86", + "sha256": "6f96f6be5d8441f71cbe6ebb1657c69b543eb085b848b92b591b7ac01d6e6598" + }, + { + "path": "research/pr4359-p7-padding/TENSOR.md", + "usage": "input", + "git_blob": "8ecfd3e4d0bcb449ecb1e150c4f1f4fbb39ca656", + "sha256": "b2eba86cb979b4dc2a045f2e74bbd29e4d9e5ec87d6a2bc23ba7b54f1f58e3e3" + }, + { + "path": "research/pr4359-p7-padding/dependencies/compiler-refill/endpoint.py", + "usage": "input", + "git_blob": "340e1f0ffb8a1a9c38fbbd9119580b6d23e01b59", + "sha256": "d097e55f06c3f244f2074ffd7c1a0a5f3c4b4b6a6accf9619d1dde5c0ae85e15" + }, + { + "path": "research/pr4359-p7-padding/native_inventory.py", + "usage": "input", + "git_blob": "8d2d96e3998254c2333c43fe47cdfd074cbd811e", + "sha256": "65539acaf45bdfe8c5aee6830f9c9b3d1107c442a60842ef803fdd7688de8f32" + }, + { + "path": "research/query-thinned-controllers/BIT-CONTROLLER.json", + "usage": "input", + "git_blob": "89c400d5970024b3debe870c36ce43889beed001", + "sha256": "39ac84fb848b908f7ba051fae4556d507900c421dc5d23501a9c0cb1d61fd08d" + }, + { + "path": "research/query-thinned-controllers/COMPLEX-CONTROLLER.json", + "usage": "input", + "git_blob": "39318f6ad9baf0838a274ca1042b1e3ba0e74bf9", + "sha256": "bf1143325d8380fab40cd5a85449f9a5412f0340deba7f4693714c92ae320088" + }, + { + "path": "research/query-thinned-controllers/RESULT.json", + "usage": "input", + "git_blob": "e0695152c98d727edfd0d2034b58a1c7e8682c0c", + "sha256": "6ebfc8c0f09166f4834e9d7427410cb31aefff2cd4d4ce588c8e52c9c70e9a0f" + }, + { + "path": "research/query-thinned-controllers/SOURCES.json", + "usage": "input", + "git_blob": "0f061c87ff87c43ff1ea0fc418582e9ccea3bc1d", + "sha256": "74b73563d9f78a4562d376b6f33528d652e41097f65747667f112a3e1fa81d29" + }, + { + "path": "research/query-thinned-controllers/controller.py", + "usage": "input", + "git_blob": "d4557e08cfb9fe57cc1ae4024705a72dc95f3583", + "sha256": "8b462d660487b1be4940357c4c7522967b1bfaede3c02b1c66109b85acae0fd2" + }, + { + "path": "research/query-thinned-controllers/verify.py", + "usage": "input", + "git_blob": "f1114036fff66f57014e5c1256141fb78ff4c4a9", + "sha256": "07dea601d6bbaa4d90e576f20c8607c37fb01e8778c798d919fa9df435049950" + }, + { + "path": "research/t74-native-fast/vendor/native/new/code/borrow/vendor/clifford/clifford_exact.py", + "usage": "input", + "git_blob": "166841a037f069249f6f7f6dedb89248812f59e2", + "sha256": "2982ead07721e83358dc67c6f49c2b4c16a236a6bebdfd72f58221be1f5d0962" + } + ] +} diff --git a/research/scalar-trace-compression/TASK.json b/research/scalar-trace-compression/TASK.json new file mode 100644 index 0000000000..ff68d8637e --- /dev/null +++ b/research/scalar-trace-compression/TASK.json @@ -0,0 +1,90 @@ +{ + "schema_version": 1, + "task_id": "joint-query-controller", + "priority_revision": 7, + "base_commit": "b58ad9ef4d4e861b0eaa5dba41742bdc072dca51", + "original_card": { + "id": "joint-query-controller", + "question": "Can the installed QQ16 caller win a complete matched protocol bill, or can a changed demand eliminate actual paid work?", + "starting_points": [ + "docs/research/research-family-status.md", + "certificates/selected-result.json", + "research/qq16-caller-install/README.md" + ], + "methods": [ + "Derive the matched whole-caller physical bill for installed and baseline protocols.", + "Change the actual demanded observations and prove a cheaper legal producer/consumer contract." + ], + "acceptance_gate": "Name the changed premise of the fixed F0/B1 observation obstruction. Show exactly which query is recovered, legal native reads and restoration, and a full favorable budget including cover maps, helpers and endpoints. Local inverse identities alone do not close the global controller. A scoped local result may be retained without a complete supplier. Expanding it into further construction rounds requires the family-level budget and obligation gate in research-family-status.md; an optimistic passing relaxation alone is not acceptance.", + "first_step": { + "command": [ + "python3", + "-B", + "scripts/research_baseline.py" + ], + "expected": "PASS_RESEARCH_BASELINE_BINDINGS_ONLY", + "inspect": "Read #4166 COST.md and ADMISSION.json. An actual caller connection is now proposed. Its native-component profile loses; parent park/restore versus external-call costs remain unresolved. Retain the producer and recovery lineage rather than rebuild it.", + "scope": "Source-binding orientation only; no scientific replay, theorem acceptance or supplier admission. Budget any heavy replay separately." + }, + "first_experiment": "At the actual installed cut, compare matched complete parent park/restore and external input/return protocols at the same bank/packet geometry, including every later root call and service cost. Alternatively pin both bridge observations and derive a genuinely smaller source-compatible demand. Stop if the complete necessary inequality fails or an essential cost is unknown; no larger decoder scan from a local tape-action saving.", + "bottleneck_link": "The native local words exist; retained query information and its physical access are the missing link to a composed recursive interface.", + "allowed_variations": [ + "One paid query, one changed first pair, or one precisely specified affine helper state.", + "A counterexample or lower bound for that exact proposed repair.", + "One unresolved obligation of a newer local decoder, with exact source heads and a distinct claim/domain." + ], + "scope_change_triggers": [ + "Retaining the fixed first pair and ordinary schedule while allowing only homogeneous selected-only control, already excluded by the witness.", + "Treating cover-map counts as zero-cost physical address operations.", + "Recreating the pending complete local decoder or early-record/output-bank coalescing already under investigation without a distinct audit or changed premise.", + "Treating a completed-output defect inequality as a producer-interior, dirty-range or physical-cost certificate.", + "Recreating completed-output recovery or caller wiring already supplied by #4166 without new independent coverage.", + "Dropping retained later root calls or claiming native-profile dominance from the isolated publication saving." + ], + "overlap_terms": [ + "QQ16", + "joint-query", + "changing-chart controller", + "selected observation", + "1969", + "2540", + "early record", + "output-bank retention", + "complete native decoder", + "2965", + "producer defect", + "dirty-helper range", + "F17 consumer", + "4166", + "qq16-caller-install" + ], + "existing_checks": [ + { + "scope": "PR #4166: author-checked installed producer/service/return/bridge connection; native-component comparison loses.", + "evidence": "research/qq16-caller-install/README.md", + "remaining": "Complete matched physical protocol bill, or changed source-compatible demand/circuit; no affordable supplier yet.", + "status": "author-checked", + "source_commit": "0b082d22a0e9a442d264ab0633e35ef26c790630", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + } + ] + }, + "scope_status": "changed", + "actual_scope": "Compress the selected native scalar dependency graph using exact commuting and triangle identities; replay every endpoint and complete paid profile.", + "scope_change_reason": "The user requested a major K increase and a bottleneck change; the selected package explicitly leaves changed scalar ordering open. This tests that route rather than the historical QQ16 caller.", + "bottleneck_link": "Determine whether reducing the scalar graph removes paid Gaussian contacts; distinguish fixed scalar savings from exponent-saving moments.", + "budget_minutes": 60, + "stop_rule": "Stop this family if both orientations preserve the paid profile; do not infer an exponent gain from a shorter scalar word.", + "outcome": "completed", + "evidence": "PROOF.md; RESULT.json; two retained exact native interpreters", + "author": "Cinna Davis, with substantial OpenAI Codex assistance", + "ai_assistance": "Substantial OpenAI Codex assistance for mathematical reasoning, code and verification; no independent human review.", + "open_questions": [ + { + "question": "Can a scalar resynthesis remove a genuinely binding Gaussian contact?", + "why_it_matters": "The tested circuit simplifications reduce fixed scalar work but leave the recursive moment unchanged.", + "first_step": "Select a paid contact with a unique incident role and supply an exact changed linear circuit avoiding that contact.", + "blocked_by": "No new circuit changing the complete paid profile has yet passed all-column replay." + } + ] +} diff --git a/research/scalar-trace-compression/VERIFY.json b/research/scalar-trace-compression/VERIFY.json new file mode 100644 index 0000000000..f5110e7d3a --- /dev/null +++ b/research/scalar-trace-compression/VERIFY.json @@ -0,0 +1,72 @@ +{ + "schema_version": 1, + "status": "ready", + "python": "3.12", + "requirements": [], + "inputs": [ + "research/fresh-helper-boundary/ARITHMETIC-RESULT.json", + "research/fresh-helper-boundary/CHANGES.json", + "research/fresh-helper-boundary/NATIVE-RESULT.json.gz", + "research/fresh-helper-boundary/RESULT.json", + "research/fresh-helper-boundary/SOURCES.json", + "research/fresh-helper-boundary/arithmetic.py", + "research/fresh-helper-boundary/native.py", + "research/fresh-helper-boundary/verify.py", + "research/fresh-helper-thinned/PROOF.md", + "research/fresh-helper-thinned/README.md", + "research/fresh-helper-thinned/RESULT.json", + "research/fresh-helper-thinned/SOURCES.json", + "research/fresh-helper-thinned/verify.py", + "research/higher-moment-strictification/README.md", + "research/higher-moment-strictification/verify.py", + "research/joint-helper-lattice/PATCH.json", + "research/joint-helper-lattice/native_joint.py", + "research/kappa-0023-productive-jobs/dependencies/kappa-next-regime/bit-compression/carrier-reuse/reference/joint_pair_dag.py", + "research/kappa-0023-productive-jobs/dependencies/kappa-next-regime/direct-decoder/sources/DATA-PHASES.json", + "research/kappa-causal-continuation/buffer-borrowing/verify_buffers.py", + "research/kappa-function-composition/complex/prune_native.py", + "research/kappa-rebuild/architecture/mixed_target_probe.py", + "research/kappa-rebuild/bit/BIT-ALLSIZE-PARAMETERS.json", + "research/kappa-rebuild/bit/BIT-P3-NATIVE-BINDING.json", + "research/kappa-rebuild/bit/DELAYED-COVER-BRIDGE.md", + "research/kappa-rebuild/bit/MIXED-PRODUCTIVE-BIT.json", + "research/kappa-rebuild/bit/bit_native_binding.py", + "research/kappa-rebuild/bit/complex_controller_factor.py", + "research/kappa-rebuild/bit/mixed_productive_bit.py", + "research/kappa-rebuild/complex/FULL-IDENTITY.md", + "research/kappa-rebuild/complex/full-identity-certificates/RESULT.json", + "research/kappa-rebuild/complex/full-identity-certificates/THREE-base-FULL-IDENTITY-CANONICAL.json.gz", + "research/kappa-rebuild/complex/full-identity-certificates/THREE-base-FULL-IDENTITY-NATIVE.json.gz", + "research/kappa-rebuild/complex/native_extensions.py", + "research/kappa-rebuild/complex/power_two_balance.py", + "research/kappa-rebuild/complex/rebuild_native.py", + "research/kappa-rebuild/transfer-audit/p3_native_audit.py", + "research/missing-join-frame/NATIVE.json.gz", + "research/missing-join-frame/PATCH.json", + "research/missing-join-frame/PROOF.md", + "research/missing-join-frame/RESULT.json", + "research/missing-join-frame/verify.py", + "research/pr4359-p7-padding/P7-FACTOR.json", + "research/pr4359-p7-padding/TENSOR.md", + "research/pr4359-p7-padding/dependencies/compiler-refill/endpoint.py", + "research/pr4359-p7-padding/native_inventory.py", + "research/query-thinned-controllers/BIT-CONTROLLER.json", + "research/query-thinned-controllers/COMPLEX-CONTROLLER.json", + "research/query-thinned-controllers/RESULT.json", + "research/query-thinned-controllers/SOURCES.json", + "research/query-thinned-controllers/controller.py", + "research/query-thinned-controllers/verify.py", + "research/t74-native-fast/vendor/native/new/code/borrow/vendor/clifford/clifford_exact.py" + ], + "commands": [ + { + "argv": [ + "{python}", + "-B", + "{package}/verify.py" + ], + "timeout_seconds": 300, + "checks": "Two exact all-632-column interpreters, physical common frames, complete paid and scalar invoices, prefix bound, phase-edge reuse and failure controls." + } + ] +} diff --git a/research/scalar-trace-compression/explore.py b/research/scalar-trace-compression/explore.py deleted file mode 100644 index b9e8c27b04..0000000000 --- a/research/scalar-trace-compression/explore.py +++ /dev/null @@ -1,61 +0,0 @@ -"""Logical ADD merging across exactly commuting instructions; exploratory.""" -from pathlib import Path -import sys,importlib.util,json -from collections import Counter -from fractions import Fraction -ROOT=Path(__file__).resolve().parents[2] -sys.dont_write_bytecode=True -spec=importlib.util.spec_from_file_location('joint_trace_source',ROOT/'research/joint-helper-lattice/native_joint.py');J=importlib.util.module_from_spec(spec);spec.loader.exec_module(J) -c,programs,*_=J.construct() - -def roles(e): - if e[0]=='warp':return {tuple(e[1])} - if e[0]=='scalar': - g=e[1];return {tuple(r) for r in g[1:] if isinstance(r,list) and r and r[0] in ('L','C','W')} - return set() -def add(e):return e[0]=='scalar' and e[1][0]=='add' and all(r[0]=='L' for r in e[1][1:3]) -def commutes(a,b): - if a[0]=='phase' or b[0]=='phase':return False - if b[0] in ('climb','center'):return b[0]=='climb' - if b[0]=='scalar' and b[1][0]=='add': - _,ad,asrc,*_=a[1];_,bd,bsrc,*_=b[1] - return ad!=bsrc and asrc!=bd - return not(roles(a)&roles(b)) -for d,p in programs.items(): - out=[];moves=[] - for i,e in enumerate(p): - if e[0]=='climb':continue - if add(e): - for j in range(len(out)-1,-1,-1): - old=out[j] - if add(old) and old[1][1:3]==e[1][1:3]: - q=Fraction(*old[1][3:5])+Fraction(*e[1][3:5]);moves.append([i,j,str(q)]) - if q:old[1][3:5]=[q.numerator,q.denominator] - else:out.pop(j) - break - if not commutes(e,old):break - else:out.append(e);continue - if moves and moves[-1][0]==i:continue - out.append(e) - print(d,'before',len(p),'after',len(out),'merged',len(moves),'zero',sum(q=='0' for _,_,q in moves),flush=True) - Path('/tmp/scalar-trace-'+d+'.json').write_text(json.dumps(out)) - def synthesize(program): - cur=c['start'][:];out=[] - def climb(r,f): - a=cur[r] - if a==f:return - if not J.F.span(c['frames'][a]) barrier: + old = out[prior] + value = Q(*old[1][3:5]) + Q(*event[1][3:5]) + merged += 1 + if value: + out[prior] = add(a, b, value, old[2]) + else: + out[prior] = None + previous.pop((a, b)) + cancelled += 1 + continue + previous[a, b] = index + if event[0] == 'scalar' and event[1][0] == 'add': + a, b = map(tuple, event[1][1:3]) + writes[a], reads[b] = index, index + else: + for role in roles(event): + barriers[role] = index + if event[0] == 'phase': + phase = index + out.append(deepcopy(event)) + return [event for event in out if event is not None], (merged, cancelled) + + +def triangles(program, spaces): + """A B A^-1 shortcuts, requiring all moved-across roles to be disjoint.""" + deleted, replacements, counts = set(), {}, Counter() + for i, first in enumerate(program): + if i in deleted or i in replacements or not is_add(first): + continue + a, b = map(tuple, first[1][1:3]) + alpha = Q(*first[1][3:5]) + j = None + for pos in range(i+1, min(i+180, len(program))): + event = program[pos] + if pos in deleted or pos in replacements or event[0] == 'phase': + break + if roles(event) & {a, b}: + j = pos + break + if j is None or not is_add(program[j]): + continue + middle = program[j] + x, y = map(tuple, middle[1][1:3]) + union = {a, b, x, y} + if len(union) != 3: + continue + k = None + for pos in range(j+1, min(j+180, len(program))): + event = program[pos] + if pos in deleted or pos in replacements or event[0] == 'phase': + break + if roles(event) & union: + k = pos + break + if k is None or not is_add(program[k]): + continue + last = program[k] + if last[1][1:3] != first[1][1:3] or Q(*last[1][3:5]) != -alpha: + continue + if any(roles(event) & union for event in program[i+1:j]): + continue + frame = middle[2] + if not spaces[first[2]] <= spaces[frame] <= spaces[last[2]]: + continue + beta = Q(*middle[1][3:5]) + if x == b and y not in {a, b}: + replacement = [middle, add(a, y, -alpha*beta, frame)] + kind = 'source_update' + elif y == a and x not in {a, b}: + replacement = [add(x, a, beta, frame), add(x, b, alpha*beta, frame)] + kind = 'target_update' + else: + continue + deleted.update((i, j, k)) + replacements[j] = replacement + counts[kind] += 1 + result = [] + for index, event in enumerate(program): + if index in replacements: + result.extend(replacements[index]) + elif index not in deleted: + result.append(event) + return result, dict(sorted(counts.items())) + + +def synthesize(canonical, program, spaces): + current, result = canonical['start'][:], [] + + def climb(role, frame): + old = current[role] + if old == frame: + return + need(spaces[old] < spaces[frame], 'Strict positive nested transport') + result.append(['climb', 'trace', role, old, frame, + len(canonical['frames'][frame])-len(canonical['frames'][old])]) + current[role] = frame + + for event in program: + if event[0] == 'scalar': + for role in sorted(roles(event)): + if role[0] == 'L': + climb(role[1], event[2]) + elif event[0] == 'warp': + climb(event[1][1], event[3]) + current[event[1][1]] = event[4] + result.append(deepcopy(event)) + for role, frame in enumerate(canonical['final']): + climb(role, frame) + return result + + +def paid(program): + return Counter(event[5] if event[0] == 'climb' else event[4] + for event in program if event[0] in ('climb', 'center')) + + +def controls(): + # Three genuinely noncommuting operations cannot be merged as equal ADDs. + gates = [add(('L', 0), ('L', 1), Q(1), 0), + add(('L', 1), ('L', 2), Q(1), 0), + add(('L', 0), ('L', 1), Q(-1), 0)] + need(combine(gates)[1] == (0, 0), 'A changed source blocks commutation') + reduced, count = triangles(gates, [frozenset({0})]) + need(count == {'source_update': 1} and len(reduced) == 2, + 'Noncommutation is repaired by the actual compensating ADD') + # Dense exact arithmetic, separate from the native sparse/free-word engines. + def matrix(program): + rows = [[Q(i == j) for j in range(3)] for i in range(3)] + for event in program: + _, dst, src, numerator, denominator = event[1] + rows[dst[1]] = [a+Q(numerator, denominator)*b + for a, b in zip(rows[dst[1]], rows[src[1]])] + return rows + need(matrix(gates) == matrix(reduced), 'Exact dense triangle identity') + wrong = deepcopy(reduced) + wrong[-1][1][3] *= -1 + need(matrix(gates) != matrix(wrong), 'A wrong correction sign is detected') + dependent = [gates[0], add(('L', 2), ('L', 0), Q(1), 0), gates[2]] + need(combine(dependent)[1] == (0, 0), 'A reader of the target blocks commutation') + + +def run(): + for row in json.loads((HERE/'SOURCES.json').read_text())['files']: + if row['usage'] == 'input': + need(sha256((ROOT/row['path']).read_bytes()).hexdigest() == row['sha256'], + 'Changed authenticated input: '+row['path']) + controls() + joint = load(ROOT/'research/joint-helper-lattice/native_joint.py', 'trace_joint_source') + c, original, *_ = joint.construct() + spaces = [joint.F.span(basis) for basis in c['frames']] + v = joint.F.load(ROOT/'research/kappa-causal-continuation/buffer-borrowing/verify_buffers.py', + 'trace_free_rows') + x = joint.F.load(ROOT/'research/kappa-rebuild/complex/native_extensions.py', 'trace_literal') + result = {'status': 'PASS_CHANGED_NATIVE_SCALAR_GRAPH', 'directions': {}, + 'new_kappa': None, 'paid_moment_changed': False} + for direction, source in original.items(): + combined, merge_counts = combine(source) + simplified, triangle_counts = triangles(combined, spaces) + candidate = synthesize(c, simplified, spaces) + need(paid(candidate) == paid(source), 'The complete paid profile is unchanged') + original_edges = {(e[3], e[4]) for e in source if e[0] == 'climb'} + new_edges = {(e[3], e[4]) for e in candidate if e[0] == 'climb'} + need(new_edges <= original_edges, 'Every physical transport retains its old exact phase recipe') + backward = direction == 'backward' + rows, receipt = x.literal_replay(v, c, candidate, backward) + for role in range(632): + need(rows['L', role] == v.expected(('L', role), [], backward, False), + 'Every arbitrary-input endpoint, including free warp words') + rebound = deepcopy(c) + rebound['local_profile'] = dict(paid(candidate)) + second = v.replay(candidate, rebound, [], backward, False) + _, baseline = x.literal_replay(v, c, source, backward) + need(Q(receipt['max_formal_prefix_l1']) < 2**192, 'Retained scalar-prefix envelope') + wrong = deepcopy(candidate) + next(e for e in wrong if e[0] == 'climb')[5] += 1 + try: + v.replay(wrong, rebound, [], backward, False) + except ValueError: + pass + else: + raise ValueError('An under/overcharged transport was accepted') + scalar_count = lambda p: sum(e[0] == 'scalar' for e in p) + result['directions'][direction] = { + 'combined_pairs': merge_counts[0], 'cancelled_pairs': merge_counts[1], + 'triangles': triangle_counts, 'removed_scalar_macros': scalar_count(source)-scalar_count(candidate), + 'primitive_allowance_before': baseline['real_scalar_allowance'], + 'primitive_allowance_after': receipt['real_scalar_allowance'], + 'paid': {str(rank): count for rank, count in sorted(paid(candidate).items())}, + 'all_632_columns_two_interpreters': True, + 'new_physical_transport_edges': len(new_edges-original_edges), + 'owned_center_cleared': receipt['arbitrary_owned_C0_cleared'], + 'prefix_l1': receipt['max_formal_prefix_l1'], + 'second_scalar_allowance': second['conservative_real_scalar_primitive_allowance'], + 'program_sha256': sha256(json.dumps(candidate, sort_keys=True).encode()).hexdigest()} + print('PASS_TRACE_NATIVE', direction, flush=True) + return result + + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument('--write', action='store_true') + args = parser.parse_args() + receipt = run() + path = HERE/'RESULT.json' + if args.write: + path.write_text(json.dumps(receipt, indent=2, sort_keys=True)+'\n') + else: + need(receipt == json.loads(path.read_text()), 'Deterministic receipt') + print('PASS_CHANGED_NATIVE_SCALAR_GRAPH no_new_kappa') From 19df2116bf72e047ee3ebf509c162fed82c0872e Mon Sep 17 00:00:00 2001 From: Cinna Davis <1337isnot1337@users.noreply.github.com> Date: Thu, 22 Oct 2026 11:08:46 -0500 Subject: [PATCH 3/3] Record registered and Git-free native circuit validation --- .../scalar-trace-compression/VALIDATION.md | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 research/scalar-trace-compression/VALIDATION.md diff --git a/research/scalar-trace-compression/VALIDATION.md b/research/scalar-trace-compression/VALIDATION.md new file mode 100644 index 0000000000..febecdfbc1 --- /dev/null +++ b/research/scalar-trace-compression/VALIDATION.md @@ -0,0 +1,25 @@ +# Executed validation + +Linux x86_64, CPython 3.12.15. Scientific commit: +`5bad501f85c453dc84bdd79affcf39de17f6150b`. + +- Registered replay and metadata/source pins: PASS. +- Direct isolated optimized (`-I -O -B`) replay: PASS. +- Committed-byte and source-history preflight: PASS, 61 files; the scientific + base b58ad9ef4d4e861b0eaa5dba41742bdc072dca51 is an ancestor. +- Committed package export and archive integrity: PASS, 61 files. +- Fresh extracted export, outside Git, `PATH=/nonexistent`, isolated optimized + CPython 3.12.15: PASS in both orientations. +- Whitespace check: PASS. + +Two retained interpreters agree on all 632 arbitrary input columns in each +orientation, paid profiles and scalar allowance. Registered replay includes +commutation, correction-sign and actual wrong-paid-rank controls. It does not +run a new compiler/outer/selected cold replay or independently re-prove the +retained all-column/physical native theorem. No independent human acceptance +is claimed. The complete moment is unchanged, so no new K is claimed. + +Initial authoring attempts caught and corrected an integer-key versus JSON +string-key receipt comparison. The final normal registered replay, rather than +only receipt generation, passes. The first export launch named a nonexistent +system Python path; the successful run used the resolved CPython path.