Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
131 changes: 131 additions & 0 deletions research/joint-output-connector-minimal-charge-247794/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
# Minimal joint-output connector charge

**Scoped connector-alphabet experiment; no new κ or supplier claim.** This
refines `connector-alphabet-change` to the smallest nonzero instance of one
output-side operation: two distinct output maps are applied to the same
connector in one joint readout record. The existing pair-source operation is
already treated in [PR #2056](../connector-pair-source-path-seed2cdb/README.md),
so this package checks the complementary output direction.

## Exact interface change

The fixed alphabet permits a single-target readout
`A_i: y_i += A_i z`. This experiment adds exactly one family

```text
J_ik: (y_i, y_k) += (A_i z, A_k z), i != k
```

`J_ik` reads the one connector `z`, adds into two distinct output rows, leaves
`z` and all sources unchanged, restores its private scratch and tape heads, and
does not inspect either old target. Both maps are arbitrary fixed
`F_2`-linear maps. The operation is a **one-record premise change**: it must
account for both coefficient/map evaluations, both target updates, connector
routing, scratch restoration and head returns. Nothing in this package claims
that a real supplier currently implements that fused record.

## Smallest dirty-state construction

Use one source `x`, one arbitrarily dirty connector `z`, and two arbitrarily
dirty targets `y_i,y_k`. Let `B` be the source map and let the requested outputs
be `A_i Bx` and `A_k Bx`. Compare these schedules:

```text
single-target alphabet: B, A_i, A_k, B, A_i, A_k
joint-output alphabet: J_ik, B, J_ik, B
```

Write `s = Bx` and let the initial connector be any `z0`. In the first
schedule, each target receives `A_r(z0+s) + A_r(z0) = A_r(s)`. In the second,
each receives `A_r(z0) + A_r(z0+s) = A_r(s)`. Both schedules leave `z=z0`;
neither changes `x`. This uses only additivity over `F_2`; no invertibility,
commutation, clean-row assumption or observation of intermediate outputs is
needed. The instance is minimal for this operation: one source gives a
nonzero requested term, and two distinct targets are required to exercise
`J_ik`.

## Complete cost

Let `c_B`, `c_i`, and `c_k` be the complete map-evaluation costs per additive
call, excluding root dispatch. They include the source/coefficient access,
arithmetic, target update, scratch restoration and head return. Let `D` be the
cost of one root record. Charge a joint readout as

```text
cost(J_ik) = c_i + c_k + D + phi,
```

where `phi >= 0` is any extra shared-routing, fusion, storage or restoration
overhead not already counted in those two complete map costs or the one root
record. This explicitly pays for both `A` maps and targets.

| Schedule | Map evaluations | Root records | Complete bill |
|---|---|---:|---|
| Original alphabet | `2 c_B + 2 c_i + 2 c_k` | 6 | `2 c_B + 2 c_i + 2 c_k + 6D` |
| With `J_ik` | `2 c_B + 2 c_i + 2 c_k` | 4 | `2 c_B + 2 c_i + 2 c_k + 4D + 2phi` |

Therefore `C_joint - C_single = 2(phi-D)`. The joint operation is favorable
exactly when `phi < D`; at `phi = D` it ties, and above that it loses. If `J`
is implemented by invoking two ordinary root-level `A` calls, that pays the
second dispatch (`phi = D`) and yields no saving. A true one-record
implementation with no extra fusion surcharge would save `2D`, but remains an
unproved implementation obligation. No leaf-map work is removed in this
minimal instance.

## Verification

```sh
python3 -I -B research/joint-output-connector-minimal-charge-247794/verify.py
```

The standard-library checker enumerates all `16^3 * 4^4 = 1,048,576`
combinations of two-dimensional `F_2` maps `B,A_i,A_k` and arbitrary data
`x,z,y_i,y_k`. It checks both the output identity and connector restoration.
Three faulty schedules (missing one output update, missing the first dirty
cancellation readout, or missing final connector restoration) must fail. It
also checks the exact symbolic cost delta at `phi/D` values 0, 1 and 2. The
finite enumeration is a verifier check; the dimension-independent claim above
follows from the displayed linear identity.

Registered replay and source pins:

```sh
python3 scripts/research_package.py --package research/joint-output-connector-minimal-charge-247794 --check-only
python3.12 scripts/research_package.py --package research/joint-output-connector-minimal-charge-247794
```

The package is pinned to base `20ecf2891d80b5acf18d980b2164fb44ea7faa90`,
priority revision 6. The selected record remains
`κ = 836330098538459/500000000000000000`; this experiment changes no selected
source, supplier, or frontier. It does not establish a real `J_ik` compiler,
an optimized caller, a reduced recursive interface tariff, or a new
multiplication bound.

## Overlap and credit

The current five-source scope map distinguishes fixed single-output calls,
pair-source calls and connector frames. Its pair-source predecessor already
accounts for two source accesses and arbitrary dirty replay. The live PR #3779
at intake concerns overlapping six-window gate counts and source restoration;
it does not change this one-source/two-target alphabet definition. The offline
overlap search found no direct joint-output match, and current handoff comments
were checked for the same operation. Open PR #3604 (head
`7156bb98f78b7492002010e8729d59fe38b92e60`) is adjacent: it co-delivers
specialized P112 tetrad products to a fused port and a source-side dirty
correction, and leaves the native schedule and full scalar tariff open. This
package does not re-audit that factorization; `J_ik` is the generic operation
that applies two arbitrary `A` maps to two targets from the same connector, and
the cost calculation deliberately grants no shared-product leaf discount.
These checks are not proof of novelty.

Credit Adam Gall and the contributors to the fixed-alphabet tariff and
pair-source connector results; this note does not supersede or restate their
theorems. Prepared by OpenAI Codex with substantial assistance. Apache-2.0.

## Open next questions

Can a caller-bound stacked map realize `J_ik` with all common-label, input
routing, output ownership, scratch and head costs included, at an overhead
`phi < D`? The next step is to instantiate one real supplier port and compare
its measured complete bill with the threshold above. Without such a caller and
tariff, do not extend this construction or infer a supplier improvement.
42 changes: 42 additions & 0 deletions research/joint-output-connector-minimal-charge-247794/SOURCES.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"schema_version": 1,
"base_commit": "20ecf2891d80b5acf18d980b2164fb44ea7faa90",
"files": [
{
"path": "certificates/selected-result.json",
"usage": "provenance",
"git_blob": "b1fea0c94436b236cc2b7d41a7be032811b94c81",
"sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129"
},
{
"path": "docs/research/agent-task-catalog.json",
"usage": "provenance",
"git_blob": "67f085acd86acd7d4e03922d9cf4b26bca66fed5",
"sha256": "47b42433f5a85809a3aadd29c2c339da2c6ed728e4f7762df6b88bccb7874cf0"
},
{
"path": "docs/research/five-source-connector-scope-map.md",
"usage": "input",
"git_blob": "c4b56250e35eb52f07987f7e96c7dba18fac75d1",
"sha256": "5b541588a5ddb38b4dbbf5dca91cc9e6684f67462d515e25f838d833ec30f62f"
},
{
"path": "research/connector-pair-source-path-seed2cdb/README.md",
"usage": "input",
"git_blob": "22aade420aef3f395792cac576a41a98d8c986f5",
"sha256": "ec2be09ba0ef27862ce880ae7bf2e0b6be3dd32fccaed70e0b6fd4e96d19e8d3"
},
{
"path": "research/universal-connector-boundary/README.md",
"usage": "input",
"git_blob": "d277f7c5830b1f2bc42e1ff41ab86e7d7564929f",
"sha256": "23415f7829ab8d80a783142f10f7d31abbce84579362769984680af3df954476"
},
{
"path": "research/universal-connector-boundary/verify.py",
"usage": "input",
"git_blob": "de6483bb7ff51940dbbb76c18f91af4c907e07da",
"sha256": "e4fa4700f9e1ae6ca09c3c76ebc569e8361b89b699425a67839d999d8812e42d"
}
]
}
67 changes: 67 additions & 0 deletions research/joint-output-connector-minimal-charge-247794/TASK.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
{
"schema_version": 1,
"task_id": "connector-alphabet-change",
"priority_revision": 6,
"base_commit": "20ecf2891d80b5acf18d980b2164fb44ea7faa90",
"assignment": {
"seed": "2477945717b9b6d6cc55a36835a0d5aa",
"track": "recursive-interfaces",
"scope_key": "ff4f5113ed2256ab19ed"
},
"original_card": {
"id": "connector-alphabet-change",
"question": "Does one explicit extension of the connector alphabet offer a favorable completed budget?",
"starting_points": [
"docs/research/research-family-status.md",
"research/universal-connector-boundary/README.md",
"certificates/selected-result.json"
],
"methods": [
"Construct and charge a legal extra operation on a minimal instance.",
"Prove a target-specific bound after adding one specified operation family."
],
"acceptance_gate": "State which fixed-alphabet premise changes and charge its implementation; do not declare it free. A scoped local result may be retained without a complete supplier. Expanding it into further construction rounds requires the family-level budget and obligation gate in research-family-status.md; an optimistic passing relaxation alone is not acceptance.",
"first_step": {
"command": [
"python3",
"-B",
"research/universal-connector-boundary/verify.py"
],
"expected": "PASS_UNIVERSAL_CONNECTOR_BOUNDARY",
"inspect": "Reproduce the 945-pairing control, then read Exact interface to list the allowed calls.",
"scope": "Positive control / source-bound orientation only; this is not a new construction or full cold replay."
},
"first_experiment": "Add exactly one legally priced operation and test a tiny dirty-input instance before enumerating larger cases.",
"bottleneck_link": "A new legal connector operation could change recursive interface cost; a larger census in the same alphabet is a separate side result.",
"allowed_variations": [
"Choose one additional operation and a small source count for its first counterexample."
],
"scope_change_triggers": [
"Keeping the alphabet and only increasing the source count; record this as a changed assignment.",
"Extending a source-count census without naming a supplier/interface decision it could change; audit #2973 pruning concerns before relying on the affected predecessor exclusions."
],
"overlap_terms": [
"universal connector",
"source-toggle",
"connector alphabet"
]
},
"scope_status": "refined",
"actual_scope": "On the smallest nonzero one-source, two-output instance, audit one extra joint-readout operation J_ik:(y_i,y_k)+=(A_i z,A_k z), including arbitrary dirty connector and target rows, and derive the exact fusion-overhead threshold for a complete-cost saving.",
"scope_change_reason": "The source-side pair operation B_jk already has a five-source construction, dirty replay and charged-access analysis in PR #2056; the current scope map records it. Refine the card to the distinct output-side joint-readout operation and the minimal instance, rather than repeating the pair-source word or the live six-window bill in PR #3779.",
"bottleneck_link": "Root dispatch savings from a multi-output connector readout count only if its real implementation overhead stays below the dispatch records it removes.",
"budget_minutes": 60,
"stop_rule": "Stop after the exact one-source/two-output dirty-state identity and full symbolic invoice. Do not expand the output alphabet or claim supplier benefit unless a concrete caller realizes J_ik with fusion overhead below one saved dispatch per use.",
"outcome": "completed",
"evidence": "A general F2-linear identity proves the four-record J_ik,B,J_ik,B schedule implements both outputs and restores arbitrary connector dirt. A stdlib verifier exhausts all 1,048,576 combinations of 2x2 linear maps and dirty data. Leaf map calls match the original six-record schedule; the complete delta is exactly 2(phi-D), so the extension wins only for fusion overhead phi < D.",
"ai_assistance": "Substantial OpenAI Codex assistance; the verifier and proof note were produced by this agent.",
"author": "OpenAI Codex (GPT-6 Luna xhigh; homelab-09)",
"open_questions": [
{
"question": "Can a real selected-supplier caller implement a joint readout J_ik with total shared-routing and fusion overhead phi < D while preserving both dirty targets, connector frames, scratch and tape heads?",
"why_it_matters": "The minimal schedule's leaf work is unchanged; only an implementation below this exact threshold reduces the completed invoice.",
"first_step": "At one concrete caller port, write the stacked map's common-label/tape realization, account for both A_i and A_k coefficients and all routing/restoration, then compare its extra cost phi with one root dispatch D.",
"blocked_by": "No caller-bound fused output module or measured complete dispatch tariff is pinned in the current connector sources."
}
]
}
23 changes: 23 additions & 0 deletions research/joint-output-connector-minimal-charge-247794/VERIFY.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"schema_version": 1,
"status": "ready",
"python": "3.12",
"requirements": [],
"inputs": [
"docs/research/five-source-connector-scope-map.md",
"research/connector-pair-source-path-seed2cdb/README.md",
"research/universal-connector-boundary/README.md",
"research/universal-connector-boundary/verify.py"
],
"commands": [
{
"argv": [
"{python}",
"-B",
"{package}/verify.py"
],
"timeout_seconds": 120,
"checks": "Exhaust all 1,048,576 combinations of 2x2 F2 maps and arbitrary source/connector/two-target states; reject three dirty/output/restoration faults; verify exact cost break-even at phi/D = 0,1,2."
}
]
}
125 changes: 125 additions & 0 deletions research/joint-output-connector-minimal-charge-247794/verify.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
#!/usr/bin/env python3
"""Exhaustively check the minimal joint-output dirty-state schedule.

The proof in README.md is dimension-independent. This checker independently
enumerates every F2-linear map on F2^2 and every source, connector, and target
state, then rejects three deliberately faulty schedules and checks the exact
symbolic break-even formula.
"""

from fractions import Fraction
from itertools import product


def require(condition, message):
if not condition:
raise AssertionError(message)


def parity(value):
return value.bit_count() & 1


def apply(matrix, vector):
"""Apply a 2x2 F2 matrix encoded as two row masks."""
row0, row1 = matrix
return parity(row0 & vector) | (parity(row1 & vector) << 1)


def all_matrices():
return tuple(product(range(4), repeat=2))


def joint_readout(z, yi, yk, ai, ak, *, omit_ak=False):
yi ^= apply(ai, z)
if not omit_ak:
yk ^= apply(ak, z)
return yi, yk


def replay(ai, ak, b, x, z, yi, yk, *, omit_first=False,
omit_ak=False, omit_second=False, omit_final_b=False):
"""Run J, B, J, B with optional faults used by negative controls."""
if not omit_first:
yi, yk = joint_readout(z, yi, yk, ai, ak, omit_ak=omit_ak)
z ^= apply(b, x)
if not omit_second:
yi, yk = joint_readout(z, yi, yk, ai, ak, omit_ak=omit_ak)
if not omit_final_b:
z ^= apply(b, x)
return x, z, yi, yk


def expected(ai, ak, b, x, z0, yi0, yk0):
signal = apply(b, x)
return (x, z0,
yi0 ^ apply(ai, signal),
yk0 ^ apply(ak, signal))


def check_positive_cases():
matrices = all_matrices()
cases = 0
for ai, ak, b in product(matrices, repeat=3):
for x, z, yi, yk in product(range(4), repeat=4):
got = replay(ai, ak, b, x, z, yi, yk)
want = expected(ai, ak, b, x, z, yi, yk)
require(got == want,
"joint-readout mismatch at case %d: %r != %r" %
(cases, got, want))
cases += 1
require(cases == 1_048_576, "unexpected exhaustive case count")
return cases


def check_negative_controls():
identity = (1, 2)
zero = (0, 0)
controls = 0

# Omitting A_k from both joint records loses the second requested output.
args = (identity, identity, identity, 1, 0, 0, 0)
require(replay(*args, omit_ak=True) != expected(*args),
"control failed to expose a missing output update")
controls += 1

# With dirty z and Bx=0, the first J is needed to cancel A_r z0.
args = (identity, identity, zero, 0, 1, 0, 0)
require(replay(*args, omit_first=True) != expected(*args),
"control failed to expose missing dirty-state cancellation")
controls += 1

# The last B call is required to return the connector to its dirty entry.
args = (identity, identity, identity, 1, 0, 0, 0)
require(replay(*args, omit_final_b=True) != expected(*args),
"control failed to expose missing connector restoration")
controls += 1

return controls


def check_cost_threshold():
# C_joint - C_single = 2(phi - D); report the ratio when D is normalized
# to one. Exact rationals avoid a floating-point break-even check.
def delta_over_d(phi_over_d):
return 2 * (phi_over_d - 1)

require(delta_over_d(Fraction(0)) == -2,
"zero fusion overhead should save two dispatches")
require(delta_over_d(Fraction(1)) == 0,
"one dispatch of fusion overhead should tie")
require(delta_over_d(Fraction(2)) == 2,
"two dispatches of fusion overhead should lose by two dispatches")
return True


def main():
cases = check_positive_cases()
controls = check_negative_controls()
check_cost_threshold()
print("PASS_JOINT_OUTPUT_CONNECTOR_MINIMAL cases=%d controls=%d "
"records=6_to_4 leaves_equal delta=2*(phi-D)" % (cases, controls))


if __name__ == "__main__":
main()