Skip to content

PDFStruct v0.2.0

Choose a tag to compare

@KelesogluMustafa KelesogluMustafa released this 07 Oct 12:36
· 21 commits to main since this release

PDFStruct converts documents on your own computer. 0.2.0 adds more input types, PDF output, a desktop window and a local connection to Claude. Free and open source (MIT): no account, no telemetry, no usage limits.

New

  • Inputs: DOCX, TXT, Markdown, HTML and images (JPG/JPEG, PNG, TIFF, BMP, WebP) next to PDF. Images go straight to OCR; multi-page TIFF and EXIF orientation are handled.
  • Output: PDF as the tenth format, next to JSON, HTML, TXT, Markdown, CSV, XLSX, DOCX, JSONL and SQLite.
  • Desktop window pdfstruct-gui (PySide6): drag files in, tick formats, Convert, cancel, open the output folder.
  • Claude: a local MCP server (pdfstruct-mcp) and an Agent Skill. Conversions return statuses and file names, not the document content; reading is explicit and capped at 2000 characters per call.
  • One engine behind terminal, window and MCP: each input is extracted once and every requested format comes from that result.
  • --all-types converts every supported file in a folder (folders stay PDF-only by default).

Install

Not on PyPI yet.

pip install "pdfstruct-0.2.0-py3-none-any.whl[gui,mcp]"

Python 3.10+; the OCR packages install automatically on Windows x86_64, Linux x86_64 and macOS Apple Silicon with Python 3.9–3.13. On Windows you can also clone the repository and run setup-windows.cmd.

Then: pdfstruct-gui, or pdfstruct report.docx --format pdf, or register the MCP server with claude mcp add --scope user pdfstruct -- <path to pdfstruct-mcp>.

Assets and how far each was verified

Asset Status
pdfstruct-0.2.0-py3-none-any.whl, pdfstruct-0.2.0.tar.gz Test suite, OCR and all formats pass on GitHub Actions (Windows x86_64, Linux x86_64, macOS Apple Silicon, Python 3.13). Installed into a clean environment and exercised end to end on Windows 11.
pdfstruct-skill.zip Agent Skill (instructions only). Structure checked; loaded in Claude Code.
PDFStruct-Portable-0.2.0-win64.zip Window + command line without Python. Built and tried on one Windows 11 x64 machine only; unsigned (SmartScreen may ask once). About 800 MB unpacked. No MCP server inside.
pdfstruct-0.2.0.mcpb Claude Desktop connector to an installed PDFStruct. Passes mcpb validate and its launcher is tested over MCP stdio, but installing it in Claude Desktop itself has not been verified. If it does not load, use the mcpServers entry from the README.
SHA256SUMS.txt Checksums of all files above.

The desktop window was used by hand on Windows 11. On macOS and Linux it is only started without a display by CI: unverified on a real desktop. There is no macOS .app/DMG and no Windows installer.

Format limits to know

  • csv and xlsx list text blocks; they are not reconstructed tables, also for DOCX/HTML tables.
  • pdf from DOCX/TXT/Markdown/HTML is a readable re-flow, not the source layout. Pixel-faithful DOCX to PDF is not a goal. pdf from an image is the picture with searchable text. A PDF input is not written again as PDF.
  • Image to DOCX/Markdown/HTML contains the recognised text only.
  • DOCX to DOCX, Markdown to Markdown and similar round trips lose styling (reported as a warning).
  • DOCX is read as one logical page; images, headers/footers and text boxes are not read.
  • PDF text uses Latin fonts (incl. Turkish and German); other scripts are reported as missing glyphs.
  • OCR needs an internet connection once, to download its models (about 70 MB).
  • Not supported: CSV/XLSX input, legacy DOC, RTF, ODT, EPUB, PowerPoint, HEIC. OCR is unavailable on macOS Intel, Linux ARM64 and Windows ARM.

Compatibility

Existing commands and aliases behave as before. PDF outputs keep their file names and their raw JSON shape (schema 1.0); other inputs use the additive schema 1.1 and keep their extension in output names (report.docx.txt). Because the tool version is part of the extraction fingerprint, existing PDFs are extracted once more on first use.