@shop-os/modelkit 0.10.0 → 0.10.2
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/CHANGELOG.md +17 -0
- package/dist/catalog.cjs +60 -17
- package/dist/catalog.cjs.map +1 -1
- package/dist/catalog.js +60 -17
- package/dist/catalog.js.map +1 -1
- package/dist/index.cjs +64 -18
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +64 -18
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2144,6 +2144,7 @@ var FISH_VOICES = [
|
|
|
2144
2144
|
var FISH_LOGO = "https://cdn.jsdelivr.net/npm/@lobehub/icons-static-png@1.97.0/light/fishaudio.png";
|
|
2145
2145
|
var PER_CALL2 = { unit: "images" };
|
|
2146
2146
|
var PER_REQUEST2 = { unit: "requests" };
|
|
2147
|
+
var EXPOSURE4 = ["cowork", "space_builder"];
|
|
2147
2148
|
var TTS_MAX_CHARS = 1e4;
|
|
2148
2149
|
function fishTts(id, label, providerModelId, description) {
|
|
2149
2150
|
return {
|
|
@@ -2154,7 +2155,7 @@ function fishTts(id, label, providerModelId, description) {
|
|
|
2154
2155
|
adapter: "fish",
|
|
2155
2156
|
providerModelId,
|
|
2156
2157
|
lifecycle: "active",
|
|
2157
|
-
exposure:
|
|
2158
|
+
exposure: EXPOSURE4,
|
|
2158
2159
|
constraints: {
|
|
2159
2160
|
voices: FISH_VOICES,
|
|
2160
2161
|
outputFormats: ["mp3", "wav"],
|
|
@@ -2195,7 +2196,7 @@ var FISH_MODELS = [
|
|
|
2195
2196
|
adapter: "fish",
|
|
2196
2197
|
providerModelId: "voice-clone",
|
|
2197
2198
|
lifecycle: "active",
|
|
2198
|
-
exposure:
|
|
2199
|
+
exposure: EXPOSURE4,
|
|
2199
2200
|
constraints: {
|
|
2200
2201
|
// POST /model takes 1-20 voice files; Fish advises 10 s or more of clean speech each.
|
|
2201
2202
|
references: { audios: 20, audioFormats: ["wav", "mp3", "m4a", "opus"] },
|
|
@@ -2219,7 +2220,7 @@ var FISH_MODELS = [
|
|
|
2219
2220
|
adapter: "fish",
|
|
2220
2221
|
providerModelId: "voice-design-1",
|
|
2221
2222
|
lifecycle: "active",
|
|
2222
|
-
exposure:
|
|
2223
|
+
exposure: EXPOSURE4,
|
|
2223
2224
|
constraints: {
|
|
2224
2225
|
voiceDesign: { maxCandidates: 4, previewMaxChars: 150 },
|
|
2225
2226
|
supports: [],
|
|
@@ -3817,7 +3818,7 @@ var GOOGLE_LOGO = "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/192485d2-a
|
|
|
3817
3818
|
var MINIMAX_LOGO = "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/f4c2e906-28b7-4a4a-b491-df8fef7808ed.png";
|
|
3818
3819
|
var SYNC_LOGO = "https://cdn.jsdelivr.net/npm/@lobehub/icons-static-png@1.97.0/light/sync.png";
|
|
3819
3820
|
var PER_CALL3 = { unit: "images" };
|
|
3820
|
-
var
|
|
3821
|
+
var EXPOSURE5 = ["cowork", "space_builder"];
|
|
3821
3822
|
var LIPSYNC_AUDIO = { audioSeconds: { max: 30 } };
|
|
3822
3823
|
function elevenLabsTts(tts) {
|
|
3823
3824
|
return {
|
|
@@ -3828,7 +3829,7 @@ function elevenLabsTts(tts) {
|
|
|
3828
3829
|
adapter: "fal",
|
|
3829
3830
|
providerModelId: tts.providerModelId,
|
|
3830
3831
|
lifecycle: "active",
|
|
3831
|
-
exposure:
|
|
3832
|
+
exposure: EXPOSURE5,
|
|
3832
3833
|
constraints: {
|
|
3833
3834
|
voices: ELEVENLABS_VOICES,
|
|
3834
3835
|
languages: tts.languages,
|
|
@@ -3853,7 +3854,7 @@ function geminiTts(id, label, description) {
|
|
|
3853
3854
|
adapter: "fal",
|
|
3854
3855
|
providerModelId,
|
|
3855
3856
|
lifecycle: "active",
|
|
3856
|
-
exposure:
|
|
3857
|
+
exposure: EXPOSURE5,
|
|
3857
3858
|
constraints: {
|
|
3858
3859
|
voices: GEMINI_TTS_VOICES,
|
|
3859
3860
|
supports: ["style"],
|
|
@@ -3876,7 +3877,7 @@ function syncLipsync(id, label, providerModelId, syncModel, description) {
|
|
|
3876
3877
|
adapter: "fal",
|
|
3877
3878
|
providerModelId,
|
|
3878
3879
|
lifecycle: "active",
|
|
3879
|
-
exposure:
|
|
3880
|
+
exposure: EXPOSURE5,
|
|
3880
3881
|
constraints: {
|
|
3881
3882
|
requires: ["sourceVideo", "sourceAudio"],
|
|
3882
3883
|
references: LIPSYNC_AUDIO,
|
|
@@ -3937,7 +3938,7 @@ var MEDIA_NODE_MODELS = [
|
|
|
3937
3938
|
adapter: "fal",
|
|
3938
3939
|
providerModelId: "fal-ai/minimax/speech-2.8-hd",
|
|
3939
3940
|
lifecycle: "active",
|
|
3940
|
-
exposure:
|
|
3941
|
+
exposure: EXPOSURE5,
|
|
3941
3942
|
constraints: {
|
|
3942
3943
|
voices: MINIMAX_VOICES,
|
|
3943
3944
|
languages: MINIMAX_SPEECH_LANGUAGES,
|
|
@@ -3962,7 +3963,7 @@ var MEDIA_NODE_MODELS = [
|
|
|
3962
3963
|
adapter: "fal",
|
|
3963
3964
|
providerModelId: "fal-ai/elevenlabs/voice-changer",
|
|
3964
3965
|
lifecycle: "active",
|
|
3965
|
-
exposure:
|
|
3966
|
+
exposure: EXPOSURE5,
|
|
3966
3967
|
constraints: {
|
|
3967
3968
|
requires: ["sourceAudio"],
|
|
3968
3969
|
// The flat price assumes at most a minute of speech.
|
|
@@ -3989,7 +3990,7 @@ var MEDIA_NODE_MODELS = [
|
|
|
3989
3990
|
adapter: "fal",
|
|
3990
3991
|
providerModelId: "fal-ai/elevenlabs/dubbing",
|
|
3991
3992
|
lifecycle: "active",
|
|
3992
|
-
exposure:
|
|
3993
|
+
exposure: EXPOSURE5,
|
|
3993
3994
|
constraints: {
|
|
3994
3995
|
requiresOneOf: ["sourceVideo", "sourceAudio"],
|
|
3995
3996
|
// The flat price covers 60 s of source.
|
|
@@ -4037,7 +4038,7 @@ var MEDIA_NODE_MODELS = [
|
|
|
4037
4038
|
adapter: "fal",
|
|
4038
4039
|
providerModelId: "veed/lipsync/v2",
|
|
4039
4040
|
lifecycle: "active",
|
|
4040
|
-
exposure:
|
|
4041
|
+
exposure: EXPOSURE5,
|
|
4041
4042
|
constraints: {
|
|
4042
4043
|
requires: ["sourceVideo", "sourceAudio"],
|
|
4043
4044
|
references: LIPSYNC_AUDIO,
|
|
@@ -4063,7 +4064,7 @@ var MEDIA_NODE_MODELS = [
|
|
|
4063
4064
|
adapter: "fal",
|
|
4064
4065
|
providerModelId: "minimax/h3-max/lip-sync/image-to-video",
|
|
4065
4066
|
lifecycle: "active",
|
|
4066
|
-
exposure:
|
|
4067
|
+
exposure: EXPOSURE5,
|
|
4067
4068
|
constraints: {
|
|
4068
4069
|
requires: ["firstFrame", "sourceAudio"],
|
|
4069
4070
|
resolutions: ["480p", "768p", "1080p", "2k"],
|
|
@@ -4089,7 +4090,7 @@ var MEDIA_NODE_MODELS = [
|
|
|
4089
4090
|
adapter: "fal",
|
|
4090
4091
|
providerModelId: "fal-ai/elevenlabs/speech-to-text/scribe-v2",
|
|
4091
4092
|
lifecycle: "active",
|
|
4092
|
-
exposure:
|
|
4093
|
+
exposure: EXPOSURE5,
|
|
4093
4094
|
constraints: {
|
|
4094
4095
|
requires: ["sourceAudio"],
|
|
4095
4096
|
// The flat price covers 10 minutes of audio.
|
|
@@ -5704,7 +5705,7 @@ var VIDEO_FAMILY_MODELS = [
|
|
|
5704
5705
|
|
|
5705
5706
|
// src/catalog/video-luma.ts
|
|
5706
5707
|
var VIDEO_USAGE2 = { unit: "seconds" };
|
|
5707
|
-
var
|
|
5708
|
+
var EXPOSURE6 = ["cowork", "space_builder"];
|
|
5708
5709
|
var LUMA_LOGO2 = "https://cdn.jsdelivr.net/npm/@lobehub/icons-static-png@1.97.0/light/luma-color.png";
|
|
5709
5710
|
var RAY_RATIOS = ["9:16", "3:4", "1:1", "4:3", "16:9", "21:9"];
|
|
5710
5711
|
var RAY_RESOLUTIONS = ["360p", "720p", "1080p"];
|
|
@@ -5722,7 +5723,7 @@ var LUMA_VIDEO_MODELS = [
|
|
|
5722
5723
|
adapter: "luma",
|
|
5723
5724
|
providerModelId: "ray-3.2",
|
|
5724
5725
|
lifecycle: "active",
|
|
5725
|
-
exposure:
|
|
5726
|
+
exposure: EXPOSURE6,
|
|
5726
5727
|
constraints: {
|
|
5727
5728
|
aspectRatios: ["adaptive", ...RAY_RATIOS],
|
|
5728
5729
|
resolutions: [...RAY_RESOLUTIONS],
|
|
@@ -5754,7 +5755,7 @@ var LUMA_VIDEO_MODELS = [
|
|
|
5754
5755
|
adapter: "luma",
|
|
5755
5756
|
providerModelId: "ray-3.2",
|
|
5756
5757
|
lifecycle: "active",
|
|
5757
|
-
exposure:
|
|
5758
|
+
exposure: EXPOSURE6,
|
|
5758
5759
|
constraints: {
|
|
5759
5760
|
resolutions: [...RAY_RESOLUTIONS],
|
|
5760
5761
|
requires: ["sourceVideo"],
|
|
@@ -5787,7 +5788,7 @@ var LUMA_VIDEO_MODELS = [
|
|
|
5787
5788
|
adapter: "luma",
|
|
5788
5789
|
providerModelId: "ray-3.2",
|
|
5789
5790
|
lifecycle: "active",
|
|
5790
|
-
exposure:
|
|
5791
|
+
exposure: EXPOSURE6,
|
|
5791
5792
|
constraints: {
|
|
5792
5793
|
aspectRatios: [...RAY_RATIOS],
|
|
5793
5794
|
resolutions: [...RAY_RESOLUTIONS],
|
|
@@ -6477,6 +6478,48 @@ var VIDEO_MODELS = [
|
|
|
6477
6478
|
},
|
|
6478
6479
|
capabilities: { ...FRAMES_EXCLUDE_REFERENCES, lastFrameRequiresFirstFrame: true }
|
|
6479
6480
|
},
|
|
6481
|
+
{
|
|
6482
|
+
// fal's Wan 3.0 Prime endpoints share Wan 3.0's input schemas field for field but bill
|
|
6483
|
+
// more per second, so Prime is its own row (the id is the pricing key).
|
|
6484
|
+
// https://fal.ai/models/alibaba/wan-3.0-prime/reference-to-video/api
|
|
6485
|
+
id: "wan-3.0-prime",
|
|
6486
|
+
aliases: ["wan-3-prime", "wan3-prime"],
|
|
6487
|
+
label: "Wan 3 Prime",
|
|
6488
|
+
type: "video",
|
|
6489
|
+
adapter: "fal",
|
|
6490
|
+
providerModelId: "alibaba/wan-3.0-prime",
|
|
6491
|
+
lifecycle: "active",
|
|
6492
|
+
exposure: ["cowork", "space_builder"],
|
|
6493
|
+
constraints: {
|
|
6494
|
+
aspectRatios: [...WAN_RATIOS],
|
|
6495
|
+
resolutions: ["480p", "720p", "1080p"],
|
|
6496
|
+
durations: { min: 2, max: 30 },
|
|
6497
|
+
durationPresets: [5, 10, 15, 30],
|
|
6498
|
+
references: {
|
|
6499
|
+
images: 10,
|
|
6500
|
+
videos: 5,
|
|
6501
|
+
audios: 5,
|
|
6502
|
+
videoSeconds: { total: 15 },
|
|
6503
|
+
audioSeconds: { total: 15 }
|
|
6504
|
+
},
|
|
6505
|
+
supports: ["seed", "lastFrame", "generateAudio", "safetyChecker"],
|
|
6506
|
+
prompt: WAN_PROMPT,
|
|
6507
|
+
audio: "optional"
|
|
6508
|
+
},
|
|
6509
|
+
defaults: {
|
|
6510
|
+
durationSeconds: 5,
|
|
6511
|
+
resolution: "1080p",
|
|
6512
|
+
aspectRatio: "adaptive",
|
|
6513
|
+
generateAudio: true
|
|
6514
|
+
},
|
|
6515
|
+
usage: { ...VIDEO_USAGE3 },
|
|
6516
|
+
pricingKind: "video_per_second",
|
|
6517
|
+
display: {
|
|
6518
|
+
provider: "alibaba",
|
|
6519
|
+
description: "Alibaba Wan 3 Prime, the faster-generating tier of Wan 3, for text-to-video, image-to-video (start/end frame), and reference-to-video from up to 10 images, 5 videos and 5 audio clips, with native audio; 2-30 seconds at up to 1080p."
|
|
6520
|
+
},
|
|
6521
|
+
capabilities: { ...FRAMES_EXCLUDE_REFERENCES, lastFrameRequiresFirstFrame: true }
|
|
6522
|
+
},
|
|
6480
6523
|
{
|
|
6481
6524
|
// Duration 3-10s per trigger-workflows mapDuration; the endpoint takes no resolution.
|
|
6482
6525
|
id: "kling-o1-v2v",
|
|
@@ -12679,7 +12722,10 @@ function minimaxBase(req, family) {
|
|
|
12679
12722
|
if (req.seed !== void 0) input.seed = req.seed;
|
|
12680
12723
|
return input;
|
|
12681
12724
|
}
|
|
12682
|
-
var WAN_MODEL_IDS = /* @__PURE__ */ new Set([
|
|
12725
|
+
var WAN_MODEL_IDS = /* @__PURE__ */ new Set([
|
|
12726
|
+
"alibaba/wan-3.0",
|
|
12727
|
+
"alibaba/wan-3.0-prime"
|
|
12728
|
+
]);
|
|
12683
12729
|
function isWan(providerModelId) {
|
|
12684
12730
|
return WAN_MODEL_IDS.has(providerModelId.toLowerCase());
|
|
12685
12731
|
}
|