TLDR: The Model–Document Protocol (MDP) is a new framework that transforms messy, unstructured data (like web pages and PDFs) into organized, “LLM-ready” knowledge. It uses pathways like agentic reasoning, memory grounding, and structured leveraging. MDP-Agent, an implementation of MDP, employs “gist memories” for documents and an agentic discovery process with diffusion search and parallel synthesis to efficiently gather and structure information. This approach significantly improves LLM performance on complex information-seeking tasks by providing compact, coherent context, outperforming existing retrieval methods.
Large Language Models (LLMs) have become incredibly powerful for information-seeking tasks, but they often hit a wall when dealing with the messy reality of real-world data. Imagine trying to find a needle in a haystack, but the haystack is also constantly shifting, full of irrelevant debris, and not organized in any logical way. This is what researchers call “Data Chaos” – the challenge of LLMs interacting with long, noisy, and unstructured documents like web pages and PDF files.
Traditional methods, known as Retrieval-Augmented Generation (RAG), simply pull raw text passages and feed them to the LLM. This leaves the heavy lifting of piecing together fragments and making sense of the context to the LLM itself, which can be inefficient and lead to errors, especially for complex queries requiring multi-step reasoning.
Introducing the Model–Document Protocol (MDP)
To address this fundamental problem, Hongjin Qian and Zheng Liu have introduced a groundbreaking framework called the Model–Document Protocol (MDP). MDP redefines how AI models interact with documents by transforming raw, unstructured data into “LLM-ready” knowledge. Instead of just fetching passages, MDP outlines multiple pathways to convert these chaotic documents into compact, structured, and directly consumable inputs for LLMs. The core idea is to ensure that what an LLM receives is not just raw fragments, but organized, coherent knowledge that it can immediately use for reasoning.
The MDP framework is built upon three complementary pathways:
- Agentic Reasoning: This pathway involves an iterative process where the system actively curates raw evidence, assembling fragments into a coherent, task-relevant context. It’s like having a smart assistant who sifts through information and organizes it specifically for your needs.
- Memory Grounding: This pathway focuses on accumulating persistent and reusable notes from past interactions or retrieved data. These “memories” enrich the reasoning process, allowing the LLM to build upon previously learned insights.
- Structured Leveraging: Here, curated knowledge is encoded into formal, structured formats. Think of it as turning raw text into a well-organized database, like key-value caches, relational graphs, or symbolic schemas, which makes the information easier for LLMs to interpret and reuse.
MDP-Agent: A Practical Implementation
As a concrete example of MDP in action, the researchers present MDP-Agent. This system tackles Data Chaos by iteratively exploring and exploiting external knowledge, distilling high-entropy retrieval results into a minimal yet sufficient knowledge space. This knowledge is then transformed into a task-specific, LLM-ready context.
MDP-Agent operates in two main stages:
1. Data Indexing with Gist Memory: Real-world documents vary greatly in length and structure. To handle this, MDP-Agent creates a “gist memory” for each document. This is a lightweight textual abstraction that captures the document’s high-level topics and structural cues, much like how humans remember the main points of a long article without recalling every detail. This gist memory, combined with a hybrid indexing scheme (dense embeddings for global semantics and sparse text for fine-grained details), allows for both broad coverage and precise access to information.
2. Agentic Knowledge Discovery: For complex tasks, the required knowledge isn’t found in a single step. MDP-Agent constructs this knowledge hierarchically and agentically. It plans information intents, breaks them down into atomic sub-queries, and then uses a “Diffusion Search” strategy to expand coverage, generating additional queries based on previous results. To manage the large volume of data, it employs “Memory-Guided Parallel Synthesis,” which filters out irrelevant pages using gist memory and processes the remaining relevant information in a map-reduce style. Finally, “Task-Aware Contextualization” organizes all the gathered information into a structured, LLM-ready knowledge chain, explicitly encoding the reasoning trajectory and supporting evidence.
Also Read:
- Graph-based Planning: A Leap Forward for AI Agent Efficiency
- Unlocking Deeper Insights: A New Framework for Corpus-Level AI Reasoning
Performance and Impact
Experiments on challenging information-seeking benchmarks like GAIA and WebWalkerQA demonstrate that MDP-Agent significantly outperforms traditional RAG methods and even advanced tool-integrated reasoning baselines. It shows remarkable gains on tasks requiring multi-hop reasoning and long-horizon synthesis, where other methods often struggle to provide coherent context.
The research highlights MDP-Agent’s efficiency, with reasoning consuming a small fraction of tokens compared to large-scale data processing. This balanced design allows strong central models to focus on complex reasoning while lightweight auxiliary models handle the bulk of text processing, ensuring scalability and performance.
In essence, the Model–Document Protocol and its instantiation, MDP-Agent, offer a principled and scalable solution to bridge the gap between raw, unstructured documents and the sophisticated reasoning capabilities of large language models. This framework promises to empower LLMs with genuine contextual intelligence, transforming the way AI systems access and utilize external knowledge. You can read the full technical report here: MODEL-DOCUMENT PROTOCOL FOR AI SEARCH.


