@askexenow/exe-os 0.9.153 → 0.9.154

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 (209) hide show
  1. package/dist/{active-agent-HDUT3T3I.js → active-agent-IVY5D7DJ.js} +2 -2
  2. package/dist/{active-agent-XHERKXH6.js → active-agent-JN7A2D2E.js} +2 -2
  3. package/dist/{agentic-ontology-GMK3MB3U.js → agentic-ontology-NU5FACOX.js} +1 -1
  4. package/dist/{backfill-metadata-PPI5QFYW.js → backfill-metadata-XBWBPBN2.js} +3 -3
  5. package/dist/{behaviors-JG75DNG3.js → behaviors-4USTCRU7.js} +2 -2
  6. package/dist/bin/agentic-ontology-backfill.js +4 -4
  7. package/dist/bin/agentic-reflection-backfill.js +5 -5
  8. package/dist/bin/agentic-semantic-label.js +4 -4
  9. package/dist/bin/backfill-conversations.js +3 -3
  10. package/dist/bin/backfill-responses.js +3 -3
  11. package/dist/bin/backfill-vectors.js +4 -4
  12. package/dist/bin/bulk-sync-postgres.js +5 -5
  13. package/dist/bin/cc-doctor.js +1 -1
  14. package/dist/bin/cleanup-stale-review-tasks.js +7 -7
  15. package/dist/bin/cli.js +12 -12
  16. package/dist/bin/exe-agent-config.js +1 -1
  17. package/dist/bin/exe-agent.js +7 -7
  18. package/dist/bin/exe-assign.js +4 -4
  19. package/dist/bin/exe-boot.js +14 -14
  20. package/dist/bin/exe-call.js +3 -3
  21. package/dist/bin/exe-cloud.js +3 -3
  22. package/dist/bin/exe-dispatch.js +7 -7
  23. package/dist/bin/exe-doctor.js +1 -1
  24. package/dist/bin/exe-export-behaviors.js +6 -6
  25. package/dist/bin/exe-forget.js +5 -5
  26. package/dist/bin/exe-gateway.js +5 -5
  27. package/dist/bin/exe-healthcheck.js +1 -1
  28. package/dist/bin/exe-heartbeat.js +7 -7
  29. package/dist/bin/exe-kill.js +10 -10
  30. package/dist/bin/exe-launch-agent.js +9 -9
  31. package/dist/bin/exe-new-employee.js +5 -5
  32. package/dist/bin/exe-pending-messages.js +8 -8
  33. package/dist/bin/exe-pending-notifications.js +7 -7
  34. package/dist/bin/exe-pending-reviews.js +7 -7
  35. package/dist/bin/exe-rename.js +3 -3
  36. package/dist/bin/exe-review.js +9 -9
  37. package/dist/bin/exe-search.js +4 -4
  38. package/dist/bin/exe-session-cleanup.js +13 -14
  39. package/dist/bin/exe-settings.js +3 -3
  40. package/dist/bin/exe-start-codex.js +10 -10
  41. package/dist/bin/exe-start-opencode.js +7 -7
  42. package/dist/bin/exe-status.js +8 -8
  43. package/dist/bin/exe-team.js +2 -2
  44. package/dist/bin/git-sweep.js +7 -7
  45. package/dist/bin/graph-backfill.js +3 -3
  46. package/dist/bin/graph-export.js +4 -4
  47. package/dist/bin/install.js +5 -5
  48. package/dist/bin/intercom-check.js +4 -4
  49. package/dist/bin/postgres-agentic-reflection-backfill.js +2 -2
  50. package/dist/bin/postgres-agentic-semantic-backfill.js +1 -1
  51. package/dist/bin/scan-tasks.js +7 -7
  52. package/dist/bin/setup.js +1 -1
  53. package/dist/bin/shard-migrate.js +3 -3
  54. package/dist/{capacity-monitor-5IVGAQ34.js → capacity-monitor-VJLRBE7S.js} +8 -8
  55. package/dist/{catchup-brief-HFJR32Q3.js → catchup-brief-T2RPTOTZ.js} +9 -9
  56. package/dist/{chunk-EYQ3DHHI.js → chunk-23H5ZURC.js} +8 -8
  57. package/dist/{chunk-5U5MI4VH.js → chunk-2BTXFKAV.js} +71 -72
  58. package/dist/{chunk-MBYJEE3B.js → chunk-2G2KOWBI.js} +12 -0
  59. package/dist/{chunk-WLSSSDAR.js → chunk-2GUTGEFX.js} +1 -1
  60. package/dist/{chunk-M37FGM3X.js → chunk-3CZBCOYI.js} +2 -2
  61. package/dist/{chunk-WZMS6X56.js → chunk-3I44JXWH.js} +2 -2
  62. package/dist/{chunk-5NSTNICM.js → chunk-3OGN523Z.js} +1 -1
  63. package/dist/{chunk-LIJC4CRF.js → chunk-3RJBXMWJ.js} +1 -1
  64. package/dist/{chunk-AMVDQ7HH.js → chunk-3S2HQUP6.js} +6 -6
  65. package/dist/{chunk-3ZU7RTMF.js → chunk-45APPAB2.js} +41 -28
  66. package/dist/{chunk-L5WTOR3T.js → chunk-5KUJDZ3J.js} +3 -3
  67. package/dist/{chunk-JUM3EUB2.js → chunk-66RYFM6Z.js} +5 -5
  68. package/dist/{chunk-4IEQIUBZ.js → chunk-6M65LFNM.js} +2 -2
  69. package/dist/{chunk-3TXOH3SJ.js → chunk-A7KEWR6S.js} +1 -1
  70. package/dist/{chunk-7WEVNBV2.js → chunk-ABVCJBON.js} +2 -2
  71. package/dist/{chunk-SFV2XRPY.js → chunk-AL7JZARP.js} +1 -1
  72. package/dist/{chunk-4RKL53PD.js → chunk-DMUNYW65.js} +25 -18
  73. package/dist/{chunk-CBLNQNWT.js → chunk-DTT4TRFR.js} +1 -1
  74. package/dist/{chunk-25NSQUZ3.js → chunk-DWLDYEGO.js} +6 -6
  75. package/dist/{chunk-MNIJA5BL.js → chunk-F2WGMIFZ.js} +1 -1
  76. package/dist/{chunk-SJKOILTX.js → chunk-G7IQNOSY.js} +1 -1
  77. package/dist/{chunk-EOU4ZLRZ.js → chunk-GCB4MHTG.js} +1 -1
  78. package/dist/{chunk-JJA6F6NA.js → chunk-HYRYMZRT.js} +1 -1
  79. package/dist/{chunk-LM7TQYLW.js → chunk-IWSXQKSB.js} +1 -1
  80. package/dist/{chunk-ODEGQCWW.js → chunk-K23KJITV.js} +3 -3
  81. package/dist/{chunk-BPBUSSYF.js → chunk-KSOPUPQX.js} +5 -5
  82. package/dist/{chunk-VJW3E5KW.js → chunk-KUPUTWQX.js} +5 -5
  83. package/dist/{chunk-OQYZQR24.js → chunk-L3JRSHHU.js} +2 -2
  84. package/dist/{chunk-PMCXWAVQ.js → chunk-LHMOPUZE.js} +2 -2
  85. package/dist/{chunk-UHL4QL5E.js → chunk-LVEOCWPL.js} +1 -1
  86. package/dist/{chunk-XQC5BNCJ.js → chunk-MLL5ICNL.js} +3 -3
  87. package/dist/{chunk-AFMQR776.js → chunk-NL4YO6I2.js} +1 -1
  88. package/dist/{chunk-4PDXCEXT.js → chunk-OC7Q4LOK.js} +16 -6
  89. package/dist/{chunk-UQE5R5PM.js → chunk-OHYMA6C3.js} +2 -2
  90. package/dist/{chunk-HZNQYDAN.js → chunk-OSPZOCPU.js} +3 -3
  91. package/dist/{chunk-PC6Y4ATU.js → chunk-PE6NCL7A.js} +1 -1
  92. package/dist/{chunk-GJMHN45Z.js → chunk-Q7TTJD4A.js} +1 -1
  93. package/dist/{chunk-RAMU6E5T.js → chunk-SE2DYYVB.js} +1 -1
  94. package/dist/{chunk-WPNWFI4A.js → chunk-SFZUC72J.js} +2 -2
  95. package/dist/{chunk-OEPEY47B.js → chunk-T2B7637C.js} +1 -1
  96. package/dist/{chunk-BR5UVRA2.js → chunk-TH2OFEQH.js} +1 -1
  97. package/dist/{chunk-ZGKU4PMY.js → chunk-TME75K53.js} +2 -2
  98. package/dist/{chunk-CF4DZKKE.js → chunk-UIAYIZNR.js} +2 -2
  99. package/dist/{chunk-BV2JVO2U.js → chunk-ULFBLCIP.js} +1 -1
  100. package/dist/{chunk-UPAEAL6K.js → chunk-UREIHGOQ.js} +3 -3
  101. package/dist/{chunk-Q7GVSS2J.js → chunk-VRKPBY6D.js} +1 -1
  102. package/dist/{chunk-IWGGTD5D.js → chunk-VZDPV32D.js} +3 -3
  103. package/dist/{chunk-RLCZBSUB.js → chunk-X347L57O.js} +12 -0
  104. package/dist/{chunk-CO2SF5SB.js → chunk-XEN5RMGU.js} +1 -1
  105. package/dist/{chunk-SGLVCPZP.js → chunk-XYFPCAA2.js} +1 -1
  106. package/dist/{chunk-YOH3ABTS.js → chunk-Y3Z6QHUR.js} +1 -1
  107. package/dist/{crdt-sync-3VQP2ISB.js → crdt-sync-B7IUR3BR.js} +1 -1
  108. package/dist/{crm-webhook-SOUYMO3X.js → crm-webhook-YU7PDS7U.js} +2 -2
  109. package/dist/{cto-delegation-gate-UGCMXYAO.js → cto-delegation-gate-JDDOHVQL.js} +6 -6
  110. package/dist/{daemon-orchestration-MD34RKQZ.js → daemon-orchestration-5OYKXYSR.js} +9 -9
  111. package/dist/{exe-drift-L5ZHO3CZ.js → exe-drift-DXRU4SXJ.js} +2 -2
  112. package/dist/{exe-export-UDQU7MMM.js → exe-export-X3AWJONG.js} +4 -4
  113. package/dist/{exe-import-OY42LQL4.js → exe-import-GC5HO3TD.js} +4 -4
  114. package/dist/{exe-key-FC67RNXI.js → exe-key-R3ER4MYY.js} +1 -1
  115. package/dist/{fast-db-init-TLOT2K43.js → fast-db-init-5DTYG5FZ.js} +1 -1
  116. package/dist/gateway/index.js +9 -9
  117. package/dist/{git-staleness-MSTOMG55.js → git-staleness-SVUTMS2F.js} +1 -1
  118. package/dist/{git-task-sweep-D4IKRGCV.js → git-task-sweep-EQHX4LXT.js} +7 -7
  119. package/dist/{global-procedures-ISPSC4B5.js → global-procedures-P7VOE476.js} +2 -2
  120. package/dist/{graph-auto-extract-D4I7DF2S.js → graph-auto-extract-UI374EYL.js} +1 -1
  121. package/dist/hooks/bug-report-worker.js +8 -8
  122. package/dist/hooks/codex-stop-task-finalizer.js +8 -8
  123. package/dist/hooks/commit-complete.js +9 -9
  124. package/dist/hooks/error-recall.js +5 -5
  125. package/dist/hooks/exe-heartbeat-hook.js +2 -2
  126. package/dist/hooks/ingest.js +5 -5
  127. package/dist/hooks/instructions-loaded.js +3 -3
  128. package/dist/hooks/notification.js +3 -3
  129. package/dist/hooks/post-compact.js +8 -8
  130. package/dist/hooks/post-tool-combined.js +4 -4
  131. package/dist/hooks/pre-compact.js +9 -9
  132. package/dist/hooks/pre-tool-use.js +34 -12
  133. package/dist/hooks/prompt-submit.js +16 -16
  134. package/dist/hooks/session-end.js +13 -13
  135. package/dist/hooks/session-start.js +7 -7
  136. package/dist/hooks/stop.js +12 -12
  137. package/dist/hooks/subagent-stop.js +8 -8
  138. package/dist/hooks/summary-worker.js +12 -12
  139. package/dist/index.js +16 -16
  140. package/dist/{installer-SPQDAGPW.js → installer-L72MRJPI.js} +4 -4
  141. package/dist/{installer-3YHQ5DJZ.js → installer-LX2TU7RS.js} +4 -4
  142. package/dist/{installer-4YIOBAFV.js → installer-SLJ3YCHB.js} +4 -4
  143. package/dist/lib/cloud-sync.js +3 -3
  144. package/dist/lib/consolidation.js +4 -4
  145. package/dist/lib/database.js +1 -1
  146. package/dist/lib/db.js +1 -1
  147. package/dist/lib/employee-templates.js +3 -3
  148. package/dist/lib/employees.js +1 -1
  149. package/dist/lib/exe-daemon.js +45 -20
  150. package/dist/lib/hybrid-search.js +4 -4
  151. package/dist/lib/identity.js +1 -1
  152. package/dist/lib/messaging.js +7 -7
  153. package/dist/lib/reminders.js +2 -2
  154. package/dist/lib/schedules.js +4 -4
  155. package/dist/lib/skill-learning.js +3 -3
  156. package/dist/lib/store.js +3 -3
  157. package/dist/lib/task-router.js +2 -2
  158. package/dist/lib/tasks.js +7 -7
  159. package/dist/lib/tmux-routing.js +6 -6
  160. package/dist/lib/tmux-transport.js +1 -1
  161. package/dist/lib/token-spend.js +2 -2
  162. package/dist/lib/transport.js +2 -2
  163. package/dist/mcp/register-tools.js +45 -45
  164. package/dist/mcp/server.js +46 -46
  165. package/dist/mcp/tools/complete-reminder.js +3 -3
  166. package/dist/mcp/tools/create-reminder.js +3 -3
  167. package/dist/mcp/tools/create-task.js +9 -9
  168. package/dist/mcp/tools/deactivate-behavior.js +4 -4
  169. package/dist/mcp/tools/list-reminders.js +3 -3
  170. package/dist/mcp/tools/list-tasks.js +9 -9
  171. package/dist/mcp/tools/send-message.js +9 -9
  172. package/dist/mcp/tools/update-task.js +8 -8
  173. package/dist/{mcp-http-config-JBNX3DAR.js → mcp-http-config-T76QB243.js} +2 -2
  174. package/dist/{memory-cards-SYVGSLXW.js → memory-cards-NTRYLVOU.js} +1 -1
  175. package/dist/{memory-poisoning-defense-T7AC4LZN.js → memory-poisoning-defense-OJ2DEGBA.js} +1 -1
  176. package/dist/{memory-reflection-FNJU7VFC.js → memory-reflection-4YOUTIMO.js} +1 -1
  177. package/dist/{notifications-76XXO4Q7.js → notifications-SF2XN5JE.js} +6 -6
  178. package/dist/{orchestrator-XAT2JSBT.js → orchestrator-2W3VNAKG.js} +8 -8
  179. package/dist/{plan-limits-IAUNTZUW.js → plan-limits-LEM76SOQ.js} +2 -2
  180. package/dist/{projection-worker-S6LYSY22.js → projection-worker-RQHV4VIR.js} +1 -1
  181. package/dist/{review-polling-E24XBNSI.js → review-polling-HD26LRW2.js} +7 -7
  182. package/dist/runtime/index.js +13 -13
  183. package/dist/{session-events-CCXFQRFW.js → session-events-NYMENC3B.js} +7 -7
  184. package/dist/{session-kill-telemetry-TX5NCPUV.js → session-kill-telemetry-LJU2MMZC.js} +2 -2
  185. package/dist/{session-scope-7QCZF3MJ.js → session-scope-QIDIKKFB.js} +6 -6
  186. package/dist/{setup-wizard-FA6YEYER.js → setup-wizard-ANL7CVWX.js} +1 -1
  187. package/dist/skill-refinement-3W3CIIG3.js +156 -0
  188. package/dist/{task-enforcement-NITY7TBM.js → task-enforcement-YXEOTTUG.js} +6 -6
  189. package/dist/{task-scope-YZDSPORL.js → task-scope-XXPTORGS.js} +6 -6
  190. package/dist/{tasks-crud-W5BFKNUS.js → tasks-crud-3UCNTXKQ.js} +6 -6
  191. package/dist/{tasks-review-VXMELVLA.js → tasks-review-IPOWGI4L.js} +6 -6
  192. package/dist/{token-budget-LJC7HHKB.js → token-budget-NP22DW2M.js} +1 -1
  193. package/dist/{tool-telemetry-L3WQDRMH.js → tool-telemetry-5JF2OAHG.js} +1 -1
  194. package/dist/tui/App.js +14 -14
  195. package/dist/{tui-data-FQYUPCYX.js → tui-data-Z7FCER3K.js} +6 -6
  196. package/dist/{worker-gate-OZCNSASA.js → worker-gate-PJYHXNUB.js} +1 -1
  197. package/dist/{workflow-engine-DA3AWD45.js → workflow-engine-GA7JS7X2.js} +2 -2
  198. package/package.json +1 -1
  199. package/release-notes.json +104 -104
  200. /package/dist/{chunk-UIOTTKLS.js → chunk-7E6ZBXO7.js} +0 -0
  201. /package/dist/{chunk-PJCTBGWN.js → chunk-7U664OM4.js} +0 -0
  202. /package/dist/{chunk-BRXDLJBU.js → chunk-LYMBXTEO.js} +0 -0
  203. /package/dist/{chunk-VN6UUZNO.js → chunk-NQND3GFO.js} +0 -0
  204. /package/dist/{chunk-OU7SLHNA.js → chunk-PBBIAKN5.js} +0 -0
  205. /package/dist/{chunk-U3B3TVLQ.js → chunk-UJ2KUF4C.js} +0 -0
  206. /package/dist/{chunk-YABPRFBT.js → chunk-Z6UYJ7HZ.js} +0 -0
  207. /package/dist/{chunk-YH7VB655.js → chunk-ZYETFCDX.js} +0 -0
  208. /package/dist/{core-memory-ONZIJYGR.js → core-memory-KL5BOUXU.js} +0 -0
  209. /package/dist/{wiki-acl-UE3CRAPQ.js → wiki-acl-ZRCU7XYC.js} +0 -0
@@ -1,10 +1,13 @@
1
+ import {
2
+ SlackAdapter
3
+ } from "./chunk-ORCCI2VV.js";
1
4
  import {
2
5
  IMessageAdapter
3
6
  } from "./chunk-FLSASUV3.js";
4
7
  import {
5
8
  createCRMWebhookHandler,
6
9
  parseTwentyWebhook
7
- } from "./chunk-AFMQR776.js";
10
+ } from "./chunk-NL4YO6I2.js";
8
11
  import {
9
12
  WhatsAppAdapter
10
13
  } from "./chunk-ECSNSHZ7.js";
@@ -17,9 +20,6 @@ import {
17
20
  import {
18
21
  DiscordAdapter
19
22
  } from "./chunk-N5RRQOAC.js";
20
- import {
21
- SlackAdapter
22
- } from "./chunk-ORCCI2VV.js";
23
23
  import {
24
24
  BotRegistry,
25
25
  BotRuntime,
@@ -42,7 +42,7 @@ import {
42
42
  retryWithBackoff,
43
43
  routeMessage,
44
44
  validateGatewayConfig
45
- } from "./chunk-UQE5R5PM.js";
45
+ } from "./chunk-OHYMA6C3.js";
46
46
  import {
47
47
  OllamaProvider
48
48
  } from "./chunk-FWFFZGSC.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  vectorToBlob
3
- } from "./chunk-25NSQUZ3.js";
3
+ } from "./chunk-DWLDYEGO.js";
4
4
  import {
5
5
  isCoordinatorName
6
- } from "./chunk-MBYJEE3B.js";
6
+ } from "./chunk-2G2KOWBI.js";
7
7
 
8
8
  // src/lib/consolidation.ts
9
9
  import { randomUUID } from "crypto";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  TmuxTransport
3
- } from "./chunk-RLCZBSUB.js";
3
+ } from "./chunk-X347L57O.js";
4
4
 
5
5
  // src/lib/transport.ts
6
6
  var _transport = null;
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-GNHN5HRQ.js";
4
4
  import {
5
5
  buildClaudeHttpMcpEntry
6
- } from "./chunk-SGLVCPZP.js";
6
+ } from "./chunk-XYFPCAA2.js";
7
7
  import {
8
8
  EXE_HOOKS,
9
9
  isLegacyHomeDirHookCommand,
@@ -11,7 +11,7 @@ import {
11
11
  } from "./chunk-L3TB7CC3.js";
12
12
  import {
13
13
  ensureAllAgentSymlinks
14
- } from "./chunk-LM7TQYLW.js";
14
+ } from "./chunk-IWSXQKSB.js";
15
15
  import {
16
16
  MCP_LEGACY_KEY,
17
17
  MCP_PRIMARY_KEY
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  createReminder
3
- } from "./chunk-Q7GVSS2J.js";
3
+ } from "./chunk-VRKPBY6D.js";
4
4
 
5
5
  // src/mcp/tools/create-reminder.ts
6
6
  import { z } from "zod";
@@ -1,21 +1,21 @@
1
1
  import {
2
2
  recordSessionKill
3
- } from "./chunk-CO2SF5SB.js";
3
+ } from "./chunk-XEN5RMGU.js";
4
4
  import {
5
5
  sessionScopeFilter,
6
6
  verifyPaneAtCapacity,
7
7
  writeNotification
8
- } from "./chunk-4PDXCEXT.js";
8
+ } from "./chunk-OC7Q4LOK.js";
9
9
  import {
10
10
  listSessions
11
11
  } from "./chunk-64WZEXXA.js";
12
12
  import {
13
13
  getTransport
14
- } from "./chunk-3TXOH3SJ.js";
14
+ } from "./chunk-A7KEWR6S.js";
15
15
  import {
16
16
  getClient,
17
17
  isCoordinatorName
18
- } from "./chunk-MBYJEE3B.js";
18
+ } from "./chunk-2G2KOWBI.js";
19
19
 
20
20
  // src/lib/capacity-monitor.ts
21
21
  var CAPACITY_PATTERNS = [
@@ -111,9 +111,9 @@ function _resetPendingCapacityKills() {
111
111
  function _resetLastRelaunchCache() {
112
112
  _lastRelaunch.clear();
113
113
  }
114
- async function lastResumeCreatedAtMs(agentId) {
114
+ async function lastResumeCreatedAtMs(agentId, sessionScope) {
115
115
  const client = getClient();
116
- const cmScope = sessionScopeFilter(null);
116
+ const cmScope = sessionScopeFilter(sessionScope ?? null);
117
117
  const result = await client.execute({
118
118
  sql: `SELECT MAX(created_at) AS last_created_at
119
119
  FROM tasks
@@ -125,20 +125,21 @@ async function lastResumeCreatedAtMs(agentId) {
125
125
  const parsed = Date.parse(String(raw));
126
126
  return Number.isNaN(parsed) ? null : parsed;
127
127
  }
128
- async function isWithinRelaunchCooldown(agentId, now = Date.now()) {
129
- const cached = _lastRelaunch.get(agentId);
128
+ async function isWithinRelaunchCooldown(agentId, now = Date.now(), sessionScope) {
129
+ const cacheKey = sessionScope ? `${agentId}::${sessionScope}` : agentId;
130
+ const cached = _lastRelaunch.get(cacheKey);
130
131
  if (cached !== void 0) return now - cached < RELAUNCH_COOLDOWN_MS;
131
- const persisted = await lastResumeCreatedAtMs(agentId);
132
+ const persisted = await lastResumeCreatedAtMs(agentId, sessionScope);
132
133
  if (persisted === null) return false;
133
134
  if (now - persisted >= RELAUNCH_COOLDOWN_MS) return false;
134
- _lastRelaunch.set(agentId, persisted);
135
+ _lastRelaunch.set(cacheKey, persisted);
135
136
  return true;
136
137
  }
137
- async function createOrRefreshResumeTask(agentId, projectDir, openTasks) {
138
+ async function createOrRefreshResumeTask(agentId, projectDir, openTasks, sessionScope) {
138
139
  const client = getClient();
139
140
  const now = (/* @__PURE__ */ new Date()).toISOString();
140
141
  const context = buildResumeContext(agentId, openTasks);
141
- const rdScope = sessionScopeFilter(null);
142
+ const rdScope = sessionScopeFilter(sessionScope ?? null);
142
143
  const existing = await client.execute({
143
144
  sql: `SELECT id FROM tasks
144
145
  WHERE assigned_to = ?
@@ -182,7 +183,9 @@ async function pollCapacityDead() {
182
183
  for (const entry of registered) {
183
184
  const { windowName, agentId, projectDir } = entry;
184
185
  if (!liveSessions.includes(windowName)) continue;
185
- if (await isWithinRelaunchCooldown(agentId)) continue;
186
+ const cmDashIdx = windowName.indexOf("-");
187
+ const cmDerivedScope = cmDashIdx >= 0 ? windowName.slice(cmDashIdx + 1) : null;
188
+ if (await isWithinRelaunchCooldown(agentId, Date.now(), cmDerivedScope)) continue;
186
189
  let pane;
187
190
  try {
188
191
  pane = transport.capturePane(windowName, 15);
@@ -246,7 +249,8 @@ async function pollCapacityDead() {
246
249
  }
247
250
  transport.kill(windowName);
248
251
  void recordSessionKill({ sessionName: windowName, agentId, reason: "capacity" });
249
- _lastRelaunch.set(agentId, Date.now());
252
+ const coordCacheKey = cmDerivedScope ? `${agentId}::${cmDerivedScope}` : agentId;
253
+ _lastRelaunch.set(coordCacheKey, Date.now());
250
254
  relaunched.push(agentId);
251
255
  } catch (err) {
252
256
  process.stderr.write(
@@ -264,8 +268,9 @@ async function pollCapacityDead() {
264
268
  reason: "capacity"
265
269
  });
266
270
  const client = getClient();
267
- const sessionScope = windowName.includes("-") ? windowName.slice(windowName.indexOf("-") + 1) : null;
268
- const rlScope = sessionScopeFilter(sessionScope);
271
+ const dashIdx = windowName.indexOf("-");
272
+ const derivedScope = dashIdx >= 0 ? windowName.slice(dashIdx + 1) : null;
273
+ const rlScope = sessionScopeFilter(derivedScope);
269
274
  const openTasks = await client.execute({
270
275
  sql: `SELECT id, title, priority, task_file, status
271
276
  FROM tasks
@@ -286,7 +291,8 @@ async function pollCapacityDead() {
286
291
  const { created } = await createOrRefreshResumeTask(
287
292
  agentId,
288
293
  projectDir,
289
- openTasks.rows
294
+ openTasks.rows,
295
+ derivedScope
290
296
  );
291
297
  if (created) {
292
298
  await writeNotification({
@@ -297,7 +303,8 @@ async function pollCapacityDead() {
297
303
  summary: `${agentId} hit context capacity. Auto-relaunched with ${openTasks.rows.length} open task(s).`
298
304
  });
299
305
  }
300
- _lastRelaunch.set(agentId, Date.now());
306
+ const cacheKey = derivedScope ? `${agentId}::${derivedScope}` : agentId;
307
+ _lastRelaunch.set(cacheKey, Date.now());
301
308
  if (created) relaunched.push(agentId);
302
309
  } catch (err) {
303
310
  process.stderr.write(
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  executeAction,
3
3
  substituteTemplate
4
- } from "./chunk-YH7VB655.js";
4
+ } from "./chunk-ZYETFCDX.js";
5
5
 
6
6
  // src/automation/workflow-engine.ts
7
7
  import { randomUUID } from "crypto";
@@ -2,7 +2,7 @@ import {
2
2
  findScopedDuplicate,
3
3
  governMemoryRecord,
4
4
  schedulePostWriteMemoryHygiene
5
- } from "./chunk-BRXDLJBU.js";
5
+ } from "./chunk-LYMBXTEO.js";
6
6
  import {
7
7
  orgBus
8
8
  } from "./chunk-MP2AFCGL.js";
@@ -11,7 +11,7 @@ import {
11
11
  ensureSchema,
12
12
  getClient,
13
13
  initTurso
14
- } from "./chunk-MBYJEE3B.js";
14
+ } from "./chunk-2G2KOWBI.js";
15
15
  import {
16
16
  EMBEDDING_DIM
17
17
  } from "./chunk-FXU7JOXK.js";
@@ -119,7 +119,7 @@ async function initStore(options) {
119
119
  );
120
120
  _nextVersion = (Number(vResult.rows[0]?.max_v) || 0) + 1;
121
121
  try {
122
- const { loadGlobalProcedures } = await import("./global-procedures-ISPSC4B5.js");
122
+ const { loadGlobalProcedures } = await import("./global-procedures-P7VOE476.js");
123
123
  await loadGlobalProcedures();
124
124
  } catch (e) {
125
125
  logStoreWarn("catch", e);
@@ -236,7 +236,7 @@ async function writeMemory(record) {
236
236
  procedure_for: record.procedure_for ?? null
237
237
  };
238
238
  try {
239
- const { checkMemoryPoisoning } = await import("./memory-poisoning-defense-T7AC4LZN.js");
239
+ const { checkMemoryPoisoning } = await import("./memory-poisoning-defense-OJ2DEGBA.js");
240
240
  const poisonResult = await checkMemoryPoisoning({
241
241
  memoryId: dbRow.id,
242
242
  vector: Array.isArray(dbRow.vector) ? dbRow.vector : void 0,
@@ -410,13 +410,13 @@ async function flushBatch() {
410
410
  }
411
411
  _nextVersion = baseVersion;
412
412
  try {
413
- const { insertMemoryCardsForBatch } = await import("./memory-cards-SYVGSLXW.js");
413
+ const { insertMemoryCardsForBatch } = await import("./memory-cards-NTRYLVOU.js");
414
414
  await insertMemoryCardsForBatch(batch);
415
415
  } catch (e) {
416
416
  logStoreWarn("catch", e);
417
417
  }
418
418
  try {
419
- const { insertOntologyForBatch } = await import("./agentic-ontology-GMK3MB3U.js");
419
+ const { insertOntologyForBatch } = await import("./agentic-ontology-NU5FACOX.js");
420
420
  await insertOntologyForBatch(batch);
421
421
  } catch (e) {
422
422
  logStoreWarn("catch", e);
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  clean,
3
3
  stableId
4
- } from "./chunk-OU7SLHNA.js";
4
+ } from "./chunk-PBBIAKN5.js";
5
5
 
6
6
  // src/lib/reflection-checkpoints.ts
7
7
  function parsePayload(payload) {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  getCurrentSessionScope,
3
3
  strictSessionScopeFilter
4
- } from "./chunk-4PDXCEXT.js";
4
+ } from "./chunk-OC7Q4LOK.js";
5
5
  import {
6
6
  getProjectName
7
7
  } from "./chunk-OPU3NYOO.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getClient
3
- } from "./chunk-MBYJEE3B.js";
3
+ } from "./chunk-2G2KOWBI.js";
4
4
 
5
5
  // src/lib/behaviors.ts
6
6
  import crypto from "crypto";
@@ -6,7 +6,7 @@ import {
6
6
  getIdentity,
7
7
  listIdentities,
8
8
  updateIdentity
9
- } from "./chunk-MBYJEE3B.js";
9
+ } from "./chunk-2G2KOWBI.js";
10
10
  import {
11
11
  atomicWriteJsonSync
12
12
  } from "./chunk-LYH5HE24.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  loadEmployees
3
- } from "./chunk-MBYJEE3B.js";
3
+ } from "./chunk-2G2KOWBI.js";
4
4
 
5
5
  // src/lib/agent-symlinks.ts
6
6
  import os from "os";
@@ -201,12 +201,12 @@ function checkMcpTransport() {
201
201
  detail: jsonRpcError ? "MCP HTTP endpoint reachable; missing-session probe returns JSON-RPC (expected)" : "MCP HTTP endpoint reachable but did not return expected JSON-RPC missing-session response"
202
202
  });
203
203
  } catch (err) {
204
- const detail = err instanceof Error ? err.message.slice(0, 180) : String(err);
205
- const isTimeout = detail.includes("ETIMEDOUT") || detail.includes("timed out") || detail.includes("killed");
204
+ const msg = err instanceof Error ? err.message.slice(0, 180) : String(err);
205
+ const timedOut = msg.includes("ETIMEDOUT") || msg.includes("timed out") || msg.includes("killed");
206
206
  results.push({
207
207
  name: "mcp/http-endpoint",
208
208
  pass: false,
209
- detail: isTimeout && daemonAlive ? "Daemon alive but MCP unresponsive (timeout) \u2014 may be under memory pressure" : `MCP HTTP endpoint not reachable: ${detail}`
209
+ detail: timedOut ? "Daemon alive but MCP unresponsive (timed out after 1.5s)" : `MCP HTTP endpoint not reachable: ${msg}`
210
210
  });
211
211
  }
212
212
  } else if (daemonAlive) {
@@ -3,10 +3,10 @@ import {
3
3
  buildRawVisibilityFilter,
4
4
  buildWikiScopeFilter,
5
5
  searchMemories
6
- } from "./chunk-25NSQUZ3.js";
6
+ } from "./chunk-DWLDYEGO.js";
7
7
  import {
8
8
  getClient
9
- } from "./chunk-MBYJEE3B.js";
9
+ } from "./chunk-2G2KOWBI.js";
10
10
 
11
11
  // src/lib/hybrid-search.ts
12
12
  var RRF_K = 60;
@@ -196,7 +196,7 @@ async function hybridSearch(queryText, agentId, options) {
196
196
  queryVector ? searchMemories(queryVector, agentId, fetchOptions) : Promise.resolve([]),
197
197
  includeStructuredCards ? (async () => {
198
198
  try {
199
- const { searchMemoryCards } = await import("./memory-cards-SYVGSLXW.js");
199
+ const { searchMemoryCards } = await import("./memory-cards-NTRYLVOU.js");
200
200
  return await searchMemoryCards(effectiveQuery, agentId, fetchOptions);
201
201
  } catch {
202
202
  return [];
@@ -205,7 +205,7 @@ async function hybridSearch(queryText, agentId, options) {
205
205
  // Reflection insights: patterns, contradictions, summaries across sessions
206
206
  includeStructuredCards ? (async () => {
207
207
  try {
208
- const { searchReflections } = await import("./memory-reflection-FNJU7VFC.js");
208
+ const { searchReflections } = await import("./memory-reflection-4YOUTIMO.js");
209
209
  const insights = await searchReflections(effectiveQuery, agentId, 5);
210
210
  return insights.map((ins) => ({
211
211
  id: ins.id,
@@ -581,7 +581,7 @@ async function lightweightSearch(queryText, agentId, options) {
581
581
  }
582
582
  if (options?.includeStructuredCards !== true) return results;
583
583
  try {
584
- const { searchMemoryCards } = await import("./memory-cards-SYVGSLXW.js");
584
+ const { searchMemoryCards } = await import("./memory-cards-NTRYLVOU.js");
585
585
  const cardResults = await searchMemoryCards(queryText, agentId, options);
586
586
  if (cardResults.length > 0) {
587
587
  return rrfMergeMulti([results, cardResults], limit, RRF_K, [1, 0.85]);
@@ -11,10 +11,10 @@ import {
11
11
  sessionScopeFilter,
12
12
  updateTaskStatus,
13
13
  writeNotification
14
- } from "./chunk-4PDXCEXT.js";
14
+ } from "./chunk-OC7Q4LOK.js";
15
15
  import {
16
16
  getTransport
17
- } from "./chunk-3TXOH3SJ.js";
17
+ } from "./chunk-A7KEWR6S.js";
18
18
  import {
19
19
  getSessionKey
20
20
  } from "./chunk-CVYC6DUW.js";
@@ -27,7 +27,7 @@ import {
27
27
  isCoordinatorName,
28
28
  isMultiInstance,
29
29
  shouldAutoInstance
30
- } from "./chunk-MBYJEE3B.js";
30
+ } from "./chunk-2G2KOWBI.js";
31
31
  import {
32
32
  EXE_AI_DIR
33
33
  } from "./chunk-TOWAZ5IV.js";
@@ -136,7 +136,7 @@ async function dispatchTaskToEmployee(input) {
136
136
  let crossProject = false;
137
137
  if (input.projectName) {
138
138
  try {
139
- const { assertSessionScope } = await import("./session-scope-7QCZF3MJ.js");
139
+ const { assertSessionScope } = await import("./session-scope-QIDIKKFB.js");
140
140
  const check = assertSessionScope("dispatch_task", input.projectName);
141
141
  if (check.reason === "cross_session_denied") {
142
142
  crossProject = true;
@@ -396,7 +396,7 @@ async function updateTask(input) {
396
396
  await markTaskNotificationsRead(taskFile);
397
397
  if (input.status === "needs_review" && !isCoordinator) {
398
398
  try {
399
- const { writeNotification: writeNotification2 } = await import("./notifications-76XXO4Q7.js");
399
+ const { writeNotification: writeNotification2 } = await import("./notifications-SF2XN5JE.js");
400
400
  await writeNotification2({
401
401
  agentId: String(row.assigned_to),
402
402
  agentRole: String(row.assigned_to),
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  initStore
3
- } from "./chunk-25NSQUZ3.js";
3
+ } from "./chunk-DWLDYEGO.js";
4
4
  import {
5
5
  getClient,
6
6
  isInitialized
7
- } from "./chunk-MBYJEE3B.js";
7
+ } from "./chunk-2G2KOWBI.js";
8
8
 
9
9
  // src/lib/schedules.ts
10
10
  import crypto from "crypto";
@@ -830,7 +830,7 @@ function formatReport(report, flags) {
830
830
  return lines.join("\n");
831
831
  }
832
832
  async function fixNullVectors() {
833
- const { tryAcquireWorkerSlot, registerWorkerPid } = await import("./worker-gate-OZCNSASA.js");
833
+ const { tryAcquireWorkerSlot, registerWorkerPid } = await import("./worker-gate-PJYHXNUB.js");
834
834
  if (!tryAcquireWorkerSlot()) {
835
835
  process.stderr.write("[exe-doctor] Worker gate full \u2014 waiting for existing backfill workers to finish\n");
836
836
  await new Promise((r) => setTimeout(r, 5e3));
@@ -951,7 +951,7 @@ function splitAtSentences(text, maxChunkSize) {
951
951
  }
952
952
  async function main(argv = process.argv.slice(2)) {
953
953
  const flags = parseFlags(argv);
954
- const { fastDbInit } = await import("./fast-db-init-TLOT2K43.js");
954
+ const { fastDbInit } = await import("./fast-db-init-5DTYG5FZ.js");
955
955
  const client = await fastDbInit();
956
956
  const report = await runAudit(client, flags);
957
957
  console.log(formatReport(report, flags));
@@ -9,7 +9,7 @@ import {
9
9
  getCoordinatorEmployee,
10
10
  getEmployee,
11
11
  loadEmployeesSync
12
- } from "./chunk-MBYJEE3B.js";
12
+ } from "./chunk-2G2KOWBI.js";
13
13
  import {
14
14
  EXE_AI_DIR
15
15
  } from "./chunk-TOWAZ5IV.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isCrdtSyncEnabled
3
- } from "./chunk-VN6UUZNO.js";
3
+ } from "./chunk-NQND3GFO.js";
4
4
  import {
5
5
  decryptSyncBlob,
6
6
  encryptSyncBlob,
@@ -12,7 +12,7 @@ import {
12
12
  loadEmployees,
13
13
  registerBinSymlinks,
14
14
  saveEmployees
15
- } from "./chunk-MBYJEE3B.js";
15
+ } from "./chunk-2G2KOWBI.js";
16
16
  import {
17
17
  loadDeviceId
18
18
  } from "./chunk-NNT2ZNMC.js";
@@ -485,7 +485,7 @@ async function cloudSync(config) {
485
485
  let pulled = 0;
486
486
  if (pullResult.records.length > 0) {
487
487
  if (isCrdtSyncEnabled()) {
488
- const { initCrdtDoc, importExistingMemories, readAllMemories } = await import("./crdt-sync-3VQP2ISB.js");
488
+ const { initCrdtDoc, importExistingMemories, readAllMemories } = await import("./crdt-sync-B7IUR3BR.js");
489
489
  initCrdtDoc();
490
490
  importExistingMemories(
491
491
  pullResult.records.map((rec) => ({
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  processCRMEvent
3
- } from "./chunk-YH7VB655.js";
3
+ } from "./chunk-ZYETFCDX.js";
4
4
 
5
5
  // src/gateway/adapters/crm-webhook.ts
6
6
  function parseTwentyWebhook(payload) {
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-64WZEXXA.js";
10
10
  import {
11
11
  getTransport
12
- } from "./chunk-3TXOH3SJ.js";
12
+ } from "./chunk-A7KEWR6S.js";
13
13
  import {
14
14
  listTmuxSessions
15
15
  } from "./chunk-GZIAQYGI.js";
@@ -30,7 +30,7 @@ import {
30
30
  import {
31
31
  PlanLimitError,
32
32
  assertEmployeeLimitSync
33
- } from "./chunk-5NSTNICM.js";
33
+ } from "./chunk-3OGN523Z.js";
34
34
  import {
35
35
  getProjectName
36
36
  } from "./chunk-OPU3NYOO.js";
@@ -45,7 +45,7 @@ import {
45
45
  } from "./chunk-MP2AFCGL.js";
46
46
  import {
47
47
  ensureAgentSymlink
48
- } from "./chunk-LM7TQYLW.js";
48
+ } from "./chunk-IWSXQKSB.js";
49
49
  import {
50
50
  expandDualPrefixTools
51
51
  } from "./chunk-HYZV25LY.js";
@@ -58,7 +58,7 @@ import {
58
58
  isCoordinatorName,
59
59
  loadEmployees,
60
60
  loadEmployeesSync
61
- } from "./chunk-MBYJEE3B.js";
61
+ } from "./chunk-2G2KOWBI.js";
62
62
  import {
63
63
  loadDeviceId
64
64
  } from "./chunk-NNT2ZNMC.js";
@@ -359,7 +359,7 @@ async function createTaskCore(input) {
359
359
  if (isCoordinatorSession) {
360
360
  earlySessionScope = resolved;
361
361
  } else {
362
- const { getSessionProject } = await import("./session-scope-7QCZF3MJ.js");
362
+ const { getSessionProject } = await import("./session-scope-QIDIKKFB.js");
363
363
  const sessionProject = getSessionProject(resolved);
364
364
  if (sessionProject && sessionProject !== input.projectName) {
365
365
  scopeMismatchWarning = `session/project mismatch: session "${resolved}" owns "${sessionProject}" but task targets "${input.projectName}". Routed to default scope.`;
@@ -879,6 +879,16 @@ ${input.result}` : `\u26A0\uFE0F ${warning}`;
879
879
  await client.execute("PRAGMA wal_checkpoint(PASSIVE)");
880
880
  } catch {
881
881
  }
882
+ if (input.status === "done" || input.status === "needs_review") {
883
+ try {
884
+ const { incrementSkillSuccess } = await import("./skill-refinement-3W3CIIG3.js");
885
+ await incrementSkillSuccess(
886
+ String(row.assigned_to),
887
+ row.project_name ? String(row.project_name) : null
888
+ );
889
+ } catch {
890
+ }
891
+ }
882
892
  if (input.status === "done" || input.status === "needs_review" || input.status === "cancelled" || input.status === "closed") {
883
893
  try {
884
894
  const { clearQueueForAgent } = await import("./intercom-queue-K3DVKSPJ.js");
@@ -1942,7 +1952,7 @@ async function verifyPaneAtCapacity(sessionName) {
1942
1952
  reason: `capture-pane failed: ${err instanceof Error ? err.message : String(err)}`
1943
1953
  };
1944
1954
  }
1945
- const { isAtCapacity } = await import("./capacity-monitor-5IVGAQ34.js");
1955
+ const { isAtCapacity } = await import("./capacity-monitor-VJLRBE7S.js");
1946
1956
  if (!isAtCapacity(pane)) {
1947
1957
  return {
1948
1958
  atCapacity: false,
@@ -2,7 +2,7 @@ import {
2
2
  listWorkflowDefinitions,
3
3
  runWorkflow,
4
4
  startWorkflow
5
- } from "./chunk-CBLNQNWT.js";
5
+ } from "./chunk-DTT4TRFR.js";
6
6
  import {
7
7
  initCRMBridge
8
8
  } from "./chunk-GCNWCYJI.js";
@@ -11,7 +11,7 @@ import {
11
11
  } from "./chunk-MP2AFCGL.js";
12
12
  import {
13
13
  getClient
14
- } from "./chunk-MBYJEE3B.js";
14
+ } from "./chunk-2G2KOWBI.js";
15
15
 
16
16
  // src/gateway/router.ts
17
17
  function matchesPlatform(msgPlatform, matchPlatform) {
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  updateTask
3
- } from "./chunk-VJW3E5KW.js";
3
+ } from "./chunk-KUPUTWQX.js";
4
4
  import {
5
5
  TASK_ALREADY_CLAIMED_PREFIX
6
- } from "./chunk-4PDXCEXT.js";
6
+ } from "./chunk-OC7Q4LOK.js";
7
7
 
8
8
  // src/mcp/tools/update-task.ts
9
9
  import { z } from "zod";
@@ -23,7 +23,7 @@ function registerUpdateTask(server) {
23
23
  const status = rawStatus;
24
24
  let callerAgentId;
25
25
  try {
26
- const { getActiveAgent: getAgent } = await import("./active-agent-HDUT3T3I.js");
26
+ const { getActiveAgent: getAgent } = await import("./active-agent-IVY5D7DJ.js");
27
27
  callerAgentId = getAgent().agentId;
28
28
  } catch {
29
29
  }
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getGlobalProceduresBlock
3
- } from "./chunk-YOH3ABTS.js";
3
+ } from "./chunk-Y3Z6QHUR.js";
4
4
 
5
5
  // src/lib/employee-templates.ts
6
6
  var BASE_OPERATING_PROCEDURES = `
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  listReminders
3
- } from "./chunk-Q7GVSS2J.js";
3
+ } from "./chunk-VRKPBY6D.js";
4
4
 
5
5
  // src/mcp/tools/list-reminders.ts
6
6
  import { z } from "zod";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isCoordinatorRole
3
- } from "./chunk-MBYJEE3B.js";
3
+ } from "./chunk-2G2KOWBI.js";
4
4
 
5
5
  // src/lib/task-router.ts
6
6
  import { randomUUID } from "crypto";
@@ -4,10 +4,10 @@ import {
4
4
  resolveExeSession,
5
5
  sendIntercom,
6
6
  strictSessionScopeFilter
7
- } from "./chunk-4PDXCEXT.js";
7
+ } from "./chunk-OC7Q4LOK.js";
8
8
  import {
9
9
  getClient
10
- } from "./chunk-MBYJEE3B.js";
10
+ } from "./chunk-2G2KOWBI.js";
11
11
 
12
12
  // src/lib/messaging.ts
13
13
  import crypto from "crypto";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  completeReminder
3
- } from "./chunk-Q7GVSS2J.js";
3
+ } from "./chunk-VRKPBY6D.js";
4
4
 
5
5
  // src/mcp/tools/complete-reminder.ts
6
6
  import { z } from "zod";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  listBehaviors
3
- } from "./chunk-EOU4ZLRZ.js";
3
+ } from "./chunk-GCB4MHTG.js";
4
4
  import {
5
5
  loadConfigSync
6
6
  } from "./chunk-TOWAZ5IV.js";