@moxt-ai/mobius 0.0.348 → 0.0.349

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js CHANGED
@@ -2086,7 +2086,7 @@ var init_package = __esm({
2086
2086
  "package.json"() {
2087
2087
  package_default = {
2088
2088
  name: "@moxt-ai/mobius",
2089
- version: "0.0.348",
2089
+ version: "0.0.349",
2090
2090
  description: "Mobius CLI for pairing and running local AI agent services.",
2091
2091
  type: "module",
2092
2092
  bin: {
@@ -95435,11 +95435,11 @@ var init_execution_receipts = __esm({
95435
95435
  }
95436
95436
  }
95437
95437
  }
95438
- #save = (commandId, receipt) => {
95438
+ #save = (commandId, receipt, liveOutcome = receipt.outcome) => {
95439
95439
  const evicted = this.#closing ? [] : this.#table.save({ ...receipt, commandId, updatedAt: (/* @__PURE__ */ new Date()).toISOString() }, MAX_TERMINAL_RECEIPTS);
95440
95440
  const previous = this.#executions.get(commandId);
95441
95441
  const wasActive = previous?.outcome === null;
95442
- this.#executions.set(commandId, receipt);
95442
+ this.#executions.set(commandId, { ...receipt, outcome: liveOutcome });
95443
95443
  for (const evictedCommandId of evicted) {
95444
95444
  this.#executions.delete(evictedCommandId);
95445
95445
  this.#recoveredCommands.delete(evictedCommandId);
@@ -95556,10 +95556,12 @@ var init_execution_receipts = __esm({
95556
95556
  return;
95557
95557
  }
95558
95558
  const sanitized = payload.kind === "prompt.completed" ? payload : { ...payload, message: "The local Agent could not complete the request" };
95559
- this.#save(payload.commandId, {
95560
- ...receipt,
95561
- outcome: JSON.stringify({ type: "lifecycle-metadata", payload: sanitized, recordedAt: event.recordedAt })
95562
- });
95559
+ const outcome = { type: "lifecycle-metadata", payload, recordedAt: event.recordedAt };
95560
+ this.#save(
95561
+ payload.commandId,
95562
+ { ...receipt, outcome: JSON.stringify({ ...outcome, payload: sanitized }) },
95563
+ JSON.stringify(outcome)
95564
+ );
95563
95565
  };
95564
95566
  recover = () => {
95565
95567
  const recovered = [];