NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Knowledge Generation for Zero-shot Knowledge-based VQA

Rui Cao, Jing Jiang

Abstract

Researchers have developed KGENVQA, a novel framework for Knowledge-based Visual Question Answering (K-VQA) that eliminates the need for task-specific training. By prompting a Large Language Model (LLM) to explicitly generate a diverse set of background facts before attempting to answer a question, the system achieves state-of-the-art zero-shot performance. Beyond accuracy, this "Generate-and-Answer" paradigm provides human-readable explanations for the model's reasoning process, addressing the interpretability issues common in black-box VQA systems.

Introduction

Standard Visual Question Answering (VQA) typically requires a model to identify and describe elements visible within an image. However, Knowledge-based VQA (K-VQA) introduces a higher level of complexity by requiring external facts not present in the pixels. For instance, answering a question about a specific animal's habitat in a California national park requires the model to bridge the gap between visual recognition and geographic or biological knowledge.

Historically, approaches to K-VQA have followed two main paths: Retrieve-and-Answer, which relies on searching external databases like Wikipedia, and Directly Answer, which converts images to text captions for an LLM to process. The former is difficult to scale and requires complex retrieval infrastructure, while the latter often acts as a "black box" prone to hallucinations or failures in accessing specific internal knowledge. To solve these issues, the authors propose a third paradigm: Generate-and-Answer.

Three distinct approaches to K-VQA: (a) Retrieve and answer, (b) Directly answer, and (c) the proposed Generate and answer paradigm.

Methodology

The KGENVQA framework utilizes a multi-stage pipeline that treats an LLM as a flexible, internal knowledge base. The process begins with Question-Aware Captioning, where the model generates text descriptions focused on image regions relevant to the specific query. This is followed by Initial Knowledge Generation, where an LLM (such as GPT-3.5) is prompted with the caption and question to produce a single relevant fact.

To prevent the model from relying on narrow or repetitive information, the researchers introduced Self-supervised Knowledge Diversification. By using K-means clustering on a pool of previously generated triplets (caption, question, knowledge), the system samples diverse "demonstrations" to prompt the LLM to generate a broader set of knowledge statements. Finally, in the Knowledge Integration phase, these diverse facts, the captions, and the question are fed into a pre-trained QA model (e.g., UnifiedQA or OPT) to derive the final answer.

Experimental Results

The authors evaluated KGENVQA on two primary benchmarks: OK-VQA, the standard for knowledge-intensive VQA, and A-OKVQA, a more challenging successor requiring multi-step reasoning.

KGENVQA consistently outperformed existing zero-shot methods across various model architectures and sizes. A key finding was that forcing the LLM to explicitly write down facts as an intermediate step significantly improved accuracy compared to implicit reasoning. For example, using UnifiedQA (3B) with generated knowledge improved OK-VQA accuracy from 39.6% to 44.5%.

Performance comparison on OK-VQA and A-OKVQA benchmarks, demonstrating consistent accuracy gains across different model sizes when using generated knowledge (w KGen).

Beyond quantitative metrics, human validation confirmed the reliability of the generated knowledge. Evaluators found that 99% of the generated facts were grammatical, 100% were relevant to the context, and 94.5% were factually correct. This high degree of reliability allows the generated knowledge to serve as an interpretable trace of the model's logic.

Conclusion and Future Work

KGENVQA demonstrates that explicit knowledge generation is a powerful tool for zero-shot reasoning. While the diversification strategy effectively broadens the model's context, some redundancy remains in the LLM outputs. Additionally, the system currently relies on an intermediate captioning step, which can create a bottleneck if the captioner misses subtle visual details. Future research will likely focus on Pre-trained Vision-Language Models (PT-VLMs) that can generate knowledge directly from image inputs, further streamlining the pipeline and reducing information loss.

Summary updated

BibTeX
@inproceedings{cao2024knowledge,
  author = {Rui Cao and Jing Jiang},
  title = {{Knowledge Generation for Zero-shot Knowledge-based VQA}},
  booktitle = {EACL (Findings)},
  year = {2024},
}
Figure