commit 477286eadb73e50fdd49797d43261f6e703ec5a3
parent 9c21b371c1c7e4a4255c021db3ba378202d06b52
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date: Sun, 1 Nov 2026 00:19:12 -0400
umtool docs: sections, split and flash-forward; the trailer's beats; take housekeeping (knobs.md, cli.md)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Diffstat:
2 files changed, 67 insertions(+), 0 deletions(-)
diff --git a/umtool/docs/cli.md b/umtool/docs/cli.md
@@ -55,7 +55,9 @@ Inbox cannot disagree about what is wrong with one.
| `take … --priority` · `takes make … --priority` · `render-mode on [--for 90m] [--note T] [--json]` · `render-mode off [--force] [--json]` · `render-mode status [--json]` | **render mode**: a render the operator waits for gets the machine. `--priority` turns it on for the take's (or the batch's) lifetime — on at the start, off at the end, on a failure and on a signal; the Takes page's **Give renders the machine** is the same flag. While it is on, every other heavy job (e2e suites, `next build`s, the publish stages, other renders) waits at the heavy slot's door (`queue-lock: held for a render (…) — waiting`), the render runs on the floor 4000 MB and the cap 10240 MB, and the editor's transcription and download lanes are held through its ops (`lane`; only the ones not already held, and only those are released at off). `render-mode on` is a window (default 2h) for a chain of renders: every `umtool take` started in it renders in it, another command joins with the `RENDER_PRIORITY_TOKEN` it prints. `off` ends it (a running take's hold only with `--force`, else it ends with the take); `status` says what holds it and releases a stale hold's lanes. A hold whose process is gone or whose window is over is no hold. Needs WORKER_TOKEN and the editor at ARCHILYZER_EDITOR_URL for the lanes; without them it still holds the door. **Exit 1** when it is already on, or a lane could not be released ([report-video.md](report-video.md#render-mode-giving-a-render-the-machine); WORKTREES.md, "Render mode") |
| `takes make <project> [--recipe FILE] [--only ID,ID] [--force]` · `takes make <project> --all-styles [--group G] [--at S --dur S \| --full]` | a recipe's takes, one at a time (default `takes/recipe.json`); every montage style, one take each (Make all styles); **exit 1** if any failed |
| `takes styles [--json]` · `takes effects <project> [--json]` · `takes pick <project> <take> [--anyway] [--json]` | the montage styles; the overlay effects the cut offers (`render.chrome.fx` presets: the Takes page's **Effect** list); **Use this take** — refused (exit 1) when the project changed since the take was made, until `--anyway` |
+| `takes ls <project> [--json]` · `takes relabel <project> <take> <label…>` · `takes supersede <project> <take> [--by <take>]` · `takes supersede <project> <take> --clear` · `takes delete <project> <take> [--dry-run] [--force]` | **take housekeeping** (the Takes page's ✎, **Mark superseded**, **Delete take**): the takes with picked / superseded / RENDERING; a label fixed in `take.json` (an undo point of the take's own); a take folded away as superseded (verdicts.json, nothing deleted); a take deleted. Relabel and delete are refused (**exit 1**) while the take renders or a live render is made from it ([knobs.md](knobs.md#takes-relabel-supersede-delete)) |
| `trailer <project> --take <t> (--beats FILE \| --beats-json JSON) [--intro] [--finale S] [--xfade 0.3] [--out NAME] [--dry-run] [--json]` | a **trailer cut from the take's finished master**: spans of the master's own frames (the deck shows the whole timeline), clip beats in source seconds mapped by the take's build records, crossfaded, the take's encode, in the heavy slot; writes `takes/<t>/out/<slug>.trailer.mp4` and `.trailer.json`; **exit 1** on a refusal ([report-video.md](report-video.md#trailer-from-the-master)) |
+| `trailer-beats <project> [ls] [--json]` · `add <clip> [<from>-<to>] [--at N] [--label L]` · `add-raw <at> <dur>` · `set <n> <from>-<to>` · `remove <n>` · `move <n> --to <m>` · `order` · `limit <s\|m:ss\|x\|instagram\|shorts\|tiktok>` · `xfade <s>` · `intro on\|off` · `candidates [--add]` | **the trailer's beats** (`promo/trailer-beats.json`, the Trailer page's file, what `trailer --beats` reads): each beat's length, the running length against the platform limit (X 2:20 by default), beats outside their clip's window, the cut's order, the walk's ★ clips ([knobs.md](knobs.md#the-trailers-beats)) |
| `rulings <project> [--json]` · `rulings <project> import [--dry-run] [--json]` · `rulings <project> set <clip\|key> keep\|cut\|not-him\|read-aloud [--reason R] [--match M]` · `rulings <project> clear <clip\|key>` | a montage's **clip rulings** (`montage-rulings.json`, the clip deck's): each clip and its ruling and the next render's kept clips; the earlier rulings in the seed's `edits.json`, once; one ruling set or cleared. A render leaves out every clip ruled cut, not-him or read-aloud ([report-video.md](report-video.md#ruling-the-clips)) |
| `fetch <project> --body` · `fetch <project> --dry-run [--json]` · `fetch <project> [--wait] [--json]` · `fetch <project> --status [--json]` · `… [--reason R]` · `… --refetch <clipId>[,…]` · `… --refetch-video <slug>/<id>` | **Fetch windows** (the Cut tab's and the clip deck's button): every clip's window asked of the editor as ONE fetch-windows batch — `--body` prints the body and asks nobody; `--dry-run` the editor's plan (groups per platform, cached, in flight, unresolved); no flag starts it (one paced job per platform queue), `--wait` follows the jobs to their end and names each window a job failed; `--status` follows the last run's jobs once. Clips the montage rulings leave out are not asked for. `--refetch <clipId>[,<clipId>…]` evicts the cached windows that OVERLAP those clips' fetch spans first (the editor's `evict-clips` `{slug, id, covering}`, one job per video, waited for), then fetches as usual — for windows known bad (cut from a corrupt saved video); `--refetch-video <slug>/<id>` does it for every window the project asks of that video; with `--dry-run` the eviction is a dry run too and names what it would remove. Every run is recorded in `<project>/fetch-runs.json` (a refetch's evictions under `refetch`). Needs WORKER_TOKEN (else the editor's env files) and the editor at ARCHILYZER_EDITOR_URL. **Exit 1** when a job failed or the editor refused ([report-video.md](report-video.md#fetching-the-windows-and-stand-ins)) |
| `prep <project> [--clips a,b] [--json]` · `prep <project> [--clips a,b] --wait` · `prep <project> --status [--json]` | **Prepare clips for the walk** (the Cut tab's): what the clip bench makes on a clip's first open — a long recording's excerpt, the waveform — made ahead ([clip-bench.md](clip-bench.md#prepared-before-you-open-it)). No flag queues it and returns (a runner starts in the background, its log `out/bench-excerpts/prep.log`); `--wait` runs it here to the end; `--status` prints ready / to prepare / failed / not fetched and the runner. One clip at a time, each in the heavy slot (estimate 400 MB), under `nice -n 19` and `ionice -c3`; a prepared clip is skipped. A fetch that lands and a write that moves or adds a clip queue it too (`UMTOOL_BENCH_PREP=0` turns that off). **Exit 1** when a clip failed (`--wait`) |
@@ -66,6 +68,7 @@ Inbox cannot disagree about what is wrong with one.
| `clips analyze <project> [--from <channel>/<id>] [--rescan] [--no-laughs] [--no-voices] [params] [--words FILE] [--progress ndjson] [--json]` · `clips propose <project> [--from <channel>/<id>] [--host N] [params] [--words FILE] [--dry] [--json]` · `clips show <project> [--json]` · `clips segments <project> [--json]` | the **clip finder** on a long recording ([report-video.md](report-video.md#highlights-the-clip-finder)): `analyze` runs the laugh scan (CED-mini) and a voice centroid per speaker on the recording's sound (cached in `<project>/scans/`), then proposes; `propose` proposes again from what is there (after a role flip, a param change, new words); `show` prints the speakers, laughs and the cut. Params `--target S` (600) `--laugh-min X` (0.25) `--merge-gap S` (6) `--setup-max S` (20) `--clip-max S` (75) and the scope `--scope FROM:TO` (either side may be empty; `all` clears it) or `--from S --to S` with numbers (a `--from` that is a `<channel>/<id>` names the recording), kept in `reactions.json`; `--host N` is your word on the host, kept. `--keep-cut` proposes without touching the cut (nothing moved, removed or added; the proposals are listed). **`--scope auto`** reads the narrated video auto-scope finds in the speaker turns (`--segment sN` names one, else the longest); `segments` lists them. A chat replay beside the recording (`live_chat.cues.json`) adds chat-burst moments and the log names the chat's lag. A channel on no site gets each clip linked to its platform page (`citeUrl`). A clip you edited, ruled, locked or added is never moved. **Exit 2** with no `diarization.json` (the message names the `archilyzer diarize backfill` to run) |
| `timeline <project> [ls] [--json]` · `timeline <project> insert --after <id\|-> <channel>/<video>@<start>-<end> [--id ID] [--section N] [--lock] [--lock-end] [--title T] [--stream-title T] [--date YYYY-MM-DD] [--quote Q] [--cite S] [--cite-url U]` · `timeline <project> move <id> --to <index>` · `remove <id>` · `reject <id> <why> [--note T]` · `wrong-speaker <id> [--correction T]` · `duplicate <id>` (`--at <index>` names one of an id's twins) · `post <json\|@file>` · `post-remove <id>` · `teaser <id> <patch-json\|@file>` · `undo` | the **structure** of the cut (the Cut tab's timeline, the On-screen section's teasers and posts) through the writers `POST /api/report/timeline` runs: `ls` prints index, id, type, video, start–end, date and title (`--json` adds the token and the posts); an insert's attribution is a second write through `window`'s writer, its date checked before anything is written; it is written in the manifest's own convention — under the deck `--title` is the deck's title (`onscreen.title`, `--stream-title` the stream's), a cut whose deck titles are dates gets `--date` as one in their format, and the clip takes the section of the clip it goes after (`--section N` names another) and, from the same recording, its deck title and its citation link. A removal re-anchors what named the clip (a marker to the clip before, a chapter to the next in its section; a pair, a status reference or a deck claim dropped) and prints each `re-anchored:` line; `reject` rejects the clip for `<why>` — `not-matching` or `wrong-speaker` (fact errors: `incorrect`, the note its correction) or `irrelevant`, `repeats`, `weak`, `privacy`, `other` (`rejected`, never a correction) — and removes it, on record in `removed.json` with the reason and the note; `wrong-speaker <id>` is `reject <id> wrong-speaker`; `ls` marks a clip rejected but still in the cut (`[rejected — irrelevant]`) ([report-video.md](report-video.md#verdict--what-the-walk-said)). Every write snapshots the manifest first (`revisions/…-auto-before-<op>`), is refused only for what it breaks in the build's own words (**exit 1**), and on a generated manifest leaves an `edit` note ([report-video.md](report-video.md#structural-edits)) |
| `timeline <project> --take <take> [ls \| move <id> --to <index> \| remove <id> \| undo]` | a **take's** timeline (walk a take): the same structure checks, written into the take's patch, each write with an undo point of the take's own (`takes/<take>/revisions/`); `undo` takes the take's newest edit back, whichever writer made it |
+| `timeline <project> sections [--json]` · `section-move <id>… --to-section N [--start]` · `section-add --after <id> [--label L] [--color C]` · `section-boundary <marker> --after <id>` · `section-remove <marker>` · `section-set <marker> [--label L] [--color C]` · `split <id> <second>` · `flash-forward <id> <from>-<to> (--after <id\|-> \| --to-section N [--start]) [--move] [--quote Q] [--id ID]` | **sections as sections** (the deck's markers; the Cut tab's section bars and row menus): clips moved to a section with every marker following, a section opened, a boundary moved, relabelled, removed — no section emptied, no boundary crossed (**exit 1**) — and every take patch in step synced; **split** (each half's quote from the words, the second half's cite and QR at its second, a marker after the clip following its second half); **flash-forward** a tight copy of a span elsewhere with the clip's attribution and locks, as `repeatOf` the clip (`--move`: out of the clip) ([knobs.md](knobs.md#sections-split-and-flash-forward-editing-the-cut)) |
| `scenes <project> <clip> [--black-min 0.05] [--threshold 8] [--pix-th 0.10] [--pad 30 \| --from S --to S] [--json]` | the picture's **scene cuts** (ffmpeg `scdet`, score ≥ threshold) and **black spans** (`blackdetect`) in the clip's fetched window, in SOURCE seconds — for `blur.from`/`blur.to` and trims ([knobs.md](knobs.md#a-clips-picture-blurred)). The window is the one the build would cut from (the project's `out/clips-raw`, the editor's `channels/<slug>/data/<id>/clips/`, a saved source); the extent ± `--pad` inside it is scanned. Nothing is fetched: **exit 1** with no window on disk (`fetch` first) |
| `posts set <project> <post> thread=on\|off [hide=on\|off] [attach=<clipId>\|auto] [--json]` | the Posts table's writer (`updatePosts`, `PUT /api/report/posts`) from a terminal: `<post>` is the manifest's id (`x-<postId>`) or the bare `<postId>`; `thread=on` draws a reply with the post it answers above it (`shot-thread.png` beside its `shot`, taken by `capture-posts` `"thread": true`; its own shot while there is none), `off` removes the key. Refused in the build's words (a post with no `shot`, an `attach` that is not a clip) — **exit 1** |
| `posts add <project> <archive-channel>/<postId> [--attach <clipId>] [--flag F] [--author A] [--id ID] [--thread] [--dry-run] [--json]` | a **post card** from the corpus's posts archive (`channels/<slug>/posts/*.jsonl`): its words, date, link and handle; id `x-<postId>` (`bsky-`, `post-`); the author an earlier post by the same handle carries in the cut, else the archive's. Its capture (`posts-media/<postId>/`: `shot.png`, `capture.json`, the post's pictures) is copied to the project's `posts-media/<slug>/<postId>/` — or used where it is, when that folder links the channel's captures; never copied through a link anywhere else. Then `upsertPost` (a post with the id is replaced, its `attachTo` kept). **Exit 1** with no screenshot, naming the `pnpm ops capture-posts` to run. `--thread`: the entry gets `thread: true` (a reply drawn with the post it answers; `shot-thread.png` is copied with the rest, and with none yet it prints the `"thread": true` capture to run) |
diff --git a/umtool/docs/knobs.md b/umtool/docs/knobs.md
@@ -232,6 +232,35 @@ the render unchanged. The two are not set together: on a migrated cut the series
The default ladder: `master`, `1080p` (crf 22), `720p` (crf 23), `fit24` (at most 24 MiB). `umtool look` also sets
the look's keys (`transition=0.3`, …: [report-video.md](report-video.md#the-look-captions-loudness-shorts-release-36)).
+## Sections, split and flash-forward (editing the cut)
+
+Under the deck a cut's **sections are its markers** (`render.chrome.deck.markers`): §0 runs to the first marker's
+boundary, and a marker `{after, label, color}` opens the next section right after that clip, its label and colour
+the new section's. These edits move clips and boundaries together, so no section empties and no boundary crosses
+another (each refused in words), and every **take patch in step** (`*.patch.json` beside the manifest whose
+markers were the manifest's before the edit) is brought along; a patch whose markers already differed is left, and
+named (`lib/report/sectionEdit.mjs`, `sectionPatches.mjs`). Each is a structural write: an undo point first
+(**Undo last edit**, `umtool timeline <p> undo`).
+
+| | In umtool | From a terminal | Route |
+|---|---|---|---|
+| the sections | the Cut tab: a bar where each opens (colour, label, clips) | `umtool timeline <p> sections [--json]` | `GET /api/report/timeline` (`sections`) |
+| move clips to a section (its end; or its start) | a row's ⋯ **move to section…**; tick rows, **move to section… → Move**; a row dragged onto a section's bar (its start) | `umtool timeline <p> section-move <id> [<id>…] --to-section N [--start]` | `POST /api/report/timeline {op: "section-move", ids, section, position?}` |
+| new section here | a row's ⋯ **new section here**: label (≤ 24), colour | `umtool timeline <p> section-add --after <id> [--label L] [--color C]` | `{op: "section-add", afterId, label?, color?}` |
+| move a boundary | drag a section bar's ⇕ onto the clip it should follow | `umtool timeline <p> section-boundary <marker> --after <id>` | `{op: "section-boundary", marker, afterId}` |
+| relabel / recolour, remove a boundary | a bar's **edit**, **remove boundary** (the section joins the one before) | `umtool timeline <p> section-set <marker> [--label L] [--color C]` · `section-remove <marker>` | `{op: "section-set", marker, label?, color?}` · `{op: "section-remove", marker}` |
+| split a clip at a second | the clip editor's **Split here** (`S`, at the playhead) | `umtool timeline <p> split <id> <second>` | `POST /api/report/clip-editor {op: "split", clip, at}` |
+| flash-forward a span | the clip editor: select the span on the strip, **Flash-forward selection…**: the start of a section, or after an entry; **move it out** for a move | `umtool timeline <p> flash-forward <id> <from>-<to> (--after <id\|-> \| --to-section N [--start]) [--move] [--quote Q] [--id ID]` | `POST /api/report/clip-editor {op: "flash-forward", clip, from, to, after? \| section?, position?, move?}` |
+
+- **A split** keeps both halves' attribution and locks (the second half's `cite` and citeUrl `t=` move to its own
+ second), each half's quote read from the words; a marker after the clip follows its second half (the same
+ boundary). A claim stays with the first half.
+- **A flash-forward** is a tight copy of the span (inside the clip's window) with the clip's title, date, channel,
+ `cite`/citeUrl at the new second, quote (the span's words), speakers, on-screen words, verdict and locks, marked
+ `repeatOf` the clip (the check's overlap row knows it is deliberate); its id is `<clip>t`. **Move** takes the span
+ out of the clip instead (it must sit at one of the clip's edges; the clip keeps the rest, its quote re-read); a
+ span in the middle is refused — split there first. A claim, the marks and the assistant's record stay with the clip.
+
## The finale (the timeline in primary view)
The cut's last clips with the footer's rail redrawn large across the top (every pip lit, the markers flagged,
@@ -442,6 +471,41 @@ again is written over.
on another OS, and from any device but the machine umtool runs on (by the request's Host, Origin and
X-Forwarded-For) — use **Download** there.
+## The trailer's beats
+
+`umtool trailer <p> --take <t> --beats <p>/promo/trailer-beats.json` cuts a trailer from a finished master; the beats
+file is edited here, through one writer (`lib/report/trailerBeats.mjs`), which says before any encode each beat's
+length (a clip beat's gaps out, as the master plays it), the **running length against the platform's limit** (X 2:20 by
+default; Instagram 1:30, a Short 3:00, TikTok 10:00, or seconds) with the trailer's crossfades and the brand intro
+(its length from the newest built take's schedule), every beat **outside its clip's window** or naming a clip no
+longer in the cut, and whether the beats are in the cut's order. A beat is `{id, start, end, label?}` (source
+seconds of a clip) or `{at, dur}` (master seconds), numbered from 1 as `umtool trailer` numbers them. The file keeps
+its shape (an array, until a setting makes it `{limit, xfade, intro, beats}`, which `--beats` reads too) and its
+indent; one that does not parse is never written over; a write over a newer file is a 409.
+
+| | In umtool | From a terminal | Route |
+|---|---|---|---|
+| the beats, the length, the limit, what to fix | the Cut tab's **Trailer** → `/projects/<p>/trailer` | `umtool trailer-beats <p> [--json]` | `GET /api/report/trailer-beats?project=<p>` |
+| add a beat (in the cut's order) | the clip editor's **Add to trailer** (the selection, else the cut); the Trailer page's **add a beat** | `umtool trailer-beats <p> add <clip> [<from>-<to>] [--at N] [--label L]` · `add-raw <at> <dur>` | `POST … {op: "add", beat, at?}` |
+| a beat's seconds; pull it inside its clip | the row's from–to; **fit to clip** | `umtool trailer-beats <p> set <n> <from>-<to> [--label L]` | `{op: "set", index, patch}` |
+| move, remove, the cut's order | ↑ ↓ **remove**; **Order by the cut** | `move <n> --to <m>` · `remove <n>` · `order` | `{op: "move", index, to}` · `{op: "remove", index}` · `{op: "order"}` |
+| the limit, the crossfade, the intro | **limit** (a platform, or seconds), **crossfade**, **open on the brand intro** | `limit <s\|m:ss\|x\|instagram\|shorts\|tiktok\|default>` · `xfade <s>` · `intro on\|off` | `{op: "settings", limit?, xfade?, intro?}` |
+| the walk's ★ clips | **★ from the walk**: each **Add** | `umtool trailer-beats <p> candidates [--add]` | `GET` (`candidates`) |
+
+## Takes: relabel, supersede, delete
+
+| | In umtool | From a terminal | Route |
+|---|---|---|---|
+| list | the Takes page | `umtool takes ls <p> [--json]` (picked, superseded, RENDERING) | `GET /api/report/takes` |
+| relabel (take.json's `label`; an undo point in the take's `revisions/`) | a take's ✎ | `umtool takes relabel <p> <take> <label…>` | `POST /api/report/takes/housekeeping {project, take, op: "relabel", label}` |
+| superseded (verdicts.json `superseded: {by, at}`; folded away in the list, nothing deleted; a pick clears it) | **Mark superseded** (by a take), **Not superseded**; **show them** in the group | `umtool takes supersede <p> <take> [--by <take>]` · `--clear` | `{op: "supersede", by?}` · `{op: "unsupersede"}` |
+| delete `takes/<take>/` | **Delete take** (the plan first) | `umtool takes delete <p> <take> [--dry-run] [--force]` | `POST /api/report/takes/delete {project, take, dryRun?, force?}` |
+
+**What a running render names is respected**: a take whose build lock (`takes/<id>/.building.json`) is live is
+rendering — its take.json is written last, from the label it started with — and a take a live build names as its
+`from` is that build's base. Relabel and delete are refused for both (`force` does not pass it); a supersede mark is
+not (no render writes verdicts.json).
+
## Make variants, and the sync report
| | In umtool | From a terminal | Route |