@nodaro/shared 3.62.0 → 3.64.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.
Files changed (264) hide show
  1. package/dist/{chunk-C7POAYFE.js → chunk-36VWLB4J.js} +3 -3
  2. package/dist/{chunk-C7POAYFE.js.map → chunk-36VWLB4J.js.map} +1 -1
  3. package/dist/{chunk-S24ZBUB4.js → chunk-3AYM47GW.js} +6 -32
  4. package/dist/chunk-3AYM47GW.js.map +1 -0
  5. package/dist/{chunk-YCXRSWCQ.js → chunk-3KTWYYCN.js} +8 -5
  6. package/dist/chunk-3KTWYYCN.js.map +1 -0
  7. package/dist/{chunk-ZES6EZC4.js → chunk-4IUE2JB7.js} +3 -3
  8. package/dist/{chunk-ZES6EZC4.js.map → chunk-4IUE2JB7.js.map} +1 -1
  9. package/dist/{chunk-MYJQELFN.cjs → chunk-5OBTGNUQ.cjs} +547 -29
  10. package/dist/chunk-5OBTGNUQ.cjs.map +1 -0
  11. package/dist/{chunk-TWF2OSH4.cjs → chunk-67CMMTLN.cjs} +4 -4
  12. package/dist/{chunk-TWF2OSH4.cjs.map → chunk-67CMMTLN.cjs.map} +1 -1
  13. package/dist/{chunk-WRSWH7US.cjs → chunk-6BRWPJPP.cjs} +17 -2
  14. package/dist/chunk-6BRWPJPP.cjs.map +1 -0
  15. package/dist/{chunk-S5TMRJMX.js → chunk-6YIV37V7.js} +4 -4
  16. package/dist/{chunk-S5TMRJMX.js.map → chunk-6YIV37V7.js.map} +1 -1
  17. package/dist/{chunk-3M4BNKFJ.cjs → chunk-7AJGUI7L.cjs} +202 -16
  18. package/dist/chunk-7AJGUI7L.cjs.map +1 -0
  19. package/dist/{chunk-JZGZ26YB.js → chunk-7KQ6W5DS.js} +4 -4
  20. package/dist/{chunk-JZGZ26YB.js.map → chunk-7KQ6W5DS.js.map} +1 -1
  21. package/dist/{chunk-IWWVPR3W.cjs → chunk-ACZZHHFZ.cjs} +149 -34
  22. package/dist/chunk-ACZZHHFZ.cjs.map +1 -0
  23. package/dist/{chunk-2W745U4A.cjs → chunk-AZNZ5WNZ.cjs} +42 -70
  24. package/dist/chunk-AZNZ5WNZ.cjs.map +1 -0
  25. package/dist/{chunk-HSHCCBIV.js → chunk-BQYCZLMF.js} +16 -3
  26. package/dist/chunk-BQYCZLMF.js.map +1 -0
  27. package/dist/chunk-CHS2SIP6.cjs +504 -0
  28. package/dist/chunk-CHS2SIP6.cjs.map +1 -0
  29. package/dist/{chunk-CIPPPT7E.cjs → chunk-CHTZZRAL.cjs} +6 -6
  30. package/dist/{chunk-CIPPPT7E.cjs.map → chunk-CHTZZRAL.cjs.map} +1 -1
  31. package/dist/{chunk-AOJ6B7K4.cjs → chunk-D4KWNDPH.cjs} +12 -12
  32. package/dist/chunk-D4KWNDPH.cjs.map +1 -0
  33. package/dist/{chunk-5YYN5X57.js → chunk-DZ4IOP3Q.js} +536 -30
  34. package/dist/chunk-DZ4IOP3Q.js.map +1 -0
  35. package/dist/{chunk-VACPZPUA.cjs → chunk-EXEVT6D2.cjs} +15 -5
  36. package/dist/chunk-EXEVT6D2.cjs.map +1 -0
  37. package/dist/{chunk-5M43XMRB.cjs → chunk-FHGRKQVZ.cjs} +8 -8
  38. package/dist/{chunk-5M43XMRB.cjs.map → chunk-FHGRKQVZ.cjs.map} +1 -1
  39. package/dist/{chunk-KJSRPHJ2.cjs → chunk-GTWUS6MQ.cjs} +165 -54
  40. package/dist/chunk-GTWUS6MQ.cjs.map +1 -0
  41. package/dist/{chunk-Q6IES3U2.js → chunk-H5KHWTAE.js} +5 -2
  42. package/dist/chunk-H5KHWTAE.js.map +1 -0
  43. package/dist/{chunk-G3KVK7OU.cjs → chunk-HDPJNNMF.cjs} +21 -21
  44. package/dist/{chunk-G3KVK7OU.cjs.map → chunk-HDPJNNMF.cjs.map} +1 -1
  45. package/dist/{chunk-3OYO3XCC.js → chunk-IYSOVS7O.js} +118 -24
  46. package/dist/chunk-IYSOVS7O.js.map +1 -0
  47. package/dist/{chunk-AFYTX4AI.cjs → chunk-J6B7J73J.cjs} +110 -50
  48. package/dist/chunk-J6B7J73J.cjs.map +1 -0
  49. package/dist/{chunk-I2RQB7VG.js → chunk-KB2SQAR3.js} +3 -3
  50. package/dist/{chunk-I2RQB7VG.js.map → chunk-KB2SQAR3.js.map} +1 -1
  51. package/dist/{chunk-BLJUCPMV.cjs → chunk-KSHAAPQF.cjs} +5 -2
  52. package/dist/chunk-KSHAAPQF.cjs.map +1 -0
  53. package/dist/{chunk-6G7NN4S4.js → chunk-NIAFR5EE.js} +2 -2
  54. package/dist/chunk-NIAFR5EE.js.map +1 -0
  55. package/dist/{chunk-CF4S4N5X.js → chunk-O2QOBA6Q.js} +2 -2
  56. package/dist/{chunk-CF4S4N5X.js.map → chunk-O2QOBA6Q.js.map} +1 -1
  57. package/dist/{chunk-IDTKF5EX.cjs → chunk-O4RPXBDZ.cjs} +12 -8
  58. package/dist/chunk-O4RPXBDZ.cjs.map +1 -0
  59. package/dist/{chunk-4GGLKRYI.cjs → chunk-O6TBB4IF.cjs} +2 -2
  60. package/dist/{chunk-4GGLKRYI.cjs.map → chunk-O6TBB4IF.cjs.map} +1 -1
  61. package/dist/{chunk-PTD6EDUU.js → chunk-OBOOHG3N.js} +13 -4
  62. package/dist/chunk-OBOOHG3N.js.map +1 -0
  63. package/dist/{chunk-2D5LQFV4.cjs → chunk-OOZW2MM6.cjs} +9 -9
  64. package/dist/{chunk-2D5LQFV4.cjs.map → chunk-OOZW2MM6.cjs.map} +1 -1
  65. package/dist/{chunk-A2PX5IRC.cjs → chunk-PERUFUVH.cjs} +13 -13
  66. package/dist/{chunk-A2PX5IRC.cjs.map → chunk-PERUFUVH.cjs.map} +1 -1
  67. package/dist/{chunk-G4U3HW6W.js → chunk-PJJAZQVZ.js} +3 -3
  68. package/dist/{chunk-G4U3HW6W.js.map → chunk-PJJAZQVZ.js.map} +1 -1
  69. package/dist/{chunk-E2HZTGYX.js → chunk-Q2Y4JHF7.js} +7 -7
  70. package/dist/chunk-Q2Y4JHF7.js.map +1 -0
  71. package/dist/{chunk-FVII3KHN.js → chunk-QYU7J5EQ.js} +198 -17
  72. package/dist/chunk-QYU7J5EQ.js.map +1 -0
  73. package/dist/{chunk-JJNNM23P.js → chunk-S3UGLZSF.js} +3 -3
  74. package/dist/{chunk-JJNNM23P.js.map → chunk-S3UGLZSF.js.map} +1 -1
  75. package/dist/{chunk-CC4V2B7S.js → chunk-SHH2T4CR.js} +3 -3
  76. package/dist/{chunk-CC4V2B7S.js.map → chunk-SHH2T4CR.js.map} +1 -1
  77. package/dist/{chunk-4ZEFP2FQ.cjs → chunk-SPAHI7DY.cjs} +4 -4
  78. package/dist/{chunk-4ZEFP2FQ.cjs.map → chunk-SPAHI7DY.cjs.map} +1 -1
  79. package/dist/{chunk-Y6X7UJSD.js → chunk-SXHHLZ22.js} +122 -15
  80. package/dist/chunk-SXHHLZ22.js.map +1 -0
  81. package/dist/{chunk-HRY7KGAE.cjs → chunk-T2OVDF2M.cjs} +6 -6
  82. package/dist/{chunk-HRY7KGAE.cjs.map → chunk-T2OVDF2M.cjs.map} +1 -1
  83. package/dist/{chunk-2QKF7M2Z.js → chunk-TAPBDT47.js} +3 -3
  84. package/dist/{chunk-2QKF7M2Z.js.map → chunk-TAPBDT47.js.map} +1 -1
  85. package/dist/{chunk-NGKKNSK6.js → chunk-TPQJKS7D.js} +139 -16
  86. package/dist/chunk-TPQJKS7D.js.map +1 -0
  87. package/dist/{chunk-N7OUQK7E.cjs → chunk-TQW3R44P.cjs} +8 -8
  88. package/dist/{chunk-N7OUQK7E.cjs.map → chunk-TQW3R44P.cjs.map} +1 -1
  89. package/dist/{chunk-GSFB537T.js → chunk-TTGZ2L3O.js} +23 -4
  90. package/dist/chunk-TTGZ2L3O.js.map +1 -0
  91. package/dist/{chunk-SYWR5G3T.js → chunk-VPTA4Z7G.js} +54 -7
  92. package/dist/chunk-VPTA4Z7G.js.map +1 -0
  93. package/dist/{chunk-2HZGDZZN.cjs → chunk-VZ6TE23U.cjs} +6 -6
  94. package/dist/{chunk-2HZGDZZN.cjs.map → chunk-VZ6TE23U.cjs.map} +1 -1
  95. package/dist/{chunk-TRVWMKNE.cjs → chunk-W6VJAUGM.cjs} +285 -64
  96. package/dist/chunk-W6VJAUGM.cjs.map +1 -0
  97. package/dist/{chunk-UDDVDQMF.js → chunk-W7KHHNZR.js} +235 -37
  98. package/dist/chunk-W7KHHNZR.js.map +1 -0
  99. package/dist/{chunk-KYMHFVAZ.cjs → chunk-Y4GCJJPF.cjs} +2 -2
  100. package/dist/chunk-Y4GCJJPF.cjs.map +1 -0
  101. package/dist/{chunk-6CSXMWL4.cjs → chunk-YQV53HRR.cjs} +27 -4
  102. package/dist/chunk-YQV53HRR.cjs.map +1 -0
  103. package/dist/{chunk-7FCTCWHD.js → chunk-ZI3QDUHO.js} +3 -3
  104. package/dist/{chunk-7FCTCWHD.js.map → chunk-ZI3QDUHO.js.map} +1 -1
  105. package/dist/entries/apps.cjs +43 -42
  106. package/dist/entries/apps.js +8 -7
  107. package/dist/entries/captions.cjs +38 -30
  108. package/dist/entries/captions.d.cts +47 -1
  109. package/dist/entries/captions.d.ts +47 -1
  110. package/dist/entries/captions.js +1 -1
  111. package/dist/entries/credits.cjs +354 -174
  112. package/dist/entries/credits.d.cts +378 -27
  113. package/dist/entries/credits.d.ts +378 -27
  114. package/dist/entries/credits.js +11 -11
  115. package/dist/entries/llm-models.cjs +77 -57
  116. package/dist/entries/llm-models.d.cts +108 -7
  117. package/dist/entries/llm-models.d.ts +108 -7
  118. package/dist/entries/llm-models.js +2 -2
  119. package/dist/entries/media.cjs +63 -63
  120. package/dist/entries/media.d.cts +8 -0
  121. package/dist/entries/media.d.ts +8 -0
  122. package/dist/entries/media.js +1 -1
  123. package/dist/entries/model-catalog.cjs +161 -105
  124. package/dist/entries/model-catalog.d.cts +109 -22
  125. package/dist/entries/model-catalog.d.ts +109 -22
  126. package/dist/entries/model-catalog.js +4 -4
  127. package/dist/entries/models.cjs +466 -322
  128. package/dist/entries/models.d.cts +71 -5
  129. package/dist/entries/models.d.ts +71 -5
  130. package/dist/entries/models.js +5 -5
  131. package/dist/entries/nodes.cjs +226 -209
  132. package/dist/entries/nodes.d.cts +66 -7
  133. package/dist/entries/nodes.d.ts +66 -7
  134. package/dist/entries/nodes.js +10 -9
  135. package/dist/entries/pipeline.cjs +156 -152
  136. package/dist/entries/pipeline.d.cts +14 -4
  137. package/dist/entries/pipeline.d.ts +14 -4
  138. package/dist/entries/pipeline.js +3 -3
  139. package/dist/entries/runtime-config.cjs +29 -29
  140. package/dist/entries/runtime-config.d.cts +10 -7
  141. package/dist/entries/runtime-config.d.ts +10 -7
  142. package/dist/entries/runtime-config.js +1 -1
  143. package/dist/entries/social.cjs +177 -177
  144. package/dist/entries/social.js +2 -2
  145. package/dist/entries/types.d.cts +8 -0
  146. package/dist/entries/types.d.ts +8 -0
  147. package/dist/entries/ugc.cjs +71 -71
  148. package/dist/entries/ugc.js +4 -4
  149. package/dist/entries/video.cjs +154 -150
  150. package/dist/entries/video.d.cts +11 -2
  151. package/dist/entries/video.d.ts +11 -2
  152. package/dist/entries/video.js +6 -6
  153. package/dist/entries/workflow.cjs +150 -150
  154. package/dist/entries/workflow.d.cts +1 -1
  155. package/dist/entries/workflow.d.ts +1 -1
  156. package/dist/entries/workflow.js +2 -2
  157. package/dist/index.cjs +2136 -1704
  158. package/dist/index.d.cts +10 -10
  159. package/dist/index.d.ts +10 -10
  160. package/dist/index.js +27 -27
  161. package/dist/{model-catalog-CCEcv08q.d.ts → model-catalog-Cf9fkEUp.d.cts} +45 -2
  162. package/dist/{model-catalog-CCEcv08q.d.cts → model-catalog-Cf9fkEUp.d.ts} +45 -2
  163. package/dist/{model-constants-B88p6XR0.d.ts → model-constants-BxjiWVQ9.d.ts} +215 -32
  164. package/dist/{model-constants-Cf3zaITt.d.cts → model-constants-C_Nyft_i.d.cts} +215 -32
  165. package/package.json +1 -1
  166. package/src/__tests__/add-captions-nemotron-pricing.test.ts +111 -0
  167. package/src/__tests__/credit-identifiers.test.ts +29 -0
  168. package/src/__tests__/extend-providers.test.ts +359 -39
  169. package/src/__tests__/fixtures/mask-composite-quote-parity.json +1 -1
  170. package/src/__tests__/fixtures/measured-input-quote-parity.json +1435 -0
  171. package/src/__tests__/fixtures/planned-length-quote-parity.json +1866 -0
  172. package/src/__tests__/fixtures/video-utility-quote-parity.json +2343 -0
  173. package/src/__tests__/flux-3-klein.test.ts +203 -0
  174. package/src/__tests__/gpt-image-2-6-formats.test.ts +3 -1
  175. package/src/__tests__/gvp-supported-providers.test.ts +27 -2
  176. package/src/__tests__/lip-sync-audio-rate.test.ts +74 -0
  177. package/src/__tests__/lip-sync-levers.test.ts +31 -0
  178. package/src/__tests__/llm-models.test.ts +139 -12
  179. package/src/__tests__/llm-price-key.test.ts +164 -1
  180. package/src/__tests__/model-makers.test.ts +3 -0
  181. package/src/__tests__/nemotron-transcribe-pricing.test.ts +61 -0
  182. package/src/__tests__/node-runtime-keys.test.ts +7 -0
  183. package/src/__tests__/normalize-node-params.test.ts +172 -1
  184. package/src/__tests__/pixverse-v6-max-catalog.test.ts +271 -0
  185. package/src/__tests__/prompt-length-limits.test.ts +4 -0
  186. package/src/__tests__/retired-lip-sync-providers.test.ts +43 -0
  187. package/src/__tests__/seedance-extend-source-credit-id.test.ts +89 -0
  188. package/src/__tests__/seedance-task-type.test.ts +13 -3
  189. package/src/__tests__/sequence-execution.test.ts +22 -1
  190. package/src/__tests__/suno-credit-type.test.ts +21 -2
  191. package/src/__tests__/transcribe-capabilities.test.ts +41 -2
  192. package/src/__tests__/transcribe-preflight.test.ts +50 -1
  193. package/src/__tests__/video-analysis-catalog-sync.test.ts +4 -2
  194. package/src/__tests__/video-analysis-pricing.test.ts +10 -9
  195. package/src/__tests__/video-audio-capability.test.ts +35 -6
  196. package/src/__tests__/video-resolution-billed-as-named.test.ts +30 -0
  197. package/src/__tests__/video-upscale-params.test.ts +62 -0
  198. package/src/caption-styles.ts +62 -0
  199. package/src/catalog-projection.ts +8 -0
  200. package/src/credit-estimators/add-captions-nemotron.ts +73 -0
  201. package/src/credit-estimators/index.ts +20 -0
  202. package/src/credit-estimators/nemotron-transcribe.ts +87 -0
  203. package/src/credit-identifiers.ts +351 -41
  204. package/src/entries/captions.ts +2 -0
  205. package/src/entries/credits.ts +37 -2
  206. package/src/entries/llm-models.ts +6 -0
  207. package/src/entries/model-catalog.ts +22 -0
  208. package/src/entries/models.ts +50 -0
  209. package/src/entries/nodes.ts +4 -0
  210. package/src/entries/pipeline.ts +1 -1
  211. package/src/entries/video.ts +1 -1
  212. package/src/flux-3-klein.ts +69 -0
  213. package/src/freecut-protocol.ts +8 -0
  214. package/src/input-image-pricing.ts +23 -6
  215. package/src/lip-sync-levers.ts +56 -0
  216. package/src/lip-sync-pricing.ts +91 -1
  217. package/src/llm-models.ts +305 -16
  218. package/src/model-catalog.ts +529 -28
  219. package/src/model-constants.ts +417 -41
  220. package/src/model-tree.ts +2 -1
  221. package/src/nodaro-video-upscale.ts +48 -0
  222. package/src/node-default-mappings.ts +6 -0
  223. package/src/node-runtime-keys.ts +3 -0
  224. package/src/normalize-node-params.ts +172 -3
  225. package/src/runtime-config/contract.ts +10 -7
  226. package/src/seedance-draft.ts +2 -1
  227. package/src/seedance-extend-rate.ts +116 -0
  228. package/src/sequence-execution.ts +24 -0
  229. package/src/transcribe-preflight.ts +81 -7
  230. package/src/video-analysis-pricing.ts +28 -15
  231. package/src/video-duration.ts +9 -0
  232. package/src/video-ui-defaults.ts +5 -3
  233. package/src/video-upscale-params.ts +67 -0
  234. package/dist/chunk-2W745U4A.cjs.map +0 -1
  235. package/dist/chunk-3M4BNKFJ.cjs.map +0 -1
  236. package/dist/chunk-3OYO3XCC.js.map +0 -1
  237. package/dist/chunk-5YYN5X57.js.map +0 -1
  238. package/dist/chunk-6CSXMWL4.cjs.map +0 -1
  239. package/dist/chunk-6G7NN4S4.js.map +0 -1
  240. package/dist/chunk-AFYTX4AI.cjs.map +0 -1
  241. package/dist/chunk-AOJ6B7K4.cjs.map +0 -1
  242. package/dist/chunk-BLJUCPMV.cjs.map +0 -1
  243. package/dist/chunk-E2HZTGYX.js.map +0 -1
  244. package/dist/chunk-FVII3KHN.js.map +0 -1
  245. package/dist/chunk-GSFB537T.js.map +0 -1
  246. package/dist/chunk-HSHCCBIV.js.map +0 -1
  247. package/dist/chunk-IDTKF5EX.cjs.map +0 -1
  248. package/dist/chunk-IWWVPR3W.cjs.map +0 -1
  249. package/dist/chunk-KJSRPHJ2.cjs.map +0 -1
  250. package/dist/chunk-KYMHFVAZ.cjs.map +0 -1
  251. package/dist/chunk-MYJQELFN.cjs.map +0 -1
  252. package/dist/chunk-NGKKNSK6.js.map +0 -1
  253. package/dist/chunk-PTD6EDUU.js.map +0 -1
  254. package/dist/chunk-Q6IES3U2.js.map +0 -1
  255. package/dist/chunk-QWYFHQYK.cjs +0 -357
  256. package/dist/chunk-QWYFHQYK.cjs.map +0 -1
  257. package/dist/chunk-S24ZBUB4.js.map +0 -1
  258. package/dist/chunk-SYWR5G3T.js.map +0 -1
  259. package/dist/chunk-TRVWMKNE.cjs.map +0 -1
  260. package/dist/chunk-UDDVDQMF.js.map +0 -1
  261. package/dist/chunk-VACPZPUA.cjs.map +0 -1
  262. package/dist/chunk-WRSWH7US.cjs.map +0 -1
  263. package/dist/chunk-Y6X7UJSD.js.map +0 -1
  264. package/dist/chunk-YCXRSWCQ.js.map +0 -1
@@ -0,0 +1,2343 @@
1
+ {
2
+ "$comment": "Trim Video, Loop Video and Combine Videos are charged by the measured length of each clip they are given (their run probes every input before it reserves). Their quote before a run reads the one measured walk Mask Composite and Video Overlay read (measuredWireLengthSec, @nodaro/render-rules), with VIDEO_UTILITY_PLANNED_CLIP_SLACK_SEC (0.1 s) on each clip a node makes in the run, and every clip less VIDEO_UTILITY_PRICE_GRACE_SEC (0.1 s) before the node's formula (videoUtilityUnitsOf — the rule the charge counts by, so a frame past a 5-second mark is free on both): a generation at the length its model renders for its settings (Auto at its longest, a mapped length as the run resolves it), an Extend Video at its source plus what it adds, a node outside the run (or frozen) at the take it hands on, an upload or a Library clip at its measured length, and a clip nothing can size at the estimators' 8-second fallback (a minimum: the run is charged the length it measures). Each case names its step `t`; `whole` is a whole run (the editor's whole-run set, the server's estimate with no run set), `alone` is the step's own Run and its pill (the server's run of `t` alone), `partial` a run of exactly `runSet`. Units are the step's pricing units (each one unit of its own row). Held by frontend/src/lib/__tests__/video-utility-quote-parity.test.ts and backend/src/ee/billing/__tests__/video-utility-quote-parity.test.ts. The step settings: Trim keeps the whole clip (seconds mode, 0 + 0), Loop repeats twice, Combine joins by cuts with its default 1 + 2 frame trims. A case's `stepData` replaces its step's settings; a Trim is priced over the fields its run sends (trimVideoRunFields: its mode's own, an end of 0 left open, so the cut runs to the clip's end).",
3
+ "steps": {
4
+ "trim": {
5
+ "type": "trim-video",
6
+ "data": {
7
+ "trimMode": "seconds",
8
+ "trimStartSeconds": 0,
9
+ "trimEndSeconds": 0
10
+ }
11
+ },
12
+ "loop": {
13
+ "type": "loop-video",
14
+ "data": {
15
+ "mode": "repeat",
16
+ "repeatCount": 2
17
+ }
18
+ },
19
+ "combine": {
20
+ "type": "combine-videos",
21
+ "data": {
22
+ "transition": "cut",
23
+ "transitionDuration": 0.5,
24
+ "trimStartFrames": 1,
25
+ "trimEndFrames": 2
26
+ }
27
+ }
28
+ },
29
+ "cases": [
30
+ {
31
+ "name": "1. Trim — a 5 s generation (kling-4): 5.1 s planned, less the 0.1 s grace: 5 s",
32
+ "step": "trim",
33
+ "nodes": [
34
+ {
35
+ "id": "g",
36
+ "type": "generate-video",
37
+ "data": {
38
+ "provider": "kling-4",
39
+ "duration": 5
40
+ }
41
+ }
42
+ ],
43
+ "edges": [
44
+ {
45
+ "source": "g",
46
+ "target": "t",
47
+ "targetHandle": "in"
48
+ }
49
+ ],
50
+ "expectedUnits": {
51
+ "whole": 1,
52
+ "alone": 1
53
+ }
54
+ },
55
+ {
56
+ "name": "1b. Loop ×2 — a 5 s generation: 10.2 s",
57
+ "step": "loop",
58
+ "nodes": [
59
+ {
60
+ "id": "g",
61
+ "type": "generate-video",
62
+ "data": {
63
+ "provider": "kling-4",
64
+ "duration": 5
65
+ }
66
+ }
67
+ ],
68
+ "edges": [
69
+ {
70
+ "source": "g",
71
+ "target": "t",
72
+ "targetHandle": "in"
73
+ }
74
+ ],
75
+ "expectedUnits": {
76
+ "whole": 2,
77
+ "alone": 2
78
+ }
79
+ },
80
+ {
81
+ "name": "1c. Combine — two 5 s generations: 5.1 + 5.1 s, less 3 frames each",
82
+ "step": "combine",
83
+ "nodes": [
84
+ {
85
+ "id": "g",
86
+ "type": "generate-video",
87
+ "data": {
88
+ "provider": "kling-4",
89
+ "duration": 5
90
+ }
91
+ },
92
+ {
93
+ "id": "h",
94
+ "type": "generate-video",
95
+ "data": {
96
+ "provider": "kling-4",
97
+ "duration": 5
98
+ }
99
+ }
100
+ ],
101
+ "edges": [
102
+ {
103
+ "source": "g",
104
+ "target": "t",
105
+ "targetHandle": "in"
106
+ },
107
+ {
108
+ "source": "h",
109
+ "target": "t",
110
+ "targetHandle": "in"
111
+ }
112
+ ],
113
+ "expectedUnits": {
114
+ "whole": 2,
115
+ "alone": 2
116
+ }
117
+ },
118
+ {
119
+ "name": "2. Trim — a 15 s generation (the old 8-second under-quote): 15.1 s",
120
+ "step": "trim",
121
+ "nodes": [
122
+ {
123
+ "id": "g",
124
+ "type": "generate-video",
125
+ "data": {
126
+ "provider": "kling-4",
127
+ "duration": 15
128
+ }
129
+ }
130
+ ],
131
+ "edges": [
132
+ {
133
+ "source": "g",
134
+ "target": "t",
135
+ "targetHandle": "in"
136
+ }
137
+ ],
138
+ "expectedUnits": {
139
+ "whole": 3,
140
+ "alone": 3
141
+ }
142
+ },
143
+ {
144
+ "name": "2b. Loop ×2 — a 15 s generation: 30.2 s",
145
+ "step": "loop",
146
+ "nodes": [
147
+ {
148
+ "id": "g",
149
+ "type": "generate-video",
150
+ "data": {
151
+ "provider": "kling-4",
152
+ "duration": 15
153
+ }
154
+ }
155
+ ],
156
+ "edges": [
157
+ {
158
+ "source": "g",
159
+ "target": "t",
160
+ "targetHandle": "in"
161
+ }
162
+ ],
163
+ "expectedUnits": {
164
+ "whole": 6,
165
+ "alone": 6
166
+ }
167
+ },
168
+ {
169
+ "name": "2c. Combine — two 15 s generations",
170
+ "step": "combine",
171
+ "nodes": [
172
+ {
173
+ "id": "g",
174
+ "type": "generate-video",
175
+ "data": {
176
+ "provider": "kling-4",
177
+ "duration": 15
178
+ }
179
+ },
180
+ {
181
+ "id": "h",
182
+ "type": "generate-video",
183
+ "data": {
184
+ "provider": "kling-4",
185
+ "duration": 15
186
+ }
187
+ }
188
+ ],
189
+ "edges": [
190
+ {
191
+ "source": "g",
192
+ "target": "t",
193
+ "targetHandle": "in"
194
+ },
195
+ {
196
+ "source": "h",
197
+ "target": "t",
198
+ "targetHandle": "in"
199
+ }
200
+ ],
201
+ "expectedUnits": {
202
+ "whole": 6,
203
+ "alone": 6
204
+ }
205
+ },
206
+ {
207
+ "name": "3. Trim — Seedance 2.5 on Auto: its longest clip, 30.1 s",
208
+ "step": "trim",
209
+ "nodes": [
210
+ {
211
+ "id": "g",
212
+ "type": "generate-video",
213
+ "data": {
214
+ "provider": "seedance-2-5",
215
+ "duration": -1
216
+ }
217
+ }
218
+ ],
219
+ "edges": [
220
+ {
221
+ "source": "g",
222
+ "target": "t",
223
+ "targetHandle": "in"
224
+ }
225
+ ],
226
+ "expectedUnits": {
227
+ "whole": 6,
228
+ "alone": 6
229
+ }
230
+ },
231
+ {
232
+ "name": "3b. Loop ×2 — Seedance 2.5 on Auto: 60.2 s",
233
+ "step": "loop",
234
+ "nodes": [
235
+ {
236
+ "id": "g",
237
+ "type": "generate-video",
238
+ "data": {
239
+ "provider": "seedance-2-5",
240
+ "duration": -1
241
+ }
242
+ }
243
+ ],
244
+ "edges": [
245
+ {
246
+ "source": "g",
247
+ "target": "t",
248
+ "targetHandle": "in"
249
+ }
250
+ ],
251
+ "expectedUnits": {
252
+ "whole": 12,
253
+ "alone": 12
254
+ }
255
+ },
256
+ {
257
+ "name": "3c. Combine — two Seedance 2.5 Auto clips",
258
+ "step": "combine",
259
+ "nodes": [
260
+ {
261
+ "id": "g",
262
+ "type": "generate-video",
263
+ "data": {
264
+ "provider": "seedance-2-5",
265
+ "duration": -1
266
+ }
267
+ },
268
+ {
269
+ "id": "h",
270
+ "type": "generate-video",
271
+ "data": {
272
+ "provider": "seedance-2-5",
273
+ "duration": -1
274
+ }
275
+ }
276
+ ],
277
+ "edges": [
278
+ {
279
+ "source": "g",
280
+ "target": "t",
281
+ "targetHandle": "in"
282
+ },
283
+ {
284
+ "source": "h",
285
+ "target": "t",
286
+ "targetHandle": "in"
287
+ }
288
+ ],
289
+ "expectedUnits": {
290
+ "whole": 12,
291
+ "alone": 12
292
+ }
293
+ },
294
+ {
295
+ "name": "4. Trim — an Extend Video (Seedance 2.5, +5 s) of a 10 s upload: 15.1 s",
296
+ "step": "trim",
297
+ "nodes": [
298
+ {
299
+ "id": "u",
300
+ "type": "upload-video",
301
+ "data": {
302
+ "url": "https://cdn.example/up10.mp4",
303
+ "generatedResults": [
304
+ {
305
+ "url": "https://cdn.example/up10.mp4",
306
+ "duration": 10
307
+ }
308
+ ]
309
+ }
310
+ },
311
+ {
312
+ "id": "x",
313
+ "type": "extend-video",
314
+ "data": {
315
+ "provider": "seedance-2-5-extend",
316
+ "duration": 5
317
+ }
318
+ }
319
+ ],
320
+ "edges": [
321
+ {
322
+ "source": "u",
323
+ "target": "x",
324
+ "targetHandle": "video"
325
+ },
326
+ {
327
+ "source": "x",
328
+ "target": "t",
329
+ "targetHandle": "in"
330
+ }
331
+ ],
332
+ "expectedUnits": {
333
+ "whole": 3,
334
+ "alone": 3
335
+ }
336
+ },
337
+ {
338
+ "name": "4b. Loop ×2 — the same extension: 30.2 s",
339
+ "step": "loop",
340
+ "nodes": [
341
+ {
342
+ "id": "u",
343
+ "type": "upload-video",
344
+ "data": {
345
+ "url": "https://cdn.example/up10.mp4",
346
+ "generatedResults": [
347
+ {
348
+ "url": "https://cdn.example/up10.mp4",
349
+ "duration": 10
350
+ }
351
+ ]
352
+ }
353
+ },
354
+ {
355
+ "id": "x",
356
+ "type": "extend-video",
357
+ "data": {
358
+ "provider": "seedance-2-5-extend",
359
+ "duration": 5
360
+ }
361
+ }
362
+ ],
363
+ "edges": [
364
+ {
365
+ "source": "u",
366
+ "target": "x",
367
+ "targetHandle": "video"
368
+ },
369
+ {
370
+ "source": "x",
371
+ "target": "t",
372
+ "targetHandle": "in"
373
+ }
374
+ ],
375
+ "expectedUnits": {
376
+ "whole": 6,
377
+ "alone": 6
378
+ }
379
+ },
380
+ {
381
+ "name": "4c. Combine — the extension and the 10 s upload it extends: 15.1 + 10 s, less 3 frames each",
382
+ "step": "combine",
383
+ "nodes": [
384
+ {
385
+ "id": "u",
386
+ "type": "upload-video",
387
+ "data": {
388
+ "url": "https://cdn.example/up10.mp4",
389
+ "generatedResults": [
390
+ {
391
+ "url": "https://cdn.example/up10.mp4",
392
+ "duration": 10
393
+ }
394
+ ]
395
+ }
396
+ },
397
+ {
398
+ "id": "x",
399
+ "type": "extend-video",
400
+ "data": {
401
+ "provider": "seedance-2-5-extend",
402
+ "duration": 5
403
+ }
404
+ }
405
+ ],
406
+ "edges": [
407
+ {
408
+ "source": "u",
409
+ "target": "x",
410
+ "targetHandle": "video"
411
+ },
412
+ {
413
+ "source": "x",
414
+ "target": "t",
415
+ "targetHandle": "in"
416
+ },
417
+ {
418
+ "source": "u",
419
+ "target": "t",
420
+ "targetHandle": "in"
421
+ }
422
+ ],
423
+ "expectedUnits": {
424
+ "whole": 5,
425
+ "alone": 5
426
+ }
427
+ },
428
+ {
429
+ "name": "5. Trim — a Duration node of 15 s wired into a generation stored at 5 s: 15.1 s",
430
+ "step": "trim",
431
+ "nodes": [
432
+ {
433
+ "id": "d",
434
+ "type": "duration",
435
+ "data": {
436
+ "seconds": 15
437
+ }
438
+ },
439
+ {
440
+ "id": "g",
441
+ "type": "generate-video",
442
+ "data": {
443
+ "provider": "kling-4",
444
+ "duration": 5
445
+ }
446
+ }
447
+ ],
448
+ "edges": [
449
+ {
450
+ "source": "d",
451
+ "target": "g",
452
+ "targetHandle": "field-duration"
453
+ },
454
+ {
455
+ "source": "g",
456
+ "target": "t",
457
+ "targetHandle": "in"
458
+ }
459
+ ],
460
+ "expectedUnits": {
461
+ "whole": 3,
462
+ "alone": 3
463
+ }
464
+ },
465
+ {
466
+ "name": "5b. Loop ×2 — the same mapped 15 s: 30.2 s",
467
+ "step": "loop",
468
+ "nodes": [
469
+ {
470
+ "id": "d",
471
+ "type": "duration",
472
+ "data": {
473
+ "seconds": 15
474
+ }
475
+ },
476
+ {
477
+ "id": "g",
478
+ "type": "generate-video",
479
+ "data": {
480
+ "provider": "kling-4",
481
+ "duration": 5
482
+ }
483
+ }
484
+ ],
485
+ "edges": [
486
+ {
487
+ "source": "d",
488
+ "target": "g",
489
+ "targetHandle": "field-duration"
490
+ },
491
+ {
492
+ "source": "g",
493
+ "target": "t",
494
+ "targetHandle": "in"
495
+ }
496
+ ],
497
+ "expectedUnits": {
498
+ "whole": 6,
499
+ "alone": 6
500
+ }
501
+ },
502
+ {
503
+ "name": "6. Trim — a generation whose duration an LLM Chat's answer sets: kling-4's longest clip, 30.1 s",
504
+ "step": "trim",
505
+ "nodes": [
506
+ {
507
+ "id": "l",
508
+ "type": "llm-chat",
509
+ "data": {}
510
+ },
511
+ {
512
+ "id": "g",
513
+ "type": "generate-video",
514
+ "data": {
515
+ "provider": "kling-4",
516
+ "duration": 5,
517
+ "fieldMappings": {
518
+ "duration": {
519
+ "sourceNodeId": "l"
520
+ }
521
+ }
522
+ }
523
+ }
524
+ ],
525
+ "edges": [
526
+ {
527
+ "source": "g",
528
+ "target": "t",
529
+ "targetHandle": "in"
530
+ }
531
+ ],
532
+ "expectedUnits": {
533
+ "whole": 6,
534
+ "alone": 6
535
+ }
536
+ },
537
+ {
538
+ "name": "6b. Loop ×2 — the same open duration: 60.2 s",
539
+ "step": "loop",
540
+ "nodes": [
541
+ {
542
+ "id": "l",
543
+ "type": "llm-chat",
544
+ "data": {}
545
+ },
546
+ {
547
+ "id": "g",
548
+ "type": "generate-video",
549
+ "data": {
550
+ "provider": "kling-4",
551
+ "duration": 5,
552
+ "fieldMappings": {
553
+ "duration": {
554
+ "sourceNodeId": "l"
555
+ }
556
+ }
557
+ }
558
+ }
559
+ ],
560
+ "edges": [
561
+ {
562
+ "source": "g",
563
+ "target": "t",
564
+ "targetHandle": "in"
565
+ }
566
+ ],
567
+ "expectedUnits": {
568
+ "whole": 12,
569
+ "alone": 12
570
+ }
571
+ },
572
+ {
573
+ "name": "7. Trim — Seedance 2 Fast set to 30 s renders its longest, 15 s: 15.1 s (never the setting)",
574
+ "step": "trim",
575
+ "nodes": [
576
+ {
577
+ "id": "g",
578
+ "type": "generate-video",
579
+ "data": {
580
+ "provider": "seedance-2-fast",
581
+ "duration": 30
582
+ }
583
+ }
584
+ ],
585
+ "edges": [
586
+ {
587
+ "source": "g",
588
+ "target": "t",
589
+ "targetHandle": "in"
590
+ }
591
+ ],
592
+ "expectedUnits": {
593
+ "whole": 3,
594
+ "alone": 3
595
+ }
596
+ },
597
+ {
598
+ "name": "7b. Loop ×2 — Kling Image to Video set to 7 s renders the 5 s it offers: 10.2 s",
599
+ "step": "loop",
600
+ "nodes": [
601
+ {
602
+ "id": "g",
603
+ "type": "image-to-video",
604
+ "data": {
605
+ "provider": "kling",
606
+ "duration": 7
607
+ }
608
+ }
609
+ ],
610
+ "edges": [
611
+ {
612
+ "source": "g",
613
+ "target": "t",
614
+ "targetHandle": "in"
615
+ }
616
+ ],
617
+ "expectedUnits": {
618
+ "whole": 2,
619
+ "alone": 2
620
+ }
621
+ },
622
+ {
623
+ "name": "8. Trim — a 10 s upload: its measured length, no slack",
624
+ "step": "trim",
625
+ "nodes": [
626
+ {
627
+ "id": "u",
628
+ "type": "upload-video",
629
+ "data": {
630
+ "url": "https://cdn.example/up10.mp4",
631
+ "generatedResults": [
632
+ {
633
+ "url": "https://cdn.example/up10.mp4",
634
+ "duration": 10
635
+ }
636
+ ]
637
+ }
638
+ }
639
+ ],
640
+ "edges": [
641
+ {
642
+ "source": "u",
643
+ "target": "t",
644
+ "targetHandle": "in"
645
+ }
646
+ ],
647
+ "expectedUnits": {
648
+ "whole": 2,
649
+ "alone": 2
650
+ }
651
+ },
652
+ {
653
+ "name": "8b. Loop ×2 — a 10 s upload: 20 s",
654
+ "step": "loop",
655
+ "nodes": [
656
+ {
657
+ "id": "u",
658
+ "type": "upload-video",
659
+ "data": {
660
+ "url": "https://cdn.example/up10.mp4",
661
+ "generatedResults": [
662
+ {
663
+ "url": "https://cdn.example/up10.mp4",
664
+ "duration": 10
665
+ }
666
+ ]
667
+ }
668
+ }
669
+ ],
670
+ "edges": [
671
+ {
672
+ "source": "u",
673
+ "target": "t",
674
+ "targetHandle": "in"
675
+ }
676
+ ],
677
+ "expectedUnits": {
678
+ "whole": 4,
679
+ "alone": 4
680
+ }
681
+ },
682
+ {
683
+ "name": "8c. Combine — two 10 s uploads: 19.75 s",
684
+ "step": "combine",
685
+ "nodes": [
686
+ {
687
+ "id": "u",
688
+ "type": "upload-video",
689
+ "data": {
690
+ "url": "https://cdn.example/a.mp4",
691
+ "generatedResults": [
692
+ {
693
+ "url": "https://cdn.example/a.mp4",
694
+ "duration": 10
695
+ }
696
+ ]
697
+ }
698
+ },
699
+ {
700
+ "id": "v",
701
+ "type": "upload-video",
702
+ "data": {
703
+ "url": "https://cdn.example/b.mp4",
704
+ "generatedResults": [
705
+ {
706
+ "url": "https://cdn.example/b.mp4",
707
+ "duration": 10
708
+ }
709
+ ]
710
+ }
711
+ }
712
+ ],
713
+ "edges": [
714
+ {
715
+ "source": "u",
716
+ "target": "t",
717
+ "targetHandle": "in"
718
+ },
719
+ {
720
+ "source": "v",
721
+ "target": "t",
722
+ "targetHandle": "in"
723
+ }
724
+ ],
725
+ "expectedUnits": {
726
+ "whole": 4,
727
+ "alone": 4
728
+ }
729
+ },
730
+ {
731
+ "name": "9. Loop ×2 — a 12 s Library clip whose length was measured at upload: 24 s",
732
+ "step": "loop",
733
+ "nodes": [
734
+ {
735
+ "id": "u",
736
+ "type": "upload-video",
737
+ "data": {
738
+ "url": "https://cdn.example/lib.mp4",
739
+ "assetId": "asset-1",
740
+ "generatedResults": [
741
+ {
742
+ "url": "https://cdn.example/lib.mp4",
743
+ "duration": 12
744
+ }
745
+ ],
746
+ "activeResultIndex": 0
747
+ }
748
+ }
749
+ ],
750
+ "edges": [
751
+ {
752
+ "source": "u",
753
+ "target": "t",
754
+ "targetHandle": "in"
755
+ }
756
+ ],
757
+ "expectedUnits": {
758
+ "whole": 5,
759
+ "alone": 5
760
+ }
761
+ },
762
+ {
763
+ "name": "10. Trim — a Library clip with no recorded length (a generated asset): unknown, the 8-second minimum",
764
+ "step": "trim",
765
+ "nodes": [
766
+ {
767
+ "id": "u",
768
+ "type": "upload-video",
769
+ "data": {
770
+ "url": "https://cdn.example/libg.mp4",
771
+ "assetId": "asset-2",
772
+ "generatedResults": [
773
+ {
774
+ "url": "https://cdn.example/libg.mp4"
775
+ }
776
+ ],
777
+ "activeResultIndex": 0
778
+ }
779
+ }
780
+ ],
781
+ "edges": [
782
+ {
783
+ "source": "u",
784
+ "target": "t",
785
+ "targetHandle": "in"
786
+ }
787
+ ],
788
+ "expectedUnits": {
789
+ "whole": 2,
790
+ "alone": 2
791
+ }
792
+ },
793
+ {
794
+ "name": "10b. Loop ×2 — the same unknown clip: 16 s",
795
+ "step": "loop",
796
+ "nodes": [
797
+ {
798
+ "id": "u",
799
+ "type": "upload-video",
800
+ "data": {
801
+ "url": "https://cdn.example/libg.mp4",
802
+ "assetId": "asset-2",
803
+ "generatedResults": [
804
+ {
805
+ "url": "https://cdn.example/libg.mp4"
806
+ }
807
+ ],
808
+ "activeResultIndex": 0
809
+ }
810
+ }
811
+ ],
812
+ "edges": [
813
+ {
814
+ "source": "u",
815
+ "target": "t",
816
+ "targetHandle": "in"
817
+ }
818
+ ],
819
+ "expectedUnits": {
820
+ "whole": 4,
821
+ "alone": 4
822
+ }
823
+ },
824
+ {
825
+ "name": "10c. Combine — a 10 s upload and a VEO extension (a length the catalog does not declare): 10 + 8 s",
826
+ "step": "combine",
827
+ "nodes": [
828
+ {
829
+ "id": "u",
830
+ "type": "upload-video",
831
+ "data": {
832
+ "url": "https://cdn.example/up10.mp4",
833
+ "generatedResults": [
834
+ {
835
+ "url": "https://cdn.example/up10.mp4",
836
+ "duration": 10
837
+ }
838
+ ]
839
+ }
840
+ },
841
+ {
842
+ "id": "x",
843
+ "type": "extend-video",
844
+ "data": {
845
+ "provider": "veo-extend",
846
+ "duration": 7
847
+ }
848
+ }
849
+ ],
850
+ "edges": [
851
+ {
852
+ "source": "u",
853
+ "target": "x",
854
+ "targetHandle": "video"
855
+ },
856
+ {
857
+ "source": "u",
858
+ "target": "t",
859
+ "targetHandle": "in"
860
+ },
861
+ {
862
+ "source": "x",
863
+ "target": "t",
864
+ "targetHandle": "in"
865
+ }
866
+ ],
867
+ "expectedUnits": {
868
+ "whole": 4,
869
+ "alone": 4
870
+ }
871
+ },
872
+ {
873
+ "name": "11. Trim — a FROZEN generation (take 5.042 s, now set to 10 s): it never runs, so its take",
874
+ "step": "trim",
875
+ "nodes": [
876
+ {
877
+ "id": "g",
878
+ "type": "generate-video",
879
+ "data": {
880
+ "provider": "kling-4",
881
+ "duration": 10,
882
+ "skipped": true,
883
+ "generatedResults": [
884
+ {
885
+ "url": "https://cdn.example/take.mp4",
886
+ "duration": 5.042
887
+ }
888
+ ],
889
+ "activeResultIndex": 0
890
+ }
891
+ }
892
+ ],
893
+ "edges": [
894
+ {
895
+ "source": "g",
896
+ "target": "t",
897
+ "targetHandle": "in"
898
+ }
899
+ ],
900
+ "expectedUnits": {
901
+ "whole": 1,
902
+ "alone": 1
903
+ }
904
+ },
905
+ {
906
+ "name": "11b. Loop ×2 — the same frozen take: 10.084 s",
907
+ "step": "loop",
908
+ "nodes": [
909
+ {
910
+ "id": "g",
911
+ "type": "generate-video",
912
+ "data": {
913
+ "provider": "kling-4",
914
+ "duration": 10,
915
+ "skipped": true,
916
+ "generatedResults": [
917
+ {
918
+ "url": "https://cdn.example/take.mp4",
919
+ "duration": 5.042
920
+ }
921
+ ],
922
+ "activeResultIndex": 0
923
+ }
924
+ }
925
+ ],
926
+ "edges": [
927
+ {
928
+ "source": "g",
929
+ "target": "t",
930
+ "targetHandle": "in"
931
+ }
932
+ ],
933
+ "expectedUnits": {
934
+ "whole": 2,
935
+ "alone": 2
936
+ }
937
+ },
938
+ {
939
+ "name": "12. Loop ×2 — a generation with a 5.042 s take, now set to 10 s: a whole run re-runs it (20.2 s); alone it hands on its take (10.084 s)",
940
+ "step": "loop",
941
+ "nodes": [
942
+ {
943
+ "id": "g",
944
+ "type": "generate-video",
945
+ "data": {
946
+ "provider": "kling-4",
947
+ "duration": 10,
948
+ "generatedResults": [
949
+ {
950
+ "url": "https://cdn.example/take.mp4",
951
+ "duration": 5.042
952
+ }
953
+ ],
954
+ "activeResultIndex": 0
955
+ }
956
+ }
957
+ ],
958
+ "edges": [
959
+ {
960
+ "source": "g",
961
+ "target": "t",
962
+ "targetHandle": "in"
963
+ }
964
+ ],
965
+ "expectedUnits": {
966
+ "whole": 4,
967
+ "alone": 2
968
+ },
969
+ "partial": {
970
+ "runSet": [
971
+ "g",
972
+ "t"
973
+ ],
974
+ "expectedUnits": 4
975
+ }
976
+ },
977
+ {
978
+ "name": "12b. Combine — the same generation and a 10 s upload: a run that leaves the generation out reads its take",
979
+ "step": "combine",
980
+ "nodes": [
981
+ {
982
+ "id": "g",
983
+ "type": "generate-video",
984
+ "data": {
985
+ "provider": "kling-4",
986
+ "duration": 10,
987
+ "generatedResults": [
988
+ {
989
+ "url": "https://cdn.example/take.mp4",
990
+ "duration": 5.042
991
+ }
992
+ ],
993
+ "activeResultIndex": 0
994
+ }
995
+ },
996
+ {
997
+ "id": "u",
998
+ "type": "upload-video",
999
+ "data": {
1000
+ "url": "https://cdn.example/up10.mp4",
1001
+ "generatedResults": [
1002
+ {
1003
+ "url": "https://cdn.example/up10.mp4",
1004
+ "duration": 10
1005
+ }
1006
+ ]
1007
+ }
1008
+ }
1009
+ ],
1010
+ "edges": [
1011
+ {
1012
+ "source": "g",
1013
+ "target": "t",
1014
+ "targetHandle": "in"
1015
+ },
1016
+ {
1017
+ "source": "u",
1018
+ "target": "t",
1019
+ "targetHandle": "in"
1020
+ }
1021
+ ],
1022
+ "expectedUnits": {
1023
+ "whole": 4,
1024
+ "alone": 3
1025
+ },
1026
+ "partial": {
1027
+ "runSet": [
1028
+ "u",
1029
+ "t"
1030
+ ],
1031
+ "expectedUnits": 3
1032
+ }
1033
+ },
1034
+ {
1035
+ "name": "13. Loop ×2 after a Trim of a 5 s generation (a chain): 5.1 s passed on, 10.2 s",
1036
+ "step": "loop",
1037
+ "nodes": [
1038
+ {
1039
+ "id": "g",
1040
+ "type": "generate-video",
1041
+ "data": {
1042
+ "provider": "kling-4",
1043
+ "duration": 5
1044
+ }
1045
+ },
1046
+ {
1047
+ "id": "r",
1048
+ "type": "trim-video",
1049
+ "data": {
1050
+ "trimMode": "seconds",
1051
+ "trimStartSeconds": 0,
1052
+ "trimEndSeconds": 0
1053
+ }
1054
+ }
1055
+ ],
1056
+ "edges": [
1057
+ {
1058
+ "source": "g",
1059
+ "target": "r",
1060
+ "targetHandle": "in"
1061
+ },
1062
+ {
1063
+ "source": "r",
1064
+ "target": "t",
1065
+ "targetHandle": "in"
1066
+ }
1067
+ ],
1068
+ "expectedUnits": {
1069
+ "whole": 2,
1070
+ "alone": 2
1071
+ }
1072
+ },
1073
+ {
1074
+ "name": "13b. Loop ×2 after a Trim of a generation with a 5.042 s take, now 10 s: the Trim runs on the take when only it and the Loop run",
1075
+ "step": "loop",
1076
+ "nodes": [
1077
+ {
1078
+ "id": "g",
1079
+ "type": "generate-video",
1080
+ "data": {
1081
+ "provider": "kling-4",
1082
+ "duration": 10,
1083
+ "generatedResults": [
1084
+ {
1085
+ "url": "https://cdn.example/take.mp4",
1086
+ "duration": 5.042
1087
+ }
1088
+ ],
1089
+ "activeResultIndex": 0
1090
+ }
1091
+ },
1092
+ {
1093
+ "id": "r",
1094
+ "type": "trim-video",
1095
+ "data": {
1096
+ "trimMode": "seconds",
1097
+ "trimStartSeconds": 0,
1098
+ "trimEndSeconds": 0
1099
+ }
1100
+ }
1101
+ ],
1102
+ "edges": [
1103
+ {
1104
+ "source": "g",
1105
+ "target": "r",
1106
+ "targetHandle": "in"
1107
+ },
1108
+ {
1109
+ "source": "r",
1110
+ "target": "t",
1111
+ "targetHandle": "in"
1112
+ }
1113
+ ],
1114
+ "expectedUnits": {
1115
+ "whole": 4,
1116
+ "alone": 2
1117
+ },
1118
+ "partial": {
1119
+ "runSet": [
1120
+ "r",
1121
+ "t"
1122
+ ],
1123
+ "expectedUnits": 2
1124
+ }
1125
+ },
1126
+ {
1127
+ "name": "14. Trim to a fixed window (0–4 s) of a 15 s generation: its window, whatever the clip",
1128
+ "step": "trim",
1129
+ "stepData": {
1130
+ "trimMode": "time",
1131
+ "startTime": 0,
1132
+ "endTime": 4
1133
+ },
1134
+ "nodes": [
1135
+ {
1136
+ "id": "g",
1137
+ "type": "generate-video",
1138
+ "data": {
1139
+ "provider": "kling-4",
1140
+ "duration": 15
1141
+ }
1142
+ }
1143
+ ],
1144
+ "edges": [
1145
+ {
1146
+ "source": "g",
1147
+ "target": "t",
1148
+ "targetHandle": "in"
1149
+ }
1150
+ ],
1151
+ "expectedUnits": {
1152
+ "whole": 1,
1153
+ "alone": 1
1154
+ }
1155
+ },
1156
+ {
1157
+ "name": "15. Trim — a clean 10 s generation: 10.1 s planned, less the grace: 10 s, 2 units (a frame past the mark is free)",
1158
+ "step": "trim",
1159
+ "nodes": [
1160
+ {
1161
+ "id": "g",
1162
+ "type": "generate-video",
1163
+ "data": {
1164
+ "provider": "kling-4",
1165
+ "duration": 10
1166
+ }
1167
+ }
1168
+ ],
1169
+ "edges": [
1170
+ {
1171
+ "source": "g",
1172
+ "target": "t",
1173
+ "targetHandle": "in"
1174
+ }
1175
+ ],
1176
+ "expectedUnits": {
1177
+ "whole": 2,
1178
+ "alone": 2
1179
+ }
1180
+ },
1181
+ {
1182
+ "name": "15b. Loop ×2 — a clean 10 s generation: 20 s, 4 units",
1183
+ "step": "loop",
1184
+ "nodes": [
1185
+ {
1186
+ "id": "g",
1187
+ "type": "generate-video",
1188
+ "data": {
1189
+ "provider": "kling-4",
1190
+ "duration": 10
1191
+ }
1192
+ }
1193
+ ],
1194
+ "edges": [
1195
+ {
1196
+ "source": "g",
1197
+ "target": "t",
1198
+ "targetHandle": "in"
1199
+ }
1200
+ ],
1201
+ "expectedUnits": {
1202
+ "whole": 4,
1203
+ "alone": 4
1204
+ }
1205
+ },
1206
+ {
1207
+ "name": "15c. Loop ×3 — a clean 10 s generation: the grace before the copies, 30 s, 6 units",
1208
+ "step": "loop",
1209
+ "stepData": {
1210
+ "mode": "repeat",
1211
+ "repeatCount": 3
1212
+ },
1213
+ "nodes": [
1214
+ {
1215
+ "id": "g",
1216
+ "type": "generate-video",
1217
+ "data": {
1218
+ "provider": "kling-4",
1219
+ "duration": 10
1220
+ }
1221
+ }
1222
+ ],
1223
+ "edges": [
1224
+ {
1225
+ "source": "g",
1226
+ "target": "t",
1227
+ "targetHandle": "in"
1228
+ }
1229
+ ],
1230
+ "expectedUnits": {
1231
+ "whole": 6,
1232
+ "alone": 6
1233
+ }
1234
+ },
1235
+ {
1236
+ "name": "16. Trim — an upload measured at 10.1 s: at the edge of the grace, 2 units",
1237
+ "step": "trim",
1238
+ "nodes": [
1239
+ {
1240
+ "id": "u",
1241
+ "type": "upload-video",
1242
+ "data": {
1243
+ "url": "https://cdn.example/u.mp4",
1244
+ "generatedResults": [
1245
+ {
1246
+ "url": "https://cdn.example/u.mp4",
1247
+ "duration": 10.1
1248
+ }
1249
+ ]
1250
+ }
1251
+ }
1252
+ ],
1253
+ "edges": [
1254
+ {
1255
+ "source": "u",
1256
+ "target": "t",
1257
+ "targetHandle": "in"
1258
+ }
1259
+ ],
1260
+ "expectedUnits": {
1261
+ "whole": 2,
1262
+ "alone": 2
1263
+ }
1264
+ },
1265
+ {
1266
+ "name": "16b. Trim — an upload measured at 10.11 s: past the grace, 3 units",
1267
+ "step": "trim",
1268
+ "nodes": [
1269
+ {
1270
+ "id": "u",
1271
+ "type": "upload-video",
1272
+ "data": {
1273
+ "url": "https://cdn.example/u.mp4",
1274
+ "generatedResults": [
1275
+ {
1276
+ "url": "https://cdn.example/u.mp4",
1277
+ "duration": 10.11
1278
+ }
1279
+ ]
1280
+ }
1281
+ }
1282
+ ],
1283
+ "edges": [
1284
+ {
1285
+ "source": "u",
1286
+ "target": "t",
1287
+ "targetHandle": "in"
1288
+ }
1289
+ ],
1290
+ "expectedUnits": {
1291
+ "whole": 3,
1292
+ "alone": 3
1293
+ }
1294
+ },
1295
+ {
1296
+ "name": "17. Trim with the node's own defaults (time, 0 to an end of 0): no end, so from 0 to the clip's end — a 10 s upload, 9.9 s, 2 units",
1297
+ "step": "trim",
1298
+ "stepData": {
1299
+ "trimMode": "time",
1300
+ "startTime": 0,
1301
+ "endTime": 0
1302
+ },
1303
+ "nodes": [
1304
+ {
1305
+ "id": "u",
1306
+ "type": "upload-video",
1307
+ "data": {
1308
+ "url": "https://cdn.example/up10.mp4",
1309
+ "generatedResults": [
1310
+ {
1311
+ "url": "https://cdn.example/up10.mp4",
1312
+ "duration": 10
1313
+ }
1314
+ ]
1315
+ }
1316
+ }
1317
+ ],
1318
+ "edges": [
1319
+ {
1320
+ "source": "u",
1321
+ "target": "t",
1322
+ "targetHandle": "in"
1323
+ }
1324
+ ],
1325
+ "expectedUnits": {
1326
+ "whole": 2,
1327
+ "alone": 2
1328
+ }
1329
+ },
1330
+ {
1331
+ "name": "17b. Trim from 3 s with no end, of a 15 s generation: 15.1 s planned, less the grace, less 3 s: 12 s, 3 units",
1332
+ "step": "trim",
1333
+ "stepData": {
1334
+ "trimMode": "time",
1335
+ "startTime": 3,
1336
+ "endTime": 0
1337
+ },
1338
+ "nodes": [
1339
+ {
1340
+ "id": "g",
1341
+ "type": "generate-video",
1342
+ "data": {
1343
+ "provider": "kling-4",
1344
+ "duration": 15
1345
+ }
1346
+ }
1347
+ ],
1348
+ "edges": [
1349
+ {
1350
+ "source": "g",
1351
+ "target": "t",
1352
+ "targetHandle": "in"
1353
+ }
1354
+ ],
1355
+ "expectedUnits": {
1356
+ "whole": 3,
1357
+ "alone": 3
1358
+ }
1359
+ },
1360
+ {
1361
+ "name": "17c. Trim in seconds mode (0 + 0) with a keep-first setting left from an earlier mode: the run sends the seconds fields only — a 15 s generation, 15 s, 3 units",
1362
+ "step": "trim",
1363
+ "stepData": {
1364
+ "trimMode": "seconds",
1365
+ "trimStartSeconds": 0,
1366
+ "trimEndSeconds": 0,
1367
+ "keepFirstSeconds": 3
1368
+ },
1369
+ "nodes": [
1370
+ {
1371
+ "id": "g",
1372
+ "type": "generate-video",
1373
+ "data": {
1374
+ "provider": "kling-4",
1375
+ "duration": 15
1376
+ }
1377
+ }
1378
+ ],
1379
+ "edges": [
1380
+ {
1381
+ "source": "g",
1382
+ "target": "t",
1383
+ "targetHandle": "in"
1384
+ }
1385
+ ],
1386
+ "expectedUnits": {
1387
+ "whole": 3,
1388
+ "alone": 3
1389
+ }
1390
+ },
1391
+ {
1392
+ "name": "17d. Trim by smart loop cut, of a clean 10 s generation: 10 s, 2 units, and 1 for the 16 frames searched",
1393
+ "step": "trim",
1394
+ "stepData": {
1395
+ "trimMode": "smart-loop-cut"
1396
+ },
1397
+ "nodes": [
1398
+ {
1399
+ "id": "g",
1400
+ "type": "generate-video",
1401
+ "data": {
1402
+ "provider": "kling-4",
1403
+ "duration": 10
1404
+ }
1405
+ }
1406
+ ],
1407
+ "edges": [
1408
+ {
1409
+ "source": "g",
1410
+ "target": "t",
1411
+ "targetHandle": "in"
1412
+ }
1413
+ ],
1414
+ "expectedUnits": {
1415
+ "whole": 3,
1416
+ "alone": 3
1417
+ }
1418
+ },
1419
+ {
1420
+ "name": "18. Combine — a Duration node of 15 s wired into a generation stored at 5 s, and a 5 s generation: 15.1 + 5.1 s, less the grace and 3 frames each: 19.75 s",
1421
+ "step": "combine",
1422
+ "nodes": [
1423
+ {
1424
+ "id": "d",
1425
+ "type": "duration",
1426
+ "data": {
1427
+ "seconds": 15
1428
+ }
1429
+ },
1430
+ {
1431
+ "id": "g",
1432
+ "type": "generate-video",
1433
+ "data": {
1434
+ "provider": "kling-4",
1435
+ "duration": 5
1436
+ }
1437
+ },
1438
+ {
1439
+ "id": "h",
1440
+ "type": "generate-video",
1441
+ "data": {
1442
+ "provider": "kling-4",
1443
+ "duration": 5
1444
+ }
1445
+ }
1446
+ ],
1447
+ "edges": [
1448
+ {
1449
+ "source": "d",
1450
+ "target": "g",
1451
+ "targetHandle": "field-duration"
1452
+ },
1453
+ {
1454
+ "source": "g",
1455
+ "target": "t",
1456
+ "targetHandle": "in"
1457
+ },
1458
+ {
1459
+ "source": "h",
1460
+ "target": "t",
1461
+ "targetHandle": "in"
1462
+ }
1463
+ ],
1464
+ "expectedUnits": {
1465
+ "whole": 4,
1466
+ "alone": 4
1467
+ }
1468
+ },
1469
+ {
1470
+ "name": "18b. Combine — a generation whose duration an LLM Chat's answer sets (kling-4's longest clip, 30.1 s) and a 5 s generation: 34.75 s",
1471
+ "step": "combine",
1472
+ "nodes": [
1473
+ {
1474
+ "id": "l",
1475
+ "type": "llm-chat",
1476
+ "data": {}
1477
+ },
1478
+ {
1479
+ "id": "g",
1480
+ "type": "generate-video",
1481
+ "data": {
1482
+ "provider": "kling-4",
1483
+ "duration": 5,
1484
+ "fieldMappings": {
1485
+ "duration": {
1486
+ "sourceNodeId": "l"
1487
+ }
1488
+ }
1489
+ }
1490
+ },
1491
+ {
1492
+ "id": "h",
1493
+ "type": "generate-video",
1494
+ "data": {
1495
+ "provider": "kling-4",
1496
+ "duration": 5
1497
+ }
1498
+ }
1499
+ ],
1500
+ "edges": [
1501
+ {
1502
+ "source": "g",
1503
+ "target": "t",
1504
+ "targetHandle": "in"
1505
+ },
1506
+ {
1507
+ "source": "h",
1508
+ "target": "t",
1509
+ "targetHandle": "in"
1510
+ }
1511
+ ],
1512
+ "expectedUnits": {
1513
+ "whole": 7,
1514
+ "alone": 7
1515
+ }
1516
+ },
1517
+ {
1518
+ "name": "18c. Combine — Seedance 2 Fast set to 30 s (renders its longest, 15 s) and a 5 s generation: 15.1 + 5.1 s, never the setting: 19.75 s",
1519
+ "step": "combine",
1520
+ "nodes": [
1521
+ {
1522
+ "id": "g",
1523
+ "type": "generate-video",
1524
+ "data": {
1525
+ "provider": "seedance-2-fast",
1526
+ "duration": 30
1527
+ }
1528
+ },
1529
+ {
1530
+ "id": "h",
1531
+ "type": "generate-video",
1532
+ "data": {
1533
+ "provider": "kling-4",
1534
+ "duration": 5
1535
+ }
1536
+ }
1537
+ ],
1538
+ "edges": [
1539
+ {
1540
+ "source": "g",
1541
+ "target": "t",
1542
+ "targetHandle": "in"
1543
+ },
1544
+ {
1545
+ "source": "h",
1546
+ "target": "t",
1547
+ "targetHandle": "in"
1548
+ }
1549
+ ],
1550
+ "expectedUnits": {
1551
+ "whole": 4,
1552
+ "alone": 4
1553
+ }
1554
+ },
1555
+ {
1556
+ "name": "18d. Combine — a 12 s Library clip whose length was measured at upload, and a 10 s upload: 11.9 + 9.9 s, less 3 frames each: 21.55 s",
1557
+ "step": "combine",
1558
+ "nodes": [
1559
+ {
1560
+ "id": "u",
1561
+ "type": "upload-video",
1562
+ "data": {
1563
+ "url": "https://cdn.example/lib.mp4",
1564
+ "assetId": "asset-1",
1565
+ "generatedResults": [
1566
+ {
1567
+ "url": "https://cdn.example/lib.mp4",
1568
+ "duration": 12
1569
+ }
1570
+ ],
1571
+ "activeResultIndex": 0
1572
+ }
1573
+ },
1574
+ {
1575
+ "id": "v",
1576
+ "type": "upload-video",
1577
+ "data": {
1578
+ "url": "https://cdn.example/up10.mp4",
1579
+ "generatedResults": [
1580
+ {
1581
+ "url": "https://cdn.example/up10.mp4",
1582
+ "duration": 10
1583
+ }
1584
+ ]
1585
+ }
1586
+ }
1587
+ ],
1588
+ "edges": [
1589
+ {
1590
+ "source": "u",
1591
+ "target": "t",
1592
+ "targetHandle": "in"
1593
+ },
1594
+ {
1595
+ "source": "v",
1596
+ "target": "t",
1597
+ "targetHandle": "in"
1598
+ }
1599
+ ],
1600
+ "expectedUnits": {
1601
+ "whole": 5,
1602
+ "alone": 5
1603
+ }
1604
+ },
1605
+ {
1606
+ "name": "18e. Combine — a FROZEN generation (take 5.042 s, now set to 10 s) and a 10 s upload: it never runs, so its take: 14.59 s",
1607
+ "step": "combine",
1608
+ "nodes": [
1609
+ {
1610
+ "id": "g",
1611
+ "type": "generate-video",
1612
+ "data": {
1613
+ "provider": "kling-4",
1614
+ "duration": 10,
1615
+ "skipped": true,
1616
+ "generatedResults": [
1617
+ {
1618
+ "url": "https://cdn.example/take.mp4",
1619
+ "duration": 5.042
1620
+ }
1621
+ ],
1622
+ "activeResultIndex": 0
1623
+ }
1624
+ },
1625
+ {
1626
+ "id": "v",
1627
+ "type": "upload-video",
1628
+ "data": {
1629
+ "url": "https://cdn.example/up10.mp4",
1630
+ "generatedResults": [
1631
+ {
1632
+ "url": "https://cdn.example/up10.mp4",
1633
+ "duration": 10
1634
+ }
1635
+ ]
1636
+ }
1637
+ }
1638
+ ],
1639
+ "edges": [
1640
+ {
1641
+ "source": "g",
1642
+ "target": "t",
1643
+ "targetHandle": "in"
1644
+ },
1645
+ {
1646
+ "source": "v",
1647
+ "target": "t",
1648
+ "targetHandle": "in"
1649
+ }
1650
+ ],
1651
+ "expectedUnits": {
1652
+ "whole": 3,
1653
+ "alone": 3
1654
+ }
1655
+ },
1656
+ {
1657
+ "name": "19. Trim — a 12 s Library clip whose length was measured at upload: 11.9 s, 3 units",
1658
+ "step": "trim",
1659
+ "nodes": [
1660
+ {
1661
+ "id": "u",
1662
+ "type": "upload-video",
1663
+ "data": {
1664
+ "url": "https://cdn.example/lib.mp4",
1665
+ "assetId": "asset-1",
1666
+ "generatedResults": [
1667
+ {
1668
+ "url": "https://cdn.example/lib.mp4",
1669
+ "duration": 12
1670
+ }
1671
+ ],
1672
+ "activeResultIndex": 0
1673
+ }
1674
+ }
1675
+ ],
1676
+ "edges": [
1677
+ {
1678
+ "source": "u",
1679
+ "target": "t",
1680
+ "targetHandle": "in"
1681
+ }
1682
+ ],
1683
+ "expectedUnits": {
1684
+ "whole": 3,
1685
+ "alone": 3
1686
+ }
1687
+ },
1688
+ {
1689
+ "name": "19b. Trim — a generation with a 5.042 s take, now set to 10 s: alone it is outside the run and hands on its take (1 unit); a run that re-runs it reads its 10 s (2 units)",
1690
+ "step": "trim",
1691
+ "nodes": [
1692
+ {
1693
+ "id": "g",
1694
+ "type": "generate-video",
1695
+ "data": {
1696
+ "provider": "kling-4",
1697
+ "duration": 10,
1698
+ "generatedResults": [
1699
+ {
1700
+ "url": "https://cdn.example/take.mp4",
1701
+ "duration": 5.042
1702
+ }
1703
+ ],
1704
+ "activeResultIndex": 0
1705
+ }
1706
+ }
1707
+ ],
1708
+ "edges": [
1709
+ {
1710
+ "source": "g",
1711
+ "target": "t",
1712
+ "targetHandle": "in"
1713
+ }
1714
+ ],
1715
+ "expectedUnits": {
1716
+ "whole": 2,
1717
+ "alone": 1
1718
+ },
1719
+ "partial": {
1720
+ "runSet": [
1721
+ "g",
1722
+ "t"
1723
+ ],
1724
+ "expectedUnits": 2
1725
+ }
1726
+ },
1727
+ {
1728
+ "name": "20. Trim to 0–60 s of a 15 s generation: the window ends at the clip (15.1 s planned, less the grace: 15 s), 3 units",
1729
+ "step": "trim",
1730
+ "stepData": {
1731
+ "trimMode": "time",
1732
+ "startTime": 0,
1733
+ "endTime": 60
1734
+ },
1735
+ "nodes": [
1736
+ {
1737
+ "id": "g",
1738
+ "type": "generate-video",
1739
+ "data": {
1740
+ "provider": "kling-4",
1741
+ "duration": 15
1742
+ }
1743
+ }
1744
+ ],
1745
+ "edges": [
1746
+ {
1747
+ "source": "g",
1748
+ "target": "t",
1749
+ "targetHandle": "in"
1750
+ }
1751
+ ],
1752
+ "expectedUnits": {
1753
+ "whole": 3,
1754
+ "alone": 3
1755
+ }
1756
+ },
1757
+ {
1758
+ "name": "20b. Trim from 20 to 30 s of a 15 s generation: it starts past the clip, the one-unit minimum",
1759
+ "step": "trim",
1760
+ "stepData": {
1761
+ "trimMode": "time",
1762
+ "startTime": 20,
1763
+ "endTime": 30
1764
+ },
1765
+ "nodes": [
1766
+ {
1767
+ "id": "g",
1768
+ "type": "generate-video",
1769
+ "data": {
1770
+ "provider": "kling-4",
1771
+ "duration": 15
1772
+ }
1773
+ }
1774
+ ],
1775
+ "edges": [
1776
+ {
1777
+ "source": "g",
1778
+ "target": "t",
1779
+ "targetHandle": "in"
1780
+ }
1781
+ ],
1782
+ "expectedUnits": {
1783
+ "whole": 1,
1784
+ "alone": 1
1785
+ }
1786
+ },
1787
+ {
1788
+ "name": "20c. Trim to 0–60 s of a Library clip with no recorded length: never cut at the 8-second stand-in, the window: 60 s, 12 units",
1789
+ "step": "trim",
1790
+ "stepData": {
1791
+ "trimMode": "time",
1792
+ "startTime": 0,
1793
+ "endTime": 60
1794
+ },
1795
+ "nodes": [
1796
+ {
1797
+ "id": "u",
1798
+ "type": "upload-video",
1799
+ "data": {
1800
+ "url": "https://cdn.example/libg.mp4",
1801
+ "assetId": "asset-2",
1802
+ "generatedResults": [
1803
+ {
1804
+ "url": "https://cdn.example/libg.mp4"
1805
+ }
1806
+ ],
1807
+ "activeResultIndex": 0
1808
+ }
1809
+ }
1810
+ ],
1811
+ "edges": [
1812
+ {
1813
+ "source": "u",
1814
+ "target": "t",
1815
+ "targetHandle": "in"
1816
+ }
1817
+ ],
1818
+ "expectedUnits": {
1819
+ "whole": 12,
1820
+ "alone": 12
1821
+ }
1822
+ },
1823
+ {
1824
+ "name": "21. Trim — a generation set to 15 s holding a take with no recorded length (a fixed-length run records none, so the take was made at its settings): alone it hands on that take, 15 s plus the slack; a whole run re-runs it, the same",
1825
+ "step": "trim",
1826
+ "nodes": [
1827
+ {
1828
+ "id": "g",
1829
+ "type": "generate-video",
1830
+ "data": {
1831
+ "provider": "kling-4",
1832
+ "duration": 15,
1833
+ "generatedResults": [
1834
+ {
1835
+ "url": "https://cdn.example/take.mp4"
1836
+ }
1837
+ ],
1838
+ "activeResultIndex": 0
1839
+ }
1840
+ }
1841
+ ],
1842
+ "edges": [
1843
+ {
1844
+ "source": "g",
1845
+ "target": "t",
1846
+ "targetHandle": "in"
1847
+ }
1848
+ ],
1849
+ "expectedUnits": {
1850
+ "whole": 3,
1851
+ "alone": 3
1852
+ }
1853
+ },
1854
+ {
1855
+ "name": "21b. Loop ×2 — the same take: 30.2 s",
1856
+ "step": "loop",
1857
+ "nodes": [
1858
+ {
1859
+ "id": "g",
1860
+ "type": "generate-video",
1861
+ "data": {
1862
+ "provider": "kling-4",
1863
+ "duration": 15,
1864
+ "generatedResults": [
1865
+ {
1866
+ "url": "https://cdn.example/take.mp4"
1867
+ }
1868
+ ],
1869
+ "activeResultIndex": 0
1870
+ }
1871
+ }
1872
+ ],
1873
+ "edges": [
1874
+ {
1875
+ "source": "g",
1876
+ "target": "t",
1877
+ "targetHandle": "in"
1878
+ }
1879
+ ],
1880
+ "expectedUnits": {
1881
+ "whole": 6,
1882
+ "alone": 6
1883
+ }
1884
+ },
1885
+ {
1886
+ "name": "21c. Combine — the same take and a 10 s upload",
1887
+ "step": "combine",
1888
+ "nodes": [
1889
+ {
1890
+ "id": "g",
1891
+ "type": "generate-video",
1892
+ "data": {
1893
+ "provider": "kling-4",
1894
+ "duration": 15,
1895
+ "generatedResults": [
1896
+ {
1897
+ "url": "https://cdn.example/take.mp4"
1898
+ }
1899
+ ],
1900
+ "activeResultIndex": 0
1901
+ }
1902
+ },
1903
+ {
1904
+ "id": "u",
1905
+ "type": "upload-video",
1906
+ "data": {
1907
+ "url": "https://cdn.example/up10.mp4",
1908
+ "generatedResults": [
1909
+ {
1910
+ "url": "https://cdn.example/up10.mp4",
1911
+ "duration": 10
1912
+ }
1913
+ ],
1914
+ "activeResultIndex": 0
1915
+ }
1916
+ }
1917
+ ],
1918
+ "edges": [
1919
+ {
1920
+ "source": "g",
1921
+ "target": "t",
1922
+ "targetHandle": "videos"
1923
+ },
1924
+ {
1925
+ "source": "u",
1926
+ "target": "t",
1927
+ "targetHandle": "videos"
1928
+ }
1929
+ ],
1930
+ "expectedUnits": {
1931
+ "whole": 5,
1932
+ "alone": 5
1933
+ }
1934
+ },
1935
+ {
1936
+ "name": "22. Trim — Seedance 2.5 on Auto with a 5 s reference clip and no task type: the model may take it as a reference, so its longest clip, 30 s",
1937
+ "step": "trim",
1938
+ "nodes": [
1939
+ {
1940
+ "id": "u",
1941
+ "type": "upload-video",
1942
+ "data": {
1943
+ "url": "https://cdn.example/u5.mp4",
1944
+ "generatedResults": [
1945
+ {
1946
+ "url": "https://cdn.example/u5.mp4",
1947
+ "duration": 5
1948
+ }
1949
+ ],
1950
+ "activeResultIndex": 0
1951
+ }
1952
+ },
1953
+ {
1954
+ "id": "g",
1955
+ "type": "generate-video",
1956
+ "data": {
1957
+ "provider": "seedance-2-5",
1958
+ "duration": -1
1959
+ }
1960
+ }
1961
+ ],
1962
+ "edges": [
1963
+ {
1964
+ "source": "u",
1965
+ "target": "g",
1966
+ "targetHandle": "videoReferences"
1967
+ },
1968
+ {
1969
+ "source": "g",
1970
+ "target": "t",
1971
+ "targetHandle": "in"
1972
+ }
1973
+ ],
1974
+ "expectedUnits": {
1975
+ "whole": 6,
1976
+ "alone": 6
1977
+ }
1978
+ },
1979
+ {
1980
+ "name": "22b. Trim — the same run declaring The video to edit: the clip rounded up plus a second, 6 s",
1981
+ "step": "trim",
1982
+ "nodes": [
1983
+ {
1984
+ "id": "u",
1985
+ "type": "upload-video",
1986
+ "data": {
1987
+ "url": "https://cdn.example/u5.mp4",
1988
+ "generatedResults": [
1989
+ {
1990
+ "url": "https://cdn.example/u5.mp4",
1991
+ "duration": 5
1992
+ }
1993
+ ],
1994
+ "activeResultIndex": 0
1995
+ }
1996
+ },
1997
+ {
1998
+ "id": "g",
1999
+ "type": "generate-video",
2000
+ "data": {
2001
+ "provider": "seedance-2-5",
2002
+ "duration": -1,
2003
+ "referenceTaskType": "edit"
2004
+ }
2005
+ }
2006
+ ],
2007
+ "edges": [
2008
+ {
2009
+ "source": "u",
2010
+ "target": "g",
2011
+ "targetHandle": "videoReferences"
2012
+ },
2013
+ {
2014
+ "source": "g",
2015
+ "target": "t",
2016
+ "targetHandle": "in"
2017
+ }
2018
+ ],
2019
+ "expectedUnits": {
2020
+ "whole": 2,
2021
+ "alone": 2
2022
+ }
2023
+ },
2024
+ {
2025
+ "name": "23. Loop ×4 after a LOSSLESS Trim of 3–8 s of a 10 s upload: a keyframe-snapped cut can start before its window and run a few frames past its end (a stream copy of 3–8 s with keyframes at 0 and 10 s measures 8.083 s), so the Trim passes on its end plus the copy's overshoot, 8.6 s, at most its input: 4 × 8.5 s, 7 units",
2026
+ "step": "loop",
2027
+ "stepData": {
2028
+ "mode": "repeat",
2029
+ "repeatCount": 4
2030
+ },
2031
+ "nodes": [
2032
+ {
2033
+ "id": "u",
2034
+ "type": "upload-video",
2035
+ "data": {
2036
+ "url": "https://cdn.example/up10.mp4",
2037
+ "generatedResults": [
2038
+ {
2039
+ "url": "https://cdn.example/up10.mp4",
2040
+ "duration": 10
2041
+ }
2042
+ ],
2043
+ "activeResultIndex": 0
2044
+ }
2045
+ },
2046
+ {
2047
+ "id": "r",
2048
+ "type": "trim-video",
2049
+ "data": {
2050
+ "trimMode": "time",
2051
+ "startTime": 3,
2052
+ "endTime": 8,
2053
+ "losslessKeyframe": true
2054
+ }
2055
+ }
2056
+ ],
2057
+ "edges": [
2058
+ {
2059
+ "source": "u",
2060
+ "target": "r",
2061
+ "targetHandle": "in"
2062
+ },
2063
+ {
2064
+ "source": "r",
2065
+ "target": "t",
2066
+ "targetHandle": "in"
2067
+ }
2068
+ ],
2069
+ "expectedUnits": {
2070
+ "whole": 7,
2071
+ "alone": 7
2072
+ }
2073
+ },
2074
+ {
2075
+ "name": "23b. The same Trim re-encoded (Lossless off): its window, 5 s; Loop ×4 is 20 s, 4 units",
2076
+ "step": "loop",
2077
+ "stepData": {
2078
+ "mode": "repeat",
2079
+ "repeatCount": 4
2080
+ },
2081
+ "nodes": [
2082
+ {
2083
+ "id": "u",
2084
+ "type": "upload-video",
2085
+ "data": {
2086
+ "url": "https://cdn.example/up10.mp4",
2087
+ "generatedResults": [
2088
+ {
2089
+ "url": "https://cdn.example/up10.mp4",
2090
+ "duration": 10
2091
+ }
2092
+ ],
2093
+ "activeResultIndex": 0
2094
+ }
2095
+ },
2096
+ {
2097
+ "id": "r",
2098
+ "type": "trim-video",
2099
+ "data": {
2100
+ "trimMode": "time",
2101
+ "startTime": 3,
2102
+ "endTime": 8
2103
+ }
2104
+ }
2105
+ ],
2106
+ "edges": [
2107
+ {
2108
+ "source": "u",
2109
+ "target": "r",
2110
+ "targetHandle": "in"
2111
+ },
2112
+ {
2113
+ "source": "r",
2114
+ "target": "t",
2115
+ "targetHandle": "in"
2116
+ }
2117
+ ],
2118
+ "expectedUnits": {
2119
+ "whole": 4,
2120
+ "alone": 4
2121
+ }
2122
+ },
2123
+ {
2124
+ "name": "24. Loop with the older `loops: 5` and no `repeatCount` (an older or API-written graph), on a 10 s upload: every run reads 5 copies, so 50 s, 10 units",
2125
+ "step": "loop",
2126
+ "stepData": {
2127
+ "mode": "repeat",
2128
+ "loops": 5
2129
+ },
2130
+ "nodes": [
2131
+ {
2132
+ "id": "u",
2133
+ "type": "upload-video",
2134
+ "data": {
2135
+ "url": "https://cdn.example/up10.mp4",
2136
+ "generatedResults": [
2137
+ {
2138
+ "url": "https://cdn.example/up10.mp4",
2139
+ "duration": 10
2140
+ }
2141
+ ],
2142
+ "activeResultIndex": 0
2143
+ }
2144
+ }
2145
+ ],
2146
+ "edges": [
2147
+ {
2148
+ "source": "u",
2149
+ "target": "t",
2150
+ "targetHandle": "in"
2151
+ }
2152
+ ],
2153
+ "expectedUnits": {
2154
+ "whole": 10,
2155
+ "alone": 10
2156
+ }
2157
+ },
2158
+ {
2159
+ "name": "25. Loop ×2 after a LOSSLESS Trim of 0–60 s of an upload whose length is not known: never the 8-second stand-in, the end of the cut plus the copy's overshoot, 60.6 s",
2160
+ "step": "loop",
2161
+ "stepData": {
2162
+ "mode": "repeat",
2163
+ "repeatCount": 2
2164
+ },
2165
+ "nodes": [
2166
+ {
2167
+ "id": "u",
2168
+ "type": "upload-video",
2169
+ "data": {
2170
+ "url": "https://cdn.example/nolen.mp4"
2171
+ }
2172
+ },
2173
+ {
2174
+ "id": "r",
2175
+ "type": "trim-video",
2176
+ "data": {
2177
+ "trimMode": "time",
2178
+ "startTime": 0,
2179
+ "endTime": 60,
2180
+ "losslessKeyframe": true
2181
+ }
2182
+ }
2183
+ ],
2184
+ "edges": [
2185
+ {
2186
+ "source": "u",
2187
+ "target": "r",
2188
+ "targetHandle": "in"
2189
+ },
2190
+ {
2191
+ "source": "r",
2192
+ "target": "t",
2193
+ "targetHandle": "in"
2194
+ }
2195
+ ],
2196
+ "expectedUnits": {
2197
+ "whole": 25,
2198
+ "alone": 25
2199
+ }
2200
+ },
2201
+ {
2202
+ "name": "25b. Loop ×2 after a LOSSLESS Trim keeping the first 7 s of a 20 s upload: 7.6 s",
2203
+ "step": "loop",
2204
+ "stepData": {
2205
+ "mode": "repeat",
2206
+ "repeatCount": 2
2207
+ },
2208
+ "nodes": [
2209
+ {
2210
+ "id": "u",
2211
+ "type": "upload-video",
2212
+ "data": {
2213
+ "url": "https://cdn.example/up20.mp4",
2214
+ "generatedResults": [
2215
+ {
2216
+ "url": "https://cdn.example/up20.mp4",
2217
+ "duration": 20
2218
+ }
2219
+ ],
2220
+ "activeResultIndex": 0
2221
+ }
2222
+ },
2223
+ {
2224
+ "id": "r",
2225
+ "type": "trim-video",
2226
+ "data": {
2227
+ "trimMode": "keep-first-seconds",
2228
+ "keepFirstSeconds": 7,
2229
+ "losslessKeyframe": true
2230
+ }
2231
+ }
2232
+ ],
2233
+ "edges": [
2234
+ {
2235
+ "source": "u",
2236
+ "target": "r",
2237
+ "targetHandle": "in"
2238
+ },
2239
+ {
2240
+ "source": "r",
2241
+ "target": "t",
2242
+ "targetHandle": "in"
2243
+ }
2244
+ ],
2245
+ "expectedUnits": {
2246
+ "whole": 3,
2247
+ "alone": 3
2248
+ }
2249
+ },
2250
+ {
2251
+ "name": "25c. Loop ×2 after a LOSSLESS Trim of 0–30 s of a 600 s upload: the end of the cut, 30.6 s, never the 600 s input",
2252
+ "step": "loop",
2253
+ "stepData": {
2254
+ "mode": "repeat",
2255
+ "repeatCount": 2
2256
+ },
2257
+ "nodes": [
2258
+ {
2259
+ "id": "u",
2260
+ "type": "upload-video",
2261
+ "data": {
2262
+ "url": "https://cdn.example/up600.mp4",
2263
+ "generatedResults": [
2264
+ {
2265
+ "url": "https://cdn.example/up600.mp4",
2266
+ "duration": 600
2267
+ }
2268
+ ],
2269
+ "activeResultIndex": 0
2270
+ }
2271
+ },
2272
+ {
2273
+ "id": "r",
2274
+ "type": "trim-video",
2275
+ "data": {
2276
+ "trimMode": "time",
2277
+ "startTime": 0,
2278
+ "endTime": 30,
2279
+ "losslessKeyframe": true
2280
+ }
2281
+ }
2282
+ ],
2283
+ "edges": [
2284
+ {
2285
+ "source": "u",
2286
+ "target": "r",
2287
+ "targetHandle": "in"
2288
+ },
2289
+ {
2290
+ "source": "r",
2291
+ "target": "t",
2292
+ "targetHandle": "in"
2293
+ }
2294
+ ],
2295
+ "expectedUnits": {
2296
+ "whole": 13,
2297
+ "alone": 13
2298
+ }
2299
+ },
2300
+ {
2301
+ "name": "26. Loop ×2 after a LOSSLESS Trim keeping the last 30 s of an upload whose length is not known: 30 s, a minimum (the snap to an earlier keyframe can only add), as with Lossless off: 12 units",
2302
+ "step": "loop",
2303
+ "stepData": {
2304
+ "mode": "repeat",
2305
+ "repeatCount": 2
2306
+ },
2307
+ "nodes": [
2308
+ {
2309
+ "id": "u",
2310
+ "type": "upload-video",
2311
+ "data": {
2312
+ "url": "https://cdn.example/nolen.mp4"
2313
+ }
2314
+ },
2315
+ {
2316
+ "id": "r",
2317
+ "type": "trim-video",
2318
+ "data": {
2319
+ "trimMode": "keep-last-seconds",
2320
+ "keepLastSeconds": 30,
2321
+ "losslessKeyframe": true
2322
+ }
2323
+ }
2324
+ ],
2325
+ "edges": [
2326
+ {
2327
+ "source": "u",
2328
+ "target": "r",
2329
+ "targetHandle": "in"
2330
+ },
2331
+ {
2332
+ "source": "r",
2333
+ "target": "t",
2334
+ "targetHandle": "in"
2335
+ }
2336
+ ],
2337
+ "expectedUnits": {
2338
+ "whole": 12,
2339
+ "alone": 12
2340
+ }
2341
+ }
2342
+ ]
2343
+ }