@neta-art/cohub-cli 10.29.1 → 10.31.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 (87) hide show
  1. package/dist/board-gpu/page.js +3011 -133
  2. package/dist/bootstrap.js +2 -4
  3. package/dist/build.json +1 -1
  4. package/dist/chunks/FilterPipe.js +145 -269
  5. package/dist/chunks/about.js +2 -3
  6. package/dist/chunks/app-realtime.js +113 -115
  7. package/dist/chunks/app-realtime2.js +1 -2
  8. package/dist/chunks/app-ref.js +4 -5
  9. package/dist/chunks/apps.js +8 -14
  10. package/dist/chunks/auth.js +1 -2
  11. package/dist/chunks/avatar.js +2 -4
  12. package/dist/chunks/binary-pins.js +1 -2
  13. package/dist/chunks/board-export-resources.js +55 -12
  14. package/dist/chunks/board-export.js +26 -21
  15. package/dist/chunks/board-export2.js +1 -2
  16. package/dist/chunks/board-kernel.js +2672 -1623
  17. package/dist/chunks/board-kernel2.js +2 -2
  18. package/dist/chunks/board-model.js +970 -0
  19. package/dist/chunks/board-profile.js +4 -5
  20. package/dist/chunks/board-simulate.js +6 -6
  21. package/dist/chunks/board-time.js +1 -2
  22. package/dist/chunks/boards.js +547 -23
  23. package/dist/chunks/browserAll.js +18 -35
  24. package/dist/chunks/channels.js +1 -2
  25. package/dist/chunks/client.js +637 -713
  26. package/dist/chunks/command-input.js +1 -2
  27. package/dist/chunks/commander.js +16 -22
  28. package/dist/chunks/cron-jobs.js +2 -3
  29. package/dist/chunks/daemon.js +18 -4
  30. package/dist/chunks/daemon2.js +1 -2
  31. package/dist/chunks/desktop.js +2 -3
  32. package/dist/chunks/endpoint-options.js +1 -2
  33. package/dist/chunks/env-proxy.js +4 -5
  34. package/dist/chunks/environment.js +2 -4
  35. package/dist/chunks/feedback.js +3 -4
  36. package/dist/chunks/generations.js +3 -4
  37. package/dist/chunks/host.js +1 -2
  38. package/dist/chunks/http-put.js +1 -2
  39. package/dist/chunks/id.js +77 -928
  40. package/dist/chunks/init.js +7 -12
  41. package/dist/chunks/install.js +142 -138
  42. package/dist/chunks/launch.js +4 -6
  43. package/dist/chunks/lexer.js +226 -66
  44. package/dist/chunks/local-media.js +1 -2
  45. package/dist/chunks/me.js +1 -2
  46. package/dist/chunks/media.js +1 -2
  47. package/dist/chunks/{themes.js → model-clips.js} +395 -43
  48. package/dist/chunks/models.js +3 -5
  49. package/dist/chunks/operands.js +1 -2
  50. package/dist/chunks/package-paths.js +1 -2
  51. package/dist/chunks/policy.js +1 -2
  52. package/dist/chunks/preferences.js +1 -2
  53. package/dist/chunks/profile.js +2 -3
  54. package/dist/chunks/prompts.js +1 -2
  55. package/dist/chunks/public.js +1 -2
  56. package/dist/chunks/public2.js +3 -4
  57. package/dist/chunks/references.js +3 -3
  58. package/dist/chunks/referrals.js +1 -2
  59. package/dist/chunks/rolldown-runtime.js +2 -3
  60. package/dist/chunks/rooms-connect.js +1 -2
  61. package/dist/chunks/rooms-connect2.js +1 -2
  62. package/dist/chunks/rooms-rtc.js +4 -6
  63. package/dist/chunks/rooms.js +2 -3
  64. package/dist/chunks/run.js +2 -3
  65. package/dist/chunks/runtime.js +6 -12
  66. package/dist/chunks/runtime2.js +2 -3
  67. package/dist/chunks/runtimes.js +1 -2
  68. package/dist/chunks/safe-remote-image.js +1 -2
  69. package/dist/chunks/schemas.js +58 -43
  70. package/dist/chunks/search.js +3 -3
  71. package/dist/chunks/self-update.js +4 -5
  72. package/dist/chunks/serve.js +11 -25
  73. package/dist/chunks/session-status.js +1 -2
  74. package/dist/chunks/skills.js +1 -2
  75. package/dist/chunks/spaces.js +26 -45
  76. package/dist/chunks/src.js +5 -9
  77. package/dist/chunks/supervisor.js +16 -28
  78. package/dist/chunks/supervisor2.js +1 -2
  79. package/dist/chunks/tasks.js +1 -2
  80. package/dist/chunks/user-lists.js +1 -2
  81. package/dist/chunks/version.js +1 -2
  82. package/dist/chunks/version2.js +1 -2
  83. package/dist/chunks/version3.js +3 -4
  84. package/dist/chunks/web.js +1 -2
  85. package/dist/runtime/native/pi-extension.js +1 -2
  86. package/dist/runtime/worker.js +2 -3
  87. package/package.json +11 -10
@@ -1,12 +1,12 @@
1
- import { C as error, D as json, E as handleHttp, O as jsonRequested, b as resolveSpace, t as createClient } from "./client.js";
2
1
  import { a as isTextMime, o as mimeTypeForPath } from "./id.js";
3
2
  import { r as mediaFacts } from "./media.js";
4
- import { t as localMediaFacts } from "./local-media.js";
3
+ import { C as error, D as json, E as handleHttp, O as jsonRequested, b as resolveSpace, t as createClient } from "./client.js";
5
4
  import { r as putLocalFile, t as HttpPutError } from "./http-put.js";
5
+ import { t as localMediaFacts } from "./local-media.js";
6
6
  import { basename, relative, resolve } from "node:path";
7
7
  import { randomUUID } from "node:crypto";
8
8
  import { lstat, readdir } from "node:fs/promises";
9
- //#region src/commands/public.ts
9
+ // src/commands/public.ts
10
10
  const UPLOAD_CONCURRENCY = 4;
11
11
  function hasControlCharacters(value) {
12
12
  return [...value].some((char) => {
@@ -240,5 +240,4 @@ function registerPublic(program, deps = {}) {
240
240
  publicCommand.command("url <path>").description("Print a public file URL").action((path, _opts, command) => printPublicUrl(command, path, deps));
241
241
  return publicCommand;
242
242
  }
243
- //#endregion
244
243
  export { registerPublic as n, collectPublicUpload as t };
@@ -1,5 +1,6 @@
1
- import { C as error, D as json, E as handleHttp, O as jsonRequested, T as formatLocalDateTime, j as table, st as isUuid, t as createClient } from "./client.js";
2
- //#region src/commands/references.ts
1
+ import { p as isUuid } from "./app-realtime.js";
2
+ import { C as error, D as json, E as handleHttp, O as jsonRequested, T as formatLocalDateTime, j as table, t as createClient } from "./client.js";
3
+ // src/commands/references.ts
3
4
  const RESOURCE_TYPES = /* @__PURE__ */ new Set([
4
5
  "turn",
5
6
  "session",
@@ -193,5 +194,4 @@ function formatTarget(targetType, targetId) {
193
194
  }
194
195
  return `${targetType}:${targetId.slice(0, 8)}`;
195
196
  }
196
- //#endregion
197
197
  export { registerReferences };
@@ -1,6 +1,6 @@
1
1
  import { C as error, D as json, E as handleHttp, O as jsonRequested, T as formatLocalDateTime, j as table, k as ok, t as createClient } from "./client.js";
2
2
  import { t as webUrl } from "./web.js";
3
- //#region src/commands/referrals.ts
3
+ // src/commands/referrals.ts
4
4
  function referralUrl(code) {
5
5
  return webUrl(`/referrals/${code}`);
6
6
  }
@@ -86,5 +86,4 @@ function registerReferrals(program) {
86
86
  }
87
87
  });
88
88
  }
89
- //#endregion
90
89
  export { registerReferrals };
@@ -1,12 +1,12 @@
1
1
  import { createRequire } from "node:module";
2
- //#region \0rolldown/runtime.js
2
+ // \0rolldown/runtime.js
3
3
  var __create = Object.create;
4
4
  var __defProp = Object.defineProperty;
5
5
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
6
  var __getOwnPropNames = Object.getOwnPropertyNames;
7
7
  var __getProtoOf = Object.getPrototypeOf;
8
8
  var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
9
+ var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod, mod.exports), cb = null), mod.exports);
10
10
  var __copyProps = (to, from, except, desc) => {
11
11
  if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
12
12
  key = keys[i];
@@ -22,5 +22,4 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
22
22
  enumerable: true
23
23
  }) : target, mod));
24
24
  var __require = /* #__PURE__ */ (() => createRequire(import.meta.url))();
25
- //#endregion
26
25
  export { __require as n, __toESM as r, __commonJSMin as t };
@@ -1,2 +1 @@
1
- import { t as connectToRoom } from "./rooms-connect2.js";
2
- export { connectToRoom };
1
+ export { t as connectToRoom } from "./rooms-connect2.js";
@@ -1,5 +1,5 @@
1
1
  import { r as createRealtimeClient } from "./client.js";
2
- //#region src/commands/rooms-connect.ts
2
+ // src/commands/rooms-connect.ts
3
3
  const MAX_LINE_BYTES = 20480;
4
4
  const MAX_OUTPUT_BUFFER_BYTES = 1048576;
5
5
  function parseRoomInput(line) {
@@ -147,5 +147,4 @@ async function connectToRoom(roomId, options) {
147
147
  process.removeListener("SIGTERM", onSignal);
148
148
  }
149
149
  }
150
- //#endregion
151
150
  export { parseRoomInput as n, readRoomLines as r, connectToRoom as t };
@@ -1,7 +1,7 @@
1
- import { r as createRealtimeClient } from "./client.js";
2
1
  import { s as HttpError } from "./app-realtime.js";
3
- import "./binary-pins.js";
2
+ import { r as createRealtimeClient } from "./client.js";
4
3
  import { r as readRoomLines } from "./rooms-connect2.js";
4
+ import "./binary-pins.js";
5
5
  import { spawn } from "node:child_process";
6
6
  import { homedir } from "node:os";
7
7
  import { createReadStream, createWriteStream } from "node:fs";
@@ -11,7 +11,7 @@ import { Readable, Transform } from "node:stream";
11
11
  import { chmod, lstat, mkdir, mkdtemp, readFile, rename, rm, writeFile } from "node:fs/promises";
12
12
  import { pipeline } from "node:stream/promises";
13
13
  import { createGunzip } from "node:zlib";
14
- //#region src/commands/rooms-rtc-binary.ts
14
+ // src/commands/rooms-rtc-binary.ts
15
15
  const MAX_BINARY_BYTES = 134217728;
16
16
  async function digest(path) {
17
17
  const hash = createHash("sha256");
@@ -105,8 +105,7 @@ async function ensureRtcBinary(local) {
105
105
  });
106
106
  }
107
107
  }
108
- //#endregion
109
- //#region src/commands/rooms-rtc.ts
108
+ // src/commands/rooms-rtc.ts
110
109
  async function runRoomRtc(roomId, options) {
111
110
  if (options.delivery !== "reliable" && options.delivery !== "latest") throw new Error("--delivery must be reliable or latest");
112
111
  if (options.dataInput && !options.channel) throw new Error("--data-input requires --channel");
@@ -307,5 +306,4 @@ async function runRoomRtc(roomId, options) {
307
306
  }
308
307
  if (failure) throw failure;
309
308
  }
310
- //#endregion
311
309
  export { runRoomRtc };
@@ -1,6 +1,6 @@
1
- import { C as error, D as json, E as handleHttp, M as truncateText, O as jsonRequested, j as table, k as ok, t as createClient } from "./client.js";
2
1
  import { t as getAppByRef } from "./app-ref.js";
3
- //#region src/commands/rooms.ts
2
+ import { C as error, D as json, E as handleHttp, M as truncateText, O as jsonRequested, j as table, k as ok, t as createClient } from "./client.js";
3
+ // src/commands/rooms.ts
4
4
  const DURATION_RE = /^(\d+)(ms|s|m|h|d)?$/i;
5
5
  const DURATION_UNITS = {
6
6
  ms: 1,
@@ -207,5 +207,4 @@ async function follow(client, roomId, input) {
207
207
  after = page.cursor;
208
208
  }
209
209
  }
210
- //#endregion
211
210
  export { registerRooms };
@@ -1,6 +1,6 @@
1
- import { A as spinner, C as error, D as json, E as handleHttp, S as resolveSpaceTarget, t as createClient } from "./client.js";
2
1
  import { t as consumeBaseUrlOption } from "./endpoint-options.js";
3
- //#region src/commands/run.ts
2
+ import { A as spinner, C as error, D as json, E as handleHttp, S as resolveSpaceTarget, t as createClient } from "./client.js";
3
+ // src/commands/run.ts
4
4
  const DEFAULT_WAIT_TIMEOUT_MS = 2166e4;
5
5
  const DEFAULT_POLL_INTERVAL_MS = 1500;
6
6
  function shellQuote(value) {
@@ -216,5 +216,4 @@ async function maybeHandleRunCommand(argv) {
216
216
  await handleRunCli(argv);
217
217
  return true;
218
218
  }
219
- //#endregion
220
219
  export { maybeHandleRunCommand, printRunHelp };
@@ -1,10 +1,9 @@
1
1
  import { S as _isoDateTime, _ as union, a as array, b as uuid, c as discriminatedUnion, d as literal, f as number, h as string, m as record, n as _enum, p as object, s as boolean, t as ZodISODateTime, u as lazy, v as unknown, y as url } from "./schemas.js";
2
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/classic/iso.js
2
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/classic/iso.js
3
3
  function datetime(params) {
4
4
  return _isoDateTime(ZodISODateTime, params);
5
5
  }
6
- //#endregion
7
- //#region ../protocol/src/model/thinking.ts
6
+ // ../protocol/dist/model/thinking.js
8
7
  /** Every thinking level a Harness or model can declare, in ascending order. */
9
8
  const MODEL_THINKING_LEVELS = [
10
9
  "off",
@@ -35,8 +34,7 @@ function thinkingLevelMapFor(native) {
35
34
  }));
36
35
  }
37
36
  const isModelThinkingLevel = (value) => typeof value === "string" && MODEL_THINKING_LEVELS.includes(value);
38
- //#endregion
39
- //#region ../protocol/src/core/content-schema.ts
37
+ // ../protocol/dist/core/content-schema.js
40
38
  const meta = record(string(), unknown());
41
39
  const contentBlockSchema = lazy(() => discriminatedUnion("type", [
42
40
  object({
@@ -94,8 +92,7 @@ const contentBlockSchema = lazy(() => discriminatedUnion("type", [
94
92
  _meta: meta.optional()
95
93
  })
96
94
  ]));
97
- //#endregion
98
- //#region ../protocol/src/runtime/harnesses.ts
95
+ // ../protocol/dist/runtime/harnesses.js
99
96
  /** Single source of truth for local Harness identities. Adding a Harness starts here. */
100
97
  const LOCAL_HARNESSES = [
101
98
  "pi",
@@ -137,8 +134,7 @@ const isLocalHarness = (value) => LOCAL_HARNESSES.includes(value);
137
134
  const assertHarnessAccess = (harness, accessMode) => {
138
135
  if (accessMode === "read_only" && isLocalHarness(harness) && !LOCAL_HARNESS_SPECS[harness].readOnly) throw new Error(`${LOCAL_HARNESS_SPECS[harness].label} cannot enforce read-only access`);
139
136
  };
140
- //#endregion
141
- //#region ../protocol/src/runtime/archive.ts
137
+ // ../protocol/dist/runtime/archive.js
142
138
  const nativeFormats = LOCAL_HARNESSES.map((harness) => LOCAL_HARNESS_SPECS[harness].nativeFormat);
143
139
  const RUNTIME_ARCHIVE_SEGMENT_BYTES = 4194304;
144
140
  const digest = string().regex(/^[a-f0-9]{64}$/);
@@ -173,8 +169,7 @@ function validateArchiveBoundary(index, parent) {
173
169
  if (offset !== index.sizeBytes || !parent && !index.segments.length) throw new Error("Archive is incomplete");
174
170
  if (!index.segments.length && parent?.sha256 !== index.sha256) throw new Error("Unchanged archive checksum mismatch");
175
171
  }
176
- //#endregion
177
- //#region ../protocol/src/runtime/native.ts
172
+ // ../protocol/dist/runtime/native.js
178
173
  const id$1 = uuid();
179
174
  const content$1 = array(contentBlockSchema).max(1e4);
180
175
  const count$1 = number().finite().nonnegative().optional();
@@ -650,5 +645,4 @@ const runtimeCommandSchema = discriminatedUnion("type", [
650
645
  turnId: id
651
646
  })
652
647
  ]);
653
- //#endregion
654
648
  export { MODEL_THINKING_LEVELS as C, isLocalHarness as S, thinkingLevelMapFor as T, validateArchiveBoundary as _, runtimeCapabilitiesSchema as a, assertHarnessAccess as b, runtimeHelloCapabilities as c, APPROVAL_DECISIONS as d, SETTLED_TURN_STATUSES as f, harnessArchiveIndexSchema as g, RUNTIME_ARCHIVE_SEGMENT_BYTES as h, isApprovalMode as i, runtimeReadySchema as l, runtimeNativeStopSchema as m, RUNTIME_MAX_FRAME_BYTES as n, runtimeCommandSchema as o, runtimeApprovalDecisionSchema as p, STANDARD_SERVICE_TIER as r, runtimeEventSchema as s, APPROVAL_MODES as t, runtimeServiceTierSchema as u, LOCAL_HARNESSES as v, isModelThinkingLevel as w, harnessSchema as x, LOCAL_HARNESS_SPECS as y };
@@ -1,11 +1,11 @@
1
1
  import { v as LOCAL_HARNESSES, y as LOCAL_HARNESS_SPECS } from "./runtime.js";
2
2
  import { D as json, J as getRuntimeSpaceBinding, O as jsonRequested, f as stopRuntimeInstance, h as currentIdentityKey, l as requestRuntimeInstance, q as canonicalRuntimeRoot, s as controlRuntimeInstance, t as createClient, u as runtimeInstanceDirectory } from "./client.js";
3
- import { J as serializeDiagnosticError, K as readRuntimeDiagnosticEvents, W as RuntimeDiagnosticReader, c as runtimeStateRoot, f as diagnosticLevels, g as printRuntimeSummary, h as formatNativeSync, l as writeNativeConfig, m as formatImportProgress, p as formatDiagnostic, q as runtimeDiagnosticsDirectory, r as piExtensionState, s as readNativeConfig, t as installPiExtension, u as atLeastLevel, y as RuntimeArchiveStore } from "./install.js";
4
3
  import { a as resolveRuntimeTarget, o as runtimeUp, r as parseRuntimeHarnesses } from "./launch.js";
4
+ import { J as serializeDiagnosticError, K as readRuntimeDiagnosticEvents, W as RuntimeDiagnosticReader, c as runtimeStateRoot, f as diagnosticLevels, g as printRuntimeSummary, h as formatNativeSync, l as writeNativeConfig, m as formatImportProgress, p as formatDiagnostic, q as runtimeDiagnosticsDirectory, r as piExtensionState, s as readNativeConfig, t as installPiExtension, u as atLeastLevel, y as RuntimeArchiveStore } from "./install.js";
5
5
  import { t as forgetHostRuntime } from "./runtimes.js";
6
6
  import { join } from "node:path";
7
7
  import { setTimeout } from "node:timers/promises";
8
- //#region src/commands/runtime.ts
8
+ // src/commands/runtime.ts
9
9
  const reportFailure = (cause) => {
10
10
  process.stderr.write(`Runtime failed: ${serializeDiagnosticError(cause).message}\n`);
11
11
  process.exitCode = 1;
@@ -282,5 +282,4 @@ function registerRuntime(program) {
282
282
  }
283
283
  });
284
284
  }
285
- //#endregion
286
285
  export { registerRuntime };
@@ -3,7 +3,7 @@ import { homedir } from "node:os";
3
3
  import { dirname, join } from "node:path";
4
4
  import { randomUUID } from "node:crypto";
5
5
  import { mkdir, readFile, rename, rm, writeFile } from "node:fs/promises";
6
- //#region src/host/runtimes.ts
6
+ // src/host/runtimes.ts
7
7
  const hostRuntimesPath = () => join(homedir(), ".local", "state", "cohub", "host", "runtimes.json");
8
8
  async function read(path) {
9
9
  let text;
@@ -44,5 +44,4 @@ async function update(path, change) {
44
44
  const hostRuntimes = (key, path = hostRuntimesPath()) => read(path).then((runtimes) => runtimes.filter((item) => item.key === key));
45
45
  const rememberHostRuntime = (runtime, path = hostRuntimesPath()) => update(path, (runtimes) => [...runtimes.filter((item) => item.key !== runtime.key || item.spaceId !== runtime.spaceId), runtime]);
46
46
  const forgetHostRuntime = (key, spaceId, path = hostRuntimesPath()) => update(path, (runtimes) => runtimes.filter((item) => item.key !== key || item.spaceId !== spaceId));
47
- //#endregion
48
47
  export { hostRuntimes as n, rememberHostRuntime as r, forgetHostRuntime as t };
@@ -1,4 +1,4 @@
1
- import { ft as isPublicBoardRemoteAddress, pt as normalizeBoardRemoteUrl } from "./id.js";
1
+ import { N as isPublicBoardRemoteAddress, P as normalizeBoardRemoteUrl } from "./board-model.js";
2
2
  import http from "node:http";
3
3
  import { isIP } from "node:net";
4
4
  import dns from "node:dns/promises";
@@ -194,5 +194,4 @@ async function downloadPublicMedia(input, mimeTypes, options) {
194
194
  }
195
195
  throw new Error("Too many media redirects");
196
196
  }
197
- //#endregion
198
197
  export { downloadPublicImage as n, downloadPublicVideo as r, downloadPublicAudio as t };
@@ -1,4 +1,4 @@
1
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/util.js
1
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/util.js
2
2
  function getEnumValues(entries) {
3
3
  const numericValues = Object.values(entries).filter((v) => typeof v === "number");
4
4
  return Object.entries(entries).filter(([k, _]) => numericValues.indexOf(+k) === -1).map(([_, v]) => v);
@@ -323,6 +323,17 @@ function prefixIssues(path, issues) {
323
323
  function unwrapMessage(message) {
324
324
  return typeof message === "string" ? message : message?.message;
325
325
  }
326
+ /** The leading size checks of `defChecks` that set an upper bound, each paired with it. */
327
+ function sizeCaps(defChecks) {
328
+ const caps = [];
329
+ for (const ch of defChecks ?? []) {
330
+ const d = ch._zod.def;
331
+ if (!/_(length|size)$|_equals$/.test(d.check)) break;
332
+ const max = d.maximum ?? d.length ?? d.size;
333
+ if (max >= 0) caps.push([max, ch]);
334
+ }
335
+ return caps;
336
+ }
326
337
  function attachSchema(issues, start, inst) {
327
338
  var _a;
328
339
  for (let i = start; i < issues.length; i++) (_a = issues[i]).schema ?? (_a.schema = inst);
@@ -415,6 +426,7 @@ function hide(inst, key, value) {
415
426
  return own(inst, key, value, false);
416
427
  }
417
428
  /** Adds members a table derives from the instance: each builds on first read and shadows as own data, and assignment shadows the same way, as when these were own properties. */
429
+ /* @__NO_SIDE_EFFECTS__ */
418
430
  function derived(computes, table) {
419
431
  for (const key in computes) {
420
432
  const compute = computes[key];
@@ -538,8 +550,7 @@ function constantCatch(value) {
538
550
  fn[CONSTANT_CATCH] = true;
539
551
  return fn;
540
552
  }
541
- //#endregion
542
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/core.js
553
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/core.js
543
554
  var _a$1;
544
555
  const _zodDesc = {
545
556
  value: void 0,
@@ -566,6 +577,7 @@ function newError(Definition) {
566
577
  }
567
578
  return new Definition();
568
579
  }
580
+ /* @__NO_SIDE_EFFECTS__ */
569
581
  function $constructor(name, initializer, proto, params) {
570
582
  const zodProto = {};
571
583
  function Internals(def) {
@@ -644,8 +656,7 @@ function config(newConfig) {
644
656
  if (newConfig) Object.assign(globalConfig, newConfig);
645
657
  return globalConfig;
646
658
  }
647
- //#endregion
648
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/errors.js
659
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/errors.js
649
660
  function _getMessage() {
650
661
  const internals = this._zod;
651
662
  internals.message ?? (internals.message = JSON.stringify(internals.def, jsonStringifyReplacer, 2));
@@ -696,8 +707,7 @@ const initializer$1 = (inst, def) => {
696
707
  });
697
708
  }
698
709
  };
699
- const $ZodError = $constructor("$ZodError", initializer$1);
700
- $constructor("$ZodError", initializer$1, void 0, { Parent: Error });
710
+ const $ZodError = /* @__PURE__ */ $constructor("$ZodError", initializer$1);
701
711
  /** Get-or-create `obj[key]` as an own data property. A path segment naming an inherited member
702
712
  * ("toString", "constructor") would otherwise read through to the prototype, and assigning
703
713
  * "__proto__" would hit the setter instead of creating a key. */
@@ -760,8 +770,7 @@ function formatError(error, mapper = (issue) => issue.message) {
760
770
  processError(error);
761
771
  return fieldErrors;
762
772
  }
763
- //#endregion
764
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/parse.js
773
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/parse.js
765
774
  function finalizeParams(callee, params) {
766
775
  return {
767
776
  callee: params?.callee ?? callee,
@@ -963,8 +972,7 @@ const _safeEncodeAsync = (_Err) => async (schema, value, _ctx) => {
963
972
  const _safeDecodeAsync = (_Err) => async (schema, value, _ctx) => {
964
973
  return _safeParseAsync(_Err)(schema, value, _ctx);
965
974
  };
966
- //#endregion
967
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/regexes.js
975
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/regexes.js
968
976
  /**
969
977
  * @deprecated CUID v1 is deprecated by its authors due to information leakage
970
978
  * (timestamps embedded in the id). Use {@link cuid2} instead.
@@ -1037,8 +1045,7 @@ const _null$2 = /^null$/i;
1037
1045
  const _undefined$2 = /^undefined$/i;
1038
1046
  const lowercase = /^[^A-Z]*$/;
1039
1047
  const uppercase = /^[^a-z]*$/;
1040
- //#endregion
1041
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/checks.js
1048
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/checks.js
1042
1049
  const $ZodCheck = /*@__PURE__*/ $constructor("$ZodCheck", (inst, def) => {
1043
1050
  var _a;
1044
1051
  inst._zod ?? (inst._zod = {});
@@ -1333,8 +1340,7 @@ const $ZodCheckOverwrite = /*@__PURE__*/ $constructor("$ZodCheckOverwrite", (ins
1333
1340
  payload.value = def.tx(payload.value);
1334
1341
  };
1335
1342
  });
1336
- //#endregion
1337
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/doc.js
1343
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/doc.js
1338
1344
  var Doc = class {
1339
1345
  constructor(args = [], closed = {}) {
1340
1346
  this.content = [];
@@ -1367,15 +1373,13 @@ var Doc = class {
1367
1373
  return new F(...Object.keys(this.closed), `return function (${this.args.join(", ")}) {\n${content.join("\n")}\n};`)(...Object.values(this.closed));
1368
1374
  }
1369
1375
  };
1370
- //#endregion
1371
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/versions.js
1376
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/versions.js
1372
1377
  const version = {
1373
1378
  major: 4,
1374
1379
  minor: 6,
1375
- patch: 5
1380
+ patch: 7
1376
1381
  };
1377
- //#endregion
1378
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/schemas.js
1382
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/schemas.js
1379
1383
  const $ZodType = /*@__PURE__*/ $constructor("$ZodType", (inst, def) => {
1380
1384
  var _a;
1381
1385
  inst ?? (inst = {});
@@ -1904,6 +1908,26 @@ const $ZodNever = /*@__PURE__*/ $constructor("$ZodNever", (inst, def) => {
1904
1908
  return payload;
1905
1909
  };
1906
1910
  });
1911
+ function capSize(inst, size) {
1912
+ const caps = sizeCaps(inst._zod.def.checks);
1913
+ if (!caps.length) return;
1914
+ const cap = Math.min(...caps.map((c) => c[0]));
1915
+ const parse = inst._zod.parse;
1916
+ inst._zod.parse = (payload, ctx) => {
1917
+ const n = size(payload.value);
1918
+ if (n > cap && !ctx?.skipChecks && ctx?.direction !== "backward") {
1919
+ for (const [max, ch] of sizeCaps(inst._zod.def.checks)) if (n > max && ch._zod.def.when(payload)) {
1920
+ const start = payload.issues.length;
1921
+ ch._zod.check(payload);
1922
+ payload.issues[start].continue = false;
1923
+ attachSchema(payload.issues, start, inst);
1924
+ return payload;
1925
+ }
1926
+ }
1927
+ return parse(payload, ctx);
1928
+ };
1929
+ }
1930
+ const arraySize = (input) => Array.isArray(input) ? input.length : -1;
1907
1931
  function handleArrayResult(result, final, index) {
1908
1932
  if (result.issues.length) final.issues.push(...prefixIssues(index, result.issues));
1909
1933
  final.value[index] = result.value;
@@ -1941,6 +1965,7 @@ const $ZodArray = /*@__PURE__*/ $constructor("$ZodArray", (inst, def) => {
1941
1965
  if (proms.length) return Promise.all(proms).then(() => payload);
1942
1966
  return payload;
1943
1967
  };
1968
+ capSize(inst, arraySize);
1944
1969
  });
1945
1970
  function handlePropertyResult(result, final, key, input, optin, optout) {
1946
1971
  const isPresent = key in input;
@@ -2049,7 +2074,7 @@ const $ZodObject = /*@__PURE__*/ $constructor("$ZodObject", (inst, def) => {
2049
2074
  }
2050
2075
  return propValues;
2051
2076
  });
2052
- const isObject$2 = isObject;
2077
+ const isObject$1 = isObject;
2053
2078
  const catchall = def.catchall;
2054
2079
  let value;
2055
2080
  const memo = globalConfig.memoizer;
@@ -2057,7 +2082,7 @@ const $ZodObject = /*@__PURE__*/ $constructor("$ZodObject", (inst, def) => {
2057
2082
  inst._zod.parse = (payload, ctx) => {
2058
2083
  value ?? (value = _normalized.value);
2059
2084
  const input = payload.value;
2060
- if (!isObject$2(input)) {
2085
+ if (!isObject$1(input)) {
2061
2086
  payload.issues.push({
2062
2087
  expected: "object",
2063
2088
  code: "invalid_type",
@@ -2187,7 +2212,7 @@ const $ZodObjectJIT = /*@__PURE__*/ $constructor("$ZodObjectJIT", (inst, def) =>
2187
2212
  return doc.compile();
2188
2213
  };
2189
2214
  let fastpass;
2190
- const isObject$1 = isObject;
2215
+ const isObject$2 = isObject;
2191
2216
  const jit = !globalConfig.jitless;
2192
2217
  const fastEnabled = jit && allowsEval.value;
2193
2218
  const catchall = def.catchall;
@@ -2195,7 +2220,7 @@ const $ZodObjectJIT = /*@__PURE__*/ $constructor("$ZodObjectJIT", (inst, def) =>
2195
2220
  inst._zod.parse = (payload, ctx) => {
2196
2221
  value ?? (value = _normalized.value);
2197
2222
  const input = payload.value;
2198
- if (!isObject$1(input)) {
2223
+ if (!isObject$2(input)) {
2199
2224
  payload.issues.push({
2200
2225
  expected: "object",
2201
2226
  code: "invalid_type",
@@ -2963,8 +2988,7 @@ function handleRefineResult(result, payload, input, inst) {
2963
2988
  payload.issues.push(issue(_iss));
2964
2989
  }
2965
2990
  }
2966
- //#endregion
2967
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/memoizer.js
2991
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/memoizer.js
2968
2992
  var $ZodCyclicError = class extends Error {
2969
2993
  constructor() {
2970
2994
  super(`Cannot parse a reference cycle that closes through a transform`);
@@ -3216,8 +3240,7 @@ function isBackEdge(ctx, value) {
3216
3240
  const backEdges = ctx[STATE]?.backEdges;
3217
3241
  return backEdges !== void 0 && isRef(value) && backEdges.has(value);
3218
3242
  }
3219
- //#endregion
3220
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/locales/en.js
3243
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/locales/en.js
3221
3244
  const error = () => {
3222
3245
  const Sizable = {
3223
3246
  string: {
@@ -3324,8 +3347,7 @@ const error = () => {
3324
3347
  function en_default() {
3325
3348
  return { localeError: error() };
3326
3349
  }
3327
- //#endregion
3328
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/registries.js
3350
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/registries.js
3329
3351
  var _a;
3330
3352
  var $ZodRegistry = class {
3331
3353
  constructor() {
@@ -3371,8 +3393,7 @@ function registry() {
3371
3393
  }
3372
3394
  (_a = globalThis).__zod_globalRegistry ?? (_a.__zod_globalRegistry = registry());
3373
3395
  const globalRegistry = globalThis.__zod_globalRegistry;
3374
- //#endregion
3375
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/api.js
3396
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/api.js
3376
3397
  function snapshotChecks(def) {
3377
3398
  if (def.checks) def.checks = [...def.checks];
3378
3399
  return def;
@@ -3894,8 +3915,7 @@ function _check(fn, params) {
3894
3915
  ch._zod.check = fn;
3895
3916
  return ch;
3896
3917
  }
3897
- //#endregion
3898
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/to-json-schema.js
3918
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/to-json-schema.js
3899
3919
  function assignProps(target, ...sources) {
3900
3920
  for (const source of sources) for (const key of Reflect.ownKeys(source)) if (Object.prototype.propertyIsEnumerable.call(source, key)) assignProp(target, key, source[key]);
3901
3921
  return target;
@@ -4338,8 +4358,7 @@ const createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params)
4338
4358
  extractDefs(ctx, schema);
4339
4359
  return finalize(ctx, schema);
4340
4360
  };
4341
- //#endregion
4342
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/core/json-schema-processors.js
4361
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/core/json-schema-processors.js
4343
4362
  const narrowMin = (agg, key, value) => {
4344
4363
  if (agg[key] === void 0 || value > agg[key]) agg[key] = value;
4345
4364
  };
@@ -4984,8 +5003,7 @@ function toJSONSchema(input, params) {
4984
5003
  extractDefs(ctx, input);
4985
5004
  return finalize(ctx, input);
4986
5005
  }
4987
- //#endregion
4988
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/classic/errors.js
5006
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/classic/errors.js
4989
5007
  const _installedErrorProtos = /* @__PURE__ */ new WeakSet([Object.prototype, Error.prototype]);
4990
5008
  function _lazyMethod(proto, key, make) {
4991
5009
  Object.defineProperty(proto, key, {
@@ -5034,8 +5052,7 @@ const initializer = (inst, issues) => {
5034
5052
  });
5035
5053
  };
5036
5054
  const ZodRealError = /*@__PURE__*/ $constructor("ZodError", initializer, void 0, { Parent: Error });
5037
- //#endregion
5038
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/classic/parse.js
5055
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/classic/parse.js
5039
5056
  const parse = /* @__PURE__ */ _parse(ZodRealError);
5040
5057
  const parseAsync = /* @__PURE__ */ _parseAsync(ZodRealError);
5041
5058
  const safeParse = /* @__PURE__ */ _safeParse(ZodRealError);
@@ -5048,8 +5065,7 @@ const safeEncode = /* @__PURE__ */ _safeEncode(ZodRealError);
5048
5065
  const safeDecode = /* @__PURE__ */ _safeDecode(ZodRealError);
5049
5066
  const safeEncodeAsync = /* @__PURE__ */ _safeEncodeAsync(ZodRealError);
5050
5067
  const safeDecodeAsync = /* @__PURE__ */ _safeDecodeAsync(ZodRealError);
5051
- //#endregion
5052
- //#region ../../node_modules/.pnpm/zod@4.6.5/node_modules/zod/v4/classic/schemas.js
5068
+ // ../../node_modules/.pnpm/zod@4.6.7/node_modules/zod/v4/classic/schemas.js
5053
5069
  function _ensureDefaultLocale() {
5054
5070
  if (!globalConfig.localeError) config(en_default());
5055
5071
  }
@@ -6013,5 +6029,4 @@ function json(params) {
6013
6029
  });
6014
6030
  return jsonSchema;
6015
6031
  }
6016
- //#endregion
6017
6032
  export { _isoDateTime as S, union as _, array as a, uuid as b, discriminatedUnion as c, literal as d, number as f, tuple as g, string as h, _undefined as i, json as l, record as m, _enum as n, base64 as o, object as p, _null as r, boolean as s, ZodISODateTime as t, lazy as u, unknown as v, toJSONSchema as x, url as y };
@@ -1,5 +1,6 @@
1
- import { C as error, D as json, E as handleHttp, M as truncateText, O as jsonRequested, T as formatLocalDateTime, j as table, st as isUuid, t as createClient } from "./client.js";
2
- //#region src/commands/search.ts
1
+ import { p as isUuid } from "./app-realtime.js";
2
+ import { C as error, D as json, E as handleHttp, M as truncateText, O as jsonRequested, T as formatLocalDateTime, j as table, t as createClient } from "./client.js";
3
+ // src/commands/search.ts
3
4
  const DEFAULT_LIMIT = 20;
4
5
  const MAX_TITLE_LENGTH = 72;
5
6
  const MAX_CONTEXT_LENGTH = 42;
@@ -109,5 +110,4 @@ Examples:
109
110
  }
110
111
  });
111
112
  }
112
- //#endregion
113
113
  export { registerSearch };
@@ -4,7 +4,7 @@ import { spawn } from "node:child_process";
4
4
  import { constants, homedir, setPriority } from "node:os";
5
5
  import { mkdirSync, readFileSync, rmSync, statSync, writeFileSync } from "node:fs";
6
6
  import { join } from "node:path";
7
- //#region src/self-update.ts
7
+ // src/self-update.ts
8
8
  const PACKAGE_NAME = "@neta-art/cohub-cli";
9
9
  const SELF_UPDATE_WORKER_ENV = "COHUB_CLI_SELF_UPDATE_WORKER";
10
10
  const DEFAULT_INTERVAL_MS = 216e5;
@@ -127,7 +127,7 @@ const claim = () => {
127
127
  return false;
128
128
  }
129
129
  };
130
- const release$1 = () => rmSync(CLAIM_PATH, {
130
+ const release = () => rmSync(CLAIM_PATH, {
131
131
  recursive: true,
132
132
  force: true
133
133
  });
@@ -187,7 +187,7 @@ function startCliSelfUpdate(entrypoint) {
187
187
  writeFileSync(CLAIM_PID_PATH, String(worker.pid));
188
188
  } catch {
189
189
  worker?.kill();
190
- release$1();
190
+ release();
191
191
  }
192
192
  }
193
193
  async function runCliSelfUpdate() {
@@ -231,8 +231,7 @@ async function runCliSelfUpdate() {
231
231
  });
232
232
  }
233
233
  } finally {
234
- if (claimHolder() === process.pid) release$1();
234
+ if (claimHolder() === process.pid) release();
235
235
  }
236
236
  }
237
- //#endregion
238
237
  export { startCliSelfUpdate as i, isNewerVersion as n, runCliSelfUpdate as r, SELF_UPDATE_WORKER_ENV as t };