chatroom-cli 1.75.0 → 1.76.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.
package/dist/index.js CHANGED
@@ -77540,8 +77540,11 @@ ${CODE_CHANGE_VERIFICATION_CONFIRMATION}
77540
77540
 
77541
77541
  ${getUnresolvedDecisionsSectionBlock()}
77542
77542
 
77543
- ## Notes / Next steps
77544
- <anything the user should know, follow-ups, or open questions>
77543
+ ## Notes
77544
+ <anything the user should know — context, caveats, or observations not covered above. Omit if none.>
77545
+
77546
+ ## Next steps
77547
+ <follow-up actions for the user or team. Omit if none.>
77545
77548
  \`\`\``;
77546
77549
  }
77547
77550
  var init_planner_to_user = __esm(() => {
@@ -77638,8 +77641,11 @@ ${CODE_CHANGE_VERIFICATION_CONFIRMATION}
77638
77641
 
77639
77642
  ${getUnresolvedDecisionsSectionBlock()}
77640
77643
 
77641
- ## Notes / Next steps
77642
- <anything the user should know, follow-ups, or open questions>
77644
+ ## Notes
77645
+ <anything the user should know — context, caveats, or observations not covered above. Omit if none.>
77646
+
77647
+ ## Next steps
77648
+ <follow-up actions for the user or team. Omit if none.>
77643
77649
  \`\`\``;
77644
77650
  }
77645
77651
  var init_solo_to_user = __esm(() => {
@@ -103343,7 +103349,6 @@ class BufferedJournalFactory {
103343
103349
  return;
103344
103350
  flushInProgress = true;
103345
103351
  const batch = buffer.splice(0);
103346
- console.log(`[journal] Flushing ${batch.length} chunks for session ${harnessSessionId}`);
103347
103352
  outputRepository.appendChunks(harnessSessionId, batch).catch((err) => {
103348
103353
  buffer.unshift(...batch);
103349
103354
  logger.warn(`[journal] Flush FAILED for ${harnessSessionId}: ${err instanceof Error ? err.message : String(err)}`);
@@ -103362,7 +103367,6 @@ class BufferedJournalFactory {
103362
103367
  messageId: chunk2.messageId,
103363
103368
  partType: chunk2.partType
103364
103369
  });
103365
- logger.log?.(`[journal] chunk recorded session=${harnessSessionId} messageId=${chunk2.messageId ?? "-"} partType=${chunk2.partType ?? "text"} bytes=${chunk2.content.length}`);
103366
103370
  },
103367
103371
  async flush() {
103368
103372
  await waitForInProgress();
@@ -103788,6 +103792,19 @@ var init_start_subscriptions2 = __esm(() => {
103788
103792
  // src/commands/machine/daemon-start/enhancer/constants.ts
103789
103793
  var ENHANCER_AGENT_ROLE = "enhancer";
103790
103794
 
103795
+ // src/commands/machine/daemon-start/enhancer/enhancer-log.ts
103796
+ function formatEnhancerLogLine(message) {
103797
+ const trimmed = message.trimEnd();
103798
+ if (trimmed.startsWith(ENHANCER_LOG_PREFIX))
103799
+ return trimmed;
103800
+ return `${ENHANCER_LOG_PREFIX} ${trimmed}`;
103801
+ }
103802
+ function writeEnhancerLog(message) {
103803
+ process.stdout.write(`${formatEnhancerLogLine(message)}
103804
+ `);
103805
+ }
103806
+ var ENHANCER_LOG_PREFIX = "[enhancer]";
103807
+
103791
103808
  // src/commands/machine/daemon-start/enhancer/job-subscriber.ts
103792
103809
  function startEnhancerJobSubscriber(sessionId, machineId, convexUrl, backend2, wsClient2, agentServices) {
103793
103810
  const inFlight = new Set;
@@ -103809,12 +103826,14 @@ function startEnhancerJobSubscriber(sessionId, machineId, convexUrl, backend2, w
103809
103826
  if (!claim.claimed)
103810
103827
  return;
103811
103828
  claimed = true;
103829
+ writeEnhancerLog(`claimed job=${job.jobId} chatroom=${job.chatroomId}`);
103812
103830
  const payload = await backend2.query(api.daemon.enhancer.index.getSpawnPayload, {
103813
103831
  sessionId,
103814
103832
  jobId: job.jobId
103815
103833
  });
103816
103834
  chatroomId = payload.chatroomId;
103817
103835
  jobId = payload.jobId;
103836
+ writeEnhancerLog(`spawning harness=${payload.agentHarness} model=${payload.model} job=${payload.jobId}`);
103818
103837
  const service3 = agentServices.get(payload.agentHarness);
103819
103838
  if (!service3) {
103820
103839
  await backend2.mutation(api.web.enhancer.index.recordAttemptFailure, {
@@ -103838,8 +103857,11 @@ function startEnhancerJobSubscriber(sessionId, machineId, convexUrl, backend2, w
103838
103857
  resolvedConvexUrl: convexUrl
103839
103858
  });
103840
103859
  spawnResult.onLogLine?.((line) => {
103841
- process.stdout.write(`${line}
103842
- `);
103860
+ writeEnhancerLog(line);
103861
+ });
103862
+ spawnResult.onAssistantText?.((text) => {
103863
+ if (text)
103864
+ writeEnhancerLog(`text] ${text}`);
103843
103865
  });
103844
103866
  await new Promise((resolve4) => {
103845
103867
  spawnResult.onExit(() => resolve4());
@@ -103849,6 +103871,9 @@ function startEnhancerJobSubscriber(sessionId, machineId, convexUrl, backend2, w
103849
103871
  chatroomId: payload.chatroomId,
103850
103872
  jobId: payload.jobId
103851
103873
  });
103874
+ if (status3?.status === "complete") {
103875
+ writeEnhancerLog(`completed job=${payload.jobId}`);
103876
+ }
103852
103877
  if (status3?.status === "running") {
103853
103878
  await backend2.mutation(api.web.enhancer.index.recordAttemptFailure, {
103854
103879
  sessionId,
@@ -103858,7 +103883,7 @@ function startEnhancerJobSubscriber(sessionId, machineId, convexUrl, backend2, w
103858
103883
  });
103859
103884
  }
103860
103885
  } catch (err) {
103861
- console.warn("[enhancer] spawn error:", err instanceof Error ? err.message : String(err));
103886
+ writeEnhancerLog(`error: ${err instanceof Error ? err.message : String(err)}`);
103862
103887
  if (claimed) {
103863
103888
  await backend2.mutation(api.web.enhancer.index.recordAttemptFailure, {
103864
103889
  sessionId,
@@ -116027,4 +116052,4 @@ program2.hook("preAction", async (_thisCommand, actionCommand) => {
116027
116052
  });
116028
116053
  program2.parse();
116029
116054
 
116030
- //# debugId=84E53044E3B850A464756E2164756E21
116055
+ //# debugId=7F5BB9A13B1C8A7564756E2164756E21