Camelot

Python library for extracting tables from PDF files.

Open SourceSelf HostedOffline Capable
0.0 (0)

About

Camelot is a Python library that extracts tables from PDF files into pandas DataFrames. Text-based documents need no OCR, and optional OCR support extends coverage to scanned, image-only PDFs. Several parsing flavors are available: lattice for tables with ruled lines, stream for whitespace-separated layouts, network and hybrid parsers based on text alignment, and an optional neural backend using a Table Transformer model for complex borderless tables, plus an auto-detection mode. Each extraction carries accuracy and whitespace metrics so poor results can be filtered or tuned, with configuration for table regions, column separators, and text processing. Tables export to CSV, JSON, Excel, HTML, Markdown, and SQLite, and input can come from file paths, URLs, raw bytes, or file-like objects. The default pdfium backend keeps the core install light, with PyTorch loading only for the ML parser, and a command-line interface is included. Camelot is MIT licensed and popular with analysts automating data extraction from reports and public documents.

Should you use Camelot?

Pick it when

Pick Camelot when you need tables out of report-style PDFs and into pandas, want to switch between lattice and stream parsing per document, and value accuracy metrics that let a batch job flag bad extractions automatically.

Look elsewhere when

Skip it when tables are only part of the job: for full-page text, headings, and reading order use Docling or Marker. If non-programmers must run extractions themselves, note it is a Python library and CLI with no point-and-click interface.

Alternatives to Camelot

  • pdfplumber

    Exposes every character and line for custom logic with visual debugging, but you write more table-tuning code and there is no OCR path for scans.

  • Docling

    Converts whole documents with layout and tables for RAG, at the cost of heavier models when all you wanted was DataFrames from tables.

  • PDF-Extract-Kit

    Its StructTable model turns complex tables into LaTeX or HTML, but setup is a GPU-oriented model stack under AGPL-3.0 where Camelot is MIT.

Reviews (0)

Leave a Review

No reviews yet. Be the first to review!

Details

Price
Free
Platform
Local/Desktop
Difficulty
Beginner (1/5)
License
MIT
Added
Apr 3, 2026

Tags