@codexhost/cli-darwin-x64 0.18.0-beta.4 → 0.18.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.
Files changed (48) hide show
  1. package/README.md +1 -1
  2. package/app/codexhost-distribution.json +1 -1
  3. package/app/console-server.mjs +98 -55
  4. package/app/console-web.js +276 -188
  5. package/app/desktop-controller.mjs +283 -113
  6. package/app/host-runtime.mjs +2129 -1529
  7. package/app/plugins/antigravity/plugin.mjs +787 -303
  8. package/app/plugins/claude-code/plugin.mjs +85 -45
  9. package/app/plugins/codebuddy/plugin.mjs +99 -59
  10. package/app/plugins/codex-usage/plugin.mjs +85 -45
  11. package/app/plugins/copilot/plugin.mjs +90 -50
  12. package/app/plugins/cursor-cli/plugin.mjs +113 -73
  13. package/app/plugins/deepseek-harness/plugin.mjs +116 -76
  14. package/app/plugins/devin/plugin.mjs +90 -50
  15. package/app/plugins/grok/plugin.mjs +96 -56
  16. package/app/plugins/hermes/plugin.mjs +77 -37
  17. package/app/plugins/kimi-code/plugin.mjs +94 -54
  18. package/app/plugins/kiro-cli/plugin.mjs +90 -50
  19. package/app/plugins/omp/plugin.mjs +81 -41
  20. package/app/plugins/opencode/plugin.mjs +78 -38
  21. package/app/plugins/pi/plugin.mjs +94 -54
  22. package/app/plugins/qoder/plugin.mjs +106 -66
  23. package/app/plugins/qoder-cn/plugin.mjs +106 -66
  24. package/app/plugins/qwen-code/plugin.mjs +101 -61
  25. package/app/plugins/workbuddy/plugin.mjs +99 -59
  26. package/app/plugins/zcode/plugin.mjs +82 -42
  27. package/app/renderer-extension.js +435 -361
  28. package/app/web/assets/{index-D1dOzBMI.js → index-C0aXz2jD.js} +63 -63
  29. package/app/web/codex-agent.png +0 -0
  30. package/app/web/codexhost-settings.js +229 -175
  31. package/app/web/index.html +1 -1
  32. package/app/web/plugins/deepseek-ai__dsh-api-remotes/client.js +1 -1
  33. package/app/web/plugins/deepseek-ai__dsh-api-session-controller/client.js +61 -61
  34. package/app/web/plugins/deepseek-ai__dsh-client-ui-chat/client.js +8 -8
  35. package/app/web/plugins/deepseek-ai__dsh-client-ui-codexhost/client.js +2 -2
  36. package/app/web/plugins/deepseek-ai__dsh-client-ui-conversation/client.js +12 -12
  37. package/app/web/plugins/deepseek-ai__dsh-client-ui-permission-presets/client.js +1 -1
  38. package/app/web/plugins/deepseek-ai__dsh-client-ui-settings/client.js +1 -1
  39. package/app/web/plugins/deepseek-ai__dsh-client-ui-settings-general/client.js +3 -3
  40. package/app/web/plugins/deepseek-ai__dsh-client-ui-theme/client.js +1 -1
  41. package/app/web/plugins/deepseek-ai__dsh-client-ui-tool/client.js +18 -18
  42. package/app/web/plugins/deepseek-ai__dsh-client-ui-workspace/client.js +8 -8
  43. package/app/web/sw.js +41 -6
  44. package/app/web-modules/server.mjs +2079 -1201
  45. package/bin/codexhost +0 -0
  46. package/libexec/codexhost-shim +0 -0
  47. package/libexec/codexhost-updater +0 -0
  48. package/package.json +1 -1
@@ -1,8 +1,8 @@
1
1
  import { createRequire as __codexhostCreateRequire } from "node:module"; const require = __codexhostCreateRequire(import.meta.url);
2
2
  var __defProp = Object.defineProperty;
3
- var __export = (target, all) => {
3
+ var __export = (target2, all) => {
4
4
  for (var name in all)
5
- __defProp(target, name, { get: all[name], enumerable: true });
5
+ __defProp(target2, name, { get: all[name], enumerable: true });
6
6
  };
7
7
 
8
8
  // ../../harness-discovery/dist/environment.js
@@ -1352,8 +1352,8 @@ function defineLazy(object2, key, getter) {
1352
1352
  function objectClone(obj) {
1353
1353
  return Object.create(Object.getPrototypeOf(obj), Object.getOwnPropertyDescriptors(obj));
1354
1354
  }
1355
- function assignProp(target, prop, value) {
1356
- Object.defineProperty(target, prop, {
1355
+ function assignProp(target2, prop, value) {
1356
+ Object.defineProperty(target2, prop, {
1357
1357
  value,
1358
1358
  writable: true,
1359
1359
  enumerable: true,
@@ -1536,35 +1536,35 @@ function normalizeParams(_params) {
1536
1536
  return params;
1537
1537
  }
1538
1538
  function createTransparentProxy(getter) {
1539
- let target;
1539
+ let target2;
1540
1540
  return new Proxy({}, {
1541
1541
  get(_, prop, receiver) {
1542
- target ?? (target = getter());
1543
- return Reflect.get(target, prop, receiver);
1542
+ target2 ?? (target2 = getter());
1543
+ return Reflect.get(target2, prop, receiver);
1544
1544
  },
1545
1545
  set(_, prop, value, receiver) {
1546
- target ?? (target = getter());
1547
- return Reflect.set(target, prop, value, receiver);
1546
+ target2 ?? (target2 = getter());
1547
+ return Reflect.set(target2, prop, value, receiver);
1548
1548
  },
1549
1549
  has(_, prop) {
1550
- target ?? (target = getter());
1551
- return Reflect.has(target, prop);
1550
+ target2 ?? (target2 = getter());
1551
+ return Reflect.has(target2, prop);
1552
1552
  },
1553
1553
  deleteProperty(_, prop) {
1554
- target ?? (target = getter());
1555
- return Reflect.deleteProperty(target, prop);
1554
+ target2 ?? (target2 = getter());
1555
+ return Reflect.deleteProperty(target2, prop);
1556
1556
  },
1557
1557
  ownKeys(_) {
1558
- target ?? (target = getter());
1559
- return Reflect.ownKeys(target);
1558
+ target2 ?? (target2 = getter());
1559
+ return Reflect.ownKeys(target2);
1560
1560
  },
1561
1561
  getOwnPropertyDescriptor(_, prop) {
1562
- target ?? (target = getter());
1563
- return Reflect.getOwnPropertyDescriptor(target, prop);
1562
+ target2 ?? (target2 = getter());
1563
+ return Reflect.getOwnPropertyDescriptor(target2, prop);
1564
1564
  },
1565
1565
  defineProperty(_, prop, descriptor) {
1566
- target ?? (target = getter());
1567
- return Reflect.defineProperty(target, prop, descriptor);
1566
+ target2 ?? (target2 = getter());
1567
+ return Reflect.defineProperty(target2, prop, descriptor);
1568
1568
  }
1569
1569
  });
1570
1570
  }
@@ -12016,15 +12016,15 @@ function _stringFormat(Class2, format, fnOrRegex, _params = {}) {
12016
12016
 
12017
12017
  // ../../../node_modules/zod/v4/core/to-json-schema.js
12018
12018
  function initializeContext(params) {
12019
- let target = params?.target ?? "draft-2020-12";
12020
- if (target === "draft-4")
12021
- target = "draft-04";
12022
- if (target === "draft-7")
12023
- target = "draft-07";
12019
+ let target2 = params?.target ?? "draft-2020-12";
12020
+ if (target2 === "draft-4")
12021
+ target2 = "draft-04";
12022
+ if (target2 === "draft-7")
12023
+ target2 = "draft-07";
12024
12024
  return {
12025
12025
  processors: params.processors ?? {},
12026
12026
  metadataRegistry: params?.metadata ?? globalRegistry,
12027
- target,
12027
+ target: target2,
12028
12028
  unrepresentable: params?.unrepresentable ?? "throw",
12029
12029
  override: params?.override ?? (() => {
12030
12030
  }),
@@ -12366,8 +12366,8 @@ var createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
12366
12366
  return finalize(ctx, schema);
12367
12367
  };
12368
12368
  var createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params) => {
12369
- const { libraryOptions, target } = params ?? {};
12370
- const ctx = initializeContext({ ...libraryOptions ?? {}, target, io, processors });
12369
+ const { libraryOptions, target: target2 } = params ?? {};
12370
+ const ctx = initializeContext({ ...libraryOptions ?? {}, target: target2, io, processors });
12371
12371
  process2(schema, ctx);
12372
12372
  extractDefs(ctx, schema);
12373
12373
  return finalize(ctx, schema);
@@ -13426,8 +13426,8 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
13426
13426
  catch(params) {
13427
13427
  return _catch2(this, params);
13428
13428
  },
13429
- pipe(target) {
13430
- return pipe(this, target);
13429
+ pipe(target2) {
13430
+ return pipe(this, target2);
13431
13431
  },
13432
13432
  readonly() {
13433
13433
  return readonly(this);
@@ -15657,15 +15657,15 @@ var threadOwnershipListResultSchema = external_exports.object({
15657
15657
  threads: external_exports.array(threadOwnershipSchema).min(1).max(THREAD_OWNERSHIP_LIST_MAX_LENGTH)
15658
15658
  }).strict().superRefine(({ threads }, context) => {
15659
15659
  const seen = /* @__PURE__ */ new Set();
15660
- for (const [index, thread] of threads.entries()) {
15661
- if (seen.has(thread.threadId)) {
15660
+ for (const [index, thread2] of threads.entries()) {
15661
+ if (seen.has(thread2.threadId)) {
15662
15662
  context.addIssue({
15663
15663
  code: "custom",
15664
15664
  message: "Thread ownership-list results must be unique",
15665
15665
  path: ["threads", index, "threadId"]
15666
15666
  });
15667
15667
  }
15668
- seen.add(thread.threadId);
15668
+ seen.add(thread2.threadId);
15669
15669
  }
15670
15670
  });
15671
15671
  var threadSteeringInspectParamsSchema = external_exports.object({
@@ -17003,6 +17003,44 @@ var remoteSshSetupParamsSchema = external_exports.object({
17003
17003
  }).strict();
17004
17004
  var remoteSshSetupResultSchema = external_exports.object({ state: external_exports.enum(["installed", "not-installed"]) }).strict();
17005
17005
 
17006
+ // ../../shared-contracts/dist/remote-sessions.js
17007
+ var REMOTE_CONTROLLER_REQUEST_MAX_BYTES = 16 * 1024;
17008
+ var identity = external_exports.string().min(1).max(1024);
17009
+ var target = { hostId: identity.regex(/^remote-(?:ssh(?:-|:)|control:)/u) };
17010
+ var thread = { ...target, threadId: identity };
17011
+ var remoteSessionOperationSchema = external_exports.discriminatedUnion("kind", [
17012
+ external_exports.strictObject({ kind: external_exports.literal("hosts") }),
17013
+ external_exports.strictObject({
17014
+ kind: external_exports.literal("list"),
17015
+ ...target,
17016
+ cursor: external_exports.string().nullable(),
17017
+ archived: external_exports.boolean()
17018
+ }),
17019
+ external_exports.strictObject({ kind: external_exports.literal("read"), ...thread }),
17020
+ external_exports.strictObject({
17021
+ kind: external_exports.literal("prompt"),
17022
+ ...thread,
17023
+ epoch: identity,
17024
+ text: external_exports.string().min(1).max(8e3),
17025
+ requestId: identity.optional()
17026
+ }),
17027
+ external_exports.strictObject({ kind: external_exports.literal("interrupt"), ...thread, epoch: identity, turnId: identity }),
17028
+ external_exports.strictObject({
17029
+ kind: external_exports.literal("rename"),
17030
+ ...thread,
17031
+ epoch: identity,
17032
+ name: external_exports.string().min(1).max(512)
17033
+ }),
17034
+ external_exports.strictObject({ kind: external_exports.literal("archive"), ...thread, epoch: identity, archived: external_exports.boolean() }),
17035
+ external_exports.strictObject({
17036
+ kind: external_exports.literal("respond"),
17037
+ ...thread,
17038
+ epoch: identity,
17039
+ requestId: external_exports.union([identity, external_exports.number().int()]),
17040
+ result: external_exports.record(external_exports.string(), external_exports.unknown())
17041
+ })
17042
+ ]);
17043
+
17006
17044
  // ../../shared-contracts/dist/remote-connections.js
17007
17045
  var hostId = external_exports.string().min(1).max(1024);
17008
17046
  var codexSshConnectionSchema = external_exports.object({
@@ -17023,7 +17061,9 @@ var codexSshDraftSchema = external_exports.strictObject({
17023
17061
  identity: external_exports.string().max(4096).nullable()
17024
17062
  });
17025
17063
  var remoteConnectionsRequestSchema = external_exports.discriminatedUnion("action", [
17064
+ external_exports.strictObject({ action: external_exports.literal("session"), operation: remoteSessionOperationSchema }),
17026
17065
  external_exports.strictObject({ action: external_exports.literal("list") }),
17066
+ external_exports.strictObject({ action: external_exports.literal("catalog") }),
17027
17067
  external_exports.strictObject({
17028
17068
  action: external_exports.literal("read-thread"),
17029
17069
  hostId: hostId.refine((id) => id !== "local"),
@@ -21308,11 +21348,11 @@ var AgentApp = class {
21308
21348
  [runAgentConnectHandlers](connection) {
21309
21349
  runConnectHandlers(connection, this.connectHandlers);
21310
21350
  }
21311
- connect(target, options = {}) {
21312
- return this.connectConnection(target, options).connection;
21351
+ connect(target2, options = {}) {
21352
+ return this.connectConnection(target2, options).connection;
21313
21353
  }
21314
- connectWith(target, op) {
21315
- const { rawConnection, connection } = this.connectConnection(target);
21354
+ connectWith(target2, op) {
21355
+ const { rawConnection, connection } = this.connectConnection(target2);
21316
21356
  return rawConnection.runUntil(() => op(connection.client));
21317
21357
  }
21318
21358
  /**
@@ -21353,22 +21393,22 @@ var AgentApp = class {
21353
21393
  registerAppNotification(this.builder, spec, (params, cx, signal) => agentNotificationContext(params, AgentContext.create(cx), signal), handler);
21354
21394
  return this;
21355
21395
  }
21356
- connectConnection(target, options = {}) {
21357
- if (isStream(target)) {
21358
- const state2 = this.openStreamConnection(target);
21396
+ connectConnection(target2, options = {}) {
21397
+ if (isStream(target2)) {
21398
+ const state2 = this.openStreamConnection(target2);
21359
21399
  if (!options.deferConnectHandlers) {
21360
21400
  this[runAgentConnectHandlers](state2.connection);
21361
21401
  }
21362
21402
  return state2;
21363
21403
  }
21364
21404
  const [thisStream, peerStream] = memoryStreamPair();
21365
- const peerRawConnection = target[appBuilder]().connect(peerStream, stableConnectionOptions);
21405
+ const peerRawConnection = target2[appBuilder]().connect(peerStream, stableConnectionOptions);
21366
21406
  const peerConnection = clientConnection(peerRawConnection);
21367
21407
  const state = this.openStreamConnection(thisStream);
21368
21408
  void state.rawConnection.closed.then(() => peerConnection.close());
21369
21409
  void peerRawConnection.closed.then(() => state.connection.close());
21370
21410
  try {
21371
- target[runClientConnectHandlers](peerConnection);
21411
+ target2[runClientConnectHandlers](peerConnection);
21372
21412
  this[runAgentConnectHandlers](state.connection);
21373
21413
  } catch (error53) {
21374
21414
  peerConnection.close(error53);
@@ -21408,11 +21448,11 @@ var ClientApp = class {
21408
21448
  [runClientConnectHandlers](connection) {
21409
21449
  runConnectHandlers(connection, this.connectHandlers);
21410
21450
  }
21411
- connect(target) {
21412
- return this.connectConnection(target).connection;
21451
+ connect(target2) {
21452
+ return this.connectConnection(target2).connection;
21413
21453
  }
21414
- connectWith(target, op) {
21415
- const { rawConnection, connection } = this.connectConnection(target);
21454
+ connectWith(target2, op) {
21455
+ const { rawConnection, connection } = this.connectConnection(target2);
21416
21456
  return rawConnection.runUntil(() => op(connection.agent));
21417
21457
  }
21418
21458
  /**
@@ -21453,20 +21493,20 @@ var ClientApp = class {
21453
21493
  registerAppNotification(this.builder, spec, (params, cx, signal) => clientNotificationContext(params, ClientContext.create(cx), signal), handler);
21454
21494
  return this;
21455
21495
  }
21456
- connectConnection(target) {
21457
- if (isStream(target)) {
21458
- const state2 = this.openStreamConnection(target);
21496
+ connectConnection(target2) {
21497
+ if (isStream(target2)) {
21498
+ const state2 = this.openStreamConnection(target2);
21459
21499
  this[runClientConnectHandlers](state2.connection);
21460
21500
  return state2;
21461
21501
  }
21462
21502
  const [thisStream, peerStream] = memoryStreamPair();
21463
- const peerRawConnection = target[appBuilder]().connect(peerStream, stableConnectionOptions);
21503
+ const peerRawConnection = target2[appBuilder]().connect(peerStream, stableConnectionOptions);
21464
21504
  const peerConnection = agentConnection(peerRawConnection);
21465
21505
  const state = this.openStreamConnection(thisStream);
21466
21506
  void state.rawConnection.closed.then(() => peerConnection.close());
21467
21507
  void peerRawConnection.closed.then(() => state.connection.close());
21468
21508
  try {
21469
- target[runAgentConnectHandlers](peerConnection);
21509
+ target2[runAgentConnectHandlers](peerConnection);
21470
21510
  this[runClientConnectHandlers](state.connection);
21471
21511
  } catch (error53) {
21472
21512
  peerConnection.close(error53);
@@ -26664,11 +26704,11 @@ var GrokHarnessSession = class {
26664
26704
  this.#publishUsage(usage, active.command.turnId);
26665
26705
  }
26666
26706
  #appendAgent(active, text, messageId) {
26667
- const identity = messageId ?? "agent";
26668
- if (active.agentMessageId !== identity) {
26707
+ const identity2 = messageId ?? "agent";
26708
+ if (active.agentMessageId !== identity2) {
26669
26709
  this.#completeReasoning(active, { status: "succeeded" });
26670
26710
  this.#completeAgent(active, { status: "succeeded" });
26671
- active.agentMessageId = identity;
26711
+ active.agentMessageId = identity2;
26672
26712
  }
26673
26713
  if (!active.agent) {
26674
26714
  active.agent = {
@@ -26694,10 +26734,10 @@ var GrokHarnessSession = class {
26694
26734
  });
26695
26735
  }
26696
26736
  #appendReasoning(active, text, messageId) {
26697
- const identity = messageId ?? "thought";
26698
- if (active.reasoningMessageId !== identity) {
26737
+ const identity2 = messageId ?? "thought";
26738
+ if (active.reasoningMessageId !== identity2) {
26699
26739
  this.#completeReasoning(active, { status: "succeeded" });
26700
- active.reasoningMessageId = identity;
26740
+ active.reasoningMessageId = identity2;
26701
26741
  }
26702
26742
  if (!active.reasoning) {
26703
26743
  active.reasoning = {
@@ -1,8 +1,8 @@
1
1
  import { createRequire as __codexhostCreateRequire } from "node:module"; const require = __codexhostCreateRequire(import.meta.url);
2
2
  var __defProp = Object.defineProperty;
3
- var __export = (target, all) => {
3
+ var __export = (target2, all) => {
4
4
  for (var name in all)
5
- __defProp(target, name, { get: all[name], enumerable: true });
5
+ __defProp(target2, name, { get: all[name], enumerable: true });
6
6
  };
7
7
 
8
8
  // ../../harness-discovery/dist/environment.js
@@ -1119,8 +1119,8 @@ function defineLazy(object2, key, getter) {
1119
1119
  function objectClone(obj) {
1120
1120
  return Object.create(Object.getPrototypeOf(obj), Object.getOwnPropertyDescriptors(obj));
1121
1121
  }
1122
- function assignProp(target, prop, value) {
1123
- Object.defineProperty(target, prop, {
1122
+ function assignProp(target2, prop, value) {
1123
+ Object.defineProperty(target2, prop, {
1124
1124
  value,
1125
1125
  writable: true,
1126
1126
  enumerable: true,
@@ -1303,35 +1303,35 @@ function normalizeParams(_params) {
1303
1303
  return params;
1304
1304
  }
1305
1305
  function createTransparentProxy(getter) {
1306
- let target;
1306
+ let target2;
1307
1307
  return new Proxy({}, {
1308
1308
  get(_, prop, receiver) {
1309
- target ?? (target = getter());
1310
- return Reflect.get(target, prop, receiver);
1309
+ target2 ?? (target2 = getter());
1310
+ return Reflect.get(target2, prop, receiver);
1311
1311
  },
1312
1312
  set(_, prop, value, receiver) {
1313
- target ?? (target = getter());
1314
- return Reflect.set(target, prop, value, receiver);
1313
+ target2 ?? (target2 = getter());
1314
+ return Reflect.set(target2, prop, value, receiver);
1315
1315
  },
1316
1316
  has(_, prop) {
1317
- target ?? (target = getter());
1318
- return Reflect.has(target, prop);
1317
+ target2 ?? (target2 = getter());
1318
+ return Reflect.has(target2, prop);
1319
1319
  },
1320
1320
  deleteProperty(_, prop) {
1321
- target ?? (target = getter());
1322
- return Reflect.deleteProperty(target, prop);
1321
+ target2 ?? (target2 = getter());
1322
+ return Reflect.deleteProperty(target2, prop);
1323
1323
  },
1324
1324
  ownKeys(_) {
1325
- target ?? (target = getter());
1326
- return Reflect.ownKeys(target);
1325
+ target2 ?? (target2 = getter());
1326
+ return Reflect.ownKeys(target2);
1327
1327
  },
1328
1328
  getOwnPropertyDescriptor(_, prop) {
1329
- target ?? (target = getter());
1330
- return Reflect.getOwnPropertyDescriptor(target, prop);
1329
+ target2 ?? (target2 = getter());
1330
+ return Reflect.getOwnPropertyDescriptor(target2, prop);
1331
1331
  },
1332
1332
  defineProperty(_, prop, descriptor) {
1333
- target ?? (target = getter());
1334
- return Reflect.defineProperty(target, prop, descriptor);
1333
+ target2 ?? (target2 = getter());
1334
+ return Reflect.defineProperty(target2, prop, descriptor);
1335
1335
  }
1336
1336
  });
1337
1337
  }
@@ -11783,15 +11783,15 @@ function _stringFormat(Class2, format, fnOrRegex, _params = {}) {
11783
11783
 
11784
11784
  // ../../../node_modules/zod/v4/core/to-json-schema.js
11785
11785
  function initializeContext(params) {
11786
- let target = params?.target ?? "draft-2020-12";
11787
- if (target === "draft-4")
11788
- target = "draft-04";
11789
- if (target === "draft-7")
11790
- target = "draft-07";
11786
+ let target2 = params?.target ?? "draft-2020-12";
11787
+ if (target2 === "draft-4")
11788
+ target2 = "draft-04";
11789
+ if (target2 === "draft-7")
11790
+ target2 = "draft-07";
11791
11791
  return {
11792
11792
  processors: params.processors ?? {},
11793
11793
  metadataRegistry: params?.metadata ?? globalRegistry,
11794
- target,
11794
+ target: target2,
11795
11795
  unrepresentable: params?.unrepresentable ?? "throw",
11796
11796
  override: params?.override ?? (() => {
11797
11797
  }),
@@ -12133,8 +12133,8 @@ var createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
12133
12133
  return finalize(ctx, schema);
12134
12134
  };
12135
12135
  var createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params) => {
12136
- const { libraryOptions, target } = params ?? {};
12137
- const ctx = initializeContext({ ...libraryOptions ?? {}, target, io, processors });
12136
+ const { libraryOptions, target: target2 } = params ?? {};
12137
+ const ctx = initializeContext({ ...libraryOptions ?? {}, target: target2, io, processors });
12138
12138
  process2(schema, ctx);
12139
12139
  extractDefs(ctx, schema);
12140
12140
  return finalize(ctx, schema);
@@ -13193,8 +13193,8 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
13193
13193
  catch(params) {
13194
13194
  return _catch2(this, params);
13195
13195
  },
13196
- pipe(target) {
13197
- return pipe(this, target);
13196
+ pipe(target2) {
13197
+ return pipe(this, target2);
13198
13198
  },
13199
13199
  readonly() {
13200
13200
  return readonly(this);
@@ -15424,15 +15424,15 @@ var threadOwnershipListResultSchema = external_exports.object({
15424
15424
  threads: external_exports.array(threadOwnershipSchema).min(1).max(THREAD_OWNERSHIP_LIST_MAX_LENGTH)
15425
15425
  }).strict().superRefine(({ threads }, context) => {
15426
15426
  const seen = /* @__PURE__ */ new Set();
15427
- for (const [index, thread] of threads.entries()) {
15428
- if (seen.has(thread.threadId)) {
15427
+ for (const [index, thread2] of threads.entries()) {
15428
+ if (seen.has(thread2.threadId)) {
15429
15429
  context.addIssue({
15430
15430
  code: "custom",
15431
15431
  message: "Thread ownership-list results must be unique",
15432
15432
  path: ["threads", index, "threadId"]
15433
15433
  });
15434
15434
  }
15435
- seen.add(thread.threadId);
15435
+ seen.add(thread2.threadId);
15436
15436
  }
15437
15437
  });
15438
15438
  var threadSteeringInspectParamsSchema = external_exports.object({
@@ -16770,6 +16770,44 @@ var remoteSshSetupParamsSchema = external_exports.object({
16770
16770
  }).strict();
16771
16771
  var remoteSshSetupResultSchema = external_exports.object({ state: external_exports.enum(["installed", "not-installed"]) }).strict();
16772
16772
 
16773
+ // ../../shared-contracts/dist/remote-sessions.js
16774
+ var REMOTE_CONTROLLER_REQUEST_MAX_BYTES = 16 * 1024;
16775
+ var identity = external_exports.string().min(1).max(1024);
16776
+ var target = { hostId: identity.regex(/^remote-(?:ssh(?:-|:)|control:)/u) };
16777
+ var thread = { ...target, threadId: identity };
16778
+ var remoteSessionOperationSchema = external_exports.discriminatedUnion("kind", [
16779
+ external_exports.strictObject({ kind: external_exports.literal("hosts") }),
16780
+ external_exports.strictObject({
16781
+ kind: external_exports.literal("list"),
16782
+ ...target,
16783
+ cursor: external_exports.string().nullable(),
16784
+ archived: external_exports.boolean()
16785
+ }),
16786
+ external_exports.strictObject({ kind: external_exports.literal("read"), ...thread }),
16787
+ external_exports.strictObject({
16788
+ kind: external_exports.literal("prompt"),
16789
+ ...thread,
16790
+ epoch: identity,
16791
+ text: external_exports.string().min(1).max(8e3),
16792
+ requestId: identity.optional()
16793
+ }),
16794
+ external_exports.strictObject({ kind: external_exports.literal("interrupt"), ...thread, epoch: identity, turnId: identity }),
16795
+ external_exports.strictObject({
16796
+ kind: external_exports.literal("rename"),
16797
+ ...thread,
16798
+ epoch: identity,
16799
+ name: external_exports.string().min(1).max(512)
16800
+ }),
16801
+ external_exports.strictObject({ kind: external_exports.literal("archive"), ...thread, epoch: identity, archived: external_exports.boolean() }),
16802
+ external_exports.strictObject({
16803
+ kind: external_exports.literal("respond"),
16804
+ ...thread,
16805
+ epoch: identity,
16806
+ requestId: external_exports.union([identity, external_exports.number().int()]),
16807
+ result: external_exports.record(external_exports.string(), external_exports.unknown())
16808
+ })
16809
+ ]);
16810
+
16773
16811
  // ../../shared-contracts/dist/remote-connections.js
16774
16812
  var hostId = external_exports.string().min(1).max(1024);
16775
16813
  var codexSshConnectionSchema = external_exports.object({
@@ -16790,7 +16828,9 @@ var codexSshDraftSchema = external_exports.strictObject({
16790
16828
  identity: external_exports.string().max(4096).nullable()
16791
16829
  });
16792
16830
  var remoteConnectionsRequestSchema = external_exports.discriminatedUnion("action", [
16831
+ external_exports.strictObject({ action: external_exports.literal("session"), operation: remoteSessionOperationSchema }),
16793
16832
  external_exports.strictObject({ action: external_exports.literal("list") }),
16833
+ external_exports.strictObject({ action: external_exports.literal("catalog") }),
16794
16834
  external_exports.strictObject({
16795
16835
  action: external_exports.literal("read-thread"),
16796
16836
  hostId: hostId.refine((id) => id !== "local"),
@@ -17371,8 +17411,8 @@ async function venvPythonFromShim(hermesExecutable, platform = process.platform)
17371
17411
  try {
17372
17412
  const shim = await readFile(hermesExecutable, "utf8");
17373
17413
  if (platform === "win32") {
17374
- const target = WINDOWS_VENV_HERMES_SHIM_PATTERN.exec(shim)?.[1];
17375
- return target ? path4.win32.join(path4.win32.dirname(target), "python.exe") : null;
17414
+ const target2 = WINDOWS_VENV_HERMES_SHIM_PATTERN.exec(shim)?.[1];
17415
+ return target2 ? path4.win32.join(path4.win32.dirname(target2), "python.exe") : null;
17376
17416
  }
17377
17417
  return POSIX_VENV_PYTHON_SHIM_PATTERN.exec(shim)?.[1] ?? null;
17378
17418
  } catch {
@@ -18016,11 +18056,11 @@ function hermesCommandsFromCompletion(items, value) {
18016
18056
  const entry = gatewayRecord(category);
18017
18057
  if (!Array.isArray(entry.pairs))
18018
18058
  continue;
18019
- const target = entry.name === "Plugin commands" ? plugins : entry.name === "User commands" ? quick : null;
18020
- if (target) {
18059
+ const target2 = entry.name === "Plugin commands" ? plugins : entry.name === "User commands" ? quick : null;
18060
+ if (target2) {
18021
18061
  for (const pair of entry.pairs)
18022
18062
  if (Array.isArray(pair) && typeof pair[0] === "string")
18023
- target.add(pair[0]);
18063
+ target2.add(pair[0]);
18024
18064
  }
18025
18065
  }
18026
18066
  const reviewed = /* @__PURE__ */ new Set(["status", "diff", "egress", "whoami", "insights", "bundles"]);