3a-vla's picture
Publish cleaned Game for Peace VLA dataset: 4 Hz actions and reason annotations
7fecba4 verified
|
Raw History Blame Contribute Delete
10.6 kB
---
pretty_name: Game for Peace VLA
language:
- zh
size_categories:
- 1M<n<10M
tags:
- game-for-peace
- game-playing
- vision-language-action
- imitation-learning
- instruction-following
- action-prediction
- reason-annotations
- 4hz
configs:
- config_name: peace_4hz
default: true
data_files:
- split: train
path: data/peace_4hz/train-*.parquet
- split: test
path: data/peace_4hz/test-*.parquet
---
# Game for Peace VLA
The primary Game for Peace dataset release from **3a-vla**, pairing a current
game image with a task instruction, the next keyboard/mouse action, and a short
local action description stored as `reason`.
**Repository:** `3a-vla/GameForPeace-VLA` · **Version:** `1.1.0` · **Configuration:** `peace_4hz`
This release packages the aligned game frames and instruction/action/reason
annotations from the 3a-vla SFT workflow, with image cleanup applied in v1.1.0. The five columns are `id`, `image`,
`instruction`, `action`, and `reason`. Segmentation targets and masks are outside
the scope of this release.
## Image cleanup in v1.1.0
This version removes detected cyan/blue enemy corner brackets from RGB images
and repairs distance-label regions where they can be localized. It follows the locally reviewed cleanup
examples. Bracket geometry, colour, and distance-label templates validate the
repair regions. Clipped frame-edge strokes receive an additional pass, and
nearby frames can confirm weak detections. RGB repair always uses the current
frame only.
Modified frames are stored as **lossless PNGs**. Every decoded pixel outside
the repair mask is verified identical to the source frame. Unmodified frames
retain their original JPEG bytes. Covered pixels are estimated from local
image context with OpenCV Telea inpainting; distance-label regions also use
horizontal context interpolation.
**103,505 of 2,522,808 distinct source frames were repaired.** Sample
IDs, instructions, actions, reasons, and train/test membership are unchanged.
The detector is heuristic; the checks do not establish that every possible
overlay was found. Aggregate checks and the preprocessing recipe are in
[`metadata/cleanup_validation.json`](metadata/cleanup_validation.json) and
[`preprocessing/`](preprocessing/).
This repository replaces the former `game_for_peace_vla_4hz_with_reason`
repository under a shorter name. The previous remote repository and its
history were removed at the owner's request; this repository contains the
cleaned release only. Local source archives were retained during replacement.
The related step-3000 model was trained on the earlier marked-image pipeline
and has not been retrained on this release. Its model card records fresh
predictions on the cleaned examples.
## At a glance
| Property | Value |
| --- | --- |
| Game | Game for Peace / 和平精英 |
| Observation | One current 320×224 RGB image |
| Action interval | 0.25 seconds / 4 Hz |
| Annotation language | Chinese |
| Train | 7,227,144 rows; 1,743 source recordings |
| Test | 1,200 rows; 274 source recordings |
| Distinct current-frame paths | 2,522,808 |
| Storage | Parquet with embedded JPEG / PNG bytes, about 53.69 GB |
| Files | 128 train shards and one test shard |
The train and test source recordings are disjoint. The fixed 1200-example test
set has also been used during development and model selection.
## Load the dataset
```bash
pip install "datasets==4.0.0" "pyarrow>=21" "pillow>=10"
```
If the repository is private, authenticate with `hf auth login` using an
account that has access.
```python
from datasets import load_dataset
train = load_dataset(
"3a-vla/GameForPeace-VLA",
name="peace_4hz",
split="train",
streaming=True,
)
train = train.shuffle(seed=42, buffer_size=10000)
sample = next(iter(train))
print(sample["instruction"])
print(sample["action"])
print(sample["reason"])
sample["image"].save("preview.png") # PIL image, already decoded
```
Rows sharing a current frame are grouped for efficient image dictionary storage.
Shuffle the training stream as above when constructing training batches. Full
instructions, actions, and reasons are retained for every sample.
Images are embedded in the Parquet shards. Image decoding requires no separate
archive extraction or access to paths on the dataset author's machine.
## Fields
| Column | Type | Meaning |
| --- | --- | --- |
| `id` | string | Original sample ID, normalized to a string. Unique across both splits. |
| `image` | Hugging Face `Image` | Current-frame RGB image; defaults to a PIL image when loaded. |
| `instruction` | string | Original overall task instruction. |
| `action.dx` | int32 | Original horizontal mouse delta for the next 0.25 seconds. |
| `action.dy` | int32 | Original vertical mouse delta for the next 0.25 seconds. |
| `action.keys` | list of strings | Controls held for that action interval. Empty list means no held controls. |
| `reason` | string | Original current-frame local instruction / short action description. |
Allowed controls, in canonical output order:
`w, a, s, d, c, z, f, space, tab, L, R`.
Mouse deltas retain the source integer units: no gain scaling, degree
conversion, clipping, averaging, or aggregation is applied.
The original local-instruction annotations are at **1 Hz** and are shared by
the corresponding four 0.25-second action substeps. The `reason` field stores
that annotation verbatim; its granularity differs from the action frequency.
All train reasons are nonempty. The test split retains its **17 empty reason
annotations** as empty strings.
The `Image` feature physically stores `{"bytes": ..., "path": ...}`. Its path
is an image content hash plus `.jpg` or `.png`; the image bytes are embedded. To inspect
bytes instead of decoding them:
```python
from datasets import Image
raw = train.cast_column("image", Image(decode=False))
image_bytes = next(iter(raw))["image"]["bytes"]
```
## Navigation and combat examples
These two examples are from the held-out test set. Their actions and reasons
are reference annotations. The JSON examples use repository-relative image
paths for readability; the actual Parquet rows embed the image bytes.
### Navigation
![Navigation current frame](examples/navigation.jpg)
```json
{
"id": "73107",
"image": "examples/navigation.jpg",
"instruction": "前进进入红砖房室内",
"action": {
"dx": 0,
"dy": 0,
"keys": [
"w"
]
},
"reason": "向前方红白建筑前进,保持对前方红白建筑的观察。"
}
```
### Combat
![Combat current frame](examples/combat.png)
```json
{
"id": "23727",
"image": "examples/combat.png",
"instruction": "射击敌人",
"action": {
"dx": -3,
"dy": 1,
"keys": [
"L"
]
},
"reason": "开火射击前方46米处的目标。"
}
```
## Optional SFT format
The structured columns can be adapted to different model families. For the
existing Qwen3.5 recipe, serialize the assistant target as:
```text
(dx,dy) key1 | key2 <think>current-frame local instruction</think>
```
Use `NONE` for an empty held-control list. The local description follows the
action. The chat template appends its native end-of-turn marker.
The full reference system prompt is:
```text
Follow the task instruction using the current game image. Predict the action to execute for the next 0.25 seconds. Output (dx,dy) followed by the held control tokens separated by |, then a space and <think>the local instruction for the current frame</think>. dx and dy are integers in the original annotation units. Use NONE when no controls are held. Allowed control tokens, in output order: w, a, s, d, c, z, f, space, tab, L, R. Output the action before the local instruction. Do not add an END marker.
```
[`scripts/format_samples.py`](scripts/format_samples.py) provides the system
prompt, action formatter, target formatter, and Alpaca record adapter.
[`metadata/training_format.json`](metadata/training_format.json) records the
complete formatting contract.
To export a small training subset for LLaMA-Factory, download this repository's
`scripts/` directory and run:
```bash
python scripts/export_alpaca.py --split train --limit 100 --output-dir gfp_train
```
Remove `--limit 100` for the full split. The exporter writes JSONL, image files, and a
`dataset_info.json` registry entry. It copies the embedded image bytes and
reuses images shared by multiple rows. Point LLaMA-Factory's `dataset_dir` and
`media_dir` to `gfp_train`; use `qwen3_5_nothink` for the reference template and
`train_on_prompt=false` to supervise the assistant response.
For action-only inference with that recipe, stop generation at `<think>`.
Training can still supervise the full action and postposed local description.
## Preparation and validation
- Preserved the existing fixed train/test assignment and all sample IDs.
- Parsed and round-trip-checked every original action/reason response.
- Verified the original annotation-shard checksums during export.
- Preserved instruction text, action integers, control sets, and reason text.
- Checked every distinct embedded image's format, dimensions, and RGB mode.
- Repaired detected enemy overlays; preserved every decoded pixel outside repair masks.
- Preserved original bytes for unmodified JPEGs; saved repaired frames as lossless PNGs.
- Verified sample-ID uniqueness and zero recording overlap between splits.
- Grouped shared frames for Parquet compression; training row order changes.
Counts, schema, source annotation hashes, and shard checksums are provided in
[`metadata/release.json`](metadata/release.json) and `SHA256SUMS`.
## Provenance and related model
This release derives from the existing 3a-vla Game for Peace single-frame,
single-action 4 Hz conversion. Original image-corpus provenance identifies
[`theend1234/long_events_peace_600_320x224_jpg_0930`](https://huggingface.co/datasets/theend1234/long_events_peace_600_320x224_jpg_0930).
Source annotation file checksums are recorded in the release metadata.
The related [GP action/think/seg model](https://huggingface.co/3a-vla/qwen3.5-4b-sft-gp-action-think-seg-step3000)
uses the same base image/instruction/action/local-description records plus
additional segmentation supervision. That auxiliary supervision is a separate
training extension.
## License
This release does not currently specify a dataset reuse license.
## Citation
```bibtex
@dataset{three_a_vla_game_for_peace_2026,
author = {{3a-vla}},
title = {Game for Peace VLA},
year = {2026},
version = {1.1.0},
url = {https://huggingface.co/datasets/3a-vla/GameForPeace-VLA}
}
```