Abstract
We present Unified Embeddings for Multimodal Retrieval (UniMuR), a simple but effective approach that embeds multimodal inputs and retrieves visual and textual outputs via frozen Large Language Models (LLMs). Specifically, UniMuR jointly retrieves multimodal outputs via a unified multimodal embedding and applies dual alignment training to account for both visual and textual semantics. Thus, unlike previous approaches, UniMuR significantly reduces LLM’s modality bias towards generating text-only outputs. Meanwhile, the proposed unified multimodal embedding mitigates the inconsistency between visual and textual outputs and provides coherent multimodal outputs. Furthermore, benefiting from the joint training of visual and textual semantics, UniMuR also achieves strong image/text retrieval ability. Compared to existing approaches, UniMuR achieves better zero-shot multimodal response retrieval performance on MMDialog, improving the overall R@1 by 6.5% while boosting the image retrieval rate and having better cross-modal consistency on multimodal outputs. UniMuR also achieves 2.4% and 3.9% improvement on context-based image retrieval tasks on MMDialog and VisDial respectively when compared to previous approaches, validating its generalization ability across multiple tasks.
Introduction
Large Language Models (LLMs) have demonstrated remarkable reasoning capabilities in text-based tasks. However, when extended to multimodal settings, they often exhibit a strong "modality bias." Because these models are pretrained on vast text corpora, they tend to favor text-only responses, even when visual information would be more appropriate or informative.
Existing methods often treat image and text retrieval as separate processes, leading to two primary issues: low visual prevalence (the model rarely outputs images) and cross-modal inconsistency (the retrieved text and image do not align). UniMuR addresses these challenges by creating a unified embedding space where images and text are treated as equal candidates for retrieval.
Methodology: The UniMuR Approach
UniMuR leverages frozen LLMs (e.g., OPT-6.7B) and vision encoders (CLIP) to maintain efficiency while learning to bridge modalities. The architecture focuses on two learnable linear mapping layers and a "Dual Alignment Training" (DAT) strategy.
Dual Alignment Training (DAT)
The core innovation of UniMuR is mapping the LLM’s final output embedding into a Unified Multimodal Embedding space. This space is trained using two distinct objectives:
- Visual Matching (VM): A contrastive loss (InfoNCE) aligns the unified embedding with CLIP’s visual features, ensuring the model can identify relevant images.
- Textual Matching (TM): A regression loss (MSE) aligns the unified embedding with CLIP’s textual features. The authors found that MSE is more effective than contrastive loss for text, as it more strictly preserves the LLM's inherent linguistic knowledge.
By training in this unified space, the model does not require special tokens to trigger image retrieval. Instead, images and text compete based on similarity, naturally increasing the frequency and relevance of visual outputs.
Experimental Results
The model was trained on the Conceptual Captions (CC3M) dataset and evaluated across several benchmarks, including MMDialog and VisDial.
Performance on MMDialog
On the MMDialog dataset for zero-shot multimodal response retrieval, UniMuR demonstrated significant improvements over the previous state-of-the-art, FROMAGe:
- Image Retrieval Rate: UniMuR achieved a 68.3% image retrieval rate, a massive jump from FROMAGe’s 28.2%.
- Accuracy: Overall R@1 improved by 6.5%.
- Consistency: The CLIP-Sim score, measuring the alignment between retrieved text and images, increased by 2.6%.
Generalization and Efficiency
UniMuR also showed strong performance on context-based image retrieval, improving R@1 by 2.4% on MMDialog and 3.9% on VisDial. Remarkably, the model is highly efficient; 98% of parameters remain frozen, and training was completed in under 16 hours on four NVIDIA V100 GPUs.
Conclusion
UniMuR provides a lightweight yet powerful framework for enabling frozen LLMs to perform multimodal retrieval. By utilizing a unified embedding space and dual alignment training, it successfully mitigates modality bias and ensures coherent, informative multimodal dialogues. Future work will explore extending this unified approach to direct multimodal generation.
Summary updated