Datasets:
Tasks:
Image-to-Image
Modalities:
Text
Formats:
json
Languages:
English
Size:
10K - 100K
Tags:
visual-abstention
abstention
refusal
image-editing
unified-multimodal-models
multimodal-reasoning
License:
Restyle the dataset card and add the logo and overview figure
Browse files- README.md +61 -47
- assets/logo.png +3 -0
- assets/overview.png +3 -0
README.md
CHANGED
|
@@ -47,13 +47,15 @@ configs:
|
|
| 47 |
- split: train
|
| 48 |
path: maze/instruction.jsonl
|
| 49 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
| 50 |
|
| 51 |
-
|
|
|
|
| 52 |
|
| 53 |
-
|
| 54 |
-
training method of the paper *Visual Abstention in Unified Multimodal Models*
|
| 55 |
-
([arXiv:<ARXIV_ID>](https://arxiv.org/abs/<ARXIV_ID>), code: https://github.com/visual-abstention/visual-abstention).
|
| 56 |
-
The evaluation benchmark is [Draw-or-Decline](https://huggingface.co/datasets/visual-abstention/Draw-or-Decline).
|
| 57 |
|
| 58 |
Every example is a request (input image + instruction) with a target response. The data comes in feasible–infeasible
|
| 59 |
pairs, so a model learns to judge feasibility before it decides whether to draw:
|
|
@@ -62,7 +64,11 @@ pairs, so a model learns to judge feasibility before it decides whether to draw:
|
|
| 62 |
* **infeasible**: a reasoning block that explains which requirement cannot be met and ends with the plain-text marker
|
| 63 |
`[ABSTAIN]` (`<think>... [ABSTAIN]</think>`), with no target image.
|
| 64 |
|
| 65 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 66 |
|
| 67 |
38,224 pairs, 76,448 examples, one split (`train`). Every pair that passed the checks is kept, so the categories are not
|
| 68 |
balanced.
|
|
@@ -80,7 +86,7 @@ balanced.
|
|
| 80 |
|
| 81 |
Maze grids are 7×7 (446 pairs), 9×9 (2,503) or 11×11 (2,251), counting the outer wall. There are 114,672 PNG images.
|
| 82 |
|
| 83 |
-
##
|
| 84 |
|
| 85 |
* **Real-world categories (33,024 pairs).** Each feasible example keeps its
|
| 86 |
[UniREdit-Data-100K](https://huggingface.co/datasets/maplebb/UniREdit-Data-100K) instruction, chain of thought, input
|
|
@@ -100,7 +106,17 @@ Maze grids are 7×7 (446 pairs), 9×9 (2,503) or 11×11 (2,251), counting the ou
|
|
| 100 |
|
| 101 |
See Sec. 5.2 and Appx. C of the paper for details.
|
| 102 |
|
| 103 |
-
##
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 104 |
|
| 105 |
```
|
| 106 |
<category>/instruction.jsonl requests, one folder per category (7 folders)
|
|
@@ -115,7 +131,29 @@ Extract all shards into **one** directory (the dataset root) to recreate `image/
|
|
| 115 |
`<category>-<id>-target.png`. Maze pairs use `matched-maze-<nnnnn>-A.png` (feasible), `-B.png` (infeasible) and
|
| 116 |
`-target.png` (solved feasible map).
|
| 117 |
|
| 118 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 119 |
|
| 120 |
### `instruction.jsonl`
|
| 121 |
|
|
@@ -148,31 +186,7 @@ Extract all shards into **one** directory (the dataset root) to recreate `image/
|
|
| 148 |
| `source` | provenance. Real-world: `dataset` (`maplebb/UniREdit-Data-100K`), `revision` (dataset commit), `category`, `id`, `original_image_path`, `edited_image_path` in that dataset, and `synthetic_input` (`false`) on infeasible examples. Maze: `dataset`, `category`, `category_en`, `id`, `origin`, `official_image` (`false`), `seed`, `instruction_origin`, `matched_pair`, `difference` |
|
| 149 |
| `program_verification` | maze only: BFS verification record (0-based `[row, column]` including the outer wall): start, end, the changed cell, the unique feasible path, the reachable sets of both endpoints on the infeasible map, distances of the cut from both endpoints, and pixel-difference checks |
|
| 150 |
|
| 151 |
-
##
|
| 152 |
-
|
| 153 |
-
```python
|
| 154 |
-
import json, tarfile
|
| 155 |
-
from pathlib import Path
|
| 156 |
-
from huggingface_hub import snapshot_download
|
| 157 |
-
from PIL import Image
|
| 158 |
-
|
| 159 |
-
root = Path(snapshot_download("visual-abstention/VisTA-Train", repo_type="dataset"))
|
| 160 |
-
for shard in sorted((root / "images").glob("*.tar")): # recreates root/image/...
|
| 161 |
-
with tarfile.open(shard) as tar:
|
| 162 |
-
tar.extractall(root, filter="data")
|
| 163 |
-
|
| 164 |
-
category = "maze"
|
| 165 |
-
requests = [json.loads(l) for l in open(root / category / "instruction.jsonl")]
|
| 166 |
-
targets = {r["case_id"]: r for r in map(json.loads, open(root / category / "ground_truth_criteria.jsonl"))}
|
| 167 |
-
|
| 168 |
-
req = requests[0]
|
| 169 |
-
tgt = targets[req["case_id"]]
|
| 170 |
-
image = Image.open(root / req["input_image"])
|
| 171 |
-
output = tgt["training_output_image"] and Image.open(root / tgt["training_output_image"])
|
| 172 |
-
print(req["prompt_en"], tgt["training_response"])
|
| 173 |
-
```
|
| 174 |
-
|
| 175 |
-
## Training recipe used in the paper
|
| 176 |
|
| 177 |
VisTA-BAGEL starts from the official UniREdit-BAGEL weights and is trained on all 76,448 examples for 16,384 steps
|
| 178 |
(learning rate 2e-6, 8 examples per step: 4 feasible and 4 infeasible, the two examples of a pair in the same step).
|
|
@@ -183,7 +197,7 @@ appended at training time; the reminder is not stored in `prompt_en`. The full r
|
|
| 183 |
paper (Appx. C) and the [code repository](https://github.com/visual-abstention/visual-abstention). Model weights are not
|
| 184 |
part of this release.
|
| 185 |
|
| 186 |
-
## Evaluation
|
| 187 |
|
| 188 |
This dataset is for training only. Evaluate on
|
| 189 |
[Draw-or-Decline](https://huggingface.co/datasets/visual-abstention/Draw-or-Decline), whose images and mazes do not
|
|
@@ -194,18 +208,7 @@ passages of feasible examples, were written partly in Chinese and machine-transl
|
|
| 194 |
release. All other text, including almost all `training_response` fields, is unchanged. The paper's model was trained
|
| 195 |
on the original `training_response` texts; `ground_truth.reason` is not part of the training target.
|
| 196 |
|
| 197 |
-
##
|
| 198 |
-
|
| 199 |
-
The new annotations (infeasible instructions, infeasible reasoning, maze maps, maze reasoning, explanations and
|
| 200 |
-
verification records) are released under the **Apache License 2.0**.
|
| 201 |
-
|
| 202 |
-
The real-world input images, target images, feasible instructions and feasible chains of thought come from
|
| 203 |
-
**UniREdit-Data-100K** ([maplebb/UniREdit-Data-100K](https://huggingface.co/datasets/maplebb/UniREdit-Data-100K),
|
| 204 |
-
Apache-2.0) and are unchanged, except that Chinese passages in 4 feasible chains of thought were translated to English;
|
| 205 |
-
`source.revision` records the dataset commit. Please cite it as well. The maze images are generated by the
|
| 206 |
-
authors.
|
| 207 |
-
|
| 208 |
-
## Citation
|
| 209 |
|
| 210 |
```bibtex
|
| 211 |
@article{shi2026visual,
|
|
@@ -224,6 +227,17 @@ authors.
|
|
| 224 |
}
|
| 225 |
```
|
| 226 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 227 |
## Limitations
|
| 228 |
|
| 229 |
* Infeasible instructions and their reasoning were written by models and checked by models; only a 300-pair sample was
|
|
|
|
| 47 |
- split: train
|
| 48 |
path: maze/instruction.jsonl
|
| 49 |
---
|
| 50 |
+
<div align="center">
|
| 51 |
+
<img src="./assets/logo.png" width="128" alt="Visual Abstention logo">
|
| 52 |
+
<h1> VisTA-Train </h1>
|
| 53 |
+
</div>
|
| 54 |
|
| 55 |
+
This is the official training-data repository of [Visual Abstention in Unified Multimodal Models](https://github.com/visual-abstention/visual-abstention). **VisTA-Train** holds the paired feasible and infeasible examples used to train **VisTA-BAGEL**.
|
| 56 |
+
🌐 [Website](https://visual-abstention.github.io) · 💻 [Code](https://github.com/visual-abstention/visual-abstention) · 📃 [Paper](<ARXIV_LINK>)
|
| 57 |
|
| 58 |
+
## 1. Data Overview
|
|
|
|
|
|
|
|
|
|
| 59 |
|
| 60 |
Every example is a request (input image + instruction) with a target response. The data comes in feasible–infeasible
|
| 61 |
pairs, so a model learns to judge feasibility before it decides whether to draw:
|
|
|
|
| 64 |
* **infeasible**: a reasoning block that explains which requirement cannot be met and ends with the plain-text marker
|
| 65 |
`[ABSTAIN]` (`<think>... [ABSTAIN]</think>`), with no target image.
|
| 66 |
|
| 67 |
+
<div align="center">
|
| 68 |
+
<img src="./assets/overview.png" width="100%" alt="Visual abstention in a maze task: draw a path when one exists, decline when none exists">
|
| 69 |
+
</div>
|
| 70 |
+
|
| 71 |
+
## 2. Data Statistics
|
| 72 |
|
| 73 |
38,224 pairs, 76,448 examples, one split (`train`). Every pair that passed the checks is kept, so the categories are not
|
| 74 |
balanced.
|
|
|
|
| 86 |
|
| 87 |
Maze grids are 7×7 (446 pairs), 9×9 (2,503) or 11×11 (2,251), counting the outer wall. There are 114,672 PNG images.
|
| 88 |
|
| 89 |
+
## 3. Construction
|
| 90 |
|
| 91 |
* **Real-world categories (33,024 pairs).** Each feasible example keeps its
|
| 92 |
[UniREdit-Data-100K](https://huggingface.co/datasets/maplebb/UniREdit-Data-100K) instruction, chain of thought, input
|
|
|
|
| 106 |
|
| 107 |
See Sec. 5.2 and Appx. C of the paper for details.
|
| 108 |
|
| 109 |
+
## 4. Download Link
|
| 110 |
+
|
| 111 |
+
Download the whole dataset into the `data/train` folder of the [code repository](https://github.com/visual-abstention/visual-abstention), which is where the code reads it:
|
| 112 |
+
|
| 113 |
+
```shell
|
| 114 |
+
cd visual-abstention # the root of the code repository
|
| 115 |
+
python data/download.py train # downloads and extracts the image shards into data/train/image/
|
| 116 |
+
# or: huggingface-cli download visual-abstention/VisTA-Train --repo-type dataset --local-dir data/train
|
| 117 |
+
```
|
| 118 |
+
|
| 119 |
+
Layout:
|
| 120 |
|
| 121 |
```
|
| 122 |
<category>/instruction.jsonl requests, one folder per category (7 folders)
|
|
|
|
| 131 |
`<category>-<id>-target.png`. Maze pairs use `matched-maze-<nnnnn>-A.png` (feasible), `-B.png` (infeasible) and
|
| 132 |
`-target.png` (solved feasible map).
|
| 133 |
|
| 134 |
+
```python
|
| 135 |
+
import json, tarfile
|
| 136 |
+
from pathlib import Path
|
| 137 |
+
from huggingface_hub import snapshot_download
|
| 138 |
+
from PIL import Image
|
| 139 |
+
|
| 140 |
+
root = Path(snapshot_download("visual-abstention/VisTA-Train", repo_type="dataset"))
|
| 141 |
+
for shard in sorted((root / "images").glob("*.tar")): # recreates root/image/...
|
| 142 |
+
with tarfile.open(shard) as tar:
|
| 143 |
+
tar.extractall(root, filter="data")
|
| 144 |
+
|
| 145 |
+
category = "maze"
|
| 146 |
+
requests = [json.loads(l) for l in open(root / category / "instruction.jsonl")]
|
| 147 |
+
targets = {r["case_id"]: r for r in map(json.loads, open(root / category / "ground_truth_criteria.jsonl"))}
|
| 148 |
+
|
| 149 |
+
req = requests[0]
|
| 150 |
+
tgt = targets[req["case_id"]]
|
| 151 |
+
image = Image.open(root / req["input_image"])
|
| 152 |
+
output = tgt["training_output_image"] and Image.open(root / tgt["training_output_image"])
|
| 153 |
+
print(req["prompt_en"], tgt["training_response"])
|
| 154 |
+
```
|
| 155 |
+
|
| 156 |
+
## 5. Data Fields
|
| 157 |
|
| 158 |
### `instruction.jsonl`
|
| 159 |
|
|
|
|
| 186 |
| `source` | provenance. Real-world: `dataset` (`maplebb/UniREdit-Data-100K`), `revision` (dataset commit), `category`, `id`, `original_image_path`, `edited_image_path` in that dataset, and `synthetic_input` (`false`) on infeasible examples. Maze: `dataset`, `category`, `category_en`, `id`, `origin`, `official_image` (`false`), `seed`, `instruction_origin`, `matched_pair`, `difference` |
|
| 187 |
| `program_verification` | maze only: BFS verification record (0-based `[row, column]` including the outer wall): start, end, the changed cell, the unique feasible path, the reachable sets of both endpoints on the infeasible map, distances of the cut from both endpoints, and pixel-difference checks |
|
| 188 |
|
| 189 |
+
## 6. Training Recipe
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 190 |
|
| 191 |
VisTA-BAGEL starts from the official UniREdit-BAGEL weights and is trained on all 76,448 examples for 16,384 steps
|
| 192 |
(learning rate 2e-6, 8 examples per step: 4 feasible and 4 infeasible, the two examples of a pair in the same step).
|
|
|
|
| 197 |
paper (Appx. C) and the [code repository](https://github.com/visual-abstention/visual-abstention). Model weights are not
|
| 198 |
part of this release.
|
| 199 |
|
| 200 |
+
## 7. Evaluation
|
| 201 |
|
| 202 |
This dataset is for training only. Evaluate on
|
| 203 |
[Draw-or-Decline](https://huggingface.co/datasets/visual-abstention/Draw-or-Decline), whose images and mazes do not
|
|
|
|
| 208 |
release. All other text, including almost all `training_response` fields, is unchanged. The paper's model was trained
|
| 209 |
on the original `training_response` texts; `ground_truth.reason` is not part of the training target.
|
| 210 |
|
| 211 |
+
## 8. Citation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 212 |
|
| 213 |
```bibtex
|
| 214 |
@article{shi2026visual,
|
|
|
|
| 227 |
}
|
| 228 |
```
|
| 229 |
|
| 230 |
+
## License
|
| 231 |
+
|
| 232 |
+
The new annotations (infeasible instructions, infeasible reasoning, maze maps, maze reasoning, explanations and
|
| 233 |
+
verification records) are released under the **Apache License 2.0**.
|
| 234 |
+
|
| 235 |
+
The real-world input images, target images, feasible instructions and feasible chains of thought come from
|
| 236 |
+
**UniREdit-Data-100K** ([maplebb/UniREdit-Data-100K](https://huggingface.co/datasets/maplebb/UniREdit-Data-100K),
|
| 237 |
+
Apache-2.0) and are unchanged, except that Chinese passages in 4 feasible chains of thought were translated to English;
|
| 238 |
+
`source.revision` records the dataset commit. Please cite it as well. The maze images are generated by the
|
| 239 |
+
authors.
|
| 240 |
+
|
| 241 |
## Limitations
|
| 242 |
|
| 243 |
* Infeasible instructions and their reasoning were written by models and checked by models; only a 300-pair sample was
|
assets/logo.png
ADDED
|
Git LFS Details
|
assets/overview.png
ADDED
|
Git LFS Details
|