Skip to main content
DocVortex logo

DocVortex

Native document parsing. One structure, many outputs.

PyPI Python Downloads Monthly Downloads CI License: MIT

English · 简体中文

Performance · Quick start · Formats · Documentation

Documents in. Possibilities out.

DocVortex is a standalone Python engine for parsing and converting documents. It reads native text and document structure into a unified representation, then exports the result in the formats your workflow needs.

  • Multi-format input — read text and scanned PDFs, Office files, OpenDocument files, EPUB, HTML, OFD, CSV and TSV.
  • Parse once, export many times — reuse the same result for Markdown, HTML, LaTeX, DOCX, EPUB, PDF and structured JSON.
  • Portable results — save document structure and image assets in a Bundle, then export again without the source file.
  • Composable APIs — use the complete pipeline or integrate analysis, postprocessing and rendering separately.

Native parsing works without an OCR or VLM inference service. Use DocVortex directly through its CLI or Python SDK.

Scanned PDFs use local CPU OCR. The first OCR parse automatically downloads PP-DocLayoutV2 and PP-OCRv6 Tiny Det / Small Rec from Hugging Face, falling back to ModelScope, into ~/.docvortex/model/. The six model and configuration files total about 239 MB; a complete cache works offline.

DocVortex pipeline: native documents become a unified representation, then Markdown, HTML, LaTeX, DOCX, EPUB, PDF or structured JSON.

PDF performance

Release 0.5.10 uses Rust acceleration: public parsing is 2.93× as fast as 0.4.25 on the tested corpus.

Pipeline 0.4.25 python 0.5.10 rust Speedup Time reduction Peak RSS reduction
DocVortex public parse() 42.36 s 14.48 s 2.93× 65.82% 31.17%
MinerU Flash 44.50 s 14.44 s 3.08× 67.55% 29.84%
MinerU shared PDF processing 76.28 s 12.85 s 5.94× 83.16% 35.65%

Same-machine warm-run comparison on 32 PDFs / 299 pages (31 PDFs for Flash). The existing 0.4.25 measurements are reused. For 0.5.10, each document is warmed once and timed five times in each of three balanced rounds; times sum the medians of the three per-document medians. RSS reductions are medians of per-document process-tree peak RSS reductions. MinerU results include improvements in both projects. The shared pipeline excludes model computation; excluding the extreme dense-table sample, its speedup is 2.87×.

Quick start

Requires Python 3.10–3.14.

Install

pip install docvortex

Command line

Convert a text PDF to Markdown:

docvortex convert report.pdf --format markdown --output output/report.md

Replace report.pdf with a local file in any supported input format. Use --format to choose the output; run docvortex convert --help for options. The root-level --log-level option controls loguru output and defaults to info. It must precede the command; DOCVORTEX_LOG_LEVEL=warning can also configure it.

Python

Parse a document once and export it twice:

import docvortex

result = docvortex.parse("report.pdf")
result.export("output/report.md", output_format="markdown")
result.export("output/report.docx", output_format="docx")

The result owns its document structure and assets, so further exports do not reopen or reparse the source. Existing output files are protected by default; use overwrite=True in Python or --overwrite in the CLI to replace them.

Supported formats

Native inputs · 20 formats

Document family File extensions
PDF with native text or scanned pages .pdf
Word & rich text .doc, .docx, .rtf
Presentations .ppt, .pptx
Spreadsheets .xls, .xlsx, .csv, .tsv
OpenDocument .odt, .ods, .odp
E-books .epub
Web documents .html, .htm, .shtml
Web archives .mhtml, .mht
Open Fixed-layout Document .ofd

Outputs · 7 formats

Output --format / output_format
Markdown markdown
HTML html
LaTeX latex
Word document docx
EPUB e-book epub
PDF pdf
Structured JSON structured_content

PPT/PPTX and XLS/XLSX are input formats only. Structured JSON is an export format; the document JSON protocol separately defines the analysis and intermediate representations.

Save now, export later

A Bundle packages the parsed document and its image assets for reuse across processes or machines. Load it whenever you need another output format:

import docvortex

result = docvortex.parse("report.pdf")
result.save_bundle("output/report.bundle")

restored = docvortex.load_bundle("output/report.bundle")
restored.export("output/report.epub", output_format="epub")

The restored result works without the original file. See the usage guide for Bundle contents, asset handling and overwrite rules.

Need only the title, authors or other source properties? docvortex.extract_metadata() reads metadata without parsing the document body.

Choose the right workflow

  • PDF parsing: parse_mode="auto" (default) classifies the selected PDF pages and chooses native text or local CPU OCR. Use parse_mode="txt" to force native parsing without classification or model downloads, or parse_mode="ocr" to force OCR. The CLI equivalent is --parse-mode auto|txt|ocr. Explicit modes apply only to PDF input.
  • PDF OCR: layout supplies block regions and reading order; text blocks use Tiny Det / Small Rec. Display formulas, images, charts and seals retain screenshots. Inline formulas pass through ordinary text OCR. Tables contain spatially projected text and a screenshot, without structural cell recognition. No page orientation or unwarping model is used. A selected document uses one backend throughout.

If a mixed PDF is classified as txt but contains scanned pages, use parse_mode="ocr" (CLI: --parse-mode ocr) to OCR the entire selection.

  • PDF classification: docvortex classify report.pdf returns txt or ocr without inference or networking. Metadata extraction and the low-level PdfModel.predict() native text API also remain offline. See model provenance.
  • PDF export: PDF sources with page geometry default to block layout restoration, with selectable text and HTML-based tables; charts retain region images. Other sources and older results use semantic reflow. Use --pdf-layout original|reflow to select explicitly; fonts, line breaks and drawing instructions are not reproduced losslessly. See PDF output layout.

Documentation

Guide What you will find
Usage Stage APIs, PDF pages, classification, images and Bundles
Agent skill CLI and Python SDK workflows for agents; copy the entire skills/docvortex folder to reuse
Examples Local samples for PDF, Office, EPUB, web documents and OFD with a runnable demo
Metadata Source properties and per-format coverage
JSON protocol Document schemas, extensions and protocol migration
HTML protocol Semantic markers and round trips
Public SDK & migration Supported integration boundaries and the 0.4 upgrade
Rendering ownership DocVortex exports and MinerU-specific renderers

Development

See Repository architecture for directory responsibilities, the Python/Rust boundary, and pure Python or native development commands.

From a local checkout:

uv venv
uv pip install -e ".[test,dev]"
uv run --no-project python -m pytest -q
uv run --no-project ruff check src
uv run --no-project ruff format --check src
uv build

Bug reports and contributions are welcome. When reporting a parsing issue, include a reproducible command and a sample document you can share in GitHub Issues.

License

DocVortex project code is released under the MIT License.

Metadata

Release files for docvortex 0.5.14

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

Source distribution (sdist)

Source distribution for docvortex 0.5.14
File Size Uploaded
docvortex-0.5.14.tar.gz 74.9 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for docvortex 0.5.14
File
docvortex-0.5.14-py3-none-any.whl Python 3 none any Details
docvortex-0.5.14-cp310-abi3-win_arm64.whl CPython 3.10 abi3 Windows ARM64 Details
docvortex-0.5.14-cp310-abi3-win_amd64.whl CPython 3.10 abi3 Windows x86-64 Details
docvortex-0.5.14-cp310-abi3-manylinux_2_28_x86_64.whl CPython 3.10 abi3 Linux glibc 2.28+ x86-64 Details
docvortex-0.5.14-cp310-abi3-manylinux_2_28_aarch64.whl CPython 3.10 abi3 Linux glibc 2.28+ ARM64 Details
docvortex-0.5.14-cp310-abi3-macosx_11_0_arm64.whl CPython 3.10 abi3 macOS 11.0+ ARM64 Details
docvortex-0.5.14-cp310-abi3-macosx_10_13_x86_64.whl CPython 3.10 abi3 macOS 10.13+ x86-64 Details

Total release size: 109.7 MB

Release files / docvortex-0.5.14.tar.gz

Download URL docvortex-0.5.14.tar.gz
Size 74.9 MB
Tags Source
SHA-256 checksum
How to use checksums
bdd2db7d1efdc108b2acd898af9bb55dce215daa4a657f31e389be9a8efbf6ea
BLAKE2b-256 checksum
How to use checksums
5e5bf7bf8b2a7ce49aadf464d2125e08e7917ddad8757f51160ecbe7dbbfc3a6
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-py3-none-any.whl

Download URL docvortex-0.5.14-py3-none-any.whl
Size 3.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
6631e2df82af25e7f2ffd886a000408d31aa1064db2a5a7138ed2839975a990e
BLAKE2b-256 checksum
How to use checksums
73749770a3f917f2f4b14ea5ff972d06224d4e9a32a02f1922b06fc0bb547b05
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-cp310-abi3-win_arm64.whl

Download URL docvortex-0.5.14-cp310-abi3-win_arm64.whl
Size 5.0 MB
Tags CPython 3.10 Windows ARM64 abi3
SHA-256 checksum
How to use checksums
bb153ef8258870878830d42e3b4697b5ce1dd8978271c36f772222929e14c7c5
BLAKE2b-256 checksum
How to use checksums
d34ce764c108e3976042c786f46f9d7ec0ce0c434736fadc52045f8c850f109f
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-cp310-abi3-win_amd64.whl

Download URL docvortex-0.5.14-cp310-abi3-win_amd64.whl
Size 5.1 MB
Tags CPython 3.10 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
7de931002332b49e47a7e71a2aaecf5d1733624f1ed4a2a0e2f2907806e9d019
BLAKE2b-256 checksum
How to use checksums
6808f6e2537239ab1ecb510b7262f7b80e80fbad4aac7030a2c844a4c5eb097c
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-cp310-abi3-manylinux_2_28_x86_64.whl

Download URL docvortex-0.5.14-cp310-abi3-manylinux_2_28_x86_64.whl
Size 5.3 MB
Tags CPython 3.10 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
fdcdc82064ca560f817930744b4780d7b2e4c3f283d77a80c43a5922a5066420
BLAKE2b-256 checksum
How to use checksums
89cf407be524a82e1e0b540647b8cd345cb1490d4a5692840177e01b352ad70e
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-cp310-abi3-manylinux_2_28_aarch64.whl

Download URL docvortex-0.5.14-cp310-abi3-manylinux_2_28_aarch64.whl
Size 5.1 MB
Tags CPython 3.10 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
d7d8c5273f5792744b009b1a85f0636bcca44a1fa9d1b39b3446ea595aeea44d
BLAKE2b-256 checksum
How to use checksums
4ba0e8309bc26fc640b9b64b100c45cc262c350524b705f006ac3d5118e0d56f
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-cp310-abi3-macosx_11_0_arm64.whl

Download URL docvortex-0.5.14-cp310-abi3-macosx_11_0_arm64.whl
Size 5.1 MB
Tags CPython 3.10 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
68231ecc5a5865a8aff75d46602f94a4829b158d6c48e0e059e6bfb5295cc0e1
BLAKE2b-256 checksum
How to use checksums
a0f9e29d24cbced8610aa8e9315819b9df58dd91a2945a43036fbc2d6782d9d3
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 9, 2026.

Transparency log

Release files / docvortex-0.5.14-cp310-abi3-macosx_10_13_x86_64.whl

Download URL docvortex-0.5.14-cp310-abi3-macosx_10_13_x86_64.whl
Size 5.2 MB
Tags CPython 3.10 abi3 macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
25ca17c1f1f740da43444d183e032e38897c63d375050095cf1fadf93aafca0e
BLAKE2b-256 checksum
How to use checksums
bc1efb39154537d7981ddb031ba1668f66e4dba4a6f88c290c163402b920f974
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 9, 2026.

Transparency log

Release history Release notifications | RSS feed

0.5.16

8 release files

This release

0.5.14 This release

8 release files

0.5.9

7 release files

0.5.8

7 release files

0.5.7

7 release files

0.5.6

7 release files

0.5.5

7 release files

0.5.4

7 release files

0.5.3

7 release files

0.5.2

7 release files

0.5.1

7 release files

0.5.0

7 release files

0.4.25

2 release files

0.4.24

2 release files

0.4.23

2 release files

0.4.22

2 release files

0.4.21

2 release files

0.4.20

2 release files

0.4.19

2 release files

0.4.18

2 release files

0.4.17

2 release files

0.4.16

2 release files

0.4.15

2 release files

0.4.14

2 release files

0.4.13

2 release files

0.4.12

2 release files

0.4.11

2 release files

0.4.10

2 release files

0.4.9

2 release files

0.4.8

2 release files

0.4.7

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.4

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.6

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

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