This documentation details the `toMarkdown` utility within Cloudflare Workers AI, which converts various file formats like PDF, HTML, and images into structured Markdown. This process is designed to optimize data for large language models (LLMs), retrieval-augmented generation (RAG) pipelines, and AI Agents.
Highlights
Supports a wide range of formats including PDF, XML, Microsoft Office, CSV, Apple documents, and common image types.
Facilitates better LLM performance by providing structured, semantic, and machine-readable input.
Image conversion utilizes specialized Workers AI models for automated object detection and summarization.
Provides detailed output metadata including filename, MIME type, estimated token count, and the converted content.
RAG PipelinesLarge Language ModelsAI AgentsDocument ProcessingObject Detection
Discover Similar Content
acceptmarkdown.com
Serve Markdown to AI Agents with Accept Headers
Serve Markdown to AI agents and LLMs via the Accept: text/markdown header. Browsers get HTML, agents get clean Markdown.
github.com
GitHub - microsoft/markitdown: Python tool for converting files and office documents to Markdown.
Python tool for converting files and office documents to Markdown. - microsoft/markitdown
blog.cloudflare.com
Introducing Markdown for Agents
The way content is discovered online is shifting, from traditional search engines to AI agents that need structured data from a Web built for humans. ...