# AutoShorts ERF-029 QR subtitle correction pattern

Session learning from TrueTraceShorts `erf-029-parking-meter-qr-trap-director-pass`.

## Durable lesson

When the final spoken word is an acronym (`QR`), Whisper/forced alignment may append a zero-duration phonetic hallucination such as `You` + `are.` after the correct final `QR.`. If subtitles are burned from the raw word list, the video can visually end with the wrong words even though the voice is correct.

## Detection

- Do not rely only on a framesheet overview.
- Spot-check a late frame in the final 0.5-1.5s after render.
- Inspect the word-alignment JSON tail for suspicious zero-duration or same-timestamp words after acronyms.
- For this case, the bad tail looked like:

```json
[
  {"word": "sticker", "start": 23.0, "end": 23.38},
  {"word": "QR.", "start": 23.38, "end": 23.74},
  {"word": "You", "start": 23.74, "end": 23.74},
  {"word": "are.", "start": 23.74, "end": 23.94}
]
```

## Fix pattern

Filter trailing hallucinated acronym expansions before subtitle segmentation/rendering, then re-render:

```python
if len(words) >= 2 and words[-2]["word"].lower().strip(". ,") == "you" and words[-1]["word"].lower().strip(". ,") in {"are", "r"}:
    words = words[:-2]
```

After the fix, verify the JSON tail ends at `QR.` and extract/check a late-frame screenshot.

## Workflow impact

- Any subtitle-only fix changes the MP4 SHA256.
- Regenerate the YouTube private upload package and approval command.
- Import as a superseding dashboard package ID/version, e.g. `_director_v2`.
- Tell the user explicitly to use only the new upload command.
- After private upload, website companion update should reference the corrected video ID and include the real Shorts URL even while private, per TrueTrace workflow.
