@teinai/cli 1.1.41 → 1.1.42

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 (2) hide show
  1. package/index.js +252 -137
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -96,7 +96,7 @@ var L,
96
96
  Ee,
97
97
  de,
98
98
  W,
99
- A = y(() => {
99
+ R = y(() => {
100
100
  'use strict';
101
101
  ((L = M(require('node:fs'))),
102
102
  (Pt = M(require('node:os'))),
@@ -105,13 +105,13 @@ var L,
105
105
  (W = Ee.default.join(de, 'config.json')));
106
106
  });
107
107
  var Si,
108
- It,
109
108
  vt,
109
+ It,
110
110
  Tt = y(() => {
111
111
  'use strict';
112
112
  ((Si = ['1:1', '16:9', '9:16', '21:9', '3:2', '2:3', '4:3', '3:4', '4:5', '5:4']),
113
- (It = [...Si, 'auto']),
114
- (vt =
113
+ (vt = [...Si, 'auto']),
114
+ (It =
115
115
  'The medium endpoint renders non-square images at 1K only. Use resolution 1K, aspect_ratio 1:1, or the dynamic endpoint for a non-square 2K or 4K image.'));
116
116
  });
117
117
  var ce,
@@ -217,6 +217,7 @@ var ue,
217
217
  ],
218
218
  },
219
219
  { slug: 'gemini-omni', name: 'Gemini Omni', models: ['gemini-omni-1.2-flash'] },
220
+ { slug: 'magi', name: 'MAGI', models: ['magi-2'] },
220
221
  { slug: 'kling', name: 'Kling', models: ['kling-v4', 'kling-v4-flash', 'kling-v3-video'] },
221
222
  { slug: 'ltx', name: 'LTX', models: ['ltx-2.3-pro'] },
222
223
  { slug: 'vidu', name: 'Vidu', models: ['vidu-q4-preview'] },
@@ -5775,6 +5776,51 @@ var ue,
5775
5776
  axes: { resolution: ['360p', '720p', '1080p', '4k'] },
5776
5777
  from: { variant: '720p' },
5777
5778
  },
5779
+ {
5780
+ slug: 'magi-2',
5781
+ name: 'MAGI-2',
5782
+ family: 'magi',
5783
+ vendor: 'Sand AI',
5784
+ desc: "Sand AI's MAGI-2: video with optional native sound from text, a start frame (with an optional end frame), or images, videos and audio clips as references.",
5785
+ kind: 'video',
5786
+ unit: '/sec',
5787
+ api: { model: 'magi-2' },
5788
+ variants: [
5789
+ {
5790
+ id: '720p',
5791
+ price: { starter: 0.048, plus: 0.0456, scale: 0.0432 },
5792
+ label: '720p',
5793
+ resolution: '720p',
5794
+ withVideo: !1,
5795
+ },
5796
+ {
5797
+ id: '720p-with-video',
5798
+ price: { starter: 0.029, plus: 0.0275, scale: 0.0261 },
5799
+ label: '720p \xB7 with reference video',
5800
+ resolution: '720p',
5801
+ withVideo: !0,
5802
+ },
5803
+ {
5804
+ id: '1080p',
5805
+ price: { starter: 0.089, plus: 0.089, scale: 0.089 },
5806
+ label: '1080p',
5807
+ resolution: '1080p',
5808
+ withVideo: !1,
5809
+ },
5810
+ {
5811
+ id: '1080p-with-video',
5812
+ price: { starter: 0.089, plus: 0.089, scale: 0.089 },
5813
+ label: '1080p \xB7 with reference video',
5814
+ resolution: '1080p',
5815
+ withVideo: !0,
5816
+ },
5817
+ ],
5818
+ unfiltered: null,
5819
+ priority: null,
5820
+ draft: null,
5821
+ axes: { resolution: ['720p', '1080p'] },
5822
+ from: { variant: '720p' },
5823
+ },
5778
5824
  {
5779
5825
  slug: 'kling-v4',
5780
5826
  name: 'Kling Video 4.0',
@@ -6446,7 +6492,7 @@ function Ne(e) {
6446
6492
  : (e.defaultEndpoint ?? e.endpoints[0].id);
6447
6493
  }
6448
6494
  var Nt,
6449
- Ue = y(() => {
6495
+ Ve = y(() => {
6450
6496
  'use strict';
6451
6497
  j();
6452
6498
  Nt = 'dynamic';
@@ -6461,21 +6507,21 @@ function ye(e) {
6461
6507
  (t.split('.')[1] ?? '').length < 2 ? `$${e.toFixed(2)}` : `$${t}`
6462
6508
  );
6463
6509
  }
6464
- function Ve(e) {
6510
+ function Ue(e) {
6465
6511
  return e.starter === e.plus && e.plus === e.scale
6466
6512
  ? `${ye(e.starter)} on every plan`
6467
6513
  : `${ye(e.starter)} on Starter, ${ye(e.plus)} on Plus, ${ye(e.scale)} on Scale`;
6468
6514
  }
6469
- function Ut(e) {
6515
+ function Vt(e) {
6470
6516
  let t = [],
6471
6517
  r = Oi[e],
6472
6518
  a = r != null ? Dt(qi(e)) : null;
6473
6519
  if (a && r != null) {
6474
6520
  let n =
6475
- a.addon.unfiltered && Ve(a.addon.unfiltered) === Ve(a.addon.price)
6521
+ a.addon.unfiltered && Ue(a.addon.unfiltered) === Ue(a.addon.price)
6476
6522
  ? ', Creative mode included'
6477
6523
  : '';
6478
- t.push(`Each reference image after the ${Di[r] ?? `${r}th`} adds ${Ve(a.addon.price)}${n}.`);
6524
+ t.push(`Each reference image after the ${Di[r] ?? `${r}th`} adds ${Ue(a.addon.price)}${n}.`);
6479
6525
  }
6480
6526
  return (
6481
6527
  Li.has(e) &&
@@ -6489,7 +6535,7 @@ var Ri,
6489
6535
  Oi,
6490
6536
  Li,
6491
6537
  Di,
6492
- Vt = y(() => {
6538
+ Ut = y(() => {
6493
6539
  'use strict';
6494
6540
  j();
6495
6541
  ((Ri = 'extra-image-input'), (Oi = { 'seedream-5-pro': 1, 'minimax-h3': 5 }));
@@ -6519,19 +6565,19 @@ var Ni,
6519
6565
  jt = y(() => {
6520
6566
  'use strict';
6521
6567
  j();
6522
- Ue();
6568
+ Ve();
6523
6569
  Ft();
6524
6570
  Ni = {};
6525
6571
  });
6526
6572
  function Gt(e) {
6527
- return e === 'nano-banana-pro' ? Ui : Vi;
6573
+ return e === 'nano-banana-pro' ? Vi : Ui;
6528
6574
  }
6529
- var Ui,
6530
- Vi,
6575
+ var Vi,
6576
+ Ui,
6531
6577
  Ht = y(() => {
6532
6578
  'use strict';
6533
- ((Ui = ['auto', '1:1', '2:3', '3:2', '3:4', '4:3', '4:5', '5:4', '9:16', '16:9', '21:9']),
6534
- (Vi = [
6579
+ ((Vi = ['auto', '1:1', '2:3', '3:2', '3:4', '4:3', '4:5', '5:4', '9:16', '16:9', '21:9']),
6580
+ (Ui = [
6535
6581
  'auto',
6536
6582
  '1:1',
6537
6583
  '1:4',
@@ -7282,7 +7328,7 @@ function br(e) {
7282
7328
  r && a && (r.priceFormatted = a);
7283
7329
  }
7284
7330
  }
7285
- function R(e, t) {
7331
+ function A(e, t) {
7286
7332
  let r = e.axes?.resolution ?? [
7287
7333
  ...new Set(e.variants.map((a) => a.resolution).filter((a) => !!a)),
7288
7334
  ];
@@ -7384,7 +7430,7 @@ function gr(e, t = {}) {
7384
7430
  }
7385
7431
  function Xe(e, t) {
7386
7432
  return [
7387
- E('Text prompt describing the video.'),
7433
+ S('Text prompt describing the video.'),
7388
7434
  { name: 'mode', type: 'select', required: !0, default: t.modes[0], options: t.modes },
7389
7435
  {
7390
7436
  name: 'duration',
@@ -7394,7 +7440,7 @@ function Xe(e, t) {
7394
7440
  max: t.maxSec,
7395
7441
  description: `Video length in seconds (${t.minSec} to ${t.maxSec}).`,
7396
7442
  },
7397
- R(e),
7443
+ A(e),
7398
7444
  { name: 'aspect_ratio', type: 'select', default: t.aspects[0], options: t.aspects },
7399
7445
  ...t.references.map((r) =>
7400
7446
  r.endsWith('s')
@@ -7419,7 +7465,7 @@ function pa(e, t) {
7419
7465
  function ca(e) {
7420
7466
  let t = wr(e);
7421
7467
  return [
7422
- E('Image prompt text. Supports complex composition and text instructions.'),
7468
+ S('Image prompt text. Supports complex composition and text instructions.'),
7423
7469
  ...(t ? [t] : []),
7424
7470
  {
7425
7471
  name: 'quality',
@@ -7427,17 +7473,17 @@ function ca(e) {
7427
7473
  default: 'low',
7428
7474
  options: e.axes?.quality ?? ['low', 'medium', 'high'],
7429
7475
  },
7430
- R(
7476
+ A(
7431
7477
  e,
7432
7478
  e.slug === 'gpt-image-2'
7433
- ? `1:1 is 1024, 2048 or 2880 px; other ratios keep about the same pixel count. ${vt}`
7479
+ ? `1:1 is 1024, 2048 or 2880 px; other ratios keep about the same pixel count. ${It}`
7434
7480
  : '1:1 is 1024, 2048 or 2880 px; other ratios keep about the same pixel count.',
7435
7481
  ),
7436
7482
  {
7437
7483
  name: 'aspect_ratio',
7438
7484
  type: 'select',
7439
7485
  default: 'auto',
7440
- options: [...It],
7486
+ options: [...vt],
7441
7487
  description:
7442
7488
  "The frame. auto: an edit keeps its first input image's ratio (the nearest listed one), text to image is 1:1. The image is delivered at exactly the size for the ratio and resolution.",
7443
7489
  },
@@ -7486,14 +7532,14 @@ function ca(e) {
7486
7532
  }
7487
7533
  function ua(e) {
7488
7534
  return [
7489
- E('Image prompt text.'),
7535
+ S('Image prompt text.'),
7490
7536
  {
7491
7537
  name: 'input_images',
7492
7538
  type: 'string[]',
7493
7539
  description: 'Images to edit or use as reference (up to 14).',
7494
7540
  },
7495
7541
  { name: 'aspect_ratio', type: 'select', default: '1:1', options: [...Gt(e.slug)] },
7496
- R(e),
7542
+ A(e),
7497
7543
  {
7498
7544
  name: 'n',
7499
7545
  type: 'slider',
@@ -7550,7 +7596,7 @@ function ya() {
7550
7596
  }
7551
7597
  function st(e) {
7552
7598
  return [
7553
- E('The user message or task.'),
7599
+ S('The user message or task.'),
7554
7600
  { name: 'system', type: 'string', description: 'Optional system instructions.' },
7555
7601
  {
7556
7602
  name: 'messages',
@@ -7674,7 +7720,7 @@ function xa(e) {
7674
7720
  description:
7675
7721
  'The video to upscale (up to 30 seconds): a Tein upload link, or any public https link.',
7676
7722
  },
7677
- R(
7723
+ A(
7678
7724
  e,
7679
7725
  'Size of the result: 1080p, 2k or 4k. A video already near a size cannot be upscaled to it.',
7680
7726
  ),
@@ -7784,14 +7830,14 @@ function _a(e) {
7784
7830
  return ua(e);
7785
7831
  case 'seedream-5-pro':
7786
7832
  return [
7787
- E('Detailed description of the image to generate.'),
7833
+ S('Detailed description of the image to generate.'),
7788
7834
  {
7789
7835
  name: 'images',
7790
7836
  type: 'string[]',
7791
7837
  description:
7792
7838
  'Reference images. The first is free; each one after it adds the extra reference image charge (see the price).',
7793
7839
  },
7794
- R(e),
7840
+ A(e),
7795
7841
  {
7796
7842
  name: 'aspect_ratio',
7797
7843
  type: 'select',
@@ -7803,14 +7849,14 @@ function _a(e) {
7803
7849
  case 'minimax-h3-image':
7804
7850
  case 'minimax-h3-image-highspeed':
7805
7851
  return [
7806
- E('What to make, or how to change the reference images.'),
7852
+ S('What to make, or how to change the reference images.'),
7807
7853
  {
7808
7854
  name: 'images',
7809
7855
  type: 'string[]',
7810
7856
  description:
7811
7857
  'Reference images to edit or combine (up to 16). Leave empty for text to image. Each reference image is billed.',
7812
7858
  },
7813
- { ...R(e, '1K, 2K or 4K (about 16 megapixels).'), default: '2K' },
7859
+ { ...A(e, '1K, 2K or 4K (about 16 megapixels).'), default: '2K' },
7814
7860
  {
7815
7861
  name: 'aspect_ratio',
7816
7862
  type: 'select',
@@ -7849,7 +7895,7 @@ function _a(e) {
7849
7895
  description:
7850
7896
  'text_to_image, image_to_image (up to 10 reference images) or layer_decomposition (split one image into a base image and editable transparent layers).',
7851
7897
  },
7852
- E(
7898
+ S(
7853
7899
  'What to make or change. Optional for layer_decomposition, where it can say how to split the image (for example "keep the logo as one layer").',
7854
7900
  ),
7855
7901
  {
@@ -7858,7 +7904,7 @@ function _a(e) {
7858
7904
  description:
7859
7905
  'Reference images (up to 10), or for layer_decomposition the one JPEG or PNG to split (at least 512x512). Each input image is billed.',
7860
7906
  },
7861
- R(
7907
+ A(
7862
7908
  e,
7863
7909
  '1K and 1.5K are one price, 2K the next. layer_decomposition also takes auto (keep the input size), billed at the 2K price.',
7864
7910
  ),
@@ -7898,13 +7944,13 @@ function _a(e) {
7898
7944
  case 'qwen-3':
7899
7945
  case 'qwen-3-pro':
7900
7946
  return [
7901
- E('Image prompt text; dense layouts and multilingual text work well.'),
7947
+ S('Image prompt text; dense layouts and multilingual text work well.'),
7902
7948
  {
7903
7949
  name: 'images',
7904
7950
  type: 'string[]',
7905
7951
  description: 'Up to 3 reference images, each billed at the published add-on price.',
7906
7952
  },
7907
- R(e),
7953
+ A(e),
7908
7954
  {
7909
7955
  name: 'aspect_ratio',
7910
7956
  type: 'select',
@@ -7922,8 +7968,8 @@ function _a(e) {
7922
7968
  ];
7923
7969
  case 'z-image-pro':
7924
7970
  return [
7925
- E('Image prompt text: subject, scene, style, composition and lighting.'),
7926
- R(e, 'Long edge: 1K is 1024 px, 2K is 2048 px. Same price.'),
7971
+ S('Image prompt text: subject, scene, style, composition and lighting.'),
7972
+ A(e, 'Long edge: 1K is 1024 px, 2K is 2048 px. Same price.'),
7927
7973
  {
7928
7974
  name: 'aspect_ratio',
7929
7975
  type: 'select',
@@ -7954,7 +8000,7 @@ function _a(e) {
7954
8000
  ];
7955
8001
  case 'wan-2-5-image':
7956
8002
  return [
7957
- E('Image prompt, or for an edit the change to make (up to 2000 characters).'),
8003
+ S('Image prompt, or for an edit the change to make (up to 2000 characters).'),
7958
8004
  {
7959
8005
  name: 'images',
7960
8006
  type: 'string[]',
@@ -8150,7 +8196,7 @@ function _a(e) {
8150
8196
  });
8151
8197
  case 'gemini-omni-1.2-flash':
8152
8198
  return [
8153
- E(
8199
+ S(
8154
8200
  'Describe the video and its sound (dialogue, effects, music), or for video_edit / video_extend the change or what happens next (up to 20000 characters).',
8155
8201
  ),
8156
8202
  {
@@ -8176,7 +8222,7 @@ function _a(e) {
8176
8222
  description:
8177
8223
  'Video length in seconds (3 to 15). With a last frame 3 to 10; for video_extend the seconds added (3 to 10). Not taken by video_edit, which bills the input video length.',
8178
8224
  },
8179
- { ...R(e, '1080p and 4k are upscaled. Sound is always included.'), default: '720p' },
8225
+ { ...A(e, '1080p and 4k are upscaled. Sound is always included.'), default: '720p' },
8180
8226
  {
8181
8227
  name: 'aspect_ratio',
8182
8228
  type: 'select',
@@ -8208,6 +8254,71 @@ function _a(e) {
8208
8254
  'video_edit / video_extend: the video to change (MP4, MOV or WebM, with a video track): 3 to 15 s for video_edit, 15 s or less for video_extend. A public http(s) URL or data URI.',
8209
8255
  },
8210
8256
  ];
8257
+ case 'magi-2':
8258
+ return [
8259
+ S(
8260
+ 'Describe the video, the camera and its sound; for multi_reference say what each reference is for (up to 15000 characters).',
8261
+ ),
8262
+ {
8263
+ name: 'mode',
8264
+ type: 'select',
8265
+ required: !0,
8266
+ options: ['text_to_video', 'image_to_video', 'multi_reference'],
8267
+ description:
8268
+ 'text_to_video; image_to_video (first_frame_image, optional last_frame_image); multi_reference (images, videos and/or audios).',
8269
+ },
8270
+ {
8271
+ name: 'duration',
8272
+ type: 'slider',
8273
+ default: 5,
8274
+ min: 4,
8275
+ max: 30,
8276
+ description: 'Video length in whole seconds: 4 to 15 at 720p, 4 to 30 at 1080p.',
8277
+ },
8278
+ { ...A(e, 'Sound is the same price on or off.'), default: '720p' },
8279
+ {
8280
+ name: 'aspect_ratio',
8281
+ type: 'select',
8282
+ options: ['16:9', '9:16', '1:1', '4:3', '3:4', '21:9'],
8283
+ description:
8284
+ 'text_to_video and multi_reference (left out: 16:9). image_to_video: leave it out to follow the start image (21:9 not taken); a ratio that differs from the image crops it.',
8285
+ },
8286
+ {
8287
+ name: 'generate_audio',
8288
+ type: 'boolean',
8289
+ default: !0,
8290
+ description: 'Generate sound with the video (same price either way).',
8291
+ },
8292
+ {
8293
+ name: 'first_frame_image',
8294
+ type: 'string',
8295
+ description:
8296
+ 'image_to_video: the start frame (JPEG, PNG or WebP), as a public http(s) URL or data URI. The Tein CLI and local MCP client read a file path on your machine and upload it before the request is sent.',
8297
+ },
8298
+ {
8299
+ name: 'last_frame_image',
8300
+ type: 'string',
8301
+ description: 'image_to_video: an optional end frame.',
8302
+ },
8303
+ {
8304
+ name: 'images',
8305
+ type: 'string[]',
8306
+ description:
8307
+ 'multi_reference: reference images (up to 9 at 720p, 10 at 1080p). Public http(s) URLs or data URIs.',
8308
+ },
8309
+ {
8310
+ name: 'videos',
8311
+ type: 'string[]',
8312
+ description:
8313
+ 'multi_reference: reference videos, MP4 or MOV (up to 3 at 720p, 2-15 s each and 15 s in all; up to 5 at 1080p, 2-30 s each and 30 s in all). At 720p a reference video bills its own seconds too.',
8314
+ },
8315
+ {
8316
+ name: 'audios',
8317
+ type: 'string[]',
8318
+ description:
8319
+ 'multi_reference: reference audio, MP3 or WAV (up to 3 at 720p with an image or video; up to 5 at 1080p, where audio alone works).',
8320
+ },
8321
+ ];
8211
8322
  case 'minimax-h3':
8212
8323
  return pa(
8213
8324
  Xe(e, {
@@ -8225,10 +8336,10 @@ function _a(e) {
8225
8336
  },
8226
8337
  );
8227
8338
  default:
8228
- return [E('Prompt text.')];
8339
+ return [S('Prompt text.')];
8229
8340
  }
8230
8341
  }
8231
- function Ir() {
8342
+ function vr() {
8232
8343
  let e = (t, r) => ({
8233
8344
  name: t,
8234
8345
  type: 'slider',
@@ -8249,7 +8360,7 @@ function Ir() {
8249
8360
  ),
8250
8361
  ];
8251
8362
  }
8252
- function vr(e) {
8363
+ function Ir(e) {
8253
8364
  return {
8254
8365
  name: 'image',
8255
8366
  type: 'string',
@@ -8257,7 +8368,7 @@ function vr(e) {
8257
8368
  description: `The photo to ${e}: one JPEG, PNG or WebP URL, up to 24 MB and 16.7 MP, with a shorter side of at least 256 px. HEIC/HEIF isn't supported.`,
8258
8369
  };
8259
8370
  }
8260
- function Ia() {
8371
+ function va() {
8261
8372
  return {
8262
8373
  slug: xe,
8263
8374
  name: lr,
@@ -8270,7 +8381,7 @@ function Ia() {
8270
8381
  unit: '/img',
8271
8382
  primaryToolName: rt.image,
8272
8383
  parameters: [
8273
- vr('upscale'),
8384
+ Ir('upscale'),
8274
8385
  {
8275
8386
  name: 'preset',
8276
8387
  type: 'select',
@@ -8285,11 +8396,11 @@ function Ia() {
8285
8396
  },
8286
8397
  Tr,
8287
8398
  Mr,
8288
- ...Ir(),
8399
+ ...vr(),
8289
8400
  ],
8290
8401
  };
8291
8402
  }
8292
- function va() {
8403
+ function Ia() {
8293
8404
  return {
8294
8405
  slug: ke,
8295
8406
  name: dr,
@@ -8301,11 +8412,11 @@ function va() {
8301
8412
  priceFormatted: '',
8302
8413
  unit: '/img',
8303
8414
  primaryToolName: rt.image,
8304
- parameters: [vr('deblur'), Tr, Mr, ...Ir()],
8415
+ parameters: [Ir('deblur'), Tr, Mr, ...vr()],
8305
8416
  };
8306
8417
  }
8307
8418
  function et(e, t = e.api.model) {
8308
- let r = Ut(e.slug);
8419
+ let r = Vt(e.slug);
8309
8420
  return {
8310
8421
  slug: t,
8311
8422
  name: e.name,
@@ -8337,7 +8448,7 @@ function Ta() {
8337
8448
  }
8338
8449
  t.slug.startsWith('claude-') || (e[t.api.model] = et(t));
8339
8450
  }
8340
- (Object.assign(e, Zt()), (e[xe] = Ia()), (e[ke] = va()));
8451
+ (Object.assign(e, Zt()), (e[xe] = va()), (e[ke] = Ia()));
8341
8452
  for (let [t, r] of Object.entries(be))
8342
8453
  e[r] && Object.defineProperty(e, t, { value: e[r], enumerable: !1 });
8343
8454
  return e;
@@ -8356,7 +8467,7 @@ function Sr(e) {
8356
8467
  a && typeof r == 'string' && r.trim() && (a.priceFormatted = r.trim());
8357
8468
  }
8358
8469
  }
8359
- function Ie(e) {
8470
+ function ve(e) {
8360
8471
  return !!e?.parameters.some((t) => t.name === 'image');
8361
8472
  }
8362
8473
  function G(e) {
@@ -8366,7 +8477,11 @@ function Sa(e, t, r) {
8366
8477
  if (
8367
8478
  e.startsWith('enhancor-skin-fix-') ||
8368
8479
  pr(e) ||
8369
- (e === 'gemini-omni-1.2-flash' && (t === 'aspect_ratio' || t === 'duration'))
8480
+ (e === 'gemini-omni-1.2-flash' && (t === 'aspect_ratio' || t === 'duration')) ||
8481
+ (e === 'magi-2' &&
8482
+ t === 'aspect_ratio' &&
8483
+ (typeof r.mode == 'string' ? r.mode.trim().toLowerCase() : '').replace(/-/g, '_') ===
8484
+ 'image_to_video')
8370
8485
  )
8371
8486
  return !1;
8372
8487
  if ((e === 'seedance-2-5' || e === 'seedance-2-5-lite' || kr(e)) && t === 'duration') {
@@ -8417,7 +8532,7 @@ function N() {
8417
8532
  var ta,
8418
8533
  rt,
8419
8534
  ra,
8420
- E,
8535
+ S,
8421
8536
  it,
8422
8537
  aa,
8423
8538
  xr,
@@ -8446,8 +8561,8 @@ var ta,
8446
8561
  Tt();
8447
8562
  Ae();
8448
8563
  j();
8449
- Ue();
8450
- Vt();
8564
+ Ve();
8565
+ Ut();
8451
8566
  Re();
8452
8567
  Fe();
8453
8568
  jt();
@@ -8472,7 +8587,7 @@ var ta,
8472
8587
  audio: 'Text-to-Audio',
8473
8588
  llm: 'Reasoning (LLM)',
8474
8589
  }));
8475
- E = (e) => ({ name: 'prompt', type: 'string', required: !0, description: e });
8590
+ S = (e) => ({ name: 'prompt', type: 'string', required: !0, description: e });
8476
8591
  ((it = {
8477
8592
  name: 'creative_mode',
8478
8593
  type: 'boolean',
@@ -8527,7 +8642,7 @@ var ta,
8527
8642
  audios: 'up to 5; combined duration < 30s',
8528
8643
  }));
8529
8644
  ((ma = [
8530
- E('The user message or task.'),
8645
+ S('The user message or task.'),
8531
8646
  { name: 'system', type: 'string', description: 'Optional system instructions.' },
8532
8647
  {
8533
8648
  name: 'messages',
@@ -8545,7 +8660,7 @@ var ta,
8545
8660
  { name: 'top_p', type: 'slider', min: 0, max: 1, step: 0.05 },
8546
8661
  ]),
8547
8662
  (fa = [
8548
- E('The user message or task.'),
8663
+ S('The user message or task.'),
8549
8664
  { name: 'system', type: 'string', description: 'Optional system instructions.' },
8550
8665
  {
8551
8666
  name: 'messages',
@@ -9004,7 +9119,7 @@ var ta,
9004
9119
  Y = Ta();
9005
9120
  Ka = ['draft_task_id', 'draft_generation_id'];
9006
9121
  });
9007
- function ve(e) {
9122
+ function Ie(e) {
9008
9123
  let t = '/v1/pricing/models',
9009
9124
  r = e?.trim();
9010
9125
  return r ? `${t}?model=${encodeURIComponent(r)}` : t;
@@ -9120,7 +9235,7 @@ function cn(e, t) {
9120
9235
  };
9121
9236
  }
9122
9237
  function un() {
9123
- let e = N().filter((u) => u.category === 'Image' && !Ie(u)),
9238
+ let e = N().filter((u) => u.category === 'Image' && !ve(u)),
9124
9239
  t = N().filter((u) => u.category === 'Video'),
9125
9240
  r = N().filter((u) => u.category === 'Text'),
9126
9241
  a = N().filter((u) => u.category === 'Audio'),
@@ -9606,9 +9721,9 @@ function gn() {
9606
9721
  }
9607
9722
  async function ni(e, t, r) {
9608
9723
  let a = Q.default.resolve(e);
9609
- if (!U.default.existsSync(a) || !U.default.statSync(a).isFile())
9724
+ if (!V.default.existsSync(a) || !V.default.statSync(a).isFile())
9610
9725
  throw new Error(`File not found: ${e}`);
9611
- let n = U.default.readFileSync(a),
9726
+ let n = V.default.readFileSync(a),
9612
9727
  s = n.toString('base64'),
9613
9728
  o = n.length,
9614
9729
  d = `${r.replace(/\/$/, '')}/v1/upload`,
@@ -9652,7 +9767,7 @@ function yn(e) {
9652
9767
  )
9653
9768
  return null;
9654
9769
  let r = Q.default.resolve(t);
9655
- return U.default.existsSync(r) && U.default.statSync(r).isFile() ? r : null;
9770
+ return V.default.existsSync(r) && V.default.statSync(r).isFile() ? r : null;
9656
9771
  }
9657
9772
  function ht(e) {
9658
9773
  if (Array.isArray(e))
@@ -9770,7 +9885,7 @@ async function di() {
9770
9885
  c = o.params.arguments || {};
9771
9886
  if (l === 'get_pricing') {
9772
9887
  let p = typeof c.model == 'string' ? c.model.trim() : '',
9773
- u = `${t.replace(/\/+$/, '')}${ve(p)}`;
9888
+ u = `${t.replace(/\/+$/, '')}${Ie(p)}`;
9774
9889
  try {
9775
9890
  let m = await fetch(u, {
9776
9891
  signal: AbortSignal.timeout(1e4),
@@ -9821,7 +9936,7 @@ async function di() {
9821
9936
  )
9822
9937
  try {
9823
9938
  let u = Q.default.resolve(p.trim());
9824
- if (U.default.existsSync(u) && U.default.statSync(u).isFile() && e) {
9939
+ if (V.default.existsSync(u) && V.default.statSync(u).isFile() && e) {
9825
9940
  if (!si(u)) throw oi(u);
9826
9941
  let m = await ni(u, e, t),
9827
9942
  g = (m.sizeBytes / 1024).toFixed(1),
@@ -9832,7 +9947,7 @@ async function di() {
9832
9947
 
9833
9948
  ![Uploaded Asset](${m.url})`
9834
9949
  : '',
9835
- V = {
9950
+ U = {
9836
9951
  jsonrpc: '2.0',
9837
9952
  id: o.id,
9838
9953
  result: {
@@ -9852,7 +9967,7 @@ Pass this URL to any Tein generation tool.`,
9852
9967
  },
9853
9968
  };
9854
9969
  process.stdout.write(
9855
- JSON.stringify(V) +
9970
+ JSON.stringify(U) +
9856
9971
  `
9857
9972
  `,
9858
9973
  );
@@ -9945,7 +10060,7 @@ Pass this URL to any Tein generation tool.`,
9945
10060
  process.stderr.write(`Tein AI MCP Server running on stdio transport.
9946
10061
  `));
9947
10062
  }
9948
- var U,
10063
+ var V,
9949
10064
  Q,
9950
10065
  ii,
9951
10066
  hn,
@@ -9954,12 +10069,12 @@ var U,
9954
10069
  ri,
9955
10070
  ci = y(() => {
9956
10071
  'use strict';
9957
- ((U = M(require('node:fs'))),
10072
+ ((V = M(require('node:fs'))),
9958
10073
  (Q = M(require('node:path'))),
9959
10074
  (ii = M(require('node:readline'))));
9960
10075
  dt();
9961
10076
  ei();
9962
- A();
10077
+ R();
9963
10078
  oe();
9964
10079
  hn = new Set([
9965
10080
  '.png',
@@ -10090,7 +10205,7 @@ var le = M(require('node:fs')),
10090
10205
  kt = M(require('node:path')),
10091
10206
  _t = require('node:stream/promises');
10092
10207
  oe();
10093
- var Ii = new Set([
10208
+ var vi = new Set([
10094
10209
  'account_suspended',
10095
10210
  'account_terminated',
10096
10211
  'creative_mode_restricted',
@@ -10098,7 +10213,7 @@ var Ii = new Set([
10098
10213
  'workspace_paused',
10099
10214
  ]),
10100
10215
  T = 1,
10101
- vi = 3,
10216
+ Ii = 3,
10102
10217
  b = class extends Error {
10103
10218
  constructor(t, r, a, n = {}) {
10104
10219
  (super(r),
@@ -10108,7 +10223,7 @@ var Ii = new Set([
10108
10223
  (this.fields = n));
10109
10224
  }
10110
10225
  get exitCode() {
10111
- return this.code && Ii.has(this.code) ? vi : T;
10226
+ return this.code && vi.has(this.code) ? Ii : T;
10112
10227
  }
10113
10228
  };
10114
10229
  function Ti(e, t, r) {
@@ -10127,7 +10242,7 @@ function Ti(e, t, r) {
10127
10242
  function wt(e) {
10128
10243
  return typeof e == 'number' && Number.isFinite(e) ? `$${e.toFixed(4)}` : null;
10129
10244
  }
10130
- function K(e) {
10245
+ function E(e) {
10131
10246
  let t = [e.message],
10132
10247
  r = wt(e.fields.required),
10133
10248
  a = wt(e.fields.balance);
@@ -10153,7 +10268,7 @@ function xt(e) {
10153
10268
  : r.url && t.push({ type: Mi(r.url), url: r.url, ...(r.layer ? { layer: r.layer } : {}) });
10154
10269
  return t;
10155
10270
  }
10156
- var S = class {
10271
+ var K = class {
10157
10272
  constructor(t, r) {
10158
10273
  ((this.apiKey = t), (this.baseUrl = r.replace(/\/+$/, '')));
10159
10274
  }
@@ -10243,7 +10358,7 @@ var S = class {
10243
10358
  return (await (0, _t.pipeline)(a.body, s), r);
10244
10359
  }
10245
10360
  };
10246
- A();
10361
+ R();
10247
10362
  function Ce(e) {
10248
10363
  if (typeof e != 'number' || !Number.isFinite(e)) return '';
10249
10364
  if (Math.abs(e) >= 1 || Math.abs(Number(e.toFixed(4)) - e) < 1e-12) return `$${e.toFixed(4)}`;
@@ -10358,7 +10473,7 @@ async function Ra(e, t, r, a, n) {
10358
10473
  `));
10359
10474
  }
10360
10475
  for (let l of d)
10361
- process.stderr.write(`${K(l).join(`
10476
+ process.stderr.write(`${E(l).join(`
10362
10477
  `)}
10363
10478
  `);
10364
10479
  }
@@ -10449,12 +10564,12 @@ async function ot(e, t) {
10449
10564
  delete c.count);
10450
10565
  let p = Kr(n, c);
10451
10566
  (Ea(p),
10452
- typeof p.image == 'string' && !p.images && !Ie(n) && ((p.images = [p.image]), delete p.image),
10567
+ typeof p.image == 'string' && !p.images && !ve(n) && ((p.images = [p.image]), delete p.image),
10453
10568
  p.image_url &&
10454
10569
  !p.first_frame_image &&
10455
10570
  (e.startsWith('seedance') || e.startsWith('happy-horse')) &&
10456
10571
  (p.first_frame_image = p.image_url));
10457
- let u = new S(r, a),
10572
+ let u = new K(r, a),
10458
10573
  m = [
10459
10574
  'image',
10460
10575
  'mask_image',
@@ -10469,14 +10584,14 @@ async function ot(e, t) {
10469
10584
  for (let w of m) {
10470
10585
  let h = p[w];
10471
10586
  if (typeof h == 'string' && !h.startsWith('http://') && !h.startsWith('https://')) {
10472
- let I = O.default.resolve(h);
10473
- if (H.default.existsSync(I) && H.default.statSync(I).isFile()) {
10474
- let v = new $(`Uploading local file ${O.default.basename(I)} to CDN...`);
10475
- s || v.start();
10587
+ let v = O.default.resolve(h);
10588
+ if (H.default.existsSync(v) && H.default.statSync(v).isFile()) {
10589
+ let I = new $(`Uploading local file ${O.default.basename(v)} to CDN...`);
10590
+ s || I.start();
10476
10591
  try {
10477
- let F = H.default.readFileSync(I),
10592
+ let F = H.default.readFileSync(v),
10478
10593
  q = await u.uploadAsset(F.toString('base64'));
10479
- ((p[w] = q.url), s || v.succeed(`Uploaded ${O.default.basename(I)} to CDN`));
10594
+ ((p[w] = q.url), s || I.succeed(`Uploaded ${O.default.basename(v)} to CDN`));
10480
10595
  } catch (F) {
10481
10596
  let q = F instanceof Error ? F.message : String(F);
10482
10597
  (s
@@ -10485,7 +10600,7 @@ async function ot(e, t) {
10485
10600
  `
10486
10601
  `,
10487
10602
  )
10488
- : v.fail(`Upload failed: ${q}`),
10603
+ : I.fail(`Upload failed: ${q}`),
10489
10604
  process.exit(1));
10490
10605
  }
10491
10606
  }
@@ -10495,18 +10610,18 @@ async function ot(e, t) {
10495
10610
  let h = new $(`Uploading local file ${O.default.basename(w)} to CDN...`);
10496
10611
  s || h.start();
10497
10612
  try {
10498
- let I = H.default.readFileSync(w),
10499
- v = await u.uploadAsset(I.toString('base64'));
10500
- return (s || h.succeed(`Uploaded ${O.default.basename(w)} to CDN`), v.url);
10501
- } catch (I) {
10502
- let v = I instanceof Error ? I.message : String(I);
10613
+ let v = H.default.readFileSync(w),
10614
+ I = await u.uploadAsset(v.toString('base64'));
10615
+ return (s || h.succeed(`Uploaded ${O.default.basename(w)} to CDN`), I.url);
10616
+ } catch (v) {
10617
+ let I = v instanceof Error ? v.message : String(v);
10503
10618
  (s
10504
10619
  ? process.stdout.write(
10505
- JSON.stringify({ error: v }) +
10620
+ JSON.stringify({ error: I }) +
10506
10621
  `
10507
10622
  `,
10508
10623
  )
10509
- : h.fail(`Upload failed: ${v}`),
10624
+ : h.fail(`Upload failed: ${I}`),
10510
10625
  process.exit(1));
10511
10626
  }
10512
10627
  });
@@ -10535,7 +10650,7 @@ async function ot(e, t) {
10535
10650
  )
10536
10651
  : g.fail(
10537
10652
  h
10538
- ? K(h).join(`
10653
+ ? E(h).join(`
10539
10654
  `)
10540
10655
  : `Failed to start generation: ${w instanceof Error ? w.message : w}`,
10541
10656
  ),
@@ -10554,11 +10669,11 @@ async function ot(e, t) {
10554
10669
  return;
10555
10670
  }
10556
10671
  let C = Date.now(),
10557
- V = 1500;
10672
+ U = 1500;
10558
10673
  for (; f.status === 'processing';) {
10559
10674
  let w = Math.round((Date.now() - C) / 1e3);
10560
10675
  (s || g.update(`Rendering ${i.bold(e)} (${w}s elapsed)... [ID: ${f.request_id}]`),
10561
- await new Promise((h) => setTimeout(h, V)));
10676
+ await new Promise((h) => setTimeout(h, U)));
10562
10677
  try {
10563
10678
  f = await u.getStatus(f.request_id);
10564
10679
  } catch (h) {
@@ -10566,7 +10681,7 @@ async function ot(e, t) {
10566
10681
  h.exitCode !== T &&
10567
10682
  (s ||
10568
10683
  g.fail(
10569
- K(h).join(`
10684
+ E(h).join(`
10570
10685
  `),
10571
10686
  ),
10572
10687
  process.exit(h.exitCode));
@@ -10607,30 +10722,30 @@ async function ot(e, t) {
10607
10722
  process.stdout.write(`
10608
10723
  ${i.bold('Outputs:')}
10609
10724
  `);
10610
- let w = f.output.filter((I) => I.url).length,
10725
+ let w = f.output.filter((v) => v.url).length,
10611
10726
  h = 0;
10612
- for (let I = 0; I < f.output.length; I++) {
10613
- let v = f.output[I];
10614
- if (v.url) {
10615
- let F = v.layer?.name ? ` ${i.bold(v.layer.name)}` : '';
10727
+ for (let v = 0; v < f.output.length; v++) {
10728
+ let I = f.output[v];
10729
+ if (I.url) {
10730
+ let F = I.layer?.name ? ` ${i.bold(I.layer.name)}` : '';
10616
10731
  if (
10617
- (process.stdout.write(` [${v.type.toUpperCase()}]${F} ${i.cyan(i.underline(v.url))}
10732
+ (process.stdout.write(` [${I.type.toUpperCase()}]${F} ${i.cyan(i.underline(I.url))}
10618
10733
  `),
10619
10734
  d)
10620
10735
  ) {
10621
10736
  let q = Oa(d, h++, w),
10622
10737
  yt = new $(`Downloading output to ${q}...`).start();
10623
10738
  try {
10624
- (await u.downloadOutput(v.url, O.default.resolve(process.cwd(), q)),
10739
+ (await u.downloadOutput(I.url, O.default.resolve(process.cwd(), q)),
10625
10740
  yt.succeed(`Saved to ${i.bold(q)}`));
10626
10741
  } catch (Me) {
10627
10742
  yt.fail(`Failed to download: ${Me instanceof Error ? Me.message : Me}`);
10628
10743
  }
10629
10744
  }
10630
10745
  } else
10631
- v.text &&
10746
+ I.text &&
10632
10747
  process.stdout.write(`
10633
- ${v.text}
10748
+ ${I.text}
10634
10749
  `);
10635
10750
  }
10636
10751
  }
@@ -10638,10 +10753,10 @@ ${v.text}
10638
10753
  `);
10639
10754
  }
10640
10755
  var Cr = M(require('node:readline'));
10641
- A();
10756
+ R();
10642
10757
  async function qa(e) {
10643
10758
  try {
10644
- return (await new S(e, x()).checkKey(), 'ok');
10759
+ return (await new K(e, x()).checkKey(), 'ok');
10645
10760
  } catch (t) {
10646
10761
  if (t instanceof b) {
10647
10762
  if (t.status === 401) return 'invalid';
@@ -10746,7 +10861,7 @@ ${i.bold('Tein AI CLI Configuration')}
10746
10861
  }
10747
10862
  }
10748
10863
  }
10749
- A();
10864
+ R();
10750
10865
  function P(e) {
10751
10866
  return e !== 0 && Math.abs(e) < 0.01
10752
10867
  ? `$${e.toFixed(6).replace(/0+$/, '').replace(/\.$/, '')}`
@@ -10802,7 +10917,7 @@ async function Rr(e) {
10802
10917
  process.exit(1));
10803
10918
  let n;
10804
10919
  try {
10805
- n = await new S(t, r).getBalance();
10920
+ n = await new K(t, r).getBalance();
10806
10921
  } catch (s) {
10807
10922
  (s instanceof b &&
10808
10923
  (a
@@ -10815,7 +10930,7 @@ async function Rr(e) {
10815
10930
  `
10816
10931
  `,
10817
10932
  )
10818
- : process.stderr.write(`${i.red('Error:')} ${K(s).join(`
10933
+ : process.stderr.write(`${i.red('Error:')} ${E(s).join(`
10819
10934
  `)}
10820
10935
  `),
10821
10936
  process.exit(s.exitCode)),
@@ -10838,7 +10953,7 @@ ${Da(n).join(`
10838
10953
 
10839
10954
  `);
10840
10955
  }
10841
- A();
10956
+ R();
10842
10957
  function Or(e) {
10843
10958
  let t = _(typeof e.api_key == 'string' ? e.api_key : void 0),
10844
10959
  r = x(typeof e.api_url == 'string' ? e.api_url : void 0);
@@ -10850,7 +10965,7 @@ function Or(e) {
10850
10965
  .write(`Please run ${i.cyan('tein auth login')} or set ${i.cyan('TEIN_API_KEY')} environment variable.
10851
10966
  `),
10852
10967
  process.exit(1)),
10853
- new S(t, r)
10968
+ new K(t, r)
10854
10969
  );
10855
10970
  }
10856
10971
  function qr(e, t) {
@@ -10876,7 +10991,7 @@ async function Lr(e, t) {
10876
10991
  `
10877
10992
  `,
10878
10993
  )
10879
- : process.stderr.write(`${i.red('Error:')} ${K(r).join(`
10994
+ : process.stderr.write(`${i.red('Error:')} ${E(r).join(`
10880
10995
  `)}
10881
10996
  `),
10882
10997
  process.exit(r.exitCode)),
@@ -10943,7 +11058,7 @@ ${Na(a).join(`
10943
11058
 
10944
11059
  `);
10945
11060
  }
10946
- function Ua(e) {
11061
+ function Va(e) {
10947
11062
  return e.data.length
10948
11063
  ? lt([
10949
11064
  ['When (UTC)', 'Amount', 'Balance after', 'What'],
@@ -10975,18 +11090,18 @@ async function Nr(e) {
10975
11090
  : '';
10976
11091
  process.stdout.write(`
10977
11092
  ${i.bold('Tein balance history')}
10978
- ${Ua(a).join(`
11093
+ ${Va(a).join(`
10979
11094
  `)}${n}
10980
11095
 
10981
11096
  `);
10982
11097
  }
10983
- A();
11098
+ R();
10984
11099
  Ae();
10985
11100
  ie();
10986
- A();
11101
+ R();
10987
11102
  dt();
10988
- var Va = 1e4,
10989
- Ur = {
11103
+ var Ua = 1e4,
11104
+ Vr = {
10990
11105
  price: '',
10991
11106
  creativeMode: 'Creative mode',
10992
11107
  priority: 'Priority',
@@ -10996,7 +11111,7 @@ var Va = 1e4,
10996
11111
  priorityDraft: 'Priority + Draft',
10997
11112
  creativeModePriorityDraft: 'Creative mode + Priority + Draft',
10998
11113
  },
10999
- Fa = Object.keys(Ur),
11114
+ Fa = Object.keys(Vr),
11000
11115
  Ba = {
11001
11116
  creativeMode: 'unfiltered',
11002
11117
  creativeModePriority: 'unfilteredPriority',
@@ -11008,11 +11123,11 @@ function ja(e, t) {
11008
11123
  return e[t] ?? (r ? e[r] : void 0);
11009
11124
  }
11010
11125
  async function Ga(e, t, r = _()) {
11011
- let a = `${x(e)}${ve(t)}`,
11126
+ let a = `${x(e)}${Ie(t)}`,
11012
11127
  n;
11013
11128
  try {
11014
11129
  n = await fetch(a, {
11015
- signal: AbortSignal.timeout(Va),
11130
+ signal: AbortSignal.timeout(Ua),
11016
11131
  ...(r ? { headers: { Authorization: `Bearer ${r}` } } : {}),
11017
11132
  });
11018
11133
  } catch {
@@ -11041,14 +11156,14 @@ function X(e) {
11041
11156
  r = typeof e.scale == 'number' ? e.scale : t;
11042
11157
  return `Starter ${Te(e.starter)} Plus ${Te(t)} Scale ${Te(r)}`;
11043
11158
  }
11044
- function Vr(e) {
11045
- let t = Ur[e];
11159
+ function Ur(e) {
11160
+ let t = Vr[e];
11046
11161
  return t ? ` (${t})` : '';
11047
11162
  }
11048
11163
  function pt(e) {
11049
11164
  let t = X(e.price) ?? '',
11050
11165
  r = e.public ? ` ${i.dim(`(published Starter ${Te(e.public.starter)})`)}` : '';
11051
- return `${e.label}${Vr(e.table)} ${t}${r}`;
11166
+ return `${e.label}${Ur(e.table)} ${t}${r}`;
11052
11167
  }
11053
11168
  function ct(e, t, r, a = !1) {
11054
11169
  return `${e}|${a ? 'edit/' : ''}${t}|${r}`;
@@ -11078,7 +11193,7 @@ function Wa(e, t, r, a, n) {
11078
11193
  for (let o of Fa) {
11079
11194
  let d = X(ja(t, o));
11080
11195
  if (!d) continue;
11081
- let l = Vr(o);
11196
+ let l = Ur(o);
11082
11197
  r.push(` ${s}${l} ${d}`);
11083
11198
  let c = a.get(ct(e, String(t.id ?? ''), o));
11084
11199
  c && (n.add(c), r.push(` ${i.yellow('Your price')} ${X(c.price) ?? ''}`));
@@ -11157,9 +11272,9 @@ function Ya(e) {
11157
11272
  for (let [g, f] of m) {
11158
11273
  let C = String(f[0]?.modelName ?? g);
11159
11274
  t.push(` ${i.bold(g.padEnd(26))} ${i.gray(C)}`);
11160
- for (let V of f) {
11161
- let w = String(V.displayLabel ?? V.billingUnit ?? 'price'),
11162
- h = X(V.prices);
11275
+ for (let U of f) {
11276
+ let w = String(U.displayLabel ?? U.billingUnit ?? 'price'),
11277
+ h = X(U.prices);
11163
11278
  h && t.push(` ${w} ${h}`);
11164
11279
  }
11165
11280
  t.push('');
@@ -11366,7 +11481,7 @@ ${i.bold(i.cyan(r.name))} (${i.bold(r.slug)})
11366
11481
  `);
11367
11482
  }
11368
11483
  var zr = M(require('node:path'));
11369
- A();
11484
+ R();
11370
11485
  async function Wr(e, t) {
11371
11486
  let r = _(typeof t.api_key == 'string' ? t.api_key : void 0),
11372
11487
  a = x(typeof t.api_url == 'string' ? t.api_url : void 0);
@@ -11386,7 +11501,7 @@ async function Wr(e, t) {
11386
11501
  let n = !!t.json,
11387
11502
  s = !!t.wait,
11388
11503
  o = typeof t.output == 'string' ? t.output : void 0,
11389
- d = new S(r, a),
11504
+ d = new K(r, a),
11390
11505
  l = new $(`Checking status of ${i.bold(e)}...`);
11391
11506
  n || l.start();
11392
11507
  let c;
@@ -11405,7 +11520,7 @@ async function Wr(e, t) {
11405
11520
  `,
11406
11521
  )
11407
11522
  : l.fail(
11408
- K(p).join(`
11523
+ E(p).join(`
11409
11524
  `),
11410
11525
  ),
11411
11526
  process.exit(p.exitCode)),
@@ -11479,7 +11594,7 @@ ${p.text}
11479
11594
  }
11480
11595
  var ut = M(require('node:fs')),
11481
11596
  mt = M(require('node:path'));
11482
- A();
11597
+ R();
11483
11598
  async function Jr(e, t = {}) {
11484
11599
  let r = _(typeof t.api_key == 'string' ? t.api_key : void 0),
11485
11600
  a = x(typeof t.api_url == 'string' ? t.api_url : void 0),
@@ -11504,7 +11619,7 @@ async function Jr(e, t = {}) {
11504
11619
  process.exit(1));
11505
11620
  let o = mt.default.basename(s),
11506
11621
  l = ut.default.readFileSync(s).toString('base64'),
11507
- c = new S(r, a),
11622
+ c = new K(r, a),
11508
11623
  p = new $(`Uploading ${i.bold(o)} to Tein AI CDN...`);
11509
11624
  n || p.start();
11510
11625
  try {
@@ -11529,7 +11644,7 @@ ${i.bold('CDN URL:')} ${i.green(u.url)}
11529
11644
  } catch (u) {
11530
11645
  let m = u instanceof b ? u : null,
11531
11646
  g = m
11532
- ? K(m).join(`
11647
+ ? E(m).join(`
11533
11648
  `)
11534
11649
  : u instanceof Error
11535
11650
  ? u.message
@@ -11739,7 +11854,7 @@ Run ${i.cyan('tein --help')} for the commands, or ${i.cyan('tein models')} for t
11739
11854
  _n().catch((e) => {
11740
11855
  (e instanceof b &&
11741
11856
  (process.stderr.write(`
11742
- ${i.red('Error:')} ${K(e).join(`
11857
+ ${i.red('Error:')} ${E(e).join(`
11743
11858
  `)}
11744
11859
  `),
11745
11860
  process.exit(e.exitCode)),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teinai/cli",
3
- "version": "1.1.41",
3
+ "version": "1.1.42",
4
4
  "description": "Official CLI for Tein AI models (Video, Image, Audio, LLM, 3D)",
5
5
  "main": "index.js",
6
6
  "bin": {