vidspotai-shared 1.0.100 → 1.0.101

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 (169) hide show
  1. package/lib/globals/aiModels/enums.d.ts +1 -0
  2. package/lib/globals/aiModels/enums.d.ts.map +1 -1
  3. package/lib/globals/aiModels/enums.js +3 -0
  4. package/lib/globals/aiModels/extendCapability.d.ts +26 -0
  5. package/lib/globals/aiModels/extendCapability.d.ts.map +1 -0
  6. package/lib/globals/aiModels/extendCapability.js +42 -0
  7. package/lib/globals/aiModels/index.d.ts +1 -0
  8. package/lib/globals/aiModels/index.d.ts.map +1 -1
  9. package/lib/globals/aiModels/index.js +1 -0
  10. package/lib/globals/aiModels/providers/hostedAvatars.js +10 -10
  11. package/lib/globals/types.d.ts +34 -2
  12. package/lib/globals/types.d.ts.map +1 -1
  13. package/lib/globals/types.js +37 -0
  14. package/lib/models/demoVideoProject.model.d.ts +213 -0
  15. package/lib/models/demoVideoProject.model.d.ts.map +1 -1
  16. package/lib/models/index.d.ts +2 -0
  17. package/lib/models/index.d.ts.map +1 -1
  18. package/lib/models/index.js +2 -0
  19. package/lib/models/mediaUpload.model.d.ts +25 -0
  20. package/lib/models/mediaUpload.model.d.ts.map +1 -1
  21. package/lib/models/productConnection.model.d.ts +57 -0
  22. package/lib/models/productConnection.model.d.ts.map +1 -0
  23. package/lib/models/productConnection.model.js +7 -0
  24. package/lib/models/video.model.d.ts +11 -0
  25. package/lib/models/video.model.d.ts.map +1 -1
  26. package/lib/models/videoQaJob.model.d.ts +61 -0
  27. package/lib/models/videoQaJob.model.d.ts.map +1 -0
  28. package/lib/models/videoQaJob.model.js +16 -0
  29. package/lib/schemas/brandKit.schema.d.ts +3 -1
  30. package/lib/schemas/brandKit.schema.d.ts.map +1 -1
  31. package/lib/schemas/brandKit.schema.js +9 -0
  32. package/lib/schemas/brief.schema.d.ts +5 -4
  33. package/lib/schemas/brief.schema.d.ts.map +1 -1
  34. package/lib/schemas/brief.schema.js +23 -1
  35. package/lib/schemas/demoQuestion.schema.d.ts +24 -4
  36. package/lib/schemas/demoQuestion.schema.d.ts.map +1 -1
  37. package/lib/schemas/demoQuestion.schema.js +8 -2
  38. package/lib/schemas/demoSpec.schema.d.ts +40 -6
  39. package/lib/schemas/demoSpec.schema.d.ts.map +1 -1
  40. package/lib/schemas/demoSpec.schema.js +46 -1
  41. package/lib/schemas/project.schema.d.ts +33 -3
  42. package/lib/schemas/project.schema.d.ts.map +1 -1
  43. package/lib/schemas/project.schema.js +22 -0
  44. package/lib/schemas/social.schema.d.ts +1 -1
  45. package/lib/schemas/videoPlan.schema.d.ts +22 -20
  46. package/lib/schemas/videoPlan.schema.d.ts.map +1 -1
  47. package/lib/schemas/videoPlan.schema.js +19 -0
  48. package/lib/services/agent/editClassifier.d.ts +10 -10
  49. package/lib/services/agent/eval/types.d.ts +3 -2
  50. package/lib/services/agent/eval/types.d.ts.map +1 -1
  51. package/lib/services/agent/executor/core.d.ts.map +1 -1
  52. package/lib/services/agent/executor/core.js +11 -0
  53. package/lib/services/agent/planner/Planner.d.ts.map +1 -1
  54. package/lib/services/agent/planner/Planner.js +5 -0
  55. package/lib/services/agent/planner/overlayRegen.d.ts.map +1 -1
  56. package/lib/services/agent/planner/overlayRegen.js +5 -0
  57. package/lib/services/agent/planner/plannerMessages.d.ts.map +1 -1
  58. package/lib/services/agent/planner/plannerMessages.js +10 -1
  59. package/lib/services/agent/planner/scriptFirstPlanner.d.ts.map +1 -1
  60. package/lib/services/agent/planner/scriptFirstPlanner.js +2 -0
  61. package/lib/services/agent/regenCore.d.ts.map +1 -1
  62. package/lib/services/agent/regenCore.js +11 -1
  63. package/lib/services/agent/runHelpers.d.ts +8 -0
  64. package/lib/services/agent/runHelpers.d.ts.map +1 -1
  65. package/lib/services/agent/runHelpers.js +5 -1
  66. package/lib/services/agent/tools/chapterOutline.tool.d.ts +8 -0
  67. package/lib/services/agent/tools/chapterOutline.tool.d.ts.map +1 -1
  68. package/lib/services/agent/tools/chapterOutline.tool.js +21 -8
  69. package/lib/services/agent/tools/composeScene.tool.d.ts +32 -2
  70. package/lib/services/agent/tools/composeScene.tool.d.ts.map +1 -1
  71. package/lib/services/agent/tools/estimateCost.tool.d.ts +11 -1
  72. package/lib/services/agent/tools/estimateCost.tool.d.ts.map +1 -1
  73. package/lib/services/agent/tools/extendVideo.tool.d.ts +9 -3
  74. package/lib/services/agent/tools/extendVideo.tool.d.ts.map +1 -1
  75. package/lib/services/agent/tools/extendVideo.tool.js +12 -27
  76. package/lib/services/agent/tools/generateAvatarVideo.tool.d.ts +1 -1
  77. package/lib/services/agent/tools/generateScript.tool.d.ts +3 -2
  78. package/lib/services/agent/tools/generateScript.tool.d.ts.map +1 -1
  79. package/lib/services/agent/tools/generateScript.tool.js +16 -7
  80. package/lib/services/agent/tools/generateVoiceover.tool.d.ts +1 -1
  81. package/lib/services/agent/tools/planVideo.tool.d.ts +11 -8
  82. package/lib/services/agent/tools/planVideo.tool.d.ts.map +1 -1
  83. package/lib/services/agent/tools/render.tool.d.ts +11 -1
  84. package/lib/services/agent/tools/render.tool.d.ts.map +1 -1
  85. package/lib/services/agent/tools/searchStock.tool.d.ts +1 -1
  86. package/lib/services/agent/tools/searchUserLibrary.tool.d.ts +4 -4
  87. package/lib/services/aiGen/providers/kling/kling.service.d.ts.map +1 -1
  88. package/lib/services/aiGen/providers/kling/kling.service.js +22 -3
  89. package/lib/services/aiGen/providers/kling/klingStatus.d.ts +7 -0
  90. package/lib/services/aiGen/providers/kling/klingStatus.d.ts.map +1 -1
  91. package/lib/services/aiGen/providers/kling/klingStatus.js +41 -4
  92. package/lib/services/aiGen/providers/pixverse/pixverse.service.d.ts.map +1 -1
  93. package/lib/services/aiGen/providers/pixverse/pixverse.service.js +25 -0
  94. package/lib/services/aiGen/providers/types.d.ts +20 -0
  95. package/lib/services/aiGen/providers/types.d.ts.map +1 -1
  96. package/lib/services/avatarGen/avatarProviderFactory.d.ts.map +1 -1
  97. package/lib/services/avatarGen/avatarProviderFactory.js +3 -0
  98. package/lib/services/avatarGen/index.d.ts +1 -0
  99. package/lib/services/avatarGen/index.d.ts.map +1 -1
  100. package/lib/services/avatarGen/index.js +1 -0
  101. package/lib/services/avatarGen/providers/synthesiaAvatarProvider.d.ts +53 -0
  102. package/lib/services/avatarGen/providers/synthesiaAvatarProvider.d.ts.map +1 -0
  103. package/lib/services/avatarGen/providers/synthesiaAvatarProvider.js +176 -0
  104. package/lib/services/demo/demoAuthor.d.ts +7 -0
  105. package/lib/services/demo/demoAuthor.d.ts.map +1 -1
  106. package/lib/services/demo/demoAuthor.js +2 -0
  107. package/lib/services/demo/demoAuthorPrompt.d.ts +6 -0
  108. package/lib/services/demo/demoAuthorPrompt.d.ts.map +1 -1
  109. package/lib/services/demo/demoAuthorPrompt.js +24 -2
  110. package/lib/services/demo/demoCaptions.d.ts +69 -0
  111. package/lib/services/demo/demoCaptions.d.ts.map +1 -0
  112. package/lib/services/demo/demoCaptions.js +152 -0
  113. package/lib/services/demo/demoMusic.d.ts +8 -1
  114. package/lib/services/demo/demoMusic.d.ts.map +1 -1
  115. package/lib/services/demo/demoMusic.js +32 -16
  116. package/lib/services/demo/demoScriptPrompt.d.ts +2 -1
  117. package/lib/services/demo/demoScriptPrompt.d.ts.map +1 -1
  118. package/lib/services/demo/demoScriptPrompt.js +29 -2
  119. package/lib/services/demo/demoStockAssets.d.ts +29 -0
  120. package/lib/services/demo/demoStockAssets.d.ts.map +1 -0
  121. package/lib/services/demo/demoStockAssets.js +107 -0
  122. package/lib/services/demo/index.d.ts +3 -0
  123. package/lib/services/demo/index.d.ts.map +1 -1
  124. package/lib/services/demo/index.js +3 -0
  125. package/lib/services/demo/productConnection.service.d.ts +78 -0
  126. package/lib/services/demo/productConnection.service.d.ts.map +1 -0
  127. package/lib/services/demo/productConnection.service.js +125 -0
  128. package/lib/services/editor/planToProject.d.ts.map +1 -1
  129. package/lib/services/editor/planToProject.helpers.d.ts +1 -0
  130. package/lib/services/editor/planToProject.helpers.d.ts.map +1 -1
  131. package/lib/services/editor/planToProject.helpers.js +3 -0
  132. package/lib/services/editor/planToProject.js +39 -0
  133. package/lib/services/editor/projectToDesign.js +13 -1
  134. package/lib/services/firestore.service.d.ts +14 -0
  135. package/lib/services/firestore.service.d.ts.map +1 -1
  136. package/lib/services/firestore.service.js +16 -0
  137. package/lib/services/translation/index.d.ts +1 -0
  138. package/lib/services/translation/index.d.ts.map +1 -1
  139. package/lib/services/translation/index.js +8 -1
  140. package/lib/services/translation/outputLanguage.d.ts +75 -0
  141. package/lib/services/translation/outputLanguage.d.ts.map +1 -0
  142. package/lib/services/translation/outputLanguage.js +190 -0
  143. package/lib/services/translation/translation.service.d.ts +13 -2
  144. package/lib/services/translation/translation.service.d.ts.map +1 -1
  145. package/lib/services/translation/translation.service.js +66 -5
  146. package/lib/services/tts/index.d.ts +1 -0
  147. package/lib/services/tts/index.d.ts.map +1 -1
  148. package/lib/services/tts/index.js +1 -0
  149. package/lib/services/tts/providers/elevenlabs.service.d.ts +7 -0
  150. package/lib/services/tts/providers/elevenlabs.service.d.ts.map +1 -1
  151. package/lib/services/tts/providers/elevenlabs.service.js +69 -13
  152. package/lib/services/tts/types.d.ts +29 -0
  153. package/lib/services/tts/types.d.ts.map +1 -1
  154. package/lib/services/tts/wordTimings.d.ts +27 -0
  155. package/lib/services/tts/wordTimings.d.ts.map +1 -0
  156. package/lib/services/tts/wordTimings.js +57 -0
  157. package/lib/utils/billableDuration.d.ts +11 -0
  158. package/lib/utils/billableDuration.d.ts.map +1 -0
  159. package/lib/utils/billableDuration.js +91 -0
  160. package/lib/utils/index.d.ts +3 -0
  161. package/lib/utils/index.d.ts.map +1 -1
  162. package/lib/utils/index.js +3 -0
  163. package/lib/utils/mp4Duration.d.ts +38 -0
  164. package/lib/utils/mp4Duration.d.ts.map +1 -0
  165. package/lib/utils/mp4Duration.js +164 -0
  166. package/lib/utils/socialEntitlements.d.ts +51 -0
  167. package/lib/utils/socialEntitlements.d.ts.map +1 -0
  168. package/lib/utils/socialEntitlements.js +65 -0
  169. package/package.json +1 -1
@@ -40,8 +40,8 @@ export declare const TextEditSchema: z.ZodObject<{
40
40
  overlaysByScene: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
41
41
  text: z.ZodString;
42
42
  role: z.ZodEnum<{
43
- body: "body";
44
43
  watermark: "watermark";
44
+ body: "body";
45
45
  cta: "cta";
46
46
  headline: "headline";
47
47
  subheadline: "subheadline";
@@ -49,8 +49,8 @@ export declare const TextEditSchema: z.ZodObject<{
49
49
  label: "label";
50
50
  }>;
51
51
  position: z.ZodOptional<z.ZodEnum<{
52
- center: "center";
53
52
  top: "top";
53
+ center: "center";
54
54
  "top-left": "top-left";
55
55
  "top-right": "top-right";
56
56
  "top-banner": "top-banner";
@@ -69,10 +69,10 @@ export declare const TextEditSchema: z.ZodObject<{
69
69
  fontSize: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"auto">, z.ZodNumber]>>;
70
70
  sizePct: z.ZodOptional<z.ZodNumber>;
71
71
  weight: z.ZodOptional<z.ZodEnum<{
72
- regular: "regular";
73
72
  bold: "bold";
74
- black: "black";
75
73
  medium: "medium";
74
+ regular: "regular";
75
+ black: "black";
76
76
  }>>;
77
77
  color: z.ZodOptional<z.ZodString>;
78
78
  bgColor: z.ZodOptional<z.ZodString>;
@@ -84,8 +84,8 @@ export declare const TextEditSchema: z.ZodObject<{
84
84
  outline: "outline";
85
85
  }>>;
86
86
  animation: z.ZodOptional<z.ZodEnum<{
87
- type: "type";
88
87
  pop: "pop";
88
+ type: "type";
89
89
  none: "none";
90
90
  fade: "fade";
91
91
  "slide-up": "slide-up";
@@ -143,8 +143,8 @@ export declare const EditRequestSchema: z.ZodObject<{
143
143
  overlaysByScene: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
144
144
  text: z.ZodString;
145
145
  role: z.ZodEnum<{
146
- body: "body";
147
146
  watermark: "watermark";
147
+ body: "body";
148
148
  cta: "cta";
149
149
  headline: "headline";
150
150
  subheadline: "subheadline";
@@ -152,8 +152,8 @@ export declare const EditRequestSchema: z.ZodObject<{
152
152
  label: "label";
153
153
  }>;
154
154
  position: z.ZodOptional<z.ZodEnum<{
155
- center: "center";
156
155
  top: "top";
156
+ center: "center";
157
157
  "top-left": "top-left";
158
158
  "top-right": "top-right";
159
159
  "top-banner": "top-banner";
@@ -172,10 +172,10 @@ export declare const EditRequestSchema: z.ZodObject<{
172
172
  fontSize: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"auto">, z.ZodNumber]>>;
173
173
  sizePct: z.ZodOptional<z.ZodNumber>;
174
174
  weight: z.ZodOptional<z.ZodEnum<{
175
- regular: "regular";
176
175
  bold: "bold";
177
- black: "black";
178
176
  medium: "medium";
177
+ regular: "regular";
178
+ black: "black";
179
179
  }>>;
180
180
  color: z.ZodOptional<z.ZodString>;
181
181
  bgColor: z.ZodOptional<z.ZodString>;
@@ -187,8 +187,8 @@ export declare const EditRequestSchema: z.ZodObject<{
187
187
  outline: "outline";
188
188
  }>>;
189
189
  animation: z.ZodOptional<z.ZodEnum<{
190
- type: "type";
191
190
  pop: "pop";
191
+ type: "type";
192
192
  none: "none";
193
193
  fade: "fade";
194
194
  "slide-up": "slide-up";
@@ -63,8 +63,8 @@ export declare const EvalBriefSchema: z.ZodObject<{
63
63
  "voiceover-only": "voiceover-only";
64
64
  }>>;
65
65
  pacing: z.ZodOptional<z.ZodEnum<{
66
- medium: "medium";
67
66
  fast: "fast";
67
+ medium: "medium";
68
68
  slow: "slow";
69
69
  "very-fast": "very-fast";
70
70
  }>>;
@@ -83,6 +83,7 @@ export declare const EvalBriefSchema: z.ZodObject<{
83
83
  L2: "L2";
84
84
  L3: "L3";
85
85
  }>>;
86
+ outputLanguage: z.ZodOptional<z.ZodString>;
86
87
  voice: z.ZodOptional<z.ZodObject<{
87
88
  gender: z.ZodOptional<z.ZodEnum<{
88
89
  male: "male";
@@ -97,7 +98,7 @@ export declare const EvalBriefSchema: z.ZodObject<{
97
98
  senior: "senior";
98
99
  }>>;
99
100
  accent: z.ZodOptional<z.ZodString>;
100
- language: z.ZodDefault<z.ZodString>;
101
+ language: z.ZodOptional<z.ZodString>;
101
102
  voiceId: z.ZodOptional<z.ZodString>;
102
103
  style: z.ZodOptional<z.ZodEnum<{
103
104
  energetic: "energetic";
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/eval/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB;;;;;;;;;;GAUG;AAEH,4CAA4C;AAC5C,eAAO,MAAM,gBAAgB;;;;;;;iBAQ3B,CAAC;AACH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAM1B,CAAC;AACH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAExD,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;iBAY9B,CAAC;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,+DAA+D;AAC/D,eAAO,MAAM,iBAAiB;;;;iBAI5B,CAAC;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAE5D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAW9B,CAAC;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OA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ourceRoot":"","sources":["../../../../src/services/agent/executor/core.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,SAAS,EAAE,MAAM,mCAAmC,CAAC;AAE5E,OAAO,EAA6B,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAezE,OAAO,EAAE,eAAe,EAAa,YAAY,EAAE,MAAM,SAAS,CAAC;AAInE;;;;;;;;;;;GAWG;AACH,qBAAa,QAAQ;IACnB,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAS;IACrC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAY;IACpC,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAqC;IACtE,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAoB;IAC/C,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAgC;IAC5D,OAAO,CAAC,QAAQ,CAAC,kBAAkB,CAAC,CAAsB;IAC1D,OAAO,CAAC,QAAQ,CAAC,qBAAqB,CAAC,CAAsB;IAC7D,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAkC;IAEhE;;;;;;;;;;;;;OAaG;IACH,OAAO,CAAC,cAAc,CAAC,CAGrB;gBAEU,IAAI,GAAE,eAAoB;IAiBtC;;;OAGG;YACW,eAAe;IAY7B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IAI5B;;;;;OAKG;YACW,0BAA0B;IAiBxC;;;;OAIG;IACH,OAAO,CAAC,cAAc;IAmBtB;;;OAGG;YACW,aAAa;IAe3B,iEAAiE;IACjE,OAAO,CAAC,UAAU;IAcZ,GAAG,CAAC,IAAI,EAAE,SAAS,EAAE,GAAG,EAAE,WAAW,GAAG,OAAO,CAAC,YAAY,EAAE,CAAC;YA4EvD,QAAQ;CAyHvB"}
@@ -7,6 +7,7 @@ const ttsDuration_1 = require("../ttsDuration");
7
7
  const providerTaskCache_1 = require("../providerTaskCache");
8
8
  const voice_1 = require("./voice");
9
9
  const visual_1 = require("./visual");
10
+ const outputLanguage_1 = require("../../translation/outputLanguage");
10
11
  const repair_1 = require("../repair");
11
12
  /**
12
13
  * Executor — turns an approved VideoPlan into per-scene asset results.
@@ -265,6 +266,16 @@ class Executor {
265
266
  const sanitized = (0, voice_1.sanitizeVoiceId)(plan.voiceId);
266
267
  if (sanitized)
267
268
  voInput.voiceId = sanitized;
269
+ // Tell ElevenLabs which language the line is in rather than letting it
270
+ // auto-detect. Auto-detect is decent on a full paragraph but unreliable
271
+ // on the 4-9 word lines a short scene carries, where a Spanish line can
272
+ // get read with an English phoneme set. Omitted for English so the
273
+ // default path is byte-identical to before; the provider also retries
274
+ // without the code if it rejects an unsupported one
275
+ // (elevenlabs.service.ts:107-120).
276
+ if (!(0, outputLanguage_1.isEnglish)(plan.outputLanguage)) {
277
+ voInput.languageCode = plan.outputLanguage;
278
+ }
268
279
  const voOutcome = await this.runTool("generate_voiceover", voInput, { ...sceneCtx, idempotencyKey: `${idempotencyKey}:vo` });
269
280
  if (voOutcome.ok) {
270
281
  voiceoverAudioBase64 = voOutcome.output.audioBase64;
@@ -1 +1 @@
1
- {"version":3,"file":"Planner.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/Planner.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAoB,MAAM,+BAA+B,CAAC;AAC7E,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,WAAW,EACX,SAAS,EAEV,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAChF,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAGzC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAkB7C;;;;;;;;;;;GAWG;AAEH,MAAM,WAAW,cAAc;IAC7B,GAAG,EAAE,SAAS,CAAC;IACf,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,UAAU,CAAC,EAA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AU,EACjB,IAAI,GAAE;QACJ,OAAO,CAAC,EAAE,YAAY,CAAC;QACvB,QAAQ,CAAC,EAAE,cAAc,GAAG,IAAI,CAAC;QACjC,WAAW,CAAC,EAAE,iBAAiB,GAAG,IAAI,CAAC;QACvC,KAAK,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAC;KAC5B,GACL;QAAE,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;QAAC,MAAM,EAAE,OAAO,CAAC,SAAS,CAAC,CAAA;KAAE;IAqEhE;;;;;;;;;;;;;;;;OAgBG;IACG,0BAA0B,CAC9B,KAAK,EAAE,YAAY,EACnB,KAAK,EAAE,UAAU,EACjB,IAAI,GAAE;QACJ,OAAO,CAAC,EAAE,YAAY,CAAC;QACvB,QAAQ,CAAC,EAAE,cAAc,GAAG,IAAI,CAAC;QACjC,KAAK,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAC;QAChC,cAAc,CAAC,EAAE,OAAO,CAAC;QACzB,0EAA0E;QAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;KACjB,GACL,OAAO,CAAC,WAAW,EAAE,CAAC;CAQ1B"}
@@ -244,6 +244,11 @@ class Planner {
244
244
  // "female-young-adult-excited". That triggers the executor's strip-and-
245
245
  // warn on every regen of the same trace, so kill it here once.
246
246
  reparsed.data.voiceId = brief.voice?.voiceId;
247
+ // Output language flows brief → plan deterministically, same as
248
+ // voiceId/voiceStyle. The executor reads it off the plan to set the
249
+ // TTS language and the caption ASR hint, so it must survive even when
250
+ // the LLM omits it (it's marked ORCHESTRATOR-ONLY in the schema).
251
+ reparsed.data.outputLanguage = brief.outputLanguage;
247
252
  // Soft-validation pass: vo-clip (if we downgraded after maxRetries)
248
253
  // + trailing-silence. These ship with the plan; the UI surfaces them.
249
254
  reparsed.data.warnings = (0, validators_1.collectPlanWarnings)(reparsed.data);
@@ -1 +1 @@
1
- {"version":3,"file":"overlayRegen.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/overlayRegen.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAC3D,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,WAAW,EAGZ,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAK7C,4EAA4E;AAC5E,MAAM,WAAW,gBAAgB;IAC/B,GAAG,EAAE,SAAS,CAAC;IACf,MAAM,EAAE,WAAW,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,gBAAgB,EACtB,KAAK,EAAE,YAAY,EACnB,KAAK,EAAE,UAAU,EACjB,IAAI,GAAE;IACJ,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,QAAQ,CAAC,EAAE,cAAc,GAAG,IAAI,CAAC;IACjC,KAAK,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAChC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;CACjB,GACL,OAAO,CAAC,WAAW,EAAE,CAAC,CAwIxB"}
1
+ {"version":3,"file":"overlayRegen.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/overlayRegen.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAC3D,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,WAAW,EAGZ,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAM7C,4EAA4E;AAC5E,MAAM,WAAW,gBAAgB;IAC/B,GAAG,EAAE,SAAS,CAAC;IACf,MAAM,EAAE,WAAW,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,gBAAgB,EACtB,KAAK,EAAE,YAAY,EACnB,KAAK,EAAE,UAAU,EACjB,IAAI,GAAE;IACJ,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,QAAQ,CAAC,EAAE,cAAc,GAAG,IAAI,CAAC;IACjC,KAAK,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAChC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;CACjB,GACL,OAAO,CAAC,WAAW,EAAE,CAAC,CA4IxB"}
@@ -6,6 +6,7 @@ const videoPlan_schema_1 = require("../../../schemas/videoPlan.schema");
6
6
  const personas_1 = require("../personas");
7
7
  const promptSections_1 = require("./promptSections");
8
8
  const overlaySanity_1 = require("./overlaySanity");
9
+ const outputLanguage_1 = require("../../translation/outputLanguage");
9
10
  /**
10
11
  * Stage 6 slice 4 — focused overlay regeneration for a single scene. The
11
12
  * full `plan()` path is too expensive (and too lossy) for "I just want
@@ -71,6 +72,10 @@ async function regenerateOverlaysForScene(deps, scene, brief, opts = {}) {
71
72
  personaLine,
72
73
  brandKitSection,
73
74
  bibleSection,
75
+ // Overlays are burned-in viewer-facing copy, and this path regenerates
76
+ // them independently of the planner — without its own rule a non-English
77
+ // plan would sprout English overlays on the first overlay re-roll.
78
+ (0, outputLanguage_1.buildOutputLanguageSection)(brief.outputLanguage, "every overlays[].text"),
74
79
  ]
75
80
  .filter(Boolean)
76
81
  .join("\n");
@@ -1 +1 @@
1
- {"version":3,"file":"plannerMessages.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/plannerMessages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAchF;;;;;GAKG;AAEH,wBAAgB,oBAAoB,CAClC,KAAK,EAAE,UAAU,EACjB,OAAO,EAAE,YAAY,GAAG,SAAS,EACjC,QAAQ,EAAE,cAAc,GAAG,IAAI,EAC/B,WAAW,EAAE,iBAAiB,GAAG,IAAI,EACrC,KAAK,EAAE,gBAAgB,GAAG,IAAI,EAC9B,UAAU,CAAC,EAAE,MAAM,EACnB,eAAe,UAAQ;;;;;;KA0IxB;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAiChE"}
1
+ {"version":3,"file":"plannerMessages.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/plannerMessages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAehF;;;;;GAKG;AAEH,wBAAgB,oBAAoB,CAClC,KAAK,EAAE,UAAU,EACjB,OAAO,EAAE,YAAY,GAAG,SAAS,EACjC,QAAQ,EAAE,cAAc,GAAG,IAAI,EAC/B,WAAW,EAAE,iBAAiB,GAAG,IAAI,EACrC,KAAK,EAAE,gBAAgB,GAAG,IAAI,EAC9B,UAAU,CAAC,EAAE,MAAM,EACnB,eAAe,UAAQ;;;;;;KAsJxB;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAiChE"}
@@ -4,6 +4,7 @@ exports.buildPlannerMessages = buildPlannerMessages;
4
4
  exports.briefNeedsWebResearch = briefNeedsWebResearch;
5
5
  const personas_1 = require("../personas");
6
6
  const modelQualityNotes_1 = require("../modelQualityNotes");
7
+ const outputLanguage_1 = require("../../translation/outputLanguage");
7
8
  const promptSections_1 = require("./promptSections");
8
9
  const structuralRules_1 = require("./structuralRules");
9
10
  /**
@@ -14,6 +15,11 @@ const structuralRules_1 = require("./structuralRules");
14
15
  */
15
16
  function buildPlannerMessages(brief, persona, brandKit, styleMemory, bible, lastErrors, useResearchCall = false) {
16
17
  const structuralRulesSection = (0, structuralRules_1.buildStructuralRulesSection)(brief);
18
+ // Empty string on English (the common path adds zero tokens). Placed LAST in
19
+ // the system prompt below — deliberately: this block competes with ~150
20
+ // lines of English instructions and English example titles, and recency wins
21
+ // when an instruction has to override the ambient language of the prompt.
22
+ const outputLanguageSection = (0, outputLanguage_1.buildOutputLanguageSection)(brief.outputLanguage, "every viewer-facing string (scene.voiceoverLine, scene.onScreenText, every overlays[].text, and plan.title)");
17
23
  const personaSection = persona
18
24
  ? [
19
25
  "",
@@ -125,7 +131,10 @@ function buildPlannerMessages(brief, persona, brandKit, styleMemory, bible, last
125
131
  "quotes). It should read like a video/episode title a creator would use,",
126
132
  "derived from the brief's subject and angle — NOT a restatement of the raw",
127
133
  "prompt. Examples: \"5 Morning Habits That Boost Focus\", \"Meet the New",
128
- "Aurora Smartwatch\", \"Why Your Plants Keep Dying\".",
134
+ "Aurora Smartwatch\", \"Why Your Plants Keep Dying\". (Those examples are",
135
+ "English purely to show the SHAPE — follow the output-language rule below",
136
+ "for the actual wording.)",
137
+ outputLanguageSection,
129
138
  ]
130
139
  .filter(Boolean)
131
140
  .join("\n");
@@ -1 +1 @@
1
- {"version":3,"file":"scriptFirstPlanner.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/scriptFirstPlanner.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAoB,MAAM,+BAA+B,CAAC;AAE7E,OAAO,EACL,gBAAgB,EAGhB,SAAS,EAEV,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAYzC;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,MAAM,WAAW,eAAe;IAC9B,GAAG,EAAE,SAAS,CAAC;CAChB;AAQD,wBAAsB,eAAe,CACnC,IAAI,EAAE,eAAe,EACrB,KAAK,EAAE,UAAU,EACjB,IAAI,GAAE;IAAE,OAAO,CAAC,EAAE,YAAY,CAAC;IAAC,KAAK,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAA;CAAO,GACrE,OAAO,CAAC,SAAS,CAAC,CAuIpB"}
1
+ {"version":3,"file":"scriptFirstPlanner.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/planner/scriptFirstPlanner.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAoB,MAAM,+BAA+B,CAAC;AAE7E,OAAO,EACL,gBAAgB,EAGhB,SAAS,EAEV,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAYzC;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,MAAM,WAAW,eAAe;IAC9B,GAAG,EAAE,SAAS,CAAC;CAChB;AAQD,wBAAsB,eAAe,CACnC,IAAI,EAAE,eAAe,EACrB,KAAK,EAAE,UAAU,EACjB,IAAI,GAAE;IAAE,OAAO,CAAC,EAAE,YAAY,CAAC;IAAC,KAAK,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAA;CAAO,GACrE,OAAO,CAAC,SAAS,CAAC,CAyIpB"}
@@ -33,6 +33,7 @@ async function planScriptFirst(deps, brief, opts = {}) {
33
33
  const { chapters } = await (0, chapterOutline_tool_1.chapterOutlineCore)(llm, {
34
34
  script: script.fullText,
35
35
  wpm,
36
+ outputLanguage: brief.outputLanguage,
36
37
  });
37
38
  // Pass 3 — explode each chapter into B-roll scenes, keeping sceneIndex
38
39
  // globally contiguous and back-filling chapter.sceneIndices.
@@ -117,6 +118,7 @@ async function planScriptFirst(deps, brief, opts = {}) {
117
118
  // as the scene-first path; the LLM never authors them here.
118
119
  voiceId: brief.voice?.voiceId,
119
120
  voiceStyle: brief.voice?.style,
121
+ outputLanguage: brief.outputLanguage,
120
122
  warnings: [],
121
123
  ...(opts.bible ? { bible: opts.bible } : {}),
122
124
  };
@@ -1 +1 @@
1
- {"version":3,"file":"regenCore.d.ts","sourceRoot":"","sources":["../../../src/services/agent/regenCore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAGH,OAAO,EAAQ,OAAO,EAAE,MAAM,8BAA8B,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAC3D,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAW9D,OAAO,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAE7D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAC9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAI5D,MAAM,WAAW,gBAAgB;IAC/B,oFAAoF;IACpF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,6FAA6F;IAC7F,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,uEAAuE;IACvE,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,gBAAgB;IAC/B,EAAE,EAAE,IAAI,CAAC;IACT,QAAQ,C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AAoB,CAAC;AAI5D,MAAM,WAAW,gBAAgB;IAC/B,oFAAoF;IACpF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,6FAA6F;IAC7F,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,uEAAuE;IACvE,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,gBAAgB;IAC/B,EAAE,EAAE,IAAI,CAAC;IACT,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,eAAe,EAAE,OAAO,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,OAAO,EAAE,CAAC;IACrB,IAAI,EAAE,iBAAiB,CAAC;IACxB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAClC;AAED,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,KAAK,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,4DAA4D;IAC5D,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,eAAe,GAAG,gBAAgB,GAAG,cAAc,CAAC;AAEhE,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,6FAA6F;IAC7F,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,sBAAsB,CAAC,CAAC;CACpD;AAED;;;;;GAKG;AACH,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,WAAW,EACnB,OAAO,EAAE,kBAAkB,EAC3B,GAAG,EAAE,gBAAgB,EACrB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,eAAe,CAAC,CA+d1B"}
@@ -19,6 +19,7 @@ exports.executeRegenTarget = executeRegenTarget;
19
19
  const node_crypto_1 = require("node:crypto");
20
20
  const modelRouter_1 = require("./modelRouter");
21
21
  const executor_1 = require("./executor");
22
+ const outputLanguage_1 = require("../translation/outputLanguage");
22
23
  const taskPoller_1 = require("./taskPoller");
23
24
  const planner_1 = require("./planner");
24
25
  const llmCallerRegistry_1 = require("./llmCallerRegistry");
@@ -187,6 +188,11 @@ async function executeRegenTarget(target, project, ctx, options = {}) {
187
188
  const voInput = { text: newLine };
188
189
  if (plan.voiceId)
189
190
  voInput.voiceId = plan.voiceId;
191
+ // Match the executor: a single-scene VO re-roll must speak the same
192
+ // language as the rest of the timeline, not re-auto-detect off one line.
193
+ if (!(0, outputLanguage_1.isEnglish)(plan.outputLanguage)) {
194
+ voInput.languageCode = plan.outputLanguage;
195
+ }
190
196
  const voOutcome = await (0, recorder_1.runToolRecorded)("generate_voiceover", voInput, {
191
197
  userId: ctx.userId,
192
198
  agentRunId: runId,
@@ -276,7 +282,11 @@ async function executeRegenTarget(target, project, ctx, options = {}) {
276
282
  };
277
283
  }
278
284
  const { runId, trace } = startRunTrace();
279
- const asrOutcome = await (0, recorder_1.runToolRecorded)("generate_captions", { audioUrl, wordTimestamps: true }, {
285
+ const asrOutcome = await (0, recorder_1.runToolRecorded)("generate_captions", {
286
+ audioUrl,
287
+ wordTimestamps: true,
288
+ ...(plan.outputLanguage ? { languageCode: plan.outputLanguage } : {}),
289
+ }, {
280
290
  userId: ctx.userId,
281
291
  agentRunId: runId,
282
292
  idempotencyKey: `${runId}:captions:${sceneIndex}`,
@@ -39,6 +39,14 @@ export declare function resolveSceneCaptions(outcome: SceneOutcome, ctx: {
39
39
  userId: string;
40
40
  agentRunId: string;
41
41
  projectId: string;
42
+ /**
43
+ * Plan's output language. Passed to ASR as a decode hint so captions come
44
+ * back in the language the VO was actually synthesized in. Without it
45
+ * AssemblyAI autodetects per scene, which on 2-4s clips can disagree
46
+ * scene-to-scene and produce a video whose captions switch language
47
+ * mid-way. Absent → autodetect (unchanged legacy behaviour).
48
+ */
49
+ outputLanguage?: string;
42
50
  }): Promise<void>;
43
51
  /**
44
52
  * Stage 3 — write the initial Project shell after the planner approves a
@@ -1 +1 @@
1
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AClB,aAAa,CAAC,EAAE,IAAI,EAAE,EACtB,kBAAkB,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,GACvC,OAAO,CAAC,IAAI,CAAC,CAyBf"}
@@ -161,7 +161,11 @@ async function resolveSceneCaptions(outcome, ctx) {
161
161
  return; // nothing to caption
162
162
  if (result.captionWords && result.captionWords.length > 0)
163
163
  return; // idempotent
164
- const captionOutcome = await (0, toolRegistry_1.runTool)("generate_captions", { audioUrl: result.voiceoverUrl, wordTimestamps: true }, {
164
+ const captionOutcome = await (0, toolRegistry_1.runTool)("generate_captions", {
165
+ audioUrl: result.voiceoverUrl,
166
+ wordTimestamps: true,
167
+ ...(ctx.outputLanguage ? { languageCode: ctx.outputLanguage } : {}),
168
+ }, {
165
169
  userId: ctx.userId,
166
170
  agentRunId: ctx.agentRunId,
167
171
  projectId: ctx.projectId,
@@ -17,6 +17,7 @@ declare const InputSchema: z.ZodObject<{
17
17
  script: z.ZodString;
18
18
  targetChapterCount: z.ZodOptional<z.ZodNumber>;
19
19
  wpm: z.ZodOptional<z.ZodNumber>;
20
+ outputLanguage: z.ZodOptional<z.ZodString>;
20
21
  }, z.core.$strip>;
21
22
  declare const OutputSchema: z.ZodObject<{
22
23
  chapters: z.ZodArray<z.ZodObject<{
@@ -34,6 +35,13 @@ export declare function chapterOutlineCore(llm: LlmCaller, args: {
34
35
  script: string;
35
36
  targetChapterCount?: number;
36
37
  wpm?: number;
38
+ /**
39
+ * Language for the chapter TITLES. The narration is sliced verbatim from
40
+ * the script so it's already in the right language, but titles are
41
+ * authored fresh here and would otherwise come back English on top of a
42
+ * non-English script (they ship as YouTube chapter markers).
43
+ */
44
+ outputLanguage?: string;
37
45
  }): Promise<{
38
46
  chapters: Chapter[];
39
47
  }>;
@@ -1 +1 @@
1
- {"version":3,"file":"chapterOutline.tool.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/tools/chapterOutline.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MA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IACb;;;;;OAKG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB,GACA,OAAO,CAAC;IAAE,QAAQ,EAAE,OAAO,EAAE,CAAA;CAAE,CAAC,CAuDlC;AAED,eAAO,MAAM,kBAAkB,EAAE,cAAc,CAC7C,OAAO,WAAW,EAClB,OAAO,YAAY,CAoBpB,CAAC"}
@@ -8,6 +8,7 @@ const llmCallerRegistry_1 = require("../llmCallerRegistry");
8
8
  const modelRouter_1 = require("../modelRouter");
9
9
  const ttsDuration_1 = require("../ttsDuration");
10
10
  const toolRegistry_1 = require("../toolRegistry");
11
+ const outputLanguage_1 = require("../../translation/outputLanguage");
11
12
  /**
12
13
  * Stream L (L-4) — chapter_outline. Second pass of script-first authoring:
13
14
  * segments a full narration script (from generate_script, or user-supplied)
@@ -31,6 +32,10 @@ const InputSchema = zod_1.z.object({
31
32
  targetChapterCount: zod_1.z.number().int().min(1).max(30).optional(),
32
33
  /** wpm used for per-chapter duration estimates; defaults to TTS calibration. */
33
34
  wpm: zod_1.z.number().int().positive().optional(),
35
+ outputLanguage: zod_1.z
36
+ .string()
37
+ .optional()
38
+ .describe('Language for the chapter titles, e.g. "es". Omit for English. Chapter narration is verbatim from the script, so only titles are affected.'),
34
39
  });
35
40
  /** The model returns split points + titles; we stamp ids + durations. */
36
41
  const LlmOutlineSchema = zod_1.z.object({
@@ -59,14 +64,21 @@ async function chapterOutlineCore(llm, args) {
59
64
  const defaultTarget = Math.min(12, Math.max(2, Math.round(wordCount / 120)));
60
65
  const target = args.targetChapterCount ?? defaultTarget;
61
66
  const system = [
62
- "You are a video editor structuring a narration script into chapters for a",
63
- "long-form video. Split the script at NATURAL topic boundaries into coherent",
64
- "sections, each with a short, specific title. CRITICAL: each chapter's",
65
- "narration must be the EXACT verbatim text from the script — do not rewrite,",
66
- "summarize, add, or drop words. The chapters concatenated in order must",
67
- "reproduce the original script exactly. Open with a hook chapter and close",
68
- "with a payoff/CTA chapter.",
69
- ].join(" ");
67
+ [
68
+ "You are a video editor structuring a narration script into chapters for a",
69
+ "long-form video. Split the script at NATURAL topic boundaries into coherent",
70
+ "sections, each with a short, specific title. CRITICAL: each chapter's",
71
+ "narration must be the EXACT verbatim text from the script — do not rewrite,",
72
+ "summarize, add, or drop words. The chapters concatenated in order must",
73
+ "reproduce the original script exactly. Open with a hook chapter and close",
74
+ "with a payoff/CTA chapter.",
75
+ ].join(" "),
76
+ // Titles only — the verbatim-narration rule above already pins the body
77
+ // text to whatever language the script was written in.
78
+ (0, outputLanguage_1.buildOutputLanguageSection)(args.outputLanguage, "each chapter title"),
79
+ ]
80
+ .filter(Boolean)
81
+ .join("\n");
70
82
  const user = [
71
83
  `Aim for about ${target} chapters (deviate by ±1 only if the topic structure demands it).`,
72
84
  "",
@@ -110,6 +122,7 @@ exports.chapterOutlineTool = {
110
122
  script: input.script,
111
123
  targetChapterCount: input.targetChapterCount,
112
124
  wpm: input.wpm,
125
+ outputLanguage: input.outputLanguage,
113
126
  }),
114
127
  };
115
128
  (0, toolRegistry_1.registerTool)(exports.chapterOutlineTool);
@@ -29,8 +29,8 @@ declare const InputSchema: z.ZodObject<{
29
29
  tracks: z.ZodArray<z.ZodObject<{
30
30
  id: z.ZodString;
31
31
  kind: z.ZodEnum<{
32
- audio: "audio";
33
32
  video: "video";
33
+ audio: "audio";
34
34
  text: "text";
35
35
  caption: "caption";
36
36
  fx: "fx";
@@ -124,6 +124,16 @@ declare const InputSchema: z.ZodObject<{
124
124
  saturation: z.ZodDefault<z.ZodNumber>;
125
125
  warmth: z.ZodDefault<z.ZodNumber>;
126
126
  }, z.core.$strip>>;
127
+ box: z.ZodOptional<z.ZodObject<{
128
+ left: z.ZodNumber;
129
+ top: z.ZodNumber;
130
+ width: z.ZodNumber;
131
+ height: z.ZodNumber;
132
+ }, z.core.$strip>>;
133
+ fit: z.ZodOptional<z.ZodEnum<{
134
+ cover: "cover";
135
+ contain: "contain";
136
+ }>>;
127
137
  id: z.ZodString;
128
138
  trackId: z.ZodString;
129
139
  display: z.ZodObject<{
@@ -458,6 +468,16 @@ declare const InputSchema: z.ZodObject<{
458
468
  saturation: z.ZodDefault<z.ZodNumber>;
459
469
  warmth: z.ZodDefault<z.ZodNumber>;
460
470
  }, z.core.$strip>>;
471
+ box: z.ZodOptional<z.ZodObject<{
472
+ left: z.ZodNumber;
473
+ top: z.ZodNumber;
474
+ width: z.ZodNumber;
475
+ height: z.ZodNumber;
476
+ }, z.core.$strip>>;
477
+ fit: z.ZodOptional<z.ZodEnum<{
478
+ cover: "cover";
479
+ contain: "contain";
480
+ }>>;
461
481
  id: z.ZodString;
462
482
  trackId: z.ZodString;
463
483
  display: z.ZodObject<{
@@ -734,8 +754,8 @@ declare const OutputSchema: z.ZodObject<{
734
754
  tracks: z.ZodArray<z.ZodObject<{
735
755
  id: z.ZodString;
736
756
  kind: z.ZodEnum<{
737
- audio: "audio";
738
757
  video: "video";
758
+ audio: "audio";
739
759
  text: "text";
740
760
  caption: "caption";
741
761
  fx: "fx";
@@ -829,6 +849,16 @@ declare const OutputSchema: z.ZodObject<{
829
849
  saturation: z.ZodDefault<z.ZodNumber>;
830
850
  warmth: z.ZodDefault<z.ZodNumber>;
831
851
  }, z.core.$strip>>;
852
+ box: z.ZodOptional<z.ZodObject<{
853
+ left: z.ZodNumber;
854
+ top: z.ZodNumber;
855
+ width: z.ZodNumber;
856
+ height: z.ZodNumber;
857
+ }, z.core.$strip>>;
858
+ fit: z.ZodOptional<z.ZodEnum<{
859
+ cover: "cover";
860
+ contain: "contain";
861
+ }>>;
832
862
  id: z.ZodString;
833
863
  trackId: z.ZodString;
834
864
  display: z.ZodObject<{
@@ -1 +1 @@
1
- {"version":3,"file":"composeScene.tool.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/tools/composeScene.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,OAAO,EAAgB,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAiC/D,QAAA,M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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAGf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAIhB,CAAC;AAEH,eAAO,MAAM,gBAAgB,EAAE,cAAc,CAC3C,OAAO,WAAW,EAClB,OAAO,YAAY,CA4DpB,CAAC"}
@@ -29,8 +29,8 @@ declare const InputSchema: z.ZodObject<{
29
29
  tracks: z.ZodArray<z.ZodObject<{
30
30
  id: z.ZodString;
31
31
  kind: z.ZodEnum<{
32
- audio: "audio";
33
32
  video: "video";
33
+ audio: "audio";
34
34
  text: "text";
35
35
  caption: "caption";
36
36
  fx: "fx";
@@ -124,6 +124,16 @@ declare const InputSchema: z.ZodObject<{
124
124
  saturation: z.ZodDefault<z.ZodNumber>;
125
125
  warmth: z.ZodDefault<z.ZodNumber>;
126
126
  }, z.core.$strip>>;
127
+ box: z.ZodOptional<z.ZodObject<{
128
+ left: z.ZodNumber;
129
+ top: z.ZodNumber;
130
+ width: z.ZodNumber;
131
+ height: z.ZodNumber;
132
+ }, z.core.$strip>>;
133
+ fit: z.ZodOptional<z.ZodEnum<{
134
+ cover: "cover";
135
+ contain: "contain";
136
+ }>>;
127
137
  id: z.ZodString;
128
138
  trackId: z.ZodString;
129
139
  display: z.ZodObject<{
@@ -1 +1 @@
1
- {"version":3,"file":"estimateCost.tool.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/tools/estimateCost.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAgB,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAE/D,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAEf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;;;;;;;;;;iBAmBhB,CAAC;AAEH,eAAO,MAAM,gBAAgB,EAAE,cAAc,CAC3C,OAAO,WAAW,EAClB,OAAO,YAAY,CAgEpB,CAAC"}
1
+ {"version":3,"file":"estimateCost.tool.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/tools/estimateCost.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAgB,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAE/D,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAEf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;;;;;;;;;;iBAmBhB,CAAC;AAEH,eAAO,MAAM,gBAAgB,EAAE,cAAc,CAC3C,OAAO,WAAW,EAClB,OAAO,YAAY,CAgEpB,CAAC"}
@@ -1,8 +1,15 @@
1
1
  import { z } from "zod";
2
2
  import { EVideoGenModels } from "../../../globals/aiModels";
3
3
  import { ToolDefinition } from "../toolRegistry";
4
- /** Whether a model key can be extended via its provider's extend endpoint. */
5
- export declare function modelSupportsExtend(modelKey: string): boolean;
4
+ /**
5
+ * AG-2: the extend-capable model list moved to
6
+ * `globals/aiModels/extendCapability.ts` so the HTTP request schema can consult
7
+ * it too — it previously lived here, which meant only the agent enforced it and
8
+ * `POST /v1/video/generate` accepted `endpoint:"extend"` for ANY model.
9
+ * Re-exported so `extendChain.ts` and `planner/validators.ts` keep importing
10
+ * `modelSupportsExtend` from this module unchanged.
11
+ */
12
+ export { EXTEND_CAPABLE_MODELS, modelSupportsExtend } from "../../../globals/aiModels/extendCapability";
6
13
  declare const InputSchema: z.ZodObject<{
7
14
  previousTaskId: z.ZodString;
8
15
  modelKey: z.ZodEnum<typeof EVideoGenModels>;
@@ -22,5 +29,4 @@ declare const OutputSchema: z.ZodObject<{
22
29
  modelKeyUsed: z.ZodOptional<z.ZodString>;
23
30
  }, z.core.$strip>;
24
31
  export declare const extendVideoTool: ToolDefinition<typeof InputSchema, typeof OutputSchema>;
25
- export {};
26
32
  //# sourceMappingURL=extendVideo.tool.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"extendVideo.tool.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/tools/extendVideo.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAI5D,OAAO,EAAgB,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAyB/D,8EAA8E;AAC9E,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAE7D;AAED,QAAA,MAAM,WAAW;;;;;;;;;;;iBAsCf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;iBAMhB,CAAC;AAEH,eAAO,MAAM,eAAe,EAAE,cAAc,CAC1C,OAAO,WAAW,EAClB,OAAO,YAAY,CA6EpB,CAAC"}
1
+ {"version":3,"file":"extendVideo.tool.d.ts","sourceRoot":"","sources":["../../../../src/services/agent/tools/extendVideo.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAI5D,OAAO,EAAgB,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAE/D;;;;;;;GAOG;AACH,OAAO,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,MAAM,4CAA4C,CAAC;AAGxG,QAAA,MAAM,WAAW;;;;;;;;;;;iBAsCf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;iBAMhB,CAAC;AAEH,eAAO,MAAM,eAAe,EAAE,cAAc,CAC1C,OAAO,WAAW,EAClB,OAAO,YAAY,CA6EpB,CAAC"}