ozaru¶
Read PDF files from Python with a small, simple API and a Rust core.
ozaru gets the text out of a PDF in one line of Python:
import ozaru
text = ozaru.extract_text("report.pdf")
pages = ozaru.page_count("report.pdf")
print(f"Pages: {pages}")
print(f"Title: {text.splitlines()[0]}")
Run it on the sample report and you get:
Why ozaru?¶
- One line per task. Pass a path and get the result. There are no objects to manage.
- Easy to install. Prebuilt wheels mean you don't need Rust or a compiler.
- No Python dependencies. ozaru installs nothing else into your environment.
- Built on Rust. The PDF work is done by pdf_oxide.
- Typed. Type hints are included, so your editor can autocomplete and check your calls.
Install it¶
Where to go next¶
- New to ozaru? Start with First steps.
- Want to learn it properly? Follow the Tutorial in order.
- Looking for one exact detail? Go to the API reference.