# Pixel Echo Dataset & Benchmark Protocol

## 1. The simple idea

We maintain two separate experiments:

- **Mechanism:** put Real, RECON, and GEN side by side for the same decoder
  family. This tests where the observed structure appears.
- **Benchmark:** give detectors labelled training data, a validation set for
  threshold/model selection, and a private test set. This tests whether the
  structure is useful for detection and attribution.

The mechanism cohort is never reused to train a detector, choose a threshold,
or score the benchmark. A high correlation in the mechanism cohort is evidence
about the route that produced a pattern; a high test score is evidence about a
benchmark task. They are different estimands.

## 2. Mechanism cohorts

### 2.1 C2I-Mechanism-1K

The source cohort contains 1,000 ImageNet images with a recorded class
condition. For every decoder family that passes the asset gate we create:

| role | input relationship | purpose |
| --- | --- | --- |
| REAL | original ImageNet image | direct control |
| RECON | the same source image through the encoder and the exact decoder | tests decoder-conditioned reconstruction |
| GEN | C2I output with a class distribution matched to the source cohort | tests generation through the same decoder |

REAL and RECON are pixel/content paired. GEN is class-balanced and condition
matched, but it is not claimed to be pixel paired with REAL. Every row carries a
`condition_id`; the three roles are joined by `mechanism_group_id`, not by
assuming that their pixels are identical.

There is exactly one split called `mechanism`. We do not tune a classifier or
choose a detection threshold on this cohort.

### 2.2 T2I-Mechanism-1K

The source cohort contains 1,000 high-quality real image-text pairs. For every
decoder family with an exact, documented T2I route we create:

| role | input relationship | purpose |
| --- | --- | --- |
| REAL | original image and its prompt | direct control |
| RECON | the same image through the encoder and exact decoder | decoder route |
| GEN | generation from the same prompt | text-conditioned generation route |

REAL and RECON are pixel paired. GEN is prompt matched, not pixel paired. The
prompt is recorded for audit but is not a target label. As with C2I, the cohort
has no train/validation/test split and never enters benchmark fitting.

### 2.3 Exact decoder rule

`RECON` and `GEN` may be compared as a same-decoder pair only when they carry
the same `decoder_id`, `checkpoint_identity`, and documented decoder revision.
If a closed generator does not expose its decoder, its decoder fields remain
`unknown` and the sample can support a generator observation but not a shared-
decoder claim. A public VAE checkpoint is not automatically the decoder used by
a hosted generator.

Current examples from the read-only audit:

- AliTok + ORT is the existing complete C2I pair.
- SD VAE ft-MSE is a candidate public second family, but its local audit has
  RECON-only evidence and no authorized same-checkpoint GEN cohort.
- GPT Image 1 and Seedream 3.0 have GEN cohorts but no documented decoder/
  reconstruction pair.
- PixelDiT is a pixel-native control, not a latent-decoder family.

## 3. Detection benchmark

### 3.1 Cohort sizes and labels

For every registered generator/version, create 2,000 generated images:

| split | count | public role |
| --- | ---: | --- |
| train | 1,000 | labelled fitting only |
| validation | 500 | threshold and model-selection only |
| private_test | 500 | labels held by evaluator |

Create one separate 2,000-image real-control panel with the same split sizes.
The real panel is disjoint from both mechanism source cohorts. For pairwise
Real-vs-GEN reporting, the real panel is reused as a control but each generator
is macro-averaged so a larger generator roster cannot inflate the real class.

The public release may expose private-test pixels without labels, using opaque
sample IDs, or may keep the whole private test behind a hosted evaluator when
redistribution terms require it. In both cases, `generator_id`, `decoder_id`,
`is_generated`, `condition_id`, prompt/class, and seed are withheld from the
participant-facing test record.

The public builder output and evaluator-private labels are physically separate.
By default the builder emits no private ground-truth file; an explicit separate
`--private-output-dir` is required to write
`private_test_ground_truth.jsonl`. A public directory must never contain or
point its `index.jsonl` at evaluator-private labels.

### 3.2 Split and shortcut rules

- Assign every prompt, ImageNet class/source ID, or other condition to one
  global split before model outputs are assembled. The same condition may be
  rendered by multiple generators in the same split, never in different splits.
- Do not reuse a source image, prompt, class-condition instance, or generation
  request across splits. A seed is unique within a generator and split; when an
  API does not expose seeds, the acquisition record uses a unique request ID.
- Balance prompt families/classes and native aspect-ratio bins within each
  generator and split. Record the bin counts instead of assuming that a
  provider's default distribution is neutral.
- Record native raster dimensions, color mode, MIME type, export pipeline,
  metadata policy, and every post-delivery transformation.
- The primary detector track uses a common RGB PNG export transform after
  decoding. A secondary native track preserves the delivered raster. Results
  must name the track; native-vs-canonical differences are not silently merged.
- Do not use mechanism images, prompts, source IDs, or their derived templates
  for fitting, calibration, or test scoring.

### 3.3 Benchmark tasks

1. **Real-vs-Gen detection:** binary classification with train-fitted models
   and a validation-chosen threshold.
2. **Generator attribution:** closed-set attribution among the registered
   generator IDs; report only classes present in the split.
3. **Decoder attribution:** attribution among decoder IDs only after the roster
   contains at least two generator IDs for each decoder and at least two decoder
   IDs overall. Otherwise report the task as unavailable rather than guessing a
   decoder from a generator label.
4. **Open-set attribution (optional v2):** hold out an entire generator family
   and report unknown detection separately from closed-set attribution.

The benchmark is a controlled test of whether detector outputs carry generator-
and decoder-level information when those labels are known. Generators in the
roster do not all share a decoder; the labels record which do.

## 4. Metrics and reporting

Primary metrics are defined in `evaluation_protocol.json`:

- Real-vs-Gen: AUROC and balanced accuracy; report AUPRC and TPR at 1% and 0.1%
  FPR as secondary metrics.
- Generator attribution: top-1, macro-F1 and balanced accuracy, with a confusion
  matrix and per-generator recall.
- Decoder attribution: top-1, macro-F1 and balanced accuracy, with a confusion matrix
  and a per-decoder breakdown.

Thresholds and model checkpoints are selected on validation only. The private
test is evaluated once per submitted prediction file. We report bootstrap
intervals over images as conditional uncertainty, and separately report the
number of independent generators and decoder families. Thousands of images do
not become thousands of independent decoder families.

## 5. Submission interface

Participants submit one JSONL file with an opaque `sample_id` and task-specific
probabilities/labels. The evaluator checks that each required test ID appears
once, that probabilities are finite and in `[0, 1]`, and that attribution labels
belong to the declared roster. The submission format is drafted in
`schemas/submission.schema.json`; no predictions or labels are present in this
repository yet.

## 6. Release state and claim ceiling

This directory currently contains design documents and a read-only availability
matrix only. It does not contain a new collected mechanism dataset, a public
benchmark release, or classifier performance. Any future paper text must label
those as planned until the cohort manifests and evaluator outputs exist.

The current `canonical_png` implementation is metadata-only dry-run policy
recording. It does not decode, re-encode, resize, or pixel-validate assets.
