@nodaro/shared 3.62.0 → 3.63.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/dist/{chunk-6CSXMWL4.cjs → chunk-2PU3AGGS.cjs} +27 -4
- package/dist/chunk-2PU3AGGS.cjs.map +1 -0
- package/dist/{chunk-CC4V2B7S.js → chunk-34QLPTSA.js} +3 -3
- package/dist/{chunk-CC4V2B7S.js.map → chunk-34QLPTSA.js.map} +1 -1
- package/dist/{chunk-G4U3HW6W.js → chunk-3K24DWOH.js} +3 -3
- package/dist/{chunk-G4U3HW6W.js.map → chunk-3K24DWOH.js.map} +1 -1
- package/dist/{chunk-GSFB537T.js → chunk-4DVWXEB6.js} +23 -4
- package/dist/chunk-4DVWXEB6.js.map +1 -0
- package/dist/{chunk-ZES6EZC4.js → chunk-4MMZD63H.js} +3 -3
- package/dist/{chunk-ZES6EZC4.js.map → chunk-4MMZD63H.js.map} +1 -1
- package/dist/{chunk-N7OUQK7E.cjs → chunk-63H4C56Q.cjs} +8 -8
- package/dist/{chunk-N7OUQK7E.cjs.map → chunk-63H4C56Q.cjs.map} +1 -1
- package/dist/{chunk-2D5LQFV4.cjs → chunk-6BZC2ZHC.cjs} +9 -9
- package/dist/{chunk-2D5LQFV4.cjs.map → chunk-6BZC2ZHC.cjs.map} +1 -1
- package/dist/{chunk-3OYO3XCC.js → chunk-6M563QE6.js} +71 -9
- package/dist/chunk-6M563QE6.js.map +1 -0
- package/dist/{chunk-IDTKF5EX.cjs → chunk-6TGB7ECA.cjs} +7 -7
- package/dist/{chunk-IDTKF5EX.cjs.map → chunk-6TGB7ECA.cjs.map} +1 -1
- package/dist/{chunk-2HZGDZZN.cjs → chunk-6XUG4L7X.cjs} +6 -6
- package/dist/{chunk-2HZGDZZN.cjs.map → chunk-6XUG4L7X.cjs.map} +1 -1
- package/dist/{chunk-CIPPPT7E.cjs → chunk-77WU3V3J.cjs} +6 -6
- package/dist/{chunk-CIPPPT7E.cjs.map → chunk-77WU3V3J.cjs.map} +1 -1
- package/dist/{chunk-C7POAYFE.js → chunk-AE3AAJ4O.js} +3 -3
- package/dist/{chunk-C7POAYFE.js.map → chunk-AE3AAJ4O.js.map} +1 -1
- package/dist/{chunk-NGKKNSK6.js → chunk-BMJVKYVB.js} +36 -15
- package/dist/chunk-BMJVKYVB.js.map +1 -0
- package/dist/{chunk-YCXRSWCQ.js → chunk-CZ5IQB3L.js} +3 -3
- package/dist/{chunk-YCXRSWCQ.js.map → chunk-CZ5IQB3L.js.map} +1 -1
- package/dist/{chunk-E2HZTGYX.js → chunk-EPXGG27L.js} +7 -7
- package/dist/chunk-EPXGG27L.js.map +1 -0
- package/dist/{chunk-3M4BNKFJ.cjs → chunk-F6WGGYQW.cjs} +167 -3
- package/dist/chunk-F6WGGYQW.cjs.map +1 -0
- package/dist/{chunk-7FCTCWHD.js → chunk-FXGNRYQQ.js} +3 -3
- package/dist/{chunk-7FCTCWHD.js.map → chunk-FXGNRYQQ.js.map} +1 -1
- package/dist/{chunk-QWYFHQYK.cjs → chunk-GMBDLNLD.cjs} +86 -62
- package/dist/chunk-GMBDLNLD.cjs.map +1 -0
- package/dist/{chunk-KJSRPHJ2.cjs → chunk-GSKLPI3J.cjs} +100 -46
- package/dist/chunk-GSKLPI3J.cjs.map +1 -0
- package/dist/{chunk-S5TMRJMX.js → chunk-HBXF6RUU.js} +4 -4
- package/dist/{chunk-S5TMRJMX.js.map → chunk-HBXF6RUU.js.map} +1 -1
- package/dist/{chunk-S24ZBUB4.js → chunk-HWQ2SYNA.js} +6 -32
- package/dist/chunk-HWQ2SYNA.js.map +1 -0
- package/dist/{chunk-JJNNM23P.js → chunk-IY3Y462W.js} +3 -3
- package/dist/{chunk-JJNNM23P.js.map → chunk-IY3Y462W.js.map} +1 -1
- package/dist/{chunk-JZGZ26YB.js → chunk-KCZHQH2O.js} +4 -4
- package/dist/{chunk-JZGZ26YB.js.map → chunk-KCZHQH2O.js.map} +1 -1
- package/dist/{chunk-FVII3KHN.js → chunk-KMGCHV6O.js} +163 -4
- package/dist/chunk-KMGCHV6O.js.map +1 -0
- package/dist/{chunk-4ZEFP2FQ.cjs → chunk-L2TVY6XN.cjs} +4 -4
- package/dist/{chunk-4ZEFP2FQ.cjs.map → chunk-L2TVY6XN.cjs.map} +1 -1
- package/dist/{chunk-TRVWMKNE.cjs → chunk-LH72PQO2.cjs} +204 -52
- package/dist/chunk-LH72PQO2.cjs.map +1 -0
- package/dist/{chunk-HRY7KGAE.cjs → chunk-LMAQUR55.cjs} +6 -6
- package/dist/{chunk-HRY7KGAE.cjs.map → chunk-LMAQUR55.cjs.map} +1 -1
- package/dist/{chunk-MYJQELFN.cjs → chunk-M5OCFGHF.cjs} +254 -7
- package/dist/chunk-M5OCFGHF.cjs.map +1 -0
- package/dist/{chunk-I2RQB7VG.js → chunk-MD4XHED4.js} +3 -3
- package/dist/{chunk-I2RQB7VG.js.map → chunk-MD4XHED4.js.map} +1 -1
- package/dist/{chunk-6G7NN4S4.js → chunk-NIAFR5EE.js} +2 -2
- package/dist/chunk-NIAFR5EE.js.map +1 -0
- package/dist/{chunk-CF4S4N5X.js → chunk-O2QOBA6Q.js} +2 -2
- package/dist/{chunk-CF4S4N5X.js.map → chunk-O2QOBA6Q.js.map} +1 -1
- package/dist/{chunk-4GGLKRYI.cjs → chunk-O6TBB4IF.cjs} +2 -2
- package/dist/{chunk-4GGLKRYI.cjs.map → chunk-O6TBB4IF.cjs.map} +1 -1
- package/dist/{chunk-UDDVDQMF.js → chunk-OV3JTKBY.js} +166 -25
- package/dist/chunk-OV3JTKBY.js.map +1 -0
- package/dist/{chunk-5YYN5X57.js → chunk-PSKZKLDG.js} +252 -8
- package/dist/chunk-PSKZKLDG.js.map +1 -0
- package/dist/{chunk-IWWVPR3W.cjs → chunk-TM5JYSJF.cjs} +95 -19
- package/dist/chunk-TM5JYSJF.cjs.map +1 -0
- package/dist/{chunk-G3KVK7OU.cjs → chunk-V5EEQR2U.cjs} +21 -21
- package/dist/{chunk-G3KVK7OU.cjs.map → chunk-V5EEQR2U.cjs.map} +1 -1
- package/dist/{chunk-AOJ6B7K4.cjs → chunk-WZVIBAKN.cjs} +12 -12
- package/dist/chunk-WZVIBAKN.cjs.map +1 -0
- package/dist/{chunk-5M43XMRB.cjs → chunk-X5BAFW3Q.cjs} +8 -8
- package/dist/{chunk-5M43XMRB.cjs.map → chunk-X5BAFW3Q.cjs.map} +1 -1
- package/dist/{chunk-SYWR5G3T.js → chunk-XBTYGQ6Z.js} +51 -7
- package/dist/chunk-XBTYGQ6Z.js.map +1 -0
- package/dist/{chunk-AFYTX4AI.cjs → chunk-XGGZWA4A.cjs} +107 -50
- package/dist/chunk-XGGZWA4A.cjs.map +1 -0
- package/dist/{chunk-VACPZPUA.cjs → chunk-XGVJGNZW.cjs} +5 -5
- package/dist/{chunk-VACPZPUA.cjs.map → chunk-XGVJGNZW.cjs.map} +1 -1
- package/dist/{chunk-2W745U4A.cjs → chunk-Y35JQPT6.cjs} +42 -70
- package/dist/chunk-Y35JQPT6.cjs.map +1 -0
- package/dist/{chunk-KYMHFVAZ.cjs → chunk-Y4GCJJPF.cjs} +2 -2
- package/dist/chunk-Y4GCJJPF.cjs.map +1 -0
- package/dist/{chunk-PTD6EDUU.js → chunk-YUER7TJG.js} +3 -3
- package/dist/{chunk-PTD6EDUU.js.map → chunk-YUER7TJG.js.map} +1 -1
- package/dist/{chunk-Y6X7UJSD.js → chunk-YX6TFX7H.js} +66 -14
- package/dist/chunk-YX6TFX7H.js.map +1 -0
- package/dist/{chunk-TWF2OSH4.cjs → chunk-ZPE2ZTJ4.cjs} +4 -4
- package/dist/{chunk-TWF2OSH4.cjs.map → chunk-ZPE2ZTJ4.cjs.map} +1 -1
- package/dist/entries/apps.cjs +42 -42
- package/dist/entries/apps.js +7 -7
- package/dist/entries/credits.cjs +237 -169
- package/dist/entries/credits.d.cts +163 -16
- package/dist/entries/credits.d.ts +163 -16
- package/dist/entries/credits.js +10 -10
- package/dist/entries/llm-models.cjs +77 -57
- package/dist/entries/llm-models.d.cts +85 -6
- package/dist/entries/llm-models.d.ts +85 -6
- package/dist/entries/llm-models.js +2 -2
- package/dist/entries/media.cjs +63 -63
- package/dist/entries/media.d.cts +8 -0
- package/dist/entries/media.d.ts +8 -0
- package/dist/entries/media.js +1 -1
- package/dist/entries/model-catalog.cjs +121 -105
- package/dist/entries/model-catalog.d.cts +48 -18
- package/dist/entries/model-catalog.d.ts +48 -18
- package/dist/entries/model-catalog.js +4 -4
- package/dist/entries/models.cjs +418 -322
- package/dist/entries/models.d.cts +71 -5
- package/dist/entries/models.d.ts +71 -5
- package/dist/entries/models.js +5 -5
- package/dist/entries/nodes.cjs +216 -208
- package/dist/entries/nodes.d.cts +22 -6
- package/dist/entries/nodes.d.ts +22 -6
- package/dist/entries/nodes.js +8 -8
- package/dist/entries/pipeline.cjs +152 -152
- package/dist/entries/pipeline.d.cts +3 -3
- package/dist/entries/pipeline.d.ts +3 -3
- package/dist/entries/pipeline.js +3 -3
- package/dist/entries/runtime-config.cjs +29 -29
- package/dist/entries/runtime-config.d.cts +10 -7
- package/dist/entries/runtime-config.d.ts +10 -7
- package/dist/entries/runtime-config.js +1 -1
- package/dist/entries/social.cjs +177 -177
- package/dist/entries/social.js +2 -2
- package/dist/entries/types.d.cts +8 -0
- package/dist/entries/types.d.ts +8 -0
- package/dist/entries/ugc.cjs +71 -71
- package/dist/entries/ugc.js +4 -4
- package/dist/entries/video.cjs +154 -150
- package/dist/entries/video.d.cts +11 -2
- package/dist/entries/video.d.ts +11 -2
- package/dist/entries/video.js +6 -6
- package/dist/entries/workflow.d.cts +1 -1
- package/dist/entries/workflow.d.ts +1 -1
- package/dist/index.cjs +1727 -1515
- package/dist/index.d.cts +8 -8
- package/dist/index.d.ts +8 -8
- package/dist/index.js +23 -23
- package/dist/{model-catalog-CCEcv08q.d.cts → model-catalog-C_Eo35tL.d.cts} +30 -0
- package/dist/{model-catalog-CCEcv08q.d.ts → model-catalog-C_Eo35tL.d.ts} +30 -0
- package/dist/{model-constants-Cf3zaITt.d.cts → model-constants-Bg4ccSQb.d.ts} +138 -25
- package/dist/{model-constants-B88p6XR0.d.ts → model-constants-DWcxOmaY.d.cts} +138 -25
- package/package.json +1 -1
- package/src/__tests__/credit-identifiers.test.ts +29 -0
- package/src/__tests__/extend-providers.test.ts +106 -26
- package/src/__tests__/gvp-supported-providers.test.ts +27 -2
- package/src/__tests__/lip-sync-audio-rate.test.ts +74 -0
- package/src/__tests__/lip-sync-levers.test.ts +31 -0
- package/src/__tests__/llm-models.test.ts +132 -3
- package/src/__tests__/llm-price-key.test.ts +152 -1
- package/src/__tests__/nemotron-transcribe-pricing.test.ts +61 -0
- package/src/__tests__/normalize-node-params.test.ts +25 -0
- package/src/__tests__/pixverse-v6-max-catalog.test.ts +271 -0
- package/src/__tests__/prompt-length-limits.test.ts +4 -0
- package/src/__tests__/seedance-task-type.test.ts +13 -3
- package/src/__tests__/transcribe-capabilities.test.ts +39 -2
- package/src/__tests__/transcribe-preflight.test.ts +50 -1
- package/src/__tests__/video-audio-capability.test.ts +35 -6
- package/src/__tests__/video-resolution-billed-as-named.test.ts +30 -0
- package/src/__tests__/video-upscale-params.test.ts +62 -0
- package/src/catalog-projection.ts +8 -0
- package/src/credit-estimators/index.ts +10 -0
- package/src/credit-estimators/nemotron-transcribe.ts +87 -0
- package/src/credit-identifiers.ts +109 -35
- package/src/entries/credits.ts +12 -1
- package/src/entries/llm-models.ts +6 -0
- package/src/entries/model-catalog.ts +9 -0
- package/src/entries/models.ts +35 -0
- package/src/entries/nodes.ts +2 -0
- package/src/entries/video.ts +1 -1
- package/src/freecut-protocol.ts +8 -0
- package/src/lip-sync-levers.ts +56 -0
- package/src/lip-sync-pricing.ts +91 -1
- package/src/llm-models.ts +249 -4
- package/src/model-catalog.ts +250 -4
- package/src/model-constants.ts +277 -30
- package/src/model-tree.ts +2 -1
- package/src/nodaro-video-upscale.ts +48 -0
- package/src/node-default-mappings.ts +3 -0
- package/src/normalize-node-params.ts +49 -1
- package/src/runtime-config/contract.ts +10 -7
- package/src/seedance-draft.ts +2 -1
- package/src/transcribe-preflight.ts +58 -7
- package/src/video-duration.ts +9 -0
- package/src/video-ui-defaults.ts +5 -3
- package/src/video-upscale-params.ts +67 -0
- package/dist/chunk-2W745U4A.cjs.map +0 -1
- package/dist/chunk-3M4BNKFJ.cjs.map +0 -1
- package/dist/chunk-3OYO3XCC.js.map +0 -1
- package/dist/chunk-5YYN5X57.js.map +0 -1
- package/dist/chunk-6CSXMWL4.cjs.map +0 -1
- package/dist/chunk-6G7NN4S4.js.map +0 -1
- package/dist/chunk-AFYTX4AI.cjs.map +0 -1
- package/dist/chunk-AOJ6B7K4.cjs.map +0 -1
- package/dist/chunk-E2HZTGYX.js.map +0 -1
- package/dist/chunk-FVII3KHN.js.map +0 -1
- package/dist/chunk-GSFB537T.js.map +0 -1
- package/dist/chunk-IWWVPR3W.cjs.map +0 -1
- package/dist/chunk-KJSRPHJ2.cjs.map +0 -1
- package/dist/chunk-KYMHFVAZ.cjs.map +0 -1
- package/dist/chunk-MYJQELFN.cjs.map +0 -1
- package/dist/chunk-NGKKNSK6.js.map +0 -1
- package/dist/chunk-QWYFHQYK.cjs.map +0 -1
- package/dist/chunk-S24ZBUB4.js.map +0 -1
- package/dist/chunk-SYWR5G3T.js.map +0 -1
- package/dist/chunk-TRVWMKNE.cjs.map +0 -1
- package/dist/chunk-UDDVDQMF.js.map +0 -1
- package/dist/chunk-Y6X7UJSD.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { D as DeclaredSeedanceTaskType, j as ModelInputAdjustment } from './model-catalog-
|
|
2
|
+
import { D as DeclaredSeedanceTaskType, j as ModelInputAdjustment } from './model-catalog-C_Eo35tL.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Model constants shared between frontend and backend.
|
|
@@ -420,13 +420,13 @@ type ImageGenProvider = typeof IMAGE_GEN_PROVIDERS[number];
|
|
|
420
420
|
type ImageI2IProvider = typeof IMAGE_I2I_PROVIDERS[number];
|
|
421
421
|
type ImageEditProvider = typeof IMAGE_EDIT_PROVIDERS[number];
|
|
422
422
|
/** Image-to-video providers */
|
|
423
|
-
declare const IMAGE_TO_VIDEO_PROVIDERS: readonly ["minimax", "veo3", "veo3.1", "veo3_lite", "kling", "kling-turbo", "kling-3.0", "kling-master", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3", "hailuo-2.3-pro", "hailuo-2.3", "hailuo-standard", "wan-i2v", "wan-turbo", "bytedance-lite", "bytedance-pro", "bytedance-pro-fast", "grok-i2v", "wan-2.7-i2v", "happyhorse-i2v", "happyhorse-ref2v", "runway-kie", "kling-3-omni", "gemini-omni-video", "gemini-omni-flash", "gemini-omni-flash-1-2", "wan-3", "wan-3-prime", "vidu-q4", "kling-4", "kling-4-keyframes", "kling-4-flash", "ltx-2.3-pro", "ltx-2.3-fast", "grok-imagine-video-1.5"];
|
|
423
|
+
declare const IMAGE_TO_VIDEO_PROVIDERS: readonly ["minimax", "veo3", "veo3.1", "veo3_lite", "kling", "kling-turbo", "kling-3.0", "kling-master", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3", "hailuo-2.3-pro", "hailuo-2.3", "hailuo-standard", "wan-i2v", "wan-turbo", "bytedance-lite", "bytedance-pro", "bytedance-pro-fast", "grok-i2v", "wan-2.7-i2v", "happyhorse-i2v", "happyhorse-ref2v", "runway-kie", "kling-3-omni", "gemini-omni-video", "gemini-omni-flash", "gemini-omni-flash-1-2", "wan-3", "wan-3-prime", "vidu-q4", "kling-4", "kling-4-keyframes", "kling-4-flash", "pixverse-v6-max", "ltx-2.3-pro", "ltx-2.3-fast", "grok-imagine-video-1.5"];
|
|
424
424
|
type ImageToVideoProvider = typeof IMAGE_TO_VIDEO_PROVIDERS[number];
|
|
425
425
|
/** Text-to-video providers */
|
|
426
|
-
declare const TEXT_TO_VIDEO_PROVIDERS: readonly ["minimax", "veo3", "veo3.1", "veo3_lite", "kling", "kling-turbo", "kling-3.0", "grok", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3", "wan", "hailuo-standard", "bytedance-lite", "bytedance-pro", "wan-turbo", "wan-2.7-t2v", "happyhorse", "runway-kie", "gemini-omni-video", "gemini-omni-flash", "gemini-omni-flash-1-2", "wan-3", "wan-3-prime", "kling-4", "kling-4-keyframes", "kling-4-flash", "ltx-2.3-pro", "ltx-2.3-fast", "grok-imagine-video-1.5", "kling-3-omni", "kling-master", "hailuo-2.3", "hailuo-2.3-pro", "bytedance-pro-fast", "happyhorse-ref2v", "vidu-q4"];
|
|
426
|
+
declare const TEXT_TO_VIDEO_PROVIDERS: readonly ["minimax", "veo3", "veo3.1", "veo3_lite", "kling", "kling-turbo", "kling-3.0", "grok", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3", "wan", "hailuo-standard", "bytedance-lite", "bytedance-pro", "wan-turbo", "wan-2.7-t2v", "happyhorse", "runway-kie", "gemini-omni-video", "gemini-omni-flash", "gemini-omni-flash-1-2", "wan-3", "wan-3-prime", "kling-4", "kling-4-keyframes", "kling-4-flash", "pixverse-v6-max", "ltx-2.3-pro", "ltx-2.3-fast", "grok-imagine-video-1.5", "kling-3-omni", "kling-master", "hailuo-2.3", "hailuo-2.3-pro", "bytedance-pro-fast", "happyhorse-ref2v", "vidu-q4"];
|
|
427
427
|
type TextToVideoProvider = typeof TEXT_TO_VIDEO_PROVIDERS[number];
|
|
428
428
|
/** Unified video-generation providers (image-to-video ∪ text-to-video) for the generate-video node. */
|
|
429
|
-
declare const VIDEO_GEN_PROVIDERS: readonly ["minimax", "veo3", "veo3.1", "veo3_lite", "kling", "kling-turbo", "kling-3.0", "kling-master", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3", "hailuo-2.3-pro", "hailuo-2.3", "hailuo-standard", "wan-i2v", "wan-turbo", "bytedance-lite", "bytedance-pro", "bytedance-pro-fast", "grok-i2v", "wan-2.7-i2v", "happyhorse-i2v", "happyhorse-ref2v", "runway-kie", "kling-3-omni", "gemini-omni-video", "gemini-omni-flash", "gemini-omni-flash-1-2", "wan-3", "wan-3-prime", "vidu-q4", "kling-4", "kling-4-keyframes", "kling-4-flash", "ltx-2.3-pro", "ltx-2.3-fast", "grok-imagine-video-1.5", ...("seedance-2-5" | "minimax" | "veo3" | "kling-3.0" | "seedance-2" | "veo3.1" | "wan-turbo" | "bytedance-lite" | "kling-turbo" | "hailuo-standard" | "grok" | "minimax-h3" | "hailuo-2.3-pro" | "hailuo-2.3" | "veo3_lite" | "gemini-omni-video" | "gemini-omni-flash" | "gemini-omni-flash-1-2" | "kling" | "kling-master" | "kling-3-omni" | "kling-4" | "kling-4-keyframes" | "kling-4-flash" | "grok-imagine-video-1.5" | "seedance-2-fast" | "seedance-2-mini" | "wan-3" | "wan-3-prime" | "wan" | "wan-2.7-t2v" | "ltx-2.3-pro" | "ltx-2.3-fast" | "happyhorse" | "happyhorse-ref2v" | "vidu-q4" | "bytedance-pro" | "bytedance-pro-fast" | "runway-kie")[]];
|
|
429
|
+
declare const VIDEO_GEN_PROVIDERS: readonly ["minimax", "veo3", "veo3.1", "veo3_lite", "kling", "kling-turbo", "kling-3.0", "kling-master", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3", "hailuo-2.3-pro", "hailuo-2.3", "hailuo-standard", "wan-i2v", "wan-turbo", "bytedance-lite", "bytedance-pro", "bytedance-pro-fast", "grok-i2v", "wan-2.7-i2v", "happyhorse-i2v", "happyhorse-ref2v", "runway-kie", "kling-3-omni", "gemini-omni-video", "gemini-omni-flash", "gemini-omni-flash-1-2", "wan-3", "wan-3-prime", "vidu-q4", "kling-4", "kling-4-keyframes", "kling-4-flash", "pixverse-v6-max", "ltx-2.3-pro", "ltx-2.3-fast", "grok-imagine-video-1.5", ...("seedance-2-5" | "minimax" | "veo3" | "kling-3.0" | "seedance-2" | "veo3.1" | "wan-turbo" | "bytedance-lite" | "kling-turbo" | "hailuo-standard" | "grok" | "minimax-h3" | "hailuo-2.3-pro" | "hailuo-2.3" | "veo3_lite" | "gemini-omni-video" | "gemini-omni-flash" | "gemini-omni-flash-1-2" | "kling" | "kling-master" | "kling-3-omni" | "kling-4" | "kling-4-keyframes" | "kling-4-flash" | "grok-imagine-video-1.5" | "seedance-2-fast" | "seedance-2-mini" | "wan-3" | "wan-3-prime" | "wan" | "wan-2.7-t2v" | "ltx-2.3-pro" | "ltx-2.3-fast" | "happyhorse" | "happyhorse-ref2v" | "vidu-q4" | "pixverse-v6-max" | "bytedance-pro" | "bytedance-pro-fast" | "runway-kie")[]];
|
|
430
430
|
type VideoGenProvider = typeof VIDEO_GEN_PROVIDERS[number];
|
|
431
431
|
/**
|
|
432
432
|
* Video models that expose DISTINCT provider ids per mode (text-to-video vs
|
|
@@ -622,20 +622,36 @@ declare const SEEDANCE_VIDEO_EDIT_TASK_TYPE: "edit";
|
|
|
622
622
|
declare const FACE_SWAP_PROVIDERS: readonly ["roop"];
|
|
623
623
|
type FaceSwapProvider = typeof FACE_SWAP_PROVIDERS[number];
|
|
624
624
|
/** Video upscale providers */
|
|
625
|
-
declare const VIDEO_UPSCALE_PROVIDERS: readonly ["topaz", "veo-1080p", "veo-4k", "seedance-2-5-hd"];
|
|
625
|
+
declare const VIDEO_UPSCALE_PROVIDERS: readonly ["topaz", "veo-1080p", "veo-4k", "seedance-2-5-hd", "nodaro-video-upscale"];
|
|
626
626
|
type VideoUpscaleProvider = typeof VIDEO_UPSCALE_PROVIDERS[number];
|
|
627
627
|
/** Extend video providers */
|
|
628
|
-
declare const EXTEND_VIDEO_PROVIDERS: readonly ["veo-extend", "runway-extend", "ltx-2.3-pro", "seedance-2-5-extend", "seedance-2-0-extend"];
|
|
628
|
+
declare const EXTEND_VIDEO_PROVIDERS: readonly ["veo-extend", "runway-extend", "ltx-2.3-pro", "seedance-2-5-extend", "seedance-2-0-extend", "kling-4-extend"];
|
|
629
629
|
type ExtendVideoProvider = typeof EXTEND_VIDEO_PROVIDERS[number];
|
|
630
630
|
/** The Extend Video providers that run on Seedance, one per model. */
|
|
631
631
|
type SeedanceExtendProvider = Extract<ExtendVideoProvider, "seedance-2-5-extend" | "seedance-2-0-extend">;
|
|
632
632
|
/**
|
|
633
633
|
* Whether a value is one of the Seedance Extend Video providers. A retired id
|
|
634
|
-
* answers false: pass it through {@link canonicalVideoProvider} first.
|
|
634
|
+
* answers false: pass it through {@link canonicalVideoProvider} first. It
|
|
635
|
+
* decides the levers only Seedance has (reference images, the sound switch);
|
|
636
|
+
* the length, the resolution and the price follow {@link isTailExtendProvider}.
|
|
635
637
|
*/
|
|
636
638
|
declare function isSeedanceExtendProvider(p: unknown): p is SeedanceExtendProvider;
|
|
639
|
+
/**
|
|
640
|
+
* The Extend Video providers that continue a video from its tail: the
|
|
641
|
+
* source's last frame opens the new footage and its last seconds ride as the
|
|
642
|
+
* `@video_1` reference, then the two are stitched into one clip. Each has its
|
|
643
|
+
* own catalog entry (its seconds added and resolutions) and price rows, one
|
|
644
|
+
* per second and resolution (`tailExtendCreditId`).
|
|
645
|
+
*/
|
|
646
|
+
type TailExtendProvider = SeedanceExtendProvider | Extract<ExtendVideoProvider, "kling-4-extend">;
|
|
647
|
+
/**
|
|
648
|
+
* Whether a value is one of the tail-recipe Extend Video providers
|
|
649
|
+
* ({@link TailExtendProvider}). A retired id answers false: pass it through
|
|
650
|
+
* {@link canonicalVideoProvider} first.
|
|
651
|
+
*/
|
|
652
|
+
declare function isTailExtendProvider(p: unknown): p is TailExtendProvider;
|
|
637
653
|
/** Lip sync providers */
|
|
638
|
-
declare const LIP_SYNC_PROVIDERS: readonly ["kling-avatar", "kling-avatar-pro", "infinitalk", "omnihuman-1-5", "latentsync", "wav2lip", "video-retalking", "sadtalker", "heygen-lipsync-precision", "lipsync-2-pro", "sync-lipsync-v3", "volcengine-lipsync", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3"];
|
|
654
|
+
declare const LIP_SYNC_PROVIDERS: readonly ["kling-avatar", "kling-avatar-pro", "infinitalk", "omnihuman-1-5", "omnihuman-2-0", "latentsync", "wav2lip", "video-retalking", "sadtalker", "heygen-lipsync-precision", "lipsync-2-pro", "sync-lipsync-v3", "volcengine-lipsync", "seedance-2", "seedance-2-fast", "seedance-2-mini", "seedance-2-5", "minimax-h3"];
|
|
639
655
|
type LipSyncProvider = typeof LIP_SYNC_PROVIDERS[number];
|
|
640
656
|
/** Multimodal video models exposed via the lip-sync surface (Seedance 2 family
|
|
641
657
|
* + MiniMax Hailuo 3). They go through the i2v provider with the audio
|
|
@@ -740,9 +756,10 @@ declare function resolveMusicProvider(value: unknown): MusicProvider;
|
|
|
740
756
|
* (the canvas picker re-offered the two Replicate lanes in #768 while this enum
|
|
741
757
|
* still hid them, so a single-node Run on Whisper 400'd where the same node in a
|
|
742
758
|
* workflow Run worked). `elevenlabs-stt` stays FIRST: several call sites take
|
|
743
|
-
* "the first enabled word-capable provider" from this order.
|
|
759
|
+
* "the first enabled word-capable provider" from this order. A new engine goes
|
|
760
|
+
* at the END (Nemotron 3.5 Transcribe, 2026-11-12), so that answer never moves.
|
|
744
761
|
*/
|
|
745
|
-
declare const TRANSCRIBE_PROVIDERS: readonly ["elevenlabs-stt", "whisper", "incredibly-fast-whisper"];
|
|
762
|
+
declare const TRANSCRIBE_PROVIDERS: readonly ["elevenlabs-stt", "whisper", "incredibly-fast-whisper", "nemotron-3-5-transcribe"];
|
|
746
763
|
type TranscribeProvider = typeof TRANSCRIBE_PROVIDERS[number];
|
|
747
764
|
/**
|
|
748
765
|
* Every transcription LANE the platform implements. Today this is the same set
|
|
@@ -752,8 +769,19 @@ type TranscribeProvider = typeof TRANSCRIBE_PROVIDERS[number];
|
|
|
752
769
|
* while still reached at runtime via the route default and add-captions'
|
|
753
770
|
* auto-transcribe). Capability questions must be asked over THIS union.
|
|
754
771
|
*/
|
|
755
|
-
declare const TRANSCRIBE_LANES: readonly ["whisper", "incredibly-fast-whisper", "elevenlabs-stt"];
|
|
772
|
+
declare const TRANSCRIBE_LANES: readonly ["whisper", "incredibly-fast-whisper", "elevenlabs-stt", "nemotron-3-5-transcribe"];
|
|
756
773
|
type TranscribeLane = typeof TRANSCRIBE_LANES[number];
|
|
774
|
+
/**
|
|
775
|
+
* The lanes Add Captions may transcribe on (its `transcribe_provider`, on the
|
|
776
|
+
* route, MCP `add_captions` and the SDK's `media.addCaptions`). Add Captions
|
|
777
|
+
* charges its own flat render price (`add-captions`, `add-captions:kinetic`)
|
|
778
|
+
* and reserves nothing for the transcription it runs inside, so a lane priced
|
|
779
|
+
* by the file's length (Nemotron 3.5 Transcribe, per minute) is not one of
|
|
780
|
+
* them: it would run unpriced inside the render. Kept to the lanes it offered
|
|
781
|
+
* before Nemotron (2026-11-12); widening it is a pricing decision, not a sync.
|
|
782
|
+
*/
|
|
783
|
+
declare const CAPTION_TRANSCRIBE_LANES: readonly ["whisper", "incredibly-fast-whisper", "elevenlabs-stt"];
|
|
784
|
+
type CaptionTranscribeLane = typeof CAPTION_TRANSCRIBE_LANES[number];
|
|
757
785
|
/**
|
|
758
786
|
* What each transcription lane can actually DO. Single source of truth — never
|
|
759
787
|
* re-derive a capability from a provider-name check.
|
|
@@ -765,10 +793,32 @@ type TranscribeLane = typeof TRANSCRIBE_LANES[number];
|
|
|
765
793
|
* for word timings yields an empty array, never an error.
|
|
766
794
|
* - `incredibly-fast-whisper` — yes, via `timestamp: "word"`.
|
|
767
795
|
* - `elevenlabs-stt` (direct Scribe) — always word-level, flag or not.
|
|
796
|
+
* - `nemotron-3-5-transcribe` (KIE) — yes, with a speaker per word, via
|
|
797
|
+
* `timestamps: true` (transcription only: never with a translation).
|
|
798
|
+
*
|
|
799
|
+
* `translation`: can the lane translate the speech instead of transcribing it
|
|
800
|
+
* (`targetLanguage`)? Only Nemotron 3.5 Transcribe, to or from English, and
|
|
801
|
+
* never together with word timings (KIE refuses the pair).
|
|
768
802
|
*/
|
|
769
803
|
declare const TRANSCRIBE_PROVIDER_CAPABILITIES: Record<TranscribeLane, {
|
|
770
804
|
wordTimestamps: boolean;
|
|
805
|
+
translation: boolean;
|
|
771
806
|
}>;
|
|
807
|
+
/**
|
|
808
|
+
* The languages Nemotron 3.5 Transcribe translates INTO (KIE's
|
|
809
|
+
* `target_language` enum, ISO 639-1). Translation is supported to or from
|
|
810
|
+
* English: other speech into `en`, or English speech into any other listed
|
|
811
|
+
* language. Fewer than the 40 it transcribes.
|
|
812
|
+
*/
|
|
813
|
+
declare const TRANSCRIBE_TARGET_LANGUAGES: readonly ["en", "zh", "ja", "ko", "fr", "de", "es", "pt", "it", "ru", "nl", "pl", "cs", "sk", "hi", "bg", "hr", "da", "et", "fi", "hu", "lv", "lt", "ro", "sl", "sv", "th", "uk", "ar", "el", "he", "mt"];
|
|
814
|
+
type TranscribeTargetLanguage = typeof TRANSCRIBE_TARGET_LANGUAGES[number];
|
|
815
|
+
/** The lanes that can translate, in declaration order. */
|
|
816
|
+
declare function transcribeProvidersWithTranslation(): TranscribeLane[];
|
|
817
|
+
/**
|
|
818
|
+
* Capability question for a lane id from UNTRUSTED data (node data, an
|
|
819
|
+
* imported workflow, a wire body): an unknown lane answers `false`.
|
|
820
|
+
*/
|
|
821
|
+
declare function transcribeLaneSupportsTranslation(lane: string | null | undefined): boolean;
|
|
772
822
|
/** The lanes that can honour a word-timestamps request, in declaration order. */
|
|
773
823
|
declare function transcribeProvidersWithWordTimestamps(): TranscribeLane[];
|
|
774
824
|
/**
|
|
@@ -1066,6 +1116,27 @@ declare const GROK_VIDEO_15_DEFAULT_RESOLUTION = "480p";
|
|
|
1066
1116
|
declare function normalizeGrokVideo15Resolution(resolution: string | undefined): "480p" | "720p" | "1080p";
|
|
1067
1117
|
/** Most in-between frames Grok Imagine Video 1.5 takes (KIE `keyframes`). */
|
|
1068
1118
|
declare const GROK_VIDEO_15_MAX_MIDDLE_FRAMES = 4;
|
|
1119
|
+
/**
|
|
1120
|
+
* PixVerse V6 Max — ONE Nodaro id over KIE's two V6 Max endpoints
|
|
1121
|
+
* (`pixverse-v6-max/image-to-video` with a start frame,
|
|
1122
|
+
* `pixverse-v6-max/text-to-video` without one), built by the backend's bespoke
|
|
1123
|
+
* runner (`kie/pixverse-v6-max.ts`).
|
|
1124
|
+
*/
|
|
1125
|
+
declare const PIXVERSE_V6_MAX_PROVIDER = "pixverse-v6-max";
|
|
1126
|
+
declare function isPixverseV6MaxProvider(provider: string | undefined): provider is "pixverse-v6-max";
|
|
1127
|
+
/** PixVerse V6 Max quality rendered when the param is omitted or unknown — the
|
|
1128
|
+
* tier the bare credit identifier prices. Never `resolutions[0]`, the 360p
|
|
1129
|
+
* preview tier. (KIE requires a quality; it has no default of its own.) */
|
|
1130
|
+
declare const PIXVERSE_V6_MAX_DEFAULT_QUALITY = "720p";
|
|
1131
|
+
/**
|
|
1132
|
+
* SINGLE normalization for the PixVerse V6 Max quality lever (KIE `quality`,
|
|
1133
|
+
* the platform's `resolution`). The wire enum is lowercase (`360p` | `540p` |
|
|
1134
|
+
* `720p` | `1080p`), the same spelling as the catalog and the credit
|
|
1135
|
+
* identifiers; this folds case and collapses anything else to
|
|
1136
|
+
* {@link PIXVERSE_V6_MAX_DEFAULT_QUALITY}. The runner sends what this returns
|
|
1137
|
+
* and the credit identifier bills what this returns.
|
|
1138
|
+
*/
|
|
1139
|
+
declare function normalizePixverseV6MaxQuality(resolution: string | undefined): "360p" | "540p" | "720p" | "1080p";
|
|
1069
1140
|
/**
|
|
1070
1141
|
* How many in-between frames a Grok Imagine Video 1.5 clip of `durationSec`
|
|
1071
1142
|
* seconds carries. The node has no per-frame time, so the frames sit at whole
|
|
@@ -1201,7 +1272,7 @@ type GvpAnchorWireMode = "upfront" | "progressive" | "none";
|
|
|
1201
1272
|
* here would mean duplicating the plugin's `MAX_SEGMENTS` cap in this repo
|
|
1202
1273
|
* where nothing could keep the two in step.
|
|
1203
1274
|
*/
|
|
1204
|
-
declare function resolveGvpAnchorWire(choice: string | undefined): GvpAnchorWireMode | undefined;
|
|
1275
|
+
declare function resolveGvpAnchorWire(choice: string | undefined, provider?: string): GvpAnchorWireMode | undefined;
|
|
1205
1276
|
/** Allowed single-segment durations (seconds, ascending) for a pro provider.
|
|
1206
1277
|
* Empty for anything not in the catalog — callers treat that as ineligible
|
|
1207
1278
|
* rather than falling back to a window the provider may reject. */
|
|
@@ -1664,8 +1735,9 @@ type VideoAudioMode = "none" | "ambient" | "native_speech" | "audio_driven";
|
|
|
1664
1735
|
interface VideoAudioCapability {
|
|
1665
1736
|
mode: VideoAudioMode;
|
|
1666
1737
|
/** Provider-option field carrying the on/off toggle, when user-controllable.
|
|
1667
|
-
* `audio` is Wan 3.0's own boolean lever (KIE `input.audio`, default true)
|
|
1668
|
-
|
|
1738
|
+
* `audio` is Wan 3.0's own boolean lever (KIE `input.audio`, default true);
|
|
1739
|
+
* `generateAudioSwitch` is PixVerse V6 Max's (KIE `input.generate_audio_switch`). */
|
|
1740
|
+
field?: "generateAudio" | "sound" | "audio" | "generateAudioSwitch";
|
|
1669
1741
|
/** Audio is always produced and can't be turned off by the user (VEO 3.x). */
|
|
1670
1742
|
alwaysOn?: boolean;
|
|
1671
1743
|
/** Enabling audio raises the credit cost (Kling — see AUDIO_ADDON_PROVIDERS). */
|
|
@@ -1678,6 +1750,20 @@ interface VideoAudioCapability {
|
|
|
1678
1750
|
* (see buildVideoCreditModelIdentifier). Absent ⇒ default off.
|
|
1679
1751
|
*/
|
|
1680
1752
|
defaultOn?: boolean;
|
|
1753
|
+
/**
|
|
1754
|
+
* A cost-affecting model whose audio intent the `generateAudio` request field
|
|
1755
|
+
* also carries, after `sound` (PixVerse V6 Max, decided 2026-11-12: the
|
|
1756
|
+
* Generate Video Pro engine sends only `generateAudio`). Read through
|
|
1757
|
+
* {@link videoAudioIntent}, so the switch the model gets and the `:audio`
|
|
1758
|
+
* row the run is priced at follow the same fields. Absent on Kling, which
|
|
1759
|
+
* keeps reading `sound` alone.
|
|
1760
|
+
*/
|
|
1761
|
+
readsGenerateAudio?: true;
|
|
1762
|
+
}
|
|
1763
|
+
/** The audio fields a video request carries: `sound` (canonical) and the older `generateAudio`. */
|
|
1764
|
+
interface VideoAudioRequest {
|
|
1765
|
+
readonly sound?: boolean;
|
|
1766
|
+
readonly generateAudio?: boolean;
|
|
1681
1767
|
}
|
|
1682
1768
|
/**
|
|
1683
1769
|
* Per-model audio capability. Only models that produce SOME audio are listed;
|
|
@@ -1706,6 +1792,25 @@ declare function videoModelSupportsAudio(model: string | undefined): boolean;
|
|
|
1706
1792
|
* return `false` — their audio is SFX, not speech.
|
|
1707
1793
|
*/
|
|
1708
1794
|
declare function videoModelCanSpeakDialogue(model: string | undefined): boolean;
|
|
1795
|
+
/**
|
|
1796
|
+
* THE audio intent of a video request for one model — `undefined` when the
|
|
1797
|
+
* request expresses none (the model's own default then applies). The ONE
|
|
1798
|
+
* reading of the request's audio fields: {@link applyVideoAudioToggle} (what
|
|
1799
|
+
* the model is SENT) and `buildVideoCreditModelIdentifier` (the `:audio` row
|
|
1800
|
+
* it is PRICED at) both resolve through it, so the two cannot disagree.
|
|
1801
|
+
*
|
|
1802
|
+
* - A cost-affecting model reads `sound` alone (Kling: the field its `:audio`
|
|
1803
|
+
* surcharge has always keyed off), unless it declares `readsGenerateAudio`
|
|
1804
|
+
* (PixVerse V6 Max): then `sound`, else `generateAudio`.
|
|
1805
|
+
* - Every other model reads `sound`, else the `generateAudio` alias.
|
|
1806
|
+
*/
|
|
1807
|
+
declare function videoAudioIntent(provider: string | undefined, req: VideoAudioRequest | undefined): boolean | undefined;
|
|
1808
|
+
/**
|
|
1809
|
+
* Whether a request PRICES with audio on a cost-affecting model: its intent
|
|
1810
|
+
* ({@link videoAudioIntent}), else the model's own default (`defaultOn`). The
|
|
1811
|
+
* provider runner of such a model renders the same state.
|
|
1812
|
+
*/
|
|
1813
|
+
declare function videoAudioPricedOn(provider: string | undefined, req: VideoAudioRequest | undefined): boolean;
|
|
1709
1814
|
/**
|
|
1710
1815
|
* Write the caller's neutral "enable native audio" intent onto a KIE provider
|
|
1711
1816
|
* `input` under whichever field the chosen model actually reads, per
|
|
@@ -1717,12 +1822,12 @@ declare function videoModelCanSpeakDialogue(model: string | undefined): boolean;
|
|
|
1717
1822
|
* - `sound` is the canonical neutral name; `generateAudio` is accepted as a
|
|
1718
1823
|
* legacy alias (the workflow node + some clients send that key). `sound` wins
|
|
1719
1824
|
* if both are present.
|
|
1720
|
-
* - **
|
|
1721
|
-
*
|
|
1722
|
-
*
|
|
1723
|
-
*
|
|
1724
|
-
*
|
|
1725
|
-
*
|
|
1825
|
+
* - **The intent is {@link videoAudioIntent}'s** — the same reading the `:audio`
|
|
1826
|
+
* credit surcharge (`AUDIO_ADDON_PROVIDERS` in `credit-identifiers.ts`) is
|
|
1827
|
+
* built from. That makes a billed-but-not-generated (or generated-but-not-
|
|
1828
|
+
* billed) divergence structurally impossible: the model and the surcharge
|
|
1829
|
+
* read the same fields. Kling honours ONLY `sound`; PixVerse V6 Max
|
|
1830
|
+
* (`readsGenerateAudio`) and every free model also the `generateAudio` alias.
|
|
1726
1831
|
* - No-op for `alwaysOn` models (VEO — audio can't be toggled) and silent /
|
|
1727
1832
|
* unlisted models (no `field`), and when the caller expressed no intent
|
|
1728
1833
|
* (leaves the model's own default in place).
|
|
@@ -1739,8 +1844,9 @@ declare function applyVideoAudioToggle(input: Record<string, unknown>, provider:
|
|
|
1739
1844
|
* Video variable pricing config — which params affect credit cost per model.
|
|
1740
1845
|
* "duration" = cost varies by video length
|
|
1741
1846
|
* "duration+audio" = cost varies by length AND audio on/off
|
|
1847
|
+
* "duration+resolution+audio" = cost varies by length, resolution AND audio on/off
|
|
1742
1848
|
*/
|
|
1743
|
-
declare const VIDEO_VARIABLE_PRICING: Record<string, "duration" | "duration+audio" | "duration+mode" | "duration+resolution+ref" | "duration+resolution">;
|
|
1849
|
+
declare const VIDEO_VARIABLE_PRICING: Record<string, "duration" | "duration+audio" | "duration+mode" | "duration+resolution+ref" | "duration+resolution" | "duration+resolution+audio">;
|
|
1744
1850
|
/**
|
|
1745
1851
|
* @deprecated Read {@link pricedOutputDurationSec} (or the catalog's
|
|
1746
1852
|
* `defaultDuration`). Kept only as a derived view of `MODEL_CATALOG` for
|
|
@@ -1794,7 +1900,11 @@ interface SeedanceTaskTypeFacts {
|
|
|
1794
1900
|
provider: string | undefined;
|
|
1795
1901
|
/** The value the request carries, unvalidated: anything but a declared value is Auto. */
|
|
1796
1902
|
requested: unknown;
|
|
1797
|
-
|
|
1903
|
+
/**
|
|
1904
|
+
* @deprecated Not read: a draft declares exactly as any other run does. Kept
|
|
1905
|
+
* so a caller that still passes it compiles; leave it out.
|
|
1906
|
+
*/
|
|
1907
|
+
draft?: boolean;
|
|
1798
1908
|
/** Reference images only: a start or end frame is not counted. */
|
|
1799
1909
|
referenceImageCount: number;
|
|
1800
1910
|
referenceAudioCount: number;
|
|
@@ -1841,7 +1951,6 @@ declare function seedanceTaskTypeFitsMedia(type: DeclaredSeedanceTaskType, media
|
|
|
1841
1951
|
* LISTS, matched exactly. The list is what is honoured: a model that lists
|
|
1842
1952
|
* nothing, a value it does not list (`auto`, a wrong case, a number) and a
|
|
1843
1953
|
* model that lists only some values are all Auto;
|
|
1844
|
-
* - the run is not a draft;
|
|
1845
1954
|
* - it has the reference media the type needs
|
|
1846
1955
|
* ({@link seedanceTaskTypeFitsMedia}): `edit` and `extend` need a
|
|
1847
1956
|
* reference video;
|
|
@@ -1859,7 +1968,11 @@ declare function seedanceTaskTypeFitsMedia(type: DeclaredSeedanceTaskType, media
|
|
|
1859
1968
|
* Each value it changes is reported as one adjustment; a value it fills where
|
|
1860
1969
|
* the request had none is not a correction and reports nothing, and neither is
|
|
1861
1970
|
* a ratio that already runs at the forced one (`"Auto"` with a reference video
|
|
1862
|
-
* runs at `"adaptive"`).
|
|
1971
|
+
* runs at `"adaptive"`).
|
|
1972
|
+
*
|
|
1973
|
+
* A draft (`draft: true`) is no exception: it declares, and is forced, exactly
|
|
1974
|
+
* as the same request without Draft (a draft and its 1080p finalize keep an
|
|
1975
|
+
* edit's own length and framing, measured). Pure.
|
|
1863
1976
|
*/
|
|
1864
1977
|
declare function resolveSeedanceTaskType(facts: SeedanceTaskTypeFacts): SeedanceTaskTypeResolution;
|
|
1865
1978
|
/** The longest clip a duration-tiered provider can render (its top priced tier). */
|
|
@@ -2035,4 +2148,4 @@ declare function applyDefaultVideoSelection<D>(input: {
|
|
|
2035
2148
|
duration: D | number | undefined;
|
|
2036
2149
|
};
|
|
2037
2150
|
|
|
2038
|
-
export {
|
|
2151
|
+
export { IMAGE_ASPECT_RATIO_VALUES as $, AI_WRITER_PROVIDERS as A, FAL_LIP_SYNC_PROVIDERS as B, CAPTION_TRANSCRIBE_LANES as C, DEFAULT_DIALOGUE_PROVIDER as D, EXTEND_VIDEO_PROVIDERS as E, FACE_SWAP_PROVIDERS as F, FLEXIBLE_INPUT_LIP_SYNC_PROVIDERS as G, FRAME_MODE_ADAPTIVE_ONLY_ASPECT as H, type FaceSwapProvider as I, GEMINI_OMNI_12_MAX_SOURCE_SEC as J, GEMINI_OMNI_PER_SECOND_PROVIDERS as K, GEMINI_OMNI_PROVIDERS as L, GROK_VIDEO_15_DEFAULT_RESOLUTION as M, GROK_VIDEO_15_MAX_MIDDLE_FRAMES as N, GROK_VIDEO_15_PROVIDER as O, GUIDANCE_SCALE_SUPPORT as P, GVP_ANCHOR_CHOICES as Q, GVP_DEFAULT_PROVIDER as R, GVP_END_FRAME_PROVIDERS as S, GVP_EXTEND_PROVIDERS as T, GVP_SUPPORTED_PROVIDERS as U, type GvpAnchorChoice as V, type GvpAnchorWireMode as W, HIGH_QUALITY_PROVIDERS as X, I2I_MASK_SUPPORT as Y, I2I_STRENGTH_SUPPORT as Z, IDEOGRAM_PROVIDERS as _, ASPECT_RATIO_DIMENSIONS as a, type ObjectMotionProvider as a$, IMAGE_BACKGROUND_VALUES as a0, IMAGE_EDIT_PROVIDERS as a1, IMAGE_EDIT_TARGET_RESOLUTION_VALUES as a2, IMAGE_GEN_PROVIDERS as a3, IMAGE_I2I_PROVIDERS as a4, IMAGE_K_RESOLUTION_VALUES as a5, IMAGE_MASK_MODE as a6, IMAGE_OUTPUT_FORMAT_EXT as a7, IMAGE_OUTPUT_FORMAT_MIME as a8, IMAGE_OUTPUT_FORMAT_VALUES as a9, LLM_TEXT_INPUT_MAX as aA, LOCATION_ATMOSPHERE_PROVIDERS as aB, type LipSyncProvider as aC, type LocationAtmosphereProvider as aD, MAX_IMAGE_PROMPT_CHARS_BY_PROVIDER as aE, MAX_NEGATIVE_PROMPT_CHARS_BY_PROVIDER as aF, MAX_REQUEST_IMAGE_LIMIT as aG, MAX_TTS_CHARS_BY_PROVIDER as aH, MAX_VIDEO_PROMPT_CHARS_BY_PROVIDER as aI, MINIMAX_H3_DEFAULT_RESOLUTION as aJ, MINIMAX_H3_PROVIDERS as aK, MIN_IMAGE_PROMPT_CHARS_BY_PROVIDER as aL, MODELS_WITH_REFERENCE_IMAGE_SUPPORT as aM, MODIFY_IMAGE_PROVIDERS as aN, MOTION_TRANSFER_PROVIDERS as aO, MUSIC_CREDIT_ID as aP, MUSIC_PROVIDERS as aQ, MUSIC_PROVIDER_LABELS as aR, type ModelPromptingStyle as aS, type ModifyImageProvider as aT, type MotionTransferProviderType as aU, type MusicProvider as aV, NATIVE_ADAPTIVE_ASPECT as aW, NATIVE_NEGATIVE_PROMPT_MODELS as aX, NATIVE_NEGATIVE_VIDEO_PROVIDERS as aY, NEGATIVE_PROMPT_MAX as aZ, OBJECT_MOTION_PROVIDERS as a_, IMAGE_PROMPT_MAX as aa, IMAGE_QUALITY_VALUES as ab, IMAGE_RENDERING_SPEED_VALUES as ac, IMAGE_RESOLUTION_VALUES as ad, IMAGE_SVG_LEVEL_VALUES as ae, IMAGE_TO_VIDEO_PROVIDERS as af, type ImageAspectRatio as ag, type ImageBackground as ah, type ImageEditProvider as ai, type ImageEditTargetResolution as aj, type ImageGenProvider as ak, type ImageI2IProvider as al, type ImageMaskMode as am, type ImageOutputFormat as an, type ImageQuality as ao, type ImageRenderingSpeed as ap, type ImageResolution as aq, type ImageSvgLevel as ar, type ImageToVideoProvider as as, KLING_4_DEFAULT_RESOLUTION as at, KLING_4_FLASH_PROVIDER as au, KLING_4_FLASH_RESOLUTION as av, KLING_4_MAX_MIDDLE_FRAMES as aw, KLING_4_PROVIDERS as ax, LIP_SYNC_PROVIDERS as ay, LLM_STRUCTURED_SYSTEM_MAX as az, AUDIO_ADDON_PROVIDERS as b, type TextToVideoProvider as b$, PIXVERSE_V6_MAX_DEFAULT_QUALITY as b0, PIXVERSE_V6_MAX_PROVIDER as b1, PRICING_DEFAULT_DURATION_SEC as b2, PRICING_DEFAULT_RESOLUTION as b3, PROMPT_HARD_CEILING as b4, QA_CHECK_PROVIDERS as b5, type QaCheckProvider as b6, REF_IMAGE_MAX_LIMITS as b7, RENDERING_SPEED_SUPPORT as b8, REPLICATE_LIP_SYNC_PROVIDERS as b9, type SceneInputMode as bA, SceneInputModeSchema as bB, type ScriptProvider as bC, type SeedanceExtendProvider as bD, type SeedanceReferenceMediaCount as bE, type SeedanceTaskTypeFacts as bF, type SeedanceTaskTypeResolution as bG, type SeedanceVideoEditProvider as bH, type SunoAddTrackModel as bI, type SunoModel as bJ, T2I_TO_I2I_VARIANT as bK, TASK_CHAINED_EDIT_PROVIDERS as bL, TASK_CHAINED_EDIT_PROVIDER_IDS as bM, TEXT_TO_AUDIO_PROVIDERS as bN, TEXT_TO_VIDEO_PROVIDERS as bO, TRANSCRIBE_LANES as bP, TRANSCRIBE_PROVIDERS as bQ, TRANSCRIBE_PROVIDER_CAPABILITIES as bR, TRANSCRIBE_TARGET_LANGUAGES as bS, TTS_OUTPUT_FORMATS as bT, TTS_OUTPUT_FORMAT_FILES as bU, TTS_PROVIDERS as bV, TTS_TEXT_MAX as bW, TWO_K_RESOLUTION_PROVIDERS as bX, type TailExtendProvider as bY, type TaskChainedEditProvider as bZ, type TextToAudioProvider as b_, RETIRED_VIDEO_PROVIDERS as ba, type RefAudioCheck as bb, type RefAudioProbe as bc, type RefAudioRule as bd, type RefVideoDurationLimit as be, SCRIPT_PROVIDERS as bf, SEEDANCE_2_5_REF_LIMITS as bg, SEEDANCE_2_CONTINUATION_REF_SEC as bh, SEEDANCE_2_EXTEND_STITCH as bi, SEEDANCE_2_PROVIDERS as bj, SEEDANCE_2_R2V_MAX_AUDIO_SEC_BY_PROVIDER as bk, SEEDANCE_2_R2V_MIN_REF_VIDEO_SEC as bl, SEEDANCE_2_REF_LIMITS as bm, SEEDANCE_LIP_SYNC_PROVIDERS as bn, SEEDANCE_VIDEO_EDIT_PROVIDERS as bo, SEEDANCE_VIDEO_EDIT_SHAPE as bp, SEEDANCE_VIDEO_EDIT_TASK_TYPE as bq, SEED_SUPPORT as br, SUNO_ACTIVE_MODELS as bs, SUNO_ADD_TRACK_MODELS as bt, SUNO_DURATION_MODELS as bu, SUNO_HARD_CEILING as bv, SUNO_LEGACY_MODELS as bw, SUNO_MODELS as bx, SUNO_TEXT_MAX as by, SUNO_TITLE_MAX as bz, type AiWriterProvider as c, grokVideo15MiddleFrameSlots as c$, type TranscribeLane as c0, type TranscribeProvider as c1, type TranscribeTargetLanguage as c2, type TtsOutputFormat as c3, type TtsProvider as c4, UPSCALE_IMAGE_PROVIDERS as c5, type UpscaleImageProvider as c6, VARIABLE_PRICING_MODELS as c7, VEO_PROVIDERS as c8, VIDEO_AUDIO_CAPABILITY as c9, type VideoModeAlias as cA, type VideoModelCapabilities as cB, type VideoReferenceSyntax as cC, type VideoStartFrameOnlyProblem as cD, type VideoToVideoNodeProvider as cE, type VideoToVideoProvider as cF, type VideoUpscaleProvider as cG, type VoiceDesignModel as cH, WAN_3_DEFAULT_RESOLUTION as cI, WAN_3_PROVIDERS as cJ, applyDefaultVideoSelection as cK, applyVideoAudioToggle as cL, applyVideoNegativePrompt as cM, billsReferenceVideoSeconds as cN, canonicalVideoProvider as cO, checkRefAudioRules as cP, checkRefVideoDurations as cQ, defaultVideoAspectRatio as cR, findSeedance2AudioOverLimit as cS, getMaxImagePromptChars as cT, getMaxNegativePromptChars as cU, getMaxSunoPromptChars as cV, getMaxSunoStyleChars as cW, getMaxTtsChars as cX, getMaxVideoPromptChars as cY, getMinImagePromptChars as cZ, getVideoAudioCapability as c_, VIDEO_DURATION_TIERS as ca, VIDEO_GEN_COLLAPSED_T2V_IDS as cb, VIDEO_GEN_PROVIDERS as cc, VIDEO_INPUT_LIP_SYNC_PROVIDERS as cd, VIDEO_MODEL_CAPS as ce, VIDEO_MODE_ALIASES as cf, VIDEO_PROMPT_MAX as cg, VIDEO_PROVIDERS_REQUIRING_IMAGE as ch, VIDEO_PROVIDERS_WITHOUT_DISPATCH as ci, VIDEO_PROVIDERS_WITH_SEPARATE_FRAME_CHANNEL as cj, VIDEO_REF_AUDIO_RULES as ck, VIDEO_REF_LIMITS_BY_PROVIDER as cl, VIDEO_REF_RATE_PROVIDERS as cm, VIDEO_REF_VIDEO_DURATION_LIMITS as cn, VIDEO_START_FRAME_ONLY_CODE as co, VIDEO_TO_VIDEO_NODE_PROVIDERS as cp, VIDEO_TO_VIDEO_PROVIDERS as cq, VIDEO_UPSCALE_PROVIDERS as cr, VIDEO_VARIABLE_PRICING as cs, VIDU_Q4_DEFAULT_RESOLUTION as ct, VIDU_Q4_PROVIDERS as cu, VOICE_DESIGN_MODELS as cv, type VideoAudioCapability as cw, type VideoAudioMode as cx, type VideoAudioRequest as cy, type VideoGenProvider as cz, CHARACTER_MOTION_PROVIDERS as d, videoProviderRefModeFrameSeats as d$, hasContiguousSegmentDurations as d0, imageReferenceLimit as d1, isGeminiOmniPerSecondProvider as d2, isGeminiOmniProvider as d3, isGrokVideo15Provider as d4, isGvpSupportedProvider as d5, isKling4FlashProvider as d6, isKling4Provider as d7, isKling4RunnerProvider as d8, isLegacySunoModel as d9, resolveGvpAnchorWire as dA, resolveMusicProvider as dB, resolveSeedanceTaskType as dC, resolveVideoModeForInputs as dD, resolveVideoProviderForMode as dE, seedance2AudioLimitSec as dF, seedanceTaskTypeFitsMedia as dG, segmentDurationsFor as dH, snapToNearestDuration as dI, sunoModelHonoursDuration as dJ, supportsAutoVideoDuration as dK, supportsEndAnchor as dL, supportsExtendRender as dM, supportsReferenceTaskType as dN, transcribeLaneSupportsTranslation as dO, transcribeLaneSupportsWordTimestamps as dP, transcribeProvidersWithTranslation as dQ, transcribeProvidersWithWordTimestamps as dR, videoAudioIntent as dS, videoAudioPricedOn as dT, videoDefaultDurationSec as dU, videoKeyframesMiddleCap as dV, videoModelCanSpeakDialogue as dW, videoModelSupportsAudio as dX, videoNegativeSuffix as dY, videoProviderAppendsFrames as dZ, videoProviderFoldsLoneEndFrame as d_, isMinimaxH3Provider as da, isPixverseV6MaxProvider as db, isSeedance2Provider as dc, isSeedanceExtendProvider as dd, isSeedanceVideoEditProvider as de, isTailExtendProvider as df, isVeoProvider as dg, isViduQ4Provider as dh, isWan3Provider as di, kling4KeyframeFrameCap as dj, listedSeedanceTaskType as dk, maxSegmentSecFor as dl, maxSegmentsFor as dm, maxVideoDurationSec as dn, minSegmentSecFor as dp, modelsForInputMode as dq, normalizeGrokVideo15Resolution as dr, normalizeKling4Resolution as ds, normalizeMinimaxH3Resolution as dt, normalizePixverseV6MaxQuality as du, normalizeViduQ4Resolution as dv, normalizeWan3Resolution as dw, preferredInputModeForModel as dx, pricedOutputDurationSec as dy, requestImageLimit as dz, COMPOSER_PLAN_FIELDS as e, videoProviderReferenceSyntax as e0, videoProviderRefsReplaceStartFrame as e1, videoProviderRequiresImage as e2, videoProviderRunsFromReferences as e3, videoProviderTakesLoneEndFrame as e4, videoSourceTrimMaxSec as e5, videoStartFrameOnlyMessage as e6, videoStartFrameOnlyProblem as e7, videoStartFrameOnlyResolution as e8, COMPOSER_PLAN_MAP as f, CREDIT_BASE_USD as g, type CaptionTranscribeLane as h, type CharacterMotionProvider as i, DEFAULT_MUSIC_PROVIDER as j, DEFAULT_REF_IMAGE_MAX as k, DEFAULT_REQUEST_IMAGE_LIMIT as l, DEFAULT_SUNO_MODEL as m, DEFAULT_TEXT_TO_AUDIO_PROVIDER as n, DEFAULT_TRANSCRIBE_NODE_PROVIDER as o, DEFAULT_TRANSCRIBE_PROVIDER as p, DEFAULT_TTS_OUTPUT_FORMAT as q, DEFAULT_TTS_PROVIDER as r, DEFAULT_VIDEO_DURATION_SEC as s, DEFAULT_VIDEO_PROVIDER as t, DEFAULT_VIDEO_TO_VIDEO_PROVIDER as u, DEFAULT_VOICE_DESIGN_MODEL as v, DIALOGUE_PROVIDERS as w, DURATION_PRICED_PROVIDERS as x, type DialogueProvider as y, type ExtendVideoProvider as z };
|
package/package.json
CHANGED
|
@@ -4,6 +4,7 @@ import {
|
|
|
4
4
|
resolveNormalizedImageGen,
|
|
5
5
|
buildVideoCreditModelIdentifier,
|
|
6
6
|
buildMotionCreditModelIdentifier,
|
|
7
|
+
motionTransferResolution,
|
|
7
8
|
} from "../credit-identifiers.js"
|
|
8
9
|
|
|
9
10
|
// ---------------------------------------------------------------------------
|
|
@@ -795,6 +796,34 @@ describe("buildMotionCreditModelIdentifier", () => {
|
|
|
795
796
|
})
|
|
796
797
|
})
|
|
797
798
|
|
|
799
|
+
// --- A size the model does not have (decided 2026-11-12) ---
|
|
800
|
+
describe("a size the model does not have", () => {
|
|
801
|
+
it("Wan Animate at 1080p runs, and is priced, as 720p, and says so", () => {
|
|
802
|
+
for (const provider of ["wan-animate-move", "wan-animate-replace"]) {
|
|
803
|
+
expect(buildMotionCreditModelIdentifier(provider, "1080p")).toBe(`${provider}:720p`)
|
|
804
|
+
const sized = motionTransferResolution(provider, "1080p")
|
|
805
|
+
expect(sized.resolution).toBe("720p")
|
|
806
|
+
expect(sized.adjustments.map(({ field, from, to }) => ({ field, from, to }))).toEqual([{ field: "resolution", from: "1080p", to: "720p" }])
|
|
807
|
+
}
|
|
808
|
+
})
|
|
809
|
+
|
|
810
|
+
it("Wan Animate's own sizes are kept, with nothing to say", () => {
|
|
811
|
+
for (const size of ["480p", "580p", "720p"]) {
|
|
812
|
+
expect(motionTransferResolution("wan-animate-replace", size)).toEqual({ resolution: size, adjustments: [] })
|
|
813
|
+
}
|
|
814
|
+
})
|
|
815
|
+
|
|
816
|
+
it("the Kling motion models are sent the size they name, as before (their price is the same either way)", () => {
|
|
817
|
+
for (const provider of ["kling", "kling-3.0"]) {
|
|
818
|
+
for (const size of ["480p", "580p", "720p", "1080p"]) {
|
|
819
|
+
expect(motionTransferResolution(provider, size), `${provider} ${size}`).toEqual({ resolution: size, adjustments: [] })
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
expect(buildMotionCreditModelIdentifier("kling", "480p")).toBe("motion-transfer:10s")
|
|
823
|
+
expect(buildMotionCreditModelIdentifier("kling-3.0", "1080p")).toBe("kling-3.0-motion:1080p:10s")
|
|
824
|
+
})
|
|
825
|
+
})
|
|
826
|
+
|
|
798
827
|
// --- Duration tier matching ---
|
|
799
828
|
describe("duration tier matching", () => {
|
|
800
829
|
it("3s falls into 5s tier", () => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { describe, expect, it } from "vitest"
|
|
2
|
-
import { EXTEND_VIDEO_PROVIDERS, isSeedanceExtendProvider } from "../model-constants.js"
|
|
2
|
+
import { EXTEND_VIDEO_PROVIDERS, isSeedanceExtendProvider, isTailExtendProvider } from "../model-constants.js"
|
|
3
3
|
import { MODEL_CATALOG } from "../model-catalog.js"
|
|
4
|
-
import { buildVideoCreditModelIdentifier, seedanceExtendCreditId, seedanceExtendResolution } from "../credit-identifiers.js"
|
|
4
|
+
import { buildVideoCreditModelIdentifier, seedanceExtendCreditId, seedanceExtendResolution, tailExtendCreditId, tailExtendResolution } from "../credit-identifiers.js"
|
|
5
5
|
|
|
6
6
|
const range = (from: number, to: number): number[] => Array.from({ length: to - from + 1 }, (_, i) => from + i)
|
|
7
7
|
const RESOLUTIONS = ["480p", "720p", "1080p"] as const
|
|
@@ -28,39 +28,39 @@ describe("Seedance Extend Video providers", () => {
|
|
|
28
28
|
})
|
|
29
29
|
|
|
30
30
|
it("prices each Seedance extend on its own rows", () => {
|
|
31
|
-
expect(
|
|
32
|
-
expect(
|
|
33
|
-
expect(
|
|
34
|
-
expect(
|
|
35
|
-
expect(
|
|
31
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 8, "720p")).toBe("seedance-2-5-extend:8s:720p")
|
|
32
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 8, "720p")).toBe("seedance-2-0-extend:8s:720p")
|
|
33
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 30, "1080p")).toBe("seedance-2-5-extend:30s:1080p")
|
|
34
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 25, "480p")).toBe("seedance-2-0-extend:15s:480p")
|
|
35
|
+
expect(tailExtendCreditId("seedance-2-5-extend")).toBe("seedance-2-5-extend:8s:720p")
|
|
36
36
|
})
|
|
37
37
|
|
|
38
38
|
it("prices both Seedance models per second added", () => {
|
|
39
|
-
expect(
|
|
40
|
-
expect(
|
|
41
|
-
expect(
|
|
42
|
-
expect(
|
|
43
|
-
expect(
|
|
39
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 6, "480p")).toBe("seedance-2-5-extend:6s:480p")
|
|
40
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 6, "480p")).toBe("seedance-2-0-extend:6s:480p")
|
|
41
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 10, "1080p")).toBe("seedance-2-0-extend:10s:1080p")
|
|
42
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 4, "720p")).toBe("seedance-2-0-extend:4s:720p")
|
|
43
|
+
expect(tailExtendCreditId("seedance-2-0-extend")).toBe("seedance-2-0-extend:8s:720p")
|
|
44
44
|
})
|
|
45
45
|
|
|
46
46
|
it("snaps a length or a resolution the provider does not offer", () => {
|
|
47
|
-
expect(
|
|
48
|
-
expect(
|
|
49
|
-
expect(
|
|
50
|
-
expect(
|
|
51
|
-
expect(
|
|
52
|
-
expect(
|
|
47
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 2, "720p")).toBe("seedance-2-5-extend:4s:720p")
|
|
48
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 45, "720p")).toBe("seedance-2-5-extend:30s:720p")
|
|
49
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 8, "4k")).toBe("seedance-2-5-extend:8s:720p")
|
|
50
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 8, "4k")).toBe("seedance-2-0-extend:8s:720p")
|
|
51
|
+
expect(tailExtendCreditId("seedance-2-0-extend", 2, "480p")).toBe("seedance-2-0-extend:4s:480p")
|
|
52
|
+
expect(tailExtendCreditId("seedance-2-5-extend", 0, "480p")).toBe("seedance-2-5-extend:8s:480p")
|
|
53
53
|
})
|
|
54
54
|
|
|
55
55
|
it("renders at the resolution it is priced at: one the model offers, else 720p", () => {
|
|
56
56
|
for (const provider of ["seedance-2-5-extend", "seedance-2-0-extend"] as const) {
|
|
57
|
-
for (const res of RESOLUTIONS) expect(
|
|
57
|
+
for (const res of RESOLUTIONS) expect(tailExtendResolution(provider, res), `${provider} ${res}`).toBe(res)
|
|
58
58
|
for (const res of [undefined, "4k", "360p", "", 1080, null]) {
|
|
59
|
-
expect(
|
|
59
|
+
expect(tailExtendResolution(provider, res), `${provider} ${String(res)}`).toBe("720p")
|
|
60
60
|
}
|
|
61
61
|
// The id names exactly the resolution the run renders at.
|
|
62
62
|
for (const res of [...RESOLUTIONS, undefined, "4k"]) {
|
|
63
|
-
expect(
|
|
63
|
+
expect(tailExtendCreditId(provider, 8, res)).toBe(`${provider}:8s:${tailExtendResolution(provider, res)}`)
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
})
|
|
@@ -72,8 +72,8 @@ describe("Seedance Extend Video providers", () => {
|
|
|
72
72
|
const rows25 = new Set(range(4, 30).flatMap((n) => RESOLUTIONS.map((r) => `seedance-2-5-extend:${n}s:${r}`)))
|
|
73
73
|
for (const res of [...RESOLUTIONS, undefined, "4k"]) {
|
|
74
74
|
for (const duration of [undefined, ...range(-1, 35)]) {
|
|
75
|
-
expect(rows20.has(
|
|
76
|
-
expect(rows25.has(
|
|
75
|
+
expect(rows20.has(tailExtendCreditId("seedance-2-0-extend", duration, res)), `2.0 ${duration}s ${res}`).toBe(true)
|
|
76
|
+
expect(rows25.has(tailExtendCreditId("seedance-2-5-extend", duration, res)), `2.5 ${duration}s ${res}`).toBe(true)
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
79
|
})
|
|
@@ -83,7 +83,7 @@ describe("Seedance Extend Video providers", () => {
|
|
|
83
83
|
for (const duration of [undefined, 1, 6, 12, 25, 45, "12"]) {
|
|
84
84
|
for (const res of [undefined, "480p", "720p", "1080p", "4k"]) {
|
|
85
85
|
expect(buildVideoCreditModelIdentifier(provider, duration, undefined, undefined, undefined, res), `${provider} ${duration} ${res}`)
|
|
86
|
-
.toBe(
|
|
86
|
+
.toBe(tailExtendCreditId(provider, duration, res))
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
}
|
|
@@ -104,11 +104,91 @@ describe("Seedance Extend Video providers", () => {
|
|
|
104
104
|
expect(entry.resolutions).toEqual([...RESOLUTIONS])
|
|
105
105
|
// Each catalog entry lists the rows its default length is priced on.
|
|
106
106
|
const ids = entry.pricing.map((p) => p.identifier)
|
|
107
|
-
for (const res of RESOLUTIONS) expect(ids, `${id} ${res}`).toContain(
|
|
107
|
+
for (const res of RESOLUTIONS) expect(ids, `${id} ${res}`).toContain(tailExtendCreditId(id, 8, res))
|
|
108
108
|
// The first row is the default run's price; the retired provider id is
|
|
109
109
|
// never listed (sent as a provider, it runs and bills as Seedance 2.5).
|
|
110
|
-
expect(entry.pricing[0]!.identifier, id).toBe(
|
|
110
|
+
expect(entry.pricing[0]!.identifier, id).toBe(tailExtendCreditId(id))
|
|
111
111
|
expect(ids, id).not.toContain("seedance-2-extend")
|
|
112
112
|
}
|
|
113
113
|
})
|
|
114
114
|
})
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* Kling 4 extends any video with the same tail recipe as Seedance (the
|
|
118
|
+
* source's last frame opens the new footage, its last seconds ride as
|
|
119
|
+
* `@video_1`, then the two are stitched): `kling-4-extend`, 3–30 s added at
|
|
120
|
+
* 720p or 1080p, priced on its own rows.
|
|
121
|
+
*/
|
|
122
|
+
describe("Kling 4 Extend Video provider", () => {
|
|
123
|
+
const KLING_RESOLUTIONS = ["720p", "1080p"] as const
|
|
124
|
+
|
|
125
|
+
it("lists Kling 4 right after the two Seedance extend providers", () => {
|
|
126
|
+
const at = EXTEND_VIDEO_PROVIDERS.indexOf("kling-4-extend")
|
|
127
|
+
expect(at).toBeGreaterThan(-1)
|
|
128
|
+
expect(EXTEND_VIDEO_PROVIDERS[at - 1]).toBe("seedance-2-0-extend")
|
|
129
|
+
})
|
|
130
|
+
|
|
131
|
+
it("is a tail-recipe extend provider, but no Seedance one (its levers are its own)", () => {
|
|
132
|
+
expect(isTailExtendProvider("kling-4-extend")).toBe(true)
|
|
133
|
+
expect(isSeedanceExtendProvider("kling-4-extend")).toBe(false)
|
|
134
|
+
expect(isTailExtendProvider("kling-4")).toBe(false)
|
|
135
|
+
})
|
|
136
|
+
|
|
137
|
+
it("offers 3–30 s and 720p/1080p on Kling 4, in a catalog entry of its own", () => {
|
|
138
|
+
const entry = MODEL_CATALOG["kling-4-extend"]!
|
|
139
|
+
expect(entry.modes).toEqual(["extend"])
|
|
140
|
+
expect(entry.maker).toBe("kuaishou")
|
|
141
|
+
expect(entry.durations).toEqual(range(3, 30))
|
|
142
|
+
expect(entry.resolutions).toEqual([...KLING_RESOLUTIONS])
|
|
143
|
+
// Its default run is Kling 4's own default length.
|
|
144
|
+
expect(entry.defaultDuration).toBe(MODEL_CATALOG["kling-4"]!.defaultDuration)
|
|
145
|
+
expect(entry.pricing[0]!.identifier).toBe(tailExtendCreditId("kling-4-extend"))
|
|
146
|
+
expect(entry.pricing[0]!.identifier).toBe("kling-4-extend:5s:720p")
|
|
147
|
+
})
|
|
148
|
+
|
|
149
|
+
it("prices every length and resolution on its own rows, snapping what it does not offer", () => {
|
|
150
|
+
expect(tailExtendCreditId("kling-4-extend", 5, "720p")).toBe("kling-4-extend:5s:720p")
|
|
151
|
+
expect(tailExtendCreditId("kling-4-extend", 30, "1080p")).toBe("kling-4-extend:30s:1080p")
|
|
152
|
+
expect(tailExtendCreditId("kling-4-extend", 3, "1080p")).toBe("kling-4-extend:3s:1080p")
|
|
153
|
+
expect(tailExtendCreditId("kling-4-extend", 2, "720p")).toBe("kling-4-extend:3s:720p")
|
|
154
|
+
expect(tailExtendCreditId("kling-4-extend", 45, "720p")).toBe("kling-4-extend:30s:720p")
|
|
155
|
+
// Kling 4 renders no 480p: a run naming it is priced, and renders, at 720p.
|
|
156
|
+
expect(tailExtendCreditId("kling-4-extend", 8, "480p")).toBe("kling-4-extend:8s:720p")
|
|
157
|
+
expect(tailExtendResolution("kling-4-extend", "480p")).toBe("720p")
|
|
158
|
+
expect(tailExtendResolution("kling-4-extend", "1080p")).toBe("1080p")
|
|
159
|
+
const rows = new Set(range(3, 30).flatMap((n) => KLING_RESOLUTIONS.map((r) => `kling-4-extend:${n}s:${r}`)))
|
|
160
|
+
for (const res of [...KLING_RESOLUTIONS, undefined, "480p", "4k"]) {
|
|
161
|
+
for (const duration of [undefined, ...range(-1, 35)]) {
|
|
162
|
+
expect(rows.has(tailExtendCreditId("kling-4-extend", duration, res)), `${duration}s ${res}`).toBe(true)
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
})
|
|
166
|
+
|
|
167
|
+
it("the generic video builder prices a Kling 4 extend on its own rows", () => {
|
|
168
|
+
for (const duration of [undefined, 1, 5, 12, 30, 45, "12"]) {
|
|
169
|
+
for (const res of [undefined, "480p", "720p", "1080p"]) {
|
|
170
|
+
expect(buildVideoCreditModelIdentifier("kling-4-extend", duration, undefined, undefined, undefined, res), `${duration} ${res}`)
|
|
171
|
+
.toBe(tailExtendCreditId("kling-4-extend", duration, res))
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
})
|
|
175
|
+
})
|
|
176
|
+
|
|
177
|
+
describe("the tail-recipe extend providers", () => {
|
|
178
|
+
it("are Seedance 2.5, Seedance 2.0 and Kling 4", () => {
|
|
179
|
+
expect(EXTEND_VIDEO_PROVIDERS.filter(isTailExtendProvider)).toEqual(["seedance-2-5-extend", "seedance-2-0-extend", "kling-4-extend"])
|
|
180
|
+
expect(isTailExtendProvider("seedance-2-extend")).toBe(false)
|
|
181
|
+
expect(isTailExtendProvider("veo-extend")).toBe(false)
|
|
182
|
+
expect(isTailExtendProvider(undefined)).toBe(false)
|
|
183
|
+
expect(isTailExtendProvider("toString")).toBe(false)
|
|
184
|
+
})
|
|
185
|
+
|
|
186
|
+
it("the earlier Seedance-only names still answer, as the tail builders do (published API)", () => {
|
|
187
|
+
for (const provider of ["seedance-2-5-extend", "seedance-2-0-extend"] as const) {
|
|
188
|
+
for (const res of [undefined, "480p", "1080p", "4k"]) {
|
|
189
|
+
expect(seedanceExtendCreditId(provider, 12, res)).toBe(tailExtendCreditId(provider, 12, res))
|
|
190
|
+
expect(seedanceExtendResolution(provider, res)).toBe(tailExtendResolution(provider, res))
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
})
|
|
194
|
+
})
|