mulmocast 1.2.26 → 1.2.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/templates/documentary.json +19 -0
- package/assets/templates/image_prompt.json +16 -0
- package/lib/actions/image_agents.d.ts +13 -31
- package/lib/actions/image_agents.js +3 -5
- package/lib/actions/image_references.js +2 -2
- package/lib/actions/images.d.ts +12 -30
- package/lib/actions/images.js +2 -1
- package/lib/agents/image_replicate_agent.d.ts +7 -0
- package/lib/agents/image_replicate_agent.js +84 -0
- package/lib/agents/index.d.ts +2 -1
- package/lib/agents/index.js +2 -1
- package/lib/data/promptTemplates.d.ts +10 -40
- package/lib/data/promptTemplates.js +85 -48
- package/lib/data/scriptTemplates.js +160 -160
- package/lib/data/templateDataSet.d.ts +2 -0
- package/lib/data/templateDataSet.js +9 -1
- package/lib/mcp/aaa.js +1 -1
- package/lib/mcp/server.js +0 -1
- package/lib/types/agent.d.ts +12 -0
- package/lib/types/schema.d.ts +98 -98
- package/lib/types/schema.js +1 -3
- package/lib/utils/context.d.ts +33 -33
- package/lib/utils/image_plugins/image.d.ts +1 -1
- package/lib/utils/image_plugins/image.js +2 -2
- package/lib/utils/image_plugins/movie.d.ts +1 -1
- package/lib/utils/image_plugins/movie.js +2 -2
- package/lib/utils/image_plugins/source.d.ts +2 -1
- package/lib/utils/image_plugins/source.js +34 -1
- package/lib/utils/image_plugins/vision.js +1 -1
- package/lib/utils/provider2agent.d.ts +5 -0
- package/lib/utils/provider2agent.js +5 -0
- package/lib/utils/utils.js +3 -0
- package/package.json +3 -3
- package/scripts/templates/vision.json +160 -160
- package/scripts/test/test_mv.json +6 -4
- package/scripts/test/test_replicate.json +18 -0
- package/scripts/test/test_vision.json +1 -1
package/lib/types/schema.d.ts
CHANGED
|
@@ -2998,7 +2998,7 @@ export declare const mulmoPresentationStyleSchema: z.ZodObject<{
|
|
|
2998
2998
|
quality?: string | undefined;
|
|
2999
2999
|
moderation?: string | undefined;
|
|
3000
3000
|
}>>>;
|
|
3001
|
-
movieParams: z.
|
|
3001
|
+
movieParams: z.ZodOptional<z.ZodObject<{
|
|
3002
3002
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
3003
3003
|
model: z.ZodOptional<z.ZodString>;
|
|
3004
3004
|
transition: z.ZodOptional<z.ZodObject<{
|
|
@@ -3038,7 +3038,7 @@ export declare const mulmoPresentationStyleSchema: z.ZodObject<{
|
|
|
3038
3038
|
type: "fade" | "slideout_left";
|
|
3039
3039
|
duration?: number | undefined;
|
|
3040
3040
|
} | undefined;
|
|
3041
|
-
}
|
|
3041
|
+
}>>;
|
|
3042
3042
|
soundEffectParams: z.ZodDefault<z.ZodOptional<z.ZodObject<{
|
|
3043
3043
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
3044
3044
|
model: z.ZodOptional<z.ZodString>;
|
|
@@ -3224,17 +3224,6 @@ export declare const mulmoPresentationStyleSchema: z.ZodObject<{
|
|
|
3224
3224
|
kind: "path";
|
|
3225
3225
|
} | undefined;
|
|
3226
3226
|
};
|
|
3227
|
-
movieParams: {
|
|
3228
|
-
provider?: string | undefined;
|
|
3229
|
-
model?: string | undefined;
|
|
3230
|
-
fillOption?: {
|
|
3231
|
-
style: "aspectFit" | "aspectFill";
|
|
3232
|
-
} | undefined;
|
|
3233
|
-
transition?: {
|
|
3234
|
-
type: "fade" | "slideout_left";
|
|
3235
|
-
duration: number;
|
|
3236
|
-
} | undefined;
|
|
3237
|
-
};
|
|
3238
3227
|
soundEffectParams: {
|
|
3239
3228
|
provider?: string | undefined;
|
|
3240
3229
|
model?: string | undefined;
|
|
@@ -3271,6 +3260,17 @@ export declare const mulmoPresentationStyleSchema: z.ZodObject<{
|
|
|
3271
3260
|
model?: string | undefined;
|
|
3272
3261
|
}>;
|
|
3273
3262
|
};
|
|
3263
|
+
movieParams?: {
|
|
3264
|
+
provider?: string | undefined;
|
|
3265
|
+
model?: string | undefined;
|
|
3266
|
+
fillOption?: {
|
|
3267
|
+
style: "aspectFit" | "aspectFill";
|
|
3268
|
+
} | undefined;
|
|
3269
|
+
transition?: {
|
|
3270
|
+
type: "fade" | "slideout_left";
|
|
3271
|
+
duration: number;
|
|
3272
|
+
} | undefined;
|
|
3273
|
+
} | undefined;
|
|
3274
3274
|
lipSyncParams?: {
|
|
3275
3275
|
provider?: string | undefined;
|
|
3276
3276
|
model?: string | undefined;
|
|
@@ -3716,7 +3716,7 @@ export declare const mulmoScriptSchema: z.ZodObject<{
|
|
|
3716
3716
|
quality?: string | undefined;
|
|
3717
3717
|
moderation?: string | undefined;
|
|
3718
3718
|
}>>>;
|
|
3719
|
-
movieParams: z.
|
|
3719
|
+
movieParams: z.ZodOptional<z.ZodObject<{
|
|
3720
3720
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
3721
3721
|
model: z.ZodOptional<z.ZodString>;
|
|
3722
3722
|
transition: z.ZodOptional<z.ZodObject<{
|
|
@@ -3756,7 +3756,7 @@ export declare const mulmoScriptSchema: z.ZodObject<{
|
|
|
3756
3756
|
type: "fade" | "slideout_left";
|
|
3757
3757
|
duration?: number | undefined;
|
|
3758
3758
|
} | undefined;
|
|
3759
|
-
}
|
|
3759
|
+
}>>;
|
|
3760
3760
|
soundEffectParams: z.ZodDefault<z.ZodOptional<z.ZodObject<{
|
|
3761
3761
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
3762
3762
|
model: z.ZodOptional<z.ZodString>;
|
|
@@ -5156,17 +5156,6 @@ export declare const mulmoScriptSchema: z.ZodObject<{
|
|
|
5156
5156
|
kind: "path";
|
|
5157
5157
|
} | undefined;
|
|
5158
5158
|
};
|
|
5159
|
-
movieParams: {
|
|
5160
|
-
provider?: string | undefined;
|
|
5161
|
-
model?: string | undefined;
|
|
5162
|
-
fillOption?: {
|
|
5163
|
-
style: "aspectFit" | "aspectFill";
|
|
5164
|
-
} | undefined;
|
|
5165
|
-
transition?: {
|
|
5166
|
-
type: "fade" | "slideout_left";
|
|
5167
|
-
duration: number;
|
|
5168
|
-
} | undefined;
|
|
5169
|
-
};
|
|
5170
5159
|
soundEffectParams: {
|
|
5171
5160
|
provider?: string | undefined;
|
|
5172
5161
|
model?: string | undefined;
|
|
@@ -5410,6 +5399,17 @@ export declare const mulmoScriptSchema: z.ZodObject<{
|
|
|
5410
5399
|
}[];
|
|
5411
5400
|
title?: string | undefined;
|
|
5412
5401
|
description?: string | undefined;
|
|
5402
|
+
movieParams?: {
|
|
5403
|
+
provider?: string | undefined;
|
|
5404
|
+
model?: string | undefined;
|
|
5405
|
+
fillOption?: {
|
|
5406
|
+
style: "aspectFit" | "aspectFill";
|
|
5407
|
+
} | undefined;
|
|
5408
|
+
transition?: {
|
|
5409
|
+
type: "fade" | "slideout_left";
|
|
5410
|
+
duration: number;
|
|
5411
|
+
} | undefined;
|
|
5412
|
+
} | undefined;
|
|
5413
5413
|
lipSyncParams?: {
|
|
5414
5414
|
provider?: string | undefined;
|
|
5415
5415
|
model?: string | undefined;
|
|
@@ -6417,7 +6417,7 @@ export declare const mulmoStudioSchema: z.ZodObject<{
|
|
|
6417
6417
|
quality?: string | undefined;
|
|
6418
6418
|
moderation?: string | undefined;
|
|
6419
6419
|
}>>>;
|
|
6420
|
-
movieParams: z.
|
|
6420
|
+
movieParams: z.ZodOptional<z.ZodObject<{
|
|
6421
6421
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
6422
6422
|
model: z.ZodOptional<z.ZodString>;
|
|
6423
6423
|
transition: z.ZodOptional<z.ZodObject<{
|
|
@@ -6457,7 +6457,7 @@ export declare const mulmoStudioSchema: z.ZodObject<{
|
|
|
6457
6457
|
type: "fade" | "slideout_left";
|
|
6458
6458
|
duration?: number | undefined;
|
|
6459
6459
|
} | undefined;
|
|
6460
|
-
}
|
|
6460
|
+
}>>;
|
|
6461
6461
|
soundEffectParams: z.ZodDefault<z.ZodOptional<z.ZodObject<{
|
|
6462
6462
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
6463
6463
|
model: z.ZodOptional<z.ZodString>;
|
|
@@ -7857,17 +7857,6 @@ export declare const mulmoStudioSchema: z.ZodObject<{
|
|
|
7857
7857
|
kind: "path";
|
|
7858
7858
|
} | undefined;
|
|
7859
7859
|
};
|
|
7860
|
-
movieParams: {
|
|
7861
|
-
provider?: string | undefined;
|
|
7862
|
-
model?: string | undefined;
|
|
7863
|
-
fillOption?: {
|
|
7864
|
-
style: "aspectFit" | "aspectFill";
|
|
7865
|
-
} | undefined;
|
|
7866
|
-
transition?: {
|
|
7867
|
-
type: "fade" | "slideout_left";
|
|
7868
|
-
duration: number;
|
|
7869
|
-
} | undefined;
|
|
7870
|
-
};
|
|
7871
7860
|
soundEffectParams: {
|
|
7872
7861
|
provider?: string | undefined;
|
|
7873
7862
|
model?: string | undefined;
|
|
@@ -8111,6 +8100,17 @@ export declare const mulmoStudioSchema: z.ZodObject<{
|
|
|
8111
8100
|
}[];
|
|
8112
8101
|
title?: string | undefined;
|
|
8113
8102
|
description?: string | undefined;
|
|
8103
|
+
movieParams?: {
|
|
8104
|
+
provider?: string | undefined;
|
|
8105
|
+
model?: string | undefined;
|
|
8106
|
+
fillOption?: {
|
|
8107
|
+
style: "aspectFit" | "aspectFill";
|
|
8108
|
+
} | undefined;
|
|
8109
|
+
transition?: {
|
|
8110
|
+
type: "fade" | "slideout_left";
|
|
8111
|
+
duration: number;
|
|
8112
|
+
} | undefined;
|
|
8113
|
+
} | undefined;
|
|
8114
8114
|
lipSyncParams?: {
|
|
8115
8115
|
provider?: string | undefined;
|
|
8116
8116
|
model?: string | undefined;
|
|
@@ -8580,17 +8580,6 @@ export declare const mulmoStudioSchema: z.ZodObject<{
|
|
|
8580
8580
|
kind: "path";
|
|
8581
8581
|
} | undefined;
|
|
8582
8582
|
};
|
|
8583
|
-
movieParams: {
|
|
8584
|
-
provider?: string | undefined;
|
|
8585
|
-
model?: string | undefined;
|
|
8586
|
-
fillOption?: {
|
|
8587
|
-
style: "aspectFit" | "aspectFill";
|
|
8588
|
-
} | undefined;
|
|
8589
|
-
transition?: {
|
|
8590
|
-
type: "fade" | "slideout_left";
|
|
8591
|
-
duration: number;
|
|
8592
|
-
} | undefined;
|
|
8593
|
-
};
|
|
8594
8583
|
soundEffectParams: {
|
|
8595
8584
|
provider?: string | undefined;
|
|
8596
8585
|
model?: string | undefined;
|
|
@@ -8834,6 +8823,17 @@ export declare const mulmoStudioSchema: z.ZodObject<{
|
|
|
8834
8823
|
}[];
|
|
8835
8824
|
title?: string | undefined;
|
|
8836
8825
|
description?: string | undefined;
|
|
8826
|
+
movieParams?: {
|
|
8827
|
+
provider?: string | undefined;
|
|
8828
|
+
model?: string | undefined;
|
|
8829
|
+
fillOption?: {
|
|
8830
|
+
style: "aspectFit" | "aspectFill";
|
|
8831
|
+
} | undefined;
|
|
8832
|
+
transition?: {
|
|
8833
|
+
type: "fade" | "slideout_left";
|
|
8834
|
+
duration: number;
|
|
8835
|
+
} | undefined;
|
|
8836
|
+
} | undefined;
|
|
8837
8837
|
lipSyncParams?: {
|
|
8838
8838
|
provider?: string | undefined;
|
|
8839
8839
|
model?: string | undefined;
|
|
@@ -9514,7 +9514,7 @@ export declare const mulmoPromptTemplateSchema: z.ZodObject<{
|
|
|
9514
9514
|
quality?: string | undefined;
|
|
9515
9515
|
moderation?: string | undefined;
|
|
9516
9516
|
}>>>;
|
|
9517
|
-
movieParams: z.
|
|
9517
|
+
movieParams: z.ZodOptional<z.ZodObject<{
|
|
9518
9518
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
9519
9519
|
model: z.ZodOptional<z.ZodString>;
|
|
9520
9520
|
transition: z.ZodOptional<z.ZodObject<{
|
|
@@ -9554,7 +9554,7 @@ export declare const mulmoPromptTemplateSchema: z.ZodObject<{
|
|
|
9554
9554
|
type: "fade" | "slideout_left";
|
|
9555
9555
|
duration?: number | undefined;
|
|
9556
9556
|
} | undefined;
|
|
9557
|
-
}
|
|
9557
|
+
}>>;
|
|
9558
9558
|
soundEffectParams: z.ZodDefault<z.ZodOptional<z.ZodObject<{
|
|
9559
9559
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
9560
9560
|
model: z.ZodOptional<z.ZodString>;
|
|
@@ -9740,17 +9740,6 @@ export declare const mulmoPromptTemplateSchema: z.ZodObject<{
|
|
|
9740
9740
|
kind: "path";
|
|
9741
9741
|
} | undefined;
|
|
9742
9742
|
};
|
|
9743
|
-
movieParams: {
|
|
9744
|
-
provider?: string | undefined;
|
|
9745
|
-
model?: string | undefined;
|
|
9746
|
-
fillOption?: {
|
|
9747
|
-
style: "aspectFit" | "aspectFill";
|
|
9748
|
-
} | undefined;
|
|
9749
|
-
transition?: {
|
|
9750
|
-
type: "fade" | "slideout_left";
|
|
9751
|
-
duration: number;
|
|
9752
|
-
} | undefined;
|
|
9753
|
-
};
|
|
9754
9743
|
soundEffectParams: {
|
|
9755
9744
|
provider?: string | undefined;
|
|
9756
9745
|
model?: string | undefined;
|
|
@@ -9787,6 +9776,17 @@ export declare const mulmoPromptTemplateSchema: z.ZodObject<{
|
|
|
9787
9776
|
model?: string | undefined;
|
|
9788
9777
|
}>;
|
|
9789
9778
|
};
|
|
9779
|
+
movieParams?: {
|
|
9780
|
+
provider?: string | undefined;
|
|
9781
|
+
model?: string | undefined;
|
|
9782
|
+
fillOption?: {
|
|
9783
|
+
style: "aspectFit" | "aspectFill";
|
|
9784
|
+
} | undefined;
|
|
9785
|
+
transition?: {
|
|
9786
|
+
type: "fade" | "slideout_left";
|
|
9787
|
+
duration: number;
|
|
9788
|
+
} | undefined;
|
|
9789
|
+
} | undefined;
|
|
9790
9790
|
lipSyncParams?: {
|
|
9791
9791
|
provider?: string | undefined;
|
|
9792
9792
|
model?: string | undefined;
|
|
@@ -9968,17 +9968,6 @@ export declare const mulmoPromptTemplateSchema: z.ZodObject<{
|
|
|
9968
9968
|
kind: "path";
|
|
9969
9969
|
} | undefined;
|
|
9970
9970
|
};
|
|
9971
|
-
movieParams: {
|
|
9972
|
-
provider?: string | undefined;
|
|
9973
|
-
model?: string | undefined;
|
|
9974
|
-
fillOption?: {
|
|
9975
|
-
style: "aspectFit" | "aspectFill";
|
|
9976
|
-
} | undefined;
|
|
9977
|
-
transition?: {
|
|
9978
|
-
type: "fade" | "slideout_left";
|
|
9979
|
-
duration: number;
|
|
9980
|
-
} | undefined;
|
|
9981
|
-
};
|
|
9982
9971
|
soundEffectParams: {
|
|
9983
9972
|
provider?: string | undefined;
|
|
9984
9973
|
model?: string | undefined;
|
|
@@ -10015,6 +10004,17 @@ export declare const mulmoPromptTemplateSchema: z.ZodObject<{
|
|
|
10015
10004
|
model?: string | undefined;
|
|
10016
10005
|
}>;
|
|
10017
10006
|
};
|
|
10007
|
+
movieParams?: {
|
|
10008
|
+
provider?: string | undefined;
|
|
10009
|
+
model?: string | undefined;
|
|
10010
|
+
fillOption?: {
|
|
10011
|
+
style: "aspectFit" | "aspectFill";
|
|
10012
|
+
} | undefined;
|
|
10013
|
+
transition?: {
|
|
10014
|
+
type: "fade" | "slideout_left";
|
|
10015
|
+
duration: number;
|
|
10016
|
+
} | undefined;
|
|
10017
|
+
} | undefined;
|
|
10018
10018
|
lipSyncParams?: {
|
|
10019
10019
|
provider?: string | undefined;
|
|
10020
10020
|
model?: string | undefined;
|
|
@@ -10456,7 +10456,7 @@ export declare const mulmoPromptTemplateFileSchema: z.ZodObject<{
|
|
|
10456
10456
|
quality?: string | undefined;
|
|
10457
10457
|
moderation?: string | undefined;
|
|
10458
10458
|
}>>>;
|
|
10459
|
-
movieParams: z.
|
|
10459
|
+
movieParams: z.ZodOptional<z.ZodObject<{
|
|
10460
10460
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
10461
10461
|
model: z.ZodOptional<z.ZodString>;
|
|
10462
10462
|
transition: z.ZodOptional<z.ZodObject<{
|
|
@@ -10496,7 +10496,7 @@ export declare const mulmoPromptTemplateFileSchema: z.ZodObject<{
|
|
|
10496
10496
|
type: "fade" | "slideout_left";
|
|
10497
10497
|
duration?: number | undefined;
|
|
10498
10498
|
} | undefined;
|
|
10499
|
-
}
|
|
10499
|
+
}>>;
|
|
10500
10500
|
soundEffectParams: z.ZodDefault<z.ZodOptional<z.ZodObject<{
|
|
10501
10501
|
provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<[string, ...string[]]>>>;
|
|
10502
10502
|
model: z.ZodOptional<z.ZodString>;
|
|
@@ -10682,17 +10682,6 @@ export declare const mulmoPromptTemplateFileSchema: z.ZodObject<{
|
|
|
10682
10682
|
kind: "path";
|
|
10683
10683
|
} | undefined;
|
|
10684
10684
|
};
|
|
10685
|
-
movieParams: {
|
|
10686
|
-
provider?: string | undefined;
|
|
10687
|
-
model?: string | undefined;
|
|
10688
|
-
fillOption?: {
|
|
10689
|
-
style: "aspectFit" | "aspectFill";
|
|
10690
|
-
} | undefined;
|
|
10691
|
-
transition?: {
|
|
10692
|
-
type: "fade" | "slideout_left";
|
|
10693
|
-
duration: number;
|
|
10694
|
-
} | undefined;
|
|
10695
|
-
};
|
|
10696
10685
|
soundEffectParams: {
|
|
10697
10686
|
provider?: string | undefined;
|
|
10698
10687
|
model?: string | undefined;
|
|
@@ -10729,6 +10718,17 @@ export declare const mulmoPromptTemplateFileSchema: z.ZodObject<{
|
|
|
10729
10718
|
model?: string | undefined;
|
|
10730
10719
|
}>;
|
|
10731
10720
|
};
|
|
10721
|
+
movieParams?: {
|
|
10722
|
+
provider?: string | undefined;
|
|
10723
|
+
model?: string | undefined;
|
|
10724
|
+
fillOption?: {
|
|
10725
|
+
style: "aspectFit" | "aspectFill";
|
|
10726
|
+
} | undefined;
|
|
10727
|
+
transition?: {
|
|
10728
|
+
type: "fade" | "slideout_left";
|
|
10729
|
+
duration: number;
|
|
10730
|
+
} | undefined;
|
|
10731
|
+
} | undefined;
|
|
10732
10732
|
lipSyncParams?: {
|
|
10733
10733
|
provider?: string | undefined;
|
|
10734
10734
|
model?: string | undefined;
|
|
@@ -10913,17 +10913,6 @@ export declare const mulmoPromptTemplateFileSchema: z.ZodObject<{
|
|
|
10913
10913
|
kind: "path";
|
|
10914
10914
|
} | undefined;
|
|
10915
10915
|
};
|
|
10916
|
-
movieParams: {
|
|
10917
|
-
provider?: string | undefined;
|
|
10918
|
-
model?: string | undefined;
|
|
10919
|
-
fillOption?: {
|
|
10920
|
-
style: "aspectFit" | "aspectFill";
|
|
10921
|
-
} | undefined;
|
|
10922
|
-
transition?: {
|
|
10923
|
-
type: "fade" | "slideout_left";
|
|
10924
|
-
duration: number;
|
|
10925
|
-
} | undefined;
|
|
10926
|
-
};
|
|
10927
10916
|
soundEffectParams: {
|
|
10928
10917
|
provider?: string | undefined;
|
|
10929
10918
|
model?: string | undefined;
|
|
@@ -10960,6 +10949,17 @@ export declare const mulmoPromptTemplateFileSchema: z.ZodObject<{
|
|
|
10960
10949
|
model?: string | undefined;
|
|
10961
10950
|
}>;
|
|
10962
10951
|
};
|
|
10952
|
+
movieParams?: {
|
|
10953
|
+
provider?: string | undefined;
|
|
10954
|
+
model?: string | undefined;
|
|
10955
|
+
fillOption?: {
|
|
10956
|
+
style: "aspectFit" | "aspectFill";
|
|
10957
|
+
} | undefined;
|
|
10958
|
+
transition?: {
|
|
10959
|
+
type: "fade" | "slideout_left";
|
|
10960
|
+
duration: number;
|
|
10961
|
+
} | undefined;
|
|
10962
|
+
} | undefined;
|
|
10963
10963
|
lipSyncParams?: {
|
|
10964
10964
|
provider?: string | undefined;
|
|
10965
10965
|
model?: string | undefined;
|
package/lib/types/schema.js
CHANGED
|
@@ -346,9 +346,7 @@ export const mulmoPresentationStyleSchema = z.object({
|
|
|
346
346
|
provider: defaultProviders.text2image,
|
|
347
347
|
images: {},
|
|
348
348
|
}),
|
|
349
|
-
movieParams: mulmoMovieParamsSchema.optional()
|
|
350
|
-
provider: defaultProviders.text2movie,
|
|
351
|
-
}),
|
|
349
|
+
movieParams: mulmoMovieParamsSchema.optional(),
|
|
352
350
|
soundEffectParams: mulmoSoundEffectParamsSchema.optional().default({
|
|
353
351
|
provider: defaultProviders.soundEffect,
|
|
354
352
|
}),
|
package/lib/utils/context.d.ts
CHANGED
|
@@ -67,17 +67,6 @@ export declare const createStudioData: (_mulmoScript: MulmoScript, fileName: str
|
|
|
67
67
|
kind: "path";
|
|
68
68
|
} | undefined;
|
|
69
69
|
};
|
|
70
|
-
movieParams: {
|
|
71
|
-
provider?: string | undefined;
|
|
72
|
-
model?: string | undefined;
|
|
73
|
-
fillOption?: {
|
|
74
|
-
style: "aspectFit" | "aspectFill";
|
|
75
|
-
} | undefined;
|
|
76
|
-
transition?: {
|
|
77
|
-
type: "fade" | "slideout_left";
|
|
78
|
-
duration: number;
|
|
79
|
-
} | undefined;
|
|
80
|
-
};
|
|
81
70
|
soundEffectParams: {
|
|
82
71
|
provider?: string | undefined;
|
|
83
72
|
model?: string | undefined;
|
|
@@ -321,6 +310,17 @@ export declare const createStudioData: (_mulmoScript: MulmoScript, fileName: str
|
|
|
321
310
|
}[];
|
|
322
311
|
title?: string | undefined;
|
|
323
312
|
description?: string | undefined;
|
|
313
|
+
movieParams?: {
|
|
314
|
+
provider?: string | undefined;
|
|
315
|
+
model?: string | undefined;
|
|
316
|
+
fillOption?: {
|
|
317
|
+
style: "aspectFit" | "aspectFill";
|
|
318
|
+
} | undefined;
|
|
319
|
+
transition?: {
|
|
320
|
+
type: "fade" | "slideout_left";
|
|
321
|
+
duration: number;
|
|
322
|
+
} | undefined;
|
|
323
|
+
} | undefined;
|
|
324
324
|
lipSyncParams?: {
|
|
325
325
|
provider?: string | undefined;
|
|
326
326
|
model?: string | undefined;
|
|
@@ -419,17 +419,6 @@ export declare const initializeContextFromFiles: (files: FileObject, raiseError:
|
|
|
419
419
|
kind: "path";
|
|
420
420
|
} | undefined;
|
|
421
421
|
};
|
|
422
|
-
movieParams: {
|
|
423
|
-
provider?: string | undefined;
|
|
424
|
-
model?: string | undefined;
|
|
425
|
-
fillOption?: {
|
|
426
|
-
style: "aspectFit" | "aspectFill";
|
|
427
|
-
} | undefined;
|
|
428
|
-
transition?: {
|
|
429
|
-
type: "fade" | "slideout_left";
|
|
430
|
-
duration: number;
|
|
431
|
-
} | undefined;
|
|
432
|
-
};
|
|
433
422
|
soundEffectParams: {
|
|
434
423
|
provider?: string | undefined;
|
|
435
424
|
model?: string | undefined;
|
|
@@ -673,6 +662,17 @@ export declare const initializeContextFromFiles: (files: FileObject, raiseError:
|
|
|
673
662
|
}[];
|
|
674
663
|
title?: string | undefined;
|
|
675
664
|
description?: string | undefined;
|
|
665
|
+
movieParams?: {
|
|
666
|
+
provider?: string | undefined;
|
|
667
|
+
model?: string | undefined;
|
|
668
|
+
fillOption?: {
|
|
669
|
+
style: "aspectFit" | "aspectFill";
|
|
670
|
+
} | undefined;
|
|
671
|
+
transition?: {
|
|
672
|
+
type: "fade" | "slideout_left";
|
|
673
|
+
duration: number;
|
|
674
|
+
} | undefined;
|
|
675
|
+
} | undefined;
|
|
676
676
|
lipSyncParams?: {
|
|
677
677
|
provider?: string | undefined;
|
|
678
678
|
model?: string | undefined;
|
|
@@ -760,17 +760,6 @@ export declare const initializeContextFromFiles: (files: FileObject, raiseError:
|
|
|
760
760
|
kind: "path";
|
|
761
761
|
} | undefined;
|
|
762
762
|
};
|
|
763
|
-
movieParams: {
|
|
764
|
-
provider?: string | undefined;
|
|
765
|
-
model?: string | undefined;
|
|
766
|
-
fillOption?: {
|
|
767
|
-
style: "aspectFit" | "aspectFill";
|
|
768
|
-
} | undefined;
|
|
769
|
-
transition?: {
|
|
770
|
-
type: "fade" | "slideout_left";
|
|
771
|
-
duration: number;
|
|
772
|
-
} | undefined;
|
|
773
|
-
};
|
|
774
763
|
soundEffectParams: {
|
|
775
764
|
provider?: string | undefined;
|
|
776
765
|
model?: string | undefined;
|
|
@@ -807,6 +796,17 @@ export declare const initializeContextFromFiles: (files: FileObject, raiseError:
|
|
|
807
796
|
model?: string | undefined;
|
|
808
797
|
}>;
|
|
809
798
|
};
|
|
799
|
+
movieParams?: {
|
|
800
|
+
provider?: string | undefined;
|
|
801
|
+
model?: string | undefined;
|
|
802
|
+
fillOption?: {
|
|
803
|
+
style: "aspectFit" | "aspectFill";
|
|
804
|
+
} | undefined;
|
|
805
|
+
transition?: {
|
|
806
|
+
type: "fade" | "slideout_left";
|
|
807
|
+
duration: number;
|
|
808
|
+
} | undefined;
|
|
809
|
+
} | undefined;
|
|
810
810
|
lipSyncParams?: {
|
|
811
811
|
provider?: string | undefined;
|
|
812
812
|
model?: string | undefined;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare const imageType = "image";
|
|
2
|
-
export declare const process: (params: import("../../index.common.js").ImageProcessorParams) => string | undefined
|
|
2
|
+
export declare const process: (params: import("../../index.common.js").ImageProcessorParams) => Promise<string | undefined>;
|
|
3
3
|
export declare const path: (params: import("../../index.common.js").ImageProcessorParams) => string | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { processSource } from "./source.js";
|
|
1
|
+
import { processSource, pathSource } from "./source.js";
|
|
2
2
|
export const imageType = "image";
|
|
3
3
|
export const process = processSource(imageType);
|
|
4
|
-
export const path =
|
|
4
|
+
export const path = pathSource(imageType);
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare const imageType = "movie";
|
|
2
|
-
export declare const process: (params: import("../../index.common.js").ImageProcessorParams) => string | undefined
|
|
2
|
+
export declare const process: (params: import("../../index.common.js").ImageProcessorParams) => Promise<string | undefined>;
|
|
3
3
|
export declare const path: (params: import("../../index.common.js").ImageProcessorParams) => string | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { processSource } from "./source.js";
|
|
1
|
+
import { processSource, pathSource } from "./source.js";
|
|
2
2
|
export const imageType = "movie";
|
|
3
3
|
export const process = processSource(imageType);
|
|
4
|
-
export const path =
|
|
4
|
+
export const path = pathSource(imageType);
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ImageProcessorParams } from "../../types/index.js";
|
|
2
2
|
type ImageType = "image" | "movie";
|
|
3
|
-
export declare const processSource: (imageType: ImageType) => (params: ImageProcessorParams) => string | undefined
|
|
3
|
+
export declare const processSource: (imageType: ImageType) => (params: ImageProcessorParams) => Promise<string | undefined>;
|
|
4
|
+
export declare const pathSource: (__: ImageType) => (params: ImageProcessorParams) => string | undefined;
|
|
4
5
|
export {};
|
|
@@ -1,10 +1,28 @@
|
|
|
1
|
+
import fs from "fs";
|
|
1
2
|
import { GraphAILogger } from "graphai";
|
|
2
3
|
import { MulmoMediaSourceMethods } from "../../methods/mulmo_media_source.js";
|
|
4
|
+
function fixExtention(path, imageType) {
|
|
5
|
+
if (imageType === "movie") {
|
|
6
|
+
return path.replace(/\.png$/, ".mov");
|
|
7
|
+
}
|
|
8
|
+
return path;
|
|
9
|
+
}
|
|
3
10
|
export const processSource = (imageType) => {
|
|
4
|
-
return (params) => {
|
|
11
|
+
return async (params) => {
|
|
5
12
|
const { beat, context } = params;
|
|
6
13
|
if (!beat?.image || beat.image.type !== imageType)
|
|
7
14
|
return;
|
|
15
|
+
if (beat.image.source.kind === "url") {
|
|
16
|
+
const response = await fetch(beat.image.source.url);
|
|
17
|
+
if (!response.ok) {
|
|
18
|
+
throw new Error(`Failed to download image: ${beat.image.source.url}`);
|
|
19
|
+
}
|
|
20
|
+
const buffer = Buffer.from(await response.arrayBuffer());
|
|
21
|
+
// Detect file extension from Content-Type header or URL
|
|
22
|
+
const imagePath = fixExtention(params.imagePath, beat.image.type);
|
|
23
|
+
await fs.promises.writeFile(imagePath, buffer);
|
|
24
|
+
return imagePath;
|
|
25
|
+
}
|
|
8
26
|
const path = MulmoMediaSourceMethods.resolve(beat.image.source, context);
|
|
9
27
|
if (path) {
|
|
10
28
|
return path;
|
|
@@ -13,3 +31,18 @@ export const processSource = (imageType) => {
|
|
|
13
31
|
throw new Error(`ERROR: unknown ${imageType} source type`);
|
|
14
32
|
};
|
|
15
33
|
};
|
|
34
|
+
export const pathSource = (__) => {
|
|
35
|
+
return (params) => {
|
|
36
|
+
const { beat, context } = params;
|
|
37
|
+
if (beat.image?.type == "image" || beat.image?.type == "movie") {
|
|
38
|
+
if (beat.image.source?.kind === "url") {
|
|
39
|
+
return fixExtention(params.imagePath, beat.image.type);
|
|
40
|
+
}
|
|
41
|
+
const path = MulmoMediaSourceMethods.resolve(beat.image.source, context);
|
|
42
|
+
if (path) {
|
|
43
|
+
return path;
|
|
44
|
+
}
|
|
45
|
+
return undefined;
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
};
|
|
@@ -8,7 +8,7 @@ const processVision = async (params) => {
|
|
|
8
8
|
if (!beat?.image || beat.image.type !== imageType)
|
|
9
9
|
return;
|
|
10
10
|
const handler = new htmlPlugin({ rootDir });
|
|
11
|
-
await handler
|
|
11
|
+
await handler.callNamedFunction(templateNameTofunctionName(beat.image.style), beat.image.data, {
|
|
12
12
|
functionName: beat.image.style,
|
|
13
13
|
imageFilePath: imagePath,
|
|
14
14
|
htmlFilePath: imagePath.replace(/\.png$/, ".html"),
|
|
@@ -40,6 +40,11 @@ export const provider2ImageAgent = {
|
|
|
40
40
|
defaultModel: "gemini-2.5-flash-image-preview",
|
|
41
41
|
models: ["imagen-3.0-generate-002", "imagen-4.0-generate-preview-06-06", "imagen-4.0-ultra-generate-preview-06-06", "gemini-2.5-flash-image-preview"],
|
|
42
42
|
},
|
|
43
|
+
replicate: {
|
|
44
|
+
agentName: "imageReplicateAgent",
|
|
45
|
+
defaultModel: "bytedance/seedream-4",
|
|
46
|
+
models: ["bytedance/seedream-4", "qwen/qwen-image"],
|
|
47
|
+
},
|
|
43
48
|
mock: {
|
|
44
49
|
agentName: "mediaMockAgent",
|
|
45
50
|
defaultModel: "mock-model",
|
package/lib/utils/utils.js
CHANGED
|
@@ -55,6 +55,9 @@ export const settings2GraphAIConfig = (settings, env) => {
|
|
|
55
55
|
apiKey: getKey("IMAGE", "OPENAI_API_KEY"),
|
|
56
56
|
baseURL: getKey("IMAGE", "OPENAI_BASE_URL"),
|
|
57
57
|
},
|
|
58
|
+
imageReplicateAgent: {
|
|
59
|
+
apiKey: getKey("IMAGE", "REPLICATE_API_TOKEN"),
|
|
60
|
+
},
|
|
58
61
|
imageGenAIAgent: {
|
|
59
62
|
apiKey: getKey("IMAGE", "GEMINI_API_KEY"),
|
|
60
63
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mulmocast",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.28",
|
|
4
4
|
"description": "",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.node.js",
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"graphai": "^2.0.14",
|
|
89
89
|
"jsdom": "^26.1.0",
|
|
90
90
|
"marked": "^16.2.1",
|
|
91
|
-
"mulmocast-vision": "^0.
|
|
91
|
+
"mulmocast-vision": "^0.1.1",
|
|
92
92
|
"ora": "^8.2.0",
|
|
93
93
|
"puppeteer": "^24.19.0",
|
|
94
94
|
"replicate": "^1.1.0",
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
"prettier": "^3.6.2",
|
|
110
110
|
"tsx": "^4.20.5",
|
|
111
111
|
"typescript": "^5.9.2",
|
|
112
|
-
"typescript-eslint": "^8.
|
|
112
|
+
"typescript-eslint": "^8.43.0"
|
|
113
113
|
},
|
|
114
114
|
"engines": {
|
|
115
115
|
"node": ">=18.0.0"
|