@shop-os/modelkit 0.1.7 → 0.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -35,6 +35,23 @@ var Catalog = class _Catalog {
35
35
  for (const model of models) this.add(model);
36
36
  }
37
37
  add(model) {
38
+ if (this.byId.has(model.id)) {
39
+ throw new Error(`Duplicate model id "${model.id}"`);
40
+ }
41
+ if (this.byAlias.has(model.id)) {
42
+ throw new Error(
43
+ `Model id "${model.id}" collides with an alias of "${this.byAlias.get(model.id)}"`
44
+ );
45
+ }
46
+ for (const alias of model.aliases) {
47
+ if (alias === model.id) {
48
+ throw new Error(`Alias "${alias}" collides with its own model id "${model.id}"`);
49
+ }
50
+ const existing = this.byAlias.get(alias);
51
+ if (existing !== void 0) {
52
+ throw new Error(`Duplicate alias "${alias}" (already maps to "${existing}")`);
53
+ }
54
+ }
38
55
  this.byId.set(model.id, model);
39
56
  this.byAlias.set(model.id, model.id);
40
57
  for (const alias of model.aliases) this.byAlias.set(alias, model.id);
@@ -97,7 +114,7 @@ var GEMINI_RATIOS = [
97
114
  "5:4",
98
115
  "adaptive"
99
116
  ];
100
- function geminiImage(id, label, aliases, sizes, display) {
117
+ function geminiImage(id, label, aliases, sizes, display, exposure) {
101
118
  const model = {
102
119
  id,
103
120
  aliases,
@@ -106,6 +123,7 @@ function geminiImage(id, label, aliases, sizes, display) {
106
123
  adapter: "google-image",
107
124
  providerModelId: id,
108
125
  lifecycle: "active",
126
+ exposure,
109
127
  constraints: {
110
128
  aspectRatios: [...GEMINI_RATIOS],
111
129
  sizes,
@@ -120,14 +138,21 @@ function geminiImage(id, label, aliases, sizes, display) {
120
138
  return model;
121
139
  }
122
140
  var IMAGE_MODELS = [
123
- geminiImage("gemini-3-pro-image-preview", "Nano Banana Pro", ["nb-pro"], ["1K", "2K", "4K"], {
124
- provider: "google",
125
- description: "Create stunning, production-quality visuals with exceptional realism, detail, and typography. Best for campaigns, e-commerce, product photography, and hero creatives.",
126
- logo: "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/192485d2-a76a-4657-9c06-930b2c70badd_compressed.png"
127
- }),
141
+ geminiImage(
142
+ "gemini-3-pro-image-preview",
143
+ "Nano Banana Pro",
144
+ ["nb-pro"],
145
+ ["1K", "2K", "4K"],
146
+ {
147
+ provider: "google",
148
+ description: "Create stunning, production-quality visuals with exceptional realism, detail, and typography. Best for campaigns, e-commerce, product photography, and hero creatives.",
149
+ logo: "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/192485d2-a76a-4657-9c06-930b2c70badd_compressed.png"
150
+ },
151
+ "catalog"
152
+ ),
128
153
  geminiImage(
129
154
  "gemini-3.1-flash-image-preview",
130
- "Nano Banana Flash",
155
+ "Nano Banana 2",
131
156
  ["nb-2"],
132
157
  // Flash 3.1 is the only Gemini image model with the 512 tier.
133
158
  ["512", "1K", "2K", "4K"],
@@ -135,30 +160,47 @@ var IMAGE_MODELS = [
135
160
  provider: "google",
136
161
  description: "Generate high-quality images at speed. Perfect for brainstorming, moodboards, concept testing, creative exploration, and large batch workflows.",
137
162
  logo: "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/192485d2-a76a-4657-9c06-930b2c70badd_compressed.png"
138
- }
163
+ },
164
+ "catalog"
165
+ ),
166
+ geminiImage(
167
+ "gemini-3.1-flash-lite-image",
168
+ "Nano Banana Lite",
169
+ ["nb-lite"],
170
+ ["1K"],
171
+ {
172
+ provider: "google",
173
+ description: "The fastest and most affordable image model. Ideal for rapid drafts, bulk exploration, and iterative concept testing at 1K resolution.",
174
+ logo: "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/192485d2-a76a-4657-9c06-930b2c70badd_compressed.png"
175
+ },
176
+ "catalog"
139
177
  ),
140
- geminiImage("gemini-3.1-flash-lite-image", "Nano Banana Lite", ["nb-lite"], ["1K"], {
141
- provider: "google",
142
- description: "The fastest and most affordable image model. Ideal for rapid drafts, bulk exploration, and iterative concept testing at 1K resolution.",
143
- logo: "https://d31vvfpk2ppdyq.cloudfront.net/assets/image/192485d2-a76a-4657-9c06-930b2c70badd_compressed.png"
144
- }),
145
178
  // trigger-workflows validates 1K only; pricing seeds 2K/4K rows so allow all three.
146
- geminiImage("gemini-2.5-flash-image", "Gemini 2.5 Flash Image", [], ["1K", "2K", "4K"], {
147
- provider: "google",
148
- description: "Nano Banana (legacy Gemini 2.5 Flash Image) native image generation and editing model for high-volume, low-latency creative workflows."
149
- }),
179
+ geminiImage(
180
+ "gemini-2.5-flash-image",
181
+ "Gemini 2.5 Flash Image",
182
+ [],
183
+ ["1K", "2K", "4K"],
184
+ {
185
+ provider: "google",
186
+ description: "Nano Banana (legacy Gemini 2.5 Flash Image) native image generation and editing model for high-volume, low-latency creative workflows."
187
+ },
188
+ "internal"
189
+ ),
150
190
  {
151
191
  // Cowork "auto" lets OpenAI pick the size; the canonical equivalent is adaptive.
152
192
  id: "gpt-image-2",
153
193
  aliases: [],
154
- label: "GPT Image 2",
194
+ label: "GPT-image-2",
155
195
  type: "image",
156
196
  adapter: "openai-image",
157
197
  providerModelId: "gpt-image-2",
158
198
  lifecycle: "active",
199
+ exposure: "catalog",
159
200
  constraints: {
160
201
  aspectRatios: ["1:1", "3:2", "2:3", "16:9", "9:16", "4:5", "5:4", "adaptive"],
161
202
  sizes: ["1K", "2K", "4K"],
203
+ qualityOptions: ["auto", "low", "medium", "high"],
162
204
  references: { images: 16 },
163
205
  supports: ["quality", "count"]
164
206
  },
@@ -181,9 +223,11 @@ var IMAGE_MODELS = [
181
223
  adapter: "openai-image",
182
224
  providerModelId: "gpt-image-2.5-sunburst",
183
225
  lifecycle: "active",
226
+ exposure: "internal",
184
227
  constraints: {
185
228
  aspectRatios: ["1:1", "3:2", "2:3", "16:9", "9:16", "4:5", "5:4", "adaptive"],
186
229
  sizes: ["1K", "2K", "4K"],
230
+ qualityOptions: ["auto", "low", "medium", "high"],
187
231
  references: { images: 16 },
188
232
  supports: ["quality", "count"]
189
233
  },
@@ -205,9 +249,11 @@ var IMAGE_MODELS = [
205
249
  adapter: "openai-image",
206
250
  providerModelId: "gpt-image-2.5-flare",
207
251
  lifecycle: "active",
252
+ exposure: "internal",
208
253
  constraints: {
209
254
  aspectRatios: ["1:1", "3:2", "2:3", "16:9", "9:16", "4:5", "5:4", "adaptive"],
210
255
  sizes: ["1K", "2K", "4K"],
256
+ qualityOptions: ["auto", "low", "medium", "high"],
211
257
  references: { images: 16 },
212
258
  supports: ["quality", "count"]
213
259
  },
@@ -223,12 +269,13 @@ var IMAGE_MODELS = [
223
269
  {
224
270
  // Cowork allows 7 ratios; trigger-workflows allows 9 (adds 3:2, 9:21, drops 4:5/5:4).
225
271
  id: "muse-image-1.0",
226
- aliases: [],
272
+ aliases: ["meta-muse"],
227
273
  label: "Meta Muse",
228
274
  type: "image",
229
275
  adapter: "fal",
230
276
  providerModelId: "muse-image-1.0",
231
277
  lifecycle: "active",
278
+ exposure: "catalog",
232
279
  constraints: {
233
280
  aspectRatios: [
234
281
  "21:9",
@@ -266,6 +313,7 @@ var IMAGE_MODELS = [
266
313
  adapter: "ark",
267
314
  providerModelId: "dola-seedream-5-0-pro-260628",
268
315
  lifecycle: "active",
316
+ exposure: "catalog",
269
317
  constraints: {
270
318
  aspectRatios: ["1:1", "4:3", "3:4", "16:9", "9:16", "3:2", "2:3", "21:9", "4:5", "5:4"],
271
319
  sizes: ["1K", "2K"],
@@ -291,6 +339,7 @@ var IMAGE_MODELS = [
291
339
  adapter: "ark",
292
340
  providerModelId: "seedream-4-5-251128",
293
341
  lifecycle: "active",
342
+ exposure: "internal",
294
343
  constraints: {
295
344
  // 97:30 has no Ark size spelling; the A+ flow pads inputs to 97:30 and
296
345
  // omits the ratio instead. Advertise only sizes the adapter can send.
@@ -328,6 +377,7 @@ var IMAGE_MODELS = [
328
377
  adapter: "prodia",
329
378
  providerModelId: "flux-2-pro",
330
379
  lifecycle: "active",
380
+ exposure: "catalog",
331
381
  constraints: {
332
382
  aspectRatios: ["1:1", "2:3", "3:2", "16:9", "9:16", "4:3", "3:4", "4:5", "5:4", "21:9"],
333
383
  sizes: ["1K"],
@@ -354,6 +404,7 @@ var IMAGE_MODELS = [
354
404
  adapter: "prodia",
355
405
  providerModelId: "inference.gemini-3-pro.img2img.v1",
356
406
  lifecycle: "active",
407
+ exposure: "internal",
357
408
  constraints: {
358
409
  aspectRatios: ["1:1", "2:3", "3:2", "4:3", "3:4", "4:5", "5:4", "9:16", "16:9", "21:9"],
359
410
  sizes: ["1K", "2K", "4K"],
@@ -379,6 +430,7 @@ var IMAGE_MODELS = [
379
430
  adapter: "prodia",
380
431
  providerModelId: "inference.nano-banana.img2img.v2",
381
432
  lifecycle: "active",
433
+ exposure: "internal",
382
434
  constraints: {
383
435
  aspectRatios: ["1:1", "2:3", "3:4", "4:3", "9:16", "16:9", "21:9"],
384
436
  sizes: ["1K"],
@@ -405,6 +457,7 @@ var IMAGE_MODELS = [
405
457
  adapter: "replicate",
406
458
  providerModelId: "wan-video/wan-2.7-image-pro",
407
459
  lifecycle: "active",
460
+ exposure: "internal",
408
461
  constraints: {
409
462
  aspectRatios: ["1:1", "16:9", "9:16", "4:3", "3:4"],
410
463
  sizes: ["1K", "2K", "4K"],
@@ -431,6 +484,7 @@ var IMAGE_MODELS = [
431
484
  adapter: "replicate",
432
485
  providerModelId: "qwen/qwen-image-2-pro",
433
486
  lifecycle: "active",
487
+ exposure: "internal",
434
488
  constraints: {
435
489
  aspectRatios: ["1:1", "16:9", "9:16", "4:3", "3:4", "3:2", "2:3"],
436
490
  sizes: [],
@@ -458,6 +512,7 @@ var IMAGE_MODELS = [
458
512
  adapter: "replicate",
459
513
  providerModelId: "qwen-edit-apps/qwen-image-edit-plus-lora-skin",
460
514
  lifecycle: "active",
515
+ exposure: "internal",
461
516
  constraints: {
462
517
  aspectRatios: ["1:1", "16:9", "9:16", "4:3", "3:4"],
463
518
  sizes: [],
@@ -486,6 +541,7 @@ var OTHER_MODELS = [
486
541
  adapter: "google-genai",
487
542
  providerModelId: "lyria-3-clip-preview",
488
543
  lifecycle: "active",
544
+ exposure: "catalog",
489
545
  constraints: {
490
546
  durations: [30],
491
547
  references: { images: 10 },
@@ -497,7 +553,8 @@ var OTHER_MODELS = [
497
553
  display: {
498
554
  provider: "google",
499
555
  description: "Google Lyria 3 Clip short music clips, loops, and previews; takes text and up to 10 image prompts and returns a fixed 30-second MP3 plus lyrics."
500
- }
556
+ },
557
+ capabilities: {}
501
558
  },
502
559
  {
503
560
  id: "lyria-3-pro-preview",
@@ -507,6 +564,7 @@ var OTHER_MODELS = [
507
564
  adapter: "google-genai",
508
565
  providerModelId: "lyria-3-pro-preview",
509
566
  lifecycle: "active",
567
+ exposure: "catalog",
510
568
  constraints: {
511
569
  references: { images: 10 },
512
570
  supports: []
@@ -517,7 +575,8 @@ var OTHER_MODELS = [
517
575
  display: {
518
576
  provider: "google",
519
577
  description: "Google Lyria 3 Pro flagship music model for full-length songs with verses, choruses, and bridges; takes text and up to 10 image prompts and returns MP3 plus lyrics."
520
- }
578
+ },
579
+ capabilities: {}
521
580
  },
522
581
  {
523
582
  id: "google/lyria-2",
@@ -527,6 +586,7 @@ var OTHER_MODELS = [
527
586
  adapter: "replicate",
528
587
  providerModelId: "google/lyria-2",
529
588
  lifecycle: "active",
589
+ exposure: "internal",
530
590
  constraints: {
531
591
  durations: [30],
532
592
  supports: ["seed", "negativePrompt"]
@@ -537,7 +597,8 @@ var OTHER_MODELS = [
537
597
  display: {
538
598
  provider: "google",
539
599
  description: "Lyria 2 music generation on Replicate; produces 30 seconds of 48 kHz stereo audio from a text prompt."
540
- }
600
+ },
601
+ capabilities: {}
541
602
  },
542
603
  {
543
604
  id: "mmaudio",
@@ -547,6 +608,7 @@ var OTHER_MODELS = [
547
608
  adapter: "replicate",
548
609
  providerModelId: "zsxkib/mmaudio:62871fb59889b2d7c13777f08deb3b36bdff88f7e1d53a50ad7694548a41b484",
549
610
  lifecycle: "active",
611
+ exposure: "catalog",
550
612
  constraints: {
551
613
  durations: { min: 1, max: 30 },
552
614
  requires: ["sourceVideo"],
@@ -558,7 +620,8 @@ var OTHER_MODELS = [
558
620
  display: {
559
621
  provider: "mmaudio",
560
622
  description: "MMAudio V2 video-to-audio model on Replicate; takes a source video and prompt and synthesizes synchronized environmental, action, and speech-like audio."
561
- }
623
+ },
624
+ capabilities: {}
562
625
  },
563
626
  {
564
627
  id: "elevenlabs-music",
@@ -568,6 +631,7 @@ var OTHER_MODELS = [
568
631
  adapter: "replicate",
569
632
  providerModelId: "elevenlabs/music",
570
633
  lifecycle: "active",
634
+ exposure: "internal",
571
635
  constraints: {
572
636
  durations: { min: 5, max: 300 },
573
637
  supports: ["instrumental"]
@@ -579,7 +643,8 @@ var OTHER_MODELS = [
579
643
  display: {
580
644
  provider: "elevenlabs",
581
645
  description: "ElevenLabs Music text-to-music on Replicate; generates full songs, instrumental or with vocals, up to 5 minutes long at up to 44.1 kHz."
582
- }
646
+ },
647
+ capabilities: {}
583
648
  },
584
649
  {
585
650
  id: "topaz",
@@ -589,6 +654,7 @@ var OTHER_MODELS = [
589
654
  adapter: "replicate",
590
655
  providerModelId: "topazlabs/image-upscale",
591
656
  lifecycle: "active",
657
+ exposure: "catalog",
592
658
  constraints: {
593
659
  references: { images: 1 },
594
660
  requires: ["references"],
@@ -611,6 +677,7 @@ var OTHER_MODELS = [
611
677
  adapter: "prodia",
612
678
  providerModelId: "inference.remove-background.v1",
613
679
  lifecycle: "active",
680
+ exposure: "catalog",
614
681
  constraints: {
615
682
  references: { images: 1 },
616
683
  requires: ["references"],
@@ -638,6 +705,7 @@ function text(id, label, providerModelId, extra) {
638
705
  adapter: "ai-sdk-text",
639
706
  providerModelId,
640
707
  lifecycle: "active",
708
+ exposure: "internal",
641
709
  constraints: { supports: [] },
642
710
  defaults: {},
643
711
  usage: { ...TEXT_USAGE },
@@ -647,37 +715,47 @@ function text(id, label, providerModelId, extra) {
647
715
  }
648
716
  var TEXT_MODELS = [
649
717
  text("gpt-4o", "GPT-4o", "gpt-4o", {
718
+ exposure: "internal",
650
719
  display: {
651
720
  provider: "openai",
721
+ costTier: 2,
652
722
  description: "OpenAI GPT-4o flagship multimodal model; text and image input, 128K-token context."
653
723
  },
654
724
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 128e3 }
655
725
  }),
656
726
  text("gpt-4o-mini", "GPT-4o mini", "gpt-4o-mini", {
727
+ exposure: "internal",
657
728
  display: {
658
729
  provider: "openai",
730
+ costTier: 1,
659
731
  description: "OpenAI GPT-4o mini fast, low-cost multimodal model; text and image input, 128K-token context."
660
732
  },
661
733
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 128e3 }
662
734
  }),
663
735
  text("gpt-5.1", "GPT-5.1", "gpt-5.1", {
736
+ exposure: "catalog",
664
737
  display: {
665
738
  provider: "openai",
739
+ costTier: 3,
666
740
  description: "OpenAI GPT-5.1 reasoning model for coding and agentic tasks; text and image input, 400K-token context."
667
741
  },
668
742
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 4e5 }
669
743
  }),
670
744
  text("gpt-5.2", "GPT-5.2", "gpt-5.2", {
745
+ exposure: "catalog",
671
746
  display: {
672
747
  provider: "openai",
748
+ costTier: 3,
673
749
  description: "OpenAI GPT-5.2 reasoning model for complex professional work; text and image input, 400K-token context."
674
750
  },
675
751
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 4e5 }
676
752
  }),
677
753
  // 1.05M-token context: https://platform.openai.com/docs/models/gpt-5.4
678
754
  text("gpt-5.4", "GPT-5.4", "gpt-5.4", {
755
+ exposure: "internal",
679
756
  display: {
680
757
  provider: "openai",
758
+ costTier: 3,
681
759
  description: "OpenAI GPT-5.4 flagship reasoning model; text and image input, 1.05M-token context."
682
760
  },
683
761
  capabilities: {
@@ -689,16 +767,20 @@ var TEXT_MODELS = [
689
767
  }),
690
768
  // OpenAI never shipped gpt-5.1-mini or gpt-5.2-mini; callers that still send them get 5.4 mini.
691
769
  text("gpt-5.4-mini", "GPT-5.4 mini", "gpt-5.4-mini", {
770
+ exposure: "catalog",
692
771
  aliases: ["gpt-5.1-mini", "gpt-5.2-mini"],
693
772
  display: {
694
773
  provider: "openai",
774
+ costTier: 1,
695
775
  description: "OpenAI GPT-5.4 mini efficient reasoning model for high-volume workloads; text and image input, 400K-token context."
696
776
  },
697
777
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 4e5 }
698
778
  }),
699
779
  text("gpt-5.5", "GPT-5.5", "gpt-5.5", {
780
+ exposure: "catalog",
700
781
  display: {
701
782
  provider: "openai",
783
+ costTier: 3,
702
784
  description: "OpenAI GPT-5.5 flagship reasoning model for the most complex professional and coding work; text and image input, 1.05M-token context."
703
785
  },
704
786
  capabilities: {
@@ -709,8 +791,10 @@ var TEXT_MODELS = [
709
791
  }
710
792
  }),
711
793
  text("gpt-5.6-luna", "GPT-5.6 Luna", "gpt-5.6-luna", {
794
+ exposure: "catalog",
712
795
  display: {
713
796
  provider: "openai",
797
+ costTier: 1,
714
798
  description: "OpenAI GPT-5.6 Luna cost-optimized tier of the GPT-5.6 reasoning family; text and image input, 1.05M-token context."
715
799
  },
716
800
  capabilities: {
@@ -721,8 +805,10 @@ var TEXT_MODELS = [
721
805
  }
722
806
  }),
723
807
  text("gpt-5.6-terra", "GPT-5.6 Terra", "gpt-5.6-terra", {
808
+ exposure: "catalog",
724
809
  display: {
725
810
  provider: "openai",
811
+ costTier: 2,
726
812
  description: "OpenAI GPT-5.6 Terra balanced tier of the GPT-5.6 reasoning family; text and image input, 1.05M-token context."
727
813
  },
728
814
  capabilities: {
@@ -733,8 +819,10 @@ var TEXT_MODELS = [
733
819
  }
734
820
  }),
735
821
  text("gpt-5.6-sol", "GPT-5.6 Sol", "gpt-5.6-sol", {
822
+ exposure: "catalog",
736
823
  display: {
737
824
  provider: "openai",
825
+ costTier: 3,
738
826
  description: "OpenAI GPT-5.6 Sol flagship tier of the GPT-5.6 reasoning family; text and image input, 1.05M-token context."
739
827
  },
740
828
  capabilities: {
@@ -746,15 +834,18 @@ var TEXT_MODELS = [
746
834
  }),
747
835
  // Library key "claude-sonnet-4.5" maps to the SDK id "claude-sonnet-4-5".
748
836
  text("claude-sonnet-4-5", "Claude Sonnet 4.5", "claude-sonnet-4-5", {
837
+ exposure: "internal",
749
838
  aliases: ["claude-sonnet-4.5", "claude-sonnet-4-5-20250929"],
750
839
  display: {
751
840
  provider: "anthropic",
841
+ costTier: 2,
752
842
  description: "Anthropic Claude Sonnet 4.5 (legacy) balanced model; text and image input, 200K-token context."
753
843
  },
754
844
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 2e5 }
755
845
  }),
756
846
  // Anthropic retired the dated 4.0 ids; callers that still send them get 4.6.
757
847
  text("claude-sonnet-4-6", "Claude Sonnet 4.6", "claude-sonnet-4-6", {
848
+ exposure: "catalog",
758
849
  aliases: [
759
850
  "claude-sonnet-4.6",
760
851
  "claude-sonnet-4",
@@ -763,6 +854,7 @@ var TEXT_MODELS = [
763
854
  ],
764
855
  display: {
765
856
  provider: "anthropic",
857
+ costTier: 2,
766
858
  description: "Anthropic Claude Sonnet 4.6 (legacy) balanced model; text and image input, 1M-token context."
767
859
  },
768
860
  capabilities: {
@@ -773,8 +865,10 @@ var TEXT_MODELS = [
773
865
  }
774
866
  }),
775
867
  text("claude-sonnet-5", "Claude Sonnet 5", "claude-sonnet-5", {
868
+ exposure: "catalog",
776
869
  display: {
777
870
  provider: "anthropic",
871
+ costTier: 3,
778
872
  description: "Anthropic Claude Sonnet 5 current balanced model; text and image input, 1M-token context."
779
873
  },
780
874
  capabilities: {
@@ -785,9 +879,11 @@ var TEXT_MODELS = [
785
879
  }
786
880
  }),
787
881
  text("claude-opus-4-8", "Claude Opus 4.8", "claude-opus-4-8", {
882
+ exposure: "catalog",
788
883
  aliases: ["claude-opus-4.8", "claude-opus-4", "claude-opus-4.0", "claude-opus-4-20250514"],
789
884
  display: {
790
885
  provider: "anthropic",
886
+ costTier: 3,
791
887
  description: "Anthropic Claude Opus 4.8 (legacy) frontier model; text and image input, 1M-token context."
792
888
  },
793
889
  capabilities: {
@@ -798,17 +894,21 @@ var TEXT_MODELS = [
798
894
  }
799
895
  }),
800
896
  text("claude-haiku-4-5", "Claude Haiku 4.5", "claude-haiku-4-5", {
897
+ exposure: "catalog",
801
898
  aliases: ["claude-haiku-4.5", "claude-haiku-4-5-20251001", "claude-haiku-4"],
802
899
  display: {
803
900
  provider: "anthropic",
901
+ costTier: 1,
804
902
  description: "Anthropic Claude Haiku 4.5 fast model with near-frontier intelligence; text and image input, 200K-token context."
805
903
  },
806
904
  capabilities: { vision: true, tools: true, structuredOutput: true, contextWindow: 2e5 }
807
905
  }),
808
906
  text("claude-opus-5", "Claude Opus 5", "claude-opus-5", {
907
+ exposure: "internal",
809
908
  aliases: ["claude-opus-5.0"],
810
909
  display: {
811
910
  provider: "anthropic",
911
+ costTier: 3,
812
912
  description: "Anthropic Claude Opus 5 current frontier model for agentic coding and enterprise work; text and image input, 1M-token context."
813
913
  },
814
914
  capabilities: {
@@ -819,8 +919,10 @@ var TEXT_MODELS = [
819
919
  }
820
920
  }),
821
921
  text("claude-fable-5", "Claude Fable 5", "claude-fable-5", {
922
+ exposure: "internal",
822
923
  display: {
823
924
  provider: "anthropic",
925
+ costTier: 3,
824
926
  description: "Anthropic Claude Fable 5 (legacy) model for demanding reasoning and long-horizon agentic work; text and image input, 1M-token context."
825
927
  },
826
928
  capabilities: {
@@ -831,8 +933,10 @@ var TEXT_MODELS = [
831
933
  }
832
934
  }),
833
935
  text("gemini-2.5-flash", "Gemini 2.5 Flash", "gemini-2.5-flash", {
936
+ exposure: "internal",
834
937
  display: {
835
938
  provider: "google",
939
+ costTier: 1,
836
940
  description: "Google Gemini 2.5 Flash low-latency multimodal model for high-volume reasoning over text, images, video, and audio; 1M-token context."
837
941
  },
838
942
  capabilities: {
@@ -843,8 +947,10 @@ var TEXT_MODELS = [
843
947
  }
844
948
  }),
845
949
  text("gemini-2.5-pro", "Gemini 2.5 Pro", "gemini-2.5-pro", {
950
+ exposure: "internal",
846
951
  display: {
847
952
  provider: "google",
953
+ costTier: 2,
848
954
  description: "Google Gemini 2.5 Pro thinking model for complex reasoning over code, math, and documents; text, image, video, audio, and PDF input, 1M-token context."
849
955
  },
850
956
  capabilities: {
@@ -855,8 +961,10 @@ var TEXT_MODELS = [
855
961
  }
856
962
  }),
857
963
  text("gemini-3.1-pro-preview", "Gemini 3.1 Pro (preview)", "gemini-3.1-pro-preview", {
964
+ exposure: "catalog",
858
965
  display: {
859
966
  provider: "google",
967
+ costTier: 2,
860
968
  description: "Google Gemini 3.1 Pro preview reasoning model for software engineering, tool use, and reliable agentic workflows; 1M-token context."
861
969
  },
862
970
  capabilities: {
@@ -867,8 +975,10 @@ var TEXT_MODELS = [
867
975
  }
868
976
  }),
869
977
  text("gemini-3.5-flash", "Gemini 3.5 Flash", "gemini-3.5-flash", {
978
+ exposure: "catalog",
870
979
  display: {
871
980
  provider: "google",
981
+ costTier: 1,
872
982
  description: "Google Gemini 3.5 Flash high-throughput model for frontier-level agentic tasks; text, image, video, audio, and PDF input, 1M-token context."
873
983
  },
874
984
  capabilities: {
@@ -879,8 +989,10 @@ var TEXT_MODELS = [
879
989
  }
880
990
  }),
881
991
  text("gemini-3.6-flash", "Gemini 3.6 Flash", "gemini-3.6-flash", {
992
+ exposure: "catalog",
882
993
  display: {
883
994
  provider: "google",
995
+ costTier: 1,
884
996
  description: "Google Gemini 3.6 Flash general-purpose multimodal agentic model balancing speed and capability; 1M-token context."
885
997
  },
886
998
  capabilities: {
@@ -891,8 +1003,11 @@ var TEXT_MODELS = [
891
1003
  }
892
1004
  }),
893
1005
  text("gemini-3.7-flash", "Gemini 3.7 Flash", "gemini-3.7-flash", {
1006
+ exposure: "catalog",
894
1007
  display: {
895
1008
  provider: "google",
1009
+ costTier: 1,
1010
+ recommended: true,
896
1011
  description: "Google Gemini 3.7 Flash natively multimodal reasoning model for coding, agentic workflows, and multi-step execution; 1M-token context."
897
1012
  },
898
1013
  capabilities: {
@@ -903,8 +1018,10 @@ var TEXT_MODELS = [
903
1018
  }
904
1019
  }),
905
1020
  text("gemini-3.8-flash", "Gemini 3.8 Flash", "gemini-3.8-flash", {
1021
+ exposure: "internal",
906
1022
  display: {
907
1023
  provider: "google",
1024
+ costTier: 1,
908
1025
  description: "Google Gemini 3.8 Flash frontier model for long-horizon software engineering, autonomous agents, and enterprise workflows; 1M-token context."
909
1026
  },
910
1027
  capabilities: {
@@ -916,12 +1033,15 @@ var TEXT_MODELS = [
916
1033
  }),
917
1034
  // Renamed to gemini-3.6-flash in vibe-shared model-migration.ts.
918
1035
  text("gemini-3-flash-preview", "Gemini 3 Flash (preview)", "gemini-3-flash-preview", {
1036
+ exposure: "internal",
919
1037
  lifecycle: "deprecated",
920
1038
  replacedBy: "gemini-3.6-flash"
921
1039
  }),
922
1040
  text("gemini-3.1-flash-lite", "Gemini 3.1 Flash Lite", "gemini-3.1-flash-lite", {
1041
+ exposure: "internal",
923
1042
  display: {
924
1043
  provider: "google",
1044
+ costTier: 1,
925
1045
  description: "Google Gemini 3.1 Flash-Lite low-latency multimodal model for high-volume agentic, translation, and data-extraction tasks; 1M-token context."
926
1046
  },
927
1047
  capabilities: {
@@ -932,8 +1052,10 @@ var TEXT_MODELS = [
932
1052
  }
933
1053
  }),
934
1054
  text("sonar", "Sonar", "sonar", {
1055
+ exposure: "internal",
935
1056
  display: {
936
1057
  provider: "perplexity",
1058
+ costTier: 1,
937
1059
  description: "Perplexity Sonar lightweight web-grounded search model returning cited answers; 128K-token context."
938
1060
  },
939
1061
  capabilities: {
@@ -944,8 +1066,10 @@ var TEXT_MODELS = [
944
1066
  }
945
1067
  }),
946
1068
  text("sonar-pro", "Sonar Pro", "sonar-pro", {
1069
+ exposure: "internal",
947
1070
  display: {
948
1071
  provider: "perplexity",
1072
+ costTier: 2,
949
1073
  description: "Perplexity Sonar Pro advanced web-grounded search model for complex multi-step queries; 200K-token context."
950
1074
  },
951
1075
  capabilities: {
@@ -956,8 +1080,10 @@ var TEXT_MODELS = [
956
1080
  }
957
1081
  }),
958
1082
  text("sonar-reasoning-pro", "Sonar Reasoning Pro", "sonar-reasoning-pro", {
1083
+ exposure: "internal",
959
1084
  display: {
960
1085
  provider: "perplexity",
1086
+ costTier: 2,
961
1087
  description: "Perplexity Sonar Reasoning Pro chain-of-thought web-grounded search model for complex problem-solving; 128K-token context."
962
1088
  },
963
1089
  capabilities: {
@@ -968,8 +1094,11 @@ var TEXT_MODELS = [
968
1094
  }
969
1095
  }),
970
1096
  text("deepseek-v4-flash", "DeepSeek V4 Flash", "deepseek-v4-flash", {
1097
+ exposure: "catalog",
971
1098
  display: {
972
1099
  provider: "deepseek",
1100
+ costTier: 1,
1101
+ recommended: true,
973
1102
  description: "DeepSeek V4 Flash thinking/non-thinking model with vision, tool calls, and JSON output; 1M-token context and up to 384K output tokens."
974
1103
  },
975
1104
  capabilities: {
@@ -980,8 +1109,10 @@ var TEXT_MODELS = [
980
1109
  }
981
1110
  }),
982
1111
  text("deepseek-v4-pro", "DeepSeek V4 Pro", "deepseek-v4-pro", {
1112
+ exposure: "catalog",
983
1113
  display: {
984
1114
  provider: "deepseek",
1115
+ costTier: 2,
985
1116
  description: "DeepSeek V4 Pro thinking/non-thinking text model with tool calls and JSON output (no vision); 1M-token context and up to 384K output tokens."
986
1117
  },
987
1118
  capabilities: {
@@ -993,8 +1124,10 @@ var TEXT_MODELS = [
993
1124
  }),
994
1125
  // 1M-token context: https://docs.x.ai/docs/models/grok-4.3
995
1126
  text("grok-4.3", "Grok 4.3", "grok-4.3", {
1127
+ exposure: "catalog",
996
1128
  display: {
997
1129
  provider: "xai",
1130
+ costTier: 2,
998
1131
  description: "xAI Grok 4.3 reasoning model with tool calling and structured outputs; text and image input, 1M-token context."
999
1132
  },
1000
1133
  capabilities: {
@@ -1006,15 +1139,19 @@ var TEXT_MODELS = [
1006
1139
  }),
1007
1140
  // Moonshot retired kimi-k2.5 on 2026-08-31 and no longer publishes its specs.
1008
1141
  text("kimi-k2.5", "Kimi K2.5", "kimi-k2.5", {
1142
+ exposure: "catalog",
1009
1143
  display: {
1010
1144
  provider: "moonshot",
1145
+ costTier: 2,
1011
1146
  description: "Moonshot Kimi K2.5; the provider retired the model on 2026-08-31 and calls now return a model-not-found error."
1012
1147
  },
1013
1148
  capabilities: {}
1014
1149
  }),
1015
1150
  text("kimi-k3", "Kimi K3", "kimi-k3", {
1151
+ exposure: "catalog",
1016
1152
  display: {
1017
1153
  provider: "moonshot",
1154
+ costTier: 2,
1018
1155
  description: "Moonshot Kimi K3 flagship model with native visual understanding and always-on thinking; text, image, and video input, 1M-token context."
1019
1156
  },
1020
1157
  capabilities: {
@@ -1027,9 +1164,11 @@ var TEXT_MODELS = [
1027
1164
  // Cowork calls the provider "MiniMax-M3"; the pricing key is lowercase.
1028
1165
  // 1M-token context: https://platform.minimax.io/docs/api-reference/text-openai-api
1029
1166
  text("minimax-m3", "MiniMax M3", "MiniMax-M3", {
1167
+ exposure: "catalog",
1030
1168
  aliases: ["MiniMax-M3"],
1031
1169
  display: {
1032
1170
  provider: "minimax",
1171
+ costTier: 2,
1033
1172
  description: "MiniMax M3 frontier multimodal model for agentic reasoning, tool use, and coding; text, image, and video input, 1M-token context."
1034
1173
  },
1035
1174
  capabilities: { vision: true, tools: true, contextWindow: 1e6 }
@@ -1061,6 +1200,7 @@ var VIDEO_MODELS = [
1061
1200
  adapter: "google-genai",
1062
1201
  providerModelId: "veo-3.1-generate-preview",
1063
1202
  lifecycle: "active",
1203
+ exposure: "catalog",
1064
1204
  constraints: {
1065
1205
  aspectRatios: [...OMNI_RATIOS],
1066
1206
  resolutions: ["720p", "1080p", "4k"],
@@ -1090,6 +1230,7 @@ var VIDEO_MODELS = [
1090
1230
  adapter: "google-genai",
1091
1231
  providerModelId: "veo-3.1-fast-generate-preview",
1092
1232
  lifecycle: "active",
1233
+ exposure: "internal",
1093
1234
  constraints: {
1094
1235
  aspectRatios: [...OMNI_RATIOS],
1095
1236
  resolutions: ["720p", "1080p", "4k"],
@@ -1118,9 +1259,10 @@ var VIDEO_MODELS = [
1118
1259
  adapter: "google-genai",
1119
1260
  providerModelId: "veo-3.1-lite-generate-preview",
1120
1261
  lifecycle: "active",
1262
+ exposure: "internal",
1121
1263
  constraints: {
1122
1264
  aspectRatios: [...OMNI_RATIOS],
1123
- resolutions: ["720p", "1080p", "4k"],
1265
+ resolutions: ["720p", "1080p"],
1124
1266
  durations: [4, 8],
1125
1267
  references: { images: 3 },
1126
1268
  supports: ["lastFrame"]
@@ -1148,6 +1290,7 @@ var VIDEO_MODELS = [
1148
1290
  adapter: "google-genai",
1149
1291
  providerModelId: "gemini-omni-flash-preview",
1150
1292
  lifecycle: "active",
1293
+ exposure: "catalog",
1151
1294
  constraints: {
1152
1295
  // 1.0 rejects `resolution`; it renders 720p. No defaults: the adapter
1153
1296
  // sends ratio and duration only when the caller set them, so a
@@ -1175,6 +1318,7 @@ var VIDEO_MODELS = [
1175
1318
  adapter: "google-genai",
1176
1319
  providerModelId: "gemini-omni-1.1-flash",
1177
1320
  lifecycle: "active",
1321
+ exposure: "catalog",
1178
1322
  constraints: {
1179
1323
  aspectRatios: [...OMNI_RATIOS],
1180
1324
  resolutions: ["360p", "720p", "1080p", "4k"],
@@ -1200,10 +1344,12 @@ var VIDEO_MODELS = [
1200
1344
  adapter: "ark",
1201
1345
  providerModelId: "dreamina-seedance-2-0-260128",
1202
1346
  lifecycle: "active",
1347
+ exposure: "catalog",
1203
1348
  constraints: {
1204
1349
  aspectRatios: [...SEEDANCE_RATIOS],
1205
1350
  resolutions: ["480p", "720p", "1080p", "4k"],
1206
1351
  durations: [4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15],
1352
+ durationPresets: [4, 6, 8, 10, 12, 15],
1207
1353
  references: { images: 9, videos: 3, audios: 3, audioOnly: false },
1208
1354
  ratioIgnoredWith: ["firstFrame"],
1209
1355
  supports: ["generateAudio", "seed", "lastFrame", "watermark"]
@@ -1231,6 +1377,7 @@ var VIDEO_MODELS = [
1231
1377
  adapter: "ark",
1232
1378
  providerModelId: "dreamina-seedance-2-0-fast-260128",
1233
1379
  lifecycle: "active",
1380
+ exposure: "catalog",
1234
1381
  constraints: {
1235
1382
  aspectRatios: [...SEEDANCE_RATIOS],
1236
1383
  resolutions: ["480p", "720p"],
@@ -1262,6 +1409,7 @@ var VIDEO_MODELS = [
1262
1409
  adapter: "ark",
1263
1410
  providerModelId: "dreamina-seedance-2-5-260628",
1264
1411
  lifecycle: "active",
1412
+ exposure: "catalog",
1265
1413
  constraints: {
1266
1414
  aspectRatios: [...SEEDANCE_RATIOS],
1267
1415
  resolutions: ["480p", "720p", "1080p"],
@@ -1293,10 +1441,12 @@ var VIDEO_MODELS = [
1293
1441
  adapter: "xai-video",
1294
1442
  providerModelId: "grok-imagine-video",
1295
1443
  lifecycle: "active",
1444
+ exposure: "catalog",
1296
1445
  constraints: {
1297
1446
  aspectRatios: [...GROK_RATIOS],
1298
1447
  resolutions: ["480p", "720p"],
1299
1448
  durations: { min: 1, max: 15 },
1449
+ durationPresets: [4, 6, 8, 10],
1300
1450
  references: { images: 7 },
1301
1451
  supports: []
1302
1452
  },
@@ -1319,6 +1469,7 @@ var VIDEO_MODELS = [
1319
1469
  adapter: "higgsfield",
1320
1470
  providerModelId: "kling-video/v2.5-turbo/pro/image-to-video",
1321
1471
  lifecycle: "active",
1472
+ exposure: "catalog",
1322
1473
  constraints: {
1323
1474
  aspectRatios: [...KLING_RATIOS],
1324
1475
  durations: [5, 10],
@@ -1348,6 +1499,7 @@ var VIDEO_MODELS = [
1348
1499
  adapter: "higgsfield",
1349
1500
  providerModelId: "kling-video/v3.0/pro/image-to-video",
1350
1501
  lifecycle: "active",
1502
+ exposure: "catalog",
1351
1503
  constraints: {
1352
1504
  aspectRatios: [...KLING_RATIOS],
1353
1505
  durations: { min: 3, max: 15 },
@@ -1377,6 +1529,7 @@ var VIDEO_MODELS = [
1377
1529
  adapter: "replicate",
1378
1530
  providerModelId: "kwaivgi/kling-v3-omni-video",
1379
1531
  lifecycle: "active",
1532
+ exposure: "catalog",
1380
1533
  constraints: {
1381
1534
  aspectRatios: [
1382
1535
  "1:1",
@@ -1412,6 +1565,7 @@ var VIDEO_MODELS = [
1412
1565
  adapter: "fal",
1413
1566
  providerModelId: "minimax/h3",
1414
1567
  lifecycle: "active",
1568
+ exposure: "catalog",
1415
1569
  constraints: {
1416
1570
  aspectRatios: [...H3_RATIOS],
1417
1571
  resolutions: ["480p", "768p", "2k", "4k"],
@@ -1440,6 +1594,7 @@ var VIDEO_MODELS = [
1440
1594
  adapter: "fal",
1441
1595
  providerModelId: "minimax/h3-max",
1442
1596
  lifecycle: "active",
1597
+ exposure: "catalog",
1443
1598
  constraints: {
1444
1599
  aspectRatios: [...H3_RATIOS],
1445
1600
  resolutions: ["480p", "768p"],
@@ -1468,6 +1623,7 @@ var VIDEO_MODELS = [
1468
1623
  adapter: "fal",
1469
1624
  providerModelId: "minimax/h3/reference-to-video",
1470
1625
  lifecycle: "active",
1626
+ exposure: "catalog",
1471
1627
  constraints: {
1472
1628
  aspectRatios: [...H3_REFERENCE_RATIOS],
1473
1629
  resolutions: ["480p", "768p", "2k", "4k"],
@@ -1497,6 +1653,7 @@ var VIDEO_MODELS = [
1497
1653
  adapter: "fal",
1498
1654
  providerModelId: "minimax/h3-max/reference-to-video",
1499
1655
  lifecycle: "active",
1656
+ exposure: "catalog",
1500
1657
  constraints: {
1501
1658
  aspectRatios: [...H3_REFERENCE_RATIOS],
1502
1659
  resolutions: ["480p", "768p"],
@@ -1527,6 +1684,7 @@ var VIDEO_MODELS = [
1527
1684
  adapter: "fal",
1528
1685
  providerModelId: "fal-ai/kling-video/o1/video-to-video/reference",
1529
1686
  lifecycle: "active",
1687
+ exposure: "internal",
1530
1688
  constraints: {
1531
1689
  aspectRatios: [...KLING_RATIOS],
1532
1690
  durations: { min: 3, max: 10 },
@@ -1550,6 +1708,7 @@ var VIDEO_MODELS = [
1550
1708
  adapter: "replicate",
1551
1709
  providerModelId: "minimax/hailuo-02",
1552
1710
  lifecycle: "active",
1711
+ exposure: "internal",
1553
1712
  constraints: {
1554
1713
  resolutions: ["768p"],
1555
1714
  durations: [6, 10],
@@ -1572,6 +1731,7 @@ var VIDEO_MODELS = [
1572
1731
  adapter: "higgsfield",
1573
1732
  providerModelId: "dop-preview",
1574
1733
  lifecycle: "active",
1734
+ exposure: "internal",
1575
1735
  constraints: {
1576
1736
  requires: ["firstFrame"],
1577
1737
  supports: ["seed", "lastFrame"]
@@ -2169,6 +2329,7 @@ function passthroughTextModel(model) {
2169
2329
  adapter: "ai-sdk-text",
2170
2330
  providerModelId: model.modelId,
2171
2331
  lifecycle: "active",
2332
+ exposure: "internal",
2172
2333
  constraints: {},
2173
2334
  defaults: {},
2174
2335
  usage: { unit: "tokens", modality: "TEXT" },