@melius-ai/cli 0.52.0 → 0.53.0
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/README.md +1 -1
- package/dist/bin/mel.js +1 -1
- package/dist/{chunk-3RVBS56N.js → chunk-RQ7UAXLU.js} +838 -59
- package/dist/src/index.js +1 -1
- package/package.json +1 -1
|
@@ -10054,7 +10054,11 @@ var FileCardSchema = external_exports.object({
|
|
|
10054
10054
|
// Node/version to toggle when favoriting this asset from a Files surface.
|
|
10055
10055
|
favoriteNodeId: external_exports.string().uuid().nullable().optional(),
|
|
10056
10056
|
favoriteVersionId: external_exports.string().uuid().nullable().optional(),
|
|
10057
|
-
favoritedByUserId: external_exports.string().uuid().nullable().optional()
|
|
10057
|
+
favoritedByUserId: external_exports.string().uuid().nullable().optional(),
|
|
10058
|
+
/** The Cast take whose clip this file is, which the viewer may open, so
|
|
10059
|
+
* the Assets page can open it in Cast. Null for anything else. Optional so
|
|
10060
|
+
* a client released ahead of the server keeps validating. */
|
|
10061
|
+
castGenerationId: external_exports.string().uuid().nullable().optional()
|
|
10058
10062
|
});
|
|
10059
10063
|
var FileGenerationSchema = external_exports.object({
|
|
10060
10064
|
prompt: external_exports.string().nullable(),
|
|
@@ -12289,6 +12293,28 @@ var REMOVE_BACKGROUND_NODE_TOOL_NAME = "remove-background";
|
|
|
12289
12293
|
var BACKGROUND_REMOVAL_MODELS = ["pixelcut"];
|
|
12290
12294
|
var DEFAULT_BACKGROUND_REMOVAL_MODEL = "pixelcut";
|
|
12291
12295
|
var TOPAZ_UPSCALE_NODE_TOOL_NAME = "topaz-upscale";
|
|
12296
|
+
var ENHANCOR_SKIN_MODEL_VERSIONS = [
|
|
12297
|
+
"enhancorv4",
|
|
12298
|
+
"enhancorv4_base"
|
|
12299
|
+
];
|
|
12300
|
+
var ENHANCOR_SKIN_STRENGTHS = [
|
|
12301
|
+
"subtle",
|
|
12302
|
+
"realistic",
|
|
12303
|
+
"pimple",
|
|
12304
|
+
"freckle"
|
|
12305
|
+
];
|
|
12306
|
+
var ENHANCOR_FRECKLE_INTENSITIES = [50, 100];
|
|
12307
|
+
var EnhancorSkinToolConfigSchema = external_exports.object({
|
|
12308
|
+
model_version: external_exports.enum(ENHANCOR_SKIN_MODEL_VERSIONS).default("enhancorv4"),
|
|
12309
|
+
enhancement_strength: external_exports.enum(ENHANCOR_SKIN_STRENGTHS).default("realistic"),
|
|
12310
|
+
freckle_intensity: external_exports.union([
|
|
12311
|
+
external_exports.literal(ENHANCOR_FRECKLE_INTENSITIES[0]),
|
|
12312
|
+
external_exports.literal(ENHANCOR_FRECKLE_INTENSITIES[1])
|
|
12313
|
+
]).default(50),
|
|
12314
|
+
fast_mode: external_exports.boolean().default(false),
|
|
12315
|
+
fix_lighting_mode: external_exports.boolean().default(false)
|
|
12316
|
+
});
|
|
12317
|
+
var DEFAULT_ENHANCOR_SKIN_TOOL_CONFIG = EnhancorSkinToolConfigSchema.parse({});
|
|
12292
12318
|
var EDIT_REGIONS_MAX_REGIONS = 10;
|
|
12293
12319
|
var EDIT_REGIONS_MAX_NOTE_LENGTH = 800;
|
|
12294
12320
|
var EDIT_REGIONS_QUALITIES = ["low", "medium", "high"];
|
|
@@ -13177,8 +13203,88 @@ var CanvasPaginationErrorSchema = external_exports.object({
|
|
|
13177
13203
|
code: external_exports.literal("INVALID_CURSOR")
|
|
13178
13204
|
});
|
|
13179
13205
|
|
|
13206
|
+
// ../api-contract/src/cast/scenes.ts
|
|
13207
|
+
var CAST_SCENE_TIMES = ["present", "flashback", "later"];
|
|
13208
|
+
var CastSceneTimeSchema = external_exports.enum(CAST_SCENE_TIMES);
|
|
13209
|
+
var MAX_CAST_SCENE_PLACE_LENGTH = 500;
|
|
13210
|
+
var MAX_CAST_SCENE_LOOK_LENGTH = 500;
|
|
13211
|
+
var MAX_CAST_SCENE_TIME_LABEL_LENGTH = 80;
|
|
13212
|
+
var MAX_CAST_SCENE_LOOKS = 8;
|
|
13213
|
+
var CastSceneLookSchema = external_exports.object({
|
|
13214
|
+
/** The avatar entry id (`config.avatars[].id`), as a section's `speakerId`. */
|
|
13215
|
+
avatarId: external_exports.string().min(1).max(200),
|
|
13216
|
+
lookId: external_exports.string().uuid().optional(),
|
|
13217
|
+
look: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_LOOK_LENGTH).optional()
|
|
13218
|
+
}).refine((entry) => !(entry.lookId && entry.look), {
|
|
13219
|
+
message: "Name a look by lookId or describe it in look, not both"
|
|
13220
|
+
});
|
|
13221
|
+
var CastSceneHeadingSchema = external_exports.object({
|
|
13222
|
+
/** A place the series keeps. */
|
|
13223
|
+
placeId: external_exports.string().uuid().optional(),
|
|
13224
|
+
/** A place described in words, when the series keeps none for it. */
|
|
13225
|
+
place: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_PLACE_LENGTH).optional(),
|
|
13226
|
+
/** Absent is the present. */
|
|
13227
|
+
time: CastSceneTimeSchema.optional(),
|
|
13228
|
+
/** How far from the present, in the member's words: "10 years earlier". */
|
|
13229
|
+
timeLabel: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_TIME_LABEL_LENGTH).optional(),
|
|
13230
|
+
/** Each person's look from this scene on; a person left out keeps theirs. */
|
|
13231
|
+
looks: external_exports.array(CastSceneLookSchema).max(MAX_CAST_SCENE_LOOKS).optional()
|
|
13232
|
+
}).refine((heading) => !(heading.placeId && heading.place), {
|
|
13233
|
+
message: "Name a place by placeId or describe it in place, not both"
|
|
13234
|
+
});
|
|
13235
|
+
var CastLookChangesSchema = external_exports.array(CastSceneLookSchema).min(1).max(MAX_CAST_SCENE_LOOKS);
|
|
13236
|
+
var CastWrittenSceneLookSchema = external_exports.object({
|
|
13237
|
+
speaker: external_exports.string().trim().min(1).max(200),
|
|
13238
|
+
/** A look the series keeps, where the writer named one of its looks. */
|
|
13239
|
+
lookId: external_exports.string().uuid().optional(),
|
|
13240
|
+
/** The look's name, kept or new. */
|
|
13241
|
+
look: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_LOOK_LENGTH).optional(),
|
|
13242
|
+
/** A new look's description: what changes from the character sheet. */
|
|
13243
|
+
lookDescription: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_LOOK_LENGTH).optional()
|
|
13244
|
+
});
|
|
13245
|
+
var CastWrittenSceneHeadingSchema = external_exports.object({
|
|
13246
|
+
/** A place the series keeps, where the writer named one of its places. */
|
|
13247
|
+
placeId: external_exports.string().uuid().optional(),
|
|
13248
|
+
/** The place's name, kept or new. */
|
|
13249
|
+
place: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_PLACE_LENGTH).optional(),
|
|
13250
|
+
/** A new place's description, for drawing its picture. */
|
|
13251
|
+
placeDescription: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_PLACE_LENGTH).optional(),
|
|
13252
|
+
time: CastSceneTimeSchema.optional(),
|
|
13253
|
+
timeLabel: external_exports.string().trim().min(1).max(MAX_CAST_SCENE_TIME_LABEL_LENGTH).optional(),
|
|
13254
|
+
looks: external_exports.array(CastWrittenSceneLookSchema).max(MAX_CAST_SCENE_LOOKS).optional()
|
|
13255
|
+
});
|
|
13256
|
+
var CastWrittenLookChangesSchema = external_exports.array(CastWrittenSceneLookSchema).min(1).max(MAX_CAST_SCENE_LOOKS);
|
|
13257
|
+
var MAX_CAST_SCENE_READ_TEXT_LENGTH = 4e3;
|
|
13258
|
+
var MAX_CAST_SCENE_READ_SECTIONS = 300;
|
|
13259
|
+
var CastSceneReadSectionSchema = external_exports.object({
|
|
13260
|
+
text: external_exports.string().max(MAX_CAST_SCENE_READ_TEXT_LENGTH),
|
|
13261
|
+
action: external_exports.string().max(MAX_CAST_SCENE_READ_TEXT_LENGTH).optional(),
|
|
13262
|
+
scene: external_exports.string().max(MAX_CAST_SCENE_READ_TEXT_LENGTH).optional(),
|
|
13263
|
+
/** Who says it, by a `cast` name. */
|
|
13264
|
+
speaker: external_exports.string().trim().min(1).max(200).optional()
|
|
13265
|
+
});
|
|
13266
|
+
var ReadCastSeriesScenesBodySchema = external_exports.object({
|
|
13267
|
+
sections: external_exports.array(CastSceneReadSectionSchema).min(1).max(MAX_CAST_SCENE_READ_SECTIONS),
|
|
13268
|
+
cast: external_exports.array(
|
|
13269
|
+
external_exports.object({
|
|
13270
|
+
name: external_exports.string().trim().min(1).max(200),
|
|
13271
|
+
customAvatarId: external_exports.string().uuid().optional(),
|
|
13272
|
+
presetAvatarId: external_exports.string().uuid().optional(),
|
|
13273
|
+
elementId: external_exports.string().uuid().optional()
|
|
13274
|
+
})
|
|
13275
|
+
).min(1).max(MAX_CAST_SCENE_LOOKS)
|
|
13276
|
+
});
|
|
13277
|
+
var ReadCastSeriesScenesResponseSchema = external_exports.object({
|
|
13278
|
+
sections: external_exports.array(
|
|
13279
|
+
external_exports.object({
|
|
13280
|
+
heading: CastWrittenSceneHeadingSchema.optional(),
|
|
13281
|
+
lookChanges: CastWrittenLookChangesSchema.optional()
|
|
13282
|
+
})
|
|
13283
|
+
)
|
|
13284
|
+
});
|
|
13285
|
+
|
|
13180
13286
|
// ../api-contract/src/cast/creation.ts
|
|
13181
|
-
var CastVideoEngineSchema = external_exports.enum(["seedance"]);
|
|
13287
|
+
var CastVideoEngineSchema = external_exports.enum(["seedance", "seedance-fast"]);
|
|
13182
13288
|
var CastVideoStyleIdSchema = external_exports.enum([
|
|
13183
13289
|
"auto",
|
|
13184
13290
|
"self-filmed",
|
|
@@ -13216,7 +13322,8 @@ var CastVideoStyleIdSchema = external_exports.enum([
|
|
|
13216
13322
|
"product-stop-motion",
|
|
13217
13323
|
"asmr",
|
|
13218
13324
|
"claymation",
|
|
13219
|
-
"animated-2d"
|
|
13325
|
+
"animated-2d",
|
|
13326
|
+
"open-world-game"
|
|
13220
13327
|
]);
|
|
13221
13328
|
var CAST_VIDEO_STYLE_IDS = CastVideoStyleIdSchema.options;
|
|
13222
13329
|
var CAST_MICRODRAMA_STYLE_IDS = [
|
|
@@ -13260,6 +13367,9 @@ var CastCreationSettingsSchema = external_exports.object({
|
|
|
13260
13367
|
aesthetic: CastAestheticSchema.optional().describe(
|
|
13261
13368
|
"How self-filmed the video looks, on Auto, Self-filmed and Comment reply; other styles ignore it. Polished: a steady phone in soft, even light, focus holding. Natural: a propped phone with small camera flaws. Raw: the phone held in the hand, with shake, late autofocus and an uneven zoom. Set it only when the member asks for a polished, raw, handheld or shaky look; omitted means Natural."
|
|
13262
13369
|
),
|
|
13370
|
+
brandKit: external_exports.union([external_exports.literal("none"), external_exports.string().uuid()]).optional().describe(
|
|
13371
|
+
"The brand kit added visuals wear. Omitted is Auto: the team's kit the script names, else its default kit. none: graphics follow the script, with no brand colors, fonts or logo. A kit id picks that kit, which must be one of the team's kits in use. Visuals Off ignores it."
|
|
13372
|
+
),
|
|
13263
13373
|
visualsBrief: external_exports.string().trim().min(1).max(1e3).optional().describe(
|
|
13264
13374
|
"The member's direction for every added visual, in their words: look, colors, type, motion, mood and how many. Never filmed; it asks for added visuals, so Visuals must not be Off."
|
|
13265
13375
|
),
|
|
@@ -13321,7 +13431,14 @@ var CastAuthoredSectionSchema = external_exports.object({
|
|
|
13321
13431
|
* their words ("STOP slams in word by word"). Never filmed: the visuals
|
|
13322
13432
|
* pass answers it over the finished clip.
|
|
13323
13433
|
*/
|
|
13324
|
-
onScreen: external_exports.string().optional()
|
|
13434
|
+
onScreen: external_exports.string().optional(),
|
|
13435
|
+
/**
|
|
13436
|
+
* A Microdrama scene begins here (`places-and-looks-microdramas`): where it
|
|
13437
|
+
* happens, when, and how each person looks. It runs to the next heading.
|
|
13438
|
+
*/
|
|
13439
|
+
sceneHeading: CastSceneHeadingSchema.optional(),
|
|
13440
|
+
/** Looks that change after this section, inside its scene. */
|
|
13441
|
+
lookChanges: CastLookChangesSchema.optional()
|
|
13325
13442
|
});
|
|
13326
13443
|
function dropShotFieldsFromSpokenSections(sections) {
|
|
13327
13444
|
return sections.map((section) => {
|
|
@@ -13341,11 +13458,6 @@ function refuseShotFieldsOffShots(section, context2) {
|
|
|
13341
13458
|
code: external_exports.ZodIssueCode.custom,
|
|
13342
13459
|
message: 'cutaway and seconds belong to a silent action section (kind: "action")'
|
|
13343
13460
|
});
|
|
13344
|
-
else if (section.seconds !== void 0 && section.cutaway !== true)
|
|
13345
|
-
context2.addIssue({
|
|
13346
|
-
code: external_exports.ZodIssueCode.custom,
|
|
13347
|
-
message: "seconds is how long a Shot holds: set it only with cutaway: true"
|
|
13348
|
-
});
|
|
13349
13461
|
}
|
|
13350
13462
|
function refuseShotFieldsOffShotsInSections(sections, context2) {
|
|
13351
13463
|
for (const section of sections) refuseShotFieldsOffShots(section, context2);
|
|
@@ -13695,6 +13807,40 @@ var CastScriptReferencesSchema = external_exports.array(
|
|
|
13695
13807
|
name: external_exports.string().trim().min(1).max(MAX_CAST_SCRIPT_REFERENCE_NAME_LENGTH)
|
|
13696
13808
|
})
|
|
13697
13809
|
).max(MAX_CAST_SCRIPT_REFERENCES).optional();
|
|
13810
|
+
var CastScriptSectionSchema = external_exports.object({
|
|
13811
|
+
title: external_exports.string().trim().min(1).max(MAX_CAST_SECTION_TITLE_LENGTH),
|
|
13812
|
+
/** The words said across the beat — empty only on an action beat. */
|
|
13813
|
+
text: external_exports.string().trim(),
|
|
13814
|
+
/**
|
|
13815
|
+
* What the presenter does while the beat is spoken, when the words
|
|
13816
|
+
* imply it. Direction for the picture, never part of the read.
|
|
13817
|
+
*/
|
|
13818
|
+
action: external_exports.string().trim().min(1).max(MAX_CAST_SECTION_ACTION_LENGTH).optional(),
|
|
13819
|
+
/** The setting and visual direction for this beat, separate from speech. */
|
|
13820
|
+
scene: external_exports.string().max(4e3).optional(),
|
|
13821
|
+
/**
|
|
13822
|
+
* `action`: a beat with nothing said across it — a production script's
|
|
13823
|
+
* visual-only beat. Absent means a spoken beat.
|
|
13824
|
+
*/
|
|
13825
|
+
kind: external_exports.enum(["action"]).optional(),
|
|
13826
|
+
/** On an action beat, a Shot: nobody from the cast is its subject. */
|
|
13827
|
+
cutaway: external_exports.literal(true).optional(),
|
|
13828
|
+
/** On an action beat, how long it holds in whole seconds. */
|
|
13829
|
+
seconds: external_exports.number().int().min(1).max(CAST_MAX_ACTION_BEAT_SECONDS).optional(),
|
|
13830
|
+
/**
|
|
13831
|
+
* Who says it, as the request's `speakers` spell the name. Only on a
|
|
13832
|
+
* split or a draft asked with a cast.
|
|
13833
|
+
*/
|
|
13834
|
+
speaker: external_exports.string().optional(),
|
|
13835
|
+
/** A Microdrama episode's scene begins here; only the episode writer writes one. */
|
|
13836
|
+
heading: CastWrittenSceneHeadingSchema.optional(),
|
|
13837
|
+
/** Looks that change after this beat, inside its scene. */
|
|
13838
|
+
lookChanges: CastWrittenLookChangesSchema.optional()
|
|
13839
|
+
}).refine((section) => section.kind === "action" || section.text.length > 0, {
|
|
13840
|
+
message: "A spoken beat needs words",
|
|
13841
|
+
path: ["text"]
|
|
13842
|
+
});
|
|
13843
|
+
var MAX_PREPARED_CAST_SCRIPT_SECTIONS = 100;
|
|
13698
13844
|
var CastScriptTreatmentSchema = external_exports.discriminatedUnion("operation", [
|
|
13699
13845
|
/** Same words, better writing: no delivery tags, no restructure into beats. */
|
|
13700
13846
|
external_exports.object({ operation: external_exports.literal("rewrite") }),
|
|
@@ -13793,6 +13939,26 @@ var CastScriptTreatmentSchema = external_exports.discriminatedUnion("operation",
|
|
|
13793
13939
|
* read to the camera. Absent writes a read to the camera.
|
|
13794
13940
|
*/
|
|
13795
13941
|
videoStyle: CastVideoStyleSchema.optional()
|
|
13942
|
+
}),
|
|
13943
|
+
/**
|
|
13944
|
+
* The member's script, cut to fit a length the team's credits cover: the
|
|
13945
|
+
* same speakers and claims in fewer words. `prompt` carries the spoken
|
|
13946
|
+
* script; the beats carry who says what and what they do.
|
|
13947
|
+
*/
|
|
13948
|
+
external_exports.object({
|
|
13949
|
+
operation: external_exports.literal("shorten"),
|
|
13950
|
+
seconds: CastDraftSecondsSchema,
|
|
13951
|
+
sections: external_exports.array(
|
|
13952
|
+
// An action beat's own seconds count toward the slot.
|
|
13953
|
+
CastScriptSectionSchema.and(
|
|
13954
|
+
external_exports.object({
|
|
13955
|
+
seconds: CastAuthoredSectionSchema.shape.seconds
|
|
13956
|
+
})
|
|
13957
|
+
)
|
|
13958
|
+
).min(1).max(MAX_PREPARED_CAST_SCRIPT_SECTIONS),
|
|
13959
|
+
speakers: CastScriptSpeakersSchema,
|
|
13960
|
+
/** A style whose people talk to each other (Microdrama) is cut as a scene. */
|
|
13961
|
+
videoStyle: CastVideoStyleSchema.optional()
|
|
13796
13962
|
})
|
|
13797
13963
|
]);
|
|
13798
13964
|
var EnhancePromptBodySchema = external_exports.object({
|
|
@@ -13816,33 +13982,6 @@ var EnhanceScriptBodySchema = external_exports.object({
|
|
|
13816
13982
|
*/
|
|
13817
13983
|
castTreatment: CastScriptTreatmentSchema.optional()
|
|
13818
13984
|
});
|
|
13819
|
-
var CastScriptSectionSchema = external_exports.object({
|
|
13820
|
-
title: external_exports.string().trim().min(1).max(MAX_CAST_SECTION_TITLE_LENGTH),
|
|
13821
|
-
/** The words said across the beat — empty only on an action beat. */
|
|
13822
|
-
text: external_exports.string().trim(),
|
|
13823
|
-
/**
|
|
13824
|
-
* What the presenter does while the beat is spoken, when the words
|
|
13825
|
-
* imply it. Direction for the picture, never part of the read.
|
|
13826
|
-
*/
|
|
13827
|
-
action: external_exports.string().trim().min(1).max(MAX_CAST_SECTION_ACTION_LENGTH).optional(),
|
|
13828
|
-
/** The setting and visual direction for this beat, separate from speech. */
|
|
13829
|
-
scene: external_exports.string().max(4e3).optional(),
|
|
13830
|
-
/**
|
|
13831
|
-
* `action`: a beat with nothing said across it — a production script's
|
|
13832
|
-
* visual-only beat. Absent means a spoken beat.
|
|
13833
|
-
*/
|
|
13834
|
-
kind: external_exports.enum(["action"]).optional(),
|
|
13835
|
-
/** On an action beat, a Shot: nobody from the cast is its subject. */
|
|
13836
|
-
cutaway: external_exports.literal(true).optional(),
|
|
13837
|
-
/**
|
|
13838
|
-
* Who says it, as the request's `speakers` spell the name. Only on a
|
|
13839
|
-
* split or a draft asked with a cast.
|
|
13840
|
-
*/
|
|
13841
|
-
speaker: external_exports.string().optional()
|
|
13842
|
-
}).refine((section) => section.kind === "action" || section.text.length > 0, {
|
|
13843
|
-
message: "A spoken beat needs words",
|
|
13844
|
-
path: ["text"]
|
|
13845
|
-
});
|
|
13846
13985
|
var PrepareCastScriptBodySchema = external_exports.object({
|
|
13847
13986
|
prompt: external_exports.string().trim().min(1).max(MAX_PROMPT_ENHANCE_INPUT_LENGTH),
|
|
13848
13987
|
engine: CastVideoEngineSchema,
|
|
@@ -13853,7 +13992,6 @@ var PrepareCastScriptBodySchema = external_exports.object({
|
|
|
13853
13992
|
references: CastScriptReferencesSchema,
|
|
13854
13993
|
longVideo: external_exports.boolean()
|
|
13855
13994
|
});
|
|
13856
|
-
var MAX_PREPARED_CAST_SCRIPT_SECTIONS = 100;
|
|
13857
13995
|
var PrepareCastScriptResponseSchema = external_exports.object({
|
|
13858
13996
|
sections: external_exports.array(CastScriptSectionSchema).min(1).max(MAX_PREPARED_CAST_SCRIPT_SECTIONS),
|
|
13859
13997
|
requestedSeconds: external_exports.number().positive().nullable(),
|
|
@@ -13862,8 +14000,8 @@ var PrepareCastScriptResponseSchema = external_exports.object({
|
|
|
13862
14000
|
var EnhanceScriptResponseSchema = external_exports.object({
|
|
13863
14001
|
prompt: external_exports.string(),
|
|
13864
14002
|
/**
|
|
13865
|
-
* Present for the
|
|
13866
|
-
* `draft`. Both echo their input back as `prompt`, a split because it does
|
|
14003
|
+
* Present for the operations that answer in beats — `split`, `sort`,
|
|
14004
|
+
* `draft` and `shorten`. Both echo their input back as `prompt`, a split because it does
|
|
13867
14005
|
* not rewrite the script and a draft because the brief is not the answer;
|
|
13868
14006
|
* the beats are. Optional rather than a second response shape: every other
|
|
13869
14007
|
* operation returns `prompt` alone, which is what this endpoint has always
|
|
@@ -14181,6 +14319,7 @@ var CastTemplateReferenceSchema = external_exports.object({
|
|
|
14181
14319
|
|
|
14182
14320
|
// ../api-contract/src/cast/video.ts
|
|
14183
14321
|
var CAST_VIDEO_MAX_PROPS = 6;
|
|
14322
|
+
var MAX_CAST_VIDEO_SECTIONS = 300;
|
|
14184
14323
|
var CastVideoAvatarSchema = external_exports.object({
|
|
14185
14324
|
kind: external_exports.enum(["custom", "curated", "element"]),
|
|
14186
14325
|
id: external_exports.string().uuid()
|
|
@@ -14240,7 +14379,7 @@ var CastVideoInputSchema = external_exports.object({
|
|
|
14240
14379
|
*/
|
|
14241
14380
|
continues: external_exports.boolean().optional()
|
|
14242
14381
|
}).strict().superRefine(refuseShotFieldsOffShots)
|
|
14243
|
-
).min(1).max(
|
|
14382
|
+
).min(1).max(MAX_CAST_VIDEO_SECTIONS),
|
|
14244
14383
|
backgroundId: external_exports.string().uuid().optional(),
|
|
14245
14384
|
propAssetId: external_exports.string().uuid().optional(),
|
|
14246
14385
|
propName: external_exports.string().max(200).optional(),
|
|
@@ -14279,6 +14418,8 @@ var CastVideoReviewSchema = external_exports.object({
|
|
|
14279
14418
|
visuals: external_exports.string().optional(),
|
|
14280
14419
|
/** Auto or One shot, for a member offered Camera (`cast-one-shot`); absent otherwise. */
|
|
14281
14420
|
camera: external_exports.string().optional(),
|
|
14421
|
+
/** Polished, Natural or Raw, for a member offered Aesthetic (`cast-aesthetic`) in a style that takes it; absent otherwise. */
|
|
14422
|
+
aesthetic: external_exports.string().optional(),
|
|
14282
14423
|
/** What preparation changed from the request, said where the member reviews it. */
|
|
14283
14424
|
notice: external_exports.string().optional(),
|
|
14284
14425
|
/** Everyone the video casts, `avatar` first, where it casts several. */
|
|
@@ -14298,7 +14439,24 @@ var preparation = external_exports.object({
|
|
|
14298
14439
|
scriptSeconds: external_exports.number().nonnegative(),
|
|
14299
14440
|
aspectRatios: external_exports.array(OutputAspectRatioSchema),
|
|
14300
14441
|
estimatedWait: external_exports.string().optional(),
|
|
14301
|
-
visualsUnavailableReason: external_exports.string().optional()
|
|
14442
|
+
visualsUnavailableReason: external_exports.string().optional(),
|
|
14443
|
+
/**
|
|
14444
|
+
* The scenes the video films, in order, where it films a Microdrama
|
|
14445
|
+
* series' scenes (`places-and-looks-microdramas`): where each begins, its place
|
|
14446
|
+
* and time, and each person's look there.
|
|
14447
|
+
*/
|
|
14448
|
+
scenes: external_exports.array(
|
|
14449
|
+
external_exports.object({
|
|
14450
|
+
/** The section, from 0, its heading is on. */
|
|
14451
|
+
startsAtSection: external_exports.number().int().min(0),
|
|
14452
|
+
place: external_exports.string().nullable(),
|
|
14453
|
+
time: CastSceneTimeSchema,
|
|
14454
|
+
timeLabel: external_exports.string().optional(),
|
|
14455
|
+
looks: external_exports.array(
|
|
14456
|
+
external_exports.object({ avatarId: external_exports.string(), look: external_exports.string() })
|
|
14457
|
+
)
|
|
14458
|
+
})
|
|
14459
|
+
).optional()
|
|
14302
14460
|
});
|
|
14303
14461
|
var PrepareCastVideoResponseSchema = external_exports.discriminatedUnion("status", [
|
|
14304
14462
|
preparation.extend({
|
|
@@ -14315,6 +14473,7 @@ var PrepareCastVideoResponseSchema = external_exports.discriminatedUnion("status
|
|
|
14315
14473
|
estimatedCredits: external_exports.null()
|
|
14316
14474
|
})
|
|
14317
14475
|
]);
|
|
14476
|
+
var CastStudioWorkSchema = external_exports.object({ workId: external_exports.string().uuid(), rootWorkId: external_exports.string().uuid() }).strict();
|
|
14318
14477
|
var RunCastVideoBodySchema = external_exports.object({
|
|
14319
14478
|
attemptId: external_exports.string().uuid(),
|
|
14320
14479
|
preparationToken: external_exports.string().uuid().optional(),
|
|
@@ -14329,7 +14488,12 @@ var RunCastVideoBodySchema = external_exports.object({
|
|
|
14329
14488
|
*/
|
|
14330
14489
|
collectionId: external_exports.string().uuid().optional(),
|
|
14331
14490
|
/** Make another take of this episode of a series collection. */
|
|
14332
|
-
episodeId: external_exports.string().uuid().optional()
|
|
14491
|
+
episodeId: external_exports.string().uuid().optional(),
|
|
14492
|
+
/**
|
|
14493
|
+
* The studio session the video continues (the analytics' `workId` and
|
|
14494
|
+
* `rootWorkId`), so History stacks it with that session's takes.
|
|
14495
|
+
*/
|
|
14496
|
+
studioWork: CastStudioWorkSchema.optional()
|
|
14333
14497
|
}).strict();
|
|
14334
14498
|
var CastPreparedVideoQuoteSchema = external_exports.object({
|
|
14335
14499
|
estimatedCredits: external_exports.number().finite().nonnegative()
|
|
@@ -14655,6 +14819,12 @@ var AgentInFlightEntrySchema = external_exports.discriminatedUnion("type", [
|
|
|
14655
14819
|
summary: external_exports.string(),
|
|
14656
14820
|
status: external_exports.enum(["running", "complete", "error"]),
|
|
14657
14821
|
error: external_exports.string().optional(),
|
|
14822
|
+
/**
|
|
14823
|
+
* Tool call input, present only for tools whose chat row is named
|
|
14824
|
+
* and grouped from it. A snapshot without it shows the tool's own
|
|
14825
|
+
* label.
|
|
14826
|
+
*/
|
|
14827
|
+
input: external_exports.unknown().optional(),
|
|
14658
14828
|
/**
|
|
14659
14829
|
* Tool result payload, present only for tools whose result is
|
|
14660
14830
|
* worth rendering inline (currently `web_search`). Other tools
|
|
@@ -14910,6 +15080,9 @@ function describeCreditShortfall(shortfall) {
|
|
|
14910
15080
|
// ../api-contract/src/credit-refusal.ts
|
|
14911
15081
|
var MEMBER_CREDIT_LIMIT_ERROR_CODE = "MEMBER_CREDIT_LIMIT";
|
|
14912
15082
|
|
|
15083
|
+
// ../api-contract/src/task-budget/refusal.ts
|
|
15084
|
+
var TASK_BUDGET_EXCEEDED_ERROR_CODE = "TASK_BUDGET_EXCEEDED";
|
|
15085
|
+
|
|
14913
15086
|
// ../api-contract/src/errors.ts
|
|
14914
15087
|
var API_ERROR_CODE = {
|
|
14915
15088
|
projectNameTaken: "PROJECT_NAME_TAKEN",
|
|
@@ -14933,6 +15106,8 @@ var API_ERROR_CODE = {
|
|
|
14933
15106
|
insufficientCredits: INSUFFICIENT_CREDITS_ERROR_CODE,
|
|
14934
15107
|
/** The member's own credit limit can't cover the run; an admin can raise it. */
|
|
14935
15108
|
memberCreditLimit: MEMBER_CREDIT_LIMIT_ERROR_CODE,
|
|
15109
|
+
/** The run costs more than its task budget has left; only the member raises the limit. */
|
|
15110
|
+
taskBudgetExceeded: TASK_BUDGET_EXCEEDED_ERROR_CODE,
|
|
14936
15111
|
/** The team is not in the Ditto beta; the client offers the waitlist. */
|
|
14937
15112
|
dittoBetaRequired: "DITTO_BETA_REQUIRED",
|
|
14938
15113
|
/** The Ditto template was retired or deleted; the client asks for another video. */
|
|
@@ -15666,6 +15841,90 @@ var CastSubtitledFromSchema = external_exports.object({
|
|
|
15666
15841
|
generationId: external_exports.string().uuid()
|
|
15667
15842
|
});
|
|
15668
15843
|
|
|
15844
|
+
// ../api-contract/src/cast/trim-take.ts
|
|
15845
|
+
var CAST_TRIM_MIN_DURATION_MS = 500;
|
|
15846
|
+
var TrimCastGenerationBodySchema = external_exports.object({
|
|
15847
|
+
/** Where the kept part starts, in milliseconds from the clip's start. */
|
|
15848
|
+
startTimeMs: external_exports.number().int().nonnegative(),
|
|
15849
|
+
/** Where the kept part ends; after `startTimeMs`, within the clip. */
|
|
15850
|
+
endTimeMs: external_exports.number().int().positive()
|
|
15851
|
+
}).refine(
|
|
15852
|
+
(range) => range.endTimeMs - range.startTimeMs >= CAST_TRIM_MIN_DURATION_MS,
|
|
15853
|
+
{
|
|
15854
|
+
message: "Keep at least half a second of the video",
|
|
15855
|
+
path: ["endTimeMs"]
|
|
15856
|
+
}
|
|
15857
|
+
);
|
|
15858
|
+
var CastTrimmedFromSchema = external_exports.object({
|
|
15859
|
+
generationId: external_exports.string().uuid()
|
|
15860
|
+
});
|
|
15861
|
+
|
|
15862
|
+
// ../pricing/src/model-rate-card.ts
|
|
15863
|
+
var MODEL_RATE_UNITS = [
|
|
15864
|
+
"second",
|
|
15865
|
+
"image",
|
|
15866
|
+
"video",
|
|
15867
|
+
"minute",
|
|
15868
|
+
"million-tokens"
|
|
15869
|
+
];
|
|
15870
|
+
|
|
15871
|
+
// ../api-contract/src/generation/customer-model-pricing.ts
|
|
15872
|
+
var ContractDecimalSchema = external_exports.string().regex(/^\d{1,9}(\.\d{1,6})?$/);
|
|
15873
|
+
var ModelRateUnitSchema = external_exports.enum(MODEL_RATE_UNITS);
|
|
15874
|
+
var ModelRateSelectorSchema = external_exports.object({
|
|
15875
|
+
mode: external_exports.string().min(1),
|
|
15876
|
+
tier: external_exports.string().min(1).optional(),
|
|
15877
|
+
resolution: external_exports.string().min(1).optional(),
|
|
15878
|
+
audio: external_exports.enum(["on", "off"]).optional(),
|
|
15879
|
+
quality: external_exports.string().min(1).optional()
|
|
15880
|
+
});
|
|
15881
|
+
var ModelContractPriceSchema = external_exports.discriminatedUnion("kind", [
|
|
15882
|
+
external_exports.object({
|
|
15883
|
+
kind: external_exports.literal("percent"),
|
|
15884
|
+
percent: ContractDecimalSchema.refine((value) => Number(value) <= 100),
|
|
15885
|
+
basis: external_exports.enum(["unit", "token"])
|
|
15886
|
+
}),
|
|
15887
|
+
external_exports.object({
|
|
15888
|
+
kind: external_exports.literal("target"),
|
|
15889
|
+
usd: ContractDecimalSchema,
|
|
15890
|
+
unit: ModelRateUnitSchema
|
|
15891
|
+
})
|
|
15892
|
+
]);
|
|
15893
|
+
var CustomerModelPricingSchema = external_exports.object({
|
|
15894
|
+
defaultSelector: ModelRateSelectorSchema,
|
|
15895
|
+
creditUsdPerThousand: ContractDecimalSchema.nullable(),
|
|
15896
|
+
rows: external_exports.array(
|
|
15897
|
+
external_exports.object({
|
|
15898
|
+
selector: ModelRateSelectorSchema,
|
|
15899
|
+
price: ModelContractPriceSchema,
|
|
15900
|
+
nativeCreditsPerMillionTokens: external_exports.number().nonnegative().optional()
|
|
15901
|
+
})
|
|
15902
|
+
),
|
|
15903
|
+
tokenFormula: external_exports.object({
|
|
15904
|
+
kind: external_exports.literal("video-frame-tokens"),
|
|
15905
|
+
unit: external_exports.literal("1000 tokens"),
|
|
15906
|
+
framesPerSecond: external_exports.number().positive(),
|
|
15907
|
+
extraFrames: external_exports.number().nonnegative(),
|
|
15908
|
+
pixelsPerToken: external_exports.number().positive(),
|
|
15909
|
+
inputVideoSecondsBilled: external_exports.boolean(),
|
|
15910
|
+
inputVideoSecondsRoundedDown: external_exports.literal(true).optional(),
|
|
15911
|
+
frameSizes: external_exports.record(
|
|
15912
|
+
external_exports.string(),
|
|
15913
|
+
external_exports.record(
|
|
15914
|
+
external_exports.string(),
|
|
15915
|
+
external_exports.object({
|
|
15916
|
+
width: external_exports.number().positive(),
|
|
15917
|
+
height: external_exports.number().positive()
|
|
15918
|
+
})
|
|
15919
|
+
)
|
|
15920
|
+
)
|
|
15921
|
+
}).optional(),
|
|
15922
|
+
inputVideoCreditMultiplier: external_exports.number().nonnegative(),
|
|
15923
|
+
legacyDiscountPercent: external_exports.number(),
|
|
15924
|
+
alternativeDiscountPercent: external_exports.number(),
|
|
15925
|
+
runDiscountPercent: external_exports.number()
|
|
15926
|
+
});
|
|
15927
|
+
|
|
15669
15928
|
// ../api-contract/src/generation/schema.ts
|
|
15670
15929
|
var InputFileSizeConstraintsResponseSchema = external_exports.object({
|
|
15671
15930
|
maximumFileBytes: external_exports.number().int().nonnegative().optional(),
|
|
@@ -15951,6 +16210,28 @@ var ImageInputSurchargeSchema = external_exports.object({
|
|
|
15951
16210
|
includedInputCount: external_exports.number(),
|
|
15952
16211
|
perOutputSecond: external_exports.boolean()
|
|
15953
16212
|
});
|
|
16213
|
+
var ReferenceTokenSurchargeSchema = external_exports.object({
|
|
16214
|
+
creditCostPerTokenUnit: external_exports.number(),
|
|
16215
|
+
includedTokenCount: external_exports.number(),
|
|
16216
|
+
tokenUnit: external_exports.number(),
|
|
16217
|
+
imageShortSidePatches: external_exports.number(),
|
|
16218
|
+
imageMaximumAspectRatio: external_exports.number(),
|
|
16219
|
+
fallbackTokenCountPerImage: external_exports.number(),
|
|
16220
|
+
audioTokensPerSecond: external_exports.number(),
|
|
16221
|
+
frameCanvasShortSidePixelsByResolution: external_exports.record(external_exports.string(), external_exports.number()),
|
|
16222
|
+
video: external_exports.object({
|
|
16223
|
+
patchSizePixels: external_exports.number(),
|
|
16224
|
+
canvasShortSidePixelsByResolution: external_exports.record(external_exports.string(), external_exports.number()),
|
|
16225
|
+
latentFramesBySeconds: external_exports.array(external_exports.tuple([external_exports.number(), external_exports.number()])),
|
|
16226
|
+
fallbackAspectRatio: external_exports.number()
|
|
16227
|
+
}),
|
|
16228
|
+
/** Whether a wired start frame is sent to the provider, and so counted. */
|
|
16229
|
+
sendsStartFrame: external_exports.boolean(),
|
|
16230
|
+
/** Whether a wired end frame is sent to the provider, and so counted. */
|
|
16231
|
+
sendsEndFrame: external_exports.boolean(),
|
|
16232
|
+
/** The start frame's shape, not the requested ratio, shapes the frames' canvas. */
|
|
16233
|
+
startFrameSetsAspectRatio: external_exports.boolean()
|
|
16234
|
+
});
|
|
15954
16235
|
var InputImageDimensionConstraintsResponseSchema = external_exports.object({
|
|
15955
16236
|
minimumWidth: external_exports.number().int().nonnegative(),
|
|
15956
16237
|
minimumHeight: external_exports.number().int().nonnegative(),
|
|
@@ -16116,6 +16397,8 @@ var ModelVariantResponseSchema = external_exports.object({
|
|
|
16116
16397
|
defaultResolution: OutputResolutionSchema.nullable().optional(),
|
|
16117
16398
|
featuredDescription: external_exports.string().nullable(),
|
|
16118
16399
|
cost: ModelCostSchema.optional(),
|
|
16400
|
+
/** Team contract prices by setting; catalog cost remains the undiscounted basis. */
|
|
16401
|
+
customerPricing: CustomerModelPricingSchema.optional(),
|
|
16119
16402
|
/** `cost` before the team's model discount; set only when the team has one. */
|
|
16120
16403
|
listCost: ModelCostSchema.optional(),
|
|
16121
16404
|
/** Selectable voices for audio variants, or null when none apply. */
|
|
@@ -16130,7 +16413,14 @@ var ModelVariantResponseSchema = external_exports.object({
|
|
|
16130
16413
|
* Null when the price covers every image. Optional only so a client can
|
|
16131
16414
|
* read a server that predates it.
|
|
16132
16415
|
*/
|
|
16133
|
-
imageInputSurcharge: ImageInputSurchargeSchema.nullable().optional()
|
|
16416
|
+
imageInputSurcharge: ImageInputSurchargeSchema.nullable().optional(),
|
|
16417
|
+
/**
|
|
16418
|
+
* With billed input video, the fewest output lengths a run is charged:
|
|
16419
|
+
* the total is never under the output's price times this.
|
|
16420
|
+
*/
|
|
16421
|
+
minimumBilledOutputMultiple: external_exports.number().optional(),
|
|
16422
|
+
/** Null when the price covers every reference. */
|
|
16423
|
+
referenceTokenSurcharge: ReferenceTokenSurchargeSchema.nullable().optional()
|
|
16134
16424
|
});
|
|
16135
16425
|
var ModelResponseSchema = external_exports.object({
|
|
16136
16426
|
/** Whether wired audio can be played as recorded, rather than used only as a voice sample. */
|
|
@@ -16588,6 +16878,12 @@ var PresetAvatarSummarySchema = external_exports.object({
|
|
|
16588
16878
|
* resized; absent from a server that predates it.
|
|
16589
16879
|
*/
|
|
16590
16880
|
thumbnailUrl: external_exports.string().nullable().optional(),
|
|
16881
|
+
/**
|
|
16882
|
+
* The same picture at a card's width, for a tile wider than the
|
|
16883
|
+
* thumbnail. The counterpart of a team-made avatar's `cardUrl`; null and
|
|
16884
|
+
* absent on the same terms as `thumbnailUrl`.
|
|
16885
|
+
*/
|
|
16886
|
+
cardUrl: external_exports.string().nullable().optional(),
|
|
16591
16887
|
defaultVoice: PresetAvatarDefaultVoiceSchema.nullable(),
|
|
16592
16888
|
/**
|
|
16593
16889
|
* @deprecated Always empty. Melius curates avatars, not places — a team
|
|
@@ -16731,6 +17027,22 @@ var CastExploreVideoSchema = external_exports.object({
|
|
|
16731
17027
|
* so a client reading from a server that predates featuring shows none.
|
|
16732
17028
|
*/
|
|
16733
17029
|
featured: external_exports.boolean().optional(),
|
|
17030
|
+
/**
|
|
17031
|
+
* Staff feature it on its use case's row on the Cast home, kept apart
|
|
17032
|
+
* from `featured`. Optional so a server that predates it marks none.
|
|
17033
|
+
*/
|
|
17034
|
+
homeRowFeatured: external_exports.boolean().optional(),
|
|
17035
|
+
/**
|
|
17036
|
+
* Staff feature it on its ad type's or genre's row on its use case's
|
|
17037
|
+
* page. Optional so a server that predates it marks none.
|
|
17038
|
+
*/
|
|
17039
|
+
sectionFeatured: external_exports.boolean().optional(),
|
|
17040
|
+
/**
|
|
17041
|
+
* Staff picked it for business teams, and the reader's team is one: its
|
|
17042
|
+
* owner signs in with a company email, or staff set it so. Absent for
|
|
17043
|
+
* any other reader and from a server that predates business picks.
|
|
17044
|
+
*/
|
|
17045
|
+
businessPick: external_exports.boolean().optional(),
|
|
16734
17046
|
/**
|
|
16735
17047
|
* The tab staff listed it under. Absent until they choose one, and from
|
|
16736
17048
|
* a server that predates use cases.
|
|
@@ -16760,6 +17072,26 @@ var SearchCastExploreBodySchema = createCursorPaginationRequestSchema({
|
|
|
16760
17072
|
* predates it lists every video, so a client keeps those with `featured`.
|
|
16761
17073
|
*/
|
|
16762
17074
|
featured: external_exports.boolean().optional(),
|
|
17075
|
+
/**
|
|
17076
|
+
* True lists only the videos staff feature on their use case's row on the
|
|
17077
|
+
* Cast home, in staff order; pair it with `useCase` for one row. A server
|
|
17078
|
+
* that predates it lists every video, so a client keeps those with
|
|
17079
|
+
* `homeRowFeatured`.
|
|
17080
|
+
*/
|
|
17081
|
+
homeRowFeatured: external_exports.boolean().optional(),
|
|
17082
|
+
/**
|
|
17083
|
+
* True lists only the videos staff feature on their ad type's or genre's
|
|
17084
|
+
* row on their use case's page, in staff order within each row; pair it
|
|
17085
|
+
* with `useCase` for one page. A server that predates it lists every
|
|
17086
|
+
* video, so a client keeps those with `sectionFeatured`.
|
|
17087
|
+
*/
|
|
17088
|
+
sectionFeatured: external_exports.boolean().optional(),
|
|
17089
|
+
/**
|
|
17090
|
+
* True lists only the reader's business picks (`businessPick`); a reader
|
|
17091
|
+
* whose team is not a business team gets none. A server that predates it
|
|
17092
|
+
* lists every video, so a client keeps those with `businessPick`.
|
|
17093
|
+
*/
|
|
17094
|
+
businessPicks: external_exports.boolean().optional(),
|
|
16763
17095
|
/**
|
|
16764
17096
|
* One tab's videos only. A server that predates it lists every video, so
|
|
16765
17097
|
* a client keeps those whose `useCase` matches.
|
|
@@ -16779,6 +17111,35 @@ var SearchCastExploreBodySchema = createCursorPaginationRequestSchema({
|
|
|
16779
17111
|
var CastExplorePageSchema = createPaginatedResponseSchema(
|
|
16780
17112
|
CastExploreVideoSchema
|
|
16781
17113
|
);
|
|
17114
|
+
var CastExampleSeriesSchema = external_exports.object({
|
|
17115
|
+
id: external_exports.string().uuid(),
|
|
17116
|
+
title: external_exports.string().min(1).max(200),
|
|
17117
|
+
/** Its row: a Microdrama genre is its look. */
|
|
17118
|
+
genre: CastGenreSchema,
|
|
17119
|
+
episodeCount: external_exports.number().int().nonnegative(),
|
|
17120
|
+
/** Episode 1's poster and a small silent copy to play on the card; null until it has one. */
|
|
17121
|
+
cover: external_exports.object({
|
|
17122
|
+
posterUrl: external_exports.string().url(),
|
|
17123
|
+
previewVideoUrl: external_exports.string().url().optional()
|
|
17124
|
+
}).nullable()
|
|
17125
|
+
});
|
|
17126
|
+
var CastExampleSeriesEpisodeSchema = external_exports.object({
|
|
17127
|
+
number: external_exports.number().int().positive(),
|
|
17128
|
+
/** The take it shows, which a reader's own series remixes Episode 1 from. */
|
|
17129
|
+
generationId: external_exports.string().uuid(),
|
|
17130
|
+
videoUrl: external_exports.string().url(),
|
|
17131
|
+
posterUrl: external_exports.string().url().optional(),
|
|
17132
|
+
/** Absent when the take does not record them; a reader draws 9:16. */
|
|
17133
|
+
width: external_exports.number().int().positive().optional(),
|
|
17134
|
+
height: external_exports.number().int().positive().optional()
|
|
17135
|
+
});
|
|
17136
|
+
var MAX_CAST_EXAMPLE_SERIES_EPISODES = 100;
|
|
17137
|
+
var CastExampleSeriesDetailSchema = CastExampleSeriesSchema.extend({
|
|
17138
|
+
episodes: external_exports.array(CastExampleSeriesEpisodeSchema).max(MAX_CAST_EXAMPLE_SERIES_EPISODES)
|
|
17139
|
+
});
|
|
17140
|
+
var CastExampleSeriesListSchema = external_exports.object({
|
|
17141
|
+
data: external_exports.array(CastExampleSeriesSchema)
|
|
17142
|
+
});
|
|
16782
17143
|
|
|
16783
17144
|
// ../api-contract/src/cast/schema.ts
|
|
16784
17145
|
var CAST_TREATMENT_IDS = ["self-filmed", "produced", "vlog"];
|
|
@@ -16800,6 +17161,7 @@ var CAST_ENGINE_MODES = [
|
|
|
16800
17161
|
"boreal",
|
|
16801
17162
|
"heygen",
|
|
16802
17163
|
"seedance",
|
|
17164
|
+
"seedance-fast",
|
|
16803
17165
|
"seedance-2",
|
|
16804
17166
|
"kling-3-turbo",
|
|
16805
17167
|
"omni-1.1-flash",
|
|
@@ -16896,6 +17258,10 @@ var CastGenerationAnalyticsWriteSchema = CastGenerationAnalyticsSchema.omit({ ag
|
|
|
16896
17258
|
partCount: external_exports.number().int().positive().max(STITCH_MAX_CLIPS).optional()
|
|
16897
17259
|
});
|
|
16898
17260
|
var CastGenerationOperationSchema = external_exports.enum(["script", "replacement"]);
|
|
17261
|
+
var CastSourceSessionSchema = external_exports.object({
|
|
17262
|
+
rootWorkId: external_exports.string().uuid(),
|
|
17263
|
+
authorId: external_exports.string().uuid().optional()
|
|
17264
|
+
});
|
|
16899
17265
|
var CastGenerationConfigSchema = external_exports.object({
|
|
16900
17266
|
operation: CastGenerationOperationSchema.optional(),
|
|
16901
17267
|
replacement: DittoInputSchema.optional(),
|
|
@@ -16903,6 +17269,19 @@ var CastGenerationConfigSchema = external_exports.object({
|
|
|
16903
17269
|
external_exports.array(CastAuthoredSectionSchema)
|
|
16904
17270
|
).optional(),
|
|
16905
17271
|
requestedSeconds: external_exports.number().positive().optional(),
|
|
17272
|
+
/**
|
|
17273
|
+
* The nodes of this generation's graph that draw a picture of its
|
|
17274
|
+
* series' places and looks (`places-and-looks-microdramas`): once the run
|
|
17275
|
+
* finishes, each one's picture is kept on its place or look, so every
|
|
17276
|
+
* later episode films the same picture.
|
|
17277
|
+
*/
|
|
17278
|
+
scenePictures: external_exports.array(
|
|
17279
|
+
external_exports.object({
|
|
17280
|
+
nodeId: external_exports.string().min(1).max(200),
|
|
17281
|
+
kind: external_exports.enum(["place", "look"]),
|
|
17282
|
+
id: external_exports.string().uuid()
|
|
17283
|
+
})
|
|
17284
|
+
).max(60).optional().catch(void 0),
|
|
16906
17285
|
creationSettings: CastCreationSettingsSchema.optional(),
|
|
16907
17286
|
// Attribution must not reject an otherwise valid generation record.
|
|
16908
17287
|
scriptTemplate: CastTemplateReferenceSchema.optional().catch(void 0),
|
|
@@ -17123,7 +17502,9 @@ var CastGenerationConfigSchema = external_exports.object({
|
|
|
17123
17502
|
* result — for a generation they have already been charged for. A
|
|
17124
17503
|
* telemetry field must never be able to refuse a record.
|
|
17125
17504
|
*/
|
|
17126
|
-
analytics: CastGenerationAnalyticsSchema.optional().catch(void 0)
|
|
17505
|
+
analytics: CastGenerationAnalyticsSchema.optional().catch(void 0),
|
|
17506
|
+
/** Server-written on a derived take; see `CastSourceSessionSchema`. */
|
|
17507
|
+
sourceSession: CastSourceSessionSchema.optional().catch(void 0)
|
|
17127
17508
|
}).passthrough();
|
|
17128
17509
|
var SharedCastConfigSchema = CastGenerationConfigSchema.pick({
|
|
17129
17510
|
autoVoice: true,
|
|
@@ -17137,6 +17518,11 @@ var SharedCastConfigSchema = CastGenerationConfigSchema.pick({
|
|
|
17137
17518
|
engine: true,
|
|
17138
17519
|
resolution: true,
|
|
17139
17520
|
subtitles: true
|
|
17521
|
+
}).extend({
|
|
17522
|
+
// A brand kit is the source team's; a remix wears one of its own.
|
|
17523
|
+
creationSettings: CastCreationSettingsSchema.omit({
|
|
17524
|
+
brandKit: true
|
|
17525
|
+
}).optional()
|
|
17140
17526
|
}).strip();
|
|
17141
17527
|
var SharedCastGlobalSelectionSchema = external_exports.object({
|
|
17142
17528
|
kind: external_exports.literal("global"),
|
|
@@ -17241,7 +17627,17 @@ var CastGenerationCollectionSchema = external_exports.object({
|
|
|
17241
17627
|
/** The episode this video is a take of, what another take sends back; null outside a series. */
|
|
17242
17628
|
episodeId: external_exports.string().uuid().nullable(),
|
|
17243
17629
|
episodeNumber: external_exports.number().int().positive().nullable(),
|
|
17244
|
-
episodeCount: external_exports.number().int().nonnegative()
|
|
17630
|
+
episodeCount: external_exports.number().int().nonnegative(),
|
|
17631
|
+
/**
|
|
17632
|
+
* The take a member pinned as the one its episode shows; null while none
|
|
17633
|
+
* is, when the newest take that finished shows. Absent outside a series
|
|
17634
|
+
* and from a server built before pins.
|
|
17635
|
+
*/
|
|
17636
|
+
pinnedTakeId: external_exports.string().uuid().nullable().optional()
|
|
17637
|
+
});
|
|
17638
|
+
var CastStudioSessionSchema = external_exports.object({
|
|
17639
|
+
key: external_exports.string().min(1).max(200),
|
|
17640
|
+
takeCount: external_exports.number().int().positive()
|
|
17245
17641
|
});
|
|
17246
17642
|
var CastGenerationResponseSchema = external_exports.object({
|
|
17247
17643
|
id: external_exports.string().uuid(),
|
|
@@ -17335,11 +17731,25 @@ var CastGenerationResponseSchema = external_exports.object({
|
|
|
17335
17731
|
addSubtitles: CastAddSubtitlesSchema.nullable().optional(),
|
|
17336
17732
|
/** Set on a take that is another with subtitles added. Null otherwise. */
|
|
17337
17733
|
subtitledFrom: CastSubtitledFromSchema.nullable().optional(),
|
|
17734
|
+
/**
|
|
17735
|
+
* Whether the reader can trim this take into a take of its own: true on
|
|
17736
|
+
* their own finished take; false on one being made, a replacement or a
|
|
17737
|
+
* teammate's. Absent for a client built before this field.
|
|
17738
|
+
*/
|
|
17739
|
+
canTrim: external_exports.boolean().optional(),
|
|
17740
|
+
/** Set on a take that is a trim of another. Null otherwise; absent for an older client. */
|
|
17741
|
+
trimmedFrom: CastTrimmedFromSchema.nullable().optional(),
|
|
17338
17742
|
/**
|
|
17339
17743
|
* The collection this video is in; absent for a video in none, and from a
|
|
17340
17744
|
* server built before collections.
|
|
17341
17745
|
*/
|
|
17342
|
-
collection: CastGenerationCollectionSchema.nullable().optional()
|
|
17746
|
+
collection: CastGenerationCollectionSchema.nullable().optional(),
|
|
17747
|
+
/**
|
|
17748
|
+
* The studio session the take was made in, on a History read: its key and
|
|
17749
|
+
* how many takes the read lists in it, loaded or not. Null for a take in
|
|
17750
|
+
* none; absent from a server built before sessions and on other reads.
|
|
17751
|
+
*/
|
|
17752
|
+
session: CastStudioSessionSchema.nullable().optional()
|
|
17343
17753
|
});
|
|
17344
17754
|
var CreateCastGenerationResponseSchema = CastGenerationResponseSchema.extend({
|
|
17345
17755
|
/** Ownership acknowledgment, not a guarantee of delivery to PostHog. */
|
|
@@ -17357,6 +17767,11 @@ var CastGenerationPageSchema = external_exports.object({
|
|
|
17357
17767
|
var SearchCastGenerationsBodySchema = createCursorPaginationRequestSchema({
|
|
17358
17768
|
defaultPageSize: 24
|
|
17359
17769
|
}).extend({
|
|
17770
|
+
/**
|
|
17771
|
+
* File each row in its studio session (`session` on each row), which
|
|
17772
|
+
* costs the read a grouped query per page. Unset, rows carry none.
|
|
17773
|
+
*/
|
|
17774
|
+
includeSessions: external_exports.boolean().optional(),
|
|
17360
17775
|
filters: external_exports.object({
|
|
17361
17776
|
scope: CastHistoryScopeSchema.default("mine"),
|
|
17362
17777
|
generationId: external_exports.string().uuid().optional(),
|
|
@@ -17379,7 +17794,12 @@ var SearchCastGenerationsBodySchema = createCursorPaginationRequestSchema({
|
|
|
17379
17794
|
*/
|
|
17380
17795
|
inCollection: external_exports.boolean().optional(),
|
|
17381
17796
|
/** Only this collection's videos: every take of a series' episodes. */
|
|
17382
|
-
collectionId: external_exports.string().uuid().optional()
|
|
17797
|
+
collectionId: external_exports.string().uuid().optional(),
|
|
17798
|
+
/**
|
|
17799
|
+
* Only this studio session's takes (a row's `session.key`),
|
|
17800
|
+
* all on one page, newest first.
|
|
17801
|
+
*/
|
|
17802
|
+
session: external_exports.string().min(1).max(200).optional()
|
|
17383
17803
|
}).default({})
|
|
17384
17804
|
});
|
|
17385
17805
|
var SearchCastGenerationsResponseSchema = createPaginatedResponseSchema(CastGenerationResponseSchema);
|
|
@@ -17449,7 +17869,9 @@ var SearchCastCollectionsBodySchema = createCursorPaginationRequestSchema({
|
|
|
17449
17869
|
}).extend({
|
|
17450
17870
|
filters: external_exports.object({
|
|
17451
17871
|
/** Only collections of this kind; absent lists every kind. */
|
|
17452
|
-
kind: CastCollectionKindSchema.optional()
|
|
17872
|
+
kind: CastCollectionKindSchema.optional(),
|
|
17873
|
+
/** `mine` lists the collections the reader started or made a take in; absent lists the team's. */
|
|
17874
|
+
scope: CastHistoryScopeSchema.optional()
|
|
17453
17875
|
}).default({})
|
|
17454
17876
|
});
|
|
17455
17877
|
var SearchCastCollectionsResponseSchema = createPaginatedResponseSchema(CastCollectionListItemSchema);
|
|
@@ -17458,6 +17880,13 @@ var CastCollectionEpisodeSchema = external_exports.object({
|
|
|
17458
17880
|
number: external_exports.number().int().positive(),
|
|
17459
17881
|
take: CastGenerationResponseSchema
|
|
17460
17882
|
});
|
|
17883
|
+
var PinCastCollectionEpisodeTakeBodySchema = external_exports.object({
|
|
17884
|
+
takeId: external_exports.string().uuid().nullable()
|
|
17885
|
+
});
|
|
17886
|
+
var PinCastCollectionEpisodeTakeResponseSchema = external_exports.object({
|
|
17887
|
+
episodeId: external_exports.string().uuid(),
|
|
17888
|
+
pinnedTakeId: external_exports.string().uuid().nullable()
|
|
17889
|
+
});
|
|
17461
17890
|
var SearchCastCollectionEpisodesBodySchema = createCursorPaginationRequestSchema({ defaultPageSize: 24 });
|
|
17462
17891
|
var SearchCastCollectionEpisodesResponseSchema = createPaginatedResponseSchema(CastCollectionEpisodeSchema);
|
|
17463
17892
|
var DraftCastCollectionEpisodeBodySchema = external_exports.object({
|
|
@@ -17466,6 +17895,18 @@ var DraftCastCollectionEpisodeBodySchema = external_exports.object({
|
|
|
17466
17895
|
seconds: CastDraftSecondsSchema.optional(),
|
|
17467
17896
|
/** The cast's names, lead first: every line is said by one of them. */
|
|
17468
17897
|
speakers: CastScriptSpeakersSchema,
|
|
17898
|
+
/**
|
|
17899
|
+
* Who each speaker is (`places-and-looks-microdramas`), so the writer can name
|
|
17900
|
+
* the looks the series keeps for them. In `speakers` order.
|
|
17901
|
+
*/
|
|
17902
|
+
cast: external_exports.array(
|
|
17903
|
+
external_exports.object({
|
|
17904
|
+
name: external_exports.string().trim().min(1).max(200),
|
|
17905
|
+
customAvatarId: external_exports.string().uuid().optional(),
|
|
17906
|
+
presetAvatarId: external_exports.string().uuid().optional(),
|
|
17907
|
+
elementId: external_exports.string().uuid().optional()
|
|
17908
|
+
})
|
|
17909
|
+
).max(8).optional(),
|
|
17469
17910
|
/**
|
|
17470
17911
|
* The episode to write: one already made, written again from the episodes
|
|
17471
17912
|
* before it, or absent (or past the last) for the series' next episode.
|
|
@@ -17528,6 +17969,132 @@ var CastTemplatePageSchema = createPaginatedResponseSchema(
|
|
|
17528
17969
|
})
|
|
17529
17970
|
);
|
|
17530
17971
|
|
|
17972
|
+
// ../api-contract/src/cast/series-story.ts
|
|
17973
|
+
var MAX_CAST_SERIES_NAME_LENGTH = 120;
|
|
17974
|
+
var MAX_CAST_SERIES_DESCRIPTION_LENGTH = 1e3;
|
|
17975
|
+
var CastSeriesPersonSchema = external_exports.object({
|
|
17976
|
+
customAvatarId: external_exports.string().uuid().optional(),
|
|
17977
|
+
presetAvatarId: external_exports.string().uuid().optional(),
|
|
17978
|
+
elementId: external_exports.string().uuid().optional()
|
|
17979
|
+
}).refine(
|
|
17980
|
+
(person) => [
|
|
17981
|
+
person.customAvatarId,
|
|
17982
|
+
person.presetAvatarId,
|
|
17983
|
+
person.elementId
|
|
17984
|
+
].filter(Boolean).length === 1,
|
|
17985
|
+
{ message: "Name the person by exactly one id" }
|
|
17986
|
+
);
|
|
17987
|
+
var NameSchema = external_exports.string().trim().min(1).max(MAX_CAST_SERIES_NAME_LENGTH);
|
|
17988
|
+
var DescriptionSchema = external_exports.string().trim().min(1).max(MAX_CAST_SERIES_DESCRIPTION_LENGTH);
|
|
17989
|
+
var CastSeriesPlaceSchema = external_exports.object({
|
|
17990
|
+
id: external_exports.string().uuid(),
|
|
17991
|
+
name: external_exports.string(),
|
|
17992
|
+
/** What the place's picture is drawn from. */
|
|
17993
|
+
description: external_exports.string(),
|
|
17994
|
+
/**
|
|
17995
|
+
* Proposed by a draft (Write it for me, the scene reader) and kept once an
|
|
17996
|
+
* episode that names it starts, or a member edits it. The writers are
|
|
17997
|
+
* shown kept places and looks only.
|
|
17998
|
+
*/
|
|
17999
|
+
pending: external_exports.boolean(),
|
|
18000
|
+
/** Null until an episode draws it; every later episode films this picture. */
|
|
18001
|
+
pictureAssetId: external_exports.string().uuid().nullable(),
|
|
18002
|
+
pictureUrl: external_exports.string().nullable(),
|
|
18003
|
+
/**
|
|
18004
|
+
* The picture at a tile's size, which every surface but the full-screen
|
|
18005
|
+
* viewer draws; the original where no smaller one resolves. Absent from a
|
|
18006
|
+
* server older than it.
|
|
18007
|
+
*/
|
|
18008
|
+
previewUrl: external_exports.string().nullable().optional(),
|
|
18009
|
+
createdAt: external_exports.string(),
|
|
18010
|
+
updatedAt: external_exports.string()
|
|
18011
|
+
});
|
|
18012
|
+
var CastSeriesLookSchema = external_exports.object({
|
|
18013
|
+
id: external_exports.string().uuid(),
|
|
18014
|
+
person: CastSeriesPersonSchema,
|
|
18015
|
+
name: external_exports.string(),
|
|
18016
|
+
/** What changes from the look it starts from, or from the character sheet. */
|
|
18017
|
+
description: external_exports.string(),
|
|
18018
|
+
startsFromLookId: external_exports.string().uuid().nullable(),
|
|
18019
|
+
/** A look for the past, at the age its description gives. */
|
|
18020
|
+
flashback: external_exports.boolean(),
|
|
18021
|
+
/**
|
|
18022
|
+
* Proposed by a draft (Write it for me, the scene reader) and kept once an
|
|
18023
|
+
* episode that names it starts, or a member edits it. The writers are
|
|
18024
|
+
* shown kept places and looks only.
|
|
18025
|
+
*/
|
|
18026
|
+
pending: external_exports.boolean(),
|
|
18027
|
+
pictureAssetId: external_exports.string().uuid().nullable(),
|
|
18028
|
+
pictureUrl: external_exports.string().nullable(),
|
|
18029
|
+
/**
|
|
18030
|
+
* The picture at a tile's size, which every surface but the full-screen
|
|
18031
|
+
* viewer draws; the original where no smaller one resolves. Absent from a
|
|
18032
|
+
* server older than it.
|
|
18033
|
+
*/
|
|
18034
|
+
previewUrl: external_exports.string().nullable().optional(),
|
|
18035
|
+
createdAt: external_exports.string(),
|
|
18036
|
+
updatedAt: external_exports.string()
|
|
18037
|
+
});
|
|
18038
|
+
var CastSeriesCarriedLookSchema = external_exports.object({
|
|
18039
|
+
person: CastSeriesPersonSchema,
|
|
18040
|
+
lookId: external_exports.string().uuid()
|
|
18041
|
+
});
|
|
18042
|
+
var CastSeriesStorySchema = external_exports.object({
|
|
18043
|
+
places: external_exports.array(CastSeriesPlaceSchema),
|
|
18044
|
+
looks: external_exports.array(CastSeriesLookSchema),
|
|
18045
|
+
/** As the newest episode left everyone; empty before the first. */
|
|
18046
|
+
carried: external_exports.array(CastSeriesCarriedLookSchema),
|
|
18047
|
+
/** The newest episode's last place, where the next one picks up. */
|
|
18048
|
+
lastPlaceId: external_exports.string().uuid().nullable()
|
|
18049
|
+
});
|
|
18050
|
+
var PlacePictureSchema = external_exports.string().uuid();
|
|
18051
|
+
var CreateCastSeriesPlaceBodySchema = external_exports.object({
|
|
18052
|
+
name: NameSchema,
|
|
18053
|
+
description: DescriptionSchema,
|
|
18054
|
+
/** Absent, the picture is drawn the first time an episode films the place. */
|
|
18055
|
+
pictureAssetId: PlacePictureSchema.optional(),
|
|
18056
|
+
/**
|
|
18057
|
+
* A draft's proposal (Write it for me, the scene reader), kept once an
|
|
18058
|
+
* episode that names it starts. A create naming a pending row of the same
|
|
18059
|
+
* name takes that row instead; without this it is kept at once.
|
|
18060
|
+
*/
|
|
18061
|
+
pending: external_exports.literal(true).optional()
|
|
18062
|
+
});
|
|
18063
|
+
var UpdateCastSeriesPlaceBodySchema = external_exports.object({
|
|
18064
|
+
name: NameSchema.optional(),
|
|
18065
|
+
description: DescriptionSchema.optional(),
|
|
18066
|
+
pictureAssetId: PlacePictureSchema.optional()
|
|
18067
|
+
}).refine(
|
|
18068
|
+
(body) => body.name !== void 0 || body.description !== void 0 || body.pictureAssetId !== void 0,
|
|
18069
|
+
{
|
|
18070
|
+
message: "Change the name, the description or the picture"
|
|
18071
|
+
}
|
|
18072
|
+
);
|
|
18073
|
+
var CreateCastSeriesLookBodySchema = external_exports.object({
|
|
18074
|
+
person: CastSeriesPersonSchema,
|
|
18075
|
+
name: NameSchema,
|
|
18076
|
+
description: DescriptionSchema,
|
|
18077
|
+
startsFromLookId: external_exports.string().uuid().optional(),
|
|
18078
|
+
flashback: external_exports.boolean().optional(),
|
|
18079
|
+
/** Absent, the picture is drawn the first time an episode films the look. */
|
|
18080
|
+
pictureAssetId: PlacePictureSchema.optional(),
|
|
18081
|
+
/**
|
|
18082
|
+
* A draft's proposal (Write it for me, the scene reader), kept once an
|
|
18083
|
+
* episode that names it starts. A create naming a pending row of the same
|
|
18084
|
+
* name takes that row instead; without this it is kept at once.
|
|
18085
|
+
*/
|
|
18086
|
+
pending: external_exports.literal(true).optional()
|
|
18087
|
+
});
|
|
18088
|
+
var UpdateCastSeriesLookBodySchema = external_exports.object({
|
|
18089
|
+
name: NameSchema.optional(),
|
|
18090
|
+
description: DescriptionSchema.optional(),
|
|
18091
|
+
/** Kept through a new description, which on its own lets the picture go. */
|
|
18092
|
+
pictureAssetId: PlacePictureSchema.optional()
|
|
18093
|
+
}).refine(
|
|
18094
|
+
(body) => body.name !== void 0 || body.description !== void 0 || body.pictureAssetId !== void 0,
|
|
18095
|
+
{ message: "Change the name, the description or the picture" }
|
|
18096
|
+
);
|
|
18097
|
+
|
|
17531
18098
|
// ../api-contract/src/custom-context/schema.ts
|
|
17532
18099
|
var MAX_CUSTOM_CONTEXT_NAME_LENGTH = 80;
|
|
17533
18100
|
var MAX_CUSTOM_CONTEXT_INSTRUCTIONS_LENGTH = 4e3;
|
|
@@ -18200,6 +18767,8 @@ var SearchElementsBodySchema = createCursorPaginationRequestSchema({
|
|
|
18200
18767
|
createdByMe: external_exports.boolean().optional(),
|
|
18201
18768
|
/** Latest live version belongs to the requesting member and is pending or needs review. */
|
|
18202
18769
|
reviewNotificationsOnly: external_exports.boolean().optional(),
|
|
18770
|
+
/** Only elements with a published (default) version, the ones a run can use. */
|
|
18771
|
+
publishedOnly: external_exports.boolean().optional(),
|
|
18203
18772
|
/** Newest first by default, the order every older caller gets. */
|
|
18204
18773
|
sort: ElementLibrarySortSchema.optional()
|
|
18205
18774
|
});
|
|
@@ -18565,6 +19134,7 @@ var InAppExperience;
|
|
|
18565
19134
|
InAppExperience2["CastNamesGuide"] = "cast_names_guide";
|
|
18566
19135
|
InAppExperience2["CastShotsGuide"] = "cast_shots_guide";
|
|
18567
19136
|
InAppExperience2["CastLanguageGuide"] = "cast_language_guide";
|
|
19137
|
+
InAppExperience2["CastScenesGuide"] = "cast_scenes_guide";
|
|
18568
19138
|
InAppExperience2["ElementCreatorGuide"] = "element_creator_guide";
|
|
18569
19139
|
InAppExperience2["ElementProductDescriptionGuide"] = "element_product_description_guide";
|
|
18570
19140
|
InAppExperience2["PlaygroundGuide"] = "playground_guide";
|
|
@@ -18609,6 +19179,7 @@ var IN_APP_EXPERIENCE_REGISTRY = {
|
|
|
18609
19179
|
[InAppExperience.CastNamesGuide]: ON_OUTCOME,
|
|
18610
19180
|
[InAppExperience.CastShotsGuide]: ON_OUTCOME,
|
|
18611
19181
|
[InAppExperience.CastLanguageGuide]: ON_OUTCOME,
|
|
19182
|
+
[InAppExperience.CastScenesGuide]: ON_OUTCOME,
|
|
18612
19183
|
[InAppExperience.ElementCreatorGuide]: ON_OUTCOME,
|
|
18613
19184
|
[InAppExperience.ElementProductDescriptionGuide]: ON_OUTCOME,
|
|
18614
19185
|
[InAppExperience.PlaygroundGuide]: ON_OUTCOME,
|
|
@@ -19571,7 +20142,9 @@ var DittoGenerationResponseSchema = CastGenerationResponseSchema.omit({
|
|
|
19571
20142
|
upscale: true,
|
|
19572
20143
|
upscaledFrom: true,
|
|
19573
20144
|
addSubtitles: true,
|
|
19574
|
-
subtitledFrom: true
|
|
20145
|
+
subtitledFrom: true,
|
|
20146
|
+
canTrim: true,
|
|
20147
|
+
trimmedFrom: true
|
|
19575
20148
|
}).extend({
|
|
19576
20149
|
// Optional so a web build that ships ahead of core still validates.
|
|
19577
20150
|
shareLink: ShareLinkSchema.pick({ id: true, url: true }).nullable().optional(),
|
|
@@ -19588,14 +20161,28 @@ var DittoGenerationResponseSchema = CastGenerationResponseSchema.omit({
|
|
|
19588
20161
|
* while it settles, for any other status, and from a server before
|
|
19589
20162
|
* this field.
|
|
19590
20163
|
*/
|
|
19591
|
-
credits: RunCreditsSchema.optional()
|
|
20164
|
+
credits: RunCreditsSchema.optional(),
|
|
20165
|
+
/**
|
|
20166
|
+
* Whether a member of the team favorited the finished video, the
|
|
20167
|
+
* favorite its canvas version holds. Absent from a server before this
|
|
20168
|
+
* field.
|
|
20169
|
+
*/
|
|
20170
|
+
favorited: external_exports.boolean().optional()
|
|
20171
|
+
});
|
|
20172
|
+
var SetDittoGenerationFavoriteBodySchema = external_exports.object({
|
|
20173
|
+
favorited: external_exports.boolean()
|
|
20174
|
+
});
|
|
20175
|
+
var SetDittoGenerationFavoriteResponseSchema = external_exports.object({
|
|
20176
|
+
favorited: external_exports.boolean()
|
|
19592
20177
|
});
|
|
19593
20178
|
var SearchDittoGenerationsBodySchema = createCursorPaginationRequestSchema({ defaultPageSize: 24 }).extend({
|
|
19594
20179
|
// Omitted filters preserve the personal-only behavior of deployed clients.
|
|
19595
20180
|
filters: external_exports.object({
|
|
19596
20181
|
scope: CastHistoryScopeSchema.default("mine"),
|
|
19597
20182
|
/** Only the videos made from this template; omitted lists every one. */
|
|
19598
|
-
templateId: external_exports.string().uuid().optional()
|
|
20183
|
+
templateId: external_exports.string().uuid().optional(),
|
|
20184
|
+
/** Only the videos a member of the team favorited. */
|
|
20185
|
+
favorites: external_exports.boolean().optional()
|
|
19599
20186
|
}).optional()
|
|
19600
20187
|
});
|
|
19601
20188
|
var SearchDittoGenerationsResponseSchema = createPaginatedResponseSchema(DittoGenerationResponseSchema);
|
|
@@ -21234,6 +21821,18 @@ var BulkRunFreeGenerationFields = {
|
|
|
21234
21821
|
*/
|
|
21235
21822
|
generationAction: CastGenerationActionSchema.optional()
|
|
21236
21823
|
};
|
|
21824
|
+
var BulkRunCastSeriesField = {
|
|
21825
|
+
/**
|
|
21826
|
+
* The Microdrama series a Cast run draws for, by its series or by the
|
|
21827
|
+
* episode it takes again (`places-and-looks-microdramas`): a place of
|
|
21828
|
+
* that series the run draws, for a video's clips or on its own, is free.
|
|
21829
|
+
* Ignored for a series not the team's.
|
|
21830
|
+
*/
|
|
21831
|
+
castSeries: external_exports.object({
|
|
21832
|
+
collectionId: external_exports.string().uuid().optional(),
|
|
21833
|
+
episodeId: external_exports.string().uuid().optional()
|
|
21834
|
+
}).strict().optional()
|
|
21835
|
+
};
|
|
21237
21836
|
var canvasContract = c5.router({
|
|
21238
21837
|
verifyMedia: {
|
|
21239
21838
|
summary: "Verify a saved media export",
|
|
@@ -22202,6 +22801,13 @@ var canvasContract = c5.router({
|
|
|
22202
22801
|
* one node.
|
|
22203
22802
|
*/
|
|
22204
22803
|
includeAllActiveRuns: external_exports.coerce.boolean().optional(),
|
|
22804
|
+
/**
|
|
22805
|
+
* Return only runs that are pending/running or were updated in the
|
|
22806
|
+
* last two minutes, instead of every node's latest run. For a
|
|
22807
|
+
* status poller: a run it tracks that is absent is read through
|
|
22808
|
+
* `getNodeRun`.
|
|
22809
|
+
*/
|
|
22810
|
+
activeOrRecentlyUpdatedOnly: external_exports.coerce.boolean().optional(),
|
|
22205
22811
|
/** Resolve visible template owners for clients with collapsed canvas content. */
|
|
22206
22812
|
includeTemplateOwnership: external_exports.coerce.boolean().optional()
|
|
22207
22813
|
}),
|
|
@@ -22262,7 +22868,8 @@ var canvasContract = c5.router({
|
|
|
22262
22868
|
*/
|
|
22263
22869
|
scheduleNodesLate: external_exports.boolean().optional(),
|
|
22264
22870
|
creditShortfall: BulkRunCreditShortfallModeSchema.optional(),
|
|
22265
|
-
...BulkRunFreeGenerationFields
|
|
22871
|
+
...BulkRunFreeGenerationFields,
|
|
22872
|
+
...BulkRunCastSeriesField
|
|
22266
22873
|
}),
|
|
22267
22874
|
responses: {
|
|
22268
22875
|
201: BulkNodeRunStartResponseSchema,
|
|
@@ -22292,7 +22899,8 @@ var canvasContract = c5.router({
|
|
|
22292
22899
|
castVoiceReferences: external_exports.array(CastVoiceReferenceSchema).min(1).max(STITCH_MAX_CLIPS).optional(),
|
|
22293
22900
|
/** As on `bulkRunNodes`: the reads run first, then every clip at once. */
|
|
22294
22901
|
scheduleNodesLate: external_exports.boolean().optional(),
|
|
22295
|
-
...BulkRunFreeGenerationFields
|
|
22902
|
+
...BulkRunFreeGenerationFields,
|
|
22903
|
+
...BulkRunCastSeriesField
|
|
22296
22904
|
}),
|
|
22297
22905
|
responses: {
|
|
22298
22906
|
201: BulkNodeRunStartResponseSchema,
|
|
@@ -23285,6 +23893,19 @@ var dittoContract = c7.router({
|
|
|
23285
23893
|
404: MessageResponseSchema
|
|
23286
23894
|
}
|
|
23287
23895
|
},
|
|
23896
|
+
setGenerationFavorite: {
|
|
23897
|
+
method: "PUT",
|
|
23898
|
+
path: "/ditto/generations/:generationId/favorite",
|
|
23899
|
+
summary: "Favorite a Ditto video the member can see, or take the favorite back, on the canvas version it was saved as. Repeating it returns the same state",
|
|
23900
|
+
pathParams: external_exports.object({ generationId: external_exports.string().uuid() }),
|
|
23901
|
+
body: SetDittoGenerationFavoriteBodySchema,
|
|
23902
|
+
responses: {
|
|
23903
|
+
200: SetDittoGenerationFavoriteResponseSchema,
|
|
23904
|
+
403: MessageResponseSchema,
|
|
23905
|
+
404: MessageResponseSchema,
|
|
23906
|
+
409: MessageResponseSchema
|
|
23907
|
+
}
|
|
23908
|
+
},
|
|
23288
23909
|
searchImports: {
|
|
23289
23910
|
method: "POST",
|
|
23290
23911
|
path: "/ditto/imports/search",
|
|
@@ -25823,6 +26444,20 @@ var castContract = c18.router({
|
|
|
25823
26444
|
},
|
|
25824
26445
|
summary: "Burn subtitles into a finished Cast take that has none, as a new take of its own"
|
|
25825
26446
|
},
|
|
26447
|
+
trimCastGeneration: {
|
|
26448
|
+
method: "POST",
|
|
26449
|
+
path: "/cast/generations/:generationId/trim",
|
|
26450
|
+
pathParams: external_exports.object({ generationId: external_exports.string().uuid() }),
|
|
26451
|
+
body: TrimCastGenerationBodySchema,
|
|
26452
|
+
responses: {
|
|
26453
|
+
201: CastGenerationResponseSchema,
|
|
26454
|
+
400: MessageResponseSchema,
|
|
26455
|
+
403: MessageResponseSchema,
|
|
26456
|
+
404: MessageResponseSchema,
|
|
26457
|
+
409: MessageResponseSchema
|
|
26458
|
+
},
|
|
26459
|
+
summary: "Trim a finished Cast take to the part between two points, as a new take of its own"
|
|
26460
|
+
},
|
|
25826
26461
|
getSharedCastGeneration: {
|
|
25827
26462
|
method: "GET",
|
|
25828
26463
|
path: "/cast/shared/:generationId",
|
|
@@ -25863,6 +26498,19 @@ var castContract = c18.router({
|
|
|
25863
26498
|
404: MessageResponseSchema
|
|
25864
26499
|
}
|
|
25865
26500
|
},
|
|
26501
|
+
deleteCastGeneration: {
|
|
26502
|
+
method: "DELETE",
|
|
26503
|
+
path: "/cast/generations/:generationId",
|
|
26504
|
+
pathParams: external_exports.object({ generationId: external_exports.string().uuid() }),
|
|
26505
|
+
body: null,
|
|
26506
|
+
responses: {
|
|
26507
|
+
204: c18.noBody(),
|
|
26508
|
+
403: MessageResponseSchema,
|
|
26509
|
+
404: MessageResponseSchema,
|
|
26510
|
+
409: MessageResponseSchema
|
|
26511
|
+
},
|
|
26512
|
+
summary: "Delete a finished Cast video its maker no longer wants, from Cast History and Assets. Repeating it also returns 204"
|
|
26513
|
+
},
|
|
25866
26514
|
upsertCastGenerationFeedback: {
|
|
25867
26515
|
method: "PUT",
|
|
25868
26516
|
path: "/cast/generations/:generationId/feedback",
|
|
@@ -25957,6 +26605,129 @@ var castContract = c18.router({
|
|
|
25957
26605
|
},
|
|
25958
26606
|
summary: "Write a series' next episode as a scene, continuing from the episodes before it"
|
|
25959
26607
|
},
|
|
26608
|
+
getCastSeriesStory: {
|
|
26609
|
+
method: "GET",
|
|
26610
|
+
path: "/cast/collections/:collectionId/story",
|
|
26611
|
+
pathParams: external_exports.object({ collectionId: external_exports.string().uuid() }),
|
|
26612
|
+
responses: {
|
|
26613
|
+
200: CastSeriesStorySchema,
|
|
26614
|
+
404: MessageResponseSchema
|
|
26615
|
+
},
|
|
26616
|
+
summary: "A Microdrama series' places and looks, and how its newest episode left everyone"
|
|
26617
|
+
},
|
|
26618
|
+
readCastSeriesScenes: {
|
|
26619
|
+
method: "POST",
|
|
26620
|
+
path: "/cast/collections/:collectionId/scenes/read",
|
|
26621
|
+
pathParams: external_exports.object({ collectionId: external_exports.string().uuid() }),
|
|
26622
|
+
body: ReadCastSeriesScenesBodySchema,
|
|
26623
|
+
responses: {
|
|
26624
|
+
200: ReadCastSeriesScenesResponseSchema,
|
|
26625
|
+
404: MessageResponseSchema,
|
|
26626
|
+
503: MessageResponseSchema
|
|
26627
|
+
},
|
|
26628
|
+
summary: "Read where each scene of a Microdrama series' script happens and how everyone looks there"
|
|
26629
|
+
},
|
|
26630
|
+
createCastSeriesPlace: {
|
|
26631
|
+
method: "POST",
|
|
26632
|
+
path: "/cast/collections/:collectionId/places",
|
|
26633
|
+
pathParams: external_exports.object({ collectionId: external_exports.string().uuid() }),
|
|
26634
|
+
body: CreateCastSeriesPlaceBodySchema,
|
|
26635
|
+
responses: {
|
|
26636
|
+
201: CastSeriesPlaceSchema,
|
|
26637
|
+
400: MessageResponseSchema,
|
|
26638
|
+
404: MessageResponseSchema,
|
|
26639
|
+
409: MessageResponseSchema
|
|
26640
|
+
},
|
|
26641
|
+
summary: "Add a place to a Microdrama series, with a picture of the team's or one drawn the first time an episode films it"
|
|
26642
|
+
},
|
|
26643
|
+
updateCastSeriesPlace: {
|
|
26644
|
+
method: "PATCH",
|
|
26645
|
+
path: "/cast/collections/:collectionId/places/:placeId",
|
|
26646
|
+
pathParams: external_exports.object({
|
|
26647
|
+
collectionId: external_exports.string().uuid(),
|
|
26648
|
+
placeId: external_exports.string().uuid()
|
|
26649
|
+
}),
|
|
26650
|
+
body: UpdateCastSeriesPlaceBodySchema,
|
|
26651
|
+
responses: {
|
|
26652
|
+
200: CastSeriesPlaceSchema,
|
|
26653
|
+
400: MessageResponseSchema,
|
|
26654
|
+
404: MessageResponseSchema,
|
|
26655
|
+
409: MessageResponseSchema
|
|
26656
|
+
},
|
|
26657
|
+
summary: "Rename a series place, give it another picture, or describe it again, which draws its picture again unless one is named"
|
|
26658
|
+
},
|
|
26659
|
+
deleteCastSeriesPlace: {
|
|
26660
|
+
method: "DELETE",
|
|
26661
|
+
path: "/cast/collections/:collectionId/places/:placeId",
|
|
26662
|
+
pathParams: external_exports.object({
|
|
26663
|
+
collectionId: external_exports.string().uuid(),
|
|
26664
|
+
placeId: external_exports.string().uuid()
|
|
26665
|
+
}),
|
|
26666
|
+
body: null,
|
|
26667
|
+
responses: {
|
|
26668
|
+
204: c18.noBody(),
|
|
26669
|
+
404: MessageResponseSchema
|
|
26670
|
+
},
|
|
26671
|
+
summary: "Remove a place from a series; episodes already made keep it"
|
|
26672
|
+
},
|
|
26673
|
+
createCastSeriesLook: {
|
|
26674
|
+
method: "POST",
|
|
26675
|
+
path: "/cast/collections/:collectionId/looks",
|
|
26676
|
+
pathParams: external_exports.object({ collectionId: external_exports.string().uuid() }),
|
|
26677
|
+
body: CreateCastSeriesLookBodySchema,
|
|
26678
|
+
responses: {
|
|
26679
|
+
201: CastSeriesLookSchema,
|
|
26680
|
+
400: MessageResponseSchema,
|
|
26681
|
+
404: MessageResponseSchema,
|
|
26682
|
+
409: MessageResponseSchema
|
|
26683
|
+
},
|
|
26684
|
+
summary: "Add a look for one person to a Microdrama series; its picture is drawn the first time an episode films it"
|
|
26685
|
+
},
|
|
26686
|
+
updateCastSeriesLook: {
|
|
26687
|
+
method: "PATCH",
|
|
26688
|
+
path: "/cast/collections/:collectionId/looks/:lookId",
|
|
26689
|
+
pathParams: external_exports.object({
|
|
26690
|
+
collectionId: external_exports.string().uuid(),
|
|
26691
|
+
lookId: external_exports.string().uuid()
|
|
26692
|
+
}),
|
|
26693
|
+
body: UpdateCastSeriesLookBodySchema,
|
|
26694
|
+
responses: {
|
|
26695
|
+
200: CastSeriesLookSchema,
|
|
26696
|
+
400: MessageResponseSchema,
|
|
26697
|
+
404: MessageResponseSchema,
|
|
26698
|
+
409: MessageResponseSchema
|
|
26699
|
+
},
|
|
26700
|
+
summary: "Rename a series look, give it another picture, or describe it again, which draws its picture again unless one is named"
|
|
26701
|
+
},
|
|
26702
|
+
deleteCastSeriesLook: {
|
|
26703
|
+
method: "DELETE",
|
|
26704
|
+
path: "/cast/collections/:collectionId/looks/:lookId",
|
|
26705
|
+
pathParams: external_exports.object({
|
|
26706
|
+
collectionId: external_exports.string().uuid(),
|
|
26707
|
+
lookId: external_exports.string().uuid()
|
|
26708
|
+
}),
|
|
26709
|
+
body: null,
|
|
26710
|
+
responses: {
|
|
26711
|
+
204: c18.noBody(),
|
|
26712
|
+
404: MessageResponseSchema
|
|
26713
|
+
},
|
|
26714
|
+
summary: "Remove a look from a series; episodes already made keep it"
|
|
26715
|
+
},
|
|
26716
|
+
pinCastCollectionEpisodeTake: {
|
|
26717
|
+
method: "PUT",
|
|
26718
|
+
path: "/cast/collections/:collectionId/episodes/:episodeId/pinned-take",
|
|
26719
|
+
pathParams: external_exports.object({
|
|
26720
|
+
collectionId: external_exports.string().uuid(),
|
|
26721
|
+
episodeId: external_exports.string().uuid()
|
|
26722
|
+
}),
|
|
26723
|
+
body: PinCastCollectionEpisodeTakeBodySchema,
|
|
26724
|
+
responses: {
|
|
26725
|
+
200: PinCastCollectionEpisodeTakeResponseSchema,
|
|
26726
|
+
400: MessageResponseSchema,
|
|
26727
|
+
404: MessageResponseSchema
|
|
26728
|
+
},
|
|
26729
|
+
summary: "Pin the take a series episode shows, or unpin it to show its newest finished take"
|
|
26730
|
+
},
|
|
25960
26731
|
updateCastCollection: {
|
|
25961
26732
|
method: "PATCH",
|
|
25962
26733
|
path: "/cast/collections/:collectionId",
|
|
@@ -26059,7 +26830,15 @@ var publicContract = c19.router(
|
|
|
26059
26830
|
search: castContract.searchCastCollections,
|
|
26060
26831
|
get: castContract.getCastCollection,
|
|
26061
26832
|
episodes: castContract.searchCastCollectionEpisodes,
|
|
26062
|
-
rename: castContract.updateCastCollection
|
|
26833
|
+
rename: castContract.updateCastCollection,
|
|
26834
|
+
// A series' places and looks; each answers 404 without `places-and-looks-microdramas`.
|
|
26835
|
+
story: castContract.getCastSeriesStory,
|
|
26836
|
+
createPlace: castContract.createCastSeriesPlace,
|
|
26837
|
+
updatePlace: castContract.updateCastSeriesPlace,
|
|
26838
|
+
deletePlace: castContract.deleteCastSeriesPlace,
|
|
26839
|
+
createLook: castContract.createCastSeriesLook,
|
|
26840
|
+
updateLook: castContract.updateCastSeriesLook,
|
|
26841
|
+
deleteLook: castContract.deleteCastSeriesLook
|
|
26063
26842
|
},
|
|
26064
26843
|
ditto: {
|
|
26065
26844
|
listModels: dittoContract.listReplacementModels,
|
|
@@ -27111,7 +27890,7 @@ function isMajorUpgrade(current, latest) {
|
|
|
27111
27890
|
return l[0] > c20[0];
|
|
27112
27891
|
}
|
|
27113
27892
|
function shouldShowUpgradeNotice(ctx = {}) {
|
|
27114
|
-
const current = ctx.current ?? "0.
|
|
27893
|
+
const current = ctx.current ?? "0.53.0";
|
|
27115
27894
|
const latest = ctx.latest ?? serverLatestVersion;
|
|
27116
27895
|
const env = ctx.env ?? process.env;
|
|
27117
27896
|
const isTty = ctx.isTty ?? Boolean(process.stderr.isTTY);
|
|
@@ -27132,7 +27911,7 @@ Upgrade: npm install -g @melius-ai/cli@latest (or: brew update && brew upgrade
|
|
|
27132
27911
|
function printUpgradeNoticeIfNeeded(ctx = {}) {
|
|
27133
27912
|
try {
|
|
27134
27913
|
if (!shouldShowUpgradeNotice(ctx)) return;
|
|
27135
|
-
const current = ctx.current ?? "0.
|
|
27914
|
+
const current = ctx.current ?? "0.53.0";
|
|
27136
27915
|
const latest = ctx.latest ?? serverLatestVersion;
|
|
27137
27916
|
process.stderr.write(formatUpgradeNotice(current, latest));
|
|
27138
27917
|
} catch {
|
|
@@ -27239,7 +28018,7 @@ function createClient(config) {
|
|
|
27239
28018
|
"Bypass-Tunnel-Reminder": "true",
|
|
27240
28019
|
[CUSTOM_REQUEST_HEADERS.meliusClient]: buildMeliusClientHeader({
|
|
27241
28020
|
surface: "cli",
|
|
27242
|
-
version: "0.
|
|
28021
|
+
version: "0.53.0"
|
|
27243
28022
|
})
|
|
27244
28023
|
};
|
|
27245
28024
|
if (config.teamId) {
|
|
@@ -29683,7 +30462,7 @@ Examples:
|
|
|
29683
30462
|
`
|
|
29684
30463
|
Returns: status (ready, invalid, estimate_unavailable), attemptId, input, review, estimatedCredits, scriptSeconds, aspectRatios.
|
|
29685
30464
|
Input: { avatar: { name } or { kind: custom|curated|element, id }, sections: [{ text, action?, title? }], voice?, backgroundId?, props?, tone?, engine?, aspectRatio?, resolution?, subtitles?, creationSettings?, scriptTemplate? }.
|
|
29686
|
-
Use 1
|
|
30465
|
+
Use 1-${MAX_CAST_VIDEO_SECTIONS} sections (text up to 5000 characters, action up to 2000, title up to 200).
|
|
29687
30466
|
Props: 1-${CAST_VIDEO_MAX_PROPS} items shaped { assetId, name? }; get asset IDs from mel upload or mel asset search.
|
|
29688
30467
|
Template reference: scriptTemplate: { id: <templateId>, revision: <revision>, source: database }; discover with mel cast templates.
|
|
29689
30468
|
Omitted voice uses the avatar's saved voice. Explicit voice { kind: auto } generates speech.
|
|
@@ -34734,7 +35513,7 @@ function withDefaultHelp(args) {
|
|
|
34734
35513
|
}
|
|
34735
35514
|
function createProgram() {
|
|
34736
35515
|
const program2 = new Command();
|
|
34737
|
-
program2.name("mel").description("Mel \u2014 Melius agent CLI").version("0.
|
|
35516
|
+
program2.name("mel").description("Mel \u2014 Melius agent CLI").version("0.53.0").showSuggestionAfterError(true).option("--json", "Force JSON output (default)").option("--text", "Human-readable output").option(
|
|
34738
35517
|
"--fields <fields>",
|
|
34739
35518
|
"Select specific output fields (comma-separated)"
|
|
34740
35519
|
).option("--quiet", "Suppress output, exit code only").option("--verbose", "Log request/response metadata to stderr").addHelpText(
|