--- id: playa-pdf version: "1.1.0" license: MIT license_treatment: permissive maintenance: active --- # playa-pdf — Parallel and LazY Analyzer for PDFs License: permissive · Maintenance: active · Downloads: 324.0K/mo ## What it is and what it does Playa-pdf is a pure-Python PDF reader designed to expose the internals of PDF files—pages, content streams, fonts, images, annotations, document outlines, and logical structure trees—through a lazy, parallelizable interface. It implements the layout analysis algorithm from pdfminer.six and offers both a Python API and a command-line tool for dumping PDF metadata and content. The package is not primarily a text extraction tool; its main strength is providing low-level access to PDF structure and metadata, with optional parallelization across multiple CPUs. The library supports Python 3.8 through 3.13 and has no C++ dependencies, relying only on mypy-extensions at runtime. It is MIT licensed and actively maintained. While text extraction is possible, the documentation explicitly recommends other tools (pypdfium2, pypdf) for that use case alone. Playa-pdf is most useful when you need to inspect or manipulate PDF internals, extract structured metadata, or process large batches of PDFs in parallel. Use it for: - Extract and analyze document outlines, page trees, and logical structure trees from tagged PDFs for accessibility or content mapping. - Dump all PDF operators and content streams from a document for low-level analysis or debugging. - Batch-extract images and fonts from multiple PDFs in parallel using the lazy, parallelizable API. - Access absolute positions and attributes of text, lines, paths, and images on each page for layout analysis. - Read encrypted PDFs (with the crypto add-on) and inspect their metadata without full decryption overhead. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Playa-pdf reads PDF files and exposes their internal structure—pages, content streams, metadata, text, images, fonts, and logical structure trees—through a parallel, lazy, pure-Python interface with a command-line tool. Yes, if you need low-level PDF structure access, metadata inspection, or parallel batch processing. The pure-Python, dependency-light design and MIT license make it a solid choice for those use cases. No, if your only goal is fast text extraction—use pypdfium2 or pypdf instead. Medium friction on install due to compiled wheels, but active maintenance and zero known vulnerabilities reduce risk. ## Install pip install playa-pdf uv add playa-pdf poetry add playa-pdf ## Installing playa-pdf Before you install: Medium install friction due to compiled wheels for multiple Python versions and platforms (cp310–cp313, macOS/Linux/Windows). Active maintenance with recent releases. Single runtime dependency (mypy-extensions) keeps the dependency tree lean. License in practice: MIT license is permissive; you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions. Quickstart: pip install playa-pdf import playa pdf = playa.open("document.pdf") for page in pdf.pages: print(f"Page {page.label}: {page.width} x {page.height}") Requires Python 3.8 or newer. Optional: install playa-pdf[crypto] to read encrypted PDFs. Verify before relying: - Whether the layout analysis algorithm implementation is materially faster than pdfminer.six in typical workflows outside the author's benchmarks. - Whether text extraction quality and completeness match or exceed other pure-Python PDF libraries for real-world documents. - Scope and stability of the command-line interface and its output formats across releases. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: medium - Maintenance: active - Downloads: 324.0K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags pdf parsing and extraction, pdf metadata and structure, text and image extraction from pdf, pdf content stream analysis, parallel pdf processing, pdf logical structure tree, low-level pdf access, pdf-parsing, parallel-processing, cli-tool [View on SkillFed](https://skillfed.io/packages/playa-pdf) · [View on PyPI](https://pypi.org/project/playa-pdf/)