Data & documents

A new standard for consistent document parsing in AI agents

The Document Parsing Protocol 0.1 defines 140 rules for converting documents into structured text, aiming to reduce ambiguity for AI agents.

Documents turning into structured code
Illustration generated for this article

On October 28, 2026, the team behind ParseBench released working draft 0.1 of the Document Parsing Protocol (DPP). This new specification aims to solve the inconsistency problem in how AI agents interpret parsed documents by providing a standardized set of rules for converting pages into structured text.

What happened

Document parsing has long been a source of friction for developers building AI agents. When a parser converts a PDF or image into text, it must make numerous judgment calls about layout and structure. Different parsers often make different choices, leading to outputs that contain all the correct words but convey different meanings. Because AI agents rely entirely on this parsed input, any structural error in the parsing stage propagates directly into the agent’s reasoning and final answer.

To address this, the authors introduced DPP as a shared definition of what a correctly parsed page looks like. The protocol grew out of the internal guidelines used by annotators labeling data for ParseBench, a document parsing benchmark. Draft 0.1 includes 140 specific rules covering text, tables, forms, charts, and diagrams. Each rule is accompanied by example pages and the expected output, providing a clear reference for developers and evaluators.

The release invites the community to test the protocol and provide feedback. The authors have made the draft available online with tools to test it against large language models like Claude and ChatGPT. They encourage users to open issues or pull requests on GitHub if they encounter documents where the rules fail or conflict, aiming to refine the standard through open collaboration.

How it works

The core mechanism of DPP is to replace ambiguous markdown conversions with precise structural representations where necessary. For example, standard markdown tables cannot represent headers that span multiple columns. In a sales report where years span several quarters, a markdown converter might flatten the headers or drop them entirely, causing an AI agent to misattribute data. DPP mandates the use of HTML tables with colspan attributes to preserve the exact visual hierarchy of the original document. This ensures that a value like "4.1%" remains explicitly linked to "Q2" under the "2024" header.

Beyond tables, the protocol defines strict handling for other complex elements. Empty form fields are marked as [blank] to distinguish them from missed fields, and checkboxes are represented as [x] or [ ]. Charts are converted into data tables with exact printed values, while diagrams are translated into Mermaid code when possible, or described textually with all labels preserved. The protocol also specifies that hidden text in PDFs should be excluded, while unreadable visible text is marked as [illegible]. Optional position data allows every element to be mapped back to its location on the source page.

Key details

  • DPP 0.1 contains 140 rules covering text, tables, forms, charts, and diagrams.
  • The protocol requires HTML tables for complex headers to preserve column spanning.
  • Empty form fields are explicitly marked as [blank] to prevent data loss ambiguity.
  • Charts are converted into structured tables with exact numeric values from the source.
  • Diagrams are output as Mermaid code or descriptive text with all labels retained.
  • The draft is open for community feedback via GitHub issues and pull requests.

Why it matters

For engineers building retrieval-augmented generation (RAG) systems or document analysis tools, consistency is critical. Without a standard, two teams can grade the same parser output differently, making it difficult to compare performance or debug errors. DPP provides a common language for evaluating parser quality. By defining exactly how structural elements should be represented, it reduces the cognitive load on AI agents, allowing them to focus on reasoning rather than deciphering ambiguous formatting.

This standardization also impacts how benchmarks are constructed. Previously, benchmark creators had to make private decisions about what constituted a "correct" parse. DPP makes these decisions explicit and open to scrutiny. This transparency helps the entire ecosystem move toward more reliable document processing pipelines. As AI agents take on more complex tasks involving financial reports, legal contracts, and technical manuals, the fidelity of the initial parsing step becomes a primary determinant of system accuracy.

What you can do

  • Visit parseprotocol.com to view the source pages alongside their expected DPP outputs.
  • Test the protocol by uploading a page image to Claude or ChatGPT using the provided skills.
  • Verify that specific values, such as numbers in parentheses, are preserved exactly in the output.
  • Review the walkthrough examples to understand the reasoning behind specific parsing decisions.
  • Identify edge cases in your own document sets that may not be covered by the current 140 rules.
  • Contribute to the standard by opening GitHub issues with examples of rule conflicts or failures.
  • #ai agents
  • #document parsing
  • #data standards
  • #ocr
  • #llm

Tools from the Bytechap store

Keep reading

All stories