@karlorz/codexhost-cli-win32-x64 0.15.0-1 → 0.16.1-2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4642,8 +4642,8 @@
4642
4642
  }
4643
4643
 
4644
4644
  // ../../node_modules/zod/v4/locales/be.js
4645
- function getBelarusianPlural(count2, one, few, many) {
4646
- const absCount = Math.abs(count2);
4645
+ function getBelarusianPlural(count3, one, few, many) {
4646
+ const absCount = Math.abs(count3);
4647
4647
  const lastDigit = absCount % 10;
4648
4648
  const lastTwoDigits = absCount % 100;
4649
4649
  if (lastTwoDigits >= 11 && lastTwoDigits <= 19) {
@@ -6721,8 +6721,8 @@
6721
6721
  }
6722
6722
 
6723
6723
  // ../../node_modules/zod/v4/locales/hy.js
6724
- function getArmenianPlural(count2, one, many) {
6725
- return Math.abs(count2) === 1 ? one : many;
6724
+ function getArmenianPlural(count3, one, many) {
6725
+ return Math.abs(count3) === 1 ? one : many;
6726
6726
  }
6727
6727
  function withDefiniteArticle(word) {
6728
6728
  if (!word)
@@ -8850,8 +8850,8 @@
8850
8850
  }
8851
8851
 
8852
8852
  // ../../node_modules/zod/v4/locales/ru.js
8853
- function getRussianPlural(count2, one, few, many) {
8854
- const absCount = Math.abs(count2);
8853
+ function getRussianPlural(count3, one, few, many) {
8854
+ const absCount = Math.abs(count3);
8855
8855
  const lastDigit = absCount % 10;
8856
8856
  const lastTwoDigits = absCount % 100;
8857
8857
  if (lastTwoDigits >= 11 && lastTwoDigits <= 19) {
@@ -14520,6 +14520,33 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14520
14520
  // ../../node_modules/zod/v4/classic/external.js
14521
14521
  config(en_default());
14522
14522
 
14523
+ // ../shared-contracts/dist/goals.js
14524
+ var harnessGoalStatusSchema = external_exports.enum([
14525
+ "active",
14526
+ "paused",
14527
+ "blocked",
14528
+ "usageLimited",
14529
+ "budgetLimited",
14530
+ "complete"
14531
+ ]);
14532
+ var count = external_exports.number().int().nonnegative().safe();
14533
+ var harnessGoalSchema = external_exports.object({
14534
+ objective: external_exports.string().min(1),
14535
+ status: harnessGoalStatusSchema,
14536
+ tokenBudget: count.positive().nullable(),
14537
+ tokensUsed: count,
14538
+ timeUsedSeconds: count,
14539
+ createdAt: count,
14540
+ updatedAt: count
14541
+ });
14542
+ var goalOriginSchema = external_exports.enum(["user", "automatic"]).nullable();
14543
+ var harnessGoalSetSchema = external_exports.object({
14544
+ objective: external_exports.string().min(1).optional(),
14545
+ status: external_exports.enum(["active", "paused"]).optional(),
14546
+ tokenBudget: count.positive().nullable().optional(),
14547
+ origin: goalOriginSchema
14548
+ });
14549
+
14523
14550
  // ../shared-contracts/dist/delegation-read.js
14524
14551
  var REMOTE_THREAD_REPLY_MAX_BYTES = 16 * 1024 * 1024;
14525
14552
  var THREAD_REFERENCE_SOURCE_HOST_PARAM = "codexhostSourceHostId";
@@ -14651,7 +14678,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14651
14678
 
14652
14679
  // ../shared-contracts/dist/usage-statistics.js
14653
14680
  var USAGE_STATISTICS_RANGES = ["today", "7d", "30d", "90d", "all"];
14654
- var count = external_exports.number().int().min(0).max(Number.MAX_SAFE_INTEGER);
14681
+ var count2 = external_exports.number().int().min(0).max(Number.MAX_SAFE_INTEGER);
14655
14682
  var localDate = external_exports.string().regex(/^\d{4}-\d{2}-\d{2}$/u);
14656
14683
  var harness = external_exports.string().min(1).max(128);
14657
14684
  var model = external_exports.string().min(1).max(512);
@@ -14674,22 +14701,24 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14674
14701
  date: localDate.optional()
14675
14702
  });
14676
14703
  var usageStatisticsTotalsSchema = external_exports.strictObject({
14677
- requests: count,
14678
- inputTokens: count,
14679
- cachedInputTokens: count,
14680
- cacheWriteInputTokens: count,
14681
- cacheKnownInputTokens: count,
14682
- outputTokens: count,
14683
- reasoningOutputTokens: count,
14704
+ requests: count2,
14705
+ inputTokens: count2,
14706
+ cachedInputTokens: count2,
14707
+ cacheWriteInputTokens: count2,
14708
+ cacheKnownInputTokens: count2,
14709
+ cacheHitCachedInputTokens: count2,
14710
+ cacheHitInputTokens: count2,
14711
+ outputTokens: count2,
14712
+ reasoningOutputTokens: count2,
14684
14713
  /** USD at the public price, summed over the priced requests only. */
14685
14714
  costUsd: external_exports.number().finite().min(0),
14686
14715
  /** Requests without a price (or the cache data the price needs); not in `costUsd`. */
14687
- unpricedRequests: count,
14716
+ unpricedRequests: count2,
14688
14717
  /**
14689
14718
  * Requests whose storage gave no token counts: counted as requests, with neither tokens nor
14690
14719
  * cost, and not as unpriced.
14691
14720
  */
14692
- unmeteredRequests: count
14721
+ unmeteredRequests: count2
14693
14722
  });
14694
14723
  var totals = usageStatisticsTotalsSchema.shape;
14695
14724
  var usageStatisticsSessionSchema = external_exports.strictObject({
@@ -14700,8 +14729,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14700
14729
  title: external_exports.string().min(1).max(200).optional(),
14701
14730
  /** Models the session used, most requests first. */
14702
14731
  models: external_exports.array(model).max(16),
14703
- firstAtMs: count,
14704
- lastAtMs: count,
14732
+ firstAtMs: count2,
14733
+ lastAtMs: count2,
14705
14734
  ...totals
14706
14735
  });
14707
14736
  var usageStatisticsResultSchema = external_exports.strictObject({
@@ -14719,7 +14748,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14719
14748
  date: localDate.nullable()
14720
14749
  }),
14721
14750
  /** Reading of native storage: incomplete while the first read, or a refresh, is under way. */
14722
- reading: external_exports.strictObject({ complete: external_exports.boolean(), sources: count, read: count }),
14751
+ reading: external_exports.strictObject({ complete: external_exports.boolean(), sources: count2, read: count2 }),
14723
14752
  /** Harnesses whose storage could not be read; their part is missing, the rest is complete. */
14724
14753
  failures: external_exports.array(external_exports.strictObject({ harness, message: external_exports.string().max(2048) })).max(256),
14725
14754
  /** Every value seen in the range, ignoring the filters, to choose filters from. */
@@ -14739,8 +14768,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14739
14768
  harness,
14740
14769
  model: model.nullable(),
14741
14770
  credits: external_exports.number().finite().min(0),
14742
- reportedRequests: count,
14743
- requests: count
14771
+ reportedRequests: count2,
14772
+ requests: count2
14744
14773
  })).max(4096).optional(),
14745
14774
  /** All filters applied. */
14746
14775
  totals: usageStatisticsTotalsSchema,
@@ -14757,7 +14786,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
14757
14786
  model: model.nullable(),
14758
14787
  ...totals,
14759
14788
  /** Requests priced by what the Harness recorded they cost, not by a price list. */
14760
- harnessPricedRequests: count
14789
+ harnessPricedRequests: count2
14761
14790
  })).max(4096),
14762
14791
  byProject: external_exports.array(external_exports.strictObject({ project: project.nullable(), ...totals })).max(4096),
14763
14792
  /**
@@ -15390,7 +15419,9 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
15390
15419
  var harnessHistoryCapabilitiesSchema = external_exports.object({
15391
15420
  fork: external_exports.boolean(),
15392
15421
  forkAcrossCwd: external_exports.boolean(),
15393
- rollbackLastTurn: external_exports.boolean()
15422
+ rollbackLastTurn: external_exports.boolean(),
15423
+ /** Remove the selected checkpoint's Turn and every later Turn, without restoring files. */
15424
+ rollbackToCheckpoint: external_exports.boolean().optional()
15394
15425
  }).strict().refine((history) => history.fork || !history.forkAcrossCwd, {
15395
15426
  path: ["forkAcrossCwd"],
15396
15427
  message: "Cross-cwd Fork requires exact history Fork support"
@@ -15629,7 +15660,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
15629
15660
  harnessId: harnessPluginIdSchema,
15630
15661
  model: harnessModelRefSchema.optional(),
15631
15662
  thinkingOptionId: harnessThinkingOptionIdSchema.optional(),
15632
- permissionModeId: harnessPermissionModeIdSchema.optional()
15663
+ permissionModeId: harnessPermissionModeIdSchema.optional(),
15664
+ /** A draft prewarm create: stays unsubmitted until the user's first Turn.
15665
+ * Desktop forwards only the Model of a main-process prewarm to thread/start. */
15666
+ prewarm: external_exports.literal(true).optional()
15633
15667
  }).strict();
15634
15668
 
15635
15669
  // ../shared-contracts/dist/harness-launch-settings.js
@@ -16327,9 +16361,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
16327
16361
  const matchesMetadata = (profile) => (version2 === void 0 || profile.version === version2) && (platform === void 0 || profile.platform === platform);
16328
16362
  if (present.length > 0) {
16329
16363
  const profile = present.length === 1 ? present[0] : void 0;
16330
- return profile && matchesMetadata(profile) && [profile.initial, profile.shared].every(
16331
- (asset) => auditedAppInitialAssetPresent(names, asset)
16332
- ) ? profile : void 0;
16364
+ if (!profile || !matchesMetadata(profile)) return void 0;
16365
+ const initialPresent = auditedAppInitialAssetPresent(names, profile.initial);
16366
+ const sharedPresent = auditedAppInitialAssetPresent(names, profile.shared);
16367
+ return sharedPresent && (initialPresent || version2 !== void 0 && platform !== void 0) ? profile : void 0;
16333
16368
  }
16334
16369
  if (version2 === void 0) return void 0;
16335
16370
  const candidates = profiles.filter(matchesMetadata);
@@ -16357,10 +16392,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
16357
16392
  var RENDERER_NEW_THREAD_PREFERENCE_KEY = "codexhost.new-thread-preference.v1";
16358
16393
 
16359
16394
  // src/renderer-client-owned-voice.ts
16360
- var CLIENT_OWNED_VOICE_VERSION = "26.1023.51421";
16361
- var CLIENT_OWNED_VOICE_INITIAL_ASSET = "app-initial-bc8256c3cccb.js";
16362
- var CLIENT_OWNED_VOICE_SHARED_ASSET = "app-shared-e9f258fd3588.js";
16363
- var CLIENT_OWNED_VOICE_OVERLAY_ASSET = "avatar-overlay-native-page-af6c3662f64f.js";
16395
+ var CLIENT_OWNED_VOICE_VERSION = "26.1027.30824";
16396
+ var CLIENT_OWNED_VOICE_INITIAL_ASSET = "app-initial-60f141238751.js";
16397
+ var CLIENT_OWNED_VOICE_SHARED_ASSET = "app-shared-7815d5a1a42a.js";
16398
+ var CLIENT_OWNED_VOICE_OVERLAY_ASSET = "avatar-overlay-native-page-d9d400e751cd.js";
16364
16399
  var CLIENT_OWNED_VOICE_ASSETS = [
16365
16400
  {
16366
16401
  platform: "darwin",
@@ -16368,6 +16403,23 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
16368
16403
  initial: CLIENT_OWNED_VOICE_INITIAL_ASSET,
16369
16404
  shared: CLIENT_OWNED_VOICE_SHARED_ASSET,
16370
16405
  overlay: CLIENT_OWNED_VOICE_OVERLAY_ASSET,
16406
+ init: "Edr",
16407
+ fetch: "wdr",
16408
+ fetchFrom: "initial",
16409
+ bridge: "LRt",
16410
+ services: "Vct",
16411
+ responseError: "Adr",
16412
+ responseErrorFrom: "initial",
16413
+ capabilityInit: "Ner",
16414
+ capabilityFamily: "Mer",
16415
+ inferenceGateFamily: "Lfr"
16416
+ },
16417
+ {
16418
+ platform: "darwin",
16419
+ version: "26.1023.51421",
16420
+ initial: "app-initial-bc8256c3cccb.js",
16421
+ shared: "app-shared-e9f258fd3588.js",
16422
+ overlay: "avatar-overlay-native-page-af6c3662f64f.js",
16371
16423
  init: "xir",
16372
16424
  fetch: "yir",
16373
16425
  fetchFrom: "initial",
@@ -16689,7 +16741,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
16689
16741
  if (!object2(bridgeClass) && typeof bridgeClass !== "function") throw new Error();
16690
16742
  const client = Reflect.get(fetchClass, "getInstance").call(fetchClass);
16691
16743
  const bridge = Reflect.get(bridgeClass, "getInstance").call(bridgeClass);
16692
- const responseError = typeof errorName === "string" && typeof sharedModule[errorName] === "function" ? sharedModule[errorName] : async (response) => {
16744
+ const errorModule = "responseErrorFrom" in assets && assets.responseErrorFrom === "initial" ? fetchModule : sharedModule;
16745
+ const responseError = typeof errorName === "string" && typeof errorModule[errorName] === "function" ? errorModule[errorName] : async (response) => {
16693
16746
  throw Object.assign(new Error(await response.text()), { status: response.status });
16694
16747
  };
16695
16748
  if (typeof client?.fetch !== "function" || typeof bridge?.dispatchMessage !== "function" || typeof bridge?.subscribe !== "function")
@@ -16984,6 +17037,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
16984
17037
  function isRecord4(value) {
16985
17038
  return value !== null && typeof value === "object" && !Array.isArray(value);
16986
17039
  }
17040
+ function conversationIdFrom(request) {
17041
+ if (typeof request === "string" && request) return request;
17042
+ if (!isRecord4(request)) return null;
17043
+ if (typeof request.conversationId === "string" && request.conversationId)
17044
+ return request.conversationId;
17045
+ if (typeof request.threadId === "string" && request.threadId) return request.threadId;
17046
+ return null;
17047
+ }
17048
+ function isHostExternalConversation(conversation, threadId) {
17049
+ return isRecord4(conversation) && conversation.id === threadId && conversation.modelProvider === "codexhost";
17050
+ }
16987
17051
  function isManager(value) {
16988
17052
  return isRecord4(value) && ["sendRequest", "steerTurn", "startTurn", "getTurnCoordinator"].every(
16989
17053
  (key) => typeof value[key] === "function"
@@ -17019,6 +17083,27 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
17019
17083
  if (!text) return params;
17020
17084
  return { ...params, input: [{ type: "text", text, text_elements: [] }] };
17021
17085
  }
17086
+ function installExternalQueueUi(manager) {
17087
+ const coordinator = manager.getTurnCoordinator();
17088
+ const options = isRecord4(coordinator) ? coordinator.options : null;
17089
+ if (!isRecord4(options) || typeof options.getMessageQueueMode !== "function") return null;
17090
+ const descriptor = Object.getOwnPropertyDescriptor(options, "getMessageQueueMode");
17091
+ if (!descriptor?.writable) return null;
17092
+ const original = options.getMessageQueueMode;
17093
+ const getMessageQueueMode = (...args) => {
17094
+ const threadId = conversationIdFrom(args[0]);
17095
+ if (threadId && typeof manager.getConversation === "function" && isHostExternalConversation(manager.getConversation(threadId), threadId)) {
17096
+ return Promise.resolve("queue");
17097
+ }
17098
+ return original.apply(options, args);
17099
+ };
17100
+ options.getMessageQueueMode = getMessageQueueMode;
17101
+ return () => {
17102
+ if (options.getMessageQueueMode === getMessageQueueMode) {
17103
+ Object.defineProperty(options, "getMessageQueueMode", descriptor);
17104
+ }
17105
+ };
17106
+ }
17022
17107
  function submissionHost(manager) {
17023
17108
  const coordinator = manager.getTurnCoordinator();
17024
17109
  const options = isRecord4(coordinator) ? coordinator.options : null;
@@ -17092,6 +17177,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
17092
17177
  function installRendererExternalSteering(target, sendTurnStart, prepareTurnInput) {
17093
17178
  if (!isManager(target)) return null;
17094
17179
  const manager = target;
17180
+ const restoreQueueUi = installExternalQueueUi(manager);
17095
17181
  const originalSteer = manager.steerTurn;
17096
17182
  const originalSend = manager.sendRequest;
17097
17183
  const routes = /* @__PURE__ */ new Map();
@@ -17102,7 +17188,9 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
17102
17188
  if ((method === "turn/start" || method === "turn/steer") && prepareTurnInput) {
17103
17189
  params = prepareTurnInput(params);
17104
17190
  }
17105
- if (method === "turn/start") params = restoreQueuedTurnStartText(manager, params);
17191
+ if (method === "turn/start" || method === "turn/steer") {
17192
+ params = restoreQueuedTurnStartText(manager, params);
17193
+ }
17106
17194
  const messageId = isRecord4(params) ? params.clientUserMessageId : null;
17107
17195
  const route = typeof messageId === "string" && isRecord4(params) ? routes.get(`${params.threadId}\0${messageId}`) : void 0;
17108
17196
  if (method !== "turn/start" || !isRecord4(params) || !route || route.threadId !== params.threadId) {
@@ -17309,6 +17397,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
17309
17397
  });
17310
17398
  return () => {
17311
17399
  disposed = true;
17400
+ restoreQueueUi?.();
17312
17401
  restoreMethod("steerTurn");
17313
17402
  if (getStreamRole) restoreMethod("getStreamRole");
17314
17403
  if (pending.size === 0) {