Improving Zero-shot Visual Question Answering via Large Language Models with Reasoning Question Prompts

Yunshi Lan, Xiang Li, Xin Liu, Yang Li, Wei Qin, Weining Qian

Abstract

Zero-shot Visual Question Answering (VQA) leverages the vast knowledge of Large Language Models (LLMs) to answer questions about images without task-specific training. However, a significant "semantic gap" exists between the visual content and the textual queries, which are often written for humans and contain ambiguous references. This paper introduces the Reasoning Question (RQ) Prompts framework, an unsupervised "Generate-then-Choose" pipeline that rewrites ill-posed questions into self-contained reasoning prompts. By grounding question entities in image captions, the method achieves state-of-the-art results across several zero-shot benchmarks, including OK-VQA and A-OKVQA.

Introduction

Visual Question Answering (VQA) is a multimodal task requiring a model to reason over visual and textual inputs. In the zero-shot setting, where no labeled training data is provided, the standard paradigm involves converting an image into a descriptive text caption and prompting a pre-trained LLM to provide an answer.

Despite the power of LLMs, this approach often falters due to the "semantic gap." VQA questions are typically designed for human observers who have the image in view. Consequently, questions often contain ellipses or ambiguous pronouns (e.g., "What is this appliance used for?"). For a text-only LLM reading a caption, mapping "this appliance" to a specific object mentioned in the text is a non-trivial reasoning step. These "ill-posed" questions make LLMs brittle, leading to incorrect inferences even when the necessary information is present in the caption.

The RQ Prompts Framework

To address this, the researchers developed RQ Prompts (Reasoning Question Prompts). This framework automatically transforms ambiguous questions into explicit, self-contained queries that are easier for LLMs to process. The system operates via a four-stage "Generate-then-Choose" pipeline.

1. Unsupervised Question Edition

The core innovation lies in the unsupervised modification of the original question. Using constituency parse trees, the system identifies specific segments in the question (such as "this object" or "the appliance") that require grounding. It then replaces these segments with relevant constituents extracted from the image caption (e.g., "the blow dryer"). This process creates a set of candidate "reasoning questions" that are more explicit than the original.

2. Scoring and Ranking

To ensure the quality of the generated questions, the framework employs a multi-faceted scoring function. Each candidate question is evaluated based on:

  • Language Model (LM) Score: Assessing the fluency and naturalness of the sentence.
  • Semantic Integrity: Ensuring the edited question preserves the original intent of the query.
  • Syntactic Invariance: Verifying that the replacement maintains grammatical correctness (e.g., ensuring a noun phrase is replaced by another noun phrase).

3. Candidate Answer Generation

The top-$k$ ranked reasoning questions are fed into a frozen LLM (such as GPT-3 or OPT) along with the image caption. This produces a set of potential answers, each associated with a confidence score derived from the model's output probabilities.

4. Final Answer Selection

In the final stage, the LLM performs a "reasoning" step. It is provided with a prompt containing the original caption, the original question, and the list of candidate answers generated in the previous step. The model then selects the most likely correct answer, effectively using the candidate answers as "hints" to correct initial misinterpretations.

Experimental Results

The RQ Prompts framework was evaluated on four major VQA benchmarks: OK-VQA (outside knowledge), A-OKVQA (complex reasoning), VQAv2 (standard large-scale), and COCO Captions. The researchers tested the method across various LLM backbones, including GPT-3 (175B), OPT (up to 30B), BLOOM, and GPT-J.

Performance Gains

The method demonstrated consistent improvements over zero-shot baselines, with accuracy gains ranging from 0.3 to 5.2 points. Notably, the framework achieved new state-of-the-art (SOTA) results for zero-shot VQA on OK-VQA and both the validation and test sets of A-OKVQA. In several instances, this zero-shot approach outperformed previous methods that utilized 16-20 "few-shot" examples, highlighting the efficiency of the reasoning prompt strategy.

Key Insights

  • Explicit Grounding: LLMs perform significantly better when the reasoning path is explicit. By naming the object directly in the question, the model's "cognitive load" is reduced, allowing it to focus on retrieving knowledge rather than disambiguating pronouns.
  • Scaling Benefits: The effectiveness of RQ Prompts scales with model size. Larger LLMs possess more internal world knowledge, but they require precise, unambiguous queries to unlock that knowledge effectively.
  • Heuristic Correction: The two-stage process allows the LLM to act as its own editor. Providing candidate answers in the final prompt helps the model overcome the limitations of the initial caption-to-text conversion.

Conclusion and Future Work

The RQ Prompts framework offers a robust, unsupervised method for improving zero-shot VQA by bridging the semantic gap between images and text. While highly effective, the system remains dependent on the quality of the initial image captions. If a captioning model fails to identify a critical object, the question edition module lacks the necessary context to improve the prompt. Future research may explore integrating more complex "Chain-of-Thought" strategies and improving the efficiency of the multi-pass inference process to reduce computational overhead.

Summary updated

BibTeX
@inproceedings{lan2023improving,
  author = {Yunshi Lan and Xiang Li and Xin Liu and Yang Li and Wei Qin and Weining Qian},
  title = {{Improving Zero-shot Visual Question Answering via Large Language Models with Reasoning Question Prompts}},
  booktitle = {ACM Multimedia},
  year = {2023},
  doi = {10.1145/3581783.3612389},
}
Figure