@vibeframe/cli 0.111.3 → 0.112.0

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
@@ -7844,7 +7844,7 @@ function errorMessage(error) {
7844
7844
  return error instanceof Error ? error.message : "Unknown error";
7845
7845
  }
7846
7846
  function sleep(ms) {
7847
- return new Promise((resolve85) => setTimeout(resolve85, ms));
7847
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
7848
7848
  }
7849
7849
  var ProviderHttpError;
7850
7850
  var init_http = __esm({
@@ -11612,15 +11612,15 @@ async function loadKokoroFactory() {
11612
11612
  }
11613
11613
  async function loadKokoroFromWorkspace(baseDir = process.cwd()) {
11614
11614
  try {
11615
- const { readFile: readFile55 } = await import("node:fs/promises");
11616
- const { join: join29, resolve: resolve85 } = await import("node:path");
11615
+ const { readFile: readFile56 } = await import("node:fs/promises");
11616
+ const { join: join30, resolve: resolve86 } = await import("node:path");
11617
11617
  const { pathToFileURL } = await import("node:url");
11618
- const pkgDir = resolve85(baseDir, "node_modules", "kokoro-js");
11619
- const pkg = JSON.parse(await readFile55(join29(pkgDir, "package.json"), "utf-8"));
11618
+ const pkgDir = resolve86(baseDir, "node_modules", "kokoro-js");
11619
+ const pkg = JSON.parse(await readFile56(join30(pkgDir, "package.json"), "utf-8"));
11620
11620
  const entry = pkg.exports?.node?.import ?? pkg.exports?.default ?? pkg.module ?? pkg.main;
11621
11621
  if (!entry)
11622
11622
  return null;
11623
- const mod = await import(pathToFileURL(join29(pkgDir, entry)).href);
11623
+ const mod = await import(pathToFileURL(join30(pkgDir, entry)).href);
11624
11624
  return mod.KokoroTTS ?? null;
11625
11625
  } catch {
11626
11626
  return null;
@@ -12278,7 +12278,7 @@ var init_RunwayProvider = __esm({
12278
12278
  * Sleep helper
12279
12279
  */
12280
12280
  sleep(ms) {
12281
- return new Promise((resolve85) => setTimeout(resolve85, ms));
12281
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
12282
12282
  }
12283
12283
  };
12284
12284
  RunwayProvider.API_VERSION = "2024-11-06";
@@ -12719,7 +12719,7 @@ var init_KlingProvider = __esm({
12719
12719
  * Sleep helper
12720
12720
  */
12721
12721
  sleep(ms) {
12722
- return new Promise((resolve85) => setTimeout(resolve85, ms));
12722
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
12723
12723
  }
12724
12724
  };
12725
12725
  klingProvider = new KlingProvider();
@@ -13037,7 +13037,7 @@ var init_GrokProvider = __esm({
13037
13037
  }
13038
13038
  }
13039
13039
  sleep(ms) {
13040
- return new Promise((resolve85) => setTimeout(resolve85, ms));
13040
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
13041
13041
  }
13042
13042
  };
13043
13043
  grokProvider = new GrokProvider();
@@ -13072,11 +13072,11 @@ var require_middleware = __commonJS({
13072
13072
  "use strict";
13073
13073
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
13074
13074
  function adopt(value) {
13075
- return value instanceof P ? value : new P(function(resolve85) {
13076
- resolve85(value);
13075
+ return value instanceof P ? value : new P(function(resolve86) {
13076
+ resolve86(value);
13077
13077
  });
13078
13078
  }
13079
- return new (P || (P = Promise))(function(resolve85, reject) {
13079
+ return new (P || (P = Promise))(function(resolve86, reject) {
13080
13080
  function fulfilled(value) {
13081
13081
  try {
13082
13082
  step(generator.next(value));
@@ -13092,7 +13092,7 @@ var require_middleware = __commonJS({
13092
13092
  }
13093
13093
  }
13094
13094
  function step(result) {
13095
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
13095
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
13096
13096
  }
13097
13097
  step((generator = generator.apply(thisArg, _arguments || [])).next());
13098
13098
  });
@@ -13177,11 +13177,11 @@ var require_response = __commonJS({
13177
13177
  "use strict";
13178
13178
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
13179
13179
  function adopt(value) {
13180
- return value instanceof P ? value : new P(function(resolve85) {
13181
- resolve85(value);
13180
+ return value instanceof P ? value : new P(function(resolve86) {
13181
+ resolve86(value);
13182
13182
  });
13183
13183
  }
13184
- return new (P || (P = Promise))(function(resolve85, reject) {
13184
+ return new (P || (P = Promise))(function(resolve86, reject) {
13185
13185
  function fulfilled(value) {
13186
13186
  try {
13187
13187
  step(generator.next(value));
@@ -13197,7 +13197,7 @@ var require_response = __commonJS({
13197
13197
  }
13198
13198
  }
13199
13199
  function step(result) {
13200
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
13200
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
13201
13201
  }
13202
13202
  step((generator = generator.apply(thisArg, _arguments || [])).next());
13203
13203
  });
@@ -13304,11 +13304,11 @@ var require_utils = __commonJS({
13304
13304
  "use strict";
13305
13305
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
13306
13306
  function adopt(value) {
13307
- return value instanceof P ? value : new P(function(resolve85) {
13308
- resolve85(value);
13307
+ return value instanceof P ? value : new P(function(resolve86) {
13308
+ resolve86(value);
13309
13309
  });
13310
13310
  }
13311
- return new (P || (P = Promise))(function(resolve85, reject) {
13311
+ return new (P || (P = Promise))(function(resolve86, reject) {
13312
13312
  function fulfilled(value) {
13313
13313
  try {
13314
13314
  step(generator.next(value));
@@ -13324,7 +13324,7 @@ var require_utils = __commonJS({
13324
13324
  }
13325
13325
  }
13326
13326
  function step(result) {
13327
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
13327
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
13328
13328
  }
13329
13329
  step((generator = generator.apply(thisArg, _arguments || [])).next());
13330
13330
  });
@@ -13417,7 +13417,7 @@ var require_utils = __commonJS({
13417
13417
  }
13418
13418
  function sleep4(ms) {
13419
13419
  return __awaiter(this, void 0, void 0, function* () {
13420
- return new Promise((resolve85) => setTimeout(resolve85, ms));
13420
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
13421
13421
  });
13422
13422
  }
13423
13423
  }
@@ -13429,11 +13429,11 @@ var require_retry = __commonJS({
13429
13429
  "use strict";
13430
13430
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
13431
13431
  function adopt(value) {
13432
- return value instanceof P ? value : new P(function(resolve85) {
13433
- resolve85(value);
13432
+ return value instanceof P ? value : new P(function(resolve86) {
13433
+ resolve86(value);
13434
13434
  });
13435
13435
  }
13436
- return new (P || (P = Promise))(function(resolve85, reject) {
13436
+ return new (P || (P = Promise))(function(resolve86, reject) {
13437
13437
  function fulfilled(value) {
13438
13438
  try {
13439
13439
  step(generator.next(value));
@@ -13449,7 +13449,7 @@ var require_retry = __commonJS({
13449
13449
  }
13450
13450
  }
13451
13451
  function step(result) {
13452
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
13452
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
13453
13453
  }
13454
13454
  step((generator = generator.apply(thisArg, _arguments || [])).next());
13455
13455
  });
@@ -13656,11 +13656,11 @@ var require_request = __commonJS({
13656
13656
  "use strict";
13657
13657
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
13658
13658
  function adopt(value) {
13659
- return value instanceof P ? value : new P(function(resolve85) {
13660
- resolve85(value);
13659
+ return value instanceof P ? value : new P(function(resolve86) {
13660
+ resolve86(value);
13661
13661
  });
13662
13662
  }
13663
- return new (P || (P = Promise))(function(resolve85, reject) {
13663
+ return new (P || (P = Promise))(function(resolve86, reject) {
13664
13664
  function fulfilled(value) {
13665
13665
  try {
13666
13666
  step(generator.next(value));
@@ -13676,7 +13676,7 @@ var require_request = __commonJS({
13676
13676
  }
13677
13677
  }
13678
13678
  function step(result) {
13679
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
13679
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
13680
13680
  }
13681
13681
  step((generator = generator.apply(thisArg, _arguments || [])).next());
13682
13682
  });
@@ -13763,11 +13763,11 @@ var require_storage = __commonJS({
13763
13763
  "use strict";
13764
13764
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
13765
13765
  function adopt(value) {
13766
- return value instanceof P ? value : new P(function(resolve85) {
13767
- resolve85(value);
13766
+ return value instanceof P ? value : new P(function(resolve86) {
13767
+ resolve86(value);
13768
13768
  });
13769
13769
  }
13770
- return new (P || (P = Promise))(function(resolve85, reject) {
13770
+ return new (P || (P = Promise))(function(resolve86, reject) {
13771
13771
  function fulfilled(value) {
13772
13772
  try {
13773
13773
  step(generator.next(value));
@@ -13783,7 +13783,7 @@ var require_storage = __commonJS({
13783
13783
  }
13784
13784
  }
13785
13785
  function step(result) {
13786
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
13786
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
13787
13787
  }
13788
13788
  step((generator = generator.apply(thisArg, _arguments || [])).next());
13789
13789
  });
@@ -14111,11 +14111,11 @@ var require_auth = __commonJS({
14111
14111
  "use strict";
14112
14112
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
14113
14113
  function adopt(value) {
14114
- return value instanceof P ? value : new P(function(resolve85) {
14115
- resolve85(value);
14114
+ return value instanceof P ? value : new P(function(resolve86) {
14115
+ resolve86(value);
14116
14116
  });
14117
14117
  }
14118
- return new (P || (P = Promise))(function(resolve85, reject) {
14118
+ return new (P || (P = Promise))(function(resolve86, reject) {
14119
14119
  function fulfilled(value) {
14120
14120
  try {
14121
14121
  step(generator.next(value));
@@ -14131,7 +14131,7 @@ var require_auth = __commonJS({
14131
14131
  }
14132
14132
  }
14133
14133
  function step(result) {
14134
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
14134
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
14135
14135
  }
14136
14136
  step((generator = generator.apply(thisArg, _arguments || [])).next());
14137
14137
  });
@@ -14170,11 +14170,11 @@ var require_streaming = __commonJS({
14170
14170
  "use strict";
14171
14171
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
14172
14172
  function adopt(value) {
14173
- return value instanceof P ? value : new P(function(resolve85) {
14174
- resolve85(value);
14173
+ return value instanceof P ? value : new P(function(resolve86) {
14174
+ resolve86(value);
14175
14175
  });
14176
14176
  }
14177
- return new (P || (P = Promise))(function(resolve85, reject) {
14177
+ return new (P || (P = Promise))(function(resolve86, reject) {
14178
14178
  function fulfilled(value) {
14179
14179
  try {
14180
14180
  step(generator.next(value));
@@ -14190,7 +14190,7 @@ var require_streaming = __commonJS({
14190
14190
  }
14191
14191
  }
14192
14192
  function step(result) {
14193
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
14193
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
14194
14194
  }
14195
14195
  step((generator = generator.apply(thisArg, _arguments || [])).next());
14196
14196
  });
@@ -14423,7 +14423,7 @@ var require_streaming = __commonJS({
14423
14423
  query: options.queryParams
14424
14424
  });
14425
14425
  this.options = options;
14426
- this.donePromise = new Promise((resolve85, reject) => {
14426
+ this.donePromise = new Promise((resolve86, reject) => {
14427
14427
  if (this.streamClosed) {
14428
14428
  reject(new response_1.ApiError({
14429
14429
  message: "Streaming connection is already closed.",
@@ -14434,11 +14434,11 @@ var require_streaming = __commonJS({
14434
14434
  }
14435
14435
  this.signal.addEventListener("abort", () => {
14436
14436
  var _a2;
14437
- resolve85((_a2 = this.currentData) !== null && _a2 !== void 0 ? _a2 : {});
14437
+ resolve86((_a2 = this.currentData) !== null && _a2 !== void 0 ? _a2 : {});
14438
14438
  });
14439
14439
  this.on("done", (data) => {
14440
14440
  this.streamClosed = true;
14441
- resolve85(data);
14441
+ resolve86(data);
14442
14442
  });
14443
14443
  this.on("error", (error) => {
14444
14444
  this.streamClosed = true;
@@ -14463,7 +14463,7 @@ var require_streaming = __commonJS({
14463
14463
  if (data) {
14464
14464
  yield yield __await(data);
14465
14465
  }
14466
- yield __await(new Promise((resolve85) => setTimeout(resolve85, 16)));
14466
+ yield __await(new Promise((resolve86) => setTimeout(resolve86, 16)));
14467
14467
  }
14468
14468
  });
14469
14469
  }
@@ -14508,11 +14508,11 @@ var require_queue = __commonJS({
14508
14508
  "use strict";
14509
14509
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
14510
14510
  function adopt(value) {
14511
- return value instanceof P ? value : new P(function(resolve85) {
14512
- resolve85(value);
14511
+ return value instanceof P ? value : new P(function(resolve86) {
14512
+ resolve86(value);
14513
14513
  });
14514
14514
  }
14515
- return new (P || (P = Promise))(function(resolve85, reject) {
14515
+ return new (P || (P = Promise))(function(resolve86, reject) {
14516
14516
  function fulfilled(value) {
14517
14517
  try {
14518
14518
  step(generator.next(value));
@@ -14528,7 +14528,7 @@ var require_queue = __commonJS({
14528
14528
  }
14529
14529
  }
14530
14530
  function step(result) {
14531
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
14531
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
14532
14532
  }
14533
14533
  step((generator = generator.apply(thisArg, _arguments || [])).next());
14534
14534
  });
@@ -14663,7 +14663,7 @@ var require_queue = __commonJS({
14663
14663
  }
14664
14664
  return doneStatus;
14665
14665
  }
14666
- return new Promise((resolve85, reject) => {
14666
+ return new Promise((resolve86, reject) => {
14667
14667
  var _a;
14668
14668
  let pollingTimeoutId;
14669
14669
  const pollInterval = "pollInterval" in options && typeof options.pollInterval === "number" ? (_a = options.pollInterval) !== null && _a !== void 0 ? _a : DEFAULT_POLL_INTERVAL : DEFAULT_POLL_INTERVAL;
@@ -14695,7 +14695,7 @@ var require_queue = __commonJS({
14695
14695
  }
14696
14696
  if (requestStatus.status === "COMPLETED") {
14697
14697
  clearScheduledTasks();
14698
- resolve85(requestStatus);
14698
+ resolve86(requestStatus);
14699
14699
  return;
14700
14700
  }
14701
14701
  pollingTimeoutId = setTimeout(poll, pollInterval);
@@ -16656,11 +16656,11 @@ var require_realtime = __commonJS({
16656
16656
  "use strict";
16657
16657
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
16658
16658
  function adopt(value) {
16659
- return value instanceof P ? value : new P(function(resolve85) {
16660
- resolve85(value);
16659
+ return value instanceof P ? value : new P(function(resolve86) {
16660
+ resolve86(value);
16661
16661
  });
16662
16662
  }
16663
- return new (P || (P = Promise))(function(resolve85, reject) {
16663
+ return new (P || (P = Promise))(function(resolve86, reject) {
16664
16664
  function fulfilled(value) {
16665
16665
  try {
16666
16666
  step(generator.next(value));
@@ -16676,7 +16676,7 @@ var require_realtime = __commonJS({
16676
16676
  }
16677
16677
  }
16678
16678
  function step(result) {
16679
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
16679
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
16680
16680
  }
16681
16681
  step((generator = generator.apply(thisArg, _arguments || [])).next());
16682
16682
  });
@@ -17001,11 +17001,11 @@ var require_client = __commonJS({
17001
17001
  "use strict";
17002
17002
  var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) {
17003
17003
  function adopt(value) {
17004
- return value instanceof P ? value : new P(function(resolve85) {
17005
- resolve85(value);
17004
+ return value instanceof P ? value : new P(function(resolve86) {
17005
+ resolve86(value);
17006
17006
  });
17007
17007
  }
17008
- return new (P || (P = Promise))(function(resolve85, reject) {
17008
+ return new (P || (P = Promise))(function(resolve86, reject) {
17009
17009
  function fulfilled(value) {
17010
17010
  try {
17011
17011
  step(generator.next(value));
@@ -17021,7 +17021,7 @@ var require_client = __commonJS({
17021
17021
  }
17022
17022
  }
17023
17023
  function step(result) {
17024
- result.done ? resolve85(result.value) : adopt(result.value).then(fulfilled, rejected);
17024
+ result.done ? resolve86(result.value) : adopt(result.value).then(fulfilled, rejected);
17025
17025
  }
17026
17026
  step((generator = generator.apply(thisArg, _arguments || [])).next());
17027
17027
  });
@@ -17706,7 +17706,7 @@ var init_ReplicateProvider = __esm({
17706
17706
  * Sleep helper
17707
17707
  */
17708
17708
  sleep(ms) {
17709
- return new Promise((resolve85) => setTimeout(resolve85, ms));
17709
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
17710
17710
  }
17711
17711
  /**
17712
17712
  * Generate music from text prompt using MusicGen
@@ -26180,7 +26180,7 @@ async function prompt(question, hidden = false) {
26180
26180
  input: process.stdin,
26181
26181
  output: process.stdout
26182
26182
  });
26183
- return new Promise((resolve85) => {
26183
+ return new Promise((resolve86) => {
26184
26184
  if (hidden && process.stdin.isTTY) {
26185
26185
  process.stdout.write(question);
26186
26186
  let input = "";
@@ -26194,7 +26194,7 @@ async function prompt(question, hidden = false) {
26194
26194
  process.stdin.removeListener("data", onData);
26195
26195
  process.stdout.write("\n");
26196
26196
  rl.close();
26197
- resolve85(input);
26197
+ resolve86(input);
26198
26198
  } else if (char === "") {
26199
26199
  process.exit(1);
26200
26200
  } else if (char === "\x7F" || char === "\b") {
@@ -26209,7 +26209,7 @@ async function prompt(question, hidden = false) {
26209
26209
  } else {
26210
26210
  rl.question(question, (answer) => {
26211
26211
  rl.close();
26212
- resolve85(answer);
26212
+ resolve86(answer);
26213
26213
  });
26214
26214
  }
26215
26215
  });
@@ -33767,16 +33767,16 @@ async function prompt2(question) {
33767
33767
  input,
33768
33768
  output: process.stdout
33769
33769
  });
33770
- return new Promise((resolve85) => {
33770
+ return new Promise((resolve86) => {
33771
33771
  rl.question(question, (answer) => {
33772
33772
  rl.close();
33773
- resolve85(answer);
33773
+ resolve86(answer);
33774
33774
  });
33775
33775
  });
33776
33776
  }
33777
33777
  async function promptHidden(question, opts = {}) {
33778
33778
  const input = getTTYInputStream();
33779
- return new Promise((resolve85) => {
33779
+ return new Promise((resolve86) => {
33780
33780
  let value = "";
33781
33781
  if (typeof input.setRawMode === "function") {
33782
33782
  input.setRawMode(true);
@@ -33790,7 +33790,7 @@ async function promptHidden(question, opts = {}) {
33790
33790
  input.setRawMode(false);
33791
33791
  input.removeListener("data", onData);
33792
33792
  process.stdout.write("\n");
33793
- resolve85(value);
33793
+ resolve86(value);
33794
33794
  } else if (char === "") {
33795
33795
  input.setRawMode(false);
33796
33796
  process.stdout.write("\n");
@@ -33816,7 +33816,7 @@ async function promptHidden(question, opts = {}) {
33816
33816
  const rl = createInterface2({ input, output: process.stdout });
33817
33817
  rl.question(question, (answer) => {
33818
33818
  rl.close();
33819
- resolve85(answer);
33819
+ resolve86(answer);
33820
33820
  });
33821
33821
  }
33822
33822
  });
@@ -33824,7 +33824,7 @@ async function promptHidden(question, opts = {}) {
33824
33824
  async function promptSelect(_question, options, defaultIndex = 0, opts = {}) {
33825
33825
  const input = getTTYInputStream();
33826
33826
  if (typeof input.setRawMode === "function") {
33827
- return new Promise((resolve85) => {
33827
+ return new Promise((resolve86) => {
33828
33828
  let selected = defaultIndex;
33829
33829
  const render = () => {
33830
33830
  if (renderCount > 0) {
@@ -33852,7 +33852,7 @@ async function promptSelect(_question, options, defaultIndex = 0, opts = {}) {
33852
33852
  input.setRawMode(false);
33853
33853
  input.removeListener("data", onData);
33854
33854
  process.stdout.write("\n");
33855
- resolve85(selected);
33855
+ resolve86(selected);
33856
33856
  } else if (char === "") {
33857
33857
  input.setRawMode(false);
33858
33858
  process.stdout.write("\n");
@@ -33862,7 +33862,7 @@ async function promptSelect(_question, options, defaultIndex = 0, opts = {}) {
33862
33862
  input.setRawMode(false);
33863
33863
  input.removeListener("data", onData);
33864
33864
  process.stdout.write("\n");
33865
- resolve85(opts.backIndex);
33865
+ resolve86(opts.backIndex);
33866
33866
  } else if (char === "\x1B[A" || char === "k") {
33867
33867
  selected = (selected - 1 + options.length) % options.length;
33868
33868
  render();
@@ -33876,7 +33876,7 @@ async function promptSelect(_question, options, defaultIndex = 0, opts = {}) {
33876
33876
  input.removeListener("data", onData);
33877
33877
  render();
33878
33878
  process.stdout.write("\n");
33879
- resolve85(selected);
33879
+ resolve86(selected);
33880
33880
  }
33881
33881
  };
33882
33882
  const onData = (chunk) => {
@@ -33900,7 +33900,7 @@ async function promptSelect(_question, options, defaultIndex = 0, opts = {}) {
33900
33900
  async function promptConfirm(question, defaultYes = true) {
33901
33901
  const input = getTTYInputStream();
33902
33902
  if (typeof input.setRawMode === "function") {
33903
- return new Promise((resolve85) => {
33903
+ return new Promise((resolve86) => {
33904
33904
  const options = ["Yes", "No"];
33905
33905
  let selected = defaultYes ? 0 : 1;
33906
33906
  let renderCount = 0;
@@ -33930,7 +33930,7 @@ async function promptConfirm(question, defaultYes = true) {
33930
33930
  finished = true;
33931
33931
  input.setRawMode(false);
33932
33932
  input.removeListener("data", onData);
33933
- resolve85(selected === 0);
33933
+ resolve86(selected === 0);
33934
33934
  } else if (char === "") {
33935
33935
  input.setRawMode(false);
33936
33936
  process.stdout.write("\n");
@@ -33944,14 +33944,14 @@ async function promptConfirm(question, defaultYes = true) {
33944
33944
  input.setRawMode(false);
33945
33945
  input.removeListener("data", onData);
33946
33946
  render();
33947
- resolve85(true);
33947
+ resolve86(true);
33948
33948
  } else if (char === "n" || char === "N") {
33949
33949
  selected = 1;
33950
33950
  finished = true;
33951
33951
  input.setRawMode(false);
33952
33952
  input.removeListener("data", onData);
33953
33953
  render();
33954
- resolve85(false);
33954
+ resolve86(false);
33955
33955
  }
33956
33956
  };
33957
33957
  const onData = (chunk) => {
@@ -33970,7 +33970,7 @@ async function promptMultiSelect(_question, options, defaultSelected = [], opts
33970
33970
  const input = getTTYInputStream();
33971
33971
  const selected = options.map((_, i) => Boolean(defaultSelected[i]));
33972
33972
  if (typeof input.setRawMode === "function") {
33973
- return new Promise((resolve85) => {
33973
+ return new Promise((resolve86) => {
33974
33974
  let cursor = 0;
33975
33975
  let renderCount = 0;
33976
33976
  let userToggled = false;
@@ -34000,7 +34000,7 @@ async function promptMultiSelect(_question, options, defaultSelected = [], opts
34000
34000
  for (let i = 0; i < selected.length; i++) {
34001
34001
  if (selected[i]) result.push(i);
34002
34002
  }
34003
- resolve85(result);
34003
+ resolve86(result);
34004
34004
  };
34005
34005
  let finished = false;
34006
34006
  const handleChar = (char) => {
@@ -34314,7 +34314,7 @@ var init_speech = __esm({
34314
34314
  import { writeFile as writeFile20, unlink, rename } from "node:fs/promises";
34315
34315
  import { resolve as resolve24, basename as basename4 } from "node:path";
34316
34316
  function sleep2(ms) {
34317
- return new Promise((resolve85) => setTimeout(resolve85, ms));
34317
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
34318
34318
  }
34319
34319
  async function uploadToImgbb(imageBuffer, apiKey) {
34320
34320
  try {
@@ -36051,7 +36051,7 @@ function unique(items) {
36051
36051
  ];
36052
36052
  }
36053
36053
  function sleep3(ms) {
36054
- return new Promise((resolve85) => setTimeout(resolve85, ms));
36054
+ return new Promise((resolve86) => setTimeout(resolve86, ms));
36055
36055
  }
36056
36056
  var LOCAL_JOB_ORPHAN_AFTER_MS;
36057
36057
  var init_status_jobs = __esm({
@@ -48424,8 +48424,8 @@ var init_FileTokenizer = __esm({
48424
48424
  */
48425
48425
  static async fromFile(sourceFilePath) {
48426
48426
  const fileHandle = await fsOpen(sourceFilePath, "r");
48427
- const stat10 = await fileHandle.stat();
48428
- return new _FileTokenizer(fileHandle, { fileInfo: { path: sourceFilePath, size: stat10.size } });
48427
+ const stat11 = await fileHandle.stat();
48428
+ return new _FileTokenizer(fileHandle, { fileInfo: { path: sourceFilePath, size: stat11.size } });
48429
48429
  }
48430
48430
  constructor(fileHandle, options) {
48431
48431
  super(options);
@@ -71027,17 +71027,158 @@ var init_timeline = __esm({
71027
71027
  }
71028
71028
  });
71029
71029
 
71030
+ // src/commands/_shared/project-list.ts
71031
+ import { readdir as readdir7, readFile as readFile53, stat as stat9 } from "node:fs/promises";
71032
+ import { existsSync as existsSync57 } from "node:fs";
71033
+ import { join as join28, resolve as resolve80 } from "node:path";
71034
+ async function executeProjectList(opts = {}) {
71035
+ const workspaceDir = resolve80(opts.workspaceDir ?? ".");
71036
+ if (!existsSync57(workspaceDir)) {
71037
+ return {
71038
+ success: false,
71039
+ workspaceDir,
71040
+ projects: [],
71041
+ archivedCount: 0,
71042
+ error: `Workspace directory not found: ${workspaceDir}`
71043
+ };
71044
+ }
71045
+ const entries = await readdir7(workspaceDir, { withFileTypes: true });
71046
+ const projects = [];
71047
+ let archivedCount = 0;
71048
+ for (const entry of entries) {
71049
+ if (!entry.isDirectory()) continue;
71050
+ if (entry.name === "node_modules") continue;
71051
+ if (entry.name.startsWith(".")) continue;
71052
+ if (entry.name.startsWith("_")) {
71053
+ archivedCount += await countProjects(join28(workspaceDir, entry.name));
71054
+ continue;
71055
+ }
71056
+ const projectDir = join28(workspaceDir, entry.name);
71057
+ if (!existsSync57(join28(projectDir, "STORYBOARD.md"))) continue;
71058
+ projects.push(await describeProject(entry.name, projectDir));
71059
+ }
71060
+ projects.sort((a, b) => b.updatedAt.localeCompare(a.updatedAt));
71061
+ return { success: true, workspaceDir, projects, archivedCount };
71062
+ }
71063
+ async function countProjects(dir) {
71064
+ try {
71065
+ const entries = await readdir7(dir, { withFileTypes: true });
71066
+ return entries.filter(
71067
+ (e) => e.isDirectory() && existsSync57(join28(dir, e.name, "STORYBOARD.md"))
71068
+ ).length;
71069
+ } catch {
71070
+ return 0;
71071
+ }
71072
+ }
71073
+ async function describeProject(name, projectDir) {
71074
+ let beats = 0;
71075
+ let storyboardDurationSec = 0;
71076
+ const timestamps = [];
71077
+ try {
71078
+ const storyboardPath2 = join28(projectDir, "STORYBOARD.md");
71079
+ const parsed = parseStoryboard(await readFile53(storyboardPath2, "utf-8"));
71080
+ beats = parsed.beats.length;
71081
+ storyboardDurationSec = Number(
71082
+ parsed.beats.reduce((sum, beat) => sum + (beat.duration ?? 0), 0).toFixed(2)
71083
+ );
71084
+ timestamps.push((await stat9(storyboardPath2)).mtimeMs);
71085
+ } catch {
71086
+ }
71087
+ let buildStatus;
71088
+ let buildUpdatedAt;
71089
+ try {
71090
+ const reportPath = join28(projectDir, "build-report.json");
71091
+ const report = JSON.parse(await readFile53(reportPath, "utf-8"));
71092
+ buildStatus = report.status ?? report.phase;
71093
+ buildUpdatedAt = report.updatedAt;
71094
+ timestamps.push((await stat9(reportPath)).mtimeMs);
71095
+ } catch {
71096
+ }
71097
+ let latestRender;
71098
+ try {
71099
+ const rendersDir = join28(projectDir, "renders");
71100
+ const files = await readdir7(rendersDir);
71101
+ let newest;
71102
+ for (const file of files) {
71103
+ if (!/\.(mp4|webm|mov)$/i.test(file)) continue;
71104
+ const { mtimeMs } = await stat9(join28(rendersDir, file));
71105
+ if (!newest || mtimeMs > newest.mtimeMs) newest = { file, mtimeMs };
71106
+ }
71107
+ if (newest) {
71108
+ latestRender = { file: newest.file, modifiedAt: new Date(newest.mtimeMs).toISOString() };
71109
+ timestamps.push(newest.mtimeMs);
71110
+ }
71111
+ } catch {
71112
+ }
71113
+ const updatedAt = new Date(
71114
+ timestamps.length > 0 ? Math.max(...timestamps) : (await stat9(projectDir)).mtimeMs
71115
+ ).toISOString();
71116
+ return {
71117
+ name,
71118
+ path: projectDir,
71119
+ beats,
71120
+ storyboardDurationSec,
71121
+ ...buildStatus ? { buildStatus } : {},
71122
+ ...buildUpdatedAt ? { buildUpdatedAt } : {},
71123
+ ...latestRender ? { latestRender } : {},
71124
+ updatedAt
71125
+ };
71126
+ }
71127
+ var init_project_list = __esm({
71128
+ "src/commands/_shared/project-list.ts"() {
71129
+ "use strict";
71130
+ init_storyboard_parse();
71131
+ }
71132
+ });
71133
+
71030
71134
  // src/tools/manifest/project.ts
71031
- import { resolve as resolve80 } from "node:path";
71135
+ import { resolve as resolve81 } from "node:path";
71032
71136
  import { writeFile as writeFile58 } from "node:fs/promises";
71033
- var projectCreateTool, projectInfoTool, projectTools;
71137
+ var projectListTool, projectCreateTool, projectInfoTool, projectTools;
71034
71138
  var init_project2 = __esm({
71035
71139
  "src/tools/manifest/project.ts"() {
71036
71140
  "use strict";
71037
71141
  init_zod();
71038
71142
  init_define_tool();
71039
71143
  init_engine();
71144
+ init_project_list();
71040
71145
  init_project_io();
71146
+ projectListTool = defineTool({
71147
+ name: "project_list",
71148
+ category: "project",
71149
+ cost: "free",
71150
+ title: "List Video Projects",
71151
+ annotations: { readOnly: true, openWorld: false },
71152
+ description: `List every VibeFrame video project in the workspace (directories with a STORYBOARD.md), newest activity first: beat count, storyboard duration, last build status, and the latest render. Directories starting with '_' (e.g. _archive) are skipped and reported as an archived count \u2014 move a project into _archive/ to retire it. Use this to answer "what projects do I have?" before init/build/render.`,
71153
+ schema: external_exports.object({
71154
+ dir: external_exports.string().optional().describe(
71155
+ "Workspace directory to scan. Defaults to the surface's cwd; in MCP hosts this is the configured server workspace."
71156
+ )
71157
+ }),
71158
+ async execute(args, ctx) {
71159
+ const result = await executeProjectList({
71160
+ workspaceDir: args.dir ? resolve81(ctx.workingDirectory, args.dir) : ctx.workingDirectory
71161
+ });
71162
+ if (!result.success) {
71163
+ return { success: false, error: result.error ?? "project list failed" };
71164
+ }
71165
+ return {
71166
+ success: true,
71167
+ data: {
71168
+ workspaceDir: result.workspaceDir,
71169
+ count: result.projects.length,
71170
+ archivedCount: result.archivedCount,
71171
+ projects: result.projects
71172
+ },
71173
+ humanLines: [
71174
+ `\u{1F4C1} ${result.projects.length} project(s) in ${result.workspaceDir}` + (result.archivedCount > 0 ? ` (+${result.archivedCount} archived)` : ""),
71175
+ ...result.projects.map(
71176
+ (p) => ` \u2022 ${p.name} \u2014 ${p.beats} beat(s), ~${p.storyboardDurationSec}s` + (p.buildStatus ? `, build: ${p.buildStatus}` : "") + (p.latestRender ? `, latest render: ${p.latestRender.file}` : "") + ` (updated ${p.updatedAt})`
71177
+ )
71178
+ ]
71179
+ };
71180
+ }
71181
+ });
71041
71182
  projectCreateTool = defineTool({
71042
71183
  name: "project_create",
71043
71184
  category: "project",
@@ -71053,7 +71194,7 @@ var init_project2 = __esm({
71053
71194
  fps: external_exports.number().optional().describe("Frames per second (default: 30)")
71054
71195
  }),
71055
71196
  async execute(args, ctx) {
71056
- const outputPath = resolve80(ctx.workingDirectory, args.outputPath ?? `${args.name}.vibe.json`);
71197
+ const outputPath = resolve81(ctx.workingDirectory, args.outputPath ?? `${args.name}.vibe.json`);
71057
71198
  const project = new Project(args.name);
71058
71199
  if (args.fps) project.setFrameRate(args.fps);
71059
71200
  await writeFile58(outputPath, JSON.stringify(project.toJSON(), null, 2), "utf-8");
@@ -71094,6 +71235,7 @@ var init_project2 = __esm({
71094
71235
  }
71095
71236
  });
71096
71237
  projectTools = [
71238
+ projectListTool,
71097
71239
  projectCreateTool,
71098
71240
  projectInfoTool
71099
71241
  ];
@@ -71101,8 +71243,8 @@ var init_project2 = __esm({
71101
71243
  });
71102
71244
 
71103
71245
  // src/commands/export.ts
71104
- import { readFile as readFile53, access as access7 } from "node:fs/promises";
71105
- import { resolve as resolve81, basename as basename24 } from "node:path";
71246
+ import { readFile as readFile54, access as access7 } from "node:fs/promises";
71247
+ import { resolve as resolve82, basename as basename24 } from "node:path";
71106
71248
  import { spawn as spawn3 } from "node:child_process";
71107
71249
  function timelineBaseName(path2) {
71108
71250
  const name = basename24(path2);
@@ -71170,7 +71312,7 @@ async function runExport(projectPath, outputPath, options = {}) {
71170
71312
  };
71171
71313
  }
71172
71314
  const filePath = await resolveTimelineFile(projectPath);
71173
- const content = await readFile53(filePath, "utf-8");
71315
+ const content = await readFile54(filePath, "utf-8");
71174
71316
  const data = JSON.parse(content);
71175
71317
  const project = Project.fromJSON(data);
71176
71318
  const summary = project.getSummary();
@@ -71180,7 +71322,7 @@ async function runExport(projectPath, outputPath, options = {}) {
71180
71322
  message: "Project has no clips to export"
71181
71323
  };
71182
71324
  }
71183
- const finalOutputPath = resolve81(process.cwd(), outputPath);
71325
+ const finalOutputPath = resolve82(process.cwd(), outputPath);
71184
71326
  const basePresetSettings = getPresetSettings(preset, summary.aspectRatio);
71185
71327
  const presetSettings = applyCustomOverrides(basePresetSettings, { bitrate, fps, resolution, codec });
71186
71328
  const clips = project.getClips().sort((a, b) => a.startTime - b.startTime);
@@ -71576,7 +71718,7 @@ function buildFFmpegArgs(clips, sources, presetSettings, outputPath, options, so
71576
71718
  return args;
71577
71719
  }
71578
71720
  function runFFmpegProcess(ffmpegPath, args, onProgress) {
71579
- return new Promise((resolve85, reject) => {
71721
+ return new Promise((resolve86, reject) => {
71580
71722
  const ffmpeg = spawn3(ffmpegPath, args, {
71581
71723
  stdio: ["pipe", "pipe", "pipe"]
71582
71724
  });
@@ -71600,7 +71742,7 @@ function runFFmpegProcess(ffmpegPath, args, onProgress) {
71600
71742
  });
71601
71743
  ffmpeg.on("close", (code) => {
71602
71744
  if (code === 0) {
71603
- resolve85();
71745
+ resolve86();
71604
71746
  } else {
71605
71747
  const errorMatch = stderr.match(/Error.*$/m);
71606
71748
  const errorMsg = errorMatch ? errorMatch[0] : `FFmpeg exited with code ${code}`;
@@ -71736,17 +71878,17 @@ function getPresetSettings(preset, aspectRatio2) {
71736
71878
  }
71737
71879
  async function runHyperframesExport(projectPath, options, spinner2, startedAt) {
71738
71880
  spinner2.text = "Loading project...";
71739
- const { readFile: readFile55 } = await import("node:fs/promises");
71740
- const { resolve: resolve85 } = await import("node:path");
71881
+ const { readFile: readFile56 } = await import("node:fs/promises");
71882
+ const { resolve: resolve86 } = await import("node:path");
71741
71883
  const { Project: Project2 } = await Promise.resolve().then(() => (init_engine(), engine_exports));
71742
71884
  const { createHyperframesBackend: createHyperframesBackend2 } = await Promise.resolve().then(() => (init_hyperframes(), hyperframes_exports));
71743
71885
  const { exitWithError: exitWithError2, generalError: generalError2, outputSuccess: outputSuccess2 } = await Promise.resolve().then(() => (init_output(), output_exports));
71744
71886
  const chalk2 = (await Promise.resolve().then(() => (init_source(), source_exports))).default;
71745
71887
  const filePath = await resolveTimelineFile(projectPath);
71746
- const content = await readFile55(filePath, "utf-8");
71888
+ const content = await readFile56(filePath, "utf-8");
71747
71889
  const project = Project2.fromJSON(JSON.parse(content));
71748
71890
  const state = project.getState();
71749
- const outputPath = options.output ? resolve85(process.cwd(), options.output) : resolve85(process.cwd(), `${timelineBaseName(projectPath)}.${options.format ?? "mp4"}`);
71891
+ const outputPath = options.output ? resolve86(process.cwd(), options.output) : resolve86(process.cwd(), `${timelineBaseName(projectPath)}.${options.format ?? "mp4"}`);
71750
71892
  const quality = ["draft", "standard", "high"].includes(options.preset ?? "") ? options.preset : "standard";
71751
71893
  const backend = createHyperframesBackend2();
71752
71894
  spinner2.text = "Rendering with Hyperframes...";
@@ -71865,7 +72007,7 @@ Run 'vibe schema export' for structured parameter info.`).action(async (projectP
71865
72007
  }
71866
72008
  spinner2.text = "Loading project...";
71867
72009
  const filePath = await resolveTimelineFile(projectPath);
71868
- const content = await readFile53(filePath, "utf-8");
72010
+ const content = await readFile54(filePath, "utf-8");
71869
72011
  const data = JSON.parse(content);
71870
72012
  const project = Project.fromJSON(data);
71871
72013
  const summary = project.getSummary();
@@ -71873,7 +72015,7 @@ Run 'vibe schema export' for structured parameter info.`).action(async (projectP
71873
72015
  spinner2.fail("Project has no clips to export");
71874
72016
  exitWithError(usageError("Project has no clips to export"));
71875
72017
  }
71876
- const outputPath = options.output ? resolve81(process.cwd(), options.output) : resolve81(
72018
+ const outputPath = options.output ? resolve82(process.cwd(), options.output) : resolve82(
71877
72019
  process.cwd(),
71878
72020
  `${timelineBaseName(projectPath)}.${options.format}`
71879
72021
  );
@@ -71957,7 +72099,7 @@ Run 'vibe schema export' for structured parameter info.`).action(async (projectP
71957
72099
  });
71958
72100
 
71959
72101
  // src/tools/manifest/export.ts
71960
- import { resolve as resolve82 } from "node:path";
72102
+ import { resolve as resolve83 } from "node:path";
71961
72103
  var exportVideoTool, exportTools;
71962
72104
  var init_export2 = __esm({
71963
72105
  "src/tools/manifest/export.ts"() {
@@ -71980,8 +72122,8 @@ var init_export2 = __esm({
71980
72122
  overwrite: external_exports.boolean().optional().describe("Overwrite existing output file (default: false)")
71981
72123
  }),
71982
72124
  async execute(args, ctx) {
71983
- const projectPath = resolve82(ctx.workingDirectory, args.projectPath);
71984
- const outputPath = resolve82(ctx.workingDirectory, args.outputPath);
72125
+ const projectPath = resolve83(ctx.workingDirectory, args.projectPath);
72126
+ const outputPath = resolve83(ctx.workingDirectory, args.outputPath);
71985
72127
  const result = await runExport(projectPath, outputPath, {
71986
72128
  preset: args.preset,
71987
72129
  format: args.format,
@@ -72000,8 +72142,8 @@ var init_export2 = __esm({
72000
72142
  });
72001
72143
 
72002
72144
  // src/tools/manifest/agent-only.ts
72003
- import { readFile as readFile54, writeFile as writeFile59, readdir as readdir7, stat as stat9, access as access8, unlink as unlink4 } from "node:fs/promises";
72004
- import { resolve as resolve83, join as join28, basename as basename25, extname as extname16 } from "node:path";
72145
+ import { readFile as readFile55, writeFile as writeFile59, readdir as readdir8, stat as stat10, access as access8, unlink as unlink4 } from "node:fs/promises";
72146
+ import { resolve as resolve84, join as join29, basename as basename25, extname as extname16 } from "node:path";
72005
72147
  function matchPattern(filename, pattern) {
72006
72148
  const regex2 = new RegExp(
72007
72149
  "^" + pattern.replace(/\./g, "\\.").replace(/\*/g, ".*").replace(/\?/g, ".") + "$",
@@ -72081,13 +72223,13 @@ var init_agent_only = __esm({
72081
72223
  async execute(args, ctx) {
72082
72224
  const dirPath = args.path ?? ".";
72083
72225
  try {
72084
- const absPath = resolve83(ctx.workingDirectory, dirPath);
72085
- const entries = await readdir7(absPath, { withFileTypes: true });
72226
+ const absPath = resolve84(ctx.workingDirectory, dirPath);
72227
+ const entries = await readdir8(absPath, { withFileTypes: true });
72086
72228
  const results = [];
72087
72229
  for (const entry of entries) {
72088
72230
  if (args.pattern && !matchPattern(entry.name, args.pattern)) continue;
72089
- const fullPath = join28(absPath, entry.name);
72090
- const stats = await stat9(fullPath);
72231
+ const fullPath = join29(absPath, entry.name);
72232
+ const stats = await stat10(fullPath);
72091
72233
  if (entry.isDirectory()) {
72092
72234
  results.push(`[DIR] ${entry.name}/`);
72093
72235
  } else {
@@ -72114,8 +72256,8 @@ var init_agent_only = __esm({
72114
72256
  }),
72115
72257
  async execute(args, ctx) {
72116
72258
  try {
72117
- const absPath = resolve83(ctx.workingDirectory, args.path);
72118
- const content = await readFile54(absPath, "utf-8");
72259
+ const absPath = resolve84(ctx.workingDirectory, args.path);
72260
+ const content = await readFile55(absPath, "utf-8");
72119
72261
  const maxLength = 4e3;
72120
72262
  const truncated = content.length > maxLength;
72121
72263
  const output = truncated ? content.substring(0, maxLength) + "\n... (truncated)" : content;
@@ -72139,7 +72281,7 @@ var init_agent_only = __esm({
72139
72281
  }),
72140
72282
  async execute(args, ctx) {
72141
72283
  try {
72142
- const absPath = resolve83(ctx.workingDirectory, args.path);
72284
+ const absPath = resolve84(ctx.workingDirectory, args.path);
72143
72285
  await writeFile59(absPath, args.content, "utf-8");
72144
72286
  return { success: true, data: { bytes: args.content.length }, humanLines: [`File written: ${args.path} (${formatSize(args.content.length)})`] };
72145
72287
  } catch (error) {
@@ -72159,10 +72301,10 @@ var init_agent_only = __esm({
72159
72301
  path: external_exports.string().describe("Path to check")
72160
72302
  }),
72161
72303
  async execute(args, ctx) {
72162
- const absPath = resolve83(ctx.workingDirectory, args.path);
72304
+ const absPath = resolve84(ctx.workingDirectory, args.path);
72163
72305
  try {
72164
72306
  await access8(absPath);
72165
- const stats = await stat9(absPath);
72307
+ const stats = await stat10(absPath);
72166
72308
  const type = stats.isDirectory() ? "directory" : "file";
72167
72309
  return { success: true, data: { exists: true, type }, humanLines: [`${type} exists: ${args.path}`] };
72168
72310
  } catch {
@@ -72187,19 +72329,19 @@ var init_agent_only = __esm({
72187
72329
  }),
72188
72330
  async execute(args, ctx) {
72189
72331
  try {
72190
- const filePath = resolve83(ctx.workingDirectory, args.project);
72191
- const content = await readFile54(filePath, "utf-8");
72332
+ const filePath = resolve84(ctx.workingDirectory, args.project);
72333
+ const content = await readFile55(filePath, "utf-8");
72192
72334
  const data = JSON.parse(content);
72193
72335
  const project = Project.fromJSON(data);
72194
- const dirPath = resolve83(ctx.workingDirectory, args.directory);
72336
+ const dirPath = resolve84(ctx.workingDirectory, args.directory);
72195
72337
  const filterExts = args.filter ? args.filter.split(",").map((e) => e.trim().toLowerCase()) : null;
72196
72338
  const imageDuration = args.imageDuration ?? 5;
72197
72339
  const recursive = args.recursive ?? false;
72198
72340
  const mediaFiles = [];
72199
72341
  const scanDir = async (dir) => {
72200
- const entries = await readdir7(dir, { withFileTypes: true });
72342
+ const entries = await readdir8(dir, { withFileTypes: true });
72201
72343
  for (const entry of entries) {
72202
- const entryPath = join28(dir, entry.name);
72344
+ const entryPath = join29(dir, entry.name);
72203
72345
  if (entry.isDirectory() && recursive) {
72204
72346
  await scanDir(entryPath);
72205
72347
  } else if (entry.isFile()) {
@@ -72259,8 +72401,8 @@ var init_agent_only = __esm({
72259
72401
  }),
72260
72402
  async execute(args, ctx) {
72261
72403
  try {
72262
- const filePath = resolve83(ctx.workingDirectory, args.project);
72263
- const content = await readFile54(filePath, "utf-8");
72404
+ const filePath = resolve84(ctx.workingDirectory, args.project);
72405
+ const content = await readFile55(filePath, "utf-8");
72264
72406
  const data = JSON.parse(content);
72265
72407
  const project = Project.fromJSON(data);
72266
72408
  const sourceIds = args.sourceIds ?? [];
@@ -72330,8 +72472,8 @@ var init_agent_only = __esm({
72330
72472
  }),
72331
72473
  async execute(args, ctx) {
72332
72474
  try {
72333
- const filePath = resolve83(ctx.workingDirectory, args.project);
72334
- const content = await readFile54(filePath, "utf-8");
72475
+ const filePath = resolve84(ctx.workingDirectory, args.project);
72476
+ const content = await readFile55(filePath, "utf-8");
72335
72477
  const data = JSON.parse(content);
72336
72478
  const project = Project.fromJSON(data);
72337
72479
  const clipIds = args.clipIds ?? [];
@@ -72386,7 +72528,7 @@ var init_agent_only = __esm({
72386
72528
  async execute(args, ctx) {
72387
72529
  try {
72388
72530
  const filePath = await resolveTimelineFile(args.project, ctx.workingDirectory);
72389
- const content = await readFile54(filePath, "utf-8");
72531
+ const content = await readFile55(filePath, "utf-8");
72390
72532
  const data = JSON.parse(content);
72391
72533
  const project = Project.fromJSON(data);
72392
72534
  const what = args.what ?? "clips";
@@ -72463,7 +72605,7 @@ var init_agent_only = __esm({
72463
72605
  async execute(args, ctx) {
72464
72606
  try {
72465
72607
  const filePath = await resolveTimelineFile(args.projectPath, ctx.workingDirectory);
72466
- const content = await readFile54(filePath, "utf-8");
72608
+ const content = await readFile55(filePath, "utf-8");
72467
72609
  const data = JSON.parse(content);
72468
72610
  const project = Project.fromJSON(data);
72469
72611
  const updates = [];
@@ -72622,7 +72764,7 @@ var init_agent_only = __esm({
72622
72764
  }),
72623
72765
  async execute(args, ctx) {
72624
72766
  try {
72625
- const absPath = resolve83(ctx.workingDirectory, args.path);
72767
+ const absPath = resolve84(ctx.workingDirectory, args.path);
72626
72768
  const { stdout } = await execSafe(
72627
72769
  "ffprobe",
72628
72770
  ["-v", "quiet", "-print_format", "json", "-show_format", "-show_streams", absPath],
@@ -72711,10 +72853,10 @@ Audio:`);
72711
72853
  }),
72712
72854
  async execute(args, ctx) {
72713
72855
  try {
72714
- const absInput = resolve83(ctx.workingDirectory, args.input);
72856
+ const absInput = resolve84(ctx.workingDirectory, args.input);
72715
72857
  const ext = args.input.split(".").pop() || "mp4";
72716
72858
  const baseName = args.input.replace(/\.[^/.]+$/, "");
72717
- const outputPath = args.output ? resolve83(ctx.workingDirectory, args.output) : resolve83(ctx.workingDirectory, `${baseName}-compressed.${ext}`);
72859
+ const outputPath = args.output ? resolve84(ctx.workingDirectory, args.output) : resolve84(ctx.workingDirectory, `${baseName}-compressed.${ext}`);
72718
72860
  const crfValues = { low: 28, medium: 23, high: 18 };
72719
72861
  const crf = crfValues[args.quality ?? "medium"];
72720
72862
  await execSafe(
@@ -72737,8 +72879,8 @@ Audio:`);
72737
72879
  ],
72738
72880
  { maxBuffer: 50 * 1024 * 1024 }
72739
72881
  );
72740
- const inputBuf = await readFile54(absInput);
72741
- const outputBuf = await readFile54(outputPath);
72882
+ const inputBuf = await readFile55(absInput);
72883
+ const outputBuf = await readFile55(outputPath);
72742
72884
  const inputSize = inputBuf.length;
72743
72885
  const outputSize = outputBuf.length;
72744
72886
  const reduction = (inputSize - outputSize) / inputSize * 100;
@@ -72774,8 +72916,8 @@ Audio:`);
72774
72916
  }),
72775
72917
  async execute(args, ctx) {
72776
72918
  try {
72777
- const absInput = resolve83(ctx.workingDirectory, args.input);
72778
- const absOutput = resolve83(ctx.workingDirectory, args.output);
72919
+ const absInput = resolve84(ctx.workingDirectory, args.input);
72920
+ const absOutput = resolve84(ctx.workingDirectory, args.output);
72779
72921
  const codecMap = {
72780
72922
  h264: "libx264",
72781
72923
  h265: "libx265",
@@ -72828,11 +72970,11 @@ Audio:`);
72828
72970
  };
72829
72971
  }
72830
72972
  try {
72831
- const absOutput = resolve83(ctx.workingDirectory, args.output);
72973
+ const absOutput = resolve84(ctx.workingDirectory, args.output);
72832
72974
  if (args.reencode) {
72833
72975
  const ffmpegArgs = [];
72834
72976
  for (const i of args.inputs) {
72835
- ffmpegArgs.push("-i", resolve83(ctx.workingDirectory, i));
72977
+ ffmpegArgs.push("-i", resolve84(ctx.workingDirectory, i));
72836
72978
  }
72837
72979
  const filterComplex = args.inputs.map((_, i) => `[${i}:v][${i}:a]`).join("");
72838
72980
  ffmpegArgs.push(
@@ -72847,8 +72989,8 @@ Audio:`);
72847
72989
  );
72848
72990
  await execSafe("ffmpeg", ffmpegArgs, { maxBuffer: 100 * 1024 * 1024 });
72849
72991
  } else {
72850
- const tempList = resolve83(ctx.workingDirectory, `concat-list-${Date.now()}.txt`);
72851
- const listContent = args.inputs.map((i) => `file '${resolve83(ctx.workingDirectory, i)}'`).join("\n");
72992
+ const tempList = resolve84(ctx.workingDirectory, `concat-list-${Date.now()}.txt`);
72993
+ const listContent = args.inputs.map((i) => `file '${resolve84(ctx.workingDirectory, i)}'`).join("\n");
72852
72994
  await writeFile59(tempList, listContent, "utf-8");
72853
72995
  try {
72854
72996
  await execSafe(
@@ -72945,7 +73087,7 @@ var init_walkthrough = __esm({
72945
73087
  });
72946
73088
 
72947
73089
  // src/tools/manifest/status.ts
72948
- import { resolve as resolve84 } from "node:path";
73090
+ import { resolve as resolve85 } from "node:path";
72949
73091
  var PROJECT_DIR_DESCRIPTION4, statusJobTool, statusProjectTool, statusTools;
72950
73092
  var init_status = __esm({
72951
73093
  "src/tools/manifest/status.ts"() {
@@ -72969,7 +73111,7 @@ var init_status = __esm({
72969
73111
  output: external_exports.string().optional().describe("Download result media to this path when complete.")
72970
73112
  }),
72971
73113
  async execute(args, ctx) {
72972
- const projectDir = args.projectDir ? resolve84(ctx.workingDirectory, args.projectDir) : findProjectRoot(ctx.workingDirectory);
73114
+ const projectDir = args.projectDir ? resolve85(ctx.workingDirectory, args.projectDir) : findProjectRoot(ctx.workingDirectory);
72973
73115
  const record = await readJobRecord(args.jobId, projectDir);
72974
73116
  if (!record) return { success: false, error: `Job not found: ${args.jobId}` };
72975
73117
  const result = args.refresh === false ? makeJobStatusResult(record, {
@@ -72978,7 +73120,7 @@ var init_status = __esm({
72978
73120
  warnings: []
72979
73121
  }) : await refreshJobRecord(record, {
72980
73122
  wait: args.wait,
72981
- output: args.output ? resolve84(ctx.workingDirectory, args.output) : void 0,
73123
+ output: args.output ? resolve85(ctx.workingDirectory, args.output) : void 0,
72982
73124
  workingDirectory: ctx.workingDirectory
72983
73125
  });
72984
73126
  return {
@@ -73003,7 +73145,7 @@ var init_status = __esm({
73003
73145
  refresh: external_exports.boolean().optional().describe("Refresh active supported jobs before summarizing. Default false.")
73004
73146
  }),
73005
73147
  async execute(args, ctx) {
73006
- const projectDir = args.projectDir ? resolve84(ctx.workingDirectory, args.projectDir) : ctx.workingDirectory;
73148
+ const projectDir = args.projectDir ? resolve85(ctx.workingDirectory, args.projectDir) : ctx.workingDirectory;
73007
73149
  const result = await inspectProjectStatus(projectDir, { refresh: args.refresh === true });
73008
73150
  return {
73009
73151
  success: true,
@@ -73289,7 +73431,7 @@ init_source();
73289
73431
  // package.json
73290
73432
  var package_default = {
73291
73433
  name: "@vibeframe/cli",
73292
- version: "0.111.3",
73434
+ version: "0.112.0",
73293
73435
  description: "VibeFrame CLI - agentic video workflow runtime",
73294
73436
  private: false,
73295
73437
  license: "MIT",
@@ -80465,12 +80607,12 @@ function resolveCopier() {
80465
80607
  async function copyToClipboard(text) {
80466
80608
  const opener = resolveCopier();
80467
80609
  if (!opener) return false;
80468
- return new Promise((resolve85) => {
80610
+ return new Promise((resolve86) => {
80469
80611
  let settled = false;
80470
80612
  const finish = (ok) => {
80471
80613
  if (settled) return;
80472
80614
  settled = true;
80473
- resolve85(ok);
80615
+ resolve86(ok);
80474
80616
  };
80475
80617
  try {
80476
80618
  const child = spawn2(opener.command, opener.args, {
@@ -84404,13 +84546,13 @@ async function runDiagnostics() {
84404
84546
  installed = false;
84405
84547
  }
84406
84548
  } else if (toolName === "chrome") {
84407
- const { existsSync: existsSync57 } = await import("node:fs");
84549
+ const { existsSync: existsSync58 } = await import("node:fs");
84408
84550
  const { homedir: homedir8 } = await import("node:os");
84409
- const { join: join29 } = await import("node:path");
84551
+ const { join: join30 } = await import("node:path");
84410
84552
  const chromePaths = [
84411
84553
  process.env.HYPERFRAMES_CHROME_PATH,
84412
84554
  process.env.CHROME_PATH,
84413
- join29(
84555
+ join30(
84414
84556
  homedir8(),
84415
84557
  ".cache",
84416
84558
  "puppeteer",
@@ -84425,7 +84567,7 @@ async function runDiagnostics() {
84425
84567
  "/usr/bin/chromium",
84426
84568
  "/usr/bin/chromium-browser"
84427
84569
  ];
84428
- installed = chromePaths.some((p) => p && existsSync57(p));
84570
+ installed = chromePaths.some((p) => p && existsSync58(p));
84429
84571
  } else {
84430
84572
  installed = commandExists(toolName);
84431
84573
  }
@@ -86277,7 +86419,7 @@ async function startAgent(options = {}) {
86277
86419
  console.log();
86278
86420
  console.log(source_default.dim(" Commands: exit \xB7 reset \xB7 tools \xB7 context"));
86279
86421
  console.log();
86280
- return new Promise((resolve85) => {
86422
+ return new Promise((resolve86) => {
86281
86423
  if (typeof process.stdin.ref === "function") {
86282
86424
  process.stdin.ref();
86283
86425
  }
@@ -86384,7 +86526,7 @@ async function startAgent(options = {}) {
86384
86526
  clearInterval(keepalive);
86385
86527
  console.log();
86386
86528
  console.log(source_default.dim("Goodbye!"));
86387
- resolve85();
86529
+ resolve86();
86388
86530
  });
86389
86531
  rl.prompt();
86390
86532
  });