@moxt-ai/mobius 0.0.139 → 0.0.140

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/index.js CHANGED
@@ -34048,6 +34048,7 @@ var APPROVAL_TIMEOUT_MILLISECONDS2 = 36e5;
34048
34048
  var CODEX_AGENT_VERSION = "0.154.0";
34049
34049
  var SESSION_LIST_TIMEOUT_MILLISECONDS = 3e4;
34050
34050
  var CODEX_COMMANDS = Object.freeze([{ description: "Compact the conversation context", name: "compact" }]);
34051
+ var COMPACT_COMPLETED_MESSAGE = "Context compacted.";
34051
34052
  var APPROVAL_OPTIONS = Object.freeze([
34052
34053
  { kind: "allow_once", name: "Allow once", optionId: "accept" },
34053
34054
  { kind: "allow_always", name: "Allow for this session", optionId: "acceptForSession" },
@@ -34740,7 +34741,15 @@ var CodexAcpAgent = class {
34740
34741
  this.#turn = turn;
34741
34742
  try {
34742
34743
  await this.#appServer.request("thread/compact/start", { threadId: this.#nativeSessionId }, signal);
34743
- return await completion.promise;
34744
+ const result = await completion.promise;
34745
+ if (result.stopReason !== "cancelled") {
34746
+ await this.#emit({
34747
+ content: { text: COMPACT_COMPLETED_MESSAGE, type: "text" },
34748
+ messageId: turn.turn.id.length > 0 ? turn.turn.id : "compact-completed",
34749
+ sessionUpdate: "agent_message_chunk"
34750
+ });
34751
+ }
34752
+ return result;
34744
34753
  } finally {
34745
34754
  signal.removeEventListener("abort", aborted2);
34746
34755
  if (this.#turn === turn) {