#[non_exhaustive]pub enum ReasonCode {
Ok,
NativeTextHighConfidence,
NoTextLayerPresent,
TextLayerBelowThreshold,
GlyphMappingMissing,
EncryptedNoExtractPermission,
ImageTableReconstructed,
ImageTableNoStructure,
ChartNotTranscribed,
OcrRequestedButUnavailable,
OcrLowConfidenceFallback,
Empty,
}Expand description
Machine-readable why for a region/page result — the #1
cross-tool user-pain fix. A non-degraded result is
Ok; any degraded one must name the cause.
#[non_exhaustive], frozen snake_case wire tokens (append-only —
never renumber/rename, the PadesLevel lesson).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Ok
Extracted cleanly.
NativeTextHighConfidence
Native text present and high-confidence.
NoTextLayerPresent
No text layer on the page at all.
TextLayerBelowThreshold
Text layer present but below the usable-quality threshold.
GlyphMappingMissing
Glyphs without usable ToUnicode/(cid:NN)/garbled mapping.
EncryptedNoExtractPermission
Encrypted and not authorised to extract.
ImageTableReconstructed
An image-table was reconstructed into TableData.
ImageTableNoStructure
A table region was detected but structure could not be recovered (graceful — heuristic fallback used, not fail-loud).
ChartNotTranscribed
A chart/figure was detected; its internal data is not transcribed (honest scope boundary — placeholder emitted).
OCR was needed but unavailable (feature off / models absent /
mode = TextOnly) → fell back to native text + warned.
OcrLowConfidenceFallback
OCR ran but confidence was low → native used/merged.
Empty
Region/page yielded no recoverable content.