@moxxy/cli 0.32.0 → 0.33.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 (2) hide show
  1. package/dist/bin.js +125 -43
  2. package/package.json +2 -2
package/dist/bin.js CHANGED
@@ -55143,6 +55143,7 @@ function createFoldState(compactByName = EMPTY_COMPACT_MAP) {
55143
55143
  compactByName,
55144
55144
  callTargets: /* @__PURE__ */ new Map(),
55145
55145
  suppressedCallIds: /* @__PURE__ */ new Set(),
55146
+ suppressedSkillScopes: /* @__PURE__ */ new Map(),
55146
55147
  pendingLoadSkillCallId: null,
55147
55148
  openScope: null,
55148
55149
  continuationSkillEvent: null,
@@ -55170,6 +55171,7 @@ function stepFold(s2, e3) {
55170
55171
  const closeOpenScope = () => {
55171
55172
  closeOpenLive();
55172
55173
  if (s2.openScope) {
55174
+ s2.openScope.loading = false;
55173
55175
  s2.openScope.closed = true;
55174
55176
  s2.openScope = null;
55175
55177
  }
@@ -55208,6 +55210,7 @@ function stepFold(s2, e3) {
55208
55210
  s2.pendingLoadSkillCallId = null;
55209
55211
  s2.continuationSkillEvent = null;
55210
55212
  s2.suppressedCallIds.clear();
55213
+ s2.suppressedSkillScopes.clear();
55211
55214
  s2.subagentGroup.current = null;
55212
55215
  s2.subagents.clear();
55213
55216
  s2.collab.current = null;
@@ -55217,9 +55220,10 @@ function stepFold(s2, e3) {
55217
55220
  if (e3.type === "skill_invoked") {
55218
55221
  closeOpenScope();
55219
55222
  s2.continuationSkillEvent = null;
55220
- if (s2.pendingLoadSkillCallId) {
55221
- s2.suppressedCallIds.add(s2.pendingLoadSkillCallId);
55222
- removeBlockByCallId(s2.pendingLoadSkillCallId);
55223
+ const loadCallId = s2.pendingLoadSkillCallId;
55224
+ if (loadCallId) {
55225
+ s2.suppressedCallIds.add(loadCallId);
55226
+ removeBlockByCallId(loadCallId);
55223
55227
  s2.pendingLoadSkillCallId = null;
55224
55228
  }
55225
55229
  s2.subagentGroup.current = null;
@@ -55228,8 +55232,11 @@ function stepFold(s2, e3) {
55228
55232
  id: e3.id,
55229
55233
  skillEvent: e3,
55230
55234
  children: [],
55235
+ loading: loadCallId !== null,
55231
55236
  closed: false
55232
55237
  };
55238
+ if (loadCallId)
55239
+ s2.suppressedSkillScopes.set(loadCallId, s2.openScope);
55233
55240
  s2.root.push(s2.openScope);
55234
55241
  return;
55235
55242
  }
@@ -55243,6 +55250,7 @@ function stepFold(s2, e3) {
55243
55250
  id: `${s2.continuationSkillEvent.id}:cont:${e3.id}`,
55244
55251
  skillEvent: s2.continuationSkillEvent,
55245
55252
  children: [],
55253
+ loading: false,
55246
55254
  closed: false
55247
55255
  };
55248
55256
  s2.root.push(s2.openScope);
@@ -55271,8 +55279,13 @@ function stepFold(s2, e3) {
55271
55279
  return;
55272
55280
  }
55273
55281
  if (e3.type === "tool_result") {
55274
- if (s2.suppressedCallIds.has(e3.callId))
55282
+ if (s2.suppressedCallIds.has(e3.callId)) {
55283
+ const scope = s2.suppressedSkillScopes.get(e3.callId);
55284
+ if (scope)
55285
+ scope.loading = false;
55286
+ s2.suppressedSkillScopes.delete(e3.callId);
55275
55287
  return;
55288
+ }
55276
55289
  const target = s2.callTargets.get(e3.callId);
55277
55290
  if (target) {
55278
55291
  target.outcome = e3;
@@ -55280,8 +55293,13 @@ function stepFold(s2, e3) {
55280
55293
  }
55281
55294
  }
55282
55295
  if (e3.type === "tool_call_denied") {
55283
- if (s2.suppressedCallIds.has(e3.callId))
55296
+ if (s2.suppressedCallIds.has(e3.callId)) {
55297
+ const scope = s2.suppressedSkillScopes.get(e3.callId);
55298
+ if (scope)
55299
+ scope.loading = false;
55300
+ s2.suppressedSkillScopes.delete(e3.callId);
55284
55301
  return;
55302
+ }
55285
55303
  const target = s2.callTargets.get(e3.callId);
55286
55304
  if (target) {
55287
55305
  target.outcome = { type: "denied", reason: e3.reason };
@@ -55388,6 +55406,8 @@ function blocksEquivalent(a2, b3) {
55388
55406
  return true;
55389
55407
  }
55390
55408
  if (a2.kind === "skill-scope" && b3.kind === "skill-scope") {
55409
+ if (a2.loading !== b3.loading)
55410
+ return false;
55391
55411
  if (a2.closed !== b3.closed)
55392
55412
  return false;
55393
55413
  if (a2.children.length !== b3.children.length)
@@ -55964,6 +55984,9 @@ var init_AssistantBlock = __esm({
55964
55984
  });
55965
55985
 
55966
55986
  // ../plugin-cli/dist/components/chat/EventLine.js
55987
+ function formatTriggerOrigin(origin) {
55988
+ return TRIGGER_VERBS[origin.kind];
55989
+ }
55967
55990
  function collapseBlankLines(text) {
55968
55991
  return text.replace(/\n[ \t]*\n+/g, "\n").replace(/^\s+|\s+$/g, "");
55969
55992
  }
@@ -55990,7 +56013,7 @@ function trimFixed(value) {
55990
56013
  function plural(count, noun) {
55991
56014
  return count === 1 ? noun : `${noun}s`;
55992
56015
  }
55993
- var import_jsx_runtime12, EventLine;
56016
+ var import_jsx_runtime12, EventLine, TRIGGER_VERBS;
55994
56017
  var init_EventLine = __esm({
55995
56018
  async "../plugin-cli/dist/components/chat/EventLine.js"() {
55996
56019
  import_jsx_runtime12 = __toESM(require_jsx_runtime());
@@ -56002,6 +56025,9 @@ var init_EventLine = __esm({
56002
56025
  EventLine = ({ event, expandToolOutputs }) => {
56003
56026
  switch (event.type) {
56004
56027
  case "user_prompt":
56028
+ if (event.origin) {
56029
+ return (0, import_jsx_runtime12.jsxs)(Box_default, { flexDirection: "column", marginTop: 1, children: [(0, import_jsx_runtime12.jsxs)(Box_default, { children: [(0, import_jsx_runtime12.jsx)(Text, { dimColor: true, children: `${Glyphs.filled} ${formatTriggerOrigin(event.origin)} \xB7 ` }), (0, import_jsx_runtime12.jsx)(Text, { children: event.origin.name }), !expandToolOutputs ? (0, import_jsx_runtime12.jsx)(Text, { dimColor: true, children: " \u203A" }) : null] }), expandToolOutputs ? (0, import_jsx_runtime12.jsx)(Box_default, { marginLeft: 2, children: (0, import_jsx_runtime12.jsx)(Text, { dimColor: true, children: event.text }) }) : null] });
56030
+ }
56005
56031
  if (event.source && event.source !== "user") {
56006
56032
  return (0, import_jsx_runtime12.jsx)(Box_default, { marginTop: 1, children: (0, import_jsx_runtime12.jsx)(Text, { dimColor: true, children: `${Glyphs.midDot} ${event.text}` }) });
56007
56033
  }
@@ -56035,6 +56061,12 @@ var init_EventLine = __esm({
56035
56061
  return null;
56036
56062
  }
56037
56063
  };
56064
+ TRIGGER_VERBS = {
56065
+ webhook: "Webhook received",
56066
+ schedule: "Schedule fired",
56067
+ workflow: "Workflow ran",
56068
+ checkpoint: "Checkpoint intervened"
56069
+ };
56038
56070
  }
56039
56071
  });
56040
56072
  var import_jsx_runtime13, COLLAPSED_ROWS, ADD_BG, DEL_BG, DiffRowLine, FileDiffView;
@@ -56147,7 +56179,7 @@ var init_ToolCallBlock = __esm({
56147
56179
  await init_FileDiffView();
56148
56180
  await init_ShimmerText();
56149
56181
  NAME_DISPLAY_MAX = 48;
56150
- ToolCallBlock = ({ request, outcome, expanded = false }) => {
56182
+ ToolCallBlock = ({ request, outcome, expanded = false, nested = false }) => {
56151
56183
  if (isFileDiffResult(outcome)) {
56152
56184
  const display = outcome.output.display;
56153
56185
  if (isFileDiffDisplay(display)) {
@@ -56156,7 +56188,7 @@ var init_ToolCallBlock = __esm({
56156
56188
  }
56157
56189
  const status = outcome === null ? "pending" : outcome.type === "denied" ? "err" : outcome.ok ? "ok" : "err";
56158
56190
  const detail = truncate3(formatToolActivity(request.name, request.input, status === "pending"), NAME_DISPLAY_MAX + 70);
56159
- return (0, import_jsx_runtime15.jsxs)(Box_default, { flexDirection: "column", marginTop: 1, children: [(0, import_jsx_runtime15.jsxs)(Box_default, { children: [(0, import_jsx_runtime15.jsxs)(Text, { color: status === "err" ? Colors.danger : void 0, dimColor: status !== "err", children: [status === "err" ? "\u2717" : toolGlyph(request.name), " "] }), (0, import_jsx_runtime15.jsx)(ShimmerText, { text: detail, active: status === "pending" }), status === "err" ? (0, import_jsx_runtime15.jsx)(Text, { color: Colors.danger, children: " failed" }) : null] }), outcome && (expanded || status === "err") ? (0, import_jsx_runtime15.jsxs)(Box_default, { children: [(0, import_jsx_runtime15.jsx)(Text, { dimColor: true, children: " \u2514 " }), (0, import_jsx_runtime15.jsx)(OutcomeText, { outcome })] }) : null] });
56191
+ return (0, import_jsx_runtime15.jsxs)(Box_default, { flexDirection: "column", marginTop: nested ? 0 : 1, children: [(0, import_jsx_runtime15.jsxs)(Box_default, { children: [nested ? (0, import_jsx_runtime15.jsx)(Text, { dimColor: true, children: "\u2514 " }) : null, (0, import_jsx_runtime15.jsxs)(Text, { color: status === "err" ? Colors.danger : status === "ok" ? Colors.active : void 0, dimColor: status === "pending", children: [status === "err" ? "\u2717" : status === "ok" ? "\u2713" : toolGlyph(request.name), " "] }), (0, import_jsx_runtime15.jsx)(ShimmerText, { text: detail, active: status === "pending" }), status === "err" ? (0, import_jsx_runtime15.jsx)(Text, { color: Colors.danger, children: " failed" }) : null] }), outcome && (expanded || status === "err") ? (0, import_jsx_runtime15.jsxs)(Box_default, { marginLeft: nested ? 2 : 0, children: [(0, import_jsx_runtime15.jsx)(Text, { dimColor: true, children: nested ? " " : " \u2514 " }), (0, import_jsx_runtime15.jsx)(OutcomeText, { outcome })] }) : null] });
56160
56192
  };
56161
56193
  OutcomeText = ({ outcome }) => {
56162
56194
  if (outcome.type === "denied") {
@@ -56182,8 +56214,8 @@ var init_LiveToolBlock = __esm({
56182
56214
  await init_ToolCallBlock();
56183
56215
  await init_ShimmerText();
56184
56216
  init_dist7();
56185
- LiveToolBlock = ({ block, expanded }) => {
56186
- const inFlight = !block.closed || block.calls.some((call) => call.outcome === null);
56217
+ LiveToolBlock = ({ block, expanded, nested = false }) => {
56218
+ const inFlight = block.calls.some((call) => call.outcome === null);
56187
56219
  const showDetails = expanded || inFlight;
56188
56220
  const summary = buildCompactSummary(block.calls, inFlight);
56189
56221
  const latest = block.calls[block.calls.length - 1];
@@ -56195,7 +56227,7 @@ var init_LiveToolBlock = __esm({
56195
56227
  return n2 + 1;
56196
56228
  return n2 + (o2.ok ? 0 : 1);
56197
56229
  }, 0);
56198
- return (0, import_jsx_runtime16.jsxs)(Box_default, { flexDirection: "column", marginTop: 1, children: [(0, import_jsx_runtime16.jsxs)(Box_default, { children: [(0, import_jsx_runtime16.jsxs)(Text, { dimColor: true, children: [latest ? toolGlyph(latest.request.name) : Glyphs.pending, " "] }), (0, import_jsx_runtime16.jsx)(ShimmerText, { text: summary, active: inFlight }), !showDetails ? (0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: " \u203A" }) : null] }), errorCount > 0 && !showDetails ? (0, import_jsx_runtime16.jsx)(Box_default, { marginLeft: 2, children: (0, import_jsx_runtime16.jsxs)(Text, { color: Colors.danger, children: [errorCount, " ", errorCount === 1 ? "call" : "calls", " failed \u2014 press ctrl+o for detail"] }) }) : null, !showDetails && latest ? (0, import_jsx_runtime16.jsxs)(Box_default, { marginLeft: 2, children: [(0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: "\u2514 " }), (0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: compactPreviewLine(latest) })] }) : null, showDetails ? (0, import_jsx_runtime16.jsx)(Box_default, { flexDirection: "column", marginLeft: 2, children: block.calls.map((c2) => (0, import_jsx_runtime16.jsx)(ToolCallBlock, { request: c2.request, outcome: c2.outcome }, c2.id)) }) : null] });
56230
+ return (0, import_jsx_runtime16.jsxs)(Box_default, { flexDirection: "column", marginTop: nested ? 0 : 1, children: [(0, import_jsx_runtime16.jsxs)(Box_default, { children: [nested ? (0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: "\u2514 " }) : null, (0, import_jsx_runtime16.jsxs)(Text, { dimColor: true, children: [latest ? toolGlyph(latest.request.name) : Glyphs.pending, " "] }), (0, import_jsx_runtime16.jsx)(ShimmerText, { text: summary, active: inFlight }), !showDetails ? (0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: " \u203A" }) : null] }), errorCount > 0 && !showDetails ? (0, import_jsx_runtime16.jsx)(Box_default, { marginLeft: 2, children: (0, import_jsx_runtime16.jsxs)(Text, { color: Colors.danger, children: [errorCount, " ", errorCount === 1 ? "call" : "calls", " failed \u2014 press ctrl+o for detail"] }) }) : null, !showDetails && latest ? (0, import_jsx_runtime16.jsxs)(Box_default, { marginLeft: 2, children: [(0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: "\u2514 " }), (0, import_jsx_runtime16.jsx)(Text, { dimColor: true, children: compactPreviewLine(latest) })] }) : null, showDetails ? (0, import_jsx_runtime16.jsx)(Box_default, { flexDirection: "column", marginLeft: 2, children: block.calls.map((c2) => (0, import_jsx_runtime16.jsx)(ToolCallBlock, { request: c2.request, outcome: c2.outcome, nested: true }, c2.id)) }) : null] });
56199
56231
  };
56200
56232
  }
56201
56233
  });
@@ -56304,6 +56336,17 @@ var init_CollabScopeView = __esm({
56304
56336
  });
56305
56337
 
56306
56338
  // ../plugin-cli/dist/components/chat/BlockLine.js
56339
+ function skillActivityPresentation(scope, childToolCount = countToolCalls(scope.children)) {
56340
+ const name = truncate3(scope.skillEvent.name, NAME_DISPLAY_MAX2);
56341
+ const meta = childToolCount > 0 ? `${childToolCount} tool${childToolCount === 1 ? "" : "s"}` : null;
56342
+ if (scope.loading)
56343
+ return { label: `Loading skill ${name}\u2026`, meta, active: true };
56344
+ if (scope.closed)
56345
+ return { label: `Used skill ${name}`, meta, active: false };
56346
+ if (childToolCount > 0)
56347
+ return { label: `Using skill ${name}`, meta, active: false };
56348
+ return { label: `Loaded skill ${name}`, meta: null, active: false };
56349
+ }
56307
56350
  function hasRunningTool(block) {
56308
56351
  if (block.kind === "tool-call")
56309
56352
  return block.outcome === null;
@@ -56329,11 +56372,11 @@ var init_BlockLine = __esm({
56329
56372
  init_dist7();
56330
56373
  NAME_DISPLAY_MAX2 = 48;
56331
56374
  BlockLine = (0, import_react41.memo)(
56332
- function BlockLine2({ block, expandToolOutputs }) {
56375
+ function BlockLine2({ block, expandToolOutputs, renderVersion, nested = false }) {
56333
56376
  if (block.kind === "event")
56334
56377
  return (0, import_jsx_runtime20.jsx)(EventLine, { event: block.event, expandToolOutputs });
56335
56378
  if (block.kind === "tool-call") {
56336
- return (0, import_jsx_runtime20.jsx)(ToolCallBlock, { request: block.request, outcome: block.outcome, expanded: expandToolOutputs });
56379
+ return (0, import_jsx_runtime20.jsx)(ToolCallBlock, { request: block.request, outcome: block.outcome, expanded: expandToolOutputs, nested });
56337
56380
  }
56338
56381
  if (block.kind === "subagent-group") {
56339
56382
  return (0, import_jsx_runtime20.jsx)(SubagentGroupView, { group: block, expandToolOutputs });
@@ -56342,12 +56385,12 @@ var init_BlockLine = __esm({
56342
56385
  return (0, import_jsx_runtime20.jsx)(SubagentScopeView, { scope: block });
56343
56386
  }
56344
56387
  if (block.kind === "live-tools") {
56345
- return (0, import_jsx_runtime20.jsx)(LiveToolBlock, { block, expanded: expandToolOutputs });
56388
+ return (0, import_jsx_runtime20.jsx)(LiveToolBlock, { block, expanded: expandToolOutputs, nested });
56346
56389
  }
56347
56390
  if (block.kind === "collab") {
56348
56391
  return (0, import_jsx_runtime20.jsx)(CollabScopeView, { scope: block });
56349
56392
  }
56350
- return (0, import_jsx_runtime20.jsx)(SkillScopeView, { scope: block, expandToolOutputs });
56393
+ return (0, import_jsx_runtime20.jsx)(SkillScopeView, { scope: block, expandToolOutputs, renderVersion });
56351
56394
  },
56352
56395
  // Blocks are mutated in-place by `pairToolEvents` (tool outcome
56353
56396
  // arrives, scope closes, subagent counter ticks). Compare the
@@ -56356,17 +56399,19 @@ var init_BlockLine = __esm({
56356
56399
  (prev, next) => {
56357
56400
  if (prev.expandToolOutputs !== next.expandToolOutputs)
56358
56401
  return false;
56402
+ if (prev.nested !== next.nested)
56403
+ return false;
56404
+ if (prev.renderVersion !== next.renderVersion)
56405
+ return false;
56359
56406
  return blocksEquivalent(prev.block, next.block);
56360
56407
  }
56361
56408
  );
56362
- SkillScopeView = ({ scope, expandToolOutputs }) => {
56409
+ SkillScopeView = ({ scope, expandToolOutputs, renderVersion }) => {
56363
56410
  const childToolCount = countToolCalls(scope.children);
56364
- const nameLabel = truncate3(scope.skillEvent.name, NAME_DISPLAY_MAX2);
56365
- const callLabel = `${childToolCount} tool call${childToolCount === 1 ? "" : "s"}`;
56366
- const active2 = !scope.closed || scope.children.some(hasRunningTool);
56367
- const showChildren = active2 || expandToolOutputs;
56368
- const label3 = `${active2 ? "Using" : "Used"} skill ${nameLabel}${active2 ? "\u2026" : ""}`;
56369
- return (0, import_jsx_runtime20.jsxs)(Box_default, { flexDirection: "column", marginTop: 1, children: [(0, import_jsx_runtime20.jsxs)(Box_default, { children: [(0, import_jsx_runtime20.jsx)(Text, { dimColor: true, children: "\u2726 " }), (0, import_jsx_runtime20.jsx)(ShimmerText, { text: label3, active: active2 }), (0, import_jsx_runtime20.jsx)(Text, { dimColor: true, children: ` \xB7 ${callLabel}${showChildren ? "" : " \u203A"}` })] }), showChildren ? (0, import_jsx_runtime20.jsx)(Box_default, { flexDirection: "column", marginLeft: 2, children: scope.children.map((c2) => (0, import_jsx_runtime20.jsx)(BlockLine, { block: c2, expandToolOutputs }, c2.id)) }) : null] });
56411
+ const presentation = skillActivityPresentation(scope, childToolCount);
56412
+ const runningTools = scope.children.some(hasRunningTool);
56413
+ const showChildren = !scope.closed || runningTools || expandToolOutputs;
56414
+ return (0, import_jsx_runtime20.jsxs)(Box_default, { flexDirection: "column", marginTop: 1, children: [(0, import_jsx_runtime20.jsxs)(Box_default, { children: [(0, import_jsx_runtime20.jsx)(Text, { dimColor: true, children: "\u2726 " }), (0, import_jsx_runtime20.jsx)(ShimmerText, { text: presentation.label, active: presentation.active }), presentation.meta ? (0, import_jsx_runtime20.jsx)(Text, { dimColor: true, children: ` \xB7 ${presentation.meta}` }) : null, !showChildren && childToolCount > 0 ? (0, import_jsx_runtime20.jsx)(Text, { dimColor: true, children: " \u203A" }) : null] }), showChildren ? (0, import_jsx_runtime20.jsx)(Box_default, { flexDirection: "column", marginLeft: 2, children: scope.children.map((c2) => (0, import_jsx_runtime20.jsx)(BlockLine, { block: c2, expandToolOutputs, renderVersion, nested: true }, c2.id)) }) : null] });
56370
56415
  };
56371
56416
  }
56372
56417
  });
@@ -56459,7 +56504,8 @@ var init_ChatView = __esm({
56459
56504
  settledRef.current = next;
56460
56505
  }
56461
56506
  const liveBlocks = blocks.slice(settledRef.current.length);
56462
- return (0, import_jsx_runtime22.jsxs)(import_jsx_runtime22.Fragment, { children: [(0, import_jsx_runtime22.jsx)(Static, { items: settledRef.current, children: (block) => (0, import_jsx_runtime22.jsx)(BlockLine, { block, expandToolOutputs: !!expandToolOutputs }, block.id) }, clearGenerationRef.current), hideLive ? null : (0, import_jsx_runtime22.jsxs)(Box_default, { flexDirection: "column", children: [liveBlocks.map((b3) => (0, import_jsx_runtime22.jsx)(BlockLine, { block: b3, expandToolOutputs: !!expandToolOutputs }, b3.id)), streamingDelta && streamingDelta.trim() ? (0, import_jsx_runtime22.jsx)(StreamingPreview, { content: tailForViewport(streamingDelta) }) : reasoningDelta && reasoningDelta.trim() ? (
56507
+ const renderVersion = foldRef.current?.version ?? events.length;
56508
+ return (0, import_jsx_runtime22.jsxs)(import_jsx_runtime22.Fragment, { children: [(0, import_jsx_runtime22.jsx)(Static, { items: settledRef.current, children: (block) => (0, import_jsx_runtime22.jsx)(BlockLine, { block, expandToolOutputs: !!expandToolOutputs, renderVersion }, block.id) }, clearGenerationRef.current), hideLive ? null : (0, import_jsx_runtime22.jsxs)(Box_default, { flexDirection: "column", children: [liveBlocks.map((b3) => (0, import_jsx_runtime22.jsx)(BlockLine, { block: b3, expandToolOutputs: !!expandToolOutputs, renderVersion }, b3.id)), streamingDelta && streamingDelta.trim() ? (0, import_jsx_runtime22.jsx)(StreamingPreview, { content: tailForViewport(streamingDelta) }) : reasoningDelta && reasoningDelta.trim() ? (
56463
56509
  // Dim live-thinking preview, only while there's no assistant text
56464
56510
  // yet. Prefix lands on the same single visual row as the content
56465
56511
  // tail, preserving StreamingPreview's no-stacking invariant.
@@ -95647,18 +95693,26 @@ function isVisibleSchedule(entry) {
95647
95693
  return entry.deletedAt === void 0;
95648
95694
  }
95649
95695
  var SCHEDULES_STORE_GLOB = "~/.moxxy/schedules.json*";
95650
- var cronOrTimestamp = z$1.object({
95651
- cron: z$1.string().optional(),
95652
- runAt: z$1.union([
95653
- z$1.number().int(),
95654
- z$1.string().refine((s2) => !Number.isNaN(Date.parse(s2)), {
95655
- message: "runAt must be an ISO timestamp or epoch-ms"
95656
- })
95657
- ]).optional(),
95658
- timeZone: z$1.string().optional()
95659
- }).refine((v3) => !!v3.cron || v3.runAt !== void 0, {
95696
+ var blankStringToUndefined = (value) => typeof value === "string" && value.trim() === "" ? void 0 : value;
95697
+ var optionalText = z$1.preprocess(blankStringToUndefined, z$1.string().min(1).optional());
95698
+ var optionalRunAt = z$1.preprocess(blankStringToUndefined, z$1.union([
95699
+ z$1.number().int(),
95700
+ z$1.string().refine((value) => !Number.isNaN(Date.parse(value)), {
95701
+ message: "runAt must be an ISO timestamp or epoch-ms"
95702
+ })
95703
+ ]).optional());
95704
+ var scheduleCreateInputSchema = z$1.object({
95705
+ name: z$1.string().min(1).max(120).regex(/^[a-z0-9][a-z0-9-]*$/i, "name must be slug-like (letters, digits, hyphens)"),
95706
+ prompt: z$1.string().min(1),
95707
+ channel: optionalText,
95708
+ model: optionalText,
95709
+ targetSessionId: optionalText.describe("Session id to fire this schedule in (where its run executes + displays). Defaults to the session that created the schedule."),
95710
+ cron: optionalText,
95711
+ runAt: optionalRunAt,
95712
+ timeZone: optionalText
95713
+ }).refine((value) => value.cron !== void 0 || value.runAt !== void 0, {
95660
95714
  message: "provide either `cron` or `runAt`"
95661
- }).refine((v3) => !(v3.cron && v3.runAt !== void 0), {
95715
+ }).refine((value) => !(value.cron !== void 0 && value.runAt !== void 0), {
95662
95716
  message: "provide either `cron` or `runAt`, not both"
95663
95717
  });
95664
95718
  function describeScheduleEntry(entry) {
@@ -95697,14 +95751,8 @@ function buildSchedulerTools(deps) {
95697
95751
  return [
95698
95752
  defineTool({
95699
95753
  name: "schedule_create",
95700
- description: "Create a scheduled prompt that fires on a cron (recurring) or a single timestamp (one-shot). The prompt runs in an isolated session at fire time; the final assistant message is appended to the user's inbox. Cron uses 5-field POSIX syntax in the user's local timezone (override via `timeZone`). For Telegram or other delivery, write the prompt to call the right send tool itself (e.g. \"...then call telegram_send_message with the summary\").",
95701
- inputSchema: z$1.object({
95702
- name: z$1.string().min(1).max(120).regex(/^[a-z0-9][a-z0-9-]*$/i, "name must be slug-like (letters, digits, hyphens)"),
95703
- prompt: z$1.string().min(1),
95704
- channel: z$1.string().optional(),
95705
- model: z$1.string().optional(),
95706
- targetSessionId: z$1.string().min(1).optional().describe("Session id to fire this schedule in (where its run executes + displays). Defaults to the session that created the schedule.")
95707
- }).and(cronOrTimestamp),
95754
+ description: "Create a scheduled prompt with exactly one trigger. For a recurring schedule, set `cron` and omit `runAt` entirely. For a one-shot schedule, set `runAt` and omit `cron` entirely. Never send an empty placeholder for the unused trigger. The prompt runs in an isolated session at fire time; the final assistant message is appended to the user's inbox. Cron uses 5-field POSIX syntax in the user's local timezone (override via `timeZone`). For Telegram or other delivery, write the prompt to call the right send tool itself (e.g. \"...then call telegram_send_message with the summary\").",
95755
+ inputSchema: scheduleCreateInputSchema,
95708
95756
  permission: { action: "prompt" },
95709
95757
  isolation: {
95710
95758
  capabilities: {
@@ -110136,6 +110184,23 @@ async function createWebSocketTransportServer(opts) {
110136
110184
  };
110137
110185
  }
110138
110186
 
110187
+ // ../desktop-ipc-contract/dist/focus-layout.js
110188
+ var FOCUS_PET_LAYOUT = Object.freeze({
110189
+ collapsedWidth: 84,
110190
+ collapsedHeight: 104,
110191
+ activeAvatarWidth: 72,
110192
+ activeHeight: 90,
110193
+ activeOverlap: 18
110194
+ });
110195
+ FOCUS_PET_LAYOUT.activeAvatarWidth - FOCUS_PET_LAYOUT.activeOverlap;
110196
+ Object.freeze({
110197
+ width: FOCUS_PET_LAYOUT.collapsedWidth + 36,
110198
+ height: FOCUS_PET_LAYOUT.collapsedHeight
110199
+ });
110200
+ Object.freeze({
110201
+ height: FOCUS_PET_LAYOUT.activeHeight + 36
110202
+ });
110203
+
110139
110204
  // ../desktop-ipc-contract/dist/remote.js
110140
110205
  var REMOTE_ALLOWED_COMMANDS = /* @__PURE__ */ new Set([
110141
110206
  // Answer a permission/approval prompt.
@@ -110220,6 +110285,9 @@ var skillName = z.string().min(1).max(200).regex(/^[A-Za-z0-9][A-Za-z0-9 ._/-]*$
110220
110285
  var vaultKeyName = z.string().min(1).max(200).regex(/^[A-Za-z0-9][A-Za-z0-9._/-]*$/, "invalid vault key name").refine((s2) => !s2.includes(".."), 'vault key name may not contain ".."');
110221
110286
  var optionalWorkspace = z.string().min(1).max(256).optional();
110222
110287
  var MAX_AUDIO_BASE64 = 4e7;
110288
+ var MAX_SYNTHESIZE_TEXT = 1e5;
110289
+ var speechLanguage = z.string().max(35).regex(/^[A-Za-z]{2,3}(?:-[A-Za-z0-9]{2,8})*$/, "must be a BCP-47 language tag");
110290
+ var speechRate = z.number().finite().min(0.5).max(2);
110223
110291
  var MAX_INLINE_ATTACHMENT_CONTENT = 12e6;
110224
110292
  var MAX_INLINE_ATTACHMENTS_TOTAL = 24e6;
110225
110293
  var BASE64_RE = /^[A-Za-z0-9+/]*={0,2}$/;
@@ -110261,6 +110329,12 @@ var ipcInputSchemas = {
110261
110329
  "app.relaunch": z.undefined(),
110262
110330
  "app.appBooted": z.undefined(),
110263
110331
  "app.updateDiagnostics": z.undefined(),
110332
+ // Optional offline voice installation spawns the CLI and changes the active
110333
+ // synthesizer. The host owns the exact package/name; renderer input is never
110334
+ // accepted, preventing package-spec / CLI-argument injection.
110335
+ "voice.isLocalPiperInstalled": z.undefined(),
110336
+ "voice.installLocalPiper": z.undefined(),
110337
+ "voice.setRealtimeCaptureActive": z.object({ active: z.boolean() }).strict(),
110264
110338
  // Renderer-reported confirm failure — bound the message so a hostile renderer
110265
110339
  // can't bloat the on-disk boot-log.
110266
110340
  "app.bootHeartbeatFailed": z.object({ error: z.string().max(2048) }),
@@ -110272,7 +110346,8 @@ var ipcInputSchemas = {
110272
110346
  "focus.resize": z.object({
110273
110347
  width: focusSize,
110274
110348
  height: focusSize,
110275
- resizable: z.boolean().optional()
110349
+ resizable: z.boolean().optional(),
110350
+ verticalAnchor: z.enum(["center", "bottom"]).optional()
110276
110351
  }).strict(),
110277
110352
  "onboarding.openExternal": z.object({ url: httpUrl }),
110278
110353
  "onboarding.saveProviderKey": z.object({
@@ -110296,6 +110371,12 @@ var ipcInputSchemas = {
110296
110371
  audioBase64: base64,
110297
110372
  mimeType: z.string().max(128).optional()
110298
110373
  }),
110374
+ "session.synthesize": z.object({
110375
+ workspaceId: optionalWorkspace,
110376
+ text: z.string().max(MAX_SYNTHESIZE_TEXT),
110377
+ language: speechLanguage.optional(),
110378
+ rate: speechRate.optional()
110379
+ }).strict(),
110299
110380
  // Read-only snapshots and the abort RPC are reachable over the remote (WS)
110300
110381
  // bridge — they carry free-form ids/workspaceId, so bound them like the
110301
110382
  // sibling validated commands so a hostile remote can't OOM/log-bloat the host
@@ -125330,6 +125411,7 @@ var ACTIVE_DEF_KINDS = [
125330
125411
  { key: "compactor", registry: (s2) => s2.compactors },
125331
125412
  { key: "cacheStrategy", registry: (s2) => s2.cacheStrategies },
125332
125413
  { key: "workflowExecutor", registry: (s2) => s2.workflowExecutors },
125414
+ { key: "synthesizer", registry: (s2) => s2.synthesizers },
125333
125415
  { key: "viewRenderer", registry: (s2) => s2.viewRenderers },
125334
125416
  { key: "tunnelProvider", registry: (s2) => s2.tunnelProviders },
125335
125417
  { key: "eventStore", registry: (s2) => s2.eventStores },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moxxy/cli",
3
- "version": "0.32.0",
3
+ "version": "0.33.0",
4
4
  "description": "moxxy command-line agent: TUI, one-shot prompts, setup, services, and API-key or installed-CLI subscription providers.",
5
5
  "keywords": [
6
6
  "moxxy",
@@ -47,7 +47,7 @@
47
47
  },
48
48
  "dependencies": {
49
49
  "zod": "^3.24.0",
50
- "@moxxy/sdk": "0.32.0"
50
+ "@moxxy/sdk": "0.33.0"
51
51
  },
52
52
  "optionalDependencies": {
53
53
  "@napi-rs/keyring": "^1.3.0"