adhdev 0.8.39 → 0.8.40

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
@@ -2856,7 +2856,7 @@ var init_chat_history = __esm({
2856
2856
  const lines = newMessages.map((m) => JSON.stringify(m)).join("\n") + "\n";
2857
2857
  fs3.appendFileSync(filePath, lines, "utf-8");
2858
2858
  const prevCount = this.lastSeenCounts.get(dedupKey) || 0;
2859
- if (messages.length < prevCount * 0.5 && prevCount > 3) {
2859
+ if (!historySessionId && messages.length < prevCount * 0.5 && prevCount > 3) {
2860
2860
  seenHashes.clear();
2861
2861
  this.lastSeenSignatures.delete(dedupKey);
2862
2862
  this.lastSeenTurnSignatures.delete(dedupKey);
@@ -5389,16 +5389,7 @@ async function handleSendChat(h, args) {
5389
5389
  const provider = h.getProvider(args?.agentType);
5390
5390
  const transport = getTargetTransport(h, provider);
5391
5391
  const dedupeKey = buildRecentSendKey(h, args, provider, text);
5392
- const historySessionId = getHistorySessionId(h, args);
5393
5392
  const _logSendSuccess = (method, targetAgent) => {
5394
- h.historyWriter.appendNewMessages(
5395
- targetAgent || provider?.type || getCurrentProviderType(h, "unknown_agent"),
5396
- [{ role: "user", content: text, receivedAt: Date.now() }],
5397
- void 0,
5398
- // title
5399
- args?.targetSessionId,
5400
- historySessionId
5401
- );
5402
5393
  return { success: true, sent: true, method, targetAgent };
5403
5394
  };
5404
5395
  if (isRecentDuplicateSend(dedupeKey)) {
@@ -49527,7 +49518,7 @@ var init_adhdev_daemon = __esm({
49527
49518
  import_ws3 = require("ws");
49528
49519
  import_chalk2 = __toESM(require("chalk"));
49529
49520
  init_version();
49530
- pkgVersion = resolvePackageVersion({ injectedVersion: "0.8.39" });
49521
+ pkgVersion = resolvePackageVersion({ injectedVersion: "0.8.40" });
49531
49522
  ACTIVE_CHAT_POLL_STATUSES = /* @__PURE__ */ new Set([
49532
49523
  "generating",
49533
49524
  "waiting_approval",