# Four-beam tab-namer publication bundle

This directory accompanies
[`../tab-namer-four-beams.html`](../tab-namer-four-beams.html). It contains the
source and row-level evidence needed to inspect the algorithm and recompute the
published clean-development and sealed-final summaries. It is a research
record, not a packaged PorkiCoder runtime.

## Final result

The frozen B-9500 beam-4 system consumed the preregistered sealed 1,000 once.
The relative result reproduced: locked Hybrid A scored 6.197 versus FLAN's
5.446, paired +0.752 (95% paired-bootstrap interval 0.611 to 0.891;
603/67/330). The bounded-32 system scored 6.155 versus 5.421, paired +0.733
(0.593 to 0.873; 601/68/331).

The conjunctive final gate did **not** clear. In the fixed 40-row,
reference-free, identity-blind Codex audit, ours was useful on 19/40 rows
(47.5%) against a preregistered 60% requirement. Ours still beat/tied/lost
FLAN 18/9/13. Four of five gate criteria passed; absolute audit usefulness was
the sole failure. The final set is consumed and must not be used for tuning.

## What is included

- `scripts/`: exact generation, centroid, glue, Gemini-judge, blind-audit,
  structural-audit, and final-summary source.
- `data/` and `train/`: local imports required by those scripts.
- `assets/tokenizer/` and `assets/technical_250m_vocab.json`: exact tokenizer
  and reduced-vocabulary map used by the decoder.
- `assets/b9500/`: the checkpoint configuration, but not the 134 MiB weight
  tensor.
- `evidence/tasks_dev1000.jsonl` and the `*_dev1000.jsonl` files: the earlier
  reusable clean-development inputs and frozen outputs.
- `evidence/tasks_final1000.jsonl`: the formerly sealed, now consumed final
  inputs.
- `evidence/*_final1000.jsonl`: frozen raw, centroid, locked-glue, bounded-glue,
  and FLAN candidates from the one-shot run.
- `evidence/gemini_final.judge.scored.jsonl`: all 1,000 row-level anonymous
  Flash-Lite scores after deterministic unblinding.
- `evidence/codex_audit/`: blinded packet, pre-unblinding judgments, private
  mapping, manifest, and summaries.
- `evidence/protocol_frozen.json`: protocol hashed before final generation.
- `evidence/final_gate.summary.json`: authoritative aggregate result and
  deterministic confidence intervals.
- `evidence/structural_audit.json`: aggregate decoder/glue contract checks.
- `FINDINGS.md`: full campaign and final-gate narrative.
- `SHA256SUMS`: hashes for every file in this directory except the manifest
  itself.

## Verify the frozen bundle

From this directory:

```bash
sha256sum -c SHA256SUMS
```

The two load-bearing pre-run hashes are:

- sealed tasks:
  `4694f1e4b5269b525fd8fb595f45b9ce65d5f831fdd981537da07479831b6874`;
- frozen protocol:
  `238e1df1ba77e7583d0e9f032580a3bb85705f08cd2656d0c307de32c55c3789`.

## Recompute the published final summary

Create a Python 3.11 environment and install `requirements.txt`, then run:

```bash
python scripts/summarize_tab_namer_final_gate.py \
  --scores evidence/gemini_final.judge.scored.jsonl \
  --judge-summary evidence/gemini_final.judge.summary.json \
  --audit-primary evidence/codex_audit/summary_vs_flan_locked.json \
  --audit-secondary evidence/codex_audit/summary_vs_flan_bounded32.json \
  --structural-audit evidence/structural_audit.json \
  --protocol evidence/protocol_frozen.json \
  --bootstrap-replicates 100000 \
  --bootstrap-seed tab-namer-final-gate-bootstrap-v1 \
  --out /tmp/final_gate.summary.json
```

The result must match `evidence/final_gate.summary.json`.

## Regenerate the raw beam output

The exact decoder source is included. Supply the separately stored B-9500
weight tensor whose SHA-256 is
`0f45a1fef0b549bac512243df0aadad64aedec2a6ade7c17af730247b0b3d52a`:

```bash
python scripts/generate_constrained_titles.py \
  --model /path/to/B-9500-step-9500 \
  --tasks evidence/tasks_final1000.jsonl \
  --tokenizer assets/tokenizer \
  --vocab-map assets/technical_250m_vocab.json \
  --constraint-mode source-words --strip-wrapper \
  --max-content-words 2 --max-source-length 160 \
  --max-new-tokens 8 --num-beams 4 --length-penalty 1 \
  --output /tmp/beam4_raw_final1000.jsonl
```

The output must hash to
`afc3198b622d25c6cc800c0365880c010bd67299bf887d30025a0409c1efc125`.
Generic-title banning remains off, and the default source-word cap is 96.

## Availability boundary

The bundle makes the previously unlinked scripts directly inspectable and
ships all scored inputs, outputs, judgments, and small deterministic assets.
It intentionally does not duplicate the 134 MiB FP32 B-9500 weights, the
294 MiB FLAN benchmark weights, or the 249 MiB IDF source corpus. Their hashes
and exact roles are fixed in `evidence/protocol_frozen.json`; frozen centroid
and candidate outputs are included so every reported score and decision can be
recomputed without those large artifacts.

The separate PorkiCoder INT8 integration is not a byte-identical substitute
for this FP32 research run. Its parity and latency record lives in the product
bundle manifest, not in the final-gate claim.
