### `wai.media.upscale`: super-resolution as an exact derivation, residuals against it, and an account of sink-made pictures

- **The extension** ([exact-upscale](extensions/exact-upscale.md)) registers the record
  `wai.media.upscale` and two integer derivations, `wai-upscale:sr2` and `wai-upscale:sr4`: the
  pinned upscale of integer-operators §5E E11 plus a detail an integer network computes from the
  picture, clamped to the sample range. The network is a `WSR1` prior (§3.1), one file a sink
  holds by its SHA-256 under SPEC §3.1: up to eight convolutions of signed-byte weights, each with
  a per-channel multiplier, a shift and `half_up` rounding, the hidden ones clamped, the last one's
  twelve channels shuffled to the two sub-positions of each colour. Colour is `RGB8`, the channels
  together; the base repeats the last row and column, and the network reads mid-grey outside the
  picture; `sr4` is `sr2` twice under one prior.
- **Through the integer operator set.** The lowering `sr2/1` (§3.4; integer-operators §13.7)
  writes one `WHG1` graph of `rescale`, `conv`, `clamp`, `pixel_shuffle` and `add`, which loads under
  `acc64` with its bounds certificate, and under `acc32` where the certificate meets it: every
  operator is in `wai-ops/1-i32`, and the GPU path runs it. Every sink presents the same bytes,
  so the high-resolution picture is a function of the transmitted bytes and the prior.
- **Residual against the known upscale.** An origin can send a `WIR1` payload of staged-delivery
  Appendix A with the identity predictor, decoded over the upscaled picture, and sign an
  **upscale record** (`wai-upscale`, §4.2) stating the input, the prior, the upscale, the output
  and the target with the bound within which the output lies: 0 for the target itself, ⌊q/2⌋ for
  a residual of step q.
- **Per-title priors** (§5): a prior fine-tuned on one title, carried by digest like any other,
  and sent only where the bytes it saves exceed its own. `tools/wai_int_sr_train.py` trains priors
  in floating point from fixed seeds and quantises them to `WSR1`; its training is not claimed to
  regenerate the same bytes on another machine, and the priors' bytes are what is pinned.
  `wai_upscale_measure` codes the full-resolution picture directly with `WIV1`, through staged
  delivery's up2 layer, and through the derivation and a residual, at matched quality (every
  sample within ⌊q/2⌋), on the pictures the tool generates.
- **Accounting for sink-made pictures** (§6). A sink's **presentation statement**
  (`wai-presentation`) lists, for a span, each picture it presented as `transmitted` (decoded, or
  refined by a residual to the origin's target), `derived` (an exact derivation with no residual),
  `asserted` (an edit no one can recompute, such as a float upscale) or `synthesized` (generated,
  such as a frame between two others), with its pixels counted by category and the span's totals.
  Each picture is held to its origin claim: an upscale claimed captured, or a generated frame
  claimed assistive, is refused (`made_understated`). A generated picture names the model that
  made it, in the slot `made_by` of the contribution record `wai.media.contribution`.
- **Synthesis** ([synthesis](extensions/synthesis.md)): an origin claim's subject may be a
  picture by the digest of its samples, for output a sink presents and does not publish; replicate
  evidence may name `wai-upscale:sr2` or `wai-upscale:sr4` with `{"prior"}`, proved by
  recomputation from the input's samples and the prior a verifier holds (§4.3, §4.4, §11.1); and a
  pinned integer derivation over the decode keeps a presentation path's tier (§9.2;
  determinism-tiers §2). Its corpus gains a sink's upscale proved, one whose recomputation differs,
  one under a prior that does not read, and one claimed about other samples.
- **Reference and corpus.** `wai-rs` module `int_sr` (feature `neural_int`), module
  `exact_upscale` (feature `exact_upscale`), and the GPU test `tests/exact_upscale_gpu.rs`
  (features `ops_gpu`, `exact_upscale`). `live-conformance/upscale/`, written from fixed seeds by
  `wai_upscale_vectors` around two trained priors pinned by SHA-256: upscales under the generic,
  a seeded and a per-title prior, residuals exact and to a bound, a span of four kinds of
  picture, and every reason of §8 refused. Checked by `tests/exact_upscale.rs` and by
  `live-conformance/upscale_verify.py`, a second implementation that shares no code with `wai-rs`,
  runs the network with `live-conformance/_int_sr.py`, and requires every mutated copy of the
  corpus to fail. The registry lists the record, the magic `WSR1` and the document kinds
  `wai-upscale` and `wai-presentation`.

