SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2303.06594 · 2023

ChatGPT Asks, BLIP-2 Answers: Automatic Questioning Towards Enriched Visual Descriptions

arXiv · PDF · Open in the Atlas

Code that ran

6 of 8 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 6 have no contract verdict; 0 failures of our instrument; 2 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2303.06594.json · badge: /api/ran/2303.06594.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
vision-cair/chatcaptioner canonical (classifier label)
classifier basis not recorded on the link
6 ran · 2 no recorded run
FunctionStatusWhere it lives
extractQA_chatgpt Ran
ran on a synthesized input
vision-cair/chatcaptioner/ChatCaptioner/chatcaptioner/utils.py
code served (permissive licence) · get_code("702fa84151b5eac3")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

# Analyze the function: extractQA_chatgpt expects messages parameter
# which is iterated over, and each message has a 'content' key
# The function splits on 'Question: ' and 'Answer: ' strings

messages = [
    {
        'content': 'This is a Question: What is the capital of France?'
    },
    {
        'content': 'This is an Answer: The capital of France is Paris.'
    },
    {
        'content': 'Another question here. Question: What is 2+2?'
    },
    {
        'content': 'Response text. Answer: 2+2 equals 4.'
    }
]

ARGS = {
    'messages': messages
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_chat_log Ran
ran on a synthesized input
vision-cair/chatcaptioner/ChatCaptioner/chatcaptioner/chat.py
code served (permissive licence) · get_code("3a81be973bbda18d")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# Analyze the function:
# - questions: list of strings, accessed by index and len()
# - answers: list of strings, accessed by index and len()
# - last_n: int, default -1
# The function builds a chat log by combining questions and answers

# Create test data
questions = [
    "What is AI?",
    "How does machine learning work?",
    "What is a neural network?"
]

answers = [
    "AI is artificial intelligence.",
    "ML learns from data."
]

# Note: len(questions) - len(answers) = 3 - 2 = 1, which satisfies the assertion n_addition_q in [0, 1]

ARGS = {
    "questions": questions,
    "answers": answers,
    "last_n": -1
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
prepare_gpt_prompt Ran
ran on a synthesized input
vision-cair/chatcaptioner/ChatCaptioner/chatcaptioner/chat.py
code served (permissive licence) · get_code("093157191761d926")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

# Examine the function to understand what it needs:
# prepare_gpt_prompt takes:
#   - task_prompt: string
#   - questions: list of strings (used in get_chat_log)
#   - answers: list of strings (used in get_chat_log)
#   - sub_prompt: string
#
# The function joins these with newlines and calls get_chat_log on questions/answers
# get_chat_log expects:
#   - questions: list (len checked against answers, indexed)
#   - answers: list (len checked against questions, indexed)
#   - last_n: defaults to -1 (optional parameter)

task_prompt = "You are a helpful assistant. Answer the following questions."

questions = [
    "What is the capital of France?",
    "What is 2 + 2?"
]

answers = [
    "The capital of France is Paris.",
    "2 + 2 equals 4."
]

sub_prompt = "Please provide a concise answer to the next question:"

ARGS = {
    "task_prompt": task_prompt,
    "questions": questions,
    "answers": answers,
    "sub_prompt": sub_prompt,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
read_video_per_interval Ran
ran on a synthesized input
vision-cair/chatcaptioner/Video_ChatCaptioner/chatcaptioner/video_reader.py
code served (permissive licence) · get_code("a2ff5ebefe84504d")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 4, dtype family int, shape (10, 480, 640, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import cv2
import numpy as np
import tempfile
import os

# Create a temporary video file for testing
def create_test_video(filename, duration=2, fps=30, width=640, height=480):
    """Create a simple test video file."""
    fourcc = cv2.VideoWriter_fourcc(*'mp4v')
    out = cv2.VideoWriter(filename, fourcc, fps, (width, height))
    
    # Write frames with simple pattern
    num_frames = int(duration * fps)
    for i in range(num_frames):
        # Create a simple frame with changing color
        frame = np.zeros((height, width, 3), dtype=np.uint8)
        frame[:, :, 0] = (i * 10) % 256  # Blue channel varies
        frame[:, :, 1] = (i * 5) % 256   # Green channel varies
        frame[:, :, 2] = 100             # Red channel constant
        out.write(frame)
    
    out.release()

# Create temporary video file
temp_dir = tempfile.gettempdir()
video_path = os.path.join(temp_dir, 'test_video_temp.mp4')
create_test_video(video_path, duration=2, fps=30)

# Define arguments for read_video_per_interval
ARGS = {
    'path': video_path,
    'start_time': 0.0,
    'end_time': 1.0,
    'sample_interval': 0.1
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 4, dtype family int, shape (10, 480, 640, 3) — shape (10, 480, 640, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
read_video_per_interval_sampling Ran
ran on a synthesized input
vision-cair/chatcaptioner/Video_ChatCaptioner/chatcaptioner/video_reader.py
code served (permissive licence) · get_code("e347d0198c079f14")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 4, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import cv2
import numpy as np
import tempfile
import os

# Create a minimal test video file
def create_test_video(path, duration=2, fps=30, width=320, height=240):
    """Create a simple test video file"""
    fourcc = cv2.VideoWriter_fourcc(*'mp4v')
    out = cv2.VideoWriter(path, fourcc, fps, (width, height))
    
    num_frames = int(duration * fps)
    for i in range(num_frames):
        # Create a simple frame with changing color
        frame = np.zeros((height, width, 3), dtype=np.uint8)
        frame[:, :, 0] = (i * 10) % 256  # Blue channel
        frame[:, :, 1] = (i * 5) % 256   # Green channel
        frame[:, :, 2] = (i * 15) % 256  # Red channel
        out.write(frame)
    
    out.release()

# Create temporary video file
temp_dir = tempfile.gettempdir()
video_path = os.path.join(temp_dir, "test_video.mp4")
create_test_video(video_path, duration=2, fps=30)

ARGS = {
    "path": video_path,
    "start_time": 0.5,
    "end_time": 1.5,
    "num_frames": 3,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 4, dtype family int — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
read_video_with_timestamp Ran
ran on a synthesized input
vision-cair/chatcaptioner/Video_ChatCaptioner/chatcaptioner/video_reader.py
code served (permissive licence) · get_code("ef56fa6c78431650")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import cv2
import numpy as np
from PIL import Image
import tempfile
import os

# Create a minimal test video file
def create_test_video(path, duration_seconds=5, fps=30, width=320, height=240):
    """Create a simple test video file."""
    fourcc = cv2.VideoWriter_fourcc(*'mp4v')
    out = cv2.VideoWriter(path, fourcc, fps, (width, height))
    
    num_frames = int(duration_seconds * fps)
    for i in range(num_frames):
        # Create a simple frame with changing color
        frame = np.zeros((height, width, 3), dtype=np.uint8)
        frame[:, :] = [i % 256, (i * 2) % 256, (i * 3) % 256]
        out.write(frame)
    
    out.release()

# Create temporary video file
temp_dir = tempfile.gettempdir()
video_path = os.path.join(temp_dir, "test_video.mp4")
create_test_video(video_path, duration_seconds=5, fps=30)

# Build the video_annotation dict with proper structure
video_annotation = {
    'video_path': video_path,
    'annotation': {
        'timestamps': [
            [0.5, 2.0],    # 1.5 seconds - triggers num_frames=5
            [2.5, 7.0],    # 4.5 seconds - triggers num_frames=8
            [8.0, 20.0],   # 12 seconds - triggers num_frames=10
        ]
    }
}

ARGS = {
    'video_anntotation': video_annotation,
    'num_frames': 10
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list — a list output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
call_gpt3 Not yet run
unverified (harvested, no recorded run)
vision-cair/chatcaptioner/ChatCaptioner/chatcaptioner/chat.py
code served (permissive licence) · get_code("a32dbed245beda14")
How it ran

no invocation recorded.

prepare_gpt_promot_video Not yet run
unverified (harvested, no recorded run)
vision-cair/chatcaptioner/Video_ChatCaptioner/chatcaptioner/video_chat.py
code served (permissive licence) · get_code("82a105456cd33a34")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 8 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Asking insightful questions is crucial for acquiring knowledge and expanding our understanding of the world. However, the importance of questioning has been largely overlooked in AI research, where models have been primarily developed to answer questions. With the recent advancements of large language models (LLMs) like ChatGPT, we discover their capability to ask high-quality questions when provided with a suitable prompt. This discovery presents a new opportunity to develop an automatic questioning system. In this paper, we introduce ChatCaptioner, a novel automatic-questioning method deployed in image captioning. Here, ChatGPT is prompted to ask a series of informative questions about images to BLIP-2, a strong vision question-answering model. By keeping acquiring new visual information from BLIP-2's answers, ChatCaptioner is able to generate more enriched image descriptions. We conduct human-subject evaluations on common image caption datasets such as COCO, Conceptual Caption, and WikiArt, and compare ChatCaptioner with BLIP-2 as well as ground truth. Our results demonstrate that ChatCaptioner's captions are significantly more informative, receiving three times as many votes from human evaluators for providing the most image information. Besides, ChatCaptioner identifies 53% more objects within the image than BLIP-2 alone measured by WordNet synset matching. Code is available at https://github.com/Vision-CAIR/ChatCaptioner

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2303.06594")
get_code_for_paper("2303.06594")
have("2303.06594")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2303.06594.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2303.06594.svg)](https://syntology.ai/paper/2303.06594)

Connect an agent — have() is free.