SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2310.14566 · 2023

HallusionBench: An Advanced Diagnostic Suite for Entangled Language Hallucination and Visual Illusion in Large Vision-Language Models

arXiv · PDF · Open in the Atlas

Code that ran

4 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, 1 violated it and 2 have no contract verdict; 1 failure of our instrument; 4 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/2310.14566.json · badge: /api/ran/2310.14566.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
tianyi-lab/hallusionbench canonical (classifier label)
classifier basis: classifier_2025
1 ran · 0 no recorded run
zli12321/qa_metrics community (classifier label)
classifier basis not recorded on the link
2 ran · 4 no recorded run
wuxiyang1996/AutoHallusion extension (classifier label)
classifier basis: classifier_2025
1 ran · 0 no recorded run
FunctionStatusWhere it lives
f1_score_with_precision_recall_normalized Ran
ran on a synthesized input
zli12321/qa_metrics/qa_metrics/f1.py
code served (permissive licence) · get_code("8e34f912950b0c10")
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 dict. 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 re
from collections import defaultdict

def normalize_answer(s):
    """Lower text and remove punctuation, articles and extra whitespace."""
    def remove_articles(text):
        return re.sub(r'\b(a|an|the)\b', ' ', text)

    def white_space_fix(text):
        return ' '.join(text.split())

    def remove_punc(text):
        exclude = set('!"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~')
        return ''.join(ch for ch in text if ch not in exclude)

    def lower(text):
        return text.lower()

    return white_space_fix(remove_articles(remove_punc(lower(s))))

def lemmatize_text(text):
    """Simple lemmatization - just return the text as is for testing."""
    return text

ARGS = {
    'reference': 'The quick brown fox jumps over the lazy dog',
    'candidate': 'A quick brown fox jumps over a lazy dog'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict 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
generate_answer Ran
ran, violated the contract we drafted
tianyi-lab/hallusionbench/evaluation.py
code served (permissive licence) · get_code("c5e2fa32f54d0bba")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) and returned dict. 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 torch.nn as nn

torch.manual_seed(0)

# The function simply returns `data`, so we need to provide:
# 1. data - can be any value
# 2. model_output_entry - can be any value (not used in the function)

data = {
    'input_ids': torch.randint(0, 100, (2, 5)),
    'labels': torch.randint(0, 10, (2,)),
    'attention_mask': torch.ones(2, 5)
}

model_output_entry = {
    'logits': torch.randn(2, 10),
    'loss': torch.tensor(0.5)
}

ARGS = {
    'data': data,
    'model_output_entry': model_output_entry
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict 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
get_score Ran
ran on a synthesized input
zli12321/qa_metrics/qa_metrics/RewardBert.py
code served (permissive licence) · get_code("bb06d405aa0fd21d")
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 1, dtype family float; no output shape is stated. The image it ran in was not recorded. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is 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
import torch.nn as nn

torch.manual_seed(0)

# Build a minimal model that returns a scalar when called
class DummyModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 1)
    
    def forward(self, input_ids=None, attention_mask=None, token_type_ids=None, **kwargs):
        # Model expects tokenizer output dict unpacking
        # Just return a single scalar wrapped in an object with .cpu().item()
        batch_size = input_ids.shape[0] if input_ids is not None else 1
        output = self.linear(torch.randn(batch_size, 4))
        output = output.mean()  # Return scalar
        return output

# Build a minimal tokenizer that returns a dict with required keys
class DummyTokenizer:
    def __call__(self, text1, text2, return_tensors=None, padding=None, truncation=None, max_length=None):
        # Return dict with input_ids and attention_mask
        return {
            'input_ids': torch.tensor([[1, 2, 3, 4], [5, 6, 7, 8]], dtype=torch.long),
            'attention_mask': torch.tensor([[1, 1, 1, 1], [1, 1, 1, 0]], dtype=torch.long),
            'token_type_ids': torch.tensor([[0, 0, 0, 0], [0, 0, 0, 0]], dtype=torch.long)
        }

model = DummyModel()
tokenizer = DummyTokenizer()
reference = "This is a reference text"
generated_response = "This is a generated response"
device = torch.device('cpu')

ARGS = {
    'model': model,
    'tokenizer': tokenizer,
    'reference': reference,
    'generated_response': generated_response,
    'device': device,
    'max_length': 2048
}
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 1, 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
path_header_replace Ran
ran; our contract draft was wrong, not the code
wuxiyang1996/AutoHallusion/main_abnormal_obj_insertion.py
pointer only (licence: NONE) · get_code("1c0fbbfc151cff32")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, wuxiyang1996/AutoHallusion when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

em_match Not yet run
unverified (harvested, no recorded run)
zli12321/qa_metrics/qa_metrics/em.py
code served (permissive licence) · get_code("630c8505ee831159")
How it ran

no invocation recorded.

f1_score Not yet run
unverified (harvested, no recorded run)
zli12321/qa_metrics/qa_metrics/f1.py
code served (permissive licence) · get_code("032dc5fee649f52c")
How it ran

no invocation recorded.

f1_score_with_precision_recall Not yet run
unverified (harvested, no recorded run)
zli12321/qa_metrics/qa_metrics/f1.py
code served (permissive licence) · get_code("71a1ffe945841c01")
How it ran

no invocation recorded.

load_model_and_tokenizer_from_hub Not yet run
unverified (harvested, no recorded run)
zli12321/qa_metrics/qa_metrics/RewardBert.py
code served (permissive licence) · get_code("4aa1be5727c48a7d")
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, 1 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 1 later) and 7 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.

FunctionAlso present inEarliest-datedOthers named
generate_answer 1 other paper
1 later
Guan_HallusionBench_An_Advanced_Diagnostic_Suite_for_Entangled_Language_Hallucination_and_CVPR_2024_paper (2024 (year only))
HALLUSIONBENCH: An Advanced Diagnostic Suite for Entangled Language Hallucination and Visual Illusion in Large Vision-Language Models

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

We introduce HallusionBench, a comprehensive benchmark designed for the evaluation of image-context reasoning. This benchmark presents significant challenges to advanced large visual-language models (LVLMs), such as GPT-4V(Vision), Gemini Pro Vision, Claude 3, and LLaVA-1.5, by emphasizing nuanced understanding and interpretation of visual data. The benchmark comprises 346 images paired with 1129 questions, all meticulously crafted by human experts. We introduce a novel structure for these visual questions designed to establish control groups. This structure enables us to conduct a quantitative analysis of the models' response tendencies, logical consistency, and various failure modes. In our evaluation on HallusionBench, we benchmarked 15 different models, highlighting a 31.42% question-pair accuracy achieved by the state-of-the-art GPT-4V. Notably, all other evaluated models achieve accuracy below 16%. Moreover, our analysis not only highlights the observed failure modes, including language hallucination and visual illusion, but also deepens an understanding of these pitfalls. Our comprehensive case studies within HallusionBench shed light on the challenges of hallucination and illusion in LVLMs. Based on these insights, we suggest potential pathways for their future improvement. The benchmark and codebase can be accessed at https://github.com/tianyi-lab/HallusionBench.

For agents

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

get_harvested_code_for_paper("2310.14566")
get_code_for_paper("2310.14566")
have("2310.14566")

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

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

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

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

Connect an agent — have() is free.