@koda-sl/baker-cli 0.293.0-dev.cf9d5462d → 0.295.0-dev.f941e60fb

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.
package/dist/cli.js CHANGED
@@ -16,6 +16,7 @@ import {
16
16
  RunAbortedError,
17
17
  SEEDANCE_DURATIONS,
18
18
  SEEDANCE_PROFILE,
19
+ SPOKEN_WORDS_PER_SECOND,
19
20
  VIDEO_GENERATE_MODELS,
20
21
  ValidationError,
21
22
  YtDlpError,
@@ -53,6 +54,7 @@ import {
53
54
  sha256Hex,
54
55
  spineInputFlags,
55
56
  spineInputOps,
57
+ spokenWordsIn,
56
58
  supportsLastFrame,
57
59
  supportsParam,
58
60
  supportsReferenceToVideo,
@@ -60,7 +62,7 @@ import {
60
62
  ulid,
61
63
  validateCanvasDeep,
62
64
  ytDlpBlockSignal
63
- } from "./chunk-LTXNRRXW.js";
65
+ } from "./chunk-ER3KCAW3.js";
64
66
  import {
65
67
  csvOrJson,
66
68
  daysAgoIso,
@@ -57379,6 +57381,15 @@ import { defineCommand as defineCommand208 } from "citty";
57379
57381
  // src/commands/studio/animate.ts
57380
57382
  import { defineCommand as defineCommand200 } from "citty";
57381
57383
 
57384
+ // src/commands/studio/avatarModel.ts
57385
+ function pinnedModelHint(input) {
57386
+ if (!input.avatar || !input.model) return null;
57387
+ if (input.model === DEFAULT_VIDEO_GENERATE_MODEL) return null;
57388
+ const speaks = input.generateAudio ?? true;
57389
+ if (!speaks) return null;
57390
+ return `You pinned --model ${input.model} on a speaking avatar. Without it this clip routes to ${DEFAULT_VIDEO_GENERATE_MODEL}, which was chosen for exactly this case: the better picture, both orientations, and audio always on. Drop --model unless the user asked for a specific one \u2014 and note ${input.model} may not take the length or the reference you are counting on.`;
57391
+ }
57392
+
57382
57393
  // src/commands/studio/batch.ts
57383
57394
  function projectBatch(generation, full) {
57384
57395
  const compact3 = {
@@ -57593,6 +57604,21 @@ function uploadFailure(path47) {
57593
57604
  };
57594
57605
  }
57595
57606
 
57607
+ // src/commands/studio/spokenPace.ts
57608
+ var WORDS_PER_SECOND2 = SPOKEN_WORDS_PER_SECOND;
57609
+ var spokenWords = spokenWordsIn;
57610
+ function wordsThatFit(seconds) {
57611
+ return Math.floor(seconds * WORDS_PER_SECOND2);
57612
+ }
57613
+ function spokenPaceHint(prompt, seconds) {
57614
+ if (!seconds) return null;
57615
+ const words2 = spokenWords(prompt);
57616
+ const fits = wordsThatFit(seconds);
57617
+ if (words2 === 0 || words2 <= fits) return null;
57618
+ const rate = (words2 / seconds).toFixed(1);
57619
+ return `The line is ${words2} words and this clip is ${seconds}s \u2014 that is ${rate} words a second against a natural 2.5. The model will not run over, it will RUSH: syllables swallowed, endings clipped, and the take unusable however good the picture. Cut the line to about ${fits} words, or give it the length it needs (${Math.ceil(words2 / 2.5)}s). Do not re-render the same line at the same length and hope.`;
57620
+ }
57621
+
57596
57622
  // src/commands/studio/animate.ts
57597
57623
  var MODEL_LIST = VIDEO_MODEL_IDS;
57598
57624
  var DEFAULT_MAX_WAIT_MS = 6e5;
@@ -57644,10 +57670,10 @@ registerSchema({
57644
57670
  },
57645
57671
  duration: {
57646
57672
  type: "number",
57647
- // Left unset this SNAPS onto the model's set rather than failing: the lane
57648
- // default is 5s and Veo renders only 4/6/8, so an unstated length becomes 4
57649
- // there. An explicit length the model cannot render is refused by name.
57650
- description: `Clip length in seconds \u2014 per-model. Unset it and the lane default (5s) snaps onto what the model renders. Past 15s only bytedance/seedance-2.5 will do it, out to 30. Across the roster: ${CLIP_DURATIONS.join(", ")}`,
57673
+ // Left unset this SNAPS onto the model's set rather than failing: Veo renders
57674
+ // only 4/6/8, so an unstated length lands on the nearest of those. An explicit
57675
+ // length the model cannot render is refused by name.
57676
+ description: `Clip length in seconds \u2014 per-model. LEAVE IT OFF when someone speaks: the line sizes the clip itself, at ~2.5 words a second (40 words needs 16s), because a model handed more words than fit does not run over, it rushes and swallows syllables. Unset with nobody speaking is 5s. Past 15s only bytedance/seedance-2.5 will do it, out to 30. Across the roster: ${CLIP_DURATIONS.join(", ")}`,
57651
57677
  required: false
57652
57678
  },
57653
57679
  quality: {
@@ -57821,6 +57847,10 @@ function costHintsFor(body) {
57821
57847
  const hints2 = [
57822
57848
  count === 1 ? `This clip costs about ${total} credits \u2014 roughly 45x an image.` : `${count} takes at about ${perTake} credits each \u2014 about ${total} credits.`
57823
57849
  ];
57850
+ const pinned = pinnedModelHint({ avatar: body.avatar, model: body.model, generateAudio: body.generateAudio });
57851
+ if (pinned) hints2.push(pinned);
57852
+ const pace = spokenPaceHint(body.prompt, body.duration);
57853
+ if (pace) hints2.push(pace);
57824
57854
  if (count > 1) {
57825
57855
  hints2.push(
57826
57856
  "Ask for more than one take only when the MOTION is the risk \u2014 for a look you are unsure about, iterate on the still first."
@@ -57864,7 +57894,7 @@ var animateCommand = defineCommand200({
57864
57894
  "aspect-ratio": { type: "string", description: "Aspect ratio (default 9:16)", required: false },
57865
57895
  duration: {
57866
57896
  type: "string",
57867
- description: `Seconds, per-model \u2014 unset snaps the 5s default onto the model's set. Roster: ${CLIP_DURATIONS.join(" | ")}`,
57897
+ description: `Seconds, per-model \u2014 leave it off when someone speaks and the line sizes it (~2.5 words/s); 5s when nobody does. Roster: ${CLIP_DURATIONS.join(" | ")}`,
57868
57898
  required: false
57869
57899
  },
57870
57900
  quality: {