# HTML Quality Probe

These checks are diagnostic and non-gating. A `needs-review` status means the generated artifacts found a likely conversion-quality issue, not that artifact generation failed.

- Status: `needs-review`
- Source PDF: [../source.pdf](../source.pdf)
- Generated HTML: [../semantic-continuous/index.html](../semantic-continuous/index.html)
- Sample notes: Image- and diagram-heavy paper with a two-column academic layout. Categories: image-heavy, diagrams, complex-columns. Canonical source: https://arxiv.org/abs/1505.04597
- Text reference: `pdfbox-net-run-fallback`
- Pages analyzed: 8

## Page Summary

| Page | Status | Source words | HTML words | Token coverage | Long HTML tokens | Foreground delta | Severe color delta | Text/object overlaps |
| --- | --- | ---: | ---: | ---: | ---: | ---: | ---: | ---: |
| 1 | `needs-review` | 424 | 389 | 0.899 | 0 | 0.104 | 1 | 0 |
| 2 | `needs-review` | 375 | 368 | 0.795 | 2 | 0.167 | 0.923 | 3 |
| 3 | `needs-review` | 398 | 432 | 0.967 | 0 | 0.187 | 0.632 | 1 |
| 4 | `needs-review` | 483 | 445 | 0.913 | 0 | 0.236 |  | 0 |
| 5 | `needs-review` | 369 | 388 | 0.892 | 0 | 0.147 | 1 | 2 |
| 6 | `needs-review` | 433 | 433 | 0.958 | 0 | 0.039 |  | 0 |
| 7 | `needs-review` | 355 | 389 | 0.938 | 0 | 0.147 | 0.98 | 2 |
| 8 | `needs-review` | 444 | 90 | 0.203 | 0 | 0.04 |  | 0 |

## Issue Categories

| Category | Status | Evidence |
| --- | --- | --- |
| Text reconstruction and word boundaries | `needs-review` | 4 page(s) need review; worst token coverage is 0.203 on page 8, with 0 high-confidence adjacent-word join(s). |
| Page geometry and text-run structure | `passed` | Page dimensions passed where measured; 8 continuous semantic-flow run-count check(s) were skipped because source runs are intentionally grouped. |
| Text wrapping around images and vector objects | `needs-review` | 7 text/image overlap(s) and 1 text/vector overlap(s) were found. |
| Visual foreground parity | `needs-review` | Max foreground delta is 0.236; max source-only foreground ratio is 0.517; max HTML-only foreground ratio is 0.649. |
| Visual color parity | `needs-review` | Max mean CIE Lab color delta is 69.585; max severe color-delta ratio is 1; minimum compared page-pixel ratio is 0. |
| Source fixture expectations (manual review) | `skipped` | The source PDF does not contain recognizable self-describing fixture expectations. |
| Probe setup and tool availability | `passed` | The browser probe and available renderers ran. |

## Current Limitations

- Text reconstruction did not preserve all word boundaries or reading order on the affected page(s).
- Some image-backed content still behaves like fixed-position objects; text may collide with image regions.
- Large vector overlays are not semantically attached to nearby content; review whether these are decorative backgrounds, table rules, clipping masks, or true text/object collisions.
- The visual probe compared at least one page using only the overlapping crop because renderer/browser pixel dimensions differed beyond the probe tolerance.
- Perceptual color differences exceed the severe-corruption threshold on at least one page; inspect the color heatmap for incorrect fills, opacity, blending, or color-space conversion.
- The HTML contains additional foreground pixels compared with the PDF render on at least one page, which often means duplicated glyphs, fallback text, or unmodeled object masks.

## Findings

- Page 1, `word-boundaries`: Rendered HTML text appears to have lost word boundaries or token coverage.
- Page 1, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 1, `visual-color-difference`: PDF render and browser page screenshot have different pixel dimensions; color was compared across stable foreground interiors in the overlapping region only.
- Page 2, `word-boundaries`: Rendered HTML text appears to have lost word boundaries or token coverage.
- Page 2, `text-image-overlap`: 2 text run(s) overlap rendered image boxes.
- Page 2, `text-vector-overlap`: 1 text run(s) overlap large rendered vector boxes.
- Page 2, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 2, `visual-color-difference`: PDF render and browser page screenshot have different pixel dimensions; color was compared across stable foreground interiors in the overlapping region only.
- Page 3, `text-image-overlap`: 1 text run(s) overlap rendered image boxes.
- Page 3, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 3, `visual-color-difference`: PDF render and browser page screenshot have different pixel dimensions; color was compared across stable foreground interiors in the overlapping region only.
- Page 4, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 5, `word-boundaries`: Rendered HTML text appears to have lost word boundaries or token coverage.
- Page 5, `text-image-overlap`: 2 text run(s) overlap rendered image boxes.
- Page 5, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 5, `visual-color-difference`: PDF render and browser page screenshot have different pixel dimensions; color was compared across stable foreground interiors in the overlapping region only.
- Page 6, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 7, `text-image-overlap`: 2 text run(s) overlap rendered image boxes.
- Page 7, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.
- Page 7, `visual-color-difference`: PDF render and browser page screenshot have different pixel dimensions; color was compared across stable foreground interiors in the overlapping region only.
- Page 8, `word-boundaries`: Rendered HTML text appears to have lost word boundaries or token coverage.
- Page 8, `visual-foreground-mask`: PDF render and browser page screenshot have different pixel dimensions; foreground masks were compared across the overlapping region only.

## Artifacts

- [page-1-html.png](page-1-html.png)
- [page-1-source.png](page-1-source.png)
- [page-1-diff.png](page-1-diff.png)
- [page-1-color-heatmap.png](page-1-color-heatmap.png)
- [page-1-visual-report.html](page-1-visual-report.html)
- [page-2-html.png](page-2-html.png)
- [page-2-source.png](page-2-source.png)
- [page-2-diff.png](page-2-diff.png)
- [page-2-color-heatmap.png](page-2-color-heatmap.png)
- [page-2-visual-report.html](page-2-visual-report.html)
- [page-3-html.png](page-3-html.png)
- [page-3-source.png](page-3-source.png)
- [page-3-diff.png](page-3-diff.png)
- [page-3-color-heatmap.png](page-3-color-heatmap.png)
- [page-3-visual-report.html](page-3-visual-report.html)
- [page-4-html.png](page-4-html.png)
- [page-4-source.png](page-4-source.png)
- [page-4-diff.png](page-4-diff.png)
- [page-4-visual-report.html](page-4-visual-report.html)
- [page-5-html.png](page-5-html.png)
- [page-5-source.png](page-5-source.png)
- [page-5-diff.png](page-5-diff.png)
- [page-5-color-heatmap.png](page-5-color-heatmap.png)
- [page-5-visual-report.html](page-5-visual-report.html)
- [page-6-html.png](page-6-html.png)
- [page-6-source.png](page-6-source.png)
- [page-6-diff.png](page-6-diff.png)
- [page-6-visual-report.html](page-6-visual-report.html)
- [page-7-html.png](page-7-html.png)
- [page-7-source.png](page-7-source.png)
- [page-7-diff.png](page-7-diff.png)
- [page-7-color-heatmap.png](page-7-color-heatmap.png)
- [page-7-visual-report.html](page-7-visual-report.html)
- [page-8-html.png](page-8-html.png)
- [page-8-source.png](page-8-source.png)
- [page-8-diff.png](page-8-diff.png)
- [page-8-visual-report.html](page-8-visual-report.html)
