Initial commit: Rust PDF-to-Markdown library

- Smart PDF type detection (text vs scanned) without full document load
- Text extraction using lopdf directly
- Markdown conversion with header/list/code detection
- CLI tools: detect-pdf, pdf2md

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Abimael Martell
2026-02-06 11:51:41 -08:00
co-authored by Claude Opus 4.5
commit 135ce518c1
8 changed files with 1574 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
[package]
name = "pdf-to-markdown"
version = "0.1.0"
edition = "2021"
authors = ["Firecrawl Team"]
description = "Fast PDF to Markdown conversion with smart detection"
license = "MIT"
[dependencies]
# PDF parsing - use local firecrawl lopdf
lopdf = { path = "../../lopdf", features = ["rayon"] }
# Error handling
thiserror = "2.0"
# Parallel processing
rayon = "1.10"
# Logging
log = "0.4"
[dev-dependencies]
tempfile = "3.3"
[features]
default = []
[[bin]]
name = "pdf2md"
path = "src/bin/pdf2md.rs"
[[bin]]
name = "detect-pdf"
path = "src/bin/detect_pdf.rs"