File size: 4,324 Bytes
82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 c0e50c4 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 82ae169 7b1e578 dfb3879 7b1e578 c0e50c4 7b1e578 c0e50c4 7b1e578 82ae169 7b1e578 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 | ---
license: apache-2.0
task_categories:
- image-to-text
- visual-question-answering
language:
- en
size_categories:
- n<1K
tags:
- benchmark
- reflection
- rectification
- text-to-image
- visual-reasoning
- image-editing
pretty_name: R3-Bench
---
# R3-Bench: Reason-Reflect-Rectify Benchmark
**Code**: [github.com/xiaomoguhz/R3-Bench](https://github.com/xiaomoguhz/R3-Bench)
**Paper**: *Benchmarking and Evolving Reason-Reflect-Rectify for Reflective Visual Generation* — accepted to ICML 2026.
R³-Bench evaluates **reflective visual generation**: given a generated image and the original prompt, a model must (i) reason about whether the image matches the prompt, (ii) explain any discrepancy, and (iii) propose a rectification action. The benchmark measures two complementary scores:
- **S_ref** — Reflective Verdict Score (verdict + explanation correctness, judged by an LLM)
- **S_rect** — Rectification Score (normalised VQA-alignment gain after applying the proposed edit)
## Contents
| File | Description |
|---|---|
| `images.tar.gz` | 670 source images (PNG, ~717 MB), organised as `images/{category}/{verdict}/r3b_{idx:06d}.png` |
The 670-sample **prompt + ground-truth JSONL** ships with the code repository at [`r3bench/data/r3bench.jsonl`](https://github.com/xiaomoguhz/R3-Bench/blob/main/r3bench/data/r3bench.jsonl) — labels travel with the eval code so version drift is captured by git.
## Schema
Each JSONL record:
```json
{
"idx": 0,
"original_prompt": "a black candle and a white holder",
"bad_image": "images/color/false/r3b_000000.png",
"answer": false,
"explanation": "The white object is a candle, not a holder as specified in the prompt.",
"category": "color",
"generated_qa": {
"yn_question_list": ["Is there a candle in the image?", "..."]
}
}
```
| Field | Type | Description |
|---|---|---|
| `idx` | int | Unique sample id (0–669) |
| `original_prompt` | str | The text-to-image prompt |
| `bad_image` | str | Image path relative to the data root |
| `answer` | bool | Ground-truth verdict: does the image match the prompt? (`false` = mismatch) |
| `explanation` | str | Ground-truth discrepancy description (used as S_ref reference) |
| `category` | str | Error dimension: color · object · numeracy · spatial · shape · texture · complex · non |
| `generated_qa.yn_question_list` | list[str] | Yes/no VQA probes used by the S_rect rectification scorer |
## Category & verdict distribution (670 total)
| Category | false (mismatch) | true (match) | Total |
|---|---:|---:|---:|
| color | 71 | 26 | 97 |
| complex | 46 | 48 | 94 |
| non | 7 | 42 | 49 |
| numeracy | 73 | 23 | 96 |
| object | 54 | 17 | 71 |
| shape | 72 | 20 | 92 |
| spatial | 76 | 25 | 101 |
| texture | 49 | 21 | 70 |
| **Sum** | **448** | **222** | **670** |
`non` = "no error" probe samples (image matches prompt) used to calibrate false-positive reflection.
## Usage
```bash
# 1. Download images
hf download xiaomoguhzz/R3-Bench-data images.tar.gz \
--repo-type dataset --local-dir /path/to/r3bench-data
cd /path/to/r3bench-data && tar -xzf images.tar.gz
# → /path/to/r3bench-data/images/{category}/{true,false}/r3b_{idx:06d}.png
# 2. Run the 4-step pipeline (clone the code repo first)
git clone https://github.com/xiaomoguhz/R3-Bench && cd R3-Bench
export R3BENCH_DATA_DIR=/path/to/r3bench-data
bash scripts/run_reflection.sh 8 qwen2.5vl # Step 1 — reflection
bash scripts/run_edit.sh 8 qwen2.5vl qwen_image_2511 # Step 2 — editing
bash scripts/eval_reflection.sh qwen2.5vl # Step 3 — S_ref
bash scripts/eval_edit.sh qwen2.5vl qwen_image_2511 # Step 4 — S_rect
```
See the [code repo README](https://github.com/xiaomoguhz/R3-Bench) for full pipeline details, supported backends, and how to plug in a custom reflection / editor model.
## Citation
```bibtex
@inproceedings{r3bench2026,
title={Benchmarking and Evolving Reason-Reflect-Rectify for Reflective Visual Generation},
booktitle={Proceedings of the International Conference on Machine Learning (ICML)},
year={2026}
}
```
## License
Released under the **Apache 2.0** license. Source prompts adapted from T2I-CompBench, GenEval++, and GEdit-Bench under their respective licenses; see the code repository for full attribution.
|