From b6f828a939915795b507777aa66fa93277f4e4e7 Mon Sep 17 00:00:00 2001 From: Roger Hunt Date: Sat, 28 Nov 2026 13:54:19 -0300 Subject: [PATCH 1/6] learning_coordinator: hypotheses fixed before the full run --- .../learning_coordinator/hypotheses.md | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 org_frontier/studies/learning_coordinator/hypotheses.md diff --git a/org_frontier/studies/learning_coordinator/hypotheses.md b/org_frontier/studies/learning_coordinator/hypotheses.md new file mode 100644 index 000000000..b1262542a --- /dev/null +++ b/org_frontier/studies/learning_coordinator/hypotheses.md @@ -0,0 +1,36 @@ +# A coordinator that learns to trust + +Fixed before this study's computation (Nov 28, 2026). + +## Gap + +`adaptive_quota` let the mediator's quota depend on its own last decision (six of nine rules bind at r = 0; the sticky +majorities (2,1) and (3,2) bind only with misreading, at 0.107922). The mediator's memory there is its own output. Open +question: what if the coordinator has a separate memory node that learns from what happened, and the quota depends on it? + +## Model + +Five nodes: mediator S, parties P1–P3, learner L. Parties copy S's last value. S reads the three parties (each misread +with probability r) and applies a quota: q_c (cautious) if L = 0, q_t (trusting) if L = 1. The learner has no input +from outside: **latch** variant, L' = L OR (S = 1 AND all three parties = 1), once trust is earned it stays; +**last-step** variant, L' = S AND all three parties, trust lasts only one step. Quota pairs (q_c, q_t) ∈ {(2,1), (3,1), +(3,2), (1,3)}, r ∈ {0, 0.1}, both variants: 16 cases. For every reachable state, φ of every subset from +`new_big_phi.reachable_subsystems`; whole Φ = largest full-group φ; top tie set = subsets within 1e-9 of the largest +subset φ. + +Controls: for q_c = q_t ∈ {1, 2, 3} (latch, r = 0) L feeds nothing, so whole Φ is 0 (a gate; the run stops otherwise). +Reference values without a learner: `adaptive_quota` (2,1) r = 0.1: 0.107922. + +## Outcomes (threshold 1e-9 unless stated) + +- H1: latch, r = 0: whole Φ is 0 for (2,1) and (3,2), and positive for (3,1) and (1,3). +- H2: latch, r = 0.1, (2,1): whole Φ lies between 0.05 and 0.2. +- H3: memory matters: the latch and last-step whole Φ differ by more than 1e-6 in at least 5 of the 8 (pair, r) cells. +- H4: the learner joins the strongest unit rarely: the top tie set contains L in at most 7 of the 16 cases. +- H5: (3,1), latch, r = 0: whole Φ is at most 2.5 (below the 3.0 of the same rule without a learner). + +The result is scored as stated; a refuted outcome is reported as refuted. + +Disclosure: before this file was pushed, the script's `--quick` mode was run once as a smoke test; it printed the +full-group φ in the all-zero state for (3,1) latch r = 0 (0.000000) and (2,1) latch r = 0.1 (0.022626). The +hypotheses above were written before that and were not changed afterward. From 7e48d389bb1a12a2689236c9b7a84c0c3991dc3f Mon Sep 17 00:00:00 2001 From: Roger Hunt Date: Sat, 28 Nov 2026 14:03:10 -0300 Subject: [PATCH 2/6] learning_coordinator: script, results, README, FINDINGS --- .../studies/learning_coordinator/FINDINGS.md | 52 + .../studies/learning_coordinator/README.md | 21 + .../learning_coordinator/results/results.json | 2354 +++++++++++++++++ .../studies/learning_coordinator/run.py | 132 + 4 files changed, 2559 insertions(+) create mode 100644 org_frontier/studies/learning_coordinator/FINDINGS.md create mode 100644 org_frontier/studies/learning_coordinator/README.md create mode 100644 org_frontier/studies/learning_coordinator/results/results.json create mode 100644 org_frontier/studies/learning_coordinator/run.py diff --git a/org_frontier/studies/learning_coordinator/FINDINGS.md b/org_frontier/studies/learning_coordinator/FINDINGS.md new file mode 100644 index 000000000..50e174167 --- /dev/null +++ b/org_frontier/studies/learning_coordinator/FINDINGS.md @@ -0,0 +1,52 @@ +# A coordinator with a learning memory does not bind the whole group; the learner mostly stays out + +Exact IIT 4.0 Φ (PyPhi pin `b78d0e342`), every reachable subset in every reachable state. Hypotheses pushed in +`b6f828a9` before the full run (after a one-off smoke test of two single-state values, disclosed in +`hypotheses.md`). Control passed: with equal quotas the learner feeds nothing and whole Φ is 0 (q = 1, 2, 3). + +## Setup + +Mediator S reads three parties (each misread with probability r), applies quota q_c while the learner L is 0 and q_t +while L is 1; parties copy S. Latch: L' = L OR (S AND all three parties). Last-step: L' = S AND all three parties. +Four (q_c, q_t) pairs × r ∈ {0, 0.1} × 2 variants = 16 cases, 5–8 reachable states each, ~7 min. + +## Whole Φ + +| (q_c, q_t) | r | latch | last-step | +|---|---:|---:|---:| +| (2,1) | 0 | 0 | 0 | +| (3,1) | 0 | 0 | 0 | +| (3,2) | 0 | 0 | 0 | +| (1,3) | 0 | 0 | 0 | +| (2,1) | 0.1 | 0.022626 | 0.018100 | +| (3,1) | 0.1 | 0.000826 | 0.121090 | +| (3,2) | 0.1 | 0.000826 | 0.110083 | +| (1,3) | 0.1 | 0.008816 | 0.008435 | + +Strongest unit (largest φ of any subset, `results.json`): latch, r = 0.1: {S, P1, P2, P3} (without L) at 1.854569 in all +four pairs; latch, r = 0: {S, P1, P2, P3} at 3.000000 for (2,1), (3,1) and (1,3), and L alone (1.000000) for (3,2). +Last-step, r = 0: nothing binds for (2,1) (0); {S, P_k} at 0.110083 for (3,1), 0.438722 for (3,2) and 0.276692 for +(1,3). Last-step, r = 0.1: six subsets at 0.107922 for (2,1); {S, L} at 0.209244 for (3,1); {S, P_k} at 0.361447 for (3,2) and +0.484356 for (1,3). The full group is never in the top tie set. + +## Scores + +- **H1 REFUTED.** I predicted whole Φ 0 for (2,1) and (3,2) and positive for (3,1) and (1,3) at r = 0 with a latch. It is 0 in all four. +- **H2 REFUTED.** (2,1) latch r = 0.1 is 0.022626, below my 0.05 to 0.2 band (adaptive_quota's no-learner value is 0.107922). +- **H3 REFUTED.** I predicted memory type matters in at least 5 of 8 cells. It matters in 4: all four r = 0.1 cells differ + by more than 1e-6; at r = 0 both variants are 0. +- **H4 SUPPORTED.** The learner is in the top unit in 2 of 16 cases: (3,2) latch r = 0 (L alone) and (3,1) last-step r = 0.1 ({S, L}). +- **H5 SUPPORTED, trivially.** (3,1) latch r = 0 is 0, which is at most 2.5. The prediction holds as written, but the real result is a collapse to 0, not the modest drop I had in mind. + +## Post-hoc reading (seen after the run, not predicted) + +- In the latch, once L = 1 it never changes, so in those states L is a fixed background and {S, P1, P2, P3} behaves like + the plain quota-q_t rule: the best state is L = 1 (3.0 with quota 1 at r = 0; 1.854569 at r = 0.1 in every pair). The + whole group binds weakly because L only moves one way. This is an explanation after the fact; I did not test it with a + variant where L can reset. +- The one-step memory binds more tightly than the permanent memory for (3,1) and (3,2) at r = 0.1 (0.121090 and 0.110083 + against 0.000826), and both are above the plain majority's 0.026981. Four pairs, one r; not a tested rule. + +## Limits + +One learning rule (unanimous yes), two memory types, four quota pairs, r ∈ {0, 0.1}, five nodes. The CI check covers one state of two cases. diff --git a/org_frontier/studies/learning_coordinator/README.md b/org_frontier/studies/learning_coordinator/README.md new file mode 100644 index 000000000..dbcb6ed2b --- /dev/null +++ b/org_frontier/studies/learning_coordinator/README.md @@ -0,0 +1,21 @@ +# A coordinator that learns to trust + +Five nodes: mediator S, parties P1–P3 (copy S), and a learner L. S applies quota q_c while L = 0 and q_t once L = 1. +**Latch**: L stays 1 once S and all three parties have been 1 together. **Last-step**: L is 1 only right after that. +Quota pairs (q_c, q_t) ∈ {(2,1), (3,1), (3,2), (1,3)}, r ∈ {0, 0.1}. Exact IIT 4.0 φ for every subset in every reachable +state (16 cases plus 3 controls). + +``` +python org_frontier/studies/learning_coordinator/run.py --quick # CI: full-group φ in ONE state of two cases, ~15 s +python org_frontier/studies/learning_coordinator/run.py --write # full run, ~7 min +``` + +The CI quick check is narrower than the full run: it recomputes the full-group φ in the all-zero state for +(3,1) latch r = 0 and (2,1) latch r = 0.1 only. + +**Result: LEARNER_STAYS_OUT.** Two of five predictions held. Whole Φ is 0 in all 8 r = 0 cases (both variants), and at +r = 0.1 it is tiny with a permanent memory (0.000826 to 0.022626) and larger with one-step memory only in two cases +(0.121090 for (3,1), 0.110083 for (3,2)). The learner joins the strongest unit in 2 of 16 cases. + +Files: [hypotheses.md](hypotheses.md), [FINDINGS.md](FINDINGS.md), [results/results.json](results/results.json), +[BACKLOG.md](BACKLOG.md). diff --git a/org_frontier/studies/learning_coordinator/results/results.json b/org_frontier/studies/learning_coordinator/results/results.json new file mode 100644 index 000000000..390bf70f1 --- /dev/null +++ b/org_frontier/studies/learning_coordinator/results/results.json @@ -0,0 +1,2354 @@ +{ + "pyphi_version": "1.2.1.dev1470+gb78d0e342", + "phi_eps": 1e-09, + "hypotheses": { + "H1": "REFUTED", + "H2": "REFUTED", + "H3": "REFUTED", + "H4": "SUPPORTED", + "H5": "SUPPORTED" + }, + "controls": [ + { + "qc": 1, + "qt": 1, + "r": 0.0, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.0, + "top": 3.0, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 3.0, + "full_phi": 0.0, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 3.0, + "full_phi": 0.0, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 2, + "qt": 2, + "r": 0.0, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.0, + "top": 1.0, + "top_ties": [ + "L" + ], + "full_in_top": false, + "learner_in_top": true, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 3, + "r": 0.0, + "variant": "latch", + "n_states": 7, + "whole_phi": 0.0, + "top": 3.0, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 3.0, + "full_phi": 0.0, + "ties": [ + "SP1P2P3" + ], + "full_in": false + } + ] + } + ], + "rows": [ + { + "qc": 2, + "qt": 1, + "r": 0.0, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.0, + "top": 3.0, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 3.0, + "full_phi": 0.0, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 2, + "qt": 1, + "r": 0.0, + "variant": "last-step", + "n_states": 5, + "whole_phi": 0.0, + "top": 0.0, + "top_ties": [], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 2, + "qt": 1, + "r": 0.1, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.022625585267129995, + "top": 1.8545692346356781, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.022625585267129995, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0000000000000004, + "full_phi": -0.004835592457362263, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": -0.019342369829449053, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.10792243564185913, + "full_phi": -0.004500519822677134, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.8545692346356781, + "full_phi": -0.16212407515427074, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": -0.16212407515427057, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.9335299003499613, + "full_phi": -0.15770824431349303, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in": false + } + ] + }, + { + "qc": 2, + "qt": 1, + "r": 0.1, + "variant": "last-step", + "n_states": 6, + "whole_phi": 0.018100468213704004, + "top": 0.10792243564185913, + "top_ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.10792243564185912, + "full_phi": 0.018100468213704004, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.10792243564185912, + "full_phi": 0.0005256694735496259, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.10792243564185913, + "full_phi": -0.019342369829449053, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.10792243564185913, + "full_phi": -0.019342369829449053, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.0196091779421837, + "full_phi": -3.3603451313714583, + "ties": [ + "SL" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.00994884725630832, + "full_phi": 0.00994884725630832, + "ties": [ + "SL", + "SP1L", + "SP2L", + "SP3L", + "SP1P2L", + "SP1P3L", + "SP2P3L", + "SP1P2P3L" + ], + "full_in": true + } + ] + }, + { + "qc": 3, + "qt": 1, + "r": 0.0, + "variant": "latch", + "n_states": 7, + "whole_phi": 0.0, + "top": 3.0, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 3.0, + "full_phi": 0.0, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 1, + "r": 0.0, + "variant": "last-step", + "n_states": 5, + "whole_phi": 0.0, + "top": 0.11008290168136904, + "top_ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.11008290168136904, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.06847139022755935, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 1, + "r": 0.1, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.0008260520298636979, + "top": 1.8545692346356781, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0008260520298636979, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": -0.11081025512144141, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": -0.11081025512144142, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 1.8545692346356755, + "full_phi": -0.7848733462139278, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.8545692346356781, + "full_phi": -0.1786870109228317, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": -0.17868701092283154, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.5932645533894352, + "full_phi": -0.1405877347937307, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3", + "SP1P2P3" + ], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 1, + "r": 0.1, + "variant": "last-step", + "n_states": 6, + "whole_phi": 0.12109022700423659, + "top": 0.20924391226332087, + "top_ties": [ + "SL" + ], + "full_in_top": false, + "learner_in_top": true, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0007227955261307357, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3", + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0007227955261307357, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3", + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.08306713154062766, + "full_phi": -0.11081025512144142, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.07878674356699776, + "full_phi": -0.17868701092283146, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.20924391226332087, + "full_phi": -0.8803865843254649, + "ties": [ + "SL" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.12109022700423659, + "full_phi": 0.12109022700423659, + "ties": [ + "SL", + "SP1L", + "SP2L", + "SP3L", + "SP1P2L", + "SP1P3L", + "SP2P3L", + "SP1P2P3L" + ], + "full_in": true + } + ] + }, + { + "qc": 3, + "qt": 2, + "r": 0.0, + "variant": "latch", + "n_states": 7, + "whole_phi": 0.0, + "top": 1.0, + "top_ties": [ + "L" + ], + "full_in_top": false, + "learner_in_top": true, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 2, + "r": 0.0, + "variant": "last-step", + "n_states": 5, + "whole_phi": 0.0, + "top": 0.43872187554086717, + "top_ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.12244974511214896, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.43872187554086717, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 2, + "r": 0.1, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.0008260520298636979, + "top": 1.8545692346356755, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": 0.0008260520298636979, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": -0.09424731935288057, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": -0.09424731935288058, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 1.8545692346356755, + "full_phi": -0.5822024077854272, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": -0.01934236982944921, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": -0.01934236982944921, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.8433400083911704, + "full_phi": -0.004528768398372562, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.10792243564185913, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in": false + } + ] + }, + { + "qc": 3, + "qt": 2, + "r": 0.1, + "variant": "last-step", + "n_states": 6, + "whole_phi": 0.11008290168136922, + "top": 0.36144678158957305, + "top_ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0005256694735496259, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3", + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0057823642090458855, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP2P3", + "SP1P2P3", + "SP1P2P3L" + ], + "full_in": true + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.10844558431980693, + "full_phi": -0.09424731935288058, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.36144678158957305, + "full_phi": -0.16212407515427063, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.18725101576000877, + "full_phi": -1.2172947143385764, + "ties": [ + "SL" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.11008290168136922, + "full_phi": 0.11008290168136922, + "ties": [ + "SL", + "SP1L", + "SP2L", + "SP3L", + "SP1P2L", + "SP1P3L", + "SP2P3L", + "SP1P2P3L" + ], + "full_in": true + } + ] + }, + { + "qc": 1, + "qt": 3, + "r": 0.0, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.0, + "top": 3.0, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 3.0, + "full_phi": 0.0, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.9999999999999994, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.2766916661858958, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + } + ] + }, + { + "qc": 1, + "qt": 3, + "r": 0.0, + "variant": "last-step", + "n_states": 5, + "whole_phi": 0.0, + "top": 0.2766916661858958, + "top_ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.11008290168136904, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.11008290168136904, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.0, + "full_phi": 0.0, + "ties": [], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.2766916661858958, + "full_phi": 0.0, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + } + ] + }, + { + "qc": 1, + "qt": 3, + "r": 0.1, + "variant": "latch", + "n_states": 8, + "whole_phi": 0.008815841583903793, + "top": 1.8545692346356781, + "top_ties": [ + "SP1P2P3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 1.8545692346356781, + "full_phi": -0.11081025512144163, + "ties": [ + "SP1P2P3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 1.0, + "full_phi": -0.11081025512144152, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 1.0, + "full_phi": -0.11092117629773937, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.02853472126335075, + "full_phi": 0.008815841583903793, + "ties": [ + "SP1P2L", + "SP1P3L", + "SP2P3L" + ], + "full_in": false + }, + { + "state": [ + 0, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": 0.0, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 1 + ], + "top": 1.0, + "full_phi": -0.17868701092283143, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.9096683655625619, + "full_phi": -0.17868701092283146, + "ties": [ + "L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.17464037922596692, + "full_phi": -0.17868701092283146, + "ties": [ + "SP1P2", + "SP1P3", + "SP2P3" + ], + "full_in": false + } + ] + }, + { + "qc": 1, + "qt": 3, + "r": 0.1, + "variant": "last-step", + "n_states": 6, + "whole_phi": 0.008434927510364586, + "top": 0.48435609927565754, + "top_ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in_top": false, + "learner_in_top": false, + "states": [ + { + "state": [ + 0, + 0, + 0, + 0, + 0 + ], + "top": 0.09147648511883844, + "full_phi": -0.11081025512144152, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 0, + 0, + 0, + 0 + ], + "top": 0.09147648511883844, + "full_phi": -0.11081025512144152, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 0 + ], + "top": 0.0057823642090458855, + "full_phi": 0.0007482355342968279, + "ties": [ + "SP1", + "SP2", + "SP3", + "SP1P2", + "SP1P3", + "SP1L", + "SP2P3", + "SP2L", + "SP3L", + "SP1P2P3", + "SP1P2L", + "SP1P3L", + "SP2P3L" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 0 + ], + "top": 0.026347470890217266, + "full_phi": 0.008434927510364586, + "ties": [ + "SP1P2L", + "SP1P3L", + "SP2P3L" + ], + "full_in": false + }, + { + "state": [ + 0, + 1, + 1, + 1, + 1 + ], + "top": 0.48435609927565754, + "full_phi": -0.8803865843254652, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + }, + { + "state": [ + 1, + 1, + 1, + 1, + 1 + ], + "top": 0.14619612041698593, + "full_phi": -0.17868701092283146, + "ties": [ + "SP1", + "SP2", + "SP3" + ], + "full_in": false + } + ] + } + ] +} diff --git a/org_frontier/studies/learning_coordinator/run.py b/org_frontier/studies/learning_coordinator/run.py new file mode 100644 index 000000000..88651ff8b --- /dev/null +++ b/org_frontier/studies/learning_coordinator/run.py @@ -0,0 +1,132 @@ +"""A coordinator that learns to trust: S's quota is q_c while the learner L is 0 and q_t once L is 1. + +Run from the repo root: python org_frontier/studies/learning_coordinator/run.py [--quick] [--write] +Hypotheses are fixed in hypotheses.md. +""" +import argparse +import json +import os +import sys +from importlib.metadata import version +from pathlib import Path + +ROOT = Path(__file__).resolve().parents[3] +sys.path.insert(0, str(ROOT)) +os.environ.setdefault("PYPHI_WELCOME_OFF", "true") + +import numpy as np # noqa: E402 +import pyphi # noqa: E402 +from pyphi import new_big_phi # noqa: E402 + +from foundations.proxy_audit.exact_phi import reachable_states # noqa: E402 +from org_frontier.classifier.classifier import PHI_EPS # noqa: E402 +from org_frontier.probes.weighted_quorum.probe_weighted_quorum import ( # noqa: E402 + cm_numeric, gate_c1, labels_for, table_of, +) + +pyphi.config.PROGRESS_BARS = False +N = 3 +NN = 5 +PAIRS = ((2, 1), (3, 1), (3, 2), (1, 3)) +RATES = (0.0, 0.1) +VARIANTS = ("latch", "last-step") +LABELS = labels_for(N) + ("L",) +QUICK = (((3, 1), 0.0, "latch", (0, 0, 0, 0, 0)), ((2, 1), 0.1, "latch", (0, 0, 0, 0, 0))) + + +def learner_tpm(qc, qt, r, variant): + """Nodes: 0 = S, 1..3 = parties (copy S), 4 = learner L. S's quota is qt if L = 1 else qc.""" + tables = {0: table_of((1, 1, 1), qc), 1: table_of((1, 1, 1), qt)} + tpm = np.zeros((2 ** NN, NN)) + for state in range(len(tpm)): + s, learner = state & 1, (state >> 4) & 1 + actual = (state >> 1) & 0b111 + for observed, output in enumerate(tables[learner]): + d = (actual ^ observed).bit_count() + tpm[state, 0] += output * r ** d * (1 - r) ** (N - d) + tpm[state, 1:N + 1] = s + agree = int(s == 1 and actual == 0b111) + tpm[state, 4] = float(learner or agree) if variant == "latch" else float(agree) + return tpm + + +def read(pair, r, variant): + qc, qt = pair + tpm = learner_tpm(qc, qt, r, variant) + net = pyphi.Network(tpm, cm=cm_numeric(tpm), node_labels=LABELS) + full = tuple(range(NN)) + states = [] + for index in reachable_states(tpm, NN): + state = tuple((index >> i) & 1 for i in range(NN)) + phis = {tuple(s.node_indices): float(new_big_phi.sia(s).phi) + for s in new_big_phi.reachable_subsystems(net, net.node_indices, state)} + top = max(phis.values()) if phis else 0.0 + ties = sorted((k for k, v in phis.items() if top > PHI_EPS and top - v <= PHI_EPS), + key=lambda k: (len(k), k)) + states.append(dict(state=list(state), top=top, full_phi=phis.get(full, 0.0), + ties=["".join(LABELS[i] for i in k) for k in ties], full_in=full in ties)) + best = max(states, key=lambda s: s["top"]) + return dict(qc=qc, qt=qt, r=r, variant=variant, n_states=len(states), + whole_phi=max(s["full_phi"] for s in states), top=best["top"], top_ties=best["ties"], + full_in_top=best["full_in"], learner_in_top=any("L" in t for t in best["ties"]), states=states) + + +def phi_at(pair, r, variant, state): + tpm = learner_tpm(*pair, r, variant) + net = pyphi.Network(tpm, cm=cm_numeric(tpm), node_labels=LABELS) + return float(new_big_phi.sia(pyphi.Subsystem(net, state, range(NN))).phi) + + +def show(x): + ties = ",".join(x["top_ties"]) if len(x["top_ties"]) <= 6 else f"{len(x['top_ties'])} subsets" + print(f"({x['qc']},{x['qt']}) r={x['r']:<4} {x['variant']:<9} states={x['n_states']:<2} whole={x['whole_phi']:.6f} " + f"top={x['top']:.6f} full_in_top={'Y' if x['full_in_top'] else 'N'} ties={ties or '-'}", flush=True) + + +def main(): + ap = argparse.ArgumentParser(description=__doc__) + ap.add_argument("--quick", action="store_true") + ap.add_argument("--write", action="store_true") + args = ap.parse_args() + if not gate_c1(): + raise SystemExit("C1 controls failed") + if args.quick: # CI: full-group φ in one state of two cases (narrower than the full run) + for pair, r, variant, st in QUICK: + print(f"({pair[0]},{pair[1]}) r={r} {variant} state={''.join(map(str, st))} full-group phi={phi_at(pair, r, variant, st):.6f}", flush=True) + return + from multiprocessing import Pool + ctl_jobs = [((q, q), 0.0, "latch") for q in (1, 2, 3)] + jobs = ctl_jobs + [(p, r, v) for p in PAIRS for r in RATES for v in VARIANTS] + with Pool(3) as pool: + done = pool.starmap(read, jobs) + for x in done: + show(x) + controls, rows = done[:3], done[3:] + for x in controls: + if x["whole_phi"] > PHI_EPS: + raise SystemExit(f"C2 control failed: ({x['qc']},{x['qt']}) with a learner that feeds nothing has whole Φ > 0") + print("C2 equal quotas (learner feeds nothing): whole Φ = 0: PASS") + g = {((x["qc"], x["qt"]), x["r"], x["variant"]): x for x in rows} + w = lambda p, r, v: g[(p, r, v)]["whole_phi"] # noqa: E731 + cells = [(p, r) for p in PAIRS for r in RATES] + scores = { + "H1": all(w(p, 0.0, "latch") <= PHI_EPS for p in ((2, 1), (3, 2))) and all(w(p, 0.0, "latch") > PHI_EPS for p in ((3, 1), (1, 3))), + "H2": 0.05 <= w((2, 1), 0.1, "latch") <= 0.2, + "H3": sum(abs(w(p, r, "latch") - w(p, r, "last-step")) > 1e-6 for p, r in cells) >= 5, + "H4": sum(x["learner_in_top"] for x in rows) <= 7, + "H5": w((3, 1), 0.0, "latch") <= 2.5, + } + for h, ok in scores.items(): + print(f"{h}: {'SUPPORTED' if ok else 'REFUTED'}") + print("learner in top unit:", sum(x["learner_in_top"] for x in rows), "of", len(rows)) + if args.write: + out = Path(__file__).with_name("results") + out.mkdir(exist_ok=True) + (out / "results.json").write_text(json.dumps(dict( + pyphi_version=version("pyphi"), phi_eps=PHI_EPS, + hypotheses={h: "SUPPORTED" if ok else "REFUTED" for h, ok in scores.items()}, + controls=controls, rows=rows), indent=1) + "\n") + + +if __name__ == "__main__": + main() From a8b6cac6fc75982d4e79433c6ab243a118e37df9 Mon Sep 17 00:00:00 2001 From: Roger Hunt Date: Sat, 28 Nov 2026 14:03:12 -0300 Subject: [PATCH 3/6] learning_coordinator: backlog, post, readme row --- .../studies/learning_coordinator/BACKLOG.md | 7 +++ .../studies/learning_coordinator/__init__.py | 0 .../2026-11-28-a-coordinator-that-learns.md | 52 +++++++++++++++++++ substack/experiments/README.md | 1 + 4 files changed, 60 insertions(+) create mode 100644 org_frontier/studies/learning_coordinator/BACKLOG.md create mode 100644 org_frontier/studies/learning_coordinator/__init__.py create mode 100644 substack/experiments/2026-11-28-a-coordinator-that-learns.md diff --git a/org_frontier/studies/learning_coordinator/BACKLOG.md b/org_frontier/studies/learning_coordinator/BACKLOG.md new file mode 100644 index 000000000..28bd4d43d --- /dev/null +++ b/org_frontier/studies/learning_coordinator/BACKLOG.md @@ -0,0 +1,7 @@ +# Experiment backlog after learning_coordinator + +1. **A learner that can forget**: L resets with a small probability, so L is not absorbing. Does the whole Φ recover + (the post-hoc reading says the one-way latch is why it collapses)? +2. **Learning from disagreement**: L latches when the parties disagree with S, quota tightens. +3. **Two learner bits** (a counter to two): seven nodes, expensive. +4. **Why does one-step memory beat permanent memory at r = 0.1 for (3,1) and (3,2)?** Compare repertoires of {S, L, P_k}. diff --git a/org_frontier/studies/learning_coordinator/__init__.py b/org_frontier/studies/learning_coordinator/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/substack/experiments/2026-11-28-a-coordinator-that-learns.md b/substack/experiments/2026-11-28-a-coordinator-that-learns.md new file mode 100644 index 000000000..258181969 --- /dev/null +++ b/substack/experiments/2026-11-28-a-coordinator-that-learns.md @@ -0,0 +1,52 @@ +# A coordinator that learns to trust does not hold the group together, and the memory itself mostly stays on the sidelines + +*We gave the coordinator a memory that learns: once everyone has said yes together, it relaxes its rule. I expected the group to bind. Instead the whole group came out at zero whenever the coordinator reads its people perfectly. Three of my five predictions were wrong.* + +## The question + +Earlier we let a coordinator tighten or loosen its rule based on its own last decision ([the sticky coordinator](2026-11-28-sticky-coordinator.md)). Here the memory is separate: a learner that remembers whether everyone once agreed. What does a coordinator with a real memory do to the group's bond? + +We measured integrated information Φ (IIT 4.0, computed exactly with PyPhi), which says how far a setup fails to split into independent parts. It is not a claim that anything is alive or aware. + +## What we ran + +Three people and a coordinator, plus a learner. The people copy the coordinator. The coordinator reads them (perfectly, or with 10% misreading) and applies a vote rule: one rule while the learner is off, another once it is on. Four rule pairs: majority then any-yes, all-yes then any-yes, all-yes then majority, and any-yes then all-yes. Two kinds of memory: a latch (once everyone has said yes together, trust stays on forever) and a one-step memory (trust is on only right after such a moment). Sixteen cases of five parts each. Predictions were committed first. I ran a quick smoke test of two single numbers before committing them; I did not change anything afterwards. + +## What we found + +| rule pair | coordinator mistakes | latch | one-step memory | +|---|---|---:|---:| +| majority → any yes | none | 0 | 0 | +| all yes → any yes | none | 0 | 0 | +| all yes → majority | none | 0 | 0 | +| any yes → all yes | none | 0 | 0 | +| majority → any yes | 10% | 0.022626 | 0.018100 | +| all yes → any yes | 10% | 0.000826 | 0.121090 | +| all yes → majority | 10% | 0.000826 | 0.110083 | +| any yes → all yes | 10% | 0.008816 | 0.008435 | + +**With a perfect coordinator the whole group never binds.** I predicted it would bind for two of the four pairs. It was zero in all eight cases, for both kinds of memory. That prediction was refuted. + +**With 10% misreading, the latch gives a very weak bond.** My predicted range for majority → any yes was 0.05 to 0.2. The result was 0.022626. That prediction was also refuted. For comparison, the earlier coordinator without a separate learner gave 0.107922. + +**One-step memory is better than permanent memory for two pairs.** At 10% misreading, all yes → any yes gives 0.121090 with one-step memory and 0.000826 with the latch (and 0.110083 and 0.000826 for all yes → majority). I predicted the two kinds of memory would differ in at least five of eight cases; they differed in four, so that prediction was refuted too. After the run, this looks like a one-way effect: once the latch is on, it never goes off, so the learner stops depending on anything, and the four-part group behaves like a plain rule with the learner fixed. I did not test that explanation. + +**The learner mostly stays out.** The strongest bound unit is the coordinator and the three people, without the learner, in most cases (for example 3.0 at no misreading and 1.854569 with 10% misreading). The learner is in the strongest unit in only 2 of 16 cases, as I predicted (at most 7). My last prediction, a drop below 3.0 for all yes → any yes at no misreading, held, but trivially: the value was 0, down from 3.0 for the same rule without a separate learner. + +## What it means + +In these small models, a coordinator that adds a one-way memory does not bind more tightly with its people; the memory sits outside the tightly bound core. This is about these models, not about real platforms. + +## Limits + +One learning rule (everyone said yes together), two kinds of memory, four rule pairs, 0% and 10% misreading. No learner that can forget, and no learning from disagreement. + +## The code + +- Study: [org_frontier/studies/learning_coordinator/](https://github.com/rogerSuperBuilderAlpha/algorithmacy-lab/tree/main/org_frontier/studies/learning_coordinator) +- Predictions: [hypotheses.md](https://github.com/rogerSuperBuilderAlpha/algorithmacy-lab/blob/main/org_frontier/studies/learning_coordinator/hypotheses.md) +- Results: [FINDINGS.md](https://github.com/rogerSuperBuilderAlpha/algorithmacy-lab/blob/main/org_frontier/studies/learning_coordinator/FINDINGS.md) + +Run it: `python3 tools/start.py`, then `python org_frontier/studies/learning_coordinator/run.py --write`. +The analysis harness is an AI assistant working around IIT 4.0 and PyPhi in the open repo; the numbers +are PyPhi's. diff --git a/substack/experiments/README.md b/substack/experiments/README.md index 7aa5532e9..3890121c6 100644 --- a/substack/experiments/README.md +++ b/substack/experiments/README.md @@ -11,6 +11,7 @@ every number in it. | 2026-11-28 | [The weakest seam switches when a different state takes over, and we predicted the rate for six and seven people](2026-11-28-the-switch-point.md) | [`org_frontier/studies/switch_law/`](../../org_frontier/studies/switch_law/) | | 2026-11-28 | [Under noise, a parity coordinator loses half its value with every added person, and an all-yes coordinator stops gaining at a rate we could predict](2026-11-28-hubs-under-noise.md) | [`org_frontier/studies/hub_noise_laws/`](../../org_frontier/studies/hub_noise_laws/) | | 2026-11-28 | [We guessed a neat swap rule for two kinds of noise. It worked in 11 of 16 cases and broke in the wide ones.](2026-11-28-a-swap-that-half-worked.md) | [`org_frontier/studies/noise_swap/`](../../org_frontier/studies/noise_swap/) | +| 2026-11-28 | [A coordinator that learns to trust does not hold the group together, and the learner mostly stays on the sidelines](2026-11-28-a-coordinator-that-learns.md) | [`org_frontier/studies/learning_coordinator/`](../../org_frontier/studies/learning_coordinator/) | | 2026-11-28 | [Noise on the relay and the last hop together multiplies, and a majority keeps almost all of its bond](2026-11-28-noise-twice.md) | [`org_frontier/studies/double_noise/`](../../org_frontier/studies/double_noise/) | | 2026-11-28 | [Swapping "yes" and "no" in a veto vote changes nothing, even at five parties](2026-11-28-the-mirror-held.md) | [`org_frontier/studies/veto_mirror/`](../../org_frontier/studies/veto_mirror/) | | 2026-11-28 | [We wrote down seven predictions about abstention before running them. All seven held, with a catch.](2026-11-28-the-floor-held.md) | [`org_frontier/studies/abstention_state_rule/`](../../org_frontier/studies/abstention_state_rule/) | From 0770eb0a1372a99411f876c306f0ebacbc6a615c Mon Sep 17 00:00:00 2001 From: Roger Hunt Date: Sat, 28 Nov 2026 14:03:20 -0300 Subject: [PATCH 4/6] learning_coordinator: register in catalog, CI check, indexes --- MAP.md | 2 +- README.md | 1 + catalog.json | 13 ++++++++++++- ci/reproduce.json | 10 ++++++++++ 4 files changed, 24 insertions(+), 2 deletions(-) diff --git a/MAP.md b/MAP.md index 7e8032265..8e9aa7576 100644 --- a/MAP.md +++ b/MAP.md @@ -98,7 +98,7 @@ Run the relevant generator after adding content, then verify with its `--check`. |---|---|---| | 171 | questions | `org_frontier/questions/q*_*/` | | 136 | probes | `org_frontier/probes/probe_*.py` | -| 224 | studies | `org_frontier/studies/*/` | +| 225 | studies | `org_frontier/studies/*/` | | 22 | essays | `org_frontier/essays/*.md` | | 9 | foundations experiments | `foundations/*/` with a `FINDINGS.md` | | 10 | literature reviews | `org_frontier/reviews/*/` with a `FINDINGS.md` | diff --git a/README.md b/README.md index c1e2b00c9..7b740f91f 100644 --- a/README.md +++ b/README.md @@ -419,6 +419,7 @@ Multi-experiment batteries on one theme. - **[Ladder-gate Boolean property classifier](org_frontier/studies/ladder_gate_properties/README.md)** — (anchors + property probes), regime membership is predicted exactly by: - **[Noise on the last hop](org_frontier/studies/last_hop_noise/README.md)** — Exact IIT 4.0 Φ (PyPhi pin `b78d0e342`), every reachable subset in every reachable state. Hypotheses - **[Lazy update: nodes that sometimes keep their last state, on quorum hubs](org_frontier/studies/lazy_update/README.md)** — Exact IIT 4.0 Φ (PyPhi pin `b78d0e342`), every reachable subset in every reachable state. Hypotheses +- **[A coordinator that learns to trust](org_frontier/studies/learning_coordinator/README.md)** — Exact IIT 4.0 Φ (PyPhi pin `b78d0e342`), every reachable subset in every reachable state. Hypotheses pushed in - **[Local-triad necklace (V3 #4)](org_frontier/studies/local_triad_necklace/README.md)** — triads on a cycle does **not** invent a new Φ law. The closed AND necklace - **[Lockstep symmetry with four parties: a full census](org_frontier/studies/lockstep_four_parties/README.md)** — Exact IIT 4.0 Φ (PyPhi pin `b78d0e342`), max over reachable states, threshold 1e-9, scored by - **[Lockstep or symmetry: why does the one-sided veto factor?](org_frontier/studies/lockstep_symmetry/README.md)** — One rule, fixed before the run, sorts all 256 strict-mediation forms with zero misses: a form binds iff diff --git a/catalog.json b/catalog.json index e05624701..a2bcb9885 100644 --- a/catalog.json +++ b/catalog.json @@ -3,7 +3,7 @@ "counts": { "question": 171, "probe": 464, - "study": 224, + "study": 225, "foundations": 9, "open": 15 }, @@ -10487,6 +10487,17 @@ ], "runtime": "fast" }, + { + "kind": "study", + "id": "learning_coordinator", + "title": "A coordinator that learns to trust", + "finding": "Exact IIT 4.0 Φ (PyPhi pin `b78d0e342`), every reachable subset in every reachable state. Hypotheses pushed in", + "path": "org_frontier/studies/learning_coordinator", + "reproduce": [ + "python org_frontier/studies/learning_coordinator/run.py --quick" + ], + "runtime": "fast" + }, { "kind": "study", "id": "local_triad_necklace", diff --git a/ci/reproduce.json b/ci/reproduce.json index 2e53fea64..6187e434c 100644 --- a/ci/reproduce.json +++ b/ci/reproduce.json @@ -8386,6 +8386,16 @@ ], "timeout": 300, "source": "org_frontier/studies/double_noise/FINDINGS.md" + }, + { + "name": "learning-coordinator", + "cmd": "python org_frontier/studies/learning_coordinator/run.py --quick", + "expect": [ + "(3,1) r=0.0 latch state=00000 full-group phi=0.000000", + "(2,1) r=0.1 latch state=00000 full-group phi=0.022626" + ], + "timeout": 300, + "source": "org_frontier/studies/learning_coordinator/FINDINGS.md" } ] } From cdaf3c09ee5255757b1ad94de5c8a530d2c3a77a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 28 Nov 2026 17:03:26 +0000 Subject: [PATCH 5/6] docs: pin atlas snapshot --- research-atlas/snapshot.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/research-atlas/snapshot.json b/research-atlas/snapshot.json index eb236c328..7b5e4f73c 100644 --- a/research-atlas/snapshot.json +++ b/research-atlas/snapshot.json @@ -1,7 +1,7 @@ { - "revision": "b6b2cc448fb29281abb88ba6e4de3f2abdf6d64c", + "revision": "0770eb0a1372a99411f876c306f0ebacbc6a615c", "indexes": { - "catalog.json": "e056247011b8df144472107493132acd9b3433c8", + "catalog.json": "a2bcb988562e231a589f95090116efcc7ace6cd6", "research-atlas/cards.json": "b049d417c6c9a693f4fa44a53237e3bc9bc4c31b" } } From 6653e09a0ca2ff77d2595ed4961afac249227db5 Mon Sep 17 00:00:00 2001 From: Roger Hunt Date: Sat, 28 Nov 2026 14:03:57 -0300 Subject: [PATCH 6/6] learning_coordinator: backlog item 5 --- org_frontier/studies/learning_coordinator/BACKLOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/org_frontier/studies/learning_coordinator/BACKLOG.md b/org_frontier/studies/learning_coordinator/BACKLOG.md index 28bd4d43d..1301390f4 100644 --- a/org_frontier/studies/learning_coordinator/BACKLOG.md +++ b/org_frontier/studies/learning_coordinator/BACKLOG.md @@ -5,3 +5,4 @@ 2. **Learning from disagreement**: L latches when the parties disagree with S, quota tightens. 3. **Two learner bits** (a counter to two): seven nodes, expensive. 4. **Why does one-step memory beat permanent memory at r = 0.1 for (3,1) and (3,2)?** Compare repertoires of {S, L, P_k}. +5. **Does a reset-able latch also stay out of the core?** Same as item 1 but with reset probability 0.1 and 0.5.