pydelity
pydelity turns PDFs into structured JSON. Its first step, the survey, reads a PDF with an Anthropic or OpenAI model and records how its pages are laid out: page numbers, rotation, writing direction and repeated lines, with a list of things for a person to review.
This release does the survey only. Later releases add the steps that extract each page’s content and assemble it into one document.
Quickstart
Section titled “Quickstart”-
Install pydelity with uv, which also installs Python 3.13 if you don’t have it:
Terminal window uv tool install --python 3.13 pydelity -
Set your Anthropic API key, replacing
[API_KEY]with your own key:Terminal window export ANTHROPIC_API_KEY="[API_KEY]"In Windows PowerShell, run
$env:ANTHROPIC_API_KEY = "[API_KEY]"instead. -
In the folder that holds your PDF, run a survey:
Terminal window pydelity document.pdfpydelity measures the PDF, shows what the survey will likely cost and asks before sending anything. Type
yand press Enter to go ahead. -
Open
pydelity-output/document/report.htmlin a browser to see the results and the issues to review.
See Install pydelity for other ways to install and the platforms PyMuPDF doesn’t support, and Your first survey for a walkthrough.
Find your next step
Section titled “Find your next step”- Install pydelity: install it on Windows, macOS or Linux and set an API key.
- Your first survey: follow one survey from the command line to the report.
- Guides: keep settings in a file, use the command line or Python, choose models, control costs, rerun and resume runs, and read the output files.
- Reference: look up exact setting names, files and fields.
- FAQ: get short answers to common questions, including what a survey gives you.
- Need Help?: ask a question, report a bug or suggest an improvement.