Summary
DocSEAM is a 2-layer, ~235M-parameter transformer placed between a page-wise vision encoder and the LLM of a VLM (mainly Qwen3.5-9B). For each page it attends over the triplet with a center-anchored mask (Eq. 5: neighbours see only themselves and the centre, so previous and next pages never interact directly within a layer). Four per-token directional salience gates add the bias to cross-page logits (Eqs. 8-9). Only the enriched centre-page tokens are returned, so the visual token count is unchanged. The module is zero-initialised to an exact identity. It is trained alone in Stage A on cross-page supervision from MP-DocStruct1M plus a gate prior loss, then frozen while LoRA fine-tunes the LLM and merger in Stage B.