Zo pdf to markdown

From zocomputer/skills · View interactive version

Zo pdf to markdown is an AI agent skill from the GitHub repository zocomputer/skills. Convert PDF files to Markdown format

How to use this skill

Skill file

Convert PDF to Markdown

Purpose

Convert the user's PDF file to Markdown format, preserving structure and formatting.

Input

Steps

  1. Install pymupdf4llm if not already installed:
pip install pymupdf4llm
  1. Convert the user's PDF to Markdown with proper formatting:
import pymupdf4llm

# Convert with better formatting and structure preservation
markdown_text = pymupdf4llm.to_markdown(
    "<user's_pdf_path>",
    page_chunks=True,  # Separate pages with breaks
    write_images=True  # Extract and include images
)

# Save to a markdown file with the same name
output_filename = "<user's_pdf_path>".replace('.pdf', '.md')
with open(output_filename, "w", encoding="utf-8") as f:
    f.write(markdown_text)
  1. Tell the user where the converted markdown file was saved.

Note

If the PDF appears to be scanned (images of text), inform the user that OCR tools would work better for that use case.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.