# Changelog of URL and PDF to Markdown for LLMs and RAG (`magicfingers/document-to-markdown`) Actor

- **URL**: https://apify.com/magicfingers/document-to-markdown/changelog.md
- **Full Actor documentation**: https://apify.com/magicfingers/document-to-markdown.md

## Changelog

### 0.1 (2026-11-13)

- First version: converts web pages and documents (PDF, DOCX, PPTX, XLSX, HTML) from URLs, uploaded files or a URL field of a dataset into clean Markdown, one row per source.
- Tables kept as Markdown tables in every format; headings, lists, slide titles and speaker notes, sheet names; title, author, date and language from the metadata.
- Fast mode: PDF text layer with layout rules (rows, aligned columns, two-column pages, repeated headers and footers removed, right-to-left text in logical order). Accurate mode: Docling layout and table models with Tesseract OCR in English and Arabic for scanned pages.
- Web pages: main content only (trafilatura), with a guarded headless browser for pages that need JavaScript (`renderJs`).
- Optional chunks of a chosen token size (cl100k_base) cut at headings, then paragraphs, with overlap and the page each chunk starts on; optional JSON structure of every block; page ranges; texts above 2 MB stored in the key-value store with a link.
- Safety: every URL and redirect checked against private addresses (the browser's requests too), size limits, every file parsed in a separate process with a time and memory limit, ZIP and XML checks against decompression bombs and entity attacks, macros never run, the API token kept out of the parsing processes.
- Accurate mode converts pages 8 at a time (flat memory near 1,600 MB) and refuses to start below 3,072 MB of memory.
- Pay-per-event pricing: `url-converted` per saved source, `extra-page` per page beyond 5 in fast mode, `accurate-page` per PDF page in accurate mode. Failed sources are never charged; the maximum cost per run is respected before each source and before its pages are converted.
