Skip to content

Commit c2808cd

Browse files
committed
fix: match delayed-revision Bayes targets to cumulative input
1 parent 00dd477 commit c2808cd

3 files changed

Lines changed: 33 additions & 7 deletions

File tree

‎research/delayed_revision_reference/README.md‎

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,31 +4,36 @@
44

55
## Evidence claim to audit
66

7-
The current marginal posterior can be sufficient to predict a hidden regime **before** a correction schedule becomes visible while failing to preserve the information needed to update after the schedule arrives. For any 1≤j<n, the self-contained encoder must distinguish all 2^n old bit vectors to answer every legal delayed revision exactly. For n=12, this is 4096 classes / 12 fixed bits, with 10 extra tags when separately retaining the current count-posterior label. If the schedule arrives **before encoding**, the calibrated accepted-report count is sufficient. An external archive can supply the old count at corrected slots; with j=6, its numeric message has 7 values / 3 bits. These omit archive/verification cost and assume full trusted versions.
7+
The current marginal posterior can be sufficient to predict a hidden regime **before** a correction schedule becomes visible while failing to preserve the information needed to update after the schedule arrives. For any 1≤j<n, the self-contained encoder must distinguish all 2^n old bit vectors to answer every legal delayed revision exactly. For n=12, this is 4096 classes / 12 fixed bits. Separately retaining the current count-posterior label requires an additional tag of up to 10 bits inside its largest fiber; the joint optimum remains 12 bits. If the schedule arrives **before encoding**, the calibrated accepted-report count is sufficient. An external archive can supply the old count at corrected slots; with j=6, its numeric message has 7 values / 3 bits. These omit archive/verification cost and assume full trusted versions.
88

99
The upstream exact six-revision expected Brier risks (unhalved 3-class score) are 0.170499060115450 for aggregate-only and 0.106036369270665 for full Bayes, a gap 0.064462690844785. This is inherited **mathematical** evidence, not a novel neural effect or fresh independent confirmation. The preregistered authorization gain at BB-CQ-04 was 0.006206757142 below the 0.02 practical gate, so it remains **HEADROOM_BLOCKED** for that task.
1010

1111
## Exact evaluation decomposition
1212

13-
With `H` containing the full history and accepted replacements, and `G_r` the reduced information after a fixed disclosure prefix, let `p_H=P(K|H)` and `p_r=P(K|G_r)`. Then `p_r=E[p_H|G_r]`. For any predictor `a` computed only from `G_r`:
13+
Let `X` be the named old bit vector, `S` the correction schedule and `Y` the accepted replacements. Define `H=sigma(S,X,Y)` and `G_r=sigma(S,sum(X),Y,X[S[:r]])` for a fixed, outcome-independent disclosure order. With `p_H=P(K|H)` and `p_r=P(K|G_r)`, conditional expectation gives `p_r=E[p_H|G_r]`. For any predictor `a` computed only from `G_r`:
1414

1515
```
1616
E[Brier(a,K)] - E[Brier(p_H,K)]
1717
= E[||a-p_r||_2^2] + E[||p_r-p_H||_2^2].
1818
```
1919

20-
The first term is **model approximation error**, estimated on independent issuer roots. The second is **irreducible information loss** and is known exactly for this finite generator. An observational probe might estimate `p_r` accurately while a native hidden-state edit does not transport it forward. Label that outcome observational.
20+
The first term is **model approximation error**, estimated on independent issuer roots. The second is **irreducible information loss** for the explicitly count-restricted arm and is known exactly for this finite generator. An observational probe might estimate `p_r` accurately while a native hidden-state edit does not transport it forward. Label that outcome observational.
21+
22+
A raw-stream recurrent model receives all of `X` before `S` is revealed. After receiving `S` and `Y`, its complete input history is `H`; its final Bayes comparator is `p_H` for every `r`. Repeating old bits can help the model recover forgotten information, while the optimal full-input posterior stays fixed. Restricting hidden-state capacity leaves the model free to retain functions of `X` other than its total, so capacity alone does not make its output `G_r`-measurable. The count-restricted formula requires an enforced old-history interface containing only `sum(X)` plus the declared disclosures.
23+
24+
For example, with `n=4`, `S=(0,)`, `Y=(0,)`, the old vectors `(1,0,0,0)` and `(0,1,0,0)` have the same `G_0` and different accepted counts. Their full-input Bayes posteriors differ. Across the finite population, using `a=p_H` gives expected excess relative to `p_r` equal to `-E[||p_r-p_H||_2^2]`, which is negative whenever information is lost. This witness prevents interpreting that quantity as nonnegative approximation error for a learner with full old-input access.
2125

2226
## Gym protocol for BPD / LoopedTransformers / Control-Harness
2327

2428
Fix and hash the full source generator, exact oracle, model checkpoints, event grammar and all arms **before** sampling the first development root. Separate early from delayed schedule cohorts and include full replay, calibrated early-count, reduced-information Bayes, archive-verified delta, stale-native, and physically matched neural shams. Freeze `r=0..j` and the number of evidence amendments per root.
2529

26-
The primary registered neural endpoint should be root-level **reduced-info-relative excess Brier**, `Brier(a,K)-Brier(p_r,K)`, with root-paired difference against a strong baseline at identical input privileges. Report the information loss `Brier(p_r,K)-Brier(p_H,K)` separately. For a causal-mechanism claim, intervene on native recurrent states at fixed model and dose, measure final task behavior and future logits; match random/gauge/nuisance directions and include a no-edit reference. A full-input replay advantage measures input handling, not a discovered causal fiber.
30+
The primary registered neural endpoint should be root-level **input-matched excess Brier**, `Brier(a,K)-Brier(p_F,K)`, where `F` is that arm's complete input history and `p_F=P(K|F)`. Use a root-paired difference against a strong baseline with identical input privileges. The raw-stream arm has `F=H` after all replacements arrive. An enforced count-restricted arm has `F=G_r` and reports `Brier(p_r,K)-Brier(p_H,K)` separately. The expected approximation term is nonnegative for the matching information set; an empirical paired estimate can fluctuate below zero. For a causal-mechanism claim, intervene on native recurrent states at fixed model and dose, measure final task behavior and future logits; match random/gauge/nuisance directions and include a no-edit reference. A full-input replay advantage alone establishes input handling.
2731

2832
The independent unit is one issuer/source root when reusing a frozen model; for cross-training generalization count independently initialized **model roots**. Each root's 12 report slots, 3 correction sizes, disclosure stages, shams and decisions are repeated observations on that root. Do not count them as extra replications. Multiple exploration-selected endpoints must use a separately reserved confirmation cohort.
2933

30-
The native study must pass the existing [mechanistic resolution preflight](../../skills/evalmath-mechinterp-power/SKILL.md). Calibrate a physically equal-dose sham envelope on independent development roots, state a minimum scientifically meaningful Brier change, establish sufficient task headroom and selection-family adjustment. The 95/95 maximum-sham order-statistic rule needs >=59 independent calibration units under the published conditions. **Zero external/new protected roots opened** by this crosswalk.
34+
The native study must pass the existing [mechanistic resolution preflight](../../skills/evalmath-mechinterp-power/SKILL.md). Calibrate physically equal-dose shams on independent development roots, state a minimum scientifically meaningful Brier change, establish sufficient task headroom and selection-family adjustment. For a mean Brier effect, use the same paired root-mean statistic and a stated uncertainty procedure for the sham comparison. The 95/95 maximum-sham order-statistic rule needs >=59 independent calibration units under the published conditions and provides a per-root tolerance statement. A mean-effect gate requires a mean-matched sham estimator. **Zero external/new protected roots opened** by this crosswalk.
3135

3236
## Independent oracle scope
3337

34-
`python -m unittest discover -s research/delayed_revision_reference -p 'test_*.py' -v` checks the conditional posterior through raw bit-vector and named-schedule enumeration for small n, exact Brier variance decomposition and memory accounting. It does not claim a second full n=12 enumeration or a new Lean proof. [BB-CQ-05's archived receipt](https://github.com/patrickdugan/beyond-bayes/blob/main/results/bb_cq05_exact_v1.json) remains the canonical larger-domain source with source-hashed reproduction.
38+
`python -m unittest discover -s research/delayed_revision_reference -p 'test_*.py' -v` checks the conditional posterior through raw bit-vector and named-schedule enumeration for small n, exact Brier variance decomposition and memory accounting. A named-slot collision and a negative full-input-versus-reduced expected excess check enforce the comparator's information contract. It does not claim a second full n=12 enumeration or a new Lean proof. [BB-CQ-05's archived receipt](https://github.com/patrickdugan/beyond-bayes/blob/main/results/bb_cq05_exact_v1.json) remains the canonical larger-domain source with source-hashed reproduction.
39+

‎research/delayed_revision_reference/bridge.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,11 @@ def independent_raw_oracle(n: int, slots: tuple[int,...], old_m: int,
6868

6969
def final_full(n: int, old: tuple[int,...], slots: tuple[int,...],
7070
new: tuple[int,...]):
71+
"""Bayes for the complete old-input stream after S and all Y arrive.
72+
73+
This is the input-matched final comparator for a learner that received
74+
named old bits; further old-bit disclosures repeat existing input.
75+
"""
7176
if len(old)!=n or len(slots)!=len(new):
7277
raise ValueError("wrong dimensions")
7378
accepted=list(old)
@@ -121,3 +126,4 @@ def information_capacity(n:int,j:int):
121126
"extra_fixed_tag_bits":(biggest-1).bit_length(),
122127
"verified_old_sum_message_bits":j.bit_length(),
123128
"early_count_field_bits":n.bit_length()}
129+

‎research/delayed_revision_reference/test_bridge.py‎

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
from itertools import combinations, product
66
from fractions import Fraction as Q
77
sys.path.insert(0, str(Path(__file__).resolve().parent))
8-
from bridge import analytic, independent_raw_oracle, raw_population, information_capacity
8+
from bridge import (analytic, independent_raw_oracle, raw_population,
9+
information_capacity, final_full)
910

1011

1112
class DelayedRevisionTests(unittest.TestCase):
@@ -34,6 +35,19 @@ def test_full_reveal_and_variance_decomposition(self):
3435
self.assertEqual(b["mass"],Q(1))
3536
self.assertGreater(rows[0]["regret"],0)
3637

38+
def test_full_input_requires_its_own_bayes_comparator(self):
39+
n=4;slots=(0,);new=(0,)
40+
old_a=(1,0,0,0);old_b=(0,1,0,0)
41+
reduced_a=analytic(n,slots,sum(old_a),new,())
42+
reduced_b=analytic(n,slots,sum(old_b),new,())
43+
self.assertEqual(reduced_a,reduced_b)
44+
self.assertNotEqual(final_full(n,old_a,slots,new),
45+
final_full(n,old_b,slots,new))
46+
row=raw_population(3,(1,),0)
47+
full_input_excess=row["full_brier"]-row["limited_brier"]
48+
self.assertEqual(full_input_excess,-row["regret"])
49+
self.assertLess(full_input_excess,Q(0))
50+
3751
def test_exact_capacity_contract(self):
3852
result=information_capacity(12,6)
3953
self.assertEqual(result,{"histories":4096,
@@ -55,3 +69,4 @@ def test_invalid_evidence_rejected(self):
5569

5670
if __name__=="__main__":
5771
unittest.main()
72+

0 commit comments

Comments
 (0)