Skip to main content

pydoccraft

CI

pydoccraft 0.2.1 is an Apache-2.0 Python/Rust package for eager, in-process structured extraction, rendering, and semantic conversion of PDF, DOCX, and PPTX files. It exposes the compatible doc_ex PyMuPDF-style API and uses pinned PdfCraft, WordCraft, and DeckCraft library crates—without external executables, runtime downloads, networking, cloud credentials, or OCR.

Install

python -m pip install pydoccraft

The wheel contains the private doc_ex._core native extension. No office suite, Pandoc, or Craft CLI is required.

Quick start

from pathlib import Path
import doc_ex

with doc_ex.open("report.pdf") as document:
    print(document.page_count)
    print(document[0].get_text())
    print(document[0].get_text("markdown"))
    print(document[0].get_links())
    print(document[0].find_tables())
    Path("page.png").write_bytes(document[0].get_pixmap(dpi=144))
    Path("report.docx").write_bytes(document.convert("docx"))

Path("report.pdf").write_bytes(doc_ex.convert("report.docx", "pdf"))
Path("slides.pdf").write_bytes(doc_ex.convert("slides.pptx", "pdf"))

Document supports context management, iteration, integer and negative indexing, load_page, page_count, metadata, Markdown, PNG rendering, conversion, and idempotent close. Page.number is zero-based. Returned Block, Table, Link, and Image objects own their extracted data.

Supported operations

Operation PDF DOCX PPTX
Structured text, links, images, and tables Yes Yes Yes
PNG page/slide rendering Yes Yes Yes
Convert to PDF — Yes Yes
Convert to DOCX Yes — No
Password input Yes Yes Encrypted PPTX unsupported
OCR No — —

PDF table detection is conservative. PDF links usually retain destination and geometry but not label text. DOCX computed pagination cannot split one automatically wrapped paragraph into exact normalized page slices. PPTX exposes URL links but not every PowerPoint action. Conversion uses upstream semantic exporters and is not pixel-perfect.

Documentation

Development

cargo fmt --all -- --check
cargo test --locked
cargo clippy --locked --all-targets -- -D warnings
maturin build --release --locked --out dist
python -m unittest discover -s tests -v

Release validation must install the built wheel into a clean environment and run the suite against that installed package. Tests generate their own fixtures and require no external document tools.

License

pydoccraft is licensed under Apache-2.0. Distributions include LICENSE, NOTICE, and the wheel-compatible LICENSE-THIRD-PARTY copy of the audited THIRD_PARTY_LICENSES.md inventory. Upstream dependency names identify their source and are not pydoccraft branding.

The source repository is narain1/pydoccraft. PyPI trusted publishing is configured for project pydoccraft, repository pydoccraft, workflow release.yml, and environment pypi.

Metadata

Release files for pydoccraft 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for pydoccraft 0.2.1
File
pydoccraft-0.2.1-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
pydoccraft-0.2.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64 Details
pydoccraft-0.2.1-cp313-cp313-macosx_11_0_arm64.whl CPython 3.13 CPython 3.13 macOS 11.0+ ARM64 Details
pydoccraft-0.2.1-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
pydoccraft-0.2.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details
pydoccraft-0.2.1-cp312-cp312-macosx_11_0_arm64.whl CPython 3.12 CPython 3.12 macOS 11.0+ ARM64 Details
pydoccraft-0.2.1-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
pydoccraft-0.2.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
pydoccraft-0.2.1-cp311-cp311-macosx_11_0_arm64.whl CPython 3.11 CPython 3.11 macOS 11.0+ ARM64 Details

Total release size: 123.3 MB

Release files / pydoccraft-0.2.1-cp313-cp313-win_amd64.whl

Download URL pydoccraft-0.2.1-cp313-cp313-win_amd64.whl
Size 13.8 MB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
2bc85fd01d0359f96147a87a6e411f82c1ec92e7a07d049632973f03a8d040c2
BLAKE2b-256 checksum
How to use checksums
244d1e124c81b6892f3f607de40f8c0628a1845432b46b34b3d426b30ffbfc73
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pydoccraft-0.2.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.4 MB
Tags CPython 3.13 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
041321922a3dd3a77595319856910195b17278ddcede000b003495d39f6fc9a2
BLAKE2b-256 checksum
How to use checksums
b0d126a1b9e0423e3f3e67f0a152955c0e79c8f7db799bcbe9a1532b8bb47092
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp313-cp313-macosx_11_0_arm64.whl

Download URL pydoccraft-0.2.1-cp313-cp313-macosx_11_0_arm64.whl
Size 12.9 MB
Tags CPython 3.13 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
6a23842cabce0c0463f24bb57aa8de31f396deb00d21f6c7c720a75db04b477d
BLAKE2b-256 checksum
How to use checksums
816d8c1aed6fc3603f1703a15566bc74f5e8a6bbe74871bd37ddacf25e1bbcf3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp312-cp312-win_amd64.whl

Download URL pydoccraft-0.2.1-cp312-cp312-win_amd64.whl
Size 13.8 MB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
29e2d6c4ffcf401e070f45fa97c4b33378acde9965c6f7017fbfbf82c99f5363
BLAKE2b-256 checksum
How to use checksums
c58bf8b91272ae62d8c6488ceb0d8b79c2418a666fe7f970f6a77c76fde3b2f8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pydoccraft-0.2.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.4 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
bdcd7b4419c10f71763316598f90f30fd31d9e0208f1f6af738481eb3c261bbd
BLAKE2b-256 checksum
How to use checksums
0d921a7c095a5965da94d9e160bd54de3ce1208d1142305a7f69940fbf1fe4ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp312-cp312-macosx_11_0_arm64.whl

Download URL pydoccraft-0.2.1-cp312-cp312-macosx_11_0_arm64.whl
Size 12.9 MB
Tags CPython 3.12 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
2054a4825a18923d16dca539466dc6bc3d9023ba8880caf64dc3fab4adcdd1d6
BLAKE2b-256 checksum
How to use checksums
aeabcfd28dbbb8fb595d42cf792d4c720e04339f147b17c2a61e8d95256f9ac6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp311-cp311-win_amd64.whl

Download URL pydoccraft-0.2.1-cp311-cp311-win_amd64.whl
Size 13.8 MB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
3b02b9351525a693c19a852b3e7730f9461c0eccaa949edf9b070f2e29a01b9a
BLAKE2b-256 checksum
How to use checksums
461feb79fb76c6b9f06a30282580433f731562372183cc38135eb1dad381454d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pydoccraft-0.2.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.4 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
3938759e2ee79aa19c9d93b2e3be3f836daf66eddbb644a8442eed3cbd266047
BLAKE2b-256 checksum
How to use checksums
caf649b5722d3065e21369db06241b36d5a300937c1139bdf01857af68982484
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / pydoccraft-0.2.1-cp311-cp311-macosx_11_0_arm64.whl

Download URL pydoccraft-0.2.1-cp311-cp311-macosx_11_0_arm64.whl
Size 12.9 MB
Tags CPython 3.11 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
70ddb2877a32721b4ff1e758cdd0855c22ba3891a4eca404d30fc69e6e0f5e87
BLAKE2b-256 checksum
How to use checksums
f21cff51071ac364e0e0398ba4534abb522157dea67f1ec5e9af616619483437
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Security for pydoccraft 0.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 9 files in this release have been uploaded with provenance metadata.

Select from 9 files

Attestation for pydoccraft-0.2.1-cp313-cp313-win_amd64.whl

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.2.1 This release

9 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page