Compositional Chain-of-Thought Prompting for Large Multimodal Models

TL;DR

Proposes CCoT, a zero-shot chain-of-thought method using scene graphs to improve large multimodal models' compositional reasoning, boosting benchmark scores.

cs.CV 🔴 Advanced 2023-11-28 38 views
Chancharik Mitra Brandon Huang Trevor Darrell Roei Herzig
multimodal reasoning scene graph zero-shot prompting compositionality

Key Findings

Methodology

This paper introduces Compositional Chain-of-Thought (CCoT), which combines scene graph (SG) generation with prompt-based reasoning in large multimodal models like GPT-4V and LLaVA. The approach involves two main steps: first, generating an SG in JSON format from the image and task prompt, capturing objects, attributes, and relations; second, using this generated SG along with the image and prompt as input to produce a more structured response. This process leverages the zero-shot capabilities of pre-trained models, avoiding costly fine-tuning or annotated SG datasets. Experiments on benchmarks such as Winoground, WHOOPS!, and SEEDBench show performance improvements exceeding 10%, demonstrating broad applicability across different models and tasks.

Key Results

  • On LLaVA-1.5-13B, the CCoT method improved Winoground group matching accuracy by 13.5%, with overall scores rising from 58.2% to 69.7%. GPT-4V with CCoT achieved a 3% increase across multiple tasks, especially in complex relation reasoning. Ablation studies confirmed the importance of JSON formatting and scene graph generation strategies, with performance drops of 5-8% when these are removed. The method proved stable across different input lengths and architectures, indicating robustness.
  • Compared to baseline zero-shot chain-of-thought prompting, CCoT consistently outperformed in all benchmarks, including VL compositional tasks and general multimodal reasoning. It surpassed models fine-tuned on scene graphs (e.g., SGVL) without additional training, highlighting its efficiency and effectiveness. The results validate that structured scene representations significantly enhance the model's understanding of object attributes, relationships, and scene structure.
  • Ablation experiments revealed that the quality of generated scene graphs directly correlates with reasoning performance. Using JSON format and conditioned prompts improved accuracy, while removing these components caused notable performance degradation. The method's generality was demonstrated across multiple models, confirming its potential as a universal enhancement for multimodal reasoning systems.

Significance

This work addresses a fundamental bottleneck in multimodal AI: the limited ability of models to perform structured, compositional reasoning about complex scenes. By integrating scene graph generation into the inference process without requiring costly annotation or fine-tuning, CCoT offers a scalable solution that leverages existing pre-trained models' capabilities. This approach bridges the gap between unstructured object detection and structured scene understanding, enabling models to better interpret relationships and attributes crucial for tasks like visual question answering, scene understanding, and robotics. The method's zero-shot nature makes it highly adaptable, promising widespread impact in both academic research and industry applications, such as autonomous systems and intelligent assistants.

Technical Contribution

The paper introduces a novel prompting paradigm that integrates scene graph generation within a chain-of-thought framework, leveraging pre-trained models' zero-shot reasoning. Key innovations include: • Designing a JSON-based scene graph prompt Sin that guides the model to produce structured representations of objects, attributes, and relations. • Using the generated scene graph as an intermediate reasoning step, which enhances the model's understanding of scene structure without fine-tuning. • Demonstrating broad applicability across different large multimodal models, with performance gains on multiple benchmarks. This approach opens new avenues for scalable, structure-aware multimodal reasoning.

Novelty

This is the first work to incorporate scene graph generation directly into a zero-shot, prompt-based chain-of-thought reasoning framework for large multimodal models. Unlike prior methods that rely on annotated scene graphs or caption-based reasoning, CCoT generates scene graphs dynamically during inference, avoiding costly annotation and fine-tuning. Its ability to improve compositional understanding across diverse models and tasks marks a significant leap forward in scalable structured reasoning, setting a new standard for multimodal AI.

Limitations

  • The quality of scene graph generation heavily depends on the model's reasoning capacity; complex or ambiguous scenes may produce inaccurate graphs, affecting downstream responses.
  • In scenarios with highly cluttered or occluded scenes, the generated scene graphs may lack completeness, limiting reasoning depth.
  • Current experiments focus on image-based benchmarks; extension to video or 3D scenes requires further development. Computational costs for scene graph generation may also pose challenges in real-time applications.

Future Work

Future research will explore integrating self-supervised learning to improve scene graph accuracy, especially in complex scenes. Combining multi-task training with large-scale pretraining could further enhance the model's structural understanding. Extending the approach to video and 3D scene understanding, as well as optimizing inference efficiency, are promising directions. Additionally, exploring unsupervised or weakly supervised scene graph generation methods could reduce reliance on model capacity and improve robustness.

AI Executive Summary

Despite rapid advances in multimodal AI, current models still struggle with understanding complex scene structures and relationships, often reducing scenes to a 'bag of objects' representation. This limitation hampers their performance in tasks requiring detailed relational reasoning, such as visual question answering and scene comprehension. Existing solutions like supervised scene graph annotations are costly and not scalable, creating a bottleneck for broader deployment.

In response, this paper introduces Compositional Chain-of-Thought (CCoT), a novel prompting strategy that leverages pre-trained models' zero-shot reasoning capabilities. The core idea is to generate a scene graph—a structured, JSON-formatted representation of objects, attributes, and relationships—directly within the inference process. This scene graph acts as an intermediate reasoning step, providing the model with a structured understanding of the scene, which it then uses to produce more accurate and relational responses.

The method involves two key stages: first, prompting the model to generate a scene graph based on the image and task prompt; second, incorporating this generated graph into the final response prompt, guiding the model to reason over scene structure explicitly. This approach avoids costly fine-tuning and annotation, making it highly scalable and adaptable across different models like GPT-4V, LLaVA, and InstructBLIP.

Extensive experiments on benchmarks such as Winoground, WHOOPS!, and SEEDBench demonstrate that CCoT consistently outperforms baseline prompting strategies, with improvements exceeding 10%. Notably, the method enhances the understanding of object attributes, relations, and scene composition, leading to significant gains in compositional reasoning tasks. The ablation studies confirm the importance of JSON formatting and scene graph quality, while the robustness across models underscores its broad applicability.

This work marks a significant step toward more structured, relational reasoning in multimodal AI, with potential applications in autonomous navigation, robotics, and intelligent assistants. Future directions include integrating unsupervised scene graph learning, extending to video and 3D environments, and optimizing inference efficiency. Despite current limitations in scene graph accuracy for highly complex scenes, CCoT offers a scalable, effective pathway to elevate multimodal understanding and reasoning capabilities.

Deep Analysis

Background

The evolution of multimodal AI has transitioned from early fusion models to large-scale pretraining of vision-language models like CLIP, Flamingo, and BLIP. These models excel at perception tasks but often lack the capacity for structured, relational reasoning, especially in complex scenes. Scene graphs have been used as a formalized representation to encode objects, attributes, and relations, facilitating reasoning in tasks like visual question answering and scene understanding. However, their reliance on costly annotations limits scalability. Recent efforts focus on leveraging large pre-trained models for zero-shot reasoning, but these models tend to treat scenes as unstructured collections of objects, impairing performance on compositional tasks. Addressing this gap, the current work proposes a method to generate scene graphs dynamically during inference, enabling structured reasoning without annotation overhead.

Core Problem

Despite advancements, large multimodal models still underperform in tasks requiring detailed scene understanding and relational reasoning. The primary challenge is their tendency to perceive scenes as a 'bag of objects,' lacking explicit structural representations. Existing solutions rely on supervised scene graph annotations, which are expensive and not scalable. Moreover, fine-tuning models on scene graph data leads to catastrophic forgetting of pretraining objectives, reducing versatility. Therefore, a scalable, annotation-free approach to enhance compositional reasoning remains an open problem, crucial for applications demanding nuanced scene comprehension such as autonomous navigation, robotics, and complex visual question answering.

Innovation

The key innovations include: 1) A zero-shot, prompt-based scene graph generation mechanism (Sin) that constructs structured scene representations in JSON format, guiding the model to reason about objects, attributes, and relations. 2) Integrating the generated scene graph as an intermediate reasoning step, which improves the model’s understanding of scene composition without requiring additional training. 3) Demonstrating broad applicability across multiple models (GPT-4V, LLaVA, InstructBLIP) and tasks, with performance gains on diverse benchmarks. This approach uniquely combines the strengths of chain-of-thought prompting with dynamic scene understanding, avoiding costly annotations and fine-tuning, thus offering a scalable solution for structured multimodal reasoning.

Methodology

  • �� Input: image I and task prompt Pin.
  • �� Design scene graph prompt Sin, instructing the model to generate a structured JSON scene graph capturing objects, attributes, and relations.
  • �� Generate scene graph Sg = f(vϕ(I), l(Pin + Sin)), where vϕ is vision encoder, l is language embedding.
  • �� Construct a combined prompt P(2)in including image, scene graph, task prompt, context sentence C, and answer prompt E.
  • �� Feed P(2)in into the model to produce response R, which incorporates scene structure understanding.
  • �� This process is zero-shot, leveraging the model’s inherent reasoning without fine-tuning, and uses the generated scene graph as an explicit reasoning aid.

Experiments

Experiments involved applying CCoT to models like GPT-4V, LLaVA-1.5, and InstructBLIP, evaluated on benchmarks including Winoground, WHOOPS!, and SEEDBench. The evaluation metrics included accuracy on compositional tasks, group matching, and relation understanding. Baselines included no prompting, standard chain-of-thought prompting, and models fine-tuned on scene graphs. Ablation studies examined the impact of JSON formatting, scene graph quality, and input length. Results showed consistent performance improvements, with over 10% gains in key metrics, validating the effectiveness of the scene graph-based prompting strategy across models and tasks.

Results

CCoT outperformed baseline prompts across all benchmarks: Winoground group accuracy increased from 58.2% to 69.7%, overall scores improved by 13.5%. InstructBLIP-13B with CCoT achieved a 14.6% performance boost. Ablation confirmed JSON formatting and scene graph quality as critical factors. The method demonstrated robustness across different input lengths (e.g., 128, 512, 1024 tokens) and model sizes, maintaining performance stability. Performance gains were especially notable in tasks involving object relations and scene structure understanding, confirming the hypothesis that structured prompts enhance compositional reasoning.

Applications

CCoT can be immediately applied to improve visual question answering, scene understanding, and robotic perception systems. Its zero-shot nature makes it suitable for deployment in resource-constrained environments, reducing reliance on costly annotations. The approach can enhance autonomous navigation, surveillance, and assistive robots by providing structured scene comprehension. Long-term, integrating CCoT with continual learning and multi-task training could lead to more autonomous, reasoning-capable AI systems capable of understanding complex, dynamic environments, advancing fields like autonomous driving, smart surveillance, and human-robot interaction.

Limitations & Outlook

The quality of generated scene graphs heavily depends on the underlying model's reasoning ability; complex or ambiguous scenes may produce inaccurate graphs, limiting downstream response quality. In scenes with occlusion or clutter, scene graphs may lack completeness, affecting reasoning depth. The approach's computational overhead for scene graph generation may hinder real-time applications, especially in high-resolution or video data. Additionally, current experiments focus on static images; extending to videos or 3D scenes requires further development. Future work should address these issues to improve robustness and efficiency.

Plain Language Accessible to non-experts

想象你在玩一个拼图游戏。每一块拼图代表一个物体,比如一只狗或一棵树。传统的模型就像只知道拼图碎片,但不知道它们怎么拼在一起。现在,我们用一张“场景图”,就像一份详细的拼图说明书,告诉模型:狗在左边,树在右边,它们之间有追逐的关系。这样,模型就能更好地理解整个场景,知道哪个物体在前,哪个在后,关系是追逐还是合作。这个“说明书”帮助模型变得更聪明,能更准确地描述场景或回答问题,就像你用说明书拼出完整的图一样。它让模型像一个懂得看图理解的聪明助手。

ELI14 Explained like you're 14

想象你在玩一个超级复杂的拼图游戏。每块拼图代表一个物体,比如一只狗或一棵树。普通的模型就像只知道拼图的碎片,但不知道它们怎么拼在一起。现在,我们给它一张“场景图”,告诉它:这只狗在左边,追着一只猫,树在右边。这就像给它一份详细的地图,让它知道每个物体之间的关系。这样,模型就能更聪明地理解整个画面,知道谁在追谁,谁在前谁在后。它可以用这个“地图”更快地回答问题,比如“狗在追猫”或者描述场景。这个方法让模型变得更像一个会看图理解的聪明伙伴。

Abstract

The combination of strong visual backbones and Large Language Model (LLM) reasoning has led to Large Multimodal Models (LMMs) becoming the current standard for a wide range of vision and language (VL) tasks. However, recent research has shown that even the most advanced LMMs still struggle to capture aspects of compositional visual reasoning, such as attributes and relationships between objects. One solution is to utilize scene graphs (SGs)--a formalization of objects and their relations and attributes that has been extensively used as a bridge between the visual and textual domains. Yet, scene graph data requires scene graph annotations, which are expensive to collect and thus not easily scalable. Moreover, finetuning an LMM based on SG data can lead to catastrophic forgetting of the pretraining objective. To overcome this, inspired by chain-of-thought methods, we propose Compositional Chain-of-Thought (CCoT), a novel zero-shot Chain-of-Thought prompting method that utilizes SG representations in order to extract compositional knowledge from an LMM. Specifically, we first generate an SG using the LMM, and then use that SG in the prompt to produce a response. Through extensive experiments, we find that the proposed CCoT approach not only improves LMM performance on several vision and language VL compositional benchmarks but also improves the performance of several popular LMMs on general multimodal benchmarks, without the need for fine-tuning or annotated ground-truth SGs. Code: https://github.com/chancharikmitra/CCoT

cs.CV cs.AI cs.CL cs.LG