@askexenow/exe-os 0.9.302 → 0.9.310

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 (311) hide show
  1. package/deploy/compose/.env.example +8 -2
  2. package/deploy/compose/README.md +7 -3
  3. package/deploy/compose/add-routes.sh +107 -0
  4. package/deploy/compose/docker-compose.yml +91 -18
  5. package/deploy/compose/gateway-watchdog.sh +223 -0
  6. package/deploy/compose/generate-env.ts +16 -4
  7. package/deploy/compose/setup.sh +7 -8
  8. package/deploy/stack-manifests/v0.9.json +125 -4
  9. package/dist/{active-agent-ODI6GGVD.js → active-agent-ORX47ZKW.js} +4 -3
  10. package/dist/{active-agent-GGQAP4QE.js → active-agent-S5T2YMOR.js} +4 -3
  11. package/dist/{agentic-ontology-M7T72M6V.js → agentic-ontology-6KBAXLSJ.js} +1 -1
  12. package/dist/{backfill-metadata-GSZP2BEW.js → backfill-metadata-FV7GX6AS.js} +5 -4
  13. package/dist/{behaviors-JM6KFSXL.js → behaviors-47CPEKJ7.js} +6 -5
  14. package/dist/bin/agentic-ontology-backfill.js +6 -5
  15. package/dist/bin/agentic-reflection-backfill.js +7 -6
  16. package/dist/bin/agentic-semantic-label.js +6 -5
  17. package/dist/bin/backfill-conversations.js +8 -7
  18. package/dist/bin/backfill-responses.js +8 -7
  19. package/dist/bin/backfill-vectors.js +10 -9
  20. package/dist/bin/bulk-sync-postgres.js +14 -13
  21. package/dist/bin/cc-doctor.js +5 -4
  22. package/dist/bin/cleanup-stale-review-tasks.js +13 -12
  23. package/dist/bin/cli.js +20 -17
  24. package/dist/bin/deferred-daemon-restart.js +4 -4
  25. package/dist/bin/exe-agent-config.js +3 -2
  26. package/dist/bin/exe-agent.js +12 -11
  27. package/dist/bin/exe-assign.js +10 -9
  28. package/dist/bin/exe-boot.js +21 -20
  29. package/dist/bin/exe-call.js +5 -4
  30. package/dist/bin/exe-cloud.js +14 -13
  31. package/dist/bin/exe-config-dump.js +525 -0
  32. package/dist/bin/exe-dispatch.js +13 -12
  33. package/dist/bin/exe-doctor.js +2 -2
  34. package/dist/bin/exe-export-behaviors.js +8 -7
  35. package/dist/bin/exe-forget.js +7 -6
  36. package/dist/bin/exe-gateway.js +22 -11
  37. package/dist/bin/exe-healthcheck.js +7 -4
  38. package/dist/bin/exe-heartbeat.js +13 -12
  39. package/dist/bin/exe-kill.js +16 -15
  40. package/dist/bin/exe-launch-agent.js +41 -25
  41. package/dist/bin/exe-new-employee.js +9 -8
  42. package/dist/bin/exe-pending-messages.js +14 -13
  43. package/dist/bin/exe-pending-notifications.js +13 -12
  44. package/dist/bin/exe-pending-reviews.js +13 -12
  45. package/dist/bin/exe-preflight.js +108 -0
  46. package/dist/bin/exe-rename.js +5 -4
  47. package/dist/bin/exe-review.js +15 -14
  48. package/dist/bin/exe-search-quality.js +282 -0
  49. package/dist/bin/exe-search.js +6 -5
  50. package/dist/bin/exe-session-cleanup.js +18 -17
  51. package/dist/bin/exe-settings.js +15 -14
  52. package/dist/bin/exe-start-codex.js +13 -12
  53. package/dist/bin/exe-start-opencode.js +9 -8
  54. package/dist/bin/exe-status.js +14 -13
  55. package/dist/bin/exe-support.js +4 -4
  56. package/dist/bin/exe-team.js +4 -3
  57. package/dist/bin/exe-timers.js +237 -0
  58. package/dist/bin/git-sweep.js +14 -13
  59. package/dist/bin/graph-backfill.js +7 -6
  60. package/dist/bin/graph-export.js +6 -5
  61. package/dist/bin/import-history.js +10 -9
  62. package/dist/bin/install-launchd.js +5 -2
  63. package/dist/bin/install.js +16 -15
  64. package/dist/bin/intercom-check.js +4 -4
  65. package/dist/bin/mcp-sessions.js +2 -2
  66. package/dist/bin/orchestration-metrics.js +5 -4
  67. package/dist/bin/postgres-agentic-reflection-backfill.js +2 -2
  68. package/dist/bin/postgres-agentic-semantic-backfill.js +1 -1
  69. package/dist/bin/prune-orphan-chunks.js +43 -10
  70. package/dist/bin/scan-tasks.js +13 -12
  71. package/dist/bin/setup.js +1 -1
  72. package/dist/bin/shard-migrate.js +5 -4
  73. package/dist/bin/stack-update.js +30 -5
  74. package/dist/bin/vps-health-gate.js +1 -1
  75. package/dist/{capability-cards-BCTFKT4G.js → capability-cards-WQVY7WSS.js} +3 -2
  76. package/dist/{capacity-monitor-B4S3XEDO.js → capacity-monitor-BUKYPSWR.js} +14 -13
  77. package/dist/{catchup-brief-I35KHK62.js → catchup-brief-X5IVQAOH.js} +16 -15
  78. package/dist/{chunk-74TUYU5A.js → chunk-255DIG4B.js} +1 -1
  79. package/dist/{chunk-CXKR5Z5F.js → chunk-2EJ636HI.js} +4 -0
  80. package/dist/{chunk-ST3X3YMZ.js → chunk-2NGPZCWX.js} +4 -4
  81. package/dist/{chunk-LD2JKEJT.js → chunk-2NVEKSSP.js} +7 -7
  82. package/dist/{chunk-V6P7TPPA.js → chunk-2UVN2NBN.js} +148 -2
  83. package/dist/{chunk-OZRO37JW.js → chunk-3KH6GXXX.js} +2 -2
  84. package/dist/{chunk-IMJNYREY.js → chunk-43R2GILO.js} +1 -1
  85. package/dist/{chunk-6X2YNVLB.js → chunk-4BANMHJ5.js} +3 -3
  86. package/dist/{chunk-QNJPDIWY.js → chunk-4L4R6AQJ.js} +1 -1
  87. package/dist/{chunk-QWLPAEG5.js → chunk-4Q5VNQTV.js} +3 -3
  88. package/dist/{chunk-VLSYKMCJ.js → chunk-4RJJ5FJ2.js} +14 -2
  89. package/dist/{chunk-4AN6KMVG.js → chunk-5DPE7B7K.js} +1 -1
  90. package/dist/{chunk-H7ZNSQ2E.js → chunk-62UZWGFX.js} +2 -2
  91. package/dist/{chunk-ZQ2QHGWE.js → chunk-66JPZELX.js} +20 -24
  92. package/dist/{chunk-BUGMW7YF.js → chunk-6LNSZADA.js} +11 -11
  93. package/dist/{chunk-PBCRUNIK.js → chunk-6OD2RVIA.js} +492 -157
  94. package/dist/chunk-7ODTYODO.js +350 -0
  95. package/dist/{chunk-5YL4Y27D.js → chunk-7WDIGRSO.js} +1 -1
  96. package/dist/{chunk-WIL6LXNG.js → chunk-AC6DKMVS.js} +1 -1
  97. package/dist/{chunk-HZEAAKCR.js → chunk-B2J3BBJC.js} +3 -3
  98. package/dist/{chunk-LE7CDIOA.js → chunk-BUOMSIXH.js} +1 -1
  99. package/dist/{chunk-XKGNKH6V.js → chunk-DFUCFLZH.js} +1 -1
  100. package/dist/{chunk-U724Z3S3.js → chunk-DKHBMIVE.js} +100 -37
  101. package/dist/{chunk-MY36XDUK.js → chunk-DNFU56ZS.js} +1 -1
  102. package/dist/{chunk-GSWGOGP5.js → chunk-EOS7VPVT.js} +5 -5
  103. package/dist/{chunk-P33JVGSP.js → chunk-FM7XZDZI.js} +1 -1
  104. package/dist/chunk-G6EJKYK3.js +33 -0
  105. package/dist/{chunk-OMCNFTSI.js → chunk-GMZMBLHT.js} +1 -1
  106. package/dist/{chunk-4LZ54YGA.js → chunk-GSY6HL3T.js} +5 -5
  107. package/dist/{chunk-OVKNFTCL.js → chunk-HED6D5KR.js} +132 -21
  108. package/dist/{chunk-ALH6QLYF.js → chunk-HQODUV3G.js} +2 -2
  109. package/dist/{chunk-US64UR5O.js → chunk-IIHE3FNC.js} +3 -3
  110. package/dist/{chunk-H2ISTRWU.js → chunk-IRIPGGGL.js} +1 -1
  111. package/dist/{chunk-Z3EXECOX.js → chunk-ISILDO7P.js} +1 -1
  112. package/dist/{chunk-6ERZFDBS.js → chunk-IZPO6IOZ.js} +1 -1
  113. package/dist/{chunk-W65Z4SJS.js → chunk-J3QZPDNH.js} +1 -1
  114. package/dist/{chunk-3IJCP6ZH.js → chunk-JDYO76PI.js} +1 -1
  115. package/dist/{chunk-ORNKGGFX.js → chunk-JNARUXDC.js} +1 -1
  116. package/dist/{chunk-VME3UH4D.js → chunk-JV225JBX.js} +1 -1
  117. package/dist/{chunk-EI7PBUIA.js → chunk-JZW5AOWI.js} +1 -1
  118. package/dist/{chunk-TLOILHSL.js → chunk-K7KBAJQL.js} +36 -18
  119. package/dist/{chunk-RHMWSUJB.js → chunk-KAVUTP5G.js} +2 -2
  120. package/dist/{chunk-7FNELLMX.js → chunk-KPVVTHPK.js} +8 -8
  121. package/dist/{chunk-35U72CD2.js → chunk-KSMITUGY.js} +3 -3
  122. package/dist/{chunk-D6UICP3C.js → chunk-LMX7UKGX.js} +81 -3
  123. package/dist/{chunk-7ZWC5HVG.js → chunk-MTIJ2NXY.js} +1 -1
  124. package/dist/{chunk-KVHPBQV4.js → chunk-NCC3F6GM.js} +1 -1
  125. package/dist/{chunk-AYMSIV7X.js → chunk-NIZQ3CIS.js} +1 -1
  126. package/dist/{chunk-LTI2DLHY.js → chunk-OBJXZII2.js} +2 -2
  127. package/dist/{chunk-WHOT5NZ7.js → chunk-OR3TAZL3.js} +14 -2
  128. package/dist/{chunk-RQUHAXMM.js → chunk-PHFPIUWU.js} +2 -0
  129. package/dist/{chunk-N76VTMMF.js → chunk-PMEOSD6S.js} +2 -2
  130. package/dist/{chunk-TCJEFW5V.js → chunk-PPXQE7AS.js} +4 -4
  131. package/dist/{chunk-KHZQVLNZ.js → chunk-QE7UVQDP.js} +46 -0
  132. package/dist/{chunk-SXJACGQ5.js → chunk-QEGXNJGR.js} +4 -4
  133. package/dist/{chunk-W3E4VEEJ.js → chunk-RPBTYQKJ.js} +1 -1
  134. package/dist/chunk-RQ7OVXUZ.js +81 -0
  135. package/dist/{chunk-7L2EV3XX.js → chunk-RVXWGPD3.js} +39 -6
  136. package/dist/{chunk-YNALY3SX.js → chunk-RZJ6DXVE.js} +1 -1
  137. package/dist/{chunk-P3SIFDES.js → chunk-SCYWCWKY.js} +16 -4
  138. package/dist/{chunk-7I43GVER.js → chunk-SOT23KWW.js} +3 -3
  139. package/dist/{chunk-T62GAN7I.js → chunk-SPOXL7HF.js} +7 -7
  140. package/dist/{chunk-3YJMI422.js → chunk-TN2YCFQE.js} +4 -4
  141. package/dist/{chunk-YMSWCERY.js → chunk-U63BZI2B.js} +3 -3
  142. package/dist/{chunk-KA5RK5HZ.js → chunk-V42BSVX6.js} +2 -2
  143. package/dist/{chunk-PJTRAFL4.js → chunk-V4BW5HFQ.js} +3 -3
  144. package/dist/{chunk-4FG6IX7U.js → chunk-VFSYVQX4.js} +1 -1
  145. package/dist/chunk-VQRTO7IS.js +290 -0
  146. package/dist/{chunk-OR7J7TIA.js → chunk-VT6P7FV4.js} +1 -1
  147. package/dist/{chunk-BEIYF4NS.js → chunk-W2J2RF5N.js} +3 -3
  148. package/dist/{chunk-Y5ASPRP7.js → chunk-WBJXJ2R4.js} +17 -13
  149. package/dist/chunk-WCGNCH3Q.js +72 -0
  150. package/dist/{chunk-2LJDLQNO.js → chunk-WJ2PZGRV.js} +1 -1
  151. package/dist/{chunk-AAPPSMPH.js → chunk-WZBUKC5N.js} +1 -1
  152. package/dist/{chunk-RO7EXVSJ.js → chunk-X4AFBL4N.js} +1 -1
  153. package/dist/{chunk-BR74NYEF.js → chunk-XV5HRIXG.js} +5 -5
  154. package/dist/chunk-XXJRZ75E.js +43 -0
  155. package/dist/{chunk-VDHUHXFF.js → chunk-XYG722JW.js} +2 -2
  156. package/dist/{chunk-MM7SWUQ4.js → chunk-YB7U4WTY.js} +4 -4
  157. package/dist/{chunk-RMRZXPUU.js → chunk-Z6H6Y4BS.js} +1 -1
  158. package/dist/{token-budget-UMHRRDBT.js → chunk-ZOVHXTGC.js} +2 -9
  159. package/dist/{chunk-HNLBHP6P.js → chunk-ZZXADKAP.js} +3 -3
  160. package/dist/{co-activation-OKAHEMPE.js → co-activation-WN25AJOC.js} +3 -2
  161. package/dist/{co-occurrence-IHSPB53O.js → co-occurrence-YP2Q3OEA.js} +5 -4
  162. package/dist/{code-context-index-KGY4LKCA.js → code-context-index-ZWONKBKX.js} +4 -4
  163. package/dist/{conversation-entity-extractor-KXJSHRGJ.js → conversation-entity-extractor-KYOBXNID.js} +2 -2
  164. package/dist/{crdt-sync-K2G3C6XY.js → crdt-sync-ZFIFL2QM.js} +1 -1
  165. package/dist/{crm-webhook-ERZSQ3CW.js → crm-webhook-DGPHULOO.js} +2 -2
  166. package/dist/{cto-delegation-gate-ZCJ53LBQ.js → cto-delegation-gate-OF2A3TSS.js} +12 -11
  167. package/dist/daemon-auth-N6P2MZAV.js +17 -0
  168. package/dist/{daemon-orchestration-V6HALVDS.js → daemon-orchestration-G4RRTPP7.js} +16 -15
  169. package/dist/daemon-ready-signal-3L2MJT7C.js +13 -0
  170. package/dist/{db-backup-VZHSFUVA.js → db-backup-EORG4LBO.js} +1 -1
  171. package/dist/{doc-graph-extractor-LQ2IFND2.js → doc-graph-extractor-APZS3DFD.js} +5 -4
  172. package/dist/{dreaming-QAKUASYV.js → dreaming-Q4E3WBGY.js} +13 -12
  173. package/dist/{exe-drift-H3UWNFFY.js → exe-drift-CI5R6GUT.js} +4 -3
  174. package/dist/{exe-export-MN5D4JMT.js → exe-export-HQIQASIT.js} +7 -6
  175. package/dist/{exe-import-IFFMEVD7.js → exe-import-ULZK56WC.js} +7 -6
  176. package/dist/{exe-key-RSZC72QK.js → exe-key-ILNSBGRN.js} +5 -4
  177. package/dist/{exe-snapshot-I622MPLS.js → exe-snapshot-RUZTWZOF.js} +16 -15
  178. package/dist/{factory-CTFAGZUA.js → factory-YHQZ6RZZ.js} +14 -6
  179. package/dist/{fast-db-init-QEFVT7Q3.js → fast-db-init-KNJRL7T3.js} +1 -1
  180. package/dist/{founder-context-3SOKEW76.js → founder-context-QCTMEK66.js} +2 -2
  181. package/dist/gateway/index.js +12 -11
  182. package/dist/{git-staleness-E7RPQA5U.js → git-staleness-KIA5YI4H.js} +3 -2
  183. package/dist/{git-task-sweep-D3A2C5BW.js → git-task-sweep-WH6QE7HL.js} +13 -12
  184. package/dist/{global-procedures-POG4V6IK.js → global-procedures-SYZZCGDS.js} +4 -3
  185. package/dist/{graph-auto-extract-E7KALNWA.js → graph-auto-extract-J2TIWZEE.js} +5 -4
  186. package/dist/{graph-rag-3RZN7JR3.js → graph-rag-HITZZ63L.js} +2 -2
  187. package/dist/hooks/bug-report-worker.js +15 -14
  188. package/dist/hooks/codex-stop-task-finalizer.js +15 -14
  189. package/dist/hooks/commit-complete.js +15 -14
  190. package/dist/hooks/error-recall.js +8 -7
  191. package/dist/hooks/exe-heartbeat-hook.js +4 -3
  192. package/dist/hooks/ingest-worker.js +4 -4
  193. package/dist/hooks/ingest.js +8 -7
  194. package/dist/hooks/instructions-loaded.js +5 -4
  195. package/dist/hooks/manifest.json +20 -20
  196. package/dist/hooks/notification.js +5 -4
  197. package/dist/hooks/post-compact.js +14 -13
  198. package/dist/hooks/post-tool-combined.js +7 -7
  199. package/dist/hooks/pre-compact.js +19 -18
  200. package/dist/hooks/pre-tool-use.js +18 -17
  201. package/dist/hooks/prompt-submit.js +28 -27
  202. package/dist/hooks/session-end.js +24 -23
  203. package/dist/hooks/session-start.js +46 -22
  204. package/dist/hooks/stop.js +22 -21
  205. package/dist/hooks/subagent-stop.js +14 -13
  206. package/dist/hooks/summary-worker.js +22 -21
  207. package/dist/index.js +25 -23
  208. package/dist/{installer-IXUX73JN.js → installer-3NB3IBHF.js} +10 -9
  209. package/dist/{installer-RCUPPZ7Y.js → installer-IIJFCTMH.js} +10 -9
  210. package/dist/{installer-HDD6OH5Z.js → installer-PSDYMGN7.js} +7 -6
  211. package/dist/lib/cloud-sync.js +14 -13
  212. package/dist/lib/consolidation.js +8 -7
  213. package/dist/lib/database.js +3 -2
  214. package/dist/lib/db-daemon-client.js +4 -4
  215. package/dist/lib/db.js +3 -2
  216. package/dist/lib/device-registry.js +3 -1
  217. package/dist/lib/embedder.js +4 -4
  218. package/dist/lib/employee-templates.js +5 -4
  219. package/dist/lib/employees.js +3 -2
  220. package/dist/lib/exe-daemon-client.js +3 -3
  221. package/dist/lib/exe-daemon.js +256 -406
  222. package/dist/lib/hybrid-search.js +6 -5
  223. package/dist/lib/identity.js +3 -2
  224. package/dist/lib/license.js +2 -2
  225. package/dist/lib/messaging.js +13 -12
  226. package/dist/lib/reminders.js +4 -3
  227. package/dist/lib/schedules.js +6 -5
  228. package/dist/lib/session-registry.js +5 -4
  229. package/dist/lib/skill-learning.js +7 -6
  230. package/dist/lib/store.js +7 -4
  231. package/dist/lib/task-router.js +4 -3
  232. package/dist/lib/tasks.js +14 -13
  233. package/dist/lib/tmux-routing.js +16 -11
  234. package/dist/lib/token-spend.js +4 -3
  235. package/dist/{license-gate-V2UCK4KJ.js → license-gate-7SDHCJUO.js} +3 -3
  236. package/dist/mcp/register-tools.js +74 -73
  237. package/dist/mcp/server.js +97 -79
  238. package/dist/mcp/tools/complete-reminder.js +5 -4
  239. package/dist/mcp/tools/create-reminder.js +5 -4
  240. package/dist/mcp/tools/create-task.js +16 -15
  241. package/dist/mcp/tools/deactivate-behavior.js +8 -7
  242. package/dist/mcp/tools/list-reminders.js +5 -4
  243. package/dist/mcp/tools/list-tasks.js +16 -15
  244. package/dist/mcp/tools/send-message.js +15 -14
  245. package/dist/mcp/tools/update-task.js +15 -14
  246. package/dist/{mcp-http-config-7LFFPNGV.js → mcp-http-config-QSOVFXHW.js} +4 -3
  247. package/dist/mcp-tool-surface-CSPFXL3F.js +15 -0
  248. package/dist/{memory-cards-BGI6MJRN.js → memory-cards-II67WFL2.js} +3 -2
  249. package/dist/{memory-graph-extractor-DTRRNWHZ.js → memory-graph-extractor-PM4Q2KJG.js} +6 -5
  250. package/dist/{memory-poisoning-defense-MOCWJK6S.js → memory-poisoning-defense-ECXSX7HK.js} +3 -2
  251. package/dist/{memory-queue-client-DD4E5SIZ.js → memory-queue-client-HLURQEV6.js} +4 -4
  252. package/dist/{memory-reflection-UKKTGZYR.js → memory-reflection-PXF6YFDU.js} +3 -2
  253. package/dist/{notifications-AMJ2K3MM.js → notifications-UP7WQGG4.js} +12 -11
  254. package/dist/{orchestration-events-MB4QVHTD.js → orchestration-events-PZLLPCKY.js} +4 -3
  255. package/dist/orchestration-health-read-EJWVUARG.js +191 -0
  256. package/dist/{orchestrator-M7DJH6TN.js → orchestrator-PUT45J4O.js} +14 -13
  257. package/dist/{pipeline-router-4LT5YG5P.js → pipeline-router-5CRWKESM.js} +4 -3
  258. package/dist/{plan-limits-ENS7OJWP.js → plan-limits-SH2NDFNX.js} +6 -5
  259. package/dist/{project-boot-6W5JPGSB.js → project-boot-2TCPDZ4S.js} +25 -1
  260. package/dist/{projection-worker-WWXZK7QD.js → projection-worker-HWY37MNC.js} +2 -2
  261. package/dist/{prospective-memory-VNGLPMS6.js → prospective-memory-FQSVMCGG.js} +3 -2
  262. package/dist/{reranker-6XBS55FA.js → reranker-AALRMGMM.js} +1 -1
  263. package/dist/{retrieval-health-ATX5TIQ2.js → retrieval-health-PNWJSJNG.js} +1 -1
  264. package/dist/{review-polling-E4ALHTQE.js → review-polling-65JZUE3T.js} +13 -12
  265. package/dist/runtime/index.js +24 -22
  266. package/dist/{session-events-3J6APMKN.js → session-events-EJ3OSAA6.js} +13 -12
  267. package/dist/session-kill-telemetry-3HGM7SNQ.js +63 -0
  268. package/dist/{session-scope-E54VIYTJ.js → session-scope-JGDYAMJO.js} +12 -11
  269. package/dist/{setup-wizard-XV736U5D.js → setup-wizard-44LMFM2C.js} +1 -1
  270. package/dist/shared-rate-limit-store-QZPQEVE2.js +80 -0
  271. package/dist/{skill-refinement-FTURVWFN.js → skill-refinement-DUOO6B7V.js} +3 -2
  272. package/dist/{stack-release-JZVTSBJJ.js → stack-release-XYMKU7NT.js} +53 -4
  273. package/dist/{stack-update-BIK2QHOE.js → stack-update-XHQJRJEP.js} +5 -3
  274. package/dist/{steward-gate-YGU4VXPP.js → steward-gate-6NWRDLX2.js} +4 -3
  275. package/dist/{task-enforcement-GY3VTY6L.js → task-enforcement-UOULTGFB.js} +12 -11
  276. package/dist/{task-scope-PYOK7OQ6.js → task-scope-P5STKYAC.js} +12 -11
  277. package/dist/{tasks-crud-HLJEJ2UU.js → tasks-crud-24HMTULR.js} +12 -11
  278. package/dist/{tasks-notify-NGS3DWUJ.js → tasks-notify-LAIU7UUI.js} +13 -12
  279. package/dist/{tasks-review-BP5V2X34.js → tasks-review-AFJAU2DY.js} +12 -11
  280. package/dist/{telemetry-upload-AXYPFAPS.js → telemetry-upload-DWFGC2XJ.js} +8 -7
  281. package/dist/token-budget-4RFZKWGH.js +16 -0
  282. package/dist/{tool-capability-index-RHPVMMDD.js → tool-capability-index-ZEXBWKUZ.js} +1 -1
  283. package/dist/{tool-telemetry-BLSVABFJ.js → tool-telemetry-BS5JXM5M.js} +1 -1
  284. package/dist/tui/App.js +21 -20
  285. package/dist/{tui-data-EYPOFYLS.js → tui-data-UNO5B7PU.js} +12 -11
  286. package/dist/{worker-gate-SMFOBMMX.js → worker-gate-C6CTTYMD.js} +1 -1
  287. package/dist/{workflow-engine-TDJZ3TXB.js → workflow-engine-4W2KYCDV.js} +2 -2
  288. package/dist/{worktree-XISIYRM4.js → worktree-2CXY6NEB.js} +5 -4
  289. package/dist/{worktree-sweep-AS6GAR6X.js → worktree-sweep-K3CJFSUL.js} +6 -5
  290. package/package.json +9 -4
  291. package/release-notes.json +17 -88
  292. package/stack.release.json +51 -4
  293. package/dist/chunk-PHOQAVTK.js +0 -42
  294. package/dist/daemon-auth-BK7ON5ZH.js +0 -13
  295. package/dist/session-kill-telemetry-KOAHLRBT.js +0 -31
  296. package/dist/{chunk-XDE5IGBX.js → chunk-2NS3QRMJ.js} +0 -0
  297. package/dist/{chunk-JTMKRUX6.js → chunk-A2YZG4AD.js} +0 -0
  298. package/dist/{chunk-UZATXREL.js → chunk-AE74NOE6.js} +0 -0
  299. package/dist/{chunk-LUGWK6QB.js → chunk-FF5DA4XP.js} +3 -3
  300. /package/dist/{chunk-BGOMFGSW.js → chunk-GWPICNSO.js} +0 -0
  301. /package/dist/{chunk-NLHUA3YB.js → chunk-I3DPCSDG.js} +0 -0
  302. /package/dist/{chunk-YM3367VC.js → chunk-J3SR5MGG.js} +0 -0
  303. /package/dist/{chunk-FKFVNV7X.js → chunk-K4BKJJ4F.js} +0 -0
  304. /package/dist/{chunk-PTDBHQX7.js → chunk-MQCTK6EF.js} +0 -0
  305. /package/dist/{chunk-GBV5PV5T.js → chunk-QNXM2HXW.js} +0 -0
  306. /package/dist/{chunk-GZSG2ZOX.js → chunk-YUBTHJVV.js} +0 -0
  307. /package/dist/{core-memory-4OM7LR77.js → core-memory-OC5ITKKV.js} +0 -0
  308. /package/dist/{entity-boost-SFHIRXT5.js → entity-boost-NF3LE6OJ.js} +0 -0
  309. /package/dist/{message-queue-client-QTC3VHJT.js → message-queue-client-4VDU6BZY.js} +0 -0
  310. /package/dist/{oauth-server-BPN55EJM.js → oauth-server-EWUL7DMD.js} +0 -0
  311. /package/dist/{wiki-acl-45SIGG4O.js → wiki-acl-CONNF6ES.js} +0 -0
@@ -1,11 +1,11 @@
1
- import {
2
- formatDegradations,
3
- getRetrievalHealth
4
- } from "./chunk-GZSG2ZOX.js";
5
1
  import {
6
2
  buildRestartReport,
7
3
  formatRestartReport
8
4
  } from "./chunk-KQ4Z2G24.js";
5
+ import {
6
+ formatDegradations,
7
+ getRetrievalHealth
8
+ } from "./chunk-YUBTHJVV.js";
9
9
  import {
10
10
  blobToVector
11
11
  } from "./chunk-OTVEIJUQ.js";
@@ -941,7 +941,7 @@ function formatReport(report, flags) {
941
941
  return lines.join("\n");
942
942
  }
943
943
  async function fixNullVectors() {
944
- const { tryAcquireWorkerSlot, registerWorkerPid } = await import("./worker-gate-SMFOBMMX.js");
944
+ const { tryAcquireWorkerSlot, registerWorkerPid } = await import("./worker-gate-C6CTTYMD.js");
945
945
  if (!tryAcquireWorkerSlot()) {
946
946
  process.stderr.write("[exe-doctor] Worker gate full \u2014 waiting for existing backfill workers to finish\n");
947
947
  await new Promise((r) => setTimeout(r, 5e3));
@@ -1126,7 +1126,7 @@ async function main(argv = process.argv.slice(2)) {
1126
1126
  console.log(formatRestartReport(restartReport));
1127
1127
  return emptyAuditReport();
1128
1128
  }
1129
- const { fastDbInit } = await import("./fast-db-init-QEFVT7Q3.js");
1129
+ const { fastDbInit } = await import("./fast-db-init-KNJRL7T3.js");
1130
1130
  const client = await fastDbInit();
1131
1131
  const report = await runAudit(client, flags);
1132
1132
  console.log(formatReport(report, flags));
@@ -1137,7 +1137,7 @@ ${mode} Applying repairs...
1137
1137
  `);
1138
1138
  if (!flags.dryRun) {
1139
1139
  try {
1140
- const { createBackup } = await import("./db-backup-VZHSFUVA.js");
1140
+ const { createBackup } = await import("./db-backup-EORG4LBO.js");
1141
1141
  const backupPath = await createBackup("pre-fix");
1142
1142
  if (backupPath) {
1143
1143
  console.log(` Backup created: ${backupPath.split("/").pop()}`);
@@ -12,7 +12,7 @@ import {
12
12
  } from "./chunk-5A6KTWQL.js";
13
13
  import {
14
14
  mcpHttpPort
15
- } from "./chunk-EI7PBUIA.js";
15
+ } from "./chunk-JZW5AOWI.js";
16
16
  import {
17
17
  EXE_AI_DIR
18
18
  } from "./chunk-DFIOOK5R.js";
@@ -388,6 +388,150 @@ function checkCpuSteal() {
388
388
  detail: steal.severity === "critical" ? `\u{1F534} CRITICAL: ${steal.message}` : steal.severity === "warning" ? `\u{1F7E0} WARN: ${steal.message}` : steal.message
389
389
  }];
390
390
  }
391
+ function checkRetrievalHealth() {
392
+ const results = [];
393
+ let embedDaemon = "unavailable";
394
+ try {
395
+ const pidPath = path.join(EXE_AI_DIR, "exed.pid");
396
+ if (existsSync(pidPath)) {
397
+ const pid = parseInt(readFileSync(pidPath, "utf8").trim(), 10);
398
+ try {
399
+ process.kill(pid, 0);
400
+ try {
401
+ const tokenPath = path.join(EXE_AI_DIR, "exed.token");
402
+ if (existsSync(tokenPath)) {
403
+ const token = readFileSync(tokenPath, "utf8").trim();
404
+ const port = /^\d+$/.test(mcpHttpPort()) ? mcpHttpPort() : "48739";
405
+ const raw = execSync(
406
+ `curl -sS -m 2 -H "Authorization: Bearer ${token}" http://127.0.0.1:${port}/health 2>/dev/null`,
407
+ { encoding: "utf8", timeout: 3e3 }
408
+ );
409
+ const health = JSON.parse(raw);
410
+ const worker = health.embedWorker;
411
+ const embeddingField = health.embedding;
412
+ if (worker?.disabledByDesign || embeddingField === "disabled") {
413
+ embedDaemon = "disabled";
414
+ } else if (worker) {
415
+ embedDaemon = worker.forked && worker.ready && worker.pid != null ? "running" : "stopped";
416
+ } else if (embeddingField === "ok") {
417
+ embedDaemon = "running";
418
+ } else {
419
+ embedDaemon = "stopped";
420
+ }
421
+ } else {
422
+ embedDaemon = "stopped";
423
+ }
424
+ } catch {
425
+ embedDaemon = "stopped";
426
+ }
427
+ } catch {
428
+ embedDaemon = "unavailable";
429
+ }
430
+ }
431
+ } catch {
432
+ embedDaemon = "unavailable";
433
+ }
434
+ const embedIcon = embedDaemon === "running" ? "\u{1F7E2}" : embedDaemon === "disabled" ? "\u2139\uFE0F" : "\u{1F7E0}";
435
+ results.push({
436
+ name: "retrieval/embed-daemon",
437
+ pass: embedDaemon === "running" || embedDaemon === "disabled",
438
+ detail: `${embedIcon} Embed daemon: ${embedDaemon}`
439
+ });
440
+ let configuredSearchMode = "hybrid";
441
+ try {
442
+ const configPath = path.join(EXE_AI_DIR, "config.json");
443
+ if (existsSync(configPath)) {
444
+ const cfg = JSON.parse(readFileSync(configPath, "utf8"));
445
+ if (cfg.searchMode) configuredSearchMode = cfg.searchMode;
446
+ }
447
+ } catch {
448
+ }
449
+ let actualSearchMode;
450
+ if (configuredSearchMode === "fts") {
451
+ actualSearchMode = "fts+graph";
452
+ } else if (embedDaemon === "running") {
453
+ actualSearchMode = "hybrid (vector+fts+graph)";
454
+ } else {
455
+ actualSearchMode = "fts+graph (degraded from hybrid)";
456
+ }
457
+ const isDegraded = actualSearchMode.includes("degraded");
458
+ results.push({
459
+ name: "retrieval/search-mode",
460
+ pass: !isDegraded,
461
+ detail: isDegraded ? `\u{1F7E0} Search mode degraded: ${actualSearchMode} (configured: ${configuredSearchMode})` : `\u{1F7E2} Search mode: ${actualSearchMode}`
462
+ });
463
+ let queryRouter = "fallback";
464
+ try {
465
+ const configPath = path.join(EXE_AI_DIR, "config.json");
466
+ if (existsSync(configPath)) {
467
+ const cfg = JSON.parse(readFileSync(configPath, "utf8"));
468
+ if (cfg.selfQueryRouter === false) {
469
+ queryRouter = "disabled";
470
+ }
471
+ }
472
+ if (queryRouter !== "disabled") {
473
+ const hasKey = Boolean(
474
+ process.env.ANTHROPIC_API_KEY || process.env.ANTHROPIC_AUTH_TOKEN
475
+ );
476
+ queryRouter = hasKey ? "active" : "fallback";
477
+ }
478
+ } catch {
479
+ queryRouter = "fallback";
480
+ }
481
+ results.push({
482
+ name: "retrieval/query-router",
483
+ pass: queryRouter !== "fallback",
484
+ detail: queryRouter === "active" ? "\u{1F7E2} Query router: active (LLM-based)" : queryRouter === "disabled" ? "\u2139\uFE0F Query router: disabled by configuration" : "\u{1F7E0} Query router: fallback (rule-based \u2014 no Anthropic credential for LLM routing)"
485
+ });
486
+ try {
487
+ const ledgerPath = path.join(EXE_AI_DIR, "db-restore-events.json");
488
+ if (existsSync(ledgerPath)) {
489
+ const raw = JSON.parse(readFileSync(ledgerPath, "utf8"));
490
+ if (Array.isArray(raw) && raw.length > 0) {
491
+ const now = Date.now();
492
+ const dayAgo = now - 24 * 60 * 60 * 1e3;
493
+ const recentEvents = raw.filter(
494
+ (e) => e.at && new Date(e.at).getTime() > dayAgo
495
+ );
496
+ const last = raw[raw.length - 1];
497
+ if (recentEvents.length > 0) {
498
+ const lastKind = last?.kind ?? "unknown";
499
+ const isCritical = lastKind === "restore-failed" || lastKind === "zeroed-no-wal";
500
+ results.push({
501
+ name: "retrieval/db-restore",
502
+ pass: false,
503
+ detail: isCritical ? `\u{1F534} ${recentEvents.length} DB restore event(s) in last 24h (last: ${lastKind} @ ${last?.at ?? "?"})` : `\u{1F7E0} ${recentEvents.length} DB restore event(s) in last 24h (last: ${lastKind} @ ${last?.at ?? "?"})`
504
+ });
505
+ } else {
506
+ results.push({
507
+ name: "retrieval/db-restore",
508
+ pass: true,
509
+ detail: `\u{1F7E2} ${raw.length} historical DB restore event(s), none in last 24h`
510
+ });
511
+ }
512
+ } else {
513
+ results.push({
514
+ name: "retrieval/db-restore",
515
+ pass: true,
516
+ detail: "\u{1F7E2} No DB restore events on record"
517
+ });
518
+ }
519
+ } else {
520
+ results.push({
521
+ name: "retrieval/db-restore",
522
+ pass: true,
523
+ detail: "\u{1F7E2} No DB restore events on record"
524
+ });
525
+ }
526
+ } catch {
527
+ results.push({
528
+ name: "retrieval/db-restore",
529
+ pass: true,
530
+ detail: "\u{1F7E2} DB restore ledger not readable (no events assumed)"
531
+ });
532
+ }
533
+ return results;
534
+ }
391
535
  function runHealthCheck() {
392
536
  const pkgRoot = findPackageRoot();
393
537
  const results = [
@@ -397,7 +541,8 @@ function runHealthCheck() {
397
541
  ...checkWorkerSpawning(pkgRoot),
398
542
  ...checkMcpTransport(),
399
543
  ...checkClaudeCodeInstall(),
400
- ...checkCpuSteal()
544
+ ...checkCpuSteal(),
545
+ ...checkRetrievalHealth()
401
546
  ];
402
547
  const passed = results.filter((r) => r.pass).length;
403
548
  const failed = results.filter((r) => !r.pass).length;
@@ -423,5 +568,6 @@ export {
423
568
  detectAutoupdaterVar2 as detectAutoupdaterVar,
424
569
  checkClaudeCodeInstall,
425
570
  checkCpuSteal,
571
+ checkRetrievalHealth,
426
572
  runHealthCheck
427
573
  };
@@ -2,10 +2,10 @@ import {
2
2
  listWorkflowDefinitions,
3
3
  runWorkflow,
4
4
  startWorkflow
5
- } from "./chunk-RO7EXVSJ.js";
5
+ } from "./chunk-X4AFBL4N.js";
6
6
  import {
7
7
  ingest
8
- } from "./chunk-7I43GVER.js";
8
+ } from "./chunk-SOT23KWW.js";
9
9
  import {
10
10
  initCRMBridge
11
11
  } from "./chunk-ONKIWA3R.js";
@@ -2,7 +2,7 @@ import {
2
2
  connectEmbedDaemon,
3
3
  disconnectClient,
4
4
  embedViaClient
5
- } from "./chunk-TCJEFW5V.js";
5
+ } from "./chunk-PPXQE7AS.js";
6
6
  import {
7
7
  EMBEDDING_DIM
8
8
  } from "./chunk-FXU7JOXK.js";
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  sessionScopeFilter
3
- } from "./chunk-OVKNFTCL.js";
3
+ } from "./chunk-HED6D5KR.js";
4
4
  import {
5
5
  getClient,
6
6
  getIdentity
7
- } from "./chunk-P3SIFDES.js";
7
+ } from "./chunk-SCYWCWKY.js";
8
8
  import {
9
9
  getEmotionalBaseline
10
10
  } from "./chunk-PNQDP3OA.js";
@@ -643,7 +643,7 @@ var DreamingEngine = class {
643
643
  }
644
644
  let overdueProspective = [];
645
645
  try {
646
- const { getOverdueProspective, completeProspective } = await import("./prospective-memory-VNGLPMS6.js");
646
+ const { getOverdueProspective, completeProspective } = await import("./prospective-memory-FQSVMCGG.js");
647
647
  const overdue = await getOverdueProspective(agentId);
648
648
  overdueProspective = overdue.map((o) => ({
649
649
  id: o.id,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isCoordinatorRole
3
- } from "./chunk-P3SIFDES.js";
3
+ } from "./chunk-SCYWCWKY.js";
4
4
 
5
5
  // src/lib/task-router.ts
6
6
  import { randomUUID } from "crypto";
@@ -4,17 +4,17 @@ import {
4
4
  resolveExeSession,
5
5
  sendIntercom,
6
6
  strictSessionScopeFilter
7
- } from "./chunk-OVKNFTCL.js";
7
+ } from "./chunk-HED6D5KR.js";
8
8
  import {
9
9
  parseMessage,
10
10
  serializeMessage
11
11
  } from "./chunk-4JERP7NT.js";
12
12
  import {
13
13
  recordOrchestrationEventBestEffort
14
- } from "./chunk-WHOT5NZ7.js";
14
+ } from "./chunk-OR3TAZL3.js";
15
15
  import {
16
16
  getClient
17
- } from "./chunk-P3SIFDES.js";
17
+ } from "./chunk-SCYWCWKY.js";
18
18
 
19
19
  // src/lib/messaging.ts
20
20
  import crypto from "crypto";
@@ -1,6 +1,9 @@
1
+ import {
2
+ computeDaemonHeapCapMb
3
+ } from "./chunk-7XGDTKHX.js";
1
4
  import {
2
5
  resolveEmbeddingsEnabled
3
- } from "./chunk-RQUHAXMM.js";
6
+ } from "./chunk-PHFPIUWU.js";
4
7
  import {
5
8
  isMainModule
6
9
  } from "./chunk-6Y4B3QF6.js";
@@ -81,6 +84,13 @@ function mergeUserEnvVars(generatedPlist, existingPlist) {
81
84
  (_full, head, tail) => `${head}${injected}${tail}`
82
85
  );
83
86
  }
87
+ function enforceCanonicalHeapCap(generatedPlist) {
88
+ const canonical = computeDaemonHeapCapMb();
89
+ return generatedPlist.replace(
90
+ /--max-old-space-size=\d+/g,
91
+ `--max-old-space-size=${canonical}`
92
+ );
93
+ }
84
94
  function readExplicitEmbeddingsFromPlist(existingPlist) {
85
95
  if (!existingPlist) return null;
86
96
  const v = parseEnvVarsFromPlist(existingPlist).EXE_EMBEDDINGS;
@@ -179,6 +189,7 @@ function main() {
179
189
  } catch {
180
190
  }
181
191
  plist = mergeUserEnvVars(plist, existingPlist);
192
+ plist = enforceCanonicalHeapCap(plist);
182
193
  mkdirSync(LAUNCH_AGENTS_DIR, { recursive: true });
183
194
  writeFileSync(PLIST_DEST, plist);
184
195
  console.log(`Wrote ${PLIST_DEST}`);
@@ -219,7 +230,7 @@ function main() {
219
230
  if (registered) {
220
231
  console.log("Registered with launchd (bootstrap) \u2014 daemon will auto-restart on crash/exit.");
221
232
  } else {
222
- const heapFlag = plist.match(/--max-old-space-size=(\d+)/)?.[0] ?? "--max-old-space-size=4096";
233
+ const heapFlag = `--max-old-space-size=${computeDaemonHeapCapMb()}`;
223
234
  console.error(
224
235
  "ERROR: launchd registration FAILED (bug eba6d502 territory). The daemon is NOT registered for auto-restart."
225
236
  );
@@ -241,6 +252,7 @@ export {
241
252
  resolveAnthropicKeySystemdLine,
242
253
  parseEnvVarsFromPlist,
243
254
  mergeUserEnvVars,
255
+ enforceCanonicalHeapCap,
244
256
  readExplicitEmbeddingsFromPlist,
245
257
  persistEmbeddingsDecisionFromPlist
246
258
  };
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getClient
3
- } from "./chunk-P3SIFDES.js";
3
+ } from "./chunk-SCYWCWKY.js";
4
4
 
5
5
  // src/lib/token-spend.ts
6
6
  import { readdir, stat } from "fs/promises";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  sessionScopeFilter
3
- } from "./chunk-OVKNFTCL.js";
3
+ } from "./chunk-HED6D5KR.js";
4
4
 
5
5
  // src/lib/git-task-sweep.ts
6
6
  import { execSync } from "child_process";
@@ -178,7 +178,7 @@ async function sweepTasks(projectName, options = {}) {
178
178
  }
179
179
  if (!dryRun) {
180
180
  try {
181
- const { updateTaskStatus } = await import("./tasks-crud-HLJEJ2UU.js");
181
+ const { updateTaskStatus } = await import("./tasks-crud-24HMTULR.js");
182
182
  await updateTaskStatus({
183
183
  taskId: task.id,
184
184
  status: "needs_review",
@@ -5,15 +5,16 @@ import {
5
5
  import {
6
6
  attachDocumentMetadata,
7
7
  buildRawVisibilityFilter,
8
+ buildStatusFilter,
8
9
  buildWikiScopeFilter,
9
10
  searchMemories
10
- } from "./chunk-Y5ASPRP7.js";
11
+ } from "./chunk-WBJXJ2R4.js";
11
12
  import {
12
13
  blobToVector
13
14
  } from "./chunk-OTVEIJUQ.js";
14
15
  import {
15
16
  getClient
16
- } from "./chunk-P3SIFDES.js";
17
+ } from "./chunk-SCYWCWKY.js";
17
18
 
18
19
  // src/lib/hybrid-search.ts
19
20
  var RRF_K = 60;
@@ -150,8 +151,12 @@ async function graphSearch(query, agentId, options, limit) {
150
151
  }
151
152
  const entityIdArr = Array.from(allEntityIds);
152
153
  const placeholders = entityIdArr.map(() => "?").join(",");
153
- const statusFilter = options?.includeArchived ? "" : `
154
- AND COALESCE(m.status, 'active') = 'active'`;
154
+ const { statusClause: statusFilter } = buildStatusFilter(
155
+ options,
156
+ "m.",
157
+ "\n ",
158
+ { withDrafts: false }
159
+ );
155
160
  try {
156
161
  const memResult = await client.execute({
157
162
  sql: `SELECT DISTINCT m.id, m.agent_id, m.agent_role, m.session_id, m.timestamp,
@@ -348,7 +353,7 @@ async function hybridSearch(queryText, agentId, options) {
348
353
  let rerankerAvailable = false;
349
354
  if (process.env.EXE_IS_DAEMON === "1") {
350
355
  try {
351
- const { isRerankerAvailable } = await import("./reranker-6XBS55FA.js");
356
+ const { isRerankerAvailable } = await import("./reranker-AALRMGMM.js");
352
357
  rerankerAvailable = isRerankerAvailable();
353
358
  } catch {
354
359
  }
@@ -414,7 +419,7 @@ async function hybridSearch(queryText, agentId, options) {
414
419
  ]).catch(() => []),
415
420
  includeStructuredCards ? (async () => {
416
421
  try {
417
- const { searchMemoryCards } = await import("./memory-cards-BGI6MJRN.js");
422
+ const { searchMemoryCards } = await import("./memory-cards-II67WFL2.js");
418
423
  return await searchMemoryCards(effectiveQuery, agentId, fetchOptions);
419
424
  } catch {
420
425
  return [];
@@ -423,7 +428,7 @@ async function hybridSearch(queryText, agentId, options) {
423
428
  // Reflection insights: patterns, contradictions, summaries across sessions
424
429
  includeStructuredCards ? (async () => {
425
430
  try {
426
- const { searchReflections } = await import("./memory-reflection-UKKTGZYR.js");
431
+ const { searchReflections } = await import("./memory-reflection-PXF6YFDU.js");
427
432
  const insights = await searchReflections(effectiveQuery, agentId, 5, {
428
433
  includeArchived: options?.includeArchived
429
434
  });
@@ -524,7 +529,7 @@ async function hybridSearch(queryText, agentId, options) {
524
529
  let entityBoostRan = false;
525
530
  if (merged.length > 0) {
526
531
  try {
527
- const { applyEntityBoost } = await import("./entity-boost-SFHIRXT5.js");
532
+ const { applyEntityBoost } = await import("./entity-boost-NF3LE6OJ.js");
528
533
  const boosted = await applyEntityBoost(merged, effectiveQuery, getClient());
529
534
  merged = boosted.results;
530
535
  graphContextMap = boosted.graphContext;
@@ -548,7 +553,7 @@ async function hybridSearch(queryText, agentId, options) {
548
553
  try {
549
554
  let rerankedRecords;
550
555
  if (graphContextMap.size > 0) {
551
- const { rerankWithContext } = await import("./reranker-6XBS55FA.js");
556
+ const { rerankWithContext } = await import("./reranker-AALRMGMM.js");
552
557
  const candidates = merged.map((m) => ({
553
558
  text: m.raw_text,
554
559
  context: graphContextMap.get(m.id)
@@ -556,7 +561,7 @@ async function hybridSearch(queryText, agentId, options) {
556
561
  const scored = await rerankWithContext(effectiveQuery, candidates, rerankReturnLimit);
557
562
  rerankedRecords = scored.map((s) => merged[s.index]);
558
563
  } else {
559
- const { rerank } = await import("./reranker-6XBS55FA.js");
564
+ const { rerank } = await import("./reranker-AALRMGMM.js");
560
565
  rerankedRecords = await rerank(effectiveQuery, merged, rerankReturnLimit);
561
566
  }
562
567
  if (rerankedRecords.length > 0) {
@@ -918,7 +923,7 @@ async function lightweightSearch(queryText, agentId, options) {
918
923
  }
919
924
  if (results.length >= 2) {
920
925
  try {
921
- const { recordCoActivations } = await import("./co-activation-OKAHEMPE.js");
926
+ const { recordCoActivations } = await import("./co-activation-WN25AJOC.js");
922
927
  const ids = results.slice(0, 10).map((r) => r.id);
923
928
  void recordCoActivations(ids);
924
929
  } catch {
@@ -926,7 +931,7 @@ async function lightweightSearch(queryText, agentId, options) {
926
931
  }
927
932
  if (options?.includeStructuredCards !== true) return results;
928
933
  try {
929
- const { searchMemoryCards } = await import("./memory-cards-BGI6MJRN.js");
934
+ const { searchMemoryCards } = await import("./memory-cards-II67WFL2.js");
930
935
  const cardResults = await searchMemoryCards(queryText, agentId, options);
931
936
  if (cardResults.length > 0) {
932
937
  return rrfMergeMulti([results, cardResults], limit, RRF_K, [1, 0.85]);
@@ -936,10 +941,7 @@ async function lightweightSearch(queryText, agentId, options) {
936
941
  return results;
937
942
  }
938
943
  async function ftsQuery(client, matchExpr, agentId, options, limit) {
939
- const statusFilter = options?.includeArchived ? "" : `
940
- AND COALESCE(m.status, 'active') = 'active'`;
941
- const draftFilter = options?.includeDrafts ? "" : `
942
- AND (m.draft = 0 OR m.draft IS NULL)`;
944
+ const { statusClause: statusFilter, draftClause: draftFilter } = buildStatusFilter(options, "m.", "\n ");
943
945
  let sql = `SELECT m.id, m.agent_id, m.agent_role, m.session_id, m.timestamp,
944
946
  m.tool_name, m.project_name,
945
947
  m.has_error, m.raw_text, m.vector, m.task_id,
@@ -1083,10 +1085,7 @@ async function recentRecords(agentId, options, limit, textFilter) {
1083
1085
  }
1084
1086
  } catch {
1085
1087
  }
1086
- const statusFilter = options?.includeArchived ? "" : `
1087
- AND COALESCE(status, 'active') = 'active'`;
1088
- const draftFilter = options?.includeDrafts ? "" : `
1089
- AND (draft = 0 OR draft IS NULL)`;
1088
+ const { statusClause: statusFilter, draftClause: draftFilter } = buildStatusFilter(options, "", "\n ");
1090
1089
  let sql = `SELECT id, agent_id, agent_role, session_id, timestamp,
1091
1090
  tool_name, project_name,
1092
1091
  has_error, raw_text, vector, task_id,
@@ -1277,10 +1276,7 @@ async function trajectoryBypass(queryText, agentId, options, limit) {
1277
1276
  if (!toolName) return null;
1278
1277
  try {
1279
1278
  const client = getClient();
1280
- const statusFilter = options?.includeArchived ? "" : `
1281
- AND COALESCE(status, 'active') = 'active'`;
1282
- const draftFilter = options?.includeDrafts ? "" : `
1283
- AND (draft = 0 OR draft IS NULL)`;
1279
+ const { statusClause: statusFilter, draftClause: draftFilter } = buildStatusFilter(options, "", "\n ");
1284
1280
  let sql = `SELECT id, agent_id, agent_role, session_id, timestamp,
1285
1281
  tool_name, project_name,
1286
1282
  has_error, raw_text, vector, task_id,
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  recordSessionKill
3
- } from "./chunk-D6UICP3C.js";
3
+ } from "./chunk-LMX7UKGX.js";
4
4
  import {
5
5
  updateTask
6
- } from "./chunk-GSWGOGP5.js";
6
+ } from "./chunk-EOS7VPVT.js";
7
7
  import {
8
8
  ensureEmployeeAsync,
9
9
  extractRootExe,
@@ -14,7 +14,7 @@ import {
14
14
  sessionScopeFilter,
15
15
  strictSessionScopeFilter,
16
16
  writeNotification
17
- } from "./chunk-OVKNFTCL.js";
17
+ } from "./chunk-HED6D5KR.js";
18
18
  import {
19
19
  queueIntercom
20
20
  } from "./chunk-4FVVJ7ME.js";
@@ -23,17 +23,17 @@ import {
23
23
  } from "./chunk-E23LNUWJ.js";
24
24
  import {
25
25
  listSessions
26
- } from "./chunk-2LJDLQNO.js";
27
- import {
28
- getTransport
29
- } from "./chunk-KOO3J5PV.js";
26
+ } from "./chunk-WJ2PZGRV.js";
30
27
  import {
31
28
  listTmuxSessions,
32
29
  parseContextPercentage
33
30
  } from "./chunk-SSTLTIF3.js";
31
+ import {
32
+ getTransport
33
+ } from "./chunk-KOO3J5PV.js";
34
34
  import {
35
35
  recordOrchestrationEventBestEffort
36
- } from "./chunk-WHOT5NZ7.js";
36
+ } from "./chunk-OR3TAZL3.js";
37
37
  import {
38
38
  getAgentRuntime
39
39
  } from "./chunk-QB5JOGPK.js";
@@ -42,7 +42,7 @@ import {
42
42
  getCoordinatorName,
43
43
  isCoordinatorName,
44
44
  shouldAutoInstance
45
- } from "./chunk-P3SIFDES.js";
45
+ } from "./chunk-SCYWCWKY.js";
46
46
  import {
47
47
  loadConfigSync
48
48
  } from "./chunk-DFIOOK5R.js";
@@ -1900,7 +1900,7 @@ async function reapOrphanedWorktrees(deps, nowMs = Date.now()) {
1900
1900
  }
1901
1901
  async function createWorktreeReaperRealDeps() {
1902
1902
  const { getPaneCwdAsync } = await import("./lib/tmux-status.js");
1903
- const { getGitRoot, isWorktreeDirty: isDirty } = await import("./worktree-XISIYRM4.js");
1903
+ const { getGitRoot, isWorktreeDirty: isDirty } = await import("./worktree-2CXY6NEB.js");
1904
1904
  const { statSync: statSync3 } = await import("fs");
1905
1905
  const { basename } = await import("path");
1906
1906
  const { promisify: promisify2 } = await import("util");
@@ -2084,7 +2084,7 @@ async function gcStaleCheckpoints() {
2084
2084
  }
2085
2085
  async function pollTaskGroupBarriers() {
2086
2086
  try {
2087
- const { checkAndFireBarriers } = await import("./tasks-crud-HLJEJ2UU.js");
2087
+ const { checkAndFireBarriers } = await import("./tasks-crud-24HMTULR.js");
2088
2088
  const firedGroupIds = await checkAndFireBarriers();
2089
2089
  if (firedGroupIds.length === 0) return 0;
2090
2090
  const { getClient } = await import("./lib/database.js");