# Session 74: The glyph reader fails its full-page controls

The frozen glyph reader **fails both separate solved-page tests**. It gives **257 correct accepted labels and no wrong accepted labels in the rows whose counts align**, but eight other rows have segmentation mismatches. Verified accepted coverage is only **59.52% and 60.55%**, below the declared 95% requirement. The unknown opening pages were **not run through this reader**.

This closes the bounded recognition experiment without supplying an independent confirmation of the opening transcription. No source correction, cipher key or new plaintext is established. The frozen model, raw predictions, abstentions and failure crops are retained.

## The test promised before looking at its results

[Session 73](SESSION_73.md) exposed substantial errors in a manual first pass and the limited value of a subsequent master-guided review. The new question was whether an image-only algorithm could pass other solved pages before checking unknown text.

The [plan](glyph_reader_plan.json) was saved before the segmentation pilot or separate-page recognition. It divided the sources as follows:

| Role | Archive images | Use |
|---|---|---|
| Training | 01, 05, 06, 10 | Known source labels assigned to eligible glyph crops |
| Development | 09, 13 | Geometry diagnostics and a declared grid of distance/margin thresholds |
| Separate test | 07, 08 | One final test after freezing the implementation and model |
| Conditional target | 17, 18, 19 | Opening section, only if the separate-page tests pass |

The labels name the **ciphertext rune shapes on the images**, not decrypted letters. Some training and test pages are solved through transformations; their plaintext letters are not used as labels for the original ciphertext glyphs.

The pass criteria were fixed: **no wrong accepted labels, no unresolved segmentation insertion/deletion and at least 95% accepted coverage on each test page**. Uncertain shapes must be left unresolved. Failure means stopping before target recognition, not adjusting the method after the test and continuing to call the same pages held out.

## What was built

The reader handles **standard-size black runes** in a fixed central text window. Red glyphs, enlarged initials, punctuation, numeric blocks and illustrations are outside its recognition scope. Even a pass would therefore not certify the complete 729-rune opening section or its punctuation.

It finds text rows from ink projections, identifies connected components under fixed geometric bounds, and normalizes the complete ink within each proposed glyph box onto a 128-pixel square canvas while preserving aspect ratio. Each shape is compared with the learned pixel templates. A label is accepted only if its distance is within the frozen limit and it sufficiently outranks the next distinct label. Otherwise the output is `?`.

The final training bank contains **280 glyph crops covering all 29 labels**. Eighteen training rows were discarded because their counts did not agree with the known row or because they overlapped red text. Count agreement permits sequential training-label assignment, but does not independently prove every proposed box is a complete glyph.

Only **60 development glyphs** were eligible for threshold fitting. The chosen limits accept **58**, with no accepted disagreement on that development subset. The distance limit is **0.10** and the minimum distinct-label margin is **0.10**. These are fitted development results, not the separate-page outcome. Development rows excluded from fitting remain in the record.

## Development caught genuine extractor problems

The first pilot let illustration fringes behave like glyphs and clipped some right-side text. Applying component bounds before cropping individual rows removed long decoration fragments that could otherwise be sliced into apparently letter-height pieces.

A training fixture also exposed an error in component-only masks: a disconnected interior stroke was omitted, making a Y crop look identical to U. Eight-neighbor connectivity and retaining all ink within a proposed glyph box corrected that problem before the separate test.

The [development history](glyph74_development_history.json) and [earlier failed diagnostic](glyph74_development_failure.json) preserve these issues. The earlier diagnostic is not a replayable frozen-model result. The final [freeze](glyph74_freeze.json) pins the implementation, settings, templates, training records and fitting-image hashes. No test-page result was used for subsequent adjustment.

## Reading and evaluation were separate operations

The image-reading command consumes the frozen bank and the selected JPEGs. It does **not import the master transcription loader**. Its raw predictions were saved and hashed before evaluation. The evaluation command subsequently loads the known reference labels and compares the outputs.

This is an algorithmic separation of recognition and evaluation, not a blind human reading. The same assistant has previously investigated these images and the unknown section. The training labels also derive from the retained source transcription. The test supplies no independent source archive or cryptographic authentication of the book.

## The separate solved-page outcome

| Measurement | 07.jpg | 08.jpg | Total |
|---|---:|---:|---:|
| Reference runes | 210 | 218 | 428 |
| Detected glyph proposals | 206 | 214 | 420 |
| Rows with count mismatches | 4 | 4 | 8 |
| Correct accepted labels in count-aligned rows | 125 | 132 | 257 |
| Wrong accepted labels in count-aligned rows | 0 | 0 | 0 |
| Abstentions in count-aligned rows | 9 | 4 | 13 |
| Proposals in unaligned rows | 72 | 78 | 150 |
| Verified accepted coverage of reference | 59.52% | 60.55% | 60.05% |
| Complete-page pass | No | No | No |

Classification metrics are conditional on the declared positional row alignment and equal row counts. The 150 proposals in mismatched rows are **not credited as correct** merely because their best template looks convincing. Nor does equal count by itself prove every crop boundary. The reference totals are not supplied to the reading stage to force its segmentation.

The combined net shortfall of eight proposals does not establish exactly eight uniquely identified missing characters. Merged, split or misplaced components can produce the same count difference. The reader treats geometric components as candidate glyphs; that is insufficient for complete document reading when shapes and neighbors interact.

Four rows fail on each page:

| Image | Printed test row | Detected / reference | Exact source crop |
|---|---:|---:|---|
| 07.jpg | 5 | 19 / 20 | [Crop 0](glyph74_failure_00.png) |
| 07.jpg | 6 | 18 / 19 | [Crop 1](glyph74_failure_01.png) |
| 07.jpg | 7 | 18 / 19 | [Crop 2](glyph74_failure_02.png) |
| 07.jpg | 11 | 17 / 18 | [Crop 3](glyph74_failure_03.png) |
| 08.jpg | 2 | 20 / 21 | [Crop 4](glyph74_failure_04.png) |
| 08.jpg | 5 | 19 / 20 | [Crop 5](glyph74_failure_05.png) |
| 08.jpg | 6 | 21 / 22 | [Crop 6](glyph74_failure_06.png) |
| 08.jpg | 11 | 18 / 19 | [Crop 7](glyph74_failure_07.png) |

The [crop manifest](glyph74_failure_crops.json) records the boxes, source hashes and saved crop hashes. These crops preserve decoded source pixels without enhancement or resizing. They document where the output fails; they do not silently repair it.

## Controls and practical limit

All **29 exact stored-template label fixtures** recover their expected label. A blank mask and a deliberately broad filled block both trigger abstention. These verify template handling and rejection of obvious non-glyph shapes. They are constructed checks, not fresh complete-page controls or cipher-recovery demonstrations.

The separate pages are the stronger check, and both fail. Correct isolated classifications cannot rescue inadequate segmentation or justify an automatic opening-section transcription. The target stage is guarded by the saved test result and is blocked when the gate is false. No target prediction file was created.

## Reproduce and inspect

With Python, NumPy, SciPy and Pillow, run beside the retained files:

```sh
# Reuse the saved frozen bank for the same image-only reading.
python3 -B glyph_reader.py read --scope held
python3 -B glyph_reader.py evaluate --scope held
```

The `prepare` action rebuilds the bank from the declared training/development sources. Use a separate copy when rerunning preparation so the published freeze and model remain intact. Do not modify parameters after inspecting this test and describe the result as a new held-out validation.

- [Plan and fixed gate](glyph_reader_plan.json)
- [Implementation](glyph_reader.py)
- [Frozen configuration and provenance](glyph74_freeze.json)
- [Template arrays and labels](glyph74_templates.npz)
- [Training crops, discarded rows, development predictions and threshold grid](glyph74_training.json)
- [Native source-pixel training atlas](glyph74_training_atlas.png)
- [Raw image-only test predictions](glyph74_held_predictions.json)
- [Evaluation results, failures and controls](glyph74_results.json)
- [Development history](glyph74_development_history.json) and [earlier failed diagnostic](glyph74_development_failure.json)
- [Failure crop boxes and hashes](glyph74_failure_crops.json)
- Original test pages: [07.jpg](07.jpg), [08.jpg](08.jpg); [pinned JPEG manifest](jpeg_source_manifest.json)
- [Unchanged master transcription](liber-primus__transcription--master.txt)

The raw prediction SHA-256 is `ad8b6d827b665cbb075cddae0f536357594736ba9cee007127f97e05ec8bc868`. The master remains pinned at `b0b2e13c3cd35512ee5955a2d9a56c22d7410e283d35dd9c90abbaa7b99279eb`.

## Decision

Stop this bounded source-recognition branch and retain its failures. The earlier source constraints remain conditional on their documented audits; this reader does not strengthen them into independent confirmation.

Return to the cipher question with the existing constraints attached: scarce exact neighboring repeats, diverse singleton groups under the current boundaries, and the repeated six-rune phrase across sections. A proposed mechanism should specify how those observations arise, recover known controls and make a prediction on later text before a wider key search is justified.

There is still no new verified plaintext. The useful result is a tested limit on the recognition method and a record that prevents partial success from being promoted into complete validation.
