Abstract
This tutorial note summarizes the presentation on "Large Multimodal Models: Towards Building and Surpassing Multimodal GPT-4", a part of the CVPR 2023 tutorial on "Recent Advances in Vision Foundation Models". The tutorial consists of three parts. We first introduce the background on recent GPT-like large models for vision-and-language modeling to motivate the research in instruction-tuned large multimodal models (LMMs). As a pre-requisite, we describe the basics of instruction-tuning in large language models, which is further extended to the multimodal space. Lastly, we illustrate how to build the minimum prototype of multimodal GPT-4 like models with open-source resources and review recently emerged topics.
Introduction
While Large Language Models (LLMs) like ChatGPT revolutionized natural language processing, their ability to interact with the visual world remained a significant frontier. When OpenAI released GPT-4 with multimodal capabilities, it demonstrated an uncanny ability to reason about images—such as explaining visual humor or complex diagrams. However, GPT-4 remains a closed, proprietary model.
The central challenge addressed in this tutorial is how the research community can build open-source, end-to-end trained LMMs that mimic GPT-4’s multimodal reasoning. The tutorial identifies a "research gap" in instruction-following and alignment within the multimodal space, moving beyond simple image captioning toward complex, multi-turn visual dialogue.
Methodology
The tutorial outlines a standardized architecture and training pipeline for modern LMMs, using LLaVA (Large Language-and-Vision Assistant) as the primary case study.
Architecture
The LLaVA recipe utilizes a modular approach consisting of three main components:
- Vision Encoder: A pre-trained model (typically CLIP ViT-L/14) that extracts visual features.
- Language Model: A powerful LLM (like Vicuna or LLaMA) that handles reasoning and generation.
- Connection Module: A simple linear projection matrix that maps visual features into the language model's word embedding space.
Training Pipeline and Tokenization
To enable the model to process visual information as if it were text, images are converted into "visual tokens." These tokens are interleaved with text tokens and fed into the language model, which is trained to predict the next token in the sequence.
The training follows a two-stage process:
- Stage 1: Pre-training for Feature Alignment. Only the projection matrix is updated using image-caption pairs to teach the model how visual features relate to language.
- Stage 2: Fine-tuning End-to-End. Both the projection matrix and the LLM are updated using generated instruction-following data to enable "visual chat" capabilities.
GPT-Assisted Data Generation
Since high-quality multimodal instruction data is scarce, the authors employed a "self-instruct" method. By feeding text-only GPT-4 symbolic representations of images (captions and bounding box coordinates), they prompted it to generate conversations, detailed descriptions, and complex reasoning questions about those images.
Key Insights and Results
- Instruction Tuning is Essential: Just as instruction tuning transformed GPT-3 into ChatGPT, the transition from CLIP to LMMs requires explicit alignment with human intent.
- Emergent OCR: Models like LLaVA demonstrate a surprising emergent property of zero-shot Optical Character Recognition (OCR), allowing them to read and reason about text in images without explicit training.
- Performance: On a synthetic evaluation set, LLaVA achieved an 85.1% relative score compared to GPT-4. It also set a new state-of-the-art on the ScienceQA benchmark (92.53%) when using GPT-4 as a judge to ensemble outputs.
- Domain Adaptation: The tutorial introduces LLaVA-Med, demonstrating that these models can be successfully adapted to specialized fields like biomedicine with minimal additional training.
Limitations and Future Work
Despite their success, open-source LMMs still face gaps compared to GPT-4, particularly in handling high-resolution images and long sequences of interleaved content. They are also prone to "object hallucination," where the model claims to see objects not present in the image. Future research directions include scaling these models, developing better evaluation benchmarks (like POPE for hallucinations), and expanding to other modalities such as audio and depth.
Summary updated