TL;DR
FEWVLM is a moderate-sized vision-language model that proves you don't need hundreds of billions of parameters to achieve impressive few-shot learning. By combining specific pre-training objectives with clever prompt engineering, FEWVLM (at 740M parameters) outperforms the 7B-parameter Frozen model and rivals the 175B-parameter PICa on visual question answering and captioning tasks.
What Problem Does This Paper Address?
Recent breakthroughs in vision-language (VL) models have relied on "gigantism"—scaling models to massive sizes (like GPT-3 or Frozen) to enable few-shot learning, where a model performs a new task after seeing only a handful of examples. While powerful, these models are impractically large for most real-world applications due to high deployment costs and slow inference speeds.
The authors tackle the challenge of low-resource learning: can we build a relatively small, "moderate-sized" model that retains the ability to generalize to new tasks with minimal data? They specifically investigate how prompt design and pre-training objectives influence this capability.
Methods
The authors propose FEWVLM, an encoder-decoder transformer architecture based on T5. Unlike models that use a fixed set of classification heads, FEWVLM treats every task as a generative text-to-text problem.
Key Innovations:
- Hybrid Pre-training: The model is pre-trained using two distinct objectives:
- Masked Language Modeling (MaskedLM): The model learns to fill in missing spans of text based on the image and surrounding context.
- Prefix Language Modeling (PrefixLM): The model learns to generate the "suffix" of a text sequence given an image and a "prefix."
- Prompt-based Learning: Instead of fine-tuning the whole model for every task, they use natural language prompts to guide the model. For example, a VQA task is converted into a prompt like:
question: [Q] answer: <text_1>. - Visual Representation: They use a Faster R-CNN to extract 36 object region features from images, which are then fed into the transformer encoder alongside the text tokens.
Datasets
- Pre-training: A massive collection of 9.18M image-text pairs from MS COCO and Visual Genome.
- Downstream Evaluation:
- VQA: VQAv2, OK-VQA (requires external knowledge), and GQA.
- Captioning: NoCaps and Flickr30k.
- Categorical Learning: miniImageNet (5-way k-shot setup).
Key Insights and Ideas
- Prompt Sensitivity vs. Data Volume: The choice of prompt wording (e.g., "a picture of" vs. "an image of") significantly impacts zero-shot performance. However, as more training examples are provided (few-shot), the model becomes much more robust to the specific prompt format.
- Noisy Prompts Catch Up: Surprisingly, even "noisy" or irrelevant prompts (like random sentences or instructions) eventually perform as well as hand-crafted prompts once the model sees enough training data (around 100+ examples).
- Objective Synergy: The authors found a "division of labor" between pre-training tasks. MaskedLM is particularly helpful for VQA (which involves predicting specific spans/answers), while PrefixLM is superior for open-ended tasks like image captioning.
- Efficiency: FEWVLM-base (224M parameters) is 31x smaller than Frozen but significantly more accurate, demonstrating that architecture and training strategy can often trump raw parameter count.
Key Results
- Zero-shot VQA: FEWVLM-base (224M) achieved 43.4% accuracy on VQAv2, outperforming the 7B-parameter Frozen model (29.5%) by a wide margin.
- Few-shot Scaling: FEWVLM-large (740M) achieved results comparable to PICa (which uses the 175B-parameter GPT-3) on VQAv2, despite being 246x smaller.
- Captioning: On the NoCaps dataset, FEWVLM-base outperformed the VL-T5 baseline by 31.1 CIDEr points, showing the power of the PrefixLM objective.
- Categorical Learning: On miniImageNet, FEWVLM significantly outperformed Frozen in 1-shot and 5-shot settings, proving its ability to learn new visual categories rapidly.
Limitations and Future Work
- Manual Prompt Engineering: The current prompts are hand-crafted. The authors suggest that automatic prompt generation could further optimize performance without human trial-and-error.
- Task Diversity: While they covered VQA and captioning, future work could explore more complex tasks like multiple-choice VQA or visual reasoning that requires multi-step logic.
- Pre-training Data: The study found that the choice of pre-training data (e.g., MS COCO vs. Conceptual Captions) matters significantly for downstream success, suggesting a need for more research into data curation for low-resource models.
Summary updated