# Script writer: transcript imports

To have an agent write a **new script in a similar style**, use **Download
agent brief** beside your draft. It packages your topic and facts, the selected
reference analysis, writing instructions and two original worked scripts.
The [agent writing guide](agent-guide.md) is also available on its own.
Imports are optional and serve close inspection of wording and timing.

The public page includes the existing 100-film reference notes. It does not
republish full third-party transcripts. Import transcripts you provide to read
their supplied words and times next to your draft.

## Word-timed JSON

Use a single object with a `words` array, or a bundle with a `videos` array.
Each record has the YouTube `id` from the reference index. The following words
and times are an invented format example, not an excerpt from that film.

```json
{
  "videos": [{
    "id": "bbNTY8O0GTY",
    "words": [
      {"word": "Your", "start": 0.0, "end": 0.3},
      {"word": "words.", "start": 0.3, "end": 0.8}
    ]
  }]
}
```

`text` can replace `word`. Times must be finite, non-negative numeric seconds,
with end at or after start, in chronological start order. Overlapping entries
are retained. Source-clock fields `source_start` and `source_end` take precedence
when present. A JSON export using `segments[].words[]` is also accepted. A file
with a mixture of timed words and untimed spoken segments is rejected rather
than silently dropping text. `segments` without words is imported as cue timing.

The app also reads its own normalized `{id, timing, units}` JSON and bundles
using a `transcripts` array or an object keyed by video ID. A single record may
omit its ID to use the selected film. Multi-record bundles need explicit IDs.

## SRT and VTT

Caption imports preserve cue timing. They do not manufacture individual word
times. One unnamed file uses the selected film; to import multiple caption
files, name each file with its video ID, such as `bbNTY8O0GTY.vtt`.

VTT exports use millisecond precision. If rounding would make a cue end at its
start, the page asks you to use JSON rather than changing the supplied timing.
A word-timed import exports one cue per
word; a cue-timed import exports its original cues. JSON exports retain numeric
timing precision. Neither export certifies the accuracy of the input transcript.

## Working with passages

Select a word or cue to see its time and open that moment on YouTube. Enable
**Extend selection**, then choose another entry to select the intervening
passage. Shift-click works too. A range can span pages. **Add passage to draft**
copies your selected imported wording and attaches its source reference.
Your own recording times remain blank until you enter them.

Search the library across titles, study notes and imported transcripts. The
transcript search supports phrases and shows nearby context. A coverage filter
lists films with or without an imported transcript.

## Storage and backups

Files and draft text stay in your browser on the current site address; they are
not uploaded. The production address provides one consistent workspace:

[Script writer](https://openai-film-fieldnotes-work.pages.dev/videos/storytelling/script-writer/)

**Download full backup** saves the draft and all imported transcripts as JSON.
**Restore backup** replaces both with the backup contents. Keep a download of
the current state if you need both versions. **Download all imported transcripts**
exports only transcript records. The Markdown draft exports spoken words,
visual plans, supplied recording times and attached references.

Invalid imports and backups are rejected before the save transaction. Each
batch permits up to 100 files and 50 MB. If browser storage is unavailable,
the page says so and retains work in the current tab for download.

## Production timing

The draft's spoken-word count is not a duration estimate. Use the actual
talking-head recording to set speech and pause timings. The separate
[storyboard worksheet](https://openai-film-fieldnotes-work.pages.dev/videos/storytelling/worksheet/)
records the presentation lead-in, visible start cue, manual playback offset and
ending buffer. Keep the talking-head and presentation assets separate and
review the storyboard before production.
