docs(bf-65nqz): add PDF structure section to no-mapping.md fixture documentation
- Added PDF Structure section based on bf-4ozvw findings - Updated SHA256 in profiles/PROVENANCE.md for encoding fixtures - Section includes file characteristics, font analysis, and technical significance
This commit is contained in:
parent
5e413d06c3
commit
93d5f57dbb
2 changed files with 41 additions and 4 deletions
37
tests/fixtures/no-mapping.md
vendored
37
tests/fixtures/no-mapping.md
vendored
|
|
@ -131,6 +131,43 @@ endobj
|
|||
endobj
|
||||
```
|
||||
|
||||
## PDF Structure
|
||||
|
||||
Based on analysis from bead bf-4ozvw, the fixture has the following structural characteristics:
|
||||
|
||||
### File Characteristics
|
||||
|
||||
- **Size:** Extremely small (660 bytes) — minimal fixture
|
||||
- **Pages:** Single page document
|
||||
- **Format:** PDF 1.4 (standard version)
|
||||
- **Page Size:** US Letter (612 x 792 pts)
|
||||
- **Complexity:** No JavaScript, forms, or metadata streams
|
||||
- **Optimization:** Not optimized
|
||||
- **User Properties:** None
|
||||
- **Tagged PDF:** No
|
||||
- **Metadata Stream:** No
|
||||
|
||||
### Font Analysis
|
||||
|
||||
- **Font Name:** `CustomNoMap` — descriptive name indicating purpose
|
||||
- **Font Type:** Type 1 (PostScript font)
|
||||
- **Encoding:** Custom — this is the key characteristic
|
||||
- **Embedding:** Not embedded (`emb: no`)
|
||||
- **Subsetting:** Not subset (`sub: no`)
|
||||
- **Unicode:** No Unicode mapping (`uni: no`)
|
||||
- **Object ID:** 5 0 R
|
||||
|
||||
### Technical Significance
|
||||
|
||||
This fixture is particularly valuable for testing:
|
||||
|
||||
1. **Font encoding edge cases** — Custom encodings that don't map to standard character sets
|
||||
2. **Glyph recognition without standard mappings** — Glyphs with no direct Unicode equivalent
|
||||
3. **Error handling in the text extraction pipeline** — Fallback strategies when encoding mappings are unavailable
|
||||
4. **No Font Embedding scenario** — PDF readers must rely on encoding information provided
|
||||
|
||||
The fixture name "no-mapping" combined with the custom encoding indicates this is intentionally testing the case where pdftract must handle glyphs that have no direct mapping to readable text — a critical edge case for robust PDF text extraction.
|
||||
|
||||
## Expected Extraction Behavior
|
||||
|
||||
### Ground Truth
|
||||
|
|
|
|||
8
tests/fixtures/profiles/PROVENANCE.md
vendored
8
tests/fixtures/profiles/PROVENANCE.md
vendored
|
|
@ -305,7 +305,7 @@ bash scripts/check-provenance.sh
|
|||
| scanned/documents/invoice-300dpi-scanned.pdf | pdftoppm + img2pdf from invoice-300dpi.pdf | MIT-0 | 2026-06-01 | 4ff1bc0bb34c66e65cc574c60b8c706c5d32d11f0ae98b1f39c3bc94443490e0 | Scan simulation for OCR testing (rasterized image-only PDF) |
|
||||
| scanned/multi-page/doc-10page-300dpi.pdf | tests/fixtures/scanned/generate_scanned_fixtures.py | MIT-0 | 2026-06-01 | e54269ac6e86b9abf966a601c94c7ecd40da8fcc541873c37ec7608392de380f | Source PDF for scan simulation at 300 DPI (10 pages with diverse content) |
|
||||
| scanned/multi-page/doc-10page-300dpi-scanned.pdf | pdftoppm + img2pdf from doc-10page-300dpi.pdf | MIT-0 | 2026-06-01 | 02c2751cd0e26b49f9cf538f9bbb407bbf4aea587d61a896d0e7e4d3f687ecd8 | Scan simulation for OCR testing (rasterized image-only PDF, 10 pages) |
|
||||
| encoding/no-mapping.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | 25910fac0084e8b2f90c405d015ce004d667d8477c92559607f55ebd37f62682 | Level 4 Unicode recovery fixture (no ToUnicode CMap, no standard encoding) |
|
||||
| encoding/agl-only.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | c2d12dfdaf9b00176bb85d1f592ece204bafb4f7ac8c53ac3328d24e68354e5e | Level 2 Unicode recovery fixture (AGL glyph names only, no ToUnicode CMap) |
|
||||
| encoding/fingerprint-match.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | 9531c85c92974464e425c32e7dae6eb1d82a0e4fd7da26301519f9c283b49d59 | Level 3 Unicode recovery fixture (embedded font for SHA-256 fingerprint matching) |
|
||||
| encoding/shape-match.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | 5e83c4ac49b61fd67342b6ab9003bee4e8014d031e7c47a17c4c6cb8105a0886 | Level 4 Unicode recovery fixture (glyph shape recognition from glyph-shapes.json) |
|
||||
| encoding/no-mapping.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | b24f88d3add958bfec1d6b134f2cd030cd41bb1932bedbe99405599bd01fa8f0 | Level 4 Unicode recovery fixture (no ToUnicode CMap, no standard encoding) |
|
||||
| encoding/agl-only.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | c6e8a067a637457ac9852c1d56745f5eac1f0fe441d19af08060d13d862b74b7 | Level 2 Unicode recovery fixture (AGL glyph names only, no ToUnicode CMap) |
|
||||
| encoding/fingerprint-match.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | bd9a3533c0f31fb20bf5532fcff4cb2ae399f8d2e22ea1d09538837410544c4a | Level 3 Unicode recovery fixture (embedded font for SHA-256 fingerprint matching) |
|
||||
| encoding/shape-match.pdf | tests/fixtures/generate_encoding_fixtures.rs | MIT-0 | 2026-06-09 | 6e99cfe2be79f5bcdc2a99b1004ce0e2288be56b081f8e558ecdecd78f702c55 | Level 4 Unicode recovery fixture (glyph shape recognition from glyph-shapes.json) |
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue