Visual document understanding typically requires separate retrieval and generation models, doubling memory and system complexity. We present Hydra, a dual-head approach that provides both ColBERT-style late-interaction retrieval and autoregressive generation from a single vision-language model. A single LoRA adapter, trained only for retrieval, is toggled at inference: enabling it produces multi-vector embeddings; disabling it recovers the base model's generation quality, with 426 of 426 language-model weight tensors byte-for-byte identical to a freshly-loaded Qwen3.5-4B. We identify two failure modes that can silently break generation in retrieval-fine-tuned VLMs (attention-mode restoration and lm_head preservation) plus an efficiency requirement (KV-cache-aware decoding); Hydra sidesteps the first two structurally and addresses the third in the decode loop. We release two scales, Hydra-4B and Hydra-0.8B, sharing LoRA hyperparameters (r=32, alpha=32) and optimisation recipe; data mix and projection dim differ across scales. The single-model design cuts peak GPU memory from 28.85 GB to 10.77 GB at 4B (62.7% reduction) and from 5.79 GB to 2.37 GB at 0.8B (59.1%) relative to a co-resident two-model deployment. A controlled ablation finds GritLM-style joint training matches Hydra's retrieval-only training on the evaluated modes while its LoRA-on generation mode collapses. A proof-of-concept on Qwen2.5-Omni-3B preserves generation equivalence on a non-Qwen3.5 backbone and transfers image retrieval within 2-8 pp of Hydra-4B, with zero-shot audio retrieval emerging through the frozen Whisper encoder.
翻译:视觉文档理解通常需要独立的检索模型与生成模型,导致内存与系统复杂度翻倍。我们提出 Hydra,一种双头方法,通过单个视觉语言模型同时提供 ColBERT 风格的延迟交互检索与自回归生成。一个仅针对检索训练的 LoRA 适配器在推理时可切换:启用它可生成多向量嵌入;禁用它可恢复基模型的生成质量,其中 426 个语言模型权重张量中的 426 个与全新加载的 Qwen3.5-4B 逐字节相同。我们识别出两种可能在检索微调 VLM 中悄无声息破坏生成的失败模式(注意力模式恢复与 lm_head 保存),以及一个效率要求(KV 缓存感知解码);Hydra 从结构上避开前两种,并在解码循环中处理第三种。我们发布两个规模版本——Hydra-4B 与 Hydra-0.8B——共享 LoRA 超参数(r=32, alpha=32)与优化配方,但数据混合与投影维度因规模而异。与共存的双模型部署相比,单模型设计将峰值 GPU 内存从 28.85 GB 降至 10.77 GB(减少 62.7%,4B 规模),从 5.79 GB 降至 2.37 GB(减少 59.1%,0.8B 规模)。受控消融实验发现,GritLM 风格联合训练在评估模式下与 Hydra 的仅检索训练性能相当,但其 LoRA 开启的生成模式会崩溃。在 Qwen2.5-Omni-3B 上的概念验证实验表明,在非 Qwen3.5 骨干网络上保持了生成等价性,并实现了与 Hydra-4B 相差 2-8 个百分点的图像检索迁移,且通过冻结的 Whisper 编码器涌现出零样本音频检索能力。