# V2 Context Screenshots

This document defines translator context screenshots for
`TODOS.phase-72.72.11.1.9`. Context screenshots show where a string appears in
game UI or dialogue and provide an auto-upload payload for the selected TMS
provider.

## Capture Manifest

`V2/ue/Tools/generate-v2-context-screenshots.py` reads
`V2/ue/Content/Localization/V2/StringTables/StringIdRegistry_V2.json` and
generates
`V2/ue/Content/Localization/V2/Screenshots/ContextScreenshotManifest_V2.json`.

Each manifest target includes:

- canonical string ID and TMS alias
- source text and context description
- stable screenshot reference
- capture preset for the UI surface
- viewport and highlight rectangle
- capture commandlet arguments for `V2LocalizationContextScreenshotCapture`
- deterministic content hash

## Auto-Upload

The same tool generates
`V2/ue/Content/Localization/V2/Screenshots/ContextScreenshotUploadPayload_V2.json`.
The payload targets Phrase, links every screenshot to the matching TMS alias,
and references `V2_PHRASE_API_TOKEN` through the request metadata. Raw
credentials must not be committed.

Run the generator after adding or changing screenshot references:

```bash
python3 V2/ue/Tools/generate-v2-context-screenshots.py
```

## Verification

Run this gate after changing screenshot references, capture metadata, upload
payloads, docs, or CI wiring:

```bash
python3 V2/ue/Tools/check-v2-context-screenshots.py
```

Required release gates:

- `localization-context-screenshots-contract`
- `localization-context-screenshots-manifest`
- `localization-context-screenshots-capture-commandlet`
- `localization-context-screenshots-tms-upload`
- `localization-context-screenshots-deterministic-output`
- `localization-context-screenshots-ci-wired`
