Hysen Labs
Library / SDK
firecrawl/pdf-inspector avatar
firecrawl

pdf-inspector

GitHub describes it as Fast Rust library for PDF inspection, classification, and text extraction. Intelligently detects scanned vs text-based PDFs to enable smart routing decisions.. The repository metadata lists Rust as its primary language. The metadata lists the MIT license. This article stays within the project description and details documented in the GitHub repository README.

15,209 stars1,047 forksRustMIT
01
DEEP OPEN-SOURCE ANALYSIS

firecrawl/pdf-inspector: pdf-inspector

GitHub describes it as Fast Rust library for PDF inspection, classification, and text extraction. Intelligently detects scanned vs text-based PDFs to enable smart routing decisions.. The repository metadata lists Rust as its primary language. The metadata lists the MIT license. This article stays within the project description and details documented in the GitHub repository README.

02
DEEP OPEN-SOURCE ANALYSIS

Repository scope

GitHub describes it as Fast Rust library for PDF inspection, classification, and text extraction. Intelligently detects scanned vs text-based PDFs to enable smart routing decisions.. The repository metadata lists Rust as its primary language. The metadata lists the MIT license. The README describes the project this way: Fast Rust library for PDF classification and text extraction. Detects whether a PDF is text-based or scanned, extracts text with position awareness, and converts to clean Markdown , all without OCR. Includes bindings for Python, Node.js, and browser WebAssembly.

03
DEEP OPEN-SOURCE ANALYSIS

pdf-inspector

The README section "pdf-inspector" states: Built by Firecrawl to handle text-based PDFs locally in under 200ms, skipping expensive OCR services for the ~54% of PDFs that don't need them.

04
DEEP OPEN-SOURCE ANALYSIS

Features

The README section "Features" states: - Smart classification , Detect TextBased, Scanned, ImageBased, or Mixed PDFs in ~10-50ms by sampling content streams. Returns a confidence score (0.0-1.0) and per-page OCR routing. - Text extraction , Position-aware extraction with font info, X/Y coordinates, and automatic multi-column reading order. - Markdown conversion , Headings (H1-H4 via font size ratios), bullet/numbered/letter lists, code blocks (monospace font detection), tables (rectangle-based and heuristic), bold/italic formatting, URL linking, and page breaks. - Table detection , Dual-mode: rectangle-based detection from PDF drawing ops, plus heuristic detection from text alignment. Handles financial tables, footnotes, and continuation tables across pages. - CID font support , ToUnicode CMap decoding for Type0/Identity-H fonts, UTF-16BE, UTF-8, and Latin-1 encodings. - Multi-column layout , Automatic detection of newspaper-style columns, sequential reading order, and RTL text support. - Encoding issue detection , Automatically flags broken font encodings so callers can fall back to OCR. - Single document load , The document is parsed once and shared between detection and extraction, avoiding redundant I/O. - Browser WebAssembly , Run the same Rust parser locally in browsers and Web Workers, with embedded CMaps and no server round trip. - Lightweight , Pure Rust, no ML models, no external services. Single dependency on lopdf for PDF parsing.

05
DEEP OPEN-SOURCE ANALYSIS

Benchmark

The README section "Benchmark" states: Evaluated on the opendataloader-bench corpus (200 PDFs). Only local engines without model-based PDF parsing are shown; OCR was disabled. Scores are 0-1, higher is better.

06
DEEP OPEN-SOURCE ANALYSIS

Editorial conclusion

The repository README is the source for this review. It does not replace a local installation or an independent test.

07
DEEP OPEN-SOURCE ANALYSIS

Official sources

08
Community notes

Community notes