diff --git a/docs/ci-verification.md b/docs/ci-verification.md index 63ba3e9aa8..52b62d0481 100644 --- a/docs/ci-verification.md +++ b/docs/ci-verification.md @@ -1,8 +1,25 @@ # CI verification -## Current selected-family replay: #6030 +## Current selected-family replay: #7000 with #7001 The [selected record](../certificates/selected-result.json) binds conditional +κ = 0.00363005817 to the [application review](research/pr-intake-evidence/pr7000-application/PROOF-REVIEW.md), +[validation receipts](research/pr-intake-evidence/pr7000-application/VALIDATION.json), +and [explicit source closure](../certificates/frontier7000-source.json). +`make frontier7000-verify` follows that exact-source selected replay. The review +reuses eleven authenticated preceding executions and records seven fresh serial +application, scalar and complete native-catalogue executions. The earlier +monolithic timeout is retained separately and is not completed coverage. +Consult the receipts for exact commands, source heads and limits. + +The five inherited framework assumptions remain. No complete uniform word, +literal multiplier execution, independent human proof or formal-kernel proof +is asserted. Routine research submissions do not need to rerun this +selected-family replay. The sections below preserve historical checkpoints. + +## Historical selected-family replay: #6030 + +The [historical checkpoint](../certificates/checkpoints/frontier6030.json) binds conditional κ = 0.003125804 to the [proof review](research/pr-intake-evidence/pr6030-audit/PROOF-REVIEW.md), [validation receipts](research/pr-intake-evidence/pr6030-audit/VALIDATION.json), and [explicit source closure](../certificates/frontier6030-source.json). diff --git a/research/historical-selected-replay-gap/README.md b/research/historical-selected-replay-gap/README.md index 55d8cc3b49..36d9a873ca 100644 --- a/research/historical-selected-replay-gap/README.md +++ b/research/historical-selected-replay-gap/README.md @@ -69,7 +69,11 @@ python3 -B scripts/research_package.py --package research/historical-selected-re The direct command prints `PASS_HISTORICAL_SELECTED_REPLAY_GAP`. A registered replay prints `PASS_REGISTERED_RESEARCH_PACKAGE`. Both require Git history -containing the two inspected commits. +containing the two inspected commits and the source and manifest objects at +`2485805a6d47f36ea83ddde6327d453ac82d44dc`. The verifier uses a temporary +sparse checkout of that commit, checks the declared source digests there, and +uses its planner and manifest inventory. The recorded rejections and selection +therefore remain reproducible after later changes to the live Makefile or CI guide. ## Open next questions diff --git a/research/historical-selected-replay-gap/SOURCES.json b/research/historical-selected-replay-gap/SOURCES.json index c1010eec95..62bb8b3950 100644 --- a/research/historical-selected-replay-gap/SOURCES.json +++ b/research/historical-selected-replay-gap/SOURCES.json @@ -4,13 +4,13 @@ "files": [ { "path": "Makefile", - "usage": "input", + "usage": "provenance", "git_blob": "0d683a06b9e7ee162496108ce9a7c5d2ee94fccf", "sha256": "4f2d4f2dcd15139ec82658a975f85ed300897385f85799218539f4c8d60567da" }, { "path": "certificates/partial-swap-network.json", - "usage": "input", + "usage": "provenance", "git_blob": "eccafa830c16170c36faf93045ddf1f638f7bcd4", "sha256": "4c0b9d37e1034b2076e30a70f8e514416298c462d9ee98bc87fe6556b14df786" }, @@ -22,7 +22,7 @@ }, { "path": "docs/ci-verification.md", - "usage": "input", + "usage": "provenance", "git_blob": "63ba3e9aa8bdc5e942b56e34244b92b16f854085", "sha256": "c7d3027e9ad8bcbff68f07aa9576b30fb2f3c76c44d876d40c7fdbf4a3e2228a" }, @@ -34,163 +34,163 @@ }, { "path": "research/clifford-state-performance/SOURCE.json", - "usage": "input", + "usage": "provenance", "git_blob": "6f98a0061a5104dfab82c9e806f819b41811f684", "sha256": "396d0f08df24952248140d5c65c51b8c902ef1c580892ff7ea182890530f67ee" }, { "path": "research/community-batch1047-audit/CONTENT-COVERAGE.json", - "usage": "input", + "usage": "provenance", "git_blob": "5e0f92af463ec12c5e1dcc3effd44081a88af647", "sha256": "07a9daeaf2bda308a92e9a4684f13d5fc766c7772d74801fceb7f4599fdab226" }, { "path": "research/community-batch1099-audit/CONTENT-COVERAGE.json", - "usage": "input", + "usage": "provenance", "git_blob": "9e13266bf85e627f1b7dc225e9530ea69fd2c7f0", "sha256": "421e1211fb1897c45621dc6801c276e53f2e6f335583c9c9049e535f87c0a3b1" }, { "path": "research/community-batch932-audit/CONTENT-COVERAGE.json", - "usage": "input", + "usage": "provenance", "git_blob": "cc4d03eb59b9ab3f952735f7e88ff18c2d15d7af", "sha256": "184629cac91a5cfaca50330a88596008b824221433867dcf8117539c913c284a" }, { "path": "research/community-batch970-audit/CONTENT-COVERAGE.json", - "usage": "input", + "usage": "provenance", "git_blob": "8b9f4111badf7de5d97684799560b55110e9da79", "sha256": "23188ed920e38a54006cb883e181585620821c63bf7e8b5e05d32719417cc37e" }, { "path": "research/community-frontier741-audit/CONTENT-COVERAGE.json", - "usage": "input", + "usage": "provenance", "git_blob": "a5300d4e7a5381a3f443fc54c768ca6f0f236d68", "sha256": "3c820fb30e1b4d9bcfc6a7ab524375e5b2abd66b940af2c509146104f0bcd79c" }, { "path": "research/community-frontier890-audit/CONTENT-COVERAGE.json", - "usage": "input", + "usage": "provenance", "git_blob": "d7ff6d777b01d69b6ce84caf25d3b7e4a4d2f211", "sha256": "6b185a9902652f893f3ebd8ada92d2f11b6de6533a9a4d11718a8a4496101128" }, { "path": "research/community-hyperplane599-audit/SOURCE.json", - "usage": "input", + "usage": "provenance", "git_blob": "546f37d326d10a99910ae8f908e71ef768524d98", "sha256": "65099d764bfcc39bda5e4d9966783611b094c3522dbdd1435cd498d657a8ef8e" }, { "path": "research/community-k492-audit/SOURCE.json", - "usage": "input", + "usage": "provenance", "git_blob": "e538481e4cb16ed936d3195f2dfb5b5a9ca0a76b", "sha256": "2c0f4fa5bc150d05658af2e7c54c4d2c337dd52b7efd3d69530ae73bcbdf452a" }, { "path": "research/community-reconciliation92-audit/MANIFEST.json", - "usage": "input", + "usage": "provenance", "git_blob": "2a2e93685173d5f13cbb5abe740f5d90352e0228", "sha256": "5f501f3c118131e7d069f30ad77186eb2ad6961f9680a0ef105f4514ed41808a" }, { "path": "research/partial-swap-digest/baseline.py", - "usage": "input", + "usage": "provenance", "git_blob": "a2f0190704db83bd8ef48e46e723c49b925804fe", "sha256": "81e9af92cdf38243a540cdcff2062778e449467848d444da37a9553c12ca4c34" }, { "path": "research/r420-two-sided-basis/SOURCES.json", - "usage": "input", + "usage": "provenance", "git_blob": "5d718e11e62f4bcadecf1e02d6b61f87dbe190b0", "sha256": "d9810b0d139c5a1211fd2c1f0d142187cc1fca30026e1e7bc4f9ecfacf1596d1" }, { "path": "research/skip-clones/SOURCE.json", - "usage": "input", + "usage": "provenance", "git_blob": "8d1bb3b9c8189e35e5d8bfdfa632d7473e8be0d5", "sha256": "0b68e63e35a97ce6b0cdb6e291b88ebaa8f2dd4afb70b2498f10ee89428258dc" }, { "path": "research/split-skip/SOURCE.json", - "usage": "input", + "usage": "provenance", "git_blob": "2ab610b6ea2edd2865fda793ef2168b0c76afb4f", "sha256": "7c2b4646a3ecfef6f881da5c43e4bd0fa9a4d1b00548b8ab458d897e16735134" }, { "path": "scripts/historical-ci-inputs/Makefile", - "usage": "input", + "usage": "provenance", "git_blob": "aff68409021c9d401a6f8013b9dfd7dbcc30f2a8", "sha256": "ea8830dd79da493e2d75baf753d733ff7efbcf2b4794afe41fae0ac8f3055646" }, { "path": "scripts/historical-ci-inputs/ledger-batch932-run_isolated_tests.py", - "usage": "input", + "usage": "provenance", "git_blob": "65db599ab0b1dea0312c4ca048e0bd0f44c3736f", "sha256": "96ea543e6c707424afe247e77bd86c82152f90fc76a0773c4232145da5cdf8d1" }, { "path": "scripts/historical-ci-inputs/ledger-batch932-test_isolated_test_runner.py", - "usage": "input", + "usage": "provenance", "git_blob": "34820a8f24678f918f4d0e7a35380d8013fc3495", "sha256": "628391b6abfbc8674ceec1751867a4392f2cc0b5b66886243e139af86cf355ac" }, { "path": "scripts/historical-ci-inputs/ledger-batch970-verify_selected_result.py", - "usage": "input", + "usage": "provenance", "git_blob": "c755b76e0d44ba4917aa94440ebe54daefce5b2a", "sha256": "d7fd929726b326aeeaf0a3996475adec88eee9aac09ae0bebeeaa0bc1fc8f199" }, { "path": "scripts/historical-ci-inputs/ledger-frontier741-ci-verification.md", - "usage": "input", + "usage": "provenance", "git_blob": "7f3c012504187917a728b9fe87043f0fc8cd006a", "sha256": "a854022e0e1d5d4db4d60e586be3ea56005013ef14a1fc06d02bc06e8529c4b0" }, { "path": "scripts/historical-ci-inputs/partial-swap-context.json", - "usage": "input", + "usage": "provenance", "git_blob": "ad65114886bf34a4fd27e79f3be502389e689faa", "sha256": "833a9642f33aeab2ffea17ec9c6b82e0a953f90192b2c82e10bef21538dccba9" }, { "path": "scripts/historical-ci-inputs/partial-swap-network.json", - "usage": "input", + "usage": "provenance", "git_blob": "52075f2463f60af5e16571347f24274fce73a1ea", "sha256": "f3c4be597b2f2136da4ae2cc80c7454f63c90aa01f84e5b8131cee4dd55de815" }, { "path": "scripts/partial_swap/shared.py", - "usage": "input", + "usage": "provenance", "git_blob": "44a0e454c70f9c4b98e258b8443612e6a119904b", "sha256": "5a0646a50b9f3e8ea55168620a78e8853b0ab810517cefc8cfb8696aedee278a" }, { "path": "scripts/replay_historical_check.py", - "usage": "input", + "usage": "provenance", "git_blob": "1e92fff2782970ef71378f594f2350d245a4db26", "sha256": "5467619c78183d3adc82b0cb55af28e5c1a01fca2b0588677816244b53e2bafd" }, { "path": "scripts/research_package.py", - "usage": "input", + "usage": "provenance", "git_blob": "091b4c8f58bac9a9580d76025b887dc5c873d05f", "sha256": "e1256016e7f51827d04fa2179255989f639ae1d97afaa9c16265f85a0c6abd70" }, { "path": "scripts/run_isolated_tests.py", - "usage": "input", + "usage": "provenance", "git_blob": "a96ab35b315ce492e7fbbfd6c5ae211aa066b541", "sha256": "49eb56dd0fc0d8d8ffdb209970a7adf2176223580646f575d5c22e59543b381c" }, { "path": "scripts/verify_selected_result.py", - "usage": "input", + "usage": "provenance", "git_blob": "6882a4700e410dec569b51ae2eaf1a19cc019195", "sha256": "d6b305eac5b9bdb8172c469ad30a1655a60fa0aceac8b1bf610e1b73f51babd8" }, { "path": "tests/test_isolated_test_runner.py", - "usage": "input", + "usage": "provenance", "git_blob": "343b24abf6719b81805eba5a84c74e57634c8288", "sha256": "3a5470d0b139828b90e19bf9583ddeafcd69f8e34f2824664eb3a2958a52e34d" } diff --git a/research/historical-selected-replay-gap/VERIFY.json b/research/historical-selected-replay-gap/VERIFY.json index 98553e72ed..ab7efa3471 100644 --- a/research/historical-selected-replay-gap/VERIFY.json +++ b/research/historical-selected-replay-gap/VERIFY.json @@ -4,36 +4,7 @@ "python": "3.12", "requirements": [], "inputs": [ - "Makefile", - "certificates/partial-swap-network.json", - "docs/ci-verification.md", - "research/clifford-state-performance/SOURCE.json", - "research/community-batch1047-audit/CONTENT-COVERAGE.json", - "research/community-batch1099-audit/CONTENT-COVERAGE.json", - "research/community-batch932-audit/CONTENT-COVERAGE.json", - "research/community-batch970-audit/CONTENT-COVERAGE.json", - "research/community-frontier741-audit/CONTENT-COVERAGE.json", - "research/community-frontier890-audit/CONTENT-COVERAGE.json", - "research/community-hyperplane599-audit/SOURCE.json", - "research/community-k492-audit/SOURCE.json", - "research/community-reconciliation92-audit/MANIFEST.json", - "research/partial-swap-digest/baseline.py", - "research/r420-two-sided-basis/SOURCES.json", - "research/skip-clones/SOURCE.json", - "research/split-skip/SOURCE.json", - "scripts/historical-ci-inputs/Makefile", - "scripts/historical-ci-inputs/ledger-batch932-run_isolated_tests.py", - "scripts/historical-ci-inputs/ledger-batch932-test_isolated_test_runner.py", - "scripts/historical-ci-inputs/ledger-batch970-verify_selected_result.py", - "scripts/historical-ci-inputs/ledger-frontier741-ci-verification.md", - "scripts/historical-ci-inputs/partial-swap-context.json", - "scripts/historical-ci-inputs/partial-swap-network.json", - "scripts/partial_swap/shared.py", - "scripts/replay_historical_check.py", - "scripts/research_package.py", - "scripts/run_isolated_tests.py", - "scripts/verify_selected_result.py", - "tests/test_isolated_test_runner.py" + "scripts/research_package.py" ], "commands": [ { diff --git a/research/historical-selected-replay-gap/verify.py b/research/historical-selected-replay-gap/verify.py index 83b995941a..9d266c5a4e 100644 --- a/research/historical-selected-replay-gap/verify.py +++ b/research/historical-selected-replay-gap/verify.py @@ -6,8 +6,10 @@ """ import hashlib import importlib.util +import json import subprocess import sys +import tempfile from pathlib import Path ROOT = Path(__file__).resolve().parents[2] @@ -61,31 +63,47 @@ def require(ok, message): raise SystemExit(message) -def load_checker(): - path = ROOT / "scripts/replay_historical_check.py" - spec = importlib.util.spec_from_file_location("historical_selected_replay_gap_checker", path) +def load_module(path): + spec = importlib.util.spec_from_file_location(path.stem, path) module = importlib.util.module_from_spec(spec) spec.loader.exec_module(module) return module +def checkout_snapshot(snapshot, sources, runner, env): + paths = [runner.canonical_relative_path(row["path"]) for row in sources["files"]] + git = ["git", "-c", "maintenance.auto=false", "-c", "gc.auto=0", + "-c", "core.autocrlf=false"] + subprocess.run([*git, "clone", "--quiet", "--shared", "--no-tags", "--no-checkout", + "--", str(ROOT), str(snapshot)], cwd=ROOT, env=env, check=True) + subprocess.run([*git, "update-ref", "--no-deref", "HEAD", INSPECTED], + cwd=snapshot, env=env, check=True) + # The pinned planner reads omitted manifests from the sparse HEAD/index. + patterns = "".join(f"/{path.as_posix()}\n" for path in paths) + subprocess.run([*git, "sparse-checkout", "set", "--no-cone", "--stdin"], + cwd=snapshot, env=env, input=patterns.encode("utf-8"), check=True) + subprocess.run([*git, "read-tree", "-mu", "HEAD"], cwd=snapshot, env=env, check=True) + for path, row in zip(paths, sources["files"], strict=True): + require(hashlib.sha256((snapshot / path).read_bytes()).hexdigest() == row["sha256"], + "historical checkout source digest changed: " + path.as_posix()) + + def entries(checker): for name, config in checker.CONFIG.items(): for entry in [config, *config.get("additional_inputs", [])]: yield name, entry -def reject(checker, entry): +def reject(root, checker, entry): try: - checker.authenticated_input(ROOT, entry) + checker.authenticated_input(root, entry) except ValueError as exc: return str(exc) raise SystemExit("historical input was admitted: " + entry["path"]) -def main(): - require(not sys.flags.optimize, "assertions must stay enabled") - checker = load_checker() +def check_snapshot(root, env): + checker = load_module(root / "scripts/replay_historical_check.py") selected = [entry for name, entry in entries(checker) if name == "tooling-ledger" and entry["path"] == SELECTED_PATH] require(len(selected) == 1, "selected-result checker overlay is not unique") @@ -94,7 +112,7 @@ def main(): require(entry["accepted_live_sha256"] == [SELECTED_ACCEPTED], "accepted selected-checker successors changed") frozen = (checker.INPUTS / entry["input"]).read_bytes() - live = (ROOT / SELECTED_PATH).read_bytes() + live = (root / SELECTED_PATH).read_bytes() require(hashlib.sha256(frozen).hexdigest() == SELECTED_PIN, "frozen selected checker bytes changed") require(hashlib.sha256(live).hexdigest() == SELECTED_LIVE, "live selected checker digest changed") require(SELECTED_LIVE not in (SELECTED_PIN, SELECTED_ACCEPTED), "live checker was already admitted") @@ -102,7 +120,7 @@ def main(): # live successor, not a broken comparison. require(SELECTED_PIN in (SELECTED_PIN, *entry["accepted_live_sha256"]), "pin membership control failed") - require(reject(checker, entry) == REJECTIONS[SELECTED_PATH][1], + require(reject(root, checker, entry) == REJECTIONS[SELECTED_PATH][1], "selected checker rejection text changed") counts = {path: 0 for path in REJECTIONS} @@ -110,7 +128,7 @@ def main(): for _name, item in entries(checker): if item["path"] not in REJECTIONS: continue - message = reject(checker, item) + message = reject(root, checker, item) counts[item["path"]] += 1 messages.setdefault(item["path"], message) for path, (count, message) in REJECTIONS.items(): @@ -118,20 +136,31 @@ def main(): require(messages[path] == message, "rejection text changed for " + path) require(sum(counts.values()) == 19, "rejection total changed") ci = [item for _name, item in entries(checker) if item["path"] == CI_PATH] - require(len(ci) == 1 and hashlib.sha256((ROOT / CI_PATH).read_bytes()).hexdigest() == CI_LIVE, + require(len(ci) == 1 and hashlib.sha256((root / CI_PATH).read_bytes()).hexdigest() == CI_LIVE, "selected CI note digest changed") diff = subprocess.check_output( - ["git", "diff", "--name-only", PARENT, INSPECTED], cwd=ROOT, text=True) + ["git", "diff", "--name-only", PARENT, INSPECTED], cwd=root, env=env, text=True) changed = sorted(name for name in diff.splitlines() if name) require(changed == CHANGED, "inspected commit diff changed") - sys.path.insert(0, str(ROOT / "scripts")) - from research_package import plan_details - details = plan_details(ROOT, set(changed)) + planner = load_module(root / "scripts/research_package.py") + details = planner.plan_details(root, set(changed)) require([row["package"] for row in details] == PLAN_PACKAGES, "helper plan selection changed") matched = {name for row in details for names in row["causes"].values() for name in names} require(sorted(set(changed) - matched) == UNMATCHED, "unmatched plan paths changed") - require(plan_details(ROOT, set()) == [], "empty change set selected a package") + require(planner.plan_details(root, set()) == [], "empty change set selected a package") + + +def main(): + require(not sys.flags.optimize, "assertions must stay enabled") + sources = json.loads(Path(__file__).with_name("SOURCES.json").read_bytes()) + require(sources["base_commit"] == INSPECTED, "historical checkout base changed") + runner = load_module(ROOT / "scripts/research_package.py") + env = runner.git_source_env() + with tempfile.TemporaryDirectory(prefix="historical-selected-replay-") as temporary: + snapshot = Path(temporary) / "snapshot" + checkout_snapshot(snapshot, sources, runner, env) + check_snapshot(snapshot, env) print("PASS_HISTORICAL_SELECTED_REPLAY_GAP") print("selected_checker_live=" + SELECTED_LIVE) print("rejections=19 distinct_paths=7 plan_packages=9") diff --git a/research/p104-banked-cf6a-splits/.gitattributes b/research/p104-banked-cf6a-splits/.gitattributes new file mode 100644 index 0000000000..85aa032067 --- /dev/null +++ b/research/p104-banked-cf6a-splits/.gitattributes @@ -0,0 +1 @@ +credits/PR7669-PROVENANCE.md -text whitespace=cr-at-eol diff --git a/research/p104-banked-cf6a-splits/ASSETS.json b/research/p104-banked-cf6a-splits/ASSETS.json new file mode 100644 index 0000000000..fd783b6e53 --- /dev/null +++ b/research/p104-banked-cf6a-splits/ASSETS.json @@ -0,0 +1,129 @@ +{ + "schema_version": 1, + "files": [ + { + "path": ".gitattributes", + "sha256": "8809106a77c5111b765961c96ce0faff15f4ee5dd6b89ffb4db18d8c19f5e6b8" + }, + { + "path": "LICENSE", + "sha256": "c71d239df91726fc519c6eb72d318ec65820627232b2f796219e87dcf35d0ab4" + }, + { + "path": "NOTICE", + "sha256": "5645b5cc9fc560c3e5057e8e15ec1bc4e678a5724a968c13df2ac04526dbbc64" + }, + { + "path": "PHYSICAL.md", + "sha256": "7df8a8e707c1b941d22609de9dbdd1115ae261824bf39a4de162c6be0389014e" + }, + { + "path": "PROOF.md", + "sha256": "ec4aa171ca6895426eb041cb35a64b12ed8be3b8ccdf4972ed6ed75107736726" + }, + { + "path": "README.md", + "sha256": "02a1af3477ca8918e195d116fbb5b0efa0e70c16443f6ba2505484db7c18cb23" + }, + { + "path": "SOURCES.json", + "sha256": "5ae4cfc96aa890b1b06aa0de688e03d9713b2772fb0f9c6ae7e23ad7d49c479d" + }, + { + "path": "TASK.json", + "sha256": "5849b682cd039b4345d355655ce25252ed8f66193852e040c0b83f314ac378e4" + }, + { + "path": "VERIFY.json", + "sha256": "8d1f53468f1f31e9e983ef567a01a532adb98acb84d5cf0f0ed1a27e16ff3946" + }, + { + "path": "credits/7658-NOTICE", + "sha256": "2732575164931c53cc4bc57145c31d87741489e3048afee6899e856c0ea503b5" + }, + { + "path": "credits/7700-CITATION.cff", + "sha256": "50399ea15e9ce49baafbd00d6da16e662ac46c566e3c04af3993e23cf0b62ff4" + }, + { + "path": "credits/7700-NOTICE", + "sha256": "b49022cb4104d90b182e4c335f670faf45529025b15db77bf0291835083c28bd" + }, + { + "path": "credits/OUTER-GATE-NOTICE", + "sha256": "cadbc642ca84311d2c7a6cf704c7828cb4cf77e3c784b66e4c6e8a5c28002fb8" + }, + { + "path": "credits/PR7663-NOTICE", + "sha256": "5fd4367578d2339fbdcd7dc116b6c12cb4fa72e92d2e3d67be537a36c8bd9d40" + }, + { + "path": "credits/PR7669-PROVENANCE.md", + "sha256": "706c6c852e87e371ddf1828244b2f0c2b00279728818023aa911c8947d69ab83" + }, + { + "path": "credits/PR7674-NOTICE", + "sha256": "382537634a3d9fa0a8089d6121a506a399382f9310088b1f29586dcc93eec92d" + }, + { + "path": "credits/PR7682-NOTICE", + "sha256": "7590f71de481c424d2315e9ea4884bea1557481676fa5f930f7a0bed637a56a1" + }, + { + "path": "credits/PR7704-NOTICE", + "sha256": "49657dd50c9431642a9527b0d625197cb34d1838dcf00fe4d92040f9605c8ce0" + }, + { + "path": "credits/PR7705-NOTICE", + "sha256": "43510816b93ea09e0d716ccc6261c84ce081821c0d5dea7d6e748863d55f8f40" + }, + { + "path": "credits/PR7708-NOTICE", + "sha256": "c3762acca6fa198c621e0aacf8aa06526aa7716c20c761141c07393fdba6bc46" + }, + { + "path": "data/CIRCUIT.json.gz", + "sha256": "06256c172bbaf28c7d51ada9b99099db2f3b262ca72e0c1adefc9116d732f6d6" + }, + { + "path": "data/SPLITS.json", + "sha256": "f26c49d32f9f1c55084501d1c1eed63b540a945377143272f6522bc91ca29c29" + }, + { + "path": "source/CALLER.json.gz", + "sha256": "d889996a337f648087208ab51c98eaf052705d4fca88b5d01b6e9257a829897a" + }, + { + "path": "source/WORD.json.gz", + "sha256": "50c1facfc5626c060560e2f354b71bd92d0bb1c1e853b2aad72abcbaaa5328a5" + }, + { + "path": "tools/bank.py", + "sha256": "e9a6da475fdcfc2cdc3dbe49f34541ab4c321857581eac313adffcde804a8dce" + }, + { + "path": "tools/exval.py", + "sha256": "56f8a4a67a995b4f4114e1a89a3cd5aeb62ae644682f07b6a854b2a057aeddc5" + }, + { + "path": "tools/gauss.py", + "sha256": "f3fe30406700b0746bbbd999079336c97d7b9325f8b1fc8c8ac20377e228ae64" + }, + { + "path": "tools/nest.py", + "sha256": "f819c75f331222bdace538867d0459fb4d9b187ce80ed6b5b7dee120d0511156" + }, + { + "path": "tools/phys.py", + "sha256": "fc15a3610a58adff27183946080ea940949dc8a40c14ab23759e464a5b3447ab" + }, + { + "path": "tools/pricekit.py", + "sha256": "7e08e9129dfc46d7dd351d0ec972d1223b2488503fe49e556df0c6dcad1f3743" + }, + { + "path": "verify.py", + "sha256": "86d2689cf4ff6b849eae0a47cd1ad61e56ca3ca4c1b05df7fa22adc8bd17294a" + } + ] +} \ No newline at end of file diff --git a/research/p104-banked-cf6a-splits/LICENSE b/research/p104-banked-cf6a-splits/LICENSE new file mode 100644 index 0000000000..261eeb9e9f --- /dev/null +++ b/research/p104-banked-cf6a-splits/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/research/p104-banked-cf6a-splits/NOTICE b/research/p104-banked-cf6a-splits/NOTICE new file mode 100644 index 0000000000..6d6192b9a0 --- /dev/null +++ b/research/p104-banked-cf6a-splits/NOTICE @@ -0,0 +1,7 @@ +Apache License 2.0. Research prepared by DreamingOfClouds with Claude Opus 5.5 (Anthropic), via Claude Code. + +The contribution is the three causal helper splits at charts 498, 480 and 595 on the #7708 circuit, together with their search, exact builder and checks. All code here is newly written, and predecessor packages were read as data only. + +aliromman supplied the relay-cut recodings (PR #7708) and the banked-transfer circuit (PR #7674). Clear1nsight supplied the role-1256 relay (PR #7704), the chart-595 split method (PR #7697) and the role-230 reroute (PR #7682). SYLforge supplied the cf6a nine-swap word (PR #7700) and the signed sixteen-call caller. DreamingOfClouds, Rohan Arun, Jerry Chen (CubeJerry), Douglas Colkitt and the authors credited in the inherited notices supplied predecessor constructions, the selected framework and the repository infrastructure. + +The exact predecessor notices are in `credits/`. `source/` holds the #7700 word and the 16-call caller as published with #7704. `ASSETS.json` binds every package file. diff --git a/research/p104-banked-cf6a-splits/PHYSICAL.md b/research/p104-banked-cf6a-splits/PHYSICAL.md new file mode 100644 index 0000000000..7b6c73cf41 --- /dev/null +++ b/research/p104-banked-cf6a-splits/PHYSICAL.md @@ -0,0 +1,22 @@ +# Physical accounting + +All coefficients fit in 13 bits. + +The recursive row-denominator bound changes from #7708's `2025 × 2²⁰` to `2,083,725 × 2²⁰`. The new odd factor `1029 = 3 · 7³` comes from the split coefficients. It is the same odd grid that #7697 uses for its chart-595 split. Native entrance and exit conversions scale by the new odd factor. + +The paid edge count and every paid route are unchanged: 6,121 rows per native. + +The public width rises from 1,501 to 1,504, adding three fresh helper owners per native invocation. Under #7708's home count `2n + k + 5`, the private homes go from 9,128 to 9,134 per native. + +Nonzero local terms rise from 177,531 to 179,874 per native, from the input encoding, the injections and the output decoding. Under the #7682 service formulas, our recount gives: + +| Per native | #7708 | This circuit | +| --- | ---: | ---: | +| Reset services | 1,517,724 | 1,536,516 | +| Selected transfer legs | 413,036 | 417,740 | + +The same recount reproduces #7708's published 413,036 transfer legs exactly. Its reset count, 1,517,724, is within 2 of the published 1,517,726 because the home formulas differ by two homes. + +Scalar services rise by 2,343 × 32 per native. + +All of these charges are finite constants absorbed in the funded compiler margin of the selected finite-template substitution, as in #7697 and #7708. diff --git a/research/p104-banked-cf6a-splits/PROOF.md b/research/p104-banked-cf6a-splits/PROOF.md new file mode 100644 index 0000000000..5c27c81918 --- /dev/null +++ b/research/p104-banked-cf6a-splits/PROOF.md @@ -0,0 +1,43 @@ +# Causal helper splits on a banked circuit + +## The circuit and the parent + +The banked-transfer reading of #7674 is used throughout. Each paid edge `k : A → B` carries a rational linear form. The form is built over the values available at chart `A`: independent public inputs entering at `A` and returned snapshots of earlier paid edges into `A`. A paid edge applies `T_B T_A⁻¹` and leaves the normalized signal unchanged. A valid circuit has cocharted reads, an acyclic dependency graph, and the required public outputs. Each of the 400 mains must equal the #7700 word's output, and each helper must return its own input. + +The parent is #7708, rebuilt by our own code. We fold the authenticated #7700 word, apply the #7704 relay, then apply the 46 published #7708 cuts in order. That reproduces its κ crossing 0.00374039009047. + +## One split + +Let `G` be the 615 helper roles that enter at chart `E = 3` and exit at chart `X = 127`. In normalized coordinates each returns its own input. Pick a chart `C` with `E ⊂ C ⊂ X` (strictly nested). At `C` choose: + +- a set of **prefix** values `A`: the arrivals at `C`, and the inputs entering at `C`, that do not depend on the departures chosen next; +- a set of **departures** `Dp` from `C`. + +We need a functional `ℓ` that is a rational combination of the values in `A`, supported only on the inputs of `G`. We also need an output direction `v`: the change in all public outputs caused by adding fixed multiples `c_k` of one new array to the departures `k ∈ Dp`. It must be supported only on the outputs of `G`, with `ℓ(v) = 1`. Choose a role `r ∈ G` with `ℓ_r ≠ 0`. + +The construction has four steps: + +1. **Encode the inputs.** The group inputs at chart 3 are re-encoded as `x_j = u_j + v_j u_r` for `j ≠ r`, and `x_r = v_r u_r − Σ_{j≠r} ℓ_j u_j / ℓ_r`. Then `ℓ(x) = u_r`, and the encoding is invertible for arbitrary arrays. +2. **Retire role `r` at `C`.** Its output is the prefix combination `ℓ(x) = u_r`, which is available at `C`. +3. **Add a fresh role `n` entering at `C`.** Add `c_k (g − ℓ(x))` to each departure `k`, where `g` is the new input. Linearity gives the old exit fields `y = x + v(g − u_r)`. +4. **Decode at chart 127.** The fresh output is `ℓ(y) = g`, and each other helper outputs `y_j − v_j ℓ(y) = u_j`. + +The mains never see the change, because `v` vanishes outside `G`. Role `r` now pays rank `dim C − dim E` and the fresh role pays `dim X − dim C`, in place of one rank-9 target. The gain is `f(d) + f(9 − d) − f(9)` with `f(r) = r^{1−κ}`, which is strictly positive by concavity. + +A mod-p screen over every chart and every departure cut found exactly three charts on this circuit: 498 (4 | 5), 480 (2 | 7) and 595 (1 | 8). The same screen finds exactly #7697's chart 595 on the #7682 circuit. Each split was rebuilt in exact rationals and accepted only after the whole circuit passed four checks: schedule, nesting, equality of all mains with the word, and every helper being the identity. The rescreen after the three splits finds no further split. + +## Exact arithmetic and storage + +Coefficient size, the common-root grid, private homes and the service bills are in [PHYSICAL.md](PHYSICAL.md). + +## Premises + +The result is conditional on the five selected-framework assumptions used by #7674, #7682, #7697, #7704 and #7708: + +- uniform native realization at all column multiplicities; +- owned allocation and erasure; +- uniform compiler closure; +- fixed-tape precision and movement; +- analytic recovery. + +It also relies on the parent's banked-storage and common-root realization. No new assumption is added. diff --git a/research/p104-banked-cf6a-splits/README.md b/research/p104-banked-cf6a-splits/README.md new file mode 100644 index 0000000000..f9eb24ac24 --- /dev/null +++ b/research/p104-banked-cf6a-splits/README.md @@ -0,0 +1,35 @@ +# Three helper splits on the #7708 cf6a banked circuit + +**Conditional κ ≥ 0.0037427697512.** This is 0.0000023796607 (0.0636%) above #7708's crossing 0.00374039009047 (claim 0.00374039009039). The parent is aliromman's #7708 circuit: the #7700 cf6a word (SYLforge), Clear1nsight's role-1256 relay (#7704), and 46 relay-cut recodings. Three exact **causal helper splits**, in the style of Clear1nsight's chart-595 split (#7697), each replace one rank-nine helper job by two independently owned smaller jobs. Every paid edge and route is unchanged. [Construction](PROOF.md) · [Physical accounting](PHYSICAL.md) · [Check](verify.py) + +| Cut chart | Retired role (new exit) | Fresh role (route) | Target ranks | +| --- | --- | --- | --- | +| 498 | 126 (3 → 498) | 1501 (498 → 127) | 9 → 4 + 5 | +| 480 | 239 (3 → 480) | 1502 (480 → 127) | 9 → 2 + 7 | +| 595 | 281 (3 → 595) | 1503 (595 → 127) | 9 → 1 + 8 | + +Per native invocation, the paid histogram is unchanged at 6,121 edges. The productive targets change by `{1:+1, 2:+1, 4:+1, 5:+1, 7:+1, 8:+1, 9:−3}`, which leaves the rank mass unchanged. The complete 16-call invoice has 101,488 paid jobs, 21,200 targets and S = 1,328. The crossing is certified in (0.00374276975125, 0.00374276975126). + +## Reproduce + +```sh +python3.12 -I -B verify.py +``` + +From the repository root, run `python3.12 -B scripts/research_package.py --package research/p104-banked-cf6a-splits`. The check uses only the standard library and takes about two minutes on one core. It does the following: + +- Authenticates every asset and the #7700 word (canonical SHA-256 `ae62d5d8…1472`). +- Checks locality and an acyclic schedule. +- Checks that every paid edge is GF(2)-nested with positive rank and that the symplectic rank of each transfer equals the dimension difference. +- Runs an exact Gaussian column simulation of every chart pair that is absent from the word, with a non-nested control. +- Proves exact rational equality of all 1,504 public outputs: the 400 mains equal the word's, and every helper, including the three fresh roles, returns its own input. +- Prices the literal caller. + +## Open next questions + +- Do two-role splits at one chart, or splits of the smaller helper groups (exits 245, 243, 240), give further target gains? Start by extending the split screen to rank-two pairings and to the other groups. +- Do the relay-cut and hub-reroute classes find new edits after the splits? The splits change input coordinates and inject into departures from charts 498, 480 and 595. + +## Credit + +aliromman supplied the relay-cut recodings and their algebra (#7708) and the banked-transfer circuit (#7674). Clear1nsight supplied the role-1256 relay (#7704), the chart-595 split method (#7697) and the role-230 reroute (#7682). SYLforge supplied the cf6a nine-swap word (#7700) and the 16-call caller. The contributors credited in their notices supplied the predecessor constructions; their notices are in [credits/](credits/). The split search, exact builder and checks are by DreamingOfClouds with Claude Opus 5.5 (Anthropic), via Claude Code. diff --git a/research/p104-banked-cf6a-splits/SOURCES.json b/research/p104-banked-cf6a-splits/SOURCES.json new file mode 100644 index 0000000000..e8c2f265cd --- /dev/null +++ b/research/p104-banked-cf6a-splits/SOURCES.json @@ -0,0 +1,18 @@ +{ + "base_commit": "e54523517d0f03e58352e647c403a5af3e525a57", + "files": [ + { + "git_blob": "75d77b328ea02ded535e7f23aee5b1e55d0bb1a8", + "path": "certificates/selected-result.json", + "sha256": "154c3d30455d778fd3343b6b4851f0fa4665f0f7625b0adb3675e2bafbbf6bf1", + "usage": "provenance" + }, + { + "git_blob": "3404fbdd5e7529a0674eef26114b5071e4586cec", + "path": "docs/research/agent-task-catalog.json", + "sha256": "ead6cdc9d0af6d58e8a49744d8ec8c7c15e13d2ba93c276c434bcf9b51b93a81", + "usage": "provenance" + } + ], + "schema_version": 1 +} diff --git a/research/p104-banked-cf6a-splits/TASK.json b/research/p104-banked-cf6a-splits/TASK.json new file mode 100644 index 0000000000..9cda0084e1 --- /dev/null +++ b/research/p104-banked-cf6a-splits/TASK.json @@ -0,0 +1,115 @@ +{ + "actual_scope": "Verify three causal chart splits (charts 498, 480 and 595) of independent rank-nine helpers on the #7708 banked circuit of the #7700 cf6a word for the signed sixteen-call caller.", + "ai_assistance": "Substantial Claude Opus 5.5 (Anthropic) assistance, via Claude Code, in search, construction, verification and writing. All engines in this package are newly written; predecessor packages are read as data only.", + "author": "DreamingOfClouds", + "base_commit": "e54523517d0f03e58352e647c403a5af3e525a57", + "bottleneck_link": "The retained P104 signed caller repeats each paid native rank 16 times. A legal concentration of paid rank, with the same productive boundary, reduces the signed power cost.", + "evidence": "The exact circuit is data/CIRCUIT.json.gz and the splits are listed in data/SPLITS.json. The registered command authenticates the #7700 word, checks locality, acyclicity, nesting, symplectic and exact Gaussian column ranks, exact rational equality of all 1,504 public outputs, and prices the literal 16-call invoice: certified crossing (0.00374276975125, 0.00374276975126), directed lower 0.0037427697512 above #7708 at 0.00374039009047.", + "open_questions": [ + { + "blocked_by": "Each candidate needs an exact functional on the group inputs at the cut chart whose pairing with the injected output directions is nonzero.", + "first_step": "Extend the split screen to rank-two pairings at one chart and to the other helper groups, then rebuild each candidate exactly against all public outputs.", + "question": "Do causal splits with two retired roles at one chart, or splits of the smaller helper groups (exits 245, 243, 240), admit further productive-target gains on this circuit?", + "why_it_matters": "Each split converts one rank-nine target into two smaller targets; the present search uses one retired role per chart and the 3 to 127 helper group only." + } + ], + "original_card": { + "acceptance_gate": "An exact arbitrary-input identity, source/target frame availability and restoration at the chosen cut, plus the complete channel+correction+idle/hosting bill or an explicit favorable bound. The native channel alone is not a supplier. 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.", + "allowed_variations": [ + "One exact source head, helper/cut region or quantified proposition and changed hypothesis; check live handoffs first. Different seeds are not different scopes." + ], + "bottleneck_link": "Judge the actual current supplier contract and complete signed target/paid bill; frozen-profile ceilings require an applicability proof.", + "existing_checks": [ + { + "evidence": "research/p104-literal-slot-defect/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "scope": "PR #4133: literal-slot defect", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129", + "source_commit": "88666f1dee93fbd85b31fd5d6f91a219e111b5f4", + "status": "author-checked" + }, + { + "evidence": "research/p104-uniform-commutation-gap/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "scope": "PR #4136: uniform commutation gap", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129", + "source_commit": "281ce601a8be9db470de630759179c23e1dfaa88", + "status": "author-checked" + }, + { + "evidence": "research/p104-uniform-encoding-gap/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "scope": "PR #4140: uniform encoding gap", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129", + "source_commit": "de25c6525aa866962309df5d107b32d55e6e5628", + "status": "author-checked" + }, + { + "evidence": "research/p104-source-chart-shortcut/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "scope": "PR #4153: source-chart shortcut exhausts its optimistic allowance", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129", + "source_commit": "9123241fea53df77e51ffe30d9aca1625d4bf3a8", + "status": "author-checked" + }, + { + "evidence": "research/p104-fiber-tag-seam/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "scope": "PR #4154: fiber-tag seam mismatch", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129", + "source_commit": "4ffcdaee5d6255a9cea1fe53a5424435068089d0", + "status": "author-checked" + }, + { + "evidence": "docs/research/pr-intake-evidence/pr5599-completion/PROOF-REVIEW.md", + "remaining": "The next experiment must identify uncovered source-specific work. Successor archive intake does not transfer this admission.", + "scope": "Selected PR5599: complete helper-subspace construction and independent caller replay; five framework assumptions remain.", + "selected_record_sha256": "2a0220e866417774606e0f991e41b9c1d26b1f43b97857238cf478dbc7d330b5", + "source_commit": "09dd0965711ca7eeb169057a420abab1c9052137", + "status": "reviewed" + } + ], + "first_experiment": "Start with the selected #5599 emitted word and review pending #5718 distinct input/output bases plus #5717/#5719 coverage before claiming work. Pick one uncovered source word, helper group and cut region. Prove the arbitrary-input relation and legal entry/exit corrections, then compare full target and paid profiles. Reject if completion, owned lifetimes or consumer costs repay the gain. A static pairing rank alone is not a physical split.", + "first_step": { + "command": [ + "python3", + "-B", + "scripts/research_selected_baseline.py" + ], + "expected": "PASS_RESEARCH_BASELINE_BINDINGS_ONLY", + "inspect": "Read revision 8, the selected review and live exact-source handoffs. Then follow this card's bounded first_experiment.", + "scope": "Source-bound orientation only, not a supplier replay or theorem proof." + }, + "id": "p104-side-correction", + "methods": [ + "Construct and independently check one source-bound instance of the stated first experiment.", + "Seek an exact counterexample or target-specific complete-budget obstruction to that same proposed change." + ], + "overlap_terms": [ + "P104", + "helper basis", + "helper split", + "5718", + "dyadic capacity" + ], + "question": "Can joint helper bases and a legal causal split improve the complete P104 productive/paid invoice?", + "scope_change_triggers": [ + "Changing source head, helper/cut domain, operation alphabet or caller boundary without recording the new scope.", + "Treating an archived proposal or local numerical pass as complete supplier admission." + ], + "starting_points": [ + "docs/research/current-priorities.md", + "docs/research/research-family-status.md", + "certificates/selected-result.json", + "docs/research/pr-intake-evidence/pr5599-completion/PROOF-REVIEW.md", + "research/p104-helper-subspace-splits/README.md", + "research/dyadic-helper-channel-capacity/README.md" + ] + }, + "outcome": "completed", + "schema_version": 1, + "scope_change_reason": "The pinned P104 recipient already carries the #7700 word, the #7704 relay and the 46 #7708 cuts. This follow-up keeps every paid edge and route fixed and splits three productive rank-nine helpers into independently owned pairs of smaller jobs through certified causal scalar cuts, generalising the #7697 chart-595 split to the cf6a lineage.", + "scope_status": "refined", + "stop_rule": "Require the exact changed circuit, exact rational equality of all public outputs against the authenticated #7700 word and helper identities, nested positive-rank charts with exact symplectic and Gaussian column ranks, the complete signed 16-call invoice and a certified crossing above the #7708 claim.", + "task_id": "p104-side-correction" +} diff --git a/research/p104-banked-cf6a-splits/VERIFY.json b/research/p104-banked-cf6a-splits/VERIFY.json new file mode 100644 index 0000000000..072bb225f1 --- /dev/null +++ b/research/p104-banked-cf6a-splits/VERIFY.json @@ -0,0 +1,14 @@ +{ + "commands": [ + { + "argv": ["{python}", "-I", "-B", "{package}/verify.py"], + "checks": "Authenticate all package assets and the #7700 cf6a word, then check locality and an acyclic schedule, GF(2) nesting and symplectic rank of every paid chart pair, exact Gaussian column ranks of every pair absent from the word with a non-nested control, exact rational equality of all 1,504 public outputs (400 mains against the word, every helper including three fresh roles its own input), and the certified crossing of the complete 16-call invoice above 0.0037427697512.", + "timeout_seconds": 600 + } + ], + "inputs": [], + "python": "3.12", + "requirements": [], + "schema_version": 1, + "status": "ready" +} diff --git a/research/p104-banked-cf6a-splits/credits/7658-NOTICE b/research/p104-banked-cf6a-splits/credits/7658-NOTICE new file mode 100644 index 0000000000..2baa2a719e --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/7658-NOTICE @@ -0,0 +1,21 @@ +Apache-2.0. DreamingOfClouds with Claude Opus 5.5 (Anthropic), via Claude Code. + +The base word (data/base-7641-word.json.gz, unmodified bytes, sha256 de43ed04f58133eaef8f8d12a9dae1e6e8aa7f9721044200cc839673d86fd7c1) +is the word of our #7641 (20 swap-then-delete composites on SYLforge's #7637), vendored as data only. #7641's own base is SYLforge's +#7637 candidate word, whose notices read: + + "Apache-2.0. Local H5B + E1/E4 combination experiment, prepared with OpenAI assistance. + All earlier contributors and notices in hydrogen-bounded-verification-20261117/NOTICE remain credited. In particular: Ali Romman + (#7605), SYLforge, Clear1nsight, DreamingOfClouds, and all upstream contributors listed there." + +#7637's recorded technique credits: DreamingOfClouds #7630 (E1 rebirth/canceller, E4 existing-co-presence reroute), Clear1nsight +#7631/#7633 (efficient E4 integration, E1 prefix/tail settlement), and SYLforge's H5B literal-frame-restored archive. Its lineage +also carries Clear1nsight's #7626/#7314/#7274, Rohan Arun's #7277 and signed #7113 caller, and the contributors named in the +retained sources. #7641, #7637 and their code are not run by this package; only their words are read as data. + +This package adds five edits found by a large-neighbourhood search (one SWAP-NULL relabel of two helpers with a stay deletion, one main +stop removal, three helper stay deletions with re-placed contacts) and one hub re-settle. The helper-stay deletion with re-charted +contacts (E3) is of the type introduced by Clear1nsight's #7612 and ToikY's #7643. check.py is our own code: its replay, crossing and +column-test sections come from our #7630-on-#7623, swap-composite and #7641 packages; its column tests follow the description of the +affected-pair tests in #7620's README and native runner. The CLEAR certificate check implements the acceptance rule of #7620's +verify_certificates (read, not run). No other author's code was run; their words are read as data. diff --git a/research/p104-banked-cf6a-splits/credits/7700-CITATION.cff b/research/p104-banked-cf6a-splits/credits/7700-CITATION.cff new file mode 100644 index 0000000000..d80f6b8660 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/7700-CITATION.cff @@ -0,0 +1,55 @@ +cff-version: 1.2.0 +message: >- + Please cite the selected composition and its constituent contributions, + this project and the upstream manuscript. The selected checkpoint is PR4470 on the cumulative productive-helper framework; consult certificates/selected-result.json for publication status. + Project-level authorship identifies the maintainer, not sole authorship of + the community result. See CONTRIBUTORS.md and the frozen source notices. +title: "A sharper exponent for integer multiplication" +authors: + - family-names: Colkitt + given-names: Douglas +license: Apache-2.0 +type: software +version: "community-joint4470-2026-10-22" +date-released: 2026-10-22 +repository-code: "https://github.com/CrocSwap/integer-mult-bounds" +url: "https://github.com/CrocSwap/integer-mult-bounds" +abstract: >- + Community research on integer multiplication. The selected maintainer-reviewed + conditional construction has kappa = 60403/20000000 = 0.00302015. + Cinna Davis's PR4470 joint helper frames and query-thinned controller build on + her preceding constructions, zxv's native/productive-helper and compiler work, + Jacob Alan Sussman's mixed-target recursion, and the cumulative community + framework. Exact finite replays and independent audits retain explicit + all-column/native, owned-erasure, compiler, precision/tape, analytic, prime + and recovery assumptions. This is not a complete formal multiplication proof. +preferred-citation: + type: software + title: "A sharper exponent for integer multiplication: community research repository" + authors: + - family-names: Colkitt + given-names: Douglas + year: 2026 + url: "https://github.com/CrocSwap/integer-mult-bounds" + notes: >- + Maintainer citation only, not sole authorship of the mathematical result. + Credit Cinna Davis (PR4470/4447/4441/4440/4416), zxv (PR4359/4433), + Jacob Alan Sussman (PR4268), independent auditors Mihir Srivastava and + Ryanson Jonathan, Mark/Matarener for the commutation question, and the full + geometry, binary, native, precision and outer lineage, including Rohan Arun, + Jeremy Kothe, Chafik Boukhalfa and the contributors listed in CONTRIBUTORS.md + and docs/research/community-joint4470-contributors.md. Cite constituent PRs + where their results are used; preserve their licenses and assistance disclosures. +keywords: + - integer multiplication + - computational complexity + - exact arithmetic + - parameter optimization + - reproducible research +references: + - type: unpublished + title: "Integer multiplication below n log n" + authors: + - name: OpenAI + year: 2026 + url: "https://github.com/openai/math/tree/adc7f1241b42e322a6451854ab7e4b4c146bf78a/preprints/Integer-multiplication-below-n-log-n-September-23-2026" diff --git a/research/p104-banked-cf6a-splits/credits/7700-NOTICE b/research/p104-banked-cf6a-splits/credits/7700-NOTICE new file mode 100644 index 0000000000..59d8e0cf31 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/7700-NOTICE @@ -0,0 +1,415 @@ +A sharper exponent for integer multiplication +Copyright 2026 Douglas Colkitt + +This project includes unmodified source files from OpenAI's manuscript +"Integer multiplication below n log n" and its accompanying repository: +https://github.com/openai/math +Commit: adc7f1241b42e322a6451854ab7e4b4c146bf78a + +The original manuscript identifies OpenAI as its author. Its Apache-2.0 +license is retained at upstream/LICENSE. The exact source URLs and hashes +are recorded in upstream/manifest.json. Proposed modifications are supplied +as separate files under patches/; upstream source files remain unchanged. + +The original local research note, scripts, certificates, patches, and +documentation were prepared by Douglas Colkitt with assistance from OpenAI +Codex. The community release incorporates work by the contributors identified +in the notices below; it is not solely Douglas Colkitt's work. +This project is not an official OpenAI release or an OpenAI endorsement. + +Related contributions (not imported in this checkpoint): +Zhihao Chen (jacklightChen), PR #7, supplied an earlier ternary five-subset +motif, finite-alphabet transfer and a different compressed producer: +https://github.com/CrocSwap/integer-mult-bounds/pull/7 +The present checkpoint claims no priority for that motif. Related compressed +complex-network work was submitted by eumemic in PR #3: +https://github.com/CrocSwap/integer-mult-bounds/pull/3 +The pending contributions and their stronger bounds require their own review; +this notice does not represent adoption or verification of their claims. + +Additional community work, including parallel and superseded submissions, is +acknowledged in CONTRIBUTORS.md, with pinned submission metadata in +docs/research/contribution-snapshot.json. These acknowledgements do not imply +joint authorship of the checkpoint, incorporation of pending code, or verification +of submitted mathematical claims. Original source-specific notices remain in force. + +Community release (accepted by conditional maintainer audit): +The following original contributor notices apply to the imported PR #39 chain. +The preceding non-import statements describe the preserved 2^-30 checkpoint. + +Ternary five-subset construction and common-four-point resynthesis +Copyright 2026 Zhihao Chen (jacklightChen) + +This is Zhihao Chen's first submission of this specific construction to this +repository. Research, proof development, code and verification were prepared +with substantial assistance from GPT-6 Astra (OpenAI Codex), as identified by +the contributor. This is not independent review or an OpenAI endorsement. +Future research building on this contribution should explicitly acknowledge +Zhihao Chen (jacklightChen), cite the accompanying note and pull request, and +retain the preceding contributors' attribution. This notice records research +provenance; the repository's Apache-2.0 license remains unchanged. + +Dependencies retained from eumemic's Claude-assisted PRs #3 and #5: +https://github.com/CrocSwap/integer-mult-bounds/pull/3 +https://github.com/CrocSwap/integer-mult-bounds/pull/5 +PR #5 commit: d3d370c34937503bd3fa63c83d505a05e8e50893 +These include complex_circuit.py, complex_network.py, fast_gaussian.py, +their generators, construction notes and certificates. The Gaussian input +scaling proof is corrected in this derivative; see the modification notice below. +Aligned pairing also appears in Bortlesboat's PR #2. Retained totals and bank +sharing appear in dleen's PR #4 and cheaper retained centers in eumemic's PR #6. +Their results and ideas are credited separately from this new construction. + +Bulk recursion and controlled tensor basis, 8 October 2026 +Copyright 2026 icekylinx + +The new projector batching, controlled simultaneous basis, mixed-width tape +recursions, whole-residual complex recursion, and dependency-path precision +guard in the batched-23 proof package are contributed by icekylinx, developed +with substantial OpenAI GPT-6 Astra assistance. Review corrections and +repository integration were prepared with OpenAI Codex assistance. They build on the retained +PR #7 finite producers and the preceding contributions credited above. +The new package retains the repository's Apache-2.0 license and the original +authors' attribution. It is not an official OpenAI release or endorsement. + +Modification notice, 8 October 2026 (icekylinx): the retained fast Gaussian +proof now bounds shifted approximation error by F=2^ceil(1.14 alpha^2). +The P=34p precision budget and asymptotic exponent are unchanged. New batching +checks are integrated into make verify. Existing attribution and licenses +are retained. + +Partial-swap extension, 8 October 2026 +Copyright 2026 icekylinx + +The partial-swap framing, binary retained-total triple construction, +dependency-preserving positive labels and carrier reuse, unequal (25,23,57) +common basis, improved complex batching, and exact assembly are contributed +by icekylinx with substantial OpenAI GPT-6 Astra and Codex assistance. +This extension directly inherits PR #10, commit +62691e395a0458ce089a1c7b5d89e74291e95e29. The portable producer adapters +modify the retained paired-exclusion and shared-point implementations credited +above. The original licenses, attribution, and Gaussian correction are retained. + +Endpoint-gauge extension, 8 October 2026 +Copyright 2026 icekylinx + +The complementary auxiliary endpoint gauges, (32,30,40) controlled basis, +general nondegenerate binary phase residuals, retained-center complex producer, +updated path guard and exact assembly are contributed by icekylinx with +substantial OpenAI GPT-6 Astra and Codex assistance. This extension inherits +f2ab41aebad47861caf6316282c1793e5513845e and its PR #10 ancestry. New portable +adapters retain the paired-exclusion and shared-point contributions credited +above. Original licenses, notices and the Gaussian correction are retained. + +Structured-basis and semantic-bulk extension, 8 October 2026 +Copyright 2026 icekylinx + +The selected (32,30,36) bit construction, A1/A5 block refinements, fixed +middle-axis I+J profiles with bounded-minor CRT certificates, mixed dyadic +complex centers, complete data-front batching and circuit-specific assembly +are contributed by icekylinx with substantial OpenAI GPT-6 Astra and Codex +assistance. The immediate parent is ed90fd940279c336ebc45968631bdebfb087b505. + +The semantic/bulk compatibility argument, literal scalar charge, product row +stock and parameterization adapt Zhihao Chen (jacklightChen)'s PR #23, +commit 661ebabc1076c9f525d7ce4967c876b203fa9827. Translated complex endpoints +are adopted from the same contributor's PR #21, +commit 5ba6cf0bfb68f2be8d15610e7972207c50254d6a, following eumemic's source-frame +work and the earlier nested-basis contributions. + +Completed-child semantic precision, arbitrary-coordinate routing, phase-cell +Gaussian inversion and bulk tape transfer are credited to the RaD project +(hipotures), commit 45d9b60355872041f9275f77c057514def0d45bc, exposed through +PR #20 at 4f8d6c8272b5ff307a0da51df545ec3cd96a8b6e. Their selected proof +sources retain their separate CC0 license and original NOTICE under +references/semantic-bulk/rad20. The PR #23 source retains its recorded OpenAI +Codex assistance; RaD retains its recorded Codex and GPT-6.1-Sol Ultra +assistance. These are source attributions, not claims about this session's +runtime model. Related contributions by Rohan Arun and Aurel Prosz remain +acknowledged in the imported notices. No exclusive priority or additional +license condition is asserted. + +Copied retained-center extension, 8 October 2026 +Copyright 2026 icekylinx + +The copied retained-center schedule in both orientations, its complex-phase +transfer, the Wm-N+L rank budget, and the selected (25,23)/(28,28) composition +are contributed by icekylinx with substantial OpenAI GPT-6 Astra and Codex +assistance. This extension inherits PR #32 at +0ef3aeb61f55cc0b321ce6a0ef00acee25cefe52 and the preceding PR #10/#18/#24 work. + +The two-stage topology and paid copied-stream endpoint correction are due +to Aurel Prosz (Paureel), c82d09eb4781b68435e3fa3eb6beea72fa900fab, +through Zhihao Chen (jacklightChen)'s PR #29 unequal-axis composition, +9d963275075fa98f1da821e27757b238dafd6b3c. That source also credits Swapnil +Jain's two-stage development at ae405eb474d1486b2d8aef90139869f927f4836a. + +The contiguous corner method, incidence factorization and exact partition +certificates are due to Rohan Arun (PR #31), method commit +02f68f95369c39955c5ffcfddbd75cd83e26b305. The selected (25,23) certificate +specializes Dominik Scholz's parameterization (PR #33), +a499a345c040aa15b68e984a0904eadc485c7a7e. Their source notices and proof +snapshots are preserved in references/copied-centers. Historical OpenAI +Codex, GPT-6 Astra and Anthropic Claude Opus 5.5 assistance is credited to +the respective imported sources. Existing PR #21/#23 and RaD attribution, +licenses and the Gaussian correction remain in force. + +Copied centers with reversed (23,25) data corners, 2026-10-08 +Rohan Arun with substantial OpenAI Codex assistance supplies the composition, +exact dimension23 controls and cost/assembly integration. James Chang's PR34 +supplies the reversed boundary family; icekylinx's PR36 supplies copied retained +centers and the selected complex graph. The balanced assembly remains attributed +to RaD/hipotures and its PR34 specialization. Retain Dominik Scholz PR33, Rohan +Arun PR31, Zhihao Chen PR29/21/23, Paureel/Aurel Prosz, Swapnil Jain, icekylinx, +eumemic, Douglas Colkitt, OpenAI and all earlier notices and hypotheses. +This is not a claim of formal verification, new foundational rank identities, +global optimality or measured runtime speedup. + +Fixed middle basis with copied reversed corners (2026-10-08): +Rohan Arun, with substantial OpenAI Codex assistance. Composition and +simultaneous-basis proof retain icekylinx PR32/36, James Chang PR34, +Dominik Scholz PR35/38, Zhihao Chen, Paureel, Swapnil Jain, RaD/hipotures, +eumemic and all preceding attribution and licenses. See research/copied-fixed-reversed. + +Changed-graph composition with copied centers and fixed bases, 8 October 2026 +Prepared with OpenAI Codex assistance. +The new composition uses icekylinx PR36 copied centers and PR32 fixed-I+J +projectors/profiler, Dominik Scholz PR35 two fixed factors and CRT argument, +Zhihao Chen (jacklightChen) PR29/23 interfaces, Aurel Prosz (Paureel) and +Swapnil Jain's two-stage development, Rohan Arun PR25/31 corner methods, +Dominik Scholz PR33/38 dimension/composition work; James Chang (jamesyc) +PR34 reversed geometry and balanced transfer; Rohan Arun PR37/39/40 +reversed integration, modular data tests and both-fixed baseline; +RaD (hipotures) PR41 changed scalar DAGs, alternating point order and +independent role compiler; RaD balanced routing/bulk interfaces, and all +retained predecessors. +Complete attribution and the conditional proof boundary are recorded in +research/copied-fixed/PROOF.md; imported originals and source pins are retained. +Original Apache-2.0 and CC0 notices remain applicable. + +Community follow-up integration (PRs #49, #45 and #26), 8 October 2026: +Rohan Arun contributes weighted carrier matching and climbed summand/leave-one-out +orders (PRs #44/#47/#49), with Anthropic Claude assistance. The final construction +composes Chafik Boukhalfa's changed-graph checks, exact rational data recovery and +reordered exclusion sums (PRs #43/#46/#48, OpenAI Codex assistance) with RaD / +hipotures's alternating pair order and independent physical role compiler (#41). +All predecessor attribution and conditional proof interfaces remain in force. + +Alejandro Zarzuelo Urdiales contributes Gaussian parity and canonical arithmetic +proofs, finite tensor execution, profile precision accounting and mixed-center +reference checks (#45), with substantial OpenAI Codex assistance. See +research/gaussian-parity-synthesis/PROVENANCE.md for his full attribution. +Ryan S / princezuda contributes historical Lean certificate arithmetic, algebraic +frame/movement/guard lemmas and independent paired-circuit checks (#26). Original +source notices and historical snapshots are preserved. Neither formal package +claims a full formal proof of the multiplication algorithm or a new kappa. + +Joint frame compilation of skip-prefix strips + +The local compiler and exact finite witnesses were prepared by eumemic with +substantial OpenAI Codex assistance. Avi Eisenberg / ikeboy with Anthropic +Claude assistance supplied the unmodified PR #53 skip-prefix producer. +The pinned PR #48 pipeline is Chafik Boukhalfa's contribution, incorporating +Rohan Arun, RaD / hipotures, icekylinx, Dominik Scholz, James Chang, +Zhihao Chen, Aurel Prosz / Paureel, Swapnil Jain, eumemic, Douglas Colkitt, +OpenAI, David Harvey, Joris van der Hoeven and the earlier contributors +credited in the retained sources. See references/frame-compiler/pr48/NOTICE +and references/frame-compiler/pr53/NOTICE for their original attribution. +No authorship or review by those predecessors is claimed for this compiler. + +Joint dual-skip/frame-compiler composition (2026-10-08) +--------------------------------------------------- +Rohan Gupta / gupt1156 with Anthropic Claude assistance: PR55 dual-skip +scalar graph; original LICENSE and NOTICE are retained under +references/frame-compiler/pr55. eumemic with substantial OpenAI Codex +assistance: PR57 joint reversible frame compiler, serialized physical-word +replay and profile reconstruction. Chafik Boukhalfa with OpenAI Codex +assistance: this composition, independent integration and exact certificate. +Avi Eisenberg / ikeboy, Rohan Arun, RaD / hipotures, icekylinx, and all +predecessor authors retain the notices above and in pinned source files. +No original copyright or Apache-2.0 notice is removed. + +Ranked reclamation after the PR58 joint-dual composition (2026-10-08) +---------------------------------------------------------------- +Chafik Boukhalfa with OpenAI Codex assistance: prioritize retired physical +slots by descending current frame rank, retaining slot ID as the tie-breaker; +complete replay, exact profiles, comparison and adversarial controls. +The dedicated joint_dual_reclaim_compiler.py is derived from eumemic's PR57 +compiler. Its original shared compiler remains byte-identical. The PR55 +producer and all preceding attribution remain unchanged. The complete PR58 +comparison certificate and its original source/proof provenance are retained +under references/frame-compiler/pr58. + +Skip-prefix strip producer, 8 October 2026 +By Avi Eisenberg (ikeboy), with Anthropic Claude (Claude Opus 5.5) +assistance. The skip-prefix leave-one-out strip layout in +research/skip-strips/skip_graph.py is new. Everything else reuses Chafik +Boukhalfa's PR #43/#46/#48 research/copied-fixed pipeline, its verification +code, exact data recovery and support-order sorting, together with: +- Rohan Arun's PR #44 weighted carrier matching optimizer; +- RaD (hipotures) PR #41 alternating point order; +- every predecessor credited above. +Complete attribution and the conditional proof boundary are recorded in +research/skip-strips/PROOF.md. Original Apache-2.0 and CC0 notices remain +applicable. + +Local split-pair skip-prefix research continuation (2026-10-08) +Prepared with substantial OpenAI Codex assistance at the user's request. +New contribution: singleton/pair recursive partition refinement, finite summand +order and moment search, and verified composition with inherited paid clones. +Avi Eisenberg/ikeboy with Anthropic Claude assistance: PR53 skip-prefix strips. +Chafik Boukhalfa with OpenAI Codex assistance: PR54 original-envelope clone +specialization and PR43/46/48 checking interfaces. RaD/hipotures: PR51 +whole-chain/source-partition cloning and earlier producer/interfaces. +Rohan Arun: PR44 weighted matching and earlier fixed/reversed work, with all +stated historical AI assistance. All predecessor notices remain applicable. + +Original-envelope whole-chain clones on skip-prefix strips (research/skip-clones): +Chafik Boukhalfa, prepared with OpenAI Codex assistance. The complete-chain +source-partition clone operation is adapted from RaD / hipotures, PR #51, +with original envelopes retained here. The scalar base is Avi Eisenberg's +PR #53 skip-prefix layout, prepared with Anthropic Claude assistance. +All credited PR #43/#46/#48, PR #44 and earlier code/proof notices remain +in force. This extension is provided under the repository's Apache-2.0 terms. + +Community review checkpoint #50–#61, 8 October 2026 +Maintainer integration and independent arithmetic: Douglas Colkitt, with OpenAI Codex. +Avi Eisenberg / ikeboy: skip-prefix strip framework (#53), with Anthropic Claude. +Rohan Gupta / gupt1156: parallel order search (#50, stated Antigravity assistance) +and dual-suffix strips (#55, Anthropic Claude assistance). +Eumemic: equal-frame joint compilation and paid signal reclamation (#57), with Codex. +Chafik Boukhalfa: original-envelope paid clones (#54), composition (#58) and ranked +reclamation (#60), with Codex. Rohan Arun: order search (#52) and positive-frame +composition (#56), with Anthropic Claude and stated Codex validation assistance. +RaD / hipotures: enlarged frames, source partitions and paid whole-chain clones +(#51), with Codex. Rohan Garg / rohangar1: singleton/pair recursion and paid-clone +composition (#59), with Codex. Alejandro Zarzuelo Urdiales: exact parameter +refinement, scoped Lean arithmetic, matrix/parity and search tools (#61), with +his disclosed multi-tool and Codex assistance. +Parallel #50/#52 records are reviewed and credited without replacing the earlier +climbed-48 implementation; their exact commit history is retained. The separate +#51 witness is retained as research; its source-graph/negative-basis data proof +has not received the same full replay as #56's consumed compiler machinery. +See docs/research/community-round2-review.md for precise validation boundaries. +All earlier licenses, contributions and notices remain applicable. + +Interval strips and core-aware pair assembly + +The interval leave-one-out strips and the core-aware group-pair assembly in +research/pair-assembly were prepared by Avi Eisenberg / ikeboy with Anthropic +Claude assistance. They build on PR #53's skip-prefix pipeline and its +inherited PR #48 sources. The stacked witness in research/pair-assembly/frame +uses eumemic's PR #57 joint frame compiler unchanged; its driver and verifier +are adaptations of PR #57's skip_frame_compiler.py, skip_frame_compose.py and +verify_skip_frame.py. Original notices are retained. + +Stopped product-ring extension, 9 October 2026 +Copyright 2026 icekylinx + +The opposite-bank generic projector factorization, componentwise atom-ring +adapters, stopped recurrence and outer ordinary-interchange conversion, +aligned pair-star producer with rational centers, exact denominator-21 +grid and selected (23,23)/(24,24) composition are contributed by icekylinx +with substantial OpenAI GPT-6 Astra and Codex assistance. This extension +builds on merged PR #36, 11817ccacb564bb7f98789c20dc11d3fece207e3, and is +integrated on upstream main 56b66d58297deca1d7dd130247d720e960f77a37. + +The retained ordinary leaf uses the preceding projector, corner and +copied-center proofs. The selected two-stage topology retains Aurel Prosz +(Paureel), Swapnil Jain and Zhihao Chen's credits; the semantic assembly +retains PR #21/#23 and RaD's attribution. Paired producers, carrier matching, +original source notices and each imported license remain unchanged. + +Partial-gauge extension, 9 October 2026 +Copyright 2026 icekylinx + +The pair-first cube assembly, compatible backward frame enlargement, +partial source-gauge schedule and stopped whole-projector composition are +contributed by icekylinx with substantial OpenAI GPT-6 Astra and Codex +assistance, extending PR #104 at 948ce1510df750f4c18b96bdaef436a86f8bf834. + +The physical deferred bit word, reflected event accounting, fan-order +clarification and signed two-stage endpoint are adopted from Zhihao Chen +(jacklightChen), PR #97, e15350b66e4bf796153a68c240a6cc1b788abe3e, with +Codex assistance. Its deferred readouts, V leaves, lifted frames and frozen +witness originate in Swapnil Jain's 741e7aa078392553815df7926ee17ac5e25a8c38, +with the original Claude disclosure retained. Cyclic interval and core-aware +pair primitives build on Avi Eisenberg (ikeboy), PR #62, +ad0f25ff7b23cff7f08ad237c2254e6ecf74257e, with Anthropic Claude assistance. +Prior two-stage, copied-center, ordinary-leaf, semantic/bulk, routing and +precision credits remain in force. Imported source notices and licenses +are preserved under references/partial-gauge/; see SOURCES.json. + +Three-stage cover extension, 9 October 2026 +Copyright 2026 icekylinx + +The arbitrary-subspace Clifford frame theorem, three-stage Cayley geometry, +weighted q-adic GL cover, unit-lower weighted compiler, charged local-ring +fallback, uniform batching, internal row borrowing and exact composition +are contributed by icekylinx with substantial OpenAI GPT-6 Astra assistance. This +repository integration uses Codex assistance and extends +PR #115, cf60442983c153a3a0f5272ea4713f99eba13c86. + +The selected local complex DAG and support/label replay are adopted from +Copyright 2026 eumemic, PR #117, cbb05ce504d571546d9b7794c186a613c659c3bf, +with its original Apache-2.0 terms and Claude assistance disclosure. +The unchanged bit physical word retains Zhihao Chen (jacklightChen), +PR #97, and Swapnil Jain's underlying witness and assistance notices. +The prior opposite-bank, stopped ordinary-leaf, copied-center, topology, +semantic/bulk, precision and analytic credits remain applicable. +Original source notices and license bytes are preserved in +references/three-stage-cover/pr117/ and references/partial-gauge/. + +Paired-cube and shared-core extension, 9 October 2026 +Copyright 2026 icekylinx + +The paired-coordinate triple-cube identity, signed overlap channels, +original-source involution, coordinate-star centers, concrete frame/carrier +compiler, chronological source gauges, PR97 gauge-subset selection, +orthogonal cross-stage routing and exact supplier/assembly integration +are contributed by icekylinx with substantial OpenAI GPT-6 Astra assistance. +Repository integration uses Codex assistance and extends PR #130 at +6a9970a530119174507904e23592fd59ede19a5d. + +The substantial completed-core workspace-sharing principle is credited to +an664, PR #128, 530588a019b4a74f09180680c9e3961bf649ec89, with its reported +OpenAI Codex assistance. No source code, partition or serialized witness +from that PR is imported. The new routing and paired-motif integration +are described separately and claim no exclusive priority for broad sharing, +paired-coordinate, Fourier or carrier-matching ideas. + +Selected coarse queries restrict the retained eumemic PR #117 positive DAG; +its original Apache-2.0 and Claude assistance notices remain unchanged. +The bit word and original frames retain Zhihao Chen's PR #97 and Swapnil +Jain's frozen witness, notices and historical assistance disclosures. +Earlier generalized Clifford, three-stage, uniform weighted recursion, +ordinary-leaf, semantic/bulk, precision and analytic credits remain in force. +Source-specific license bytes are preserved under references/. + +October 9 recycled-bit integration: +DaysSky (#150), William Porter/hpst3r (#147), Thomas Marchand/Th0rgal (#146), +Rohan Gupta/gupt1156 (#148), James Chang/jamesyc (#124), SovereignSteak (#122). +The original notices and assistance disclosures are retained under research/, +including research/recycled-bit-integration/NOTICE. Andrew Barnes/Bortlesboat +(#101) repairs shared verifiers using rfu08's #64 counterexample. rfu08's +scoped finite and formal-transfer packages are included separately; they do +not establish the full multiplication theorem. Earlier and parallel credits +remain applicable. Douglas Colkitt integrated these with OpenAI Codex assistance. + +SovereignSteak PR151 independently supplies the matching gauge/recycling +composition and the selected 473/10^6 atom refinement; its original package +and assistance disclosure are retained under research/gauge-recycling/. + +October 9 coordinated-frame and completed-entrance-bank integration: +Dugongue PR186, 166a34d75e853e933855f0f7e940fe77c4bb6b8d, builds on +Chafik Boukhalfa/chafreaky's PR181, 7fb2194801e3a10f54772c7f0d5505035a4fc0ad, +and eumemic's PR168 v4, 4a3c769e5c5430e7114c4d3e099ff34664677f17. +The frozen package and prerequisite archive preserve all author, source-license +and assistance notices, including PR175's compiler optimization. DaysSky's +carrier closure, James Chang's terminal substitution and balanced assembly, +geckods' stopping refinements and all preceding framework credits remain. +Rohan Arun's PR185 bootstrap and chafreaky's PR182 bit refinement are reviewed +parallel contributions; their gains are not added to the selected witness. +Douglas Colkitt integrated the package and supplied the bank scheduling +supplement with OpenAI Codex assistance, under Apache-2.0. The all-size +interfaces remain conditional; finite verification is not full formalization. diff --git a/research/p104-banked-cf6a-splits/credits/OUTER-GATE-NOTICE b/research/p104-banked-cf6a-splits/credits/OUTER-GATE-NOTICE new file mode 100644 index 0000000000..1bc9b4da2b --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/OUTER-GATE-NOTICE @@ -0,0 +1,13 @@ +# Attribution and source reuse + +New independent operator/invoice verification and fixed-grid interval implementation: OpenAI Codex-assisted research session, 2026-11-10. Apache-2.0. + +DreamingOfClouds supplied the #6936 native predecessor and #6937 shared-wire backup/E-free root. CubeJerry supplied #6912 caller blocks, #6980's QUERY-only caller and #6970/#6985 precision methods. Preserve Ali Romman's #5599 helper-split attribution, icekylinx's #104 odd-grid attribution and unpaidmoon's #6930 width-phase attribution in the parent construction. + +Three unchanged source files are authenticated by exact SHA256 and source commit/path in `INDEPENDENT-SOURCES.json`: + +- #6970 `independent_bounds.py`: fixed integer-grid and positive caller-transfer engine. +- #6985 `envelopes.py`: positive forward envelopes and backward covector witnesses. +- #6985 `source_binding.py`: retained helper functions for the envelope engine. + +The adapter applies only two literal helper-census substitutions in memory and records them. It does not call that adaptation an independent mathematical implementation. The new reverse native operator, formal caller ring and elementary interval engine do not import the source authors' operator or invoice checkers. diff --git a/research/p104-banked-cf6a-splits/credits/PR7663-NOTICE b/research/p104-banked-cf6a-splits/credits/PR7663-NOTICE new file mode 100644 index 0000000000..6ce1bc49a3 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7663-NOTICE @@ -0,0 +1,7 @@ +Apache-2.0. Ali Romman with substantial OpenAI Codex assistance. + +The new material is the joint chart assignment, its source-bound operator and caller checks, and the fresh-cost complete-root scalar and private-bank specialization. The parent data are from Clear1nsight's PR #7660 on DreamingOfClouds' PRs #7658 and #7641 and SYLforge's PR #7637. The contributors credited in those sources retain their credit. Original notices are in source/parent-NOTICE, source/physical-NOTICE and source/word-NOTICE. + +Rohan Arun supplied the 17-stage signed caller in PR #7113. The unmodified interval gate and the exact caller data come from its pinned source. See source/caller-NOTICE and source/independent-NOTICE, and the source file inventory for all consumed bytes. The two operator engines and integer power evaluator come from the declared current-main inputs. + +Jerry Chen (CubeJerry) supplied selected PRs #7000 and #7001. The selected application and its phase, common-root, finite-cost and compiler arguments, the odd-native common-grid package, the prior typed six-Gamma reset of PR #7586 and the contributors credited in those records provided the foundations used here. PR #7661 independently derives the fixed caller residuals. PR #7662 supplies a rounded parent-clock alternative. This package uses neither implementation. diff --git a/research/p104-banked-cf6a-splits/credits/PR7669-PROVENANCE.md b/research/p104-banked-cf6a-splits/credits/PR7669-PROVENANCE.md new file mode 100644 index 0000000000..bbee2437f0 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7669-PROVENANCE.md @@ -0,0 +1,43 @@ +# Provenance, credit and scope + +This is a cumulative contribution. Thank you to everyone who has made their constructions, exact inputs, failure cases and careful reviews available. Those contributions made this composition possible; the small increment here should not obscure the much larger body of work it rests on. We aim to leave equally inspectable material for the next researcher. + +## Direct lineage and reused methods + +- **SYLforge, #7637:** the H5B frame-restored233-CLEAR construction is the published ancestor of this research. The present K372-2 source retains its descendants rather than starting a new independent construction. [PR7637](https://github.com/CrocSwap/integer-mult-bounds/pull/7637). +- **DreamingOfClouds, #7641 and #7658:** #7641 combines20 edits over #7637. #7658 supplies the large-neighbourhood construction and its exact joint hub reconstruction: helper360/537 SWAP-NULL relabel, main176 bypass, helper236 contact re-chart, helper370 last-stay removal and helper461 first-stay removal. The source explicitly credits its #7630/#7636 relabel lineage and #7634 swap law. Our source descends from this word; those gains are not claimed as new work here. [PR7641](https://github.com/CrocSwap/integer-mult-bounds/pull/7641), [PR7658](https://github.com/CrocSwap/integer-mult-bounds/pull/7658). +- **Clear1nsight:** the contact re-chart type from #7612 and the24-bit coefficient-splitting report are part of the construction's lineage. #7626 contributed source isolation/portable materialization, and #7631/#7633 are credited by the parent lineage. #7660 separately published the role379 shortcut already present in our source; we do not count its rediscovery as another improvement. [PR7612](https://github.com/CrocSwap/integer-mult-bounds/pull/7612), [coefficient report](https://github.com/CrocSwap/integer-mult-bounds/discussions/7111#discussioncomment-19691406), [PR7660](https://github.com/CrocSwap/integer-mult-bounds/pull/7660). +- **ToikY, #7643:** the contact re-chart work is explicitly credited by #7658 alongside Clear1nsight's #7612. Its74-erasure contract and κ are not added to this candidate. No shared CI repair is copied by this PR. [PR7643](https://github.com/CrocSwap/integer-mult-bounds/pull/7643). +- **Rohan Arun, #7113:** the signed caller/accounting lineage underlies the actual16-call composition. Its original source commit is07a76c5e2738882c0cb322278e56f6cae3c9885d. We recount the literal16-call input here; we do not substitute historical17-call constants. [PR7113](https://github.com/CrocSwap/integer-mult-bounds/pull/7113). +- **Ali Romman and upstream contributors:** #7605 supplies an earlier exact protected/application checkpoint cited by the #7637 lineage. The two unmodified directed invoice comparison files are copied from canonical upstream base e54523517d0f03e58352e647c403a5af3e525a57, retaining their attribution and Apache-2.0 headers. Their arithmetic is not a full scientific acceptance gate. [PR7605](https://github.com/CrocSwap/integer-mult-bounds/pull/7605). +- **CubeJerry, Douglas Colkitt and the earlier source contributors:** the retained framework, primitive/service work and repository infrastructure form part of the inherited basis. This package does not claim that their open supplier obligations are resolved by a successful finite replay. + +## What this contribution adds + +The predecessor K372-2 supplies five EARLY edits (1188,1013,940,1141,1195, with940/1141 sharing one ADD). This construction recomputes the1517/770 bypass on that actual source and combined it with a three-field triangle repair. The new contribution is their compatible composition, exact12-block edit, final235 CLEAR witnesses and a small reproducible publication package. Substantial OpenAI Codex assistance was used for research and packaging. New work is Apache-2.0. + +Exact source canonical:3dd1199d95291ee96e6c0aeb6f55f86244a569b1d4975840bf0207e2dcf9c025. Exact candidate canonical:ee251f6005d2a92b887c5b804bd7aac05989d278b2c9ccb3c3091b50d533b08d. Byte hashes are in MANIFEST.json. The12 edit blocks specify every changed event and leave all other fields unchanged. The parent research generators are not silently imported; this publication uses the transparent exact edit as its deterministic reconstruction recipe. + +## Related work, not automatically incorporated + +Ali Romman's #7662 studies one half-ADD rounding-error propagation with CubeJerry's service contract. Nick Petalas's #7654 provides a scoped minimal-rank interpolation result used as background when assessing structural repairs. Neither is a substitute for this candidate's entire rounded caller or physical supply proof. Their actual domains and assumptions must be checked before application. [PR7662](https://github.com/CrocSwap/integer-mult-bounds/pull/7662), [PR7654](https://github.com/CrocSwap/integer-mult-bounds/pull/7654). + +At the publication checkpoint, upstream main remained e54523517d0f03e58352e647c403a5af3e525a57. Ali Romman's #7663 uses a separate17-call full-private-bank model and changed helper endpoints; Clear1nsight's #7664 concerns180erasures/17calls; #7666 charges bank selection and return without claiming a new κ. K372-4 is later, separate research with changed helper-boundary conditions. None is silently folded into ee251f60 or used to assert identical physical assumptions. This is not a claim to the greatest bound across all models. + +## Fresh versus reused evidence + +Publication replay freshly reconstructs the whole word, runs exact rows/CLEAR, recounts native/caller histograms and checks the four directed price points. Normal, optimized Python and a Git-free committed-byte export were tested. The recorded ordinary/precision/native-phase/owner evidence retains its narrower scope and original source identifiers; it is not advertised as freshly rerun. No selected record, frozen predecessor package or common verifier is changed. + +## Editorial normalization of publication labels + +The follow-up editorial commit replaces workstation labels with construction terminology. It changes no candidate, edit, certificate, invoice, numeric result, executable code or contributor attribution. The original recorded bytes remain retrievable at commit `95d476623f1468822057554475dc8badb19bfa44`. Evidence JSON field labels and descriptive scopes are normalized, not recomputed scientific results. In NATIVE-EVIDENCE-REUSE.json, `predecessor-receipt:K372-2/NATIVE-NEW.json` is a historical receipt identifier, not a packaged file path. In PRICE-SUMMARY.json, recorded command invoice arguments now use the equivalent packaged `data/INVOICE.json` path; this is a portability transcription, not the verbatim original command. The fresh replay constructs and runs its own package-relative command. MANIFEST.json authenticates the edited publication bytes. + +Evidence byte-custody mapping (original -> editorially normalized SHA-256): + +- `evidence/BUILD.json`: `4744201691120223ded62a3e0d55ea1029203f3ea996305163e7db8d9e3679a4` -> `a0bafbb3f44920ed6ac1ed3d83385f025f5bbbcf5e9c8013ab1ca55ccf23c32d`. + +- `evidence/NATIVE-EVIDENCE-REUSE.json`: `6615b8a051ac9e4d8c73b5decf8a70d2a33d14da0c4c369574dec946984aa351` -> `84bab14d5c584aa8853b8e1025b562541ac6657e458d120ec803f2bc149c3eb8`. + +- `evidence/ROLE770-BUILD.json`: `c4ee72317678791d4b801479df0af052f3a50662c11ce3f3393b2151368fc92d` -> `1c400f16efbc427c40c811a57dc656fe97c2c84f94c71529e2c5c0598b146369`. + +- `evidence/PRICE-SUMMARY.json`: `c2777382c677634f7017b68c55dbd831a40945b77057f26b738f857c17ee8759` -> `d13741fe3217a01edd0b79b40dad037e644e441fbbc300838df99c0b050a5f42`. diff --git a/research/p104-banked-cf6a-splits/credits/PR7674-NOTICE b/research/p104-banked-cf6a-splits/credits/PR7674-NOTICE new file mode 100644 index 0000000000..951f081717 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7674-NOTICE @@ -0,0 +1,7 @@ +Apache License 2.0. Research prepared for Ali Romman with substantial OpenAI Codex assistance. + +New work includes the fifteen certified sender/receiver pivots, the forward and transposed communication construction, the complete native row checker, and the finite stock and precision application for this 16-call program. + +SYLforge supplied the composition, native word reconstruction, published invoice and exact 16-stage caller bytes from PR #7669. Their original PROVENANCE.md is preserved in source/7669-CREDITS.md. It credits the H5B work of SYLforge, DreamingOfClouds' joint native reconstructions, Clear1nsight's coefficient splitting, role-379 and helper work, Rohan Arun's signed caller lineage, and prior contributions from CubeJerry, Douglas Colkitt and others. The source/ directory holds the exact file bytes identified in SOURCE-PINS.json. + +The group-ring caller checker, independent operator checks, bit service, finite-cost method and field guide adapt the corresponding code and arguments of Ali Romman's PR #7663. That package in turn builds on the contributors named in its preserved source/7663-NOTICE. The unchanged directed log/exp gate retains its listed sources in source/gate-NOTICE. Earlier paid-transfer and bank-support constructions include PRs #7434 and #7576. Jerry Chen (CubeJerry) supplied the selected PRs #7000 and #7001 and the typed initializer in PR #7586. The per-call odd-grid induction and the selected application review provide the complete-root realization and finite-cost substitution. Douglas Colkitt and the credited repository authors supplied the pinned operator engines, price evaluator and research workflow. The license accompanies this package. diff --git a/research/p104-banked-cf6a-splits/credits/PR7682-NOTICE b/research/p104-banked-cf6a-splits/credits/PR7682-NOTICE new file mode 100644 index 0000000000..4654631de0 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7682-NOTICE @@ -0,0 +1,9 @@ +Apache License 2.0. Research prepared for Clear1nsight with substantial OpenAI Codex assistance. + +Ali Romman supplied the fifteen exact banked pivots and the frozen #7674 baseline, along with the complete signed 16-call graph and application method. The original notices remain at peer/NOTICE, peer/source/7663-NOTICE and peer/source/gate-NOTICE. Read peer/SOURCE-PINS.json for each ancestry binding and ASSETS.json for the exact vendored bytes at scientific commit 26b6c469aa6c4aa04322ce25a22150f90e5fb14e and refreshed head 28b2af322a1fab01b3734365988930920f9dda48. + +SYLforge supplied the #7669 composition, native source pins and literal caller. Its preserved parent provenance is peer/source/7669-CREDITS.md. Retain DreamingOfClouds' #7641/#7658 lineage, Clear1nsight's integer scalar/contact work including #7612, ToikY's #7643 contact-rechart precedent, Rohan Arun's #7113 signed-caller lineage, 5080's helper work, and all other contributors named in the original records. Ali Romman's #7663 exact-grid and extent proof and #7666/#7670 selection and guide work supply relevant implementation precedents. Jerry Chen (CubeJerry) supplied the selected #7000/#7001 applications and #7586 typed initialization. Douglas Colkitt and the authors in the original notices supplied the frozen native compiler, independent checker, price evaluator and package infrastructure. + +The release base reuses ToikY's exact shared CI and historical replay sync 0eabc624a9bc9ed2847719efd63390db4d297df4 above canonical e54523517d0f03e58352e647c403a5af3e525a57. This workflow provenance is separate from the banked construction and its mathematical comparison. + +This package credits the original role-230 splice and its same-contract transfer to the unchanged fifteen-pivot graph, the independent exact wire and price replays, matched complete resource accounting and source-bound native and caller verification. The original works retain their authorships and licenses. diff --git a/research/p104-banked-cf6a-splits/credits/PR7704-NOTICE b/research/p104-banked-cf6a-splits/credits/PR7704-NOTICE new file mode 100644 index 0000000000..7d2dfec60a --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7704-NOTICE @@ -0,0 +1,5 @@ +Apache License 2.0. Prepared for Clear1nsight with substantial OpenAI Codex and ChatGPT Pro assistance. + +SYLforge supplied the cf6a nine-swap word and its normalized verification in #7700. DreamingOfClouds contributed the #7641 and #7658 swap searches. Ali Romman supplied the changed helper contract in #7663 and the charged bank construction in #7674. Rohan Arun and the #7113 lineage supplied the signed caller. The bank, native, physical and directed price methods reuse work by Ali Romman, SYLforge, Clear1nsight and the contributors credited in #7669, #7682 and #7697. Jerry Chen (CubeJerry) supplied the selected #7000 and #7001 application. Douglas Colkitt and the recorded authors supplied the selected framework, compiler, checker and package infrastructure. + +This contribution identifies and contracts the two paid transfers on helper 1256, reconstructs the banked graph from the supplied source, and checks the resulting physical application and complete signed price. The separate investigation and technical review were performed with Codex agents. Preserve the original notices and citations in credits/ when redistributing the source data or derived engines. See SOURCES.json for pinned upstream inputs and ASSETS.json for file-level custody. diff --git a/research/p104-banked-cf6a-splits/credits/PR7705-NOTICE b/research/p104-banked-cf6a-splits/credits/PR7705-NOTICE new file mode 100644 index 0000000000..2a92a9df69 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7705-NOTICE @@ -0,0 +1,7 @@ +Apache License 2.0. Research prepared by DreamingOfClouds with Claude Opus 5.5 (Anthropic), via Claude Code. + +The contribution is the hub-reroute construction: its search, the exact builder, the 21 reroutes and the checks in this package. All code here is newly written, and predecessor packages were read as data only. + +Clear1nsight supplied the chart-595 helper split (PR #7697) and the role-230 rechart (PR #7682), which is the first hub reroute. Ali Romman supplied the banked-transfer circuit and its fifteen pivots (PR #7674). SYLforge supplied the #7669 word and the signed sixteen-call caller. DreamingOfClouds, Rohan Arun, Jerry Chen (CubeJerry), Douglas Colkitt and the authors credited in the inherited notices supplied predecessor constructions, the selected framework and the repository infrastructure. + +The exact predecessor notices are in `credits/`. `source/` holds the K372-2 word, the twelve #7669 edits and the 16-call caller as published with #7669. `ASSETS.json` binds every package file. diff --git a/research/p104-banked-cf6a-splits/credits/PR7708-NOTICE b/research/p104-banked-cf6a-splits/credits/PR7708-NOTICE new file mode 100644 index 0000000000..4a24e9bcb7 --- /dev/null +++ b/research/p104-banked-cf6a-splits/credits/PR7708-NOTICE @@ -0,0 +1,7 @@ +Apache License 2.0. Prepared for Ali Romman with substantial OpenAI Codex assistance in research, implementation, verification and writing. + +This contribution supplies the ordered 46-cut certificate on the exact #7704 graph, the source and receiver recoding with scalar feedback, its 3 witnesses, the composition checks and the signed application. + +SYLforge supplied the nine-swap source word in #7700. DreamingOfClouds and SYLforge supplied the preceding native searches. Clear1nsight supplied the #7704 role-1256 contraction and the open pivot-combination question, the #7682 role-230 reroute and the #7697 chart-595 split. DreamingOfClouds supplied the grouped hub mechanism in #7705 on a different graph. Ali Romman supplied the banked transfer pivots and catalogue method in #7674 and the predecessor common-grid construction in #7663. Rohan Arun supplied the signed caller lineage. Jerry Chen (CubeJerry) supplied the selected complex application and BIT input. Douglas Colkitt and the credited repository contributors supplied the source framework, compiler, operator engines, comparison tools and research infrastructure. + +The files under vendor/ and data/ retain their published bytes. SOURCE-PINS.json identifies each original file and commit. The catalogue checker adapts the #7674 checker to the new graph and adds signed contact checks. The independent operator producer and checker and the directed invoice tools come from the canonical source files in SOURCES.json. The original supplier notices, including those for the outer gate, are under credits/. Preserve these notices with the reused material. diff --git a/research/p104-banked-cf6a-splits/data/CIRCUIT.json.gz b/research/p104-banked-cf6a-splits/data/CIRCUIT.json.gz new file mode 100644 index 0000000000..ff9e73a2aa Binary files /dev/null and b/research/p104-banked-cf6a-splits/data/CIRCUIT.json.gz differ diff --git a/research/p104-banked-cf6a-splits/data/SPLITS.json b/research/p104-banked-cf6a-splits/data/SPLITS.json new file mode 100644 index 0000000000..884aaa09b2 --- /dev/null +++ b/research/p104-banked-cf6a-splits/data/SPLITS.json @@ -0,0 +1,9 @@ +{ + "parent": "#7708 circuit (rebuilt from the #7700 cf6a word, the #7704 relay and the 46 published #7708 cuts)", + "group": {"entrance_chart": 3, "exit_chart": 127, "rank": 9}, + "splits": [ + {"chart": 498, "retired_role": 126, "retired_role_new_exit": 498, "fresh_role": 1501, "fresh_role_route": [498, 127], "target_ranks": [4, 5]}, + {"chart": 480, "retired_role": 239, "retired_role_new_exit": 480, "fresh_role": 1502, "fresh_role_route": [480, 127], "target_ranks": [2, 7]}, + {"chart": 595, "retired_role": 281, "retired_role_new_exit": 595, "fresh_role": 1503, "fresh_role_route": [595, 127], "target_ranks": [1, 8]} + ] +} diff --git a/research/p104-banked-cf6a-splits/source/CALLER.json.gz b/research/p104-banked-cf6a-splits/source/CALLER.json.gz new file mode 100644 index 0000000000..26a75a1ae3 Binary files /dev/null and b/research/p104-banked-cf6a-splits/source/CALLER.json.gz differ diff --git a/research/p104-banked-cf6a-splits/source/WORD.json.gz b/research/p104-banked-cf6a-splits/source/WORD.json.gz new file mode 100644 index 0000000000..890579b0b7 Binary files /dev/null and b/research/p104-banked-cf6a-splits/source/WORD.json.gz differ diff --git a/research/p104-banked-cf6a-splits/tools/bank.py b/research/p104-banked-cf6a-splits/tools/bank.py new file mode 100644 index 0000000000..eaa47875c2 --- /dev/null +++ b/research/p104-banked-cf6a-splits/tools/bank.py @@ -0,0 +1,185 @@ +#!/usr/bin/env python3 +"""BANK: own fold + pivot + histogram tool for banked-transfer circuits (lane BANK, Nov 18). +Network: tokens >=0 are MOVE event indices (paid slots, value = sent form), tokens <0 are inputs ~r. +forms[node] = {token: Fraction}; node = move index (form sent) or FIRST+r (terminal r). +moves[k] = (src_chart, dst_chart). Paid hist = Counter |dim dst - dim src| over moves (pricekit rule).""" +import gzip, json, sys, os +from collections import Counter, defaultdict +from fractions import Fraction as Q +sys.path.insert(0, os.path.dirname(os.path.abspath(__file__))) +import pricekit as pk + +def load(p): + return json.load(gzip.open(p, 'rt') if p.endswith('.gz') else open(p)) + +class Net: + def __init__(s, first, init, final, moves, forms): + s.first, s.init, s.final, s.moves, s.forms = first, init, final, moves, forms + def chart_of_node(s, k): # chart where node's form is evaluated + return s.moves[k][0] if k < s.first else s.final[k - s.first] + def chart_of_tok(s, t): # chart where token's value is available + return s.init[~t] if t < 0 else s.moves[t][1] + def copy(s): + return Net(s.first, s.init, s.final, dict(s.moves), dict(s.forms)) + +def axpy(row, src, a): + for k, v in src.items(): + w = row.get(k, 0) + a * v + if w: row[k] = w + else: row.pop(k, None) + +def fold(W): + n = W['public']; N = n + W['owned_fields'] + rows = [{~r: Q(1)} for r in range(n)] + [None] * W['owned_fields'] + ch = list(W['initial']) + [None] * W['owned_fields'] + moves, forms = {}, {} + for i, e in enumerate(W['program']): + op, r = e[0], e[1] + if op == 'INIT': rows[r], ch[r] = {}, e[2]; continue + if op == 'MOVE': + assert ch[r] == e[2] + moves[i] = (e[2], e[3]); forms[i] = rows[r]; rows[r] = {i: Q(1)}; ch[r] = e[3] + elif op == 'CLEAR': assert ch[r] == e[-1]; rows[r] = ch[r] = None + elif op == 'SCALE': + assert ch[r] == e[-1]; c = Q(e[2]); rows[r] = {k: v * c for k, v in rows[r].items()} + elif op == 'ADD': + assert ch[r] == e[-1] == ch[e[2]] and e[2] != r + rows[r] = dict(rows[r]); axpy(rows[r], rows[e[2]], Q(e[3])) + else: raise ValueError(op) + assert ch[:n] == W['final'] + first = len(W['program']) + for r in range(n): forms[first + r] = rows[r] + return Net(first, list(W['initial']), list(W['final']), moves, forms) + +def transpose(net): + f = net.first + def rv(x): + if x < 0: return f + ~x + if x >= f: return ~(x - f) + return x + forms = {k: {} for k in net.moves}; forms.update({f + r: {} for r in range(len(net.init))}) + for node, row in net.forms.items(): + for d, c in row.items(): forms[rv(d)][rv(node)] = c + return Net(f, net.final, net.init, {k: (b, a) for k, (a, b) in net.moves.items()}, forms) + +def schedule(net): + """locality + acyclicity; returns a topological order of nodes.""" + indeg = {k: 0 for k in net.forms}; out = defaultdict(list) + for k, row in net.forms.items(): + c = net.chart_of_node(k) + for d in row: + assert net.chart_of_tok(d) == c, ('nonlocal', k, d) + if d >= 0: indeg[k] += 1; out[d].append(k) + order = [k for k, v in indeg.items() if v == 0]; i = 0 + while i < len(order): + for m in out[order[i]]: + indeg[m] -= 1 + if indeg[m] == 0: order.append(m) + i += 1 + assert len(order) == len(net.forms), 'cycle' + return order + +def pivot(net, drop, lead, F, gamma, sender, receiver): + """PROOF s1 algebra (own implementation). gamma/sender/receiver: {token: Fraction}.""" + B = net.moves[drop][1] + uses = {m: row[drop] for m, row in net.forms.items() if drop in row} + C = net.moves[lead][1] + assert lead in gamma and set(gamma) <= set(uses) + assert all(m < net.first and net.moves[m] == (B, C) for m in uses), 'readers not all B->C' + Y = {} + for m, g in gamma.items(): axpy(Y, net.forms[m], g) + s = Y.get(drop, 0); assert s + forms = dict(net.forms); del forms[drop]; forms[lead] = dict(sender) + for m, a in uses.items(): + if m != lead: + r = dict(net.forms[m]); axpy(r, Y, -a / s); assert drop not in r; forms[m] = r + YC = {lead: Q(1)}; axpy(YC, receiver, Q(-1)) # Y recovered at C = W - D + rec = {} + for m, a in uses.items(): + r = {k: -v / gamma[lead] for k, v in gamma.items() if k != lead} if m == lead else {m: Q(1)} + axpy(r, YC, a / s); rec[m] = r + for k, row in list(forms.items()): + hit = row.keys() & rec.keys() + if hit: + new = {i: v for i, v in row.items() if i not in hit} + for i in hit: axpy(new, rec[i], row[i]) + forms[k] = new + moves = dict(net.moves); del moves[drop]; moves[lead] = (F, C) + return Net(net.first, net.init, net.final, moves, forms) + +def apply(net, direction, *a): + if direction == 'transpose': return transpose(pivot(transpose(net), *a)) + return pivot(net, *a) + +def hist(net, dim): + return +Counter(r for r in (abs(dim[b] - dim[a]) for a, b in net.moves.values()) if r) + +# ---------------- values mod p (numpy) for endpoint checks and search +P1 = 2147483629 +def inv(x, p): return pow(x, -1, p) +def fmod(q, p): return q.numerator % p * inv(q.denominator % p, p) % p + +def values(net, p=P1, order=None): + import numpy as np + n = len(net.init); order = order or schedule(net); V = {} + for k in order: + v = np.zeros(n, dtype=np.int64) + for d, c in net.forms[k].items(): + cm = fmod(c, p) + if d < 0: v[~d] = (v[~d] + cm) % p + else: v = (v + cm * V[d]) % p + V[k] = v + return V + +def terminals_equal(n1, n2, p=P1): + import numpy as np + V1, V2 = values(n1, p), values(n2, p) + return all(np.array_equal(V1[n1.first + r], V2[n2.first + r]) for r in range(len(n1.init))) + +# ---------------- pricing +CALLER = os.environ.get('BANK_CALLER', os.path.join(os.path.dirname(os.path.abspath(__file__)), '..', 'source', 'CALLER.json.gz')) +def price(W, paid, digits=16): + base = pk.native_from_word(W) + nat = pk.native_from_hist(dict(paid), dict(base['T']), base['Dports']) + C = pk.load(CALLER); inv_ = pk.invoice(pk.caller_invoice(C), nat) + return pk.price(inv_, digits), inv_ + +def edits_from_pivots(path): + out = [] + for e in load(path): + cv = lambda L: {int(k): Q(v) for k, v in L} + out.append((e['direction'], e['remove'], e['pivot'], e['source_chart'], + cv(e['combination']), cv(e['sender']), cv(e['receiver']))) + return out + +if __name__ == '__main__': # control: reproduce #7674 from t7669 + their 15 pivots (DATA file) + W = load(sys.argv[1]); dim = [len(f) for f in W['frames']] + net0 = fold(W); schedule(net0); h0 = hist(net0, dim) + pr0, _ = price(W, h0); print('parent paid', sum(h0.values()), pk.kstr(pr0['kappa'], 16), 'S', pr0['S']) + net = net0 + for ed in edits_from_pivots(sys.argv[2]): + d, drop, lead, F = ed[:4] + rb = (abs(dim[net.moves[drop][1]] - dim[net.moves[drop][0]]), abs(dim[net.moves[lead][1]] - dim[net.moves[lead][0]])) + net = apply(net, d, drop, lead, F, *ed[4:]); schedule(net) + print(d, drop, lead, 'ranks drop,lead_old', rb, '-> lead_new', abs(dim[net.moves[lead][1]] - dim[net.moves[lead][0]])) + h = hist(net, dim); dh = {r: h[r] - h0[r] for r in set(h) | set(h0) if h[r] != h0[r]} + print('paid', sum(h.values()), 'delta per native', dict(sorted(dh.items()))) + print('terminals equal mod p:', terminals_equal(net0, net), terminals_equal(net0, net, 2147483587)) + pr, inv_ = price(W, h, 20); print('kappa', pk.kstr(pr['kappa'], 18), 'S', pr['S'], pk.cite('t7669+15piv', pr)) + import pickle; pickle.dump(net, open(os.path.join(os.path.dirname(__file__), 'net7674.pkl'), 'wb')) + +def price_net(W, net, dim, digits=20): + """PRICEKIT price with helper targets taken from the circuit's own boundary (width may differ from W).""" + h = W['hosted']; mains = set(W['live']) | {r + 112 for r in W['live']} | set(h.get('X2', [])) | set(h.get('Y2', [])) + from collections import Counter + T = +Counter(dim[net.final[r]] - dim[net.init[r]] for r in range(len(net.init)) if r not in mains) + nat = pk.native_from_hist(dict(hist(net, dim)), dict(T), h.get('Dports', [])) + C = pk.load(CALLER); inv_ = pk.invoice(pk.caller_invoice(C), nat) + return pk.price(inv_, digits), inv_ + +def load_graph(path): + """their p104-banked graph JSON (DATA) -> Net""" + g = json.load(gzip.open(path, 'rt') if path.endswith('.gz') else open(path)) + moves = {k: (a, b) for k, a, b in g['moves']} + forms = {k: {int(t): Q(c) for t, c in row} for k, row in g['forms']} + return Net(g['first_output'], g['initial'], g['final'], moves, forms) diff --git a/research/p104-banked-cf6a-splits/tools/exval.py b/research/p104-banked-cf6a-splits/tools/exval.py new file mode 100644 index 0000000000..036af47258 --- /dev/null +++ b/research/p104-banked-cf6a-splits/tools/exval.py @@ -0,0 +1,17 @@ +import sys,os,time,pickle +sys.path.insert(0,os.path.dirname(os.path.abspath(__file__))) +from bank import * +def exact_values(net, order=None): + order = order or schedule(net); V = {} + for k in order: + v = {} + for d,c in net.forms[k].items(): + if d < 0: axpy(v, {~d: Q(1)}, c) + else: axpy(v, V[d], c) + V[k] = v + return V +if __name__=='__main__': + t=time.time(); W=load(sys.argv[1]); net=fold(W); V=exact_values(net) + print('t',time.time()-t,'avg support',sum(len(v) for v in V.values())/len(V)) + n7674=pickle.load(open('net7674.pkl','rb')); V2=exact_values(n7674) + print('terminals exact equal:', all(V[net.first+r]==V2[net.first+r] for r in range(len(net.init))), time.time()-t) diff --git a/research/p104-banked-cf6a-splits/tools/gauss.py b/research/p104-banked-cf6a-splits/tools/gauss.py new file mode 100644 index 0000000000..66081a9a4e --- /dev/null +++ b/research/p104-banked-cf6a-splits/tools/gauss.py @@ -0,0 +1,61 @@ +"""Own exact Gaussian-dyadic state simulation of chart transfers T_b T_a^-1 (canonical chart Cliffords on 9 axes). +Checks, for every column |x>, that the transfer spreads it over exactly 2^r basis states with equal modulus, r = |dim b - dim a| +(the physical rank of the job), using exact integer Gaussian numerators over a power-of-two denominator.""" +import sys, os +sys.path.insert(0, os.path.dirname(os.path.abspath(__file__))) +from phys import gf2_inv, gf2_rank, tr, extend, par, N +def mv(rows, x): return sum(par(r & x) << i for i, r in enumerate(rows)) +def qval(Q, al, x): + return (sum(al[i] for i in range(N) if x >> i & 1) + 2 * sum(par((Q[i] >> (i + 1)) & (x >> (i + 1))) for i in range(N) if x >> i & 1)) % 4 +def mul_i(a, k): + x, y = a + return [(x, y), (-y, x), (-x, -y), (y, -x)][k % 4] +def chart_circuit(U): + r = len(U) + if r == 0: return [] + if r == N: return [('C', 1 << i, 1) for i in range(N)] + G = tr(extend(U), N); gi = gf2_inv(G, N); git = tr(gi, N) + Q = [(1 << i) ^ sum(par(git[i] & gj) << j for j, gj in enumerate(git)) for i in range(N)] + al = [(Q[i] >> i) & 1 for i in range(N)] + K = [('P', G), ('D', Q, al)] + Kd = [('D', Q, [(-a) % 4 for a in al]), ('P', gi)] + return Kd + [('C', 1 << i, 1) for i in range(r)] + K +def adjoint(circ): + out = [] + for e in reversed(circ): + if e[0] == 'P': out.append(('P', gf2_inv(e[1], N))) + elif e[0] == 'D': out.append(('D', e[1], [(-a) % 4 for a in e[2]])) + elif e[0] == 'C': out.append(('C', e[1], -e[2])) + return out +def run(circ, x): + M = 1 << N; v = [(0, 0)] * M; v[x] = (1, 0); den = 0 + for e in circ: + if e[0] == 'P': + w = [(0, 0)] * M + for y, a in enumerate(v): w[mv(e[1], y)] = a + v = w + elif e[0] == 'D': v = [mul_i(a, qval(e[1], e[2], y)) for y, a in enumerate(v)] + elif e[0] == 'C': + q, s = e[1], e[2]; w = [] + for y, (a, b) in enumerate(v): + c, d = v[y ^ q]; w.append((a - s * b + c + s * d, b + s * a + d - s * c)) + v = w; den += 1 + while den and all((a & 1) == 0 and (b & 1) == 0 for a, b in v): v = [(a // 2, b // 2) for a, b in v]; den -= 1 + return v, den +def column_rank(Ua, Ub, cols=range(1 << N)): + circ = adjoint(chart_circuit(Ua)) + chart_circuit(Ub); out = set() + for x in cols: + v, den = run(circ, x) + nz = [a * a + b * b for a, b in v if a or b] + if len(set(nz)) != 1: return None + k = len(nz).bit_length() - 1 + if len(nz) != 1 << k: return None + out.add(k) + return out.pop() if len(out) == 1 else None +if __name__ == '__main__': + import json, gzip + from bank import load + W = load(sys.argv[1]); fr = W['frames'] + pairs = json.loads(sys.argv[2]) + for a, b in pairs: + r = column_rank(fr[a], fr[b]); print(a, b, 'column rank', r, 'dim diff', abs(len(fr[a]) - len(fr[b])), 'OK' if r == abs(len(fr[a]) - len(fr[b])) else 'FAIL', flush=True) diff --git a/research/p104-banked-cf6a-splits/tools/nest.py b/research/p104-banked-cf6a-splits/tools/nest.py new file mode 100644 index 0000000000..67202fc1ab --- /dev/null +++ b/research/p104-banked-cf6a-splits/tools/nest.py @@ -0,0 +1,30 @@ +"""GF(2) chart nesting: rank of transfer a->b = |dim b - dim a| only when spans are nested (else None).""" +def _basis(vs): + B = [] + for v in vs: + for b in B: v = min(v, v ^ b) + if v: B.append(v) + return B +def _in(v, B): + for b in sorted(B, reverse=True): v = min(v, v ^ b) + return v == 0 +_cache = {} +def span(fr, c): + if c not in _cache: + B = [] + for v in fr[c]: + for b in B: + if v ^ b < v: v ^= b + if v: B.append(v); B.sort(reverse=True) + _cache[c] = B + return _cache[c] +def red(v, B): + for b in B: + if v ^ b < v: v ^= b + return v +def nested(fr, a, b): + A, Bb = span(fr, a), span(fr, b) + small, big = (A, Bb) if len(A) <= len(Bb) else (Bb, A) + return all(red(v, big) == 0 for v in small) +def trank(fr, a, b): + return abs(len(fr[b]) - len(fr[a])) if nested(fr, a, b) else None diff --git a/research/p104-banked-cf6a-splits/tools/phys.py b/research/p104-banked-cf6a-splits/tools/phys.py new file mode 100644 index 0000000000..627aa652af --- /dev/null +++ b/research/p104-banked-cf6a-splits/tools/phys.py @@ -0,0 +1,95 @@ +"""Own physical checks for a banked circuit (no upstream code): + (a) symplectic rank of every transfer T_b T_a^-1 (canonical chart Cliffords, GF(2) tableau) equals |dim b - dim a| > 0; + (b) bank-cost stock: local terms, homes, reset/transfer service bounds (#7682 formulas), coefficient bits, row-denominator lcm.""" +import sys, os, gzip, json +from math import lcm +from fractions import Fraction as Q +sys.path.insert(0, os.path.dirname(os.path.abspath(__file__))) +from bank import load, Net, schedule +N = 9 +def par(x): return bin(x).count('1') & 1 +def gf2_rank(rows): + piv = {} + for x in rows: + while x: + b = x.bit_length() - 1 + if b not in piv: piv[b] = x; break + x ^= piv[b] + return len(piv) +def gf2_inv(rows, n): + a = [r | (1 << (n + i)) for i, r in enumerate(rows)] + for j in range(n): + k = next(i for i in range(j, n) if a[i] >> j & 1); a[j], a[k] = a[k], a[j] + for i in range(n): + if i != j and a[i] >> j & 1: a[i] ^= a[j] + return [r >> n for r in a] +def tr(rows, n): return [sum(((rows[j] >> i) & 1) << j for j in range(n)) for i in range(n)] +# Clifford as tableau: images of X_0..X_{n-1}, Z_0..Z_{n-1} as (x, z) bitmasks (phases dropped: rank is phase-free) +def img(T, x, z): + u = v = 0 + for i in range(N): + if x >> i & 1: u ^= T[i][0]; v ^= T[i][1] + if z >> i & 1: u ^= T[N + i][0]; v ^= T[N + i][1] + return (u, v) +def then(A, B): return [img(B, *p) for p in A] # first A, then B +def ident(): return [(1 << i, 0) for i in range(N)] + [(0, 1 << i) for i in range(N)] +def inverse(T): + cols = [x | (z << N) for x, z in T]; M = tr(cols, 2 * N); Mi = gf2_inv(M, 2 * N); ci = tr(Mi, 2 * N) + return [(w & ((1 << N) - 1), w >> N) for w in ci] +def perm(G): + cols = tr(G, N); gi = gf2_inv(G, N) + return [(c, 0) for c in cols] + [(0, g) for g in gi] +def diag(Qr): return [(1 << i, Qr[i]) for i in range(N)] + [(0, 1 << i) for i in range(N)] +def fourier(axes): + T = ident() + for i in axes: T[N + i] = (1 << i, 1 << i) + return T +def extend(U): + out = [] + for x in list(U) + [1 << i for i in range(N)]: + if gf2_rank(out + [x]) > len(out): out.append(x) + return out +def chart(U): + r = len(U) + if r == 0: return ident() + if r == N: return fourier(range(N)) + G = tr(extend(U), N); gi = gf2_inv(G, N); git = tr(gi, N) + Qr = [(1 << i) ^ sum(par(git[i] & gj) << j for j, gj in enumerate(git)) for i in range(N)] + K = then(perm(G), diag(Qr)) + return then(then(inverse(K), fourier(range(r))), K) +def trank(U, V): + op = then(inverse(chart(U)), chart(V)) + return gf2_rank([x for x, z in op[N:]]) +if __name__ == '__main__': + W = load(sys.argv[1]); fr = W['frames']; dim = [len(f) for f in fr] + C = json.load(gzip.open(sys.argv[2], 'rt')) + moves = {int(k): tuple(v) for k, v in C['moves'].items()} + forms = {int(k): {int(t): Q(c) for t, c in row.items()} for k, row in C['forms'].items()} + pairs = sorted(set(moves.values())) + bad = [(a, b) for a, b in pairs if trank(fr[a], fr[b]) != abs(dim[a] - dim[b]) or a == b] + # control: a deliberately non-nested pair must not pass + print('distinct transfer pairs', len(pairs), 'symplectic rank == |dim diff| > 0 failures:', len(bad), bad[:5]) + print('control 912->913 (non-nested): rank', trank(fr[912], fr[913]), 'dim diff', abs(dim[912] - dim[913])) + if len(sys.argv) > 3: + old = {tuple(v) for v in json.load(gzip.open(sys.argv[3], 'rt'))['moves'].values()} + print('new pairs vs reference circuit:', sorted(set(pairs) - old)) + n = len(C.get('initial', W['initial'])); k = len(moves); t = sum(len(r) for r in forms.values()) + bits = max(max(abs(c.numerator).bit_length(), c.denominator.bit_length()) for r in forms.values() for c in r.values()) + net = Net(C['first'], C.get('initial', W['initial']), C.get('final', W['final']), moves, forms); order = schedule(net); den = {} + for x in order: + d = 1 + for y, c in forms[x].items(): + d = lcm(d, c.denominator * (den[y] if y >= 0 else 1)) + den[x] = d + L = 1 + for d in den.values(): L = lcm(L, d) + odd = L + while odd % 2 == 0: odd //= 2 + b = 2 * n + 2 * k + 4 + print('terms', t, 'paid rows', k, 'homes/native', b, 'reset R', 2 * b + 8 * (t + k + n) + 4 * n, + 'transfer legs X', 2 * t + 2 * (k + n) + 6 * k + 4 * n, 'coef bits', bits, + 'row-denominator lcm', L, '= odd', odd, 'x 2^%d' % (L // odd).bit_length() if L != odd else '') + mass = {} + for x in order: + mass[x] = sum(abs(c) * (mass[y] if y >= 0 else 1) for y, c in forms[x].items()) + print('max row absolute mass', max(mass.values()), '; x grid 2025', max(mass.values()) * 2025) diff --git a/research/p104-banked-cf6a-splits/tools/pricekit.py b/research/p104-banked-cf6a-splits/tools/pricekit.py new file mode 100644 index 0000000000..260a190a1c --- /dev/null +++ b/research/p104-banked-cf6a-splits/tools/pricekit.py @@ -0,0 +1,489 @@ +#!/usr/bin/env python3 +"""PRICEKIT: the one canonical exact pricer for P104 caller+native invoices. Standard library only. + +Accounting contract (README.md has the one-page version). Units: + rank r job a paid job of rank r (P[r] += 1) or a productive target of rank r (T[r] += 1). + S rank-mass surplus sum_r r (T_r - P_r) (= F(0)). + F(t) the bill sum_r (T_r - P_r) r^(1-t). + kappa the unique root of F on (0, hi]; certified by an interval enclosure (Decimal, error-bounded signs). + D0 sum (T-P) r ln r (= -F'(0); the HOSTCRIB/MAINRETIME/CALLERMAP "D", e.g. #6934 422589.15263423) + Dk sum (T-P) r^(1-kappa) ln r (= -F'(kappa); the DSPLIT/ARCHEQ dk.py/TRADELAW "D(kappa)") + +Charging rules (caller events, '#7113 format' = schema mixed-root-caller/1): + port count every caller event of type A/B is charged once per port of that type (len(types[t]['ports'])). + QUERY P[1] per port (thin unit / sign query). + IDLE_ONE s P[8|s|] per port (one idle over the stage set s). + IDLE_ODD s P[8|s|+1] per port. + LAMBDA ordinary work, 1000 units per port-use (#6913). lambda_mode='paid_rank1' charges P[1] per port + instead (counterfactual only). + ADD/SWAP/SCALE not invoiced (ordinary only). + diagonal row T[(q mod 2) + 8*sum(stage bits)] per port: a field of degree d is a target of rank 8d+1 (odd phase) + or 8d (even phase). Hubs are fields with d = #stages (r137 at 17 stages). + J (one stage) ONE native word per J event: stage = call = J event = one copy of the native word. The native word + serves all 104 ports internally, so it is NOT multiplied by ports. +Native word (schema p104-accumulated-block-composition/2): + paid P[|dim b - dim a|] per MOVE. + helpers T[dim final - dim initial] per public register that is not a main. + mains live X (r), live Y (r+112), hosted X2, Y2. A port with a hosted plane (r in hosted.Dports) has 4 + mains, otherwise 2. Mains are never in T: their climbs are paid (MOVEs) and their credit is the + caller diagonal. Ledger law: native mains per port per stage == caller slots covered per stage + (= mask rank - idle incidences); check_slots() tests it. +Parametric native (native_param): start from a word or a histogram native and + drop_mains_A/B k mains per A/B port per call removed, priced by main_unit: + 'rank1x8' (8 rank-1 jobs, the ARMS/MONOCALLER/SLOT3 unit), 'rank8' (one rank-8 job), or exact via + drop_registers() on a real word (preferred; this is not parametric). + c_A/c_B extra owned rank-1 paid jobs per A/B port per call (may be a Fraction). + dT/dP helper/paid histogram deltas per call. +Every switch is an explicit argument; nothing reads the environment. +""" +import gzip, json, math +from collections import Counter +from decimal import Decimal, localcontext +from fractions import Fraction as Q + +VERSION = 'pricekit/1 (2026-11-11)' +NPORTS = 104 + +# ------------------------------------------------------------------------------------------- io +def load(path): + op = gzip.open if str(path).endswith('.gz') else open + with op(path, 'rt') as f: + return json.load(f) + +def hist(d): + """dict with str/int keys -> Counter{int: int|Fraction}; zero entries dropped.""" + return Counter({int(k): (Q(v) if isinstance(v, str) else v) for k, v in d.items() if v}) + +def _add(dst, src, mult=1): + for r, v in src.items(): + dst[r] += mult * v + return dst + +# ------------------------------------------------------------------------------------------- native +def native_from_word(W, verify=False): + """Exact native invoice of one word (one call). verify=True also replays the word exactly (slow).""" + n = len(W['initial']); live = set(W['live']); H = W.get('hosted') or {} + X2, Y2 = list(H.get('X2', [])), list(H.get('Y2', [])) + main = live | {r + 112 for r in live} | set(X2) | set(Y2) + dim = [len(b) for b in W['frames']] + paid = Counter(); main_paid = Counter(); cls = {} + for r in live: cls[r] = 'X'; cls[r + 112] = 'Y' + for r in X2: cls[r] = 'X2' + for r in Y2: cls[r] = 'Y2' + by_class = {k: Counter() for k in ('X', 'Y', 'X2', 'Y2')} + for e in W['program']: + if e[0] == 'MOVE': + rk = abs(dim[e[3]] - dim[e[2]]); paid[rk] += 1 + if e[1] in cls: by_class[cls[e[1]]][rk] += 1 + helpers = Counter(dim[W['final'][r]] - dim[W['initial'][r]] for r in range(n) if r not in main) + dports = set(H.get('Dports', [])) + mains_per_port = {p: 2 + 2 * (p in dports and bool(X2)) for p in range(NPORTS)} + out = dict(T=+helpers, P=+paid, public=n, events=len(W['program']), mains=len(main), main_moves=by_class, + mains_per_port=mains_per_port, Dports=sorted(dports), source='word') + if verify: + out['replay'] = replay(W)['ok'] + return out + +def native_from_hist(paid, helpers, Dports=None, mains_A=4, mains_B=2): + dp = set(Dports) if Dports is not None else None + mpp = None if dp is None else {p: (mains_A if p in dp else mains_B) for p in range(NPORTS)} + return dict(T=hist(helpers), P=hist(paid), mains_per_port=mpp, Dports=sorted(dp) if dp else None, source='hist') + +def native_param(base, nA, nB, drop_mains_A=0, drop_mains_B=0, main_unit='rank1x8', c_A=0, c_B=0, dT=None, dP=None, + allow_negative=False): + """Parametric native per call. base = native dict. Returns a new native dict (source='param').""" + T = Counter(base['T']); P = Counter(base['P']) + unit = {'rank1x8': {1: 8}, 'rank8': {8: 1}}[main_unit] + for ports, k in ((nA, drop_mains_A), (nB, drop_mains_B)): + for r, v in unit.items(): + P[r] -= ports * k * v + P[1] += nA * Q(c_A) + nB * Q(c_B) + _add(T, dT or {}); _add(P, dP or {}) + mpp = base.get('mains_per_port') + if mpp is not None: + dp = set(base['Dports'] or []) + mpp = {p: m - (drop_mains_A if p in dp else drop_mains_B) for p, m in mpp.items()} + for r in list(P): # a negative native count is legal only if the caller absorbs it (invoice() re-checks) + if P[r] < 0 and not allow_negative: raise ValueError('native_param: negative paid count at rank %d' % r) + return dict(T=T, P=P, mains_per_port=mpp, Dports=base.get('Dports'), source='param', + param=dict(drop_mains_A=drop_mains_A, drop_mains_B=drop_mains_B, main_unit=main_unit, c_A=str(c_A), c_B=str(c_B))) + +# ------------------------------------------------------------------------------------------- exact word replay / pruning +def _span(b): + return frozenset(b) + +def replay(W): + """Exact replay (Fractions, sparse rows). Returns dict(ok, rows, frames, problems).""" + n = W['public']; N = n + W['owned_fields']; frames = W['frames'] + fs = [set(f) for f in frames] + rows = [{r: Q(1)} if r < n else {} for r in range(N)] + cur = list(W['initial']) + [None] * W['owned_fields']; owned = set(); bad = [] + for i, e in enumerate(W['program']): + op, r = e[0], e[1] + if op == 'MOVE': + a, b, priv = e[2:] + if cur[r] != a: bad.append(('move-from', i)); + cur[r] = b + elif op == 'INIT': + owned.add(r); rows[r] = {}; cur[r] = e[2] + elif op == 'CLEAR': + owned.discard(r); rows[r] = {}; cur[r] = None + elif op == 'SCALE': + q = Q(e[2]) + if cur[r] != e[3]: bad.append(('scale-frame', i)) + rows[r] = {k: v * q for k, v in rows[r].items()} + elif op in ('ADD', 'COPY'): + s = e[2]; q = Q(e[3]); f = e[4] + if cur[r] != f or cur[s] != f: bad.append(('add-frame', i)) + if op == 'COPY' and rows[r]: bad.append(('copy-nonzero', i)) + R = rows[r] + for k, v in rows[s].items(): + nv = R.get(k, 0) + q * v + if nv: R[k] = nv + else: R.pop(k, None) + else: + bad.append(('op', i, op)) + if owned: bad.append(('owned-alive', len(owned))) + if cur[:n] != list(W['final']): bad.append(('exit-frames',)) + return dict(ok=not bad, rows=rows, cur=cur, problems=bad[:20], nproblems=len(bad)) + +def drop_registers(W, drop): + """Exact dead-code deletion of the public registers in `drop` (e.g. hosted X2/Y2). + Keeps every event that some kept public output depends on; removes whole owned lifetimes with no live use. + Refuses (ValueError) if a dropped register feeds a kept output. Returns (W2, report).""" + drop = set(drop); n = W['public']; N = n + W['owned_fields']; PR = W['program'] + need_mask = 0 + dem = [0] * N + for r in range(n): + if r not in drop: dem[r] = 1 << r + keep = [False] * len(PR); feeds_dropped = 0 + for i in range(len(PR) - 1, -1, -1): + e = PR[i]; op, t = e[0], e[1] + if op in ('INIT', 'CLEAR'): + dem[t] = 0; continue + if op == 'MOVE': + continue + if dem[t]: + keep[i] = True + if op in ('ADD', 'COPY'): + s = e[2] + if s in drop: feeds_dropped += 1 + dem[s] |= dem[t] + if op == 'COPY': dem[t] = 0 + if feeds_dropped: + raise ValueError('drop_registers: %d kept events read a dropped register' % feeds_dropped) + # lifetime decisions for owned registers + life_keep = {}; open_life = {} + for i, e in enumerate(PR): + op, t = e[0], e[1] + if t >= n: + if op == 'INIT': open_life[t] = i; life_keep[i] = False + elif op in ('ADD', 'COPY', 'SCALE') and keep[i]: life_keep[open_life[t]] = True + if op in ('ADD', 'COPY') and keep[i] and e[2] >= n: life_keep[open_life[e[2]]] = True + life_of = {}; open_life = {} + for i, e in enumerate(PR): + op, t = e[0], e[1] + if t >= n: + if op == 'INIT': open_life[t] = i + life_of[i] = open_life[t] + out = []; dropped_moves = Counter(); dropped_lifetimes = 0; dim = [len(b) for b in W['frames']] + for i, e in enumerate(PR): + op, t = e[0], e[1] + if t in drop: + if op == 'MOVE': dropped_moves[abs(dim[e[3]] - dim[e[2]])] += 1 + continue + if t >= n: + if not life_keep[life_of[i]]: + if op == 'MOVE': dropped_moves[abs(dim[e[3]] - dim[e[2]])] += 1 + if op == 'INIT': dropped_lifetimes += 1 + continue + if op in ('INIT', 'CLEAR', 'MOVE') or keep[i]: out.append(e) + continue + if op == 'MOVE' or keep[i]: out.append(e) + W2 = dict(W); W2['program'] = out + H = dict(W.get('hosted') or {}) + if drop >= set(H.get('X2', [])) | set(H.get('Y2', [])) and H.get('X2'): + H['X2'] = []; H['Y2'] = []; H['dropped_hosted_plane'] = True + W2['hosted'] = H + rep = dict(events_before=len(PR), events_after=len(out), dropped_moves=dict(dropped_moves), + dropped_owned_lifetimes=dropped_lifetimes) + return W2, rep + +def zero_registers(W, drop): + """Hard deletion: registers in `drop` cease to exist (rows = 0). Every event that targets OR reads them is + removed, then dead code is pruned with drop_registers(). Only valid if verify_drop() shows every kept public row + unchanged; otherwise the word genuinely uses the dropped registers and a rebuild is needed.""" + drop = set(drop) + W1 = dict(W); W1['program'] = [e for e in W['program'] if not (e[1] in drop and e[0] != 'MOVE') + and not (e[0] in ('ADD', 'COPY') and e[2] in drop)] + removed_reads = sum(1 for e in W['program'] if e[0] in ('ADD', 'COPY') and e[2] in drop and e[1] not in drop) + W2, rep = drop_registers(W1, drop); rep['removed_reads'] = removed_reads + return W2, rep + +def verify_drop(W, W2, drop): + """Replay both words exactly; every kept public row and exit frame must be unchanged.""" + a = replay(W); b = replay(W2); n = W['public'] + same = all(a['rows'][r] == b['rows'][r] for r in range(n) if r not in set(drop)) + frames = all(b['cur'][r] == W['final'][r] for r in range(n)) + return dict(original_ok=a['ok'], pruned_ok=b['ok'], pruned_problems=b['problems'], kept_rows_equal=same, exit_frames=frames) + +# ------------------------------------------------------------------------------------------- caller +def caller_ports(C): + return {t: len(v['ports']) for t, v in C['types'].items()} + +def caller_invoice(C, lambda_mode='ordinary', only=None): + """Caller part of the invoice (no native). only='A'/'B' restricts to one port type. + Returns dict(T, P, nJ, ports, lambda_uses, ops).""" + assert lambda_mode in ('ordinary', 'paid_rank1') + ports = caller_ports(C); T = Counter(); P = Counter(); nJ = 0; lam = 0; ops = Counter() + for e in C['events']: + if e[0] == 'J': + nJ += 1; continue + ty, op = e[0], e[1] + if only and ty != only: continue + k = ports[ty]; ops[(ty, op)] += 1 + if op == 'QUERY': P[1] += k + elif op == 'IDLE_ONE': P[8 * len(e[3])] += k + elif op == 'IDLE_ODD': P[8 * len(e[3]) + 1] += k + elif op == 'LAMBDA': + lam += k + if lambda_mode == 'paid_rank1': P[1] += k + elif op in ('ADD', 'SWAP', 'SCALE', 'HOST'): pass + else: raise ValueError('caller op not in the alphabet: %r' % (op,)) + for ty, t in C['types'].items(): + if only and ty != only: continue + for dg in t['diagonal']: + T[int(dg[0]) % 2 + 8 * sum(dg[2:])] += ports[ty] + T[0] = 0; T = +T + return dict(T=T, P=+P, nJ=nJ, ports=ports, lambda_uses=lam, ops=ops) + +def check_slots(C, native=None): + """Per type and stage: mask rank, idle incidences, covered = mask - idles. With a native, compare covered with + the native's mains per port (the ledger law d = m).""" + nst = C['stages']; res = {} + for ty, t in C['types'].items(): + mask = [0] * (nst + 1); idle = [0] * (nst + 1) + for dg in t['diagonal']: + for k, b in enumerate(dg[2:], 1): + if b: mask[k] += 1 + for e in C['events']: + if e[0] == ty and e[1] in ('IDLE_ONE', 'IDLE_ODD'): + for k in e[3]: idle[k] += 1 + cov = [mask[k] - idle[k] for k in range(1, nst + 1)] + res[ty] = dict(mask=mask[1:], idle=idle[1:], covered=cov, header=sum(mask), idle_incidences=sum(idle)) + if native is not None and native.get('mains_per_port'): + mpp = native['mains_per_port'] + for ty, t in C['types'].items(): + ms = {mpp[p] for p in t['ports']} + res[ty]['native_mains'] = sorted(ms) + res[ty]['law_d_eq_m'] = (len(ms) == 1 and all(c == next(iter(ms)) for c in res[ty]['covered'])) + return res + +def caller_from_roots(fields, hosts_per_stage_cap, thin, ports, nst): + """Parametric caller (rule of our #6934 package, check.py outer()). fields = list of (mask stages, host stages); + a field of degree d is a target 8d+1; its unhosted mask stages are idled in maximal consecutive runs (P[8*run]); + a stage hosting more than hosts_per_stage_cap[k] fields pays one rank-8 idle per excess; thin rank-1 queries.""" + T = Counter(); P = Counter(); hc = Counter() + for ms, host in fields: + T[8 * len(ms) + 1] += ports + hs = set(host) + for k in hs: hc[k] += 1 + run = 0; prev = None + for k in sorted(ms): + if k in hs: + if run: P[8 * run] += ports + run = 0; prev = None; continue + if prev is not None and k == prev + 1: run += 1 + else: + if run: P[8 * run] += ports + run = 1 + prev = k + if run: P[8 * run] += ports + for k in range(nst): + if hc[k] > hosts_per_stage_cap[k]: P[8] += ports * (hc[k] - hosts_per_stage_cap[k]) + P[1] += ports * thin + return dict(T=+T, P=+P) + +# ------------------------------------------------------------------------------------------- invoice and price +def invoice(caller, native, calls=None): + """caller: dict from caller_invoice/caller_from_roots; native: native dict. calls defaults to caller nJ.""" + L = caller.get('nJ') if calls is None else calls + if not L: raise ValueError('invoice: number of native calls unknown (no J events and calls=None)') + T = Counter(caller['T']); P = Counter(caller['P']) + _add(T, native['T'], L); _add(P, native['P'], L) + for C_ in (T, P): + for r in list(C_): + if C_[r] == 0: del C_[r] + elif C_[r] < 0: raise ValueError('invoice: negative count at rank %d' % r) + return dict(T=T, P=P, calls=L) + +def S_of(T, P): + return sum(r * (T.get(r, 0) - P.get(r, 0)) for r in set(T) | set(P)) + +def _dec(x): + x = Q(x); return Decimal(x.numerator) / Decimal(x.denominator) + +def _coef(T, P): + return sorted((r, Q(T.get(r, 0)) - Q(P.get(r, 0))) for r in set(T) | set(P) if Q(T.get(r, 0)) != Q(P.get(r, 0))) + +def _F(cs, t, prec): + """F(t) and a rigorous bound on its evaluation error at this precision.""" + with localcontext() as c: + c.prec = prec; t = Decimal(t) + val = Decimal(0); mag = Decimal(0) + for r, k in cs: + p = (Decimal(r).ln() * (1 - t)).exp(); kd = _dec(k) + val += kd * p; mag += abs(kd) * p + err = mag * Decimal(10) ** (-(prec - 6)) + return val, err + +def _sign(cs, t, prec=60): + while prec <= 1200: + v, e = _F(cs, t, prec) + if abs(v) > e: return 1 if v > 0 else -1 + prec *= 2 + raise ArithmeticError('sign of F undetermined at t=%s' % t) + +def _unique(cs, hi, depth=14): + """Certify at most one root of F on [0, hi] by interval bounds (F excluded from 0, or F' < 0 on the piece).""" + with localcontext() as c: + c.prec = 40 + def pw(r, t): return (Decimal(r).ln() * (1 - Decimal(t))).exp() + def piece(a, b): + Fl = sum(_dec(k) * (pw(r, b) if k > 0 else pw(r, a)) for r, k in cs) + Fh = sum(_dec(k) * (pw(r, a) if k > 0 else pw(r, b)) for r, k in cs) + if Fl > 0 or Fh < 0: return 'noroot' + Dl = sum(_dec(k) * Decimal(r).ln() * (pw(r, b) if k > 0 else pw(r, a)) for r, k in cs if r > 1) + return 'mono' if Dl > 0 else 'unknown' + stack = [(Decimal(0), Decimal(hi), 0)]; mono = [] + while stack: + a, b, d = stack.pop(); s = piece(a, b) + if s == 'noroot': continue + if s == 'mono': mono.append((a, b)); continue + if d >= depth: return False + m = (a + b) / 2; stack += [(a, m, d + 1), (m, b, d + 1)] + mono.sort() + return all(mono[i][1] == mono[i + 1][0] for i in range(len(mono) - 1)) # one contiguous decreasing block + +def kappa(T, P, digits=50): + """Certified enclosure of the crossing. Returns dict(lo, hi, S, status). status NO_CROSSING if S <= 0.""" + cs = _coef(T, P); S = S_of(T, P) + if S <= 0: return dict(status='NO_CROSSING', S=S, lo=None, hi=None) + hi = Decimal('0.001') + while _sign(cs, hi) > 0: + hi *= 2 + if hi > 64: return dict(status='NO_SIGN_CHANGE', S=S, lo=None, hi=None) + lo = Decimal(0); uniq = _unique(cs, hi) + width = Decimal(10) ** (-digits - 2) + with localcontext() as c: + c.prec = digits + 30 + while hi - lo > width: + m = (lo + hi) / 2 + if _sign(cs, m, digits + 30) > 0: lo = m + else: hi = m + return dict(status='OK' if uniq else 'OK_UNIQUENESS_UNPROVED', S=S, lo=lo, hi=hi, unique=uniq) + +def Dsum(T, P, t=0, prec=60): + with localcontext() as c: + c.prec = prec; t = Decimal(t) + return sum(_dec(k) * Decimal(r).ln() * (Decimal(r).ln() * (1 - t)).exp() for r, k in _coef(T, P) if r > 1) + +def F_at(T, P, t, prec=60): + return _F(_coef(T, P), t, prec)[0] + +def price(inv, digits=50): + T, P = inv['T'], inv['P']; k = kappa(T, P, digits) + out = dict(S=S_of(T, P), paid_jobs=sum(P.values()), paid_positions=sum(r * v for r, v in P.items()), + targets=sum(T.values()), target_positions=sum(r * v for r, v in T.items()), kappa=k, + D0=Dsum(T, P, 0)) + if k.get('lo') is not None: out['Dk'] = Dsum(T, P, k['lo']) + return out + +def kstr(k, n=30): + if k.get('lo') is None: return k['status'] + return str(k['lo'])[:n + 2] + +def break_even_c(T, P, kappa_ref, ports_calls): + """Linear break-even: extra rank-1 paid per (port x call) at which kappa == kappa_ref. F(kref; c) = F0 - c*ports_calls.""" + return F_at(T, P, kappa_ref) / ports_calls + +# ------------------------------------------------------------------------------------------- ordinary units (#6934 package reading) +def word_ordinary(W): + """Per-call ordinary terms of a native word (allowance, reviewed upper, routes): our #6934 jclib.word_terms.""" + H = W['hosted']; nD = len(H['Dports']); n = len(W['initial']); live = set(W['live']) + main = live | {r + 112 for r in live} | set(H.get('X2', [])) | set(H.get('Y2', [])) + dim = [len(b) for b in W['frames']] + paid = Counter(abs(dim[e[3]] - dim[e[2]]) for e in W['program'] if e[0] == 'MOVE') + hel = Counter(dim[W['final'][r]] - dim[W['initial'][r]] for r in range(n) if r not in main) + life = sum(e[0] == 'INIT' for e in W['program']); allow = upper = 0 + for e in W['program']: + if e[0] in ('INIT', 'CLEAR'): allow += 2 + elif e[0] == 'SCALE': + q = Q(e[2]); a, d = abs(q.numerator), q.denominator + allow += 2 * (abs(a.bit_length() - d.bit_length()) + int(q < 0)); upper += 4 * (a.bit_length() + d.bit_length() + 1) + elif e[0] in ('ADD', 'COPY'): + q = Q(e[3]); a, d = abs(q.numerator), q.denominator + allow += 2 * (3 + a.bit_length() - 1 + bin(a).count('1') + d.bit_length() - 1); upper += 4 * (a.bit_length() + bin(a).count('1') + d.bit_length() + 1) + routes = (sum(paid.values()) + 2 * sum(hel.values()) + 208 + 2 * nD + 4 * 104 + 4 * nD + 4 * life) * 1000 + return dict(allow=allow, upper=upper, routes=routes, n=n, nD=nD) + +def _swaps(sel): + wanted = set(range(len(sel))); return len(list(zip(sorted(set(sel) - wanted), sorted(wanted - set(sel))))) + +def _shim(C, ty): + t = C['types'][ty]; off = t['offset']; ev = [] + for e in C['events']: + if e[0] == 'J': ev.append(['HOST', e[1]]) + elif e[0] == ty: + e = list(e[1:]) + if e[0] in ('ADD', 'SWAP', 'QUERY'): e[1] -= off; e[2] -= off + else: e[1] -= off + ev.append(e) + return dict(events=ev, roles=t['roles'], diagonal=t['diagonal']) + +def _rest(C, ports): + ev = C['events']; roles = C['roles']; mx = mn = mp = 0 + for role, (qp, zero, *sel) in enumerate(C['diagonal']): + axes = ([0] if qp else []) + [a for st, y in enumerate(sel, 1) if y for a in range(9 + 8 * (st - 1), 9 + 8 * st)] + k = _swaps(axes); mx += 2 * k * ports; mn += 2 * bool(qp) * ports; mp += int(qp == -1) * ports + ie = qn = qph = 0 + for e in ev: + if e[0] in ('IDLE_ONE',): + ie += 2 * _swaps([a for st in e[2] for a in range(9 + 8 * (st - 1), 9 + 8 * st)]) * ports + elif e[0] == 'QUERY': + qn += 2 * ports; qph += int(e[3] == -1) * ports + return (32 * roles * ports * len(ev) + sum(e[0] == 'QUERY' for e in ev) * 16 * ports + roles * ports * 26 + + (mx + mn + mp) * 1000 + ie * 1000 + (qn + qph) * 1000) + +def ordinary(C, W, odd_scale=1125): + """Raw ordinary readings of the #6934 package (literal/actual/upper/recharge/per_input). IDLE_ODD is not in that + formula (#7113-era callers): such callers get a flag, not a number for the IDLE_ODD routes.""" + t = word_ordinary(W); ports = caller_ports(C); L = sum(1 for e in C['events'] if e[0] == 'J') + rest = _rest(_shim(C, 'A'), ports['A']) + _rest(_shim(C, 'B'), ports['B']) + lam = sum(ports[e[0]] for e in C['events'] if e[0] != 'J' and e[1] == 'LAMBDA'); debit = 1000 * lam + sc = 4 * (odd_scale.bit_length() + 2) + 4 * (odd_scale.bit_length() + 2) + per_in = L * t['n'] * sc + lit = L * 10 ** 7 + rest; act = L * (t['allow'] + t['routes']) + rest; up = L * (t['upper'] + t['routes']) + rest + return dict(literal=lit, actual=act, upper=up, recharge=up + debit, per_input=up + per_in, per_input_recharge=up + per_in + debit, + lambda_uses=lam, lambda_debit=debit, idle_odd_present=any(e[0] != 'J' and e[1] == 'IDLE_ODD' for e in C['events'])) + +# ------------------------------------------------------------------------------------------- one-call convenience +def run(caller_path, native, lambda_mode='ordinary', digits=50): + C = load(caller_path); ci = caller_invoice(C, lambda_mode) + inv = invoice(ci, native); pr = price(inv, digits) + return dict(caller=ci, invoice=inv, price=pr, slots=check_slots(C, native)) + +def cite(label, pr): + """One-line citation string for RESULT.md files.""" + k = pr['kappa'] + return '[PRICEKIT %s] %s: S=%s kappa=%s D0=%.4f Dk=%s paid=%d' % ( + VERSION, label, pr['S'], kstr(k, 26), float(pr['D0']), ('%.8f' % float(pr['Dk'])) if 'Dk' in pr else '-', pr['paid_jobs']) + +if __name__ == '__main__': + import sys + if len(sys.argv) < 3: + print('usage: pricekit.py CALLER.json WORD.json[.gz] | NATIVE-RESULT.json'); sys.exit(1) + X = load(sys.argv[2]) + nat = native_from_word(X) if 'program' in X else native_from_hist(X['native']['paid'], X['native']['helpers']) + R = run(sys.argv[1], nat) + print(cite(sys.argv[2], R['price'])) diff --git a/research/p104-banked-cf6a-splits/verify.py b/research/p104-banked-cf6a-splits/verify.py new file mode 100644 index 0000000000..a11bdd460e --- /dev/null +++ b/research/p104-banked-cf6a-splits/verify.py @@ -0,0 +1,65 @@ +#!/usr/bin/env python3 +"""Exact check of the split banked circuit on the #7700 cf6a word (standard library only). + +1. Authenticate every package asset (ASSETS.json). +2. Authenticate the #7700 cf6a source word (canonical SHA-256 pin). +3. Locality (every donor is cocharted with its reader) and an acyclic schedule of data/CIRCUIT.json.gz. +4. Every paid edge joins GF(2)-nested charts with positive rank; the symplectic rank of T_b T_a^-1 equals |dim b - dim a|. +5. For every chart pair that is not a MOVE of the word, an exact Gaussian state simulation of T_b T_a^-1 spreads every + one of the 512 columns over exactly 2^r basis states of equal modulus (a non-nested control pair is rejected). +6. Exact rational outputs: every main output equals the word's; every helper, including the three fresh split + roles 1501-1503, returns its own normalized input. +7. Invoice on the literal 16-call caller and a certified enclosure of the crossing (PRICEKIT). +usage: python3.12 -I -B verify.py [--skip-columns]""" +import sys, os, gzip, json, hashlib +from fractions import Fraction as Q +HERE = os.path.dirname(os.path.abspath(__file__)) +sys.path.insert(0, os.path.join(HERE, 'tools')) +from bank import fold, Net, schedule, price_net, hist, pk +from exval import exact_values +import nest, phys, gauss + +def enc(v): return json.dumps(v, sort_keys=True, separators=(',', ':')).encode() +assets = json.load(open(os.path.join(HERE, 'ASSETS.json'))) +for row in assets['files']: + with open(os.path.join(HERE, row['path']), 'rb') as fh: + if hashlib.sha256(fh.read()).hexdigest() != row['sha256']: raise SystemExit('FAIL: asset hash ' + row['path']) +print('1. %d package assets authenticated' % len(assets['files'])) +def need(c, m): + if not c: raise SystemExit('FAIL: ' + m) + +W = json.load(gzip.open(os.path.join(HERE, 'source', 'WORD.json.gz'), 'rt')) +need(hashlib.sha256(enc(W)).hexdigest() == 'ae62d5d8bef6f7146454b4b3643e487a58380c606a16c5baef7bf0dcf9df1472', 'cf6a (#7700) word pin') +print('2. #7700 cf6a word authenticated: %d events, SHA-256 ae62d5d8bef6f714' % len(W['program'])) +fr = W['frames']; dim = [len(f) for f in fr] + +C = json.load(gzip.open(os.path.join(HERE, 'data', 'CIRCUIT.json.gz'), 'rt')) +net = Net(C['first'], C['initial'], C['final'], {int(k): tuple(v) for k, v in C['moves'].items()}, + {int(k): {int(t): Q(c) for t, c in row.items()} for k, row in C['forms'].items()}) +schedule(net); print('3. locality + acyclic schedule: PASS (%d paid edges, %d public roles)' % (len(net.moves), len(net.init))) +pairs = sorted(set(net.moves.values())) +for a, b in pairs: + r = nest.trank(fr, a, b) + need(r is not None and r > 0, 'nested positive pair %s' % ((a, b),)) + need(phys.trank(fr[a], fr[b]) == r, 'symplectic rank %s' % ((a, b),)) +print('4. %d distinct chart pairs nested, positive rank, symplectic rank = |dim diff|: PASS' % len(pairs)) +wordpairs = {(e[2], e[3]) for e in W['program'] if e[0] == 'MOVE'} +newp = [p for p in pairs if p not in wordpairs] +if '--skip-columns' not in sys.argv: + for a, b in newp: + need(gauss.column_rank(fr[a], fr[b]) == abs(dim[a] - dim[b]), 'Gaussian column rank %s' % ((a, b),)) + ca, cb = next((a, b) for a in range(len(fr)) for b in range(a + 1, len(fr)) if dim[a] == dim[b] > 0 and not nest.nested(fr, a, b)) + need(gauss.column_rank(fr[ca], fr[cb]) != 0, 'control: a non-nested equal-dimension pair must not be rank 0') + print('5. %d pairs outside the #7700 word: exact Gaussian column rank = |dim diff| on all 512 columns: PASS (control rejects %d->%d)' % (len(newp), ca, cb)) +h = W['hosted']; mains = set(W['live']) | {r + 112 for r in W['live']} | set(h['X2']) | set(h['Y2']) +ref = fold(W); EVr = exact_values(ref); EVc = exact_values(net) +need(all(EVc[net.first + r] == EVr[ref.first + r] and net.final[r] == W['final'][r] for r in mains), 'main outputs') +need(all(EVc[net.first + r] == {r: Q(1)} for r in range(len(net.init)) if r not in mains), 'helper identity') +print('6. EXACT: %d main outputs equal the #7700 word; %d helpers return their own input: PASS' % (len(mains), len(net.init) - len(mains))) +pr, inv = price_net(W, net, dim, 30) +k = pr['kappa']; need(k['status'] == 'OK', 'certified unique crossing') +print('7. paid/native %d, paid %d, targets %d, S %d; crossing in (%s, %s)' % ( + sum(hist(net, dim).values()), pr['paid_jobs'], pr['targets'], pr['S'], str(k['lo'])[:20], str(k['hi'])[:20])) +claim = Q('0.0037427697512') +need(Q(str(k['lo'])) > claim, 'claim below certified lower end') +print('PASS: kappa >= 0.0037427697512 on the stated invoice')