If a document’s content stays exactly the same and only its page breaks move, will AI give a different answer?
The DocSEAM researchers moved page boundaries from between paragraphs or tables into the middle of them. Models that read documents one page at a time consistently performed worse. The answer depended not just on what the document said, but also on where its pages broke.
This is easy to overlook in ONTLE’s document review work. When defect remediation terms in a request for proposals (RFP) continue onto the next page, an answer based only on the first part can still sound plausible. Checking whether an answer reads naturally is unlikely to reveal the missing conditions.
DocSEAM strengthens these connections before the language model generates an answer. As it builds each page’s visual representation, it also looks at the pages before and after it.
Vision-language models (VLMs), which understand both images and text, typically process each document page as an image. A vision encoder converts the page into visual tokens—units of representation that capture portions of the image. These tokens are then concatenated and passed to the language model.
This approach scales readily to documents with more pages. But it rests on an assumption: a page’s representation can be built without looking at its neighbors.
Real documents often break that assumption. Paragraphs continue onto the next page, as do the remaining rows of a table. Processing each page separately makes it difficult to capture those connections in the visual representation. The paper calls this “feature-level discontinuity.”
The language model can compare pages later to fill in the context. DocSEAM intervenes earlier. Before improving retrieval or reasoning, it changes the page representations those processes receive.
Imagine scanning a book and building an index. If a worker receives only their assigned page, they may struggle to tell whether a table ends there or continues onto the next page. With the neighboring pages open as well, they can check the connection before finishing the index for their own page.
DocSEAM stands for Document Selective Enrichment via Anchored Masking. It plays a similar role between the vision encoder and the language model.
Each page sits at the center of a three-page group, with the preceding and following pages on either side. Where a neighbor is missing, such as at the beginning or end of a document, the current page fills the empty slot. This preserves the computation’s shape without requiring a separately learned blank-page representation.
The group uses a self-attention mask—a rule that determines which tokens may draw information from one another.
The center page exchanges information directly with both neighbors. The preceding and following pages do not connect directly to each other. Information passing between them must go through the center. This prevents “two-hop leakage” that would bypass the center within a single computation step.
Not everything near a boundary is useful. Headers, footers, page numbers, and blank margins offer little evidence that content continues across pages.
DocSEAM uses four gates to control how much information passes through each token. They handle sending to the next page, sending to the previous page, receiving from the previous page, and receiving from the next page.
It is like an indexer checking the preceding page, skipping its header and page number, and examining the rows of a split table. The gates select which information a neighboring page needs and which information needs help from a neighbor.
The gates consider both token content and distance from the points where the actual text begins and ends. Using these content boundaries rather than the edges of the paper reduces the effect of varying margins. The sending and receiving values are multiplied, so a connection is suppressed if either value is close to 0.
DocSEAM returns only the center page’s tokens, enriched with information from its neighbors. The index has the same length; what changes is the information it contains. Neither the number of visual tokens nor the input length received by the language model changes.
At the start of training, DocSEAM passes its input through unchanged. It then learns adjustments to add to the existing representation, taking the pretrained model’s behavior as its starting point. It adds 235M parameters, equivalent to 2.6% of the 9B base model.
Training has two stages. DocSEAM first learns connections between pages. The rest of the model then adapts to reading the modified representations.
The vision encoder and language model are frozen, and only DocSEAM is trained.
The data comes from MP-DocStruct1M. Training combines contiguous-page tasks that require evidence from multiple pages with single-page controls intended to preserve single-page reading ability.
Alongside reducing next-token prediction error, training encourages the gates to respond to actual content boundaries. It suppresses activation in margins and penalizes average activation above a set level.
The researchers also tried self-supervised boundary reconstruction, asking the model to recover masked content without separately labeled answers. They did not adopt this approach.
The model could reconstruct the masked tokens using information from the same page. It could solve the task without ever consulting a neighbor. The result was a “collapse” in which the gates failed to learn their intended role.
This failure offers a criterion for choosing training tasks. Masking content near a boundary is not enough. The task must require information from a neighboring page to give the model a reason to learn connections across that boundary.
DocSEAM is now frozen while the rest of the model receives further training. This uses LoRA, which learns small additional matrices.
The sequence preserves the boundary connections learned in Stage A while allowing the vision encoder and language model to adapt to the modified visual tokens.
Evaluation covered five multi-page document VQA benchmarks, which ask models to answer questions about documents.
DUDE and MP-DocVQA use ANLS, a string-matching score that tolerates minor differences such as typos. SlideVQA, MMLongBench-Doc, and LongDocURL use accuracy: the proportion of correct answers.
The main model is Qwen3.5-9B. In the paper’s evaluation, the DocSEAM-equipped model achieved the highest scores across all five benchmarks among open-weight models with 10B parameters or fewer.
The “matched SFT baseline” below uses the same base model and LoRA settings, trained on the same data as input–answer examples. This additional training on labeled examples is called supervised fine-tuning, or SFT.
| Benchmark | Metric | DocSEAM+Qwen3.5-9B | Gain over matched SFT baseline | Gain over other public methods |
|---|---|---|---|---|
| DUDE | ANLS | 63.0 | +8.9 | +5.4 over URaG |
| MP-DocVQA | ANLS | 89.2 | +1.7 | +1.0 over URaG |
| SlideVQA | Accuracy | 87.1 | +2.0 | +10.0 over DocSeeker |
| MMLongBench-Doc | Accuracy | 58.3 | +13.8 | — |
| LongDocURL | Accuracy | 62.9 | +20.1 | +10.7 over URaG |
The gains were far from uniform. The gaps were especially large on MMLongBench-Doc and LongDocURL, which evaluate long-document reasoning. Connecting page representations had a greater effect on tasks that require synthesizing information across long documents.
Another pattern emerges when comparing these results with “zero-shot” evaluation, where the model receives no additional task-specific training.
| Evaluation setup | MMLongBench-Doc | LongDocURL |
|---|---|---|
| Qwen3.5 zero-shot | 57.1 | 54.5 |
| Standard SFT | 44.5 | 42.8 |
| DocSEAM | 58.3 | 62.9 |
The SFT model, despite receiving more training on labeled answers, scored below the zero-shot model. The authors interpret this as a consequence of training that emphasizes finding short answers at the expense of multi-step reasoning.
DocSEAM recovered that loss and exceeded the zero-shot scores. The key question here is less “Was the model trained further?” and more “Which abilities survived that training?” Evaluating only short questions that resemble the training tasks can conceal a decline in the ability to synthesize long documents.
The matched SFT baseline also received all the data from Stage A and Stage B. The difference was that it learned from them in a single SFT run.
Table 4 in the paper also isolates the effect of adding data.
| Data used for SFT | MMLongBench-Doc | LongDocURL |
|---|---|---|
| Stage B data only | 44.3 | 42.6 |
| With Stage A data added | 44.5 | 42.8 |
Adding data made little difference. That makes it difficult to explain DocSEAM’s gains simply as a benefit of extra training data.
The researchers also applied DocSEAM to Qwen3.5-4B, Gemma3-4B, and Qwen2.5-VL-7B.
Using Qwen2.5-VL-7B, the same base model used by DocSeeker and URaG, DocSEAM scored 58.0 on DUDE and 88.3 on MP-DocVQA, outperforming both methods. The smaller Qwen3.5-4B produced the following results.
| Model / method | DUDE | MP-DocVQA |
|---|---|---|
| DocSEAM+Qwen3.5-4B | 57.5 | 86.3 |
| DocSeeker | 57.4 | 86.2 |
| URaG | 57.6 | 88.2 |
The smaller base model delivered competitive performance. It did not beat every comparison method, but the benefits extended beyond the main model.
Final answer scores alone cannot tell us what a model has become better at. The researchers separately examined its ability to locate evidence pages and its sensitivity to changes in page boundaries.
The researchers created 1,500 samples based on MPDocBench-Parse, assigning 500 to each of three tasks.
Cross-page lookup requires finding both pages across which content extends. Single-page lookup asks for the page containing the content, while presence verification asks whether specified content appears on a given page.
| Task | Zero-shot | SFT baseline | DocSEAM |
|---|---|---|---|
| Cross-page lookup | 50.2 | 65.0 | 85.8 |
| Single-page lookup | 86.0 | 70.0 | 94.2 |
| Presence verification | 91.8 | 95.6 | 94.0 |
Cross-page lookup improved by +20.8 over the SFT baseline. DocSEAM also recovered the single-page lookup performance lost after SFT. The SFT decline is thought to reflect overfitting to the characteristics of the training data.
Presence verification was slightly below SFT. The main improvement lay in locating evidence and recognizing connections between pages, rather than making every kind of judgment equally well.
An analysis tracing the information the model attends to supports this interpretation. When asked to locate text spanning a boundary, the DocSEAM model focused attention on the correct evidence at the language model’s 7th layer. A similar pattern appeared at the 11th layer in the baseline. This is qualitative evidence that DocSEAM uses the evidence earlier in the computation.
The page-splitting experiment introduced at the beginning divided every page in half near its midpoint.
Cuts through whitespace between paragraphs or tables were classified as “structure-preserving”; cuts through paragraphs or tables were “structure-breaking.” Both conditions had the same page count and pixel content. Only the boundary positions differed.
All figures below are in percentage points, and lower is better.
| Evaluation measure | Benchmark | Zero-shot | SFT | DocSEAM |
|---|---|---|---|---|
| Performance gap between structure-preserving and structure-breaking splits | MMLongBench-Doc | 1.3 | 1.2 | 0.8 |
| Performance gap between structure-preserving and structure-breaking splits | LongDocURL | 2.3 | 1.6 | 0.7 |
| Overall drop | MMLongBench-Doc | 4.6 | 3.6 | 1.5 |
| Overall drop | LongDocURL | 6.1 | 2.9 | 1.8 |
DocSEAM showed smaller drops on both measures. With document content held constant, its performance was less sensitive to where pages were split.
The distinction lies in where each method intervenes in document processing.
DocSEAM first enriches the page representations that enter these processes. This leaves room to combine it with improvements in retrieval or reasoning.
Its role also differs from vision encoder research that improves representations within a single page, such as ViTs that use native resolution, DAVE, DeepEncoder V2, and UNIT. DocSEAM addresses connections between pages.
The closest prior work is SVE. SVE lets the current image use information from the previous image within the ViT’s computational layers. DocSEAM operates after the vision encoder and takes advantage of having the entire document available to reference both preceding and following pages. Its gates, which exchange information based on actual content boundaries, are another document-specific distinction.
Applying these results leaves questions about training conditions, reference distance, evaluation scope, and operating costs.
How much of the training effect can be disentangled? The comparison with the matched baseline evaluates both the presence of the module and the staged training strategy. Learning boundary connections requires supervised data, so the quality and quantity of boundary-alignment data such as MP-DocStruct1M may also affect performance.
How far can the connections reach? Even without a direct connection between the preceding and following pages in one layer, information can pass indirectly through multiple layers. But stacking layers alone does not establish that the reference range expands to cover the whole document.
If updated neighboring-page representations are exchanged at every layer, information could theoretically propagate across L pages in L layers. If computation repeats only within a fixed three-page group, no pages outside that group enter the process. The description provided does not make it easy to determine the propagation range at different distances or how much information survives transmission.
It would therefore be premature either to conclude that DocSEAM cannot handle a table spanning three pages or to claim that it has solved distant references. A reference on page 20 to a definition 10 pages earlier needs evaluation with varying distances between evidence and varying layer counts. How much the language model or retrieval compensates for distant connections also remains an open question.
How far do the diagnostics support the conclusions? Locating evidence and answering complex questions are different abilities. The localization diagnostics complement the VQA evaluation. Likewise, controlled page-splitting experiments do not guarantee consistency across every document format or conversion method. Commercial models such as GPT-4o and Gemini 3 Pro scored higher on some metrics, and the paper compares these closed models separately.
Does the same input length mean the same cost? DocSEAM still adds computation. The authors report that it accounts for less than 7% of total forward-pass FLOPs—the computation required to produce outputs from inputs—for a 20-page document. The available results do not establish how that cost changes with document length or resolution.
Because the design looks at both preceding and following pages, it is also difficult to apply directly to real-time streaming when the next page has not yet arrived. The enriched tokens can, however, be reused for multiple questions about the same document. Actual operating costs require measuring both the additional computation and the benefits of reuse.
Suppose ONTLE’s AI PM is summarizing defect remediation terms and their supporting pages in a 50-page RFP. The terms begin at the bottom of a table on page 24 and continue onto page 25. If the model reads only the earlier rows, its answer may sound natural while omitting some conditions.
An assessment of DocSEAM for this work should begin with the following questions.
Validation should assess both answer accuracy and evidence completeness: whether the defect remediation terms are summarized correctly and whether all continuation pages are identified as evidence. It should also check that every condition is captured when the input document is split differently.
The practical benefit may also show up in corrective work. We can measure how much less effort goes into stitching together tables across pages or searching again for missing evidence. Reducing that work while maintaining answer and evidence quality would provide a reason to adopt the approach.
DocSEAM shows that document understanding errors can begin before the final answer, while visual representations are being built for individual pages. ONTLE’s criteria for entrusting RFP reviews to AI should reflect that. Beyond producing a plausible answer, the model needs to read the conditions that continue onto the next page and provide all the supporting evidence.