Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
145e6ba
feat(bpd): synthetic cross-loop reader intervention and norm-matched …
patrickdugan Nov 21, 2026
b905704
test(bpd): outlier patch normalization and matched-dose sham checks
patrickdugan Nov 21, 2026
28e9141
docs(bpd): preregisterable Inkling cross-loop routing hypotheses and …
patrickdugan Nov 21, 2026
6533aa1
ci: test Inkling source-only instruments on Python 3.10 and 3.12
patrickdugan Nov 21, 2026
bb6f6f4
feat(bpd): independently replay trained-gate model and full before/af…
patrickdugan Nov 21, 2026
5054043
test(bpd): replay independent oracle, physical dose and tampered rece…
patrickdugan Nov 21, 2026
5cbd5de
ci(bpd): execute independent trained-gate receipt replay and tamper t…
patrickdugan Nov 21, 2026
5e3f7bd
docs(bpd): attach cross-audited trained-gate synthetic control and na…
patrickdugan Nov 21, 2026
25f9380
feat(bpd): bounded native pretrained TRM recurrent-state patching and…
patrickdugan Nov 21, 2026
97679e9
test(bpd): native TRM recurrence parity, dose parity, clue validation…
patrickdugan Nov 21, 2026
af291b1
ci(bpd): execute one-root SHA-pinned pretrained TRM recurrent patch o…
patrickdugan Nov 21, 2026
53a567e
fix(ci): execute pretrained TRM under a single bounded timeout command
patrickdugan Nov 21, 2026
2f94ada
feat(bpd): uniquely solvable harder Sudoku roots and configurable nat…
patrickdugan Nov 21, 2026
a54adac
fix(bpd): bound development cohort at up to 32 independent Sudoku worlds
patrickdugan Nov 21, 2026
27961fb
ci(bpd): run SHA-pinned 24-root hard Sudoku patch depth/phase sweep o…
patrickdugan Nov 21, 2026
36788a8
results(bpd): native 24-root pretrained TRM paired recurrence, nonloc…
patrickdugan Nov 21, 2026
5693cde
feat(bpd): standalone independent native TRM receipt verifier for roo…
patrickdugan Nov 21, 2026
870efa3
ci(bpd): replay full native pretrained matrix through independent rec…
patrickdugan Nov 21, 2026
7d2cb79
feat(bpd): enable 50-blank uniquely solvable fresh Sudoku development…
patrickdugan Nov 21, 2026
01d7271
fix(bpd): audit paired roots within each independently seeded difficu…
patrickdugan Nov 21, 2026
ceff140
ci(bpd): add fresh uniquely solvable 50-blank native TRM panel and cr…
patrickdugan Nov 21, 2026
4ec147f
feat(bpd): native pretrained TRM verifier-gated adaptive recurrence w…
patrickdugan Nov 21, 2026
6b062d3
test(bpd): prove real z_H/z_L recurrence continuation, verifier-stop …
patrickdugan Nov 21, 2026
91c7888
ci(bpd): run resumable pretrained TRM online verifier exit on fresh 5…
patrickdugan Nov 21, 2026
3b079be
audit(bpd): independently recheck native verifier-exit trace, Sudoku …
patrickdugan Nov 21, 2026
da1dfbb
test(bpd): audit native verifier-exit tampered Sudoku grades, early s…
patrickdugan Nov 21, 2026
2df4e3a
ci(bpd): run independent native verifier-exit receipt audit with tamp…
patrickdugan Nov 21, 2026
b2b2276
results(bpd): pin native online verifier-exit original 24-root eviden…
patrickdugan Nov 21, 2026
d85d0e3
docs(bpd): correct explicit native L-level operation totals for adapt…
patrickdugan Nov 21, 2026
74789cd
docs(bpd): archive repeatable 30.68 percent native exit speedup and i…
patrickdugan Nov 21, 2026
eb2d5ee
ci: separate dependency-free source checks from Torch-dependent pretr…
patrickdugan Nov 21, 2026
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
32 changes: 32 additions & 0 deletions .github/workflows/bpd-inkling-reader-source.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: BPD Inkling reader source checks
on:
push:
branches:
- research/inkling-cross-loop-causal-20261121
paths:
- "mechinterp/bpd/experiments/inkling_reader_v0/**"
- ".github/workflows/bpd-inkling-reader-source.yml"
pull_request:
paths:
- "mechinterp/bpd/experiments/inkling_reader_v0/**"
- ".github/workflows/bpd-inkling-reader-source.yml"
workflow_dispatch:
permissions:
contents: read
jobs:
source-test:
runs-on: ubuntu-latest
timeout-minutes: 8
strategy:
fail-fast: false
matrix:
python-version: ['3.10', '3.12']
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Run source-only unittest fixtures
run: |
python -m unittest discover -s mechinterp/bpd/experiments/inkling_reader_v0 -p 'test_reader_probe.py' -v
python -m unittest discover -s mechinterp/bpd/experiments/inkling_reader_v0 -p 'test_positive_control_audit.py' -v
101 changes: 101 additions & 0 deletions .github/workflows/bpd-native-trm-inkling-pilot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
name: Pretrained 7M TRM native boundary pilot

on:
push:
branches:
- research/inkling-cross-loop-causal-20261121
paths:
- "mechinterp/bpd/experiments/inkling_reader_v0/native_trm_pilot.py"
- "mechinterp/bpd/experiments/inkling_reader_v0/test_native_trm_pilot.py"
- ".github/workflows/bpd-native-trm-inkling-pilot.yml"
pull_request:
paths:
- "mechinterp/bpd/experiments/inkling_reader_v0/native_trm_pilot.py"
- "mechinterp/bpd/experiments/inkling_reader_v0/test_native_trm_pilot.py"
- ".github/workflows/bpd-native-trm-inkling-pilot.yml"
workflow_dispatch:

permissions:
contents: read

concurrency:
group: native-trm-${{ github.ref }}
cancel-in-progress: true

jobs:
cpu-model:
runs-on: ubuntu-latest
timeout-minutes: 20
env:
HF_HUB_DISABLE_TELEMETRY: "1"
HF_HUB_DISABLE_XET: "1"
OMP_NUM_THREADS: "2"
OPENBLAS_NUM_THREADS: "1"
MKL_NUM_THREADS: "2"
PYTHONDONTWRITEBYTECODE: "1"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install CPU-only runtime
run: |
python -m pip install --upgrade pip
python -m pip install "torch==2.5.1+cpu" --index-url https://download.pytorch.org/whl/cpu
python -m pip install "numpy>=1.24,<3" "huggingface_hub>=0.24,<1"
- name: Unit-test native recurrence and dose checks
run: >-
python -m unittest
mechinterp.bpd.experiments.inkling_reader_v0.test_native_trm_pilot -v
- name: Run SHA-pinned pretrained pilot and harder paired development cohort
if: github.event_name == 'push'
run: |
set -euo pipefail
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_pilot \
--model gaoxin492 --roots 1 --holes 22 --outer-steps 1 \
--out runs/inkling_native_trm_pilot_20261121.json
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_pilot \
--model gaoxin492 --roots 24 --holes 40 --outer-steps 1 \
--relative-dose 0.5 --patch-h-cycle 1 \
--out runs/inkling_native_trm_hard_early_20261121.json
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_pilot \
--model gaoxin492 --roots 24 --holes 40 --outer-steps 1 \
--relative-dose 0.5 --patch-h-cycle 2 \
--out runs/inkling_native_trm_hard_late_20261121.json
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_pilot \
--model gaoxin492 --roots 24 --holes 40 --outer-steps 2 \
--relative-dose 0.5 --patch-h-cycle 1 \
--out runs/inkling_native_trm_hard_depth2_20261121.json
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_pilot \
--model gaoxin492 --roots 24 --seed 20261122 --holes 50 --outer-steps 1 \
--relative-dose 0.5 --patch-h-cycle 1 \
--out runs/inkling_native_trm_50blank_depth1_20261122.json
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_pilot \
--model gaoxin492 --roots 24 --seed 20261122 --holes 50 --outer-steps 2 \
--relative-dose 0.5 --patch-h-cycle 1 \
--out runs/inkling_native_trm_50blank_depth2_20261122.json
- name: Independently replay Sudoku outcomes and raw dose receipts
if: github.event_name == 'push'
run: |
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_receipt_audit \
runs/inkling_native_trm_pilot_20261121.json \
runs/inkling_native_trm_hard_early_20261121.json \
runs/inkling_native_trm_hard_late_20261121.json \
runs/inkling_native_trm_hard_depth2_20261121.json \
runs/inkling_native_trm_50blank_depth1_20261122.json \
runs/inkling_native_trm_50blank_depth2_20261122.json \
--out runs/inkling_native_trm_receipt_audit.json
- name: Retain native model evidence
if: always()
uses: actions/upload-artifact@v4
with:
name: bpd-native-trm-cpu-pilot
path: runs/inkling_native_trm_*.json
if-no-files-found: warn
retention-days: 7
73 changes: 73 additions & 0 deletions .github/workflows/bpd-native-trm-verifier-exit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: Pretrained TRM native verifier-gated recurrence

on:
push:
branches:
- research/inkling-cross-loop-causal-20261121
paths:
- "mechinterp/bpd/experiments/inkling_reader_v0/native_trm_exit.py"
- "mechinterp/bpd/experiments/inkling_reader_v0/test_native_trm_exit.py"
- ".github/workflows/bpd-native-trm-verifier-exit.yml"
pull_request:
paths:
- "mechinterp/bpd/experiments/inkling_reader_v0/native_trm_exit.py"
- "mechinterp/bpd/experiments/inkling_reader_v0/test_native_trm_exit.py"
- ".github/workflows/bpd-native-trm-verifier-exit.yml"
workflow_dispatch:

permissions:
contents: read

concurrency:
group: native-trm-exit-${{ github.ref }}
cancel-in-progress: true

jobs:
native-exit:
runs-on: ubuntu-latest
timeout-minutes: 20
env:
HF_HUB_DISABLE_TELEMETRY: "1"
HF_HUB_DISABLE_XET: "1"
OMP_NUM_THREADS: "2"
OPENBLAS_NUM_THREADS: "1"
MKL_NUM_THREADS: "2"
PYTHONDONTWRITEBYTECODE: "1"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install CPU-only inference dependencies
run: |
python -m pip install --upgrade pip
python -m pip install "torch==2.5.1+cpu" --index-url https://download.pytorch.org/whl/cpu
python -m pip install "numpy>=1.24,<3" "huggingface_hub>=0.24,<1"
- name: Run native recurrent state and verifier unit tests
run: >-
python -m unittest
mechinterp.bpd.experiments.inkling_reader_v0.test_native_trm_exit -v
- name: Run independent 24-root 50-blank pretrained adaptive exit comparison
if: github.event_name == 'push'
run: |
timeout --signal=TERM --kill-after=15s 780s \
python -m mechinterp.bpd.experiments.inkling_reader_v0.native_trm_exit \
--model gaoxin492 --roots 24 --seed 20261123 --holes 50 \
--wall-limit 600 \
--out runs/trm_online_adaptive_50blank_20261123.json
- name: Independent offline receipt audit and adversarial test fixtures
run: |
python -m unittest mechinterp.bpd.experiments.inkling_reader_v0.test_native_trm_exit_audit -v
if [ -f runs/trm_online_adaptive_50blank_20261123.json ]; then
python -m mechinterp.bpd.experiments.inkling_reader_v0.audit_native_trm_exit \
--input runs/trm_online_adaptive_50blank_20261123.json \
--out runs/trm_online_adaptive_50blank_20261123.audit.json
fi
- name: Retain signed source-level development evidence
if: always()
uses: actions/upload-artifact@v4
with:
name: bpd-trm-native-verifier-exit
path: runs/trm_online_adaptive_50blank_20261123*.json
if-no-files-found: warn
retention-days: 7
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Native pretrained 7M Attention-TRM: fresh development root campaign

Date: 2026-11-21. The [successful GitHub Actions run](https://github.com/MoralityLabAI/BPD/actions/runs/44902293753) includes the complete JSON evidence in artifact [14706930611](https://github.com/MoralityLabAI/BPD/actions/runs/44902293753/artifacts/14706930611).

Pretrained checkpoint: gaoxin492/TinyRecursiveModels-Sudoku-Extreme-att, step_21700. The checkpoint's expected and checked SHA-256 is
932b5e0df4e90021c21a064d4e716154086c46fda7afa676ea294484a30e38c3.
The recorded code SHA-256 begins 2544738749cc757d. The test uses genuine pretrained recurrent attention/MLP blocks and a raw z_H hidden-state patch after an H-cycle commit. It does NOT exercise Inkling's Attention Residual cross-loop block reader.

## Frozen development surface

24 Sudoku roots were deterministically generated using seeds 20261121 + 101*i for i=0..23. Each problem has 40 blanks and was checked as having exactly one legal solution before model inference. A second independent backtracking enumerator confirmed 24/24 uniquely solvable puzzles after the run. This is a development cohort, with fresh generated examples but no prospective confirmation claim.

The source model has three H cycles and six L cycles per outer step. A patch is applied at the FIRST blank cell, before observing that model's answer, after H-cycle 1 or 2 on the first outer step. The remaining learned recurrence runs to completion. The head-direction vector is the fixed difference between two digit-head rows; the comparison is a seeded random direction, normalized to the same physical L2 dose. Zero-patch and clean runs are additional controls.

The per-sample physical dose is 0.5 × pre-patch state L2 norm, approximately 11.3137. The clean hand-unrolled recurrence reproduces the model's act_step forward exactly (maximum difference 0.0).

## Original results

| Scenario | Clean boards | Head direction | Random direction |
| --- | ---: | ---: | ---: |
| 40 blanks, outer 1, patch H1 | 23/24 | 23/24 | 23/24 |
| 40 blanks, outer 1, patch H2 | 23/24 | 23/24 | 23/24 |
| 40 blanks, outer 2, patch H1 | 24/24 | 24/24 | 24/24 |

| Scenario | Mean absolute digit-logit change, head | Random sham |
| --- | ---: | ---: |
| Outer 1, patch H1 | 0.08677565 | 0.12443353 |
| Outer 1, patch H2 | 0.06420392 | 0.06798894 |
| Outer 2, patch H1 | 0.01284373 | 0.01633112 |

Each mean is across the same 24 source roots and their 81×9 output digit logits. One-step clean failure occurs at root source-sudoku-20263141, cell 35: predicted 5 instead of 2. The H1 intervention changes a different predicted digit at cell 33, while the selected patch cell was index 0. This is evidence of nonlocal downstream dependence on this development example. Two outer steps recovered the correct complete board on every tested root and intervention arm.

The comparison at the same patch phase across outer steps indicates roughly 85.2% reduction in mean absolute head-direction logit change and roughly 86.9% for the random-direction arm. A similar reduction for random noise implies recurrent attenuation rather than a uniquely identified head-direction mechanism. The exact-board endpoint is near ceiling with only one susceptible root.

## Evidence and reproducibility

- Hardware: GitHub hosted CPU, bounded run; no local RTX 5080 allocation.
- Measured execution durations: 21.12 s for H1 one-step, 21.41 s for H2 one-step and 42.34 s for H1 two-step, excluding environment setup and weights download.
- 24 independent source roots, 96 rows per panel, 288 harder-panel observations; four additional one-root smoke rows.
- Complete per-root model identity, input puzzle, exact target, patch site, nominal and realized L2, all digit predictions, selected-cell logits and other output receipts are in the archived JSON files.
- The earlier 22-blank smoke with relative dose 0.2 produced 81/81 correct for all arms and head/random mean-logit changes 0.0602/0.0395. Preserve separately.
- All zero-patch outputs exactly match clean outputs, and no sealed BPD or EvalMath cohorts were opened.

Scientific classification: native pretrained DEVELOPMENT evidence showing reproducible state-dependent output sensitivity, a single nonlocal cell effect, and attenuation across recurrent computation. The experiment did not identify a reusable sparse mechanistic direction above random controls, and did not test the Inkling attention-residual reader. A new preregistered source population with adequate sham power and a memory-suitable native Inkling checkpoint is the appropriate successor.
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
# BPD RLT-EXIT-01: online verifier-gated native pretrained TRM recurrence

**First original result:** development-only, real SHA-pinned pretrained recurrent attention model,
November 21, 2026. [GitHub Actions #44903527858](https://github.com/MoralityLabAI/BPD/actions/runs/44903527858),
[raw artifact #14706404454](https://github.com/MoralityLabAI/BPD/actions/runs/44903527858/artifacts/14706404454).

- Model: gaoxin492/TinyRecursiveModels-Sudoku-Extreme-att, pretrained
checkpoint SHA-256 932b5e0df4e90021c21a064d4e716154086c46fda7afa676ea294484a30e38c3.
- Source: native_trm_exit.py SHA-256
2fd754ce38506787fdf724952ae8c64c1eedb78412b6c6746bd2f5fa9f0a7634.
- Raw original JSON SHA-256
c621861c5fc0b950d23cd30ae4de5ea677d07b893e53ecbfbd0b73b84259f948.
All per-root candidate grids, runtime records, source IDs and model settings
remain in the original Actions artifact.
- Fresh **development** cohort: 24 separate, uniquely solvable 9x9 Sudoku
questions with 50 blanks, seed 20261123 + 101*i for each root.
Prior 40-blank and 50-blank cohorts used seeds 20261121 and 20261122.
- Fixed policy: run two real outer recurrent steps using continued z_H / z_L
states, then grade. Adaptive policy: run one outer step, run an exact Sudoku
clue/row/column/box verifier, and stop immediately when complete.
Otherwise run the second outer step and check again.
- Match controls: identical checkpoint, same 24 tasks, same generated states
from each initialization and first-step candidate string, alternating
policy order across roots to moderate execution-order timing effects.
The verifier only sees the candidate and original question, never the
planted solution. Independent receipt review recomputed Sudoku legality
and per-root depth policy behavior.

## Original measurements

| Metric | Fixed 2 | Online verifier exit |
| --- | ---: | ---: |
| Cases solved completely | 23/24 | 23/24 |
| First outer step solved | 15/24 | 15/24 |
| Additional roots solved on second step | 8 | 8 |
| Subsequent regressions on earlier correct grids | 0 | 0 (stopped) |
| Total outer steps | 48 | 33 |
| Mean outer steps per task | 2.000 | 1.375 |
| Native model forward seconds, total | 10.133934 | 6.974778 |
| End-to-end policy seconds, total | 10.147272 | 6.983677 |
| Exact verifier seconds, total | 0.003163 | 0.002071 |

Result: **31.25% fewer outer recurrent steps**, 31.174% lower measured
native forward seconds, 31.177% lower policy-level elapsed seconds.
These are sums over sequential model calls on a hosted GitHub CPU runner,
not amortized parallel serving, GPU inference throughput or watt-hours.
Each outer step involves three H-cycles with seven L_level calls per
H-cycle (six L followed by one H): 21 calls per step. Across the cohort,
that is 1,008 L_level calls at fixed depth versus 693 with verifier exit.

Exactly 15 roots halted after the first verifier-valid Sudoku grid.
Eight more were successfully completed after two; one remained unsolved
at the permitted depth. The fixed model also solved 23, with zero
observed late-depth regressions among its first-step correct roots.

## Claim boundary

The trained recurrent model is **TRM**, not the native 26B Inkling 2 Mini
Attention Residual architecture. This experiment demonstrates that
task-verifier feedback can save real inference compute with preserved
Sudoku accuracy on a small, exposed development cohort. The model is
not learning an exit gate here. Its exact Sudoku checker is task-specific,
and a general language-model replacement would need externally
trustworthy verification or a calibrated learned stop controller.

One run on 24 roots is not a prospectively powered scientific confirmation.
No additional protected BPD NC09/AMM cohorts were accessed; all historical
gates and verdicts remain unchanged. No model weights were committed.

### Next scientific experiment

Fit a tiny exit-policy predictor on disjoint development roots using
the first-step logit margins, state-change norms, and future verified
outcomes. Compare learned routing to exact-verifier stop and fixed
depth under the same compute budget, with source-root bootstrap and
sham-calibrated minimum effect in EvalMath. Preserve the exact verifier
as an upper-quality source of labels, avoid exposing held-out outcomes
to controller selection, and test the stopping logic across other
reasoning task families. Native Inkling cross-loop readers still require
a separate instrumented checkpoint and memory-suitable runner.


## Independent replay and timing replication

An unchanged-root **development replication** reran the online policy
from the same pinned pretrained checkpoint, with a new source-level
independent receipt audit and adversarial audit unit tests:
[Actions #44903755773](https://github.com/MoralityLabAI/BPD/actions/runs/44903755773),
[artifact #14707545104](https://github.com/MoralityLabAI/BPD/actions/runs/44903755773/artifacts/14707545104).

The retried 24 roots again produced 15 first-step valid puzzles,
23/24 final correct, 48 fixed versus 33 adaptive recurrent steps,
and no first-valid answer regressions. This time the native model
used **6.621843 seconds fixed versus 4.590264 seconds adaptive**,
a 30.67996% measured reduction. The policy wall totals were
6.636706 versus 4.600248 seconds, a 30.68477% reduction. The
runtime difference between the original and replication reflects
hosted-run timing variability; the checker and recurrence counts
agree exactly.

The companion independent audit independently rechecked every
saved candidate's full Sudoku legality, first-step prefix identity,
stop correctness and step/time totals. Its replay verdict is PASS,
with input receipt SHA-256
8945a80beb3ed3736a76b201cc42428c4463b61a32e0fbec4013b32b4eab1443.
This independent audit rechecks outputs and receipts without
reexecuting pretrained weights. Preserve the first and second run
as separate source-labeled development evidence.

A DataGoblin adapter on branch research/inkling-varloop-distill-20261121
can import this source/audit pair to emit train-INELIGIBLE
controller task-format traces for RLT gym prototyping, preserving
all 24 development roots outside the training corpus.
Loading
Loading