@aicopycoders/exodus 2026.11.1200-beta.27 → 2026.11.1200-beta.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -290,6 +290,10 @@ move someone (Micro-drama template only), or stop.
|
|
|
290
290
|
with `--accept-findings`. A `--one-shot` run stops here too when the check
|
|
291
291
|
before pictures finds a problem: `status` prints what it found, scene by
|
|
292
292
|
scene. Show it to the member; accepting it is their call, never yours.
|
|
293
|
+
When `status` also says the plan broke one of the app's planning rules,
|
|
294
|
+
accepting draws the scene pictures and the video stops once more at them,
|
|
295
|
+
so the member looks at the pictures before anything is filmed. That second
|
|
296
|
+
stop is a normal storyboard review: show it and approve only on their yes.
|
|
293
297
|
- Redo a picture: `exodus video retry-frame <runId> --node <nodeId> --scene <n>
|
|
294
298
|
--note "<what is wrong>"`, with the node id from the `Redo one frame:` line
|
|
295
299
|
`status` printed. It redraws one picture. The CLI prints no price for it:
|
|
@@ -1874,6 +1874,59 @@ export function brollWindow(seg, counts, cueLineId, texts, broll) {
|
|
|
1874
1874
|
return { startSec, holdSec, method, found: true };
|
|
1875
1875
|
}
|
|
1876
1876
|
|
|
1877
|
+
/**
|
|
1878
|
+
* #4835: the most air a join keeps before a scene's first word (trimJoins: the new-speaker beat, floored to a whole
|
|
1879
|
+
* frame, so up to one frame more).
|
|
1880
|
+
*/
|
|
1881
|
+
const OPENING_AIR_MAX_SEC = JOIN_LEAD_NEW_SPEAKER_SEC + 1 / FPS;
|
|
1882
|
+
|
|
1883
|
+
/**
|
|
1884
|
+
* #4835: a cutaway laid from a line's first word, when that line opens its scene, started after the scene's picture did:
|
|
1885
|
+
* the air a join keeps before the first word showed the speaking scene for a few frames (3 at 24 fps), then the
|
|
1886
|
+
* cutaway. A cutaway that starts inside that air (after its scene's first frame, no later than its first word) starts
|
|
1887
|
+
* on the scene's first frame instead, and its own first frame is held over the air (`leadHoldSec`), so every frame it
|
|
1888
|
+
* showed before stays where it was and its end does not move. A scene that opens on an action (actionLeadSec) keeps
|
|
1889
|
+
* it, a scene with more air than a join keeps is left as it is, and so is a shot copied from a source ad.
|
|
1890
|
+
*/
|
|
1891
|
+
export function coverOpeningAir(cutaways, spine) {
|
|
1892
|
+
const moves = cutaways.flatMap((c) => {
|
|
1893
|
+
// A shot copied from a source ad keeps its source's place.
|
|
1894
|
+
if (c.method === "source") return [];
|
|
1895
|
+
const owner = spine.find((seg) => seg.startSec < c.startSec - 1e-6 && c.startSec < seg.startSec + seg.seconds);
|
|
1896
|
+
if (!owner?.words?.length || owner.actionLeadSec > 0) return [];
|
|
1897
|
+
const air = c.startSec - owner.startSec;
|
|
1898
|
+
const firstWord = Math.min(...owner.words.map((w) => w.s));
|
|
1899
|
+
if (air > firstWord + 1e-6 || firstWord > OPENING_AIR_MAX_SEC + 1e-6) return [];
|
|
1900
|
+
// Another cutaway on that air already covers it, or starts with this one: nothing flashes, so nothing moves.
|
|
1901
|
+
if (cutaways.some((d) => d !== c && d.seconds > 0 && d.startSec <= c.startSec + 1e-6 && d.startSec + d.seconds > owner.startSec + 1e-6)) return [];
|
|
1902
|
+
return [{ c, from: owner.startSec, air }];
|
|
1903
|
+
});
|
|
1904
|
+
for (const { c, from, air } of moves) {
|
|
1905
|
+
c.startSec = from;
|
|
1906
|
+
c.seconds += air;
|
|
1907
|
+
c.leadHoldSec = air;
|
|
1908
|
+
}
|
|
1909
|
+
}
|
|
1910
|
+
|
|
1911
|
+
/**
|
|
1912
|
+
* #4835: how long a cutaway holds its first frame before its clip plays; none when what is left of it after the hold
|
|
1913
|
+
* is under a frame (cut short inside the air), so the render never trims its clip to nothing.
|
|
1914
|
+
*/
|
|
1915
|
+
const cutawayLeadHold = (c) => (c.leadHoldSec > 0 && c.seconds - c.leadHoldSec >= 1 / FPS - 1e-9 ? c.leadHoldSec : 0);
|
|
1916
|
+
|
|
1917
|
+
/**
|
|
1918
|
+
* #4835: the frames of a cutaway moved back from `wasSec` to its scene's first frame at `startSec`. The render lays a
|
|
1919
|
+
* cutaway's frames from `setpts=...+<start>/TB` on the 24 fps clock, which ffmpeg truncates to a whole frame, so its
|
|
1920
|
+
* first frame landed on frame trunc(wasSec * FPS) (the start as written, to the millisecond). The moved cutaway's own
|
|
1921
|
+
* frames land there still, after `clones` copies of its first frame from the scene's `first` frame on, so every frame it
|
|
1922
|
+
* showed before is the one it shows now. Its frames are stamped half a frame past `first` (truncated to `first`) and it
|
|
1923
|
+
* is shown from half a frame before it, so a start written to the millisecond can never fall just after its frame.
|
|
1924
|
+
*/
|
|
1925
|
+
export function openingAirFrames(startSec, wasSec) {
|
|
1926
|
+
const first = Math.round(startSec * FPS);
|
|
1927
|
+
return { first, clones: Math.max(0, Math.trunc(Number(sec(wasSec)) * FPS) - first) };
|
|
1928
|
+
}
|
|
1929
|
+
|
|
1877
1930
|
/**
|
|
1878
1931
|
* Cut the dead air out of each join between clips that play their own sound: a
|
|
1879
1932
|
* clip's lead-in silence stacked on the previous clip's tail ran past a second
|
|
@@ -4221,6 +4274,8 @@ function assembleTimeline({
|
|
|
4221
4274
|
}
|
|
4222
4275
|
cutaways.push(placed);
|
|
4223
4276
|
}
|
|
4277
|
+
// #4835: a cutaway starting in the air before its scene's first word starts with that scene instead.
|
|
4278
|
+
if (!measure && !template) coverOpeningAir(cutaways, spine);
|
|
4224
4279
|
if (measure) {
|
|
4225
4280
|
for (const c of cutaways) {
|
|
4226
4281
|
c.startSec = Math.round(c.startSec * FPS) / FPS;
|
|
@@ -4510,18 +4565,20 @@ export function holdBroll(timeline, minSec, speed, clipSeconds) {
|
|
|
4510
4565
|
const kept = [];
|
|
4511
4566
|
const left = [];
|
|
4512
4567
|
for (const c of timeline.cutaways) {
|
|
4513
|
-
|
|
4568
|
+
// #4835: judged on its own clip's time, as before its first frame was held over its scene's opening air.
|
|
4569
|
+
const lead = cutawayLeadHold(c);
|
|
4570
|
+
const shown = (c.seconds - lead) / speed;
|
|
4514
4571
|
if (c.motionProtection || shown >= minSec - 1e-6) {
|
|
4515
4572
|
kept.push(c);
|
|
4516
4573
|
continue;
|
|
4517
4574
|
}
|
|
4518
4575
|
const why = `cutaway ${c.sceneIndex}: ${shown.toFixed(2)}s on screen, under the ${minSec}s B-roll minimum, so it is left out and`;
|
|
4519
4576
|
const before = kept.at(-1);
|
|
4520
|
-
if (before && !before.motionProtection && Math.abs(before.startSec + before.seconds - c.startSec) < 0.5 / FPS) {
|
|
4577
|
+
if (before && !before.motionProtection && Math.abs(before.startSec + before.seconds - (c.startSec + lead)) < 0.5 / FPS) {
|
|
4521
4578
|
before.seconds = roundMs(c.startSec + c.seconds - before.startSec);
|
|
4522
4579
|
if (c.cutShortBy) before.cutShortBy = c.cutShortBy;
|
|
4523
4580
|
else delete before.cutShortBy;
|
|
4524
|
-
const hold = before.source === "clip" ? roundMs(before.seconds - clipSeconds(before.file)) : 0;
|
|
4581
|
+
const hold = before.source === "clip" ? roundMs(before.seconds - cutawayLeadHold(before) - clipSeconds(before.file)) : 0;
|
|
4525
4582
|
if (hold > 0) before.holdSec = hold;
|
|
4526
4583
|
left.push(`${why} cutaway ${before.sceneIndex} plays on over it`);
|
|
4527
4584
|
} else {
|
|
@@ -4549,7 +4606,7 @@ export function speedUpSlowBroll(timeline, motionOf, clipSeconds) {
|
|
|
4549
4606
|
.map((seg) => ({ n: seg.sceneIndex, role: roleOf(seg), file: seg.file, from: seg.inSec ?? 0, sec: seg.seconds - (seg.holdSec ?? 0) })),
|
|
4550
4607
|
...timeline.cutaways
|
|
4551
4608
|
.filter((c) => c.source === "clip")
|
|
4552
|
-
.map((c) => ({ n: c.sceneIndex, role: "b-roll", file: c.file, from: 0, sec: c.seconds, cutaway: c })),
|
|
4609
|
+
.map((c) => ({ n: c.sceneIndex, role: "b-roll", file: c.file, from: 0, sec: c.seconds - cutawayLeadHold(c), cutaway: c })),
|
|
4553
4610
|
].filter((s) => s.sec > 0);
|
|
4554
4611
|
const measured = shots.map((s) => ({ ...s, motion: motionOf(s.file, s.from, s.sec) }));
|
|
4555
4612
|
const notes = [];
|
|
@@ -4557,12 +4614,13 @@ export function speedUpSlowBroll(timeline, motionOf, clipSeconds) {
|
|
|
4557
4614
|
const c = slow.cutaway;
|
|
4558
4615
|
if (!c || c.motionProtection) continue;
|
|
4559
4616
|
const have = clipSeconds(c.file);
|
|
4560
|
-
|
|
4617
|
+
const played = c.seconds - cutawayLeadHold(c);
|
|
4618
|
+
if (!(have > played + 0.05)) {
|
|
4561
4619
|
notes.push(`cutaway ${c.sceneIndex} barely moves, but its clip (${have.toFixed(2)}s) is no longer than its time on screen (${c.seconds.toFixed(2)}s), so it plays as it is`);
|
|
4562
4620
|
continue;
|
|
4563
4621
|
}
|
|
4564
|
-
c.speed = roundMs(Math.min(have /
|
|
4565
|
-
notes.push(`cutaway ${c.sceneIndex} barely moves, so it plays ${c.speed}x faster: ${(
|
|
4622
|
+
c.speed = roundMs(Math.min(have / played, SLOW_SHOT_SPEED_MAX));
|
|
4623
|
+
notes.push(`cutaway ${c.sceneIndex} barely moves, so it plays ${c.speed}x faster: ${(played * c.speed).toFixed(2)}s of its clip in ${c.seconds.toFixed(2)}s`);
|
|
4566
4624
|
}
|
|
4567
4625
|
return notes;
|
|
4568
4626
|
}
|
|
@@ -4861,12 +4919,18 @@ export function buildFfmpegArgs(timeline, { resolve, music, out, finish = null,
|
|
|
4861
4919
|
// speedUpSlowBroll: a slow cutaway plays faster; brollMinSec: one that plays on past its clip holds its last frame.
|
|
4862
4920
|
const faster = c.speed > 1 ? `,setpts=PTS/${c.speed}` : "";
|
|
4863
4921
|
const hold = c.holdSec > 0 ? `,tpad=stop_mode=clone:stop_duration=${sec(c.holdSec)}` : "";
|
|
4922
|
+
// #4835: one that starts with its scene holds its first frame over the scene's opening air (openingAirFrames).
|
|
4923
|
+
const lead = cutawayLeadHold(c);
|
|
4924
|
+
const air = lead > 0 ? openingAirFrames(c.startSec, c.startSec + lead) : null;
|
|
4925
|
+
const from = air ? (air.first - 0.5) / FPS : c.startSec;
|
|
4926
|
+
const at = air ? (air.first + 0.5) / FPS : c.startSec;
|
|
4927
|
+
const held = air?.clones ? `,setpts=PTS-STARTPTS,tpad=start_mode=clone:start=${air.clones}` : "";
|
|
4864
4928
|
filters.push(
|
|
4865
|
-
`${norm(`${i}:v`)}${faster}${hold},trim=${c.inSec ? sec(c.inSec) : 0}:${sec((c.inSec ?? 0) + c.seconds)},setpts=PTS-STARTPTS+${sec(
|
|
4929
|
+
`${norm(`${i}:v`)}${faster}${hold},trim=${c.inSec ? sec(c.inSec) : 0}:${sec((c.inSec ?? 0) + c.seconds - lead)}${held},setpts=PTS-STARTPTS+${sec(at)}/TB[cv${j}]`,
|
|
4866
4930
|
);
|
|
4867
4931
|
// eof_action=pass keeps the spine showing once the cutaway's frames end.
|
|
4868
4932
|
filters.push(
|
|
4869
|
-
`[${videoLabel}][cv${j}]overlay=enable=between(t\\,${sec(
|
|
4933
|
+
`[${videoLabel}][cv${j}]overlay=enable=between(t\\,${sec(from)}\\,${sec(end)}):eof_action=pass[ov${j}]`,
|
|
4870
4934
|
);
|
|
4871
4935
|
videoLabel = `ov${j}`;
|
|
4872
4936
|
});
|
|
@@ -5272,6 +5336,8 @@ export function inTheCut(timeline) {
|
|
|
5272
5336
|
? "word times"
|
|
5273
5337
|
: `proportion: scene ${c.spineSceneIndex} has no word times`;
|
|
5274
5338
|
const cut = c.cutShortBy ? `, cut short where ${c.cutShortBy}` : "";
|
|
5339
|
+
// #4835: started with its scene, over the air before the scene's first word.
|
|
5340
|
+
const held = c.leadHoldSec > 0 ? `, its first frame held ${c.leadHoldSec.toFixed(2)}s from the start of scene ${c.spineSceneIndex ?? "under it"}` : "";
|
|
5275
5341
|
const covers = !c.broll
|
|
5276
5342
|
? ""
|
|
5277
5343
|
: c.coversFound
|
|
@@ -5281,7 +5347,7 @@ export function inTheCut(timeline) {
|
|
|
5281
5347
|
n: c.sceneIndex,
|
|
5282
5348
|
line:
|
|
5283
5349
|
`cutaway ${c.sceneIndex}: ${label} at ${c.startSec.toFixed(2)}s for ${c.seconds.toFixed(1)}s, ` +
|
|
5284
|
-
`cued to ${c.cueLineId} in scene ${c.spineSceneIndex} (${how})${covers}${cut}`,
|
|
5350
|
+
`cued to ${c.cueLineId} in scene ${c.spineSceneIndex} (${how})${covers}${held}${cut}`,
|
|
5285
5351
|
});
|
|
5286
5352
|
}
|
|
5287
5353
|
return rows.sort((a, b) => a.n - b.n).map((r) => r.line);
|