@elizaos/agent 2.0.3-beta.2 → 2.0.3-beta.3

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 (381) hide show
  1. package/__tests__/view-user-journeys.d.ts.map +1 -1
  2. package/__tests__/view-user-journeys.js +52 -41
  3. package/actions/context-signal.d.ts +2 -2
  4. package/actions/files.d.ts +9 -0
  5. package/actions/files.d.ts.map +1 -0
  6. package/actions/files.js +183 -0
  7. package/actions/index.d.ts +17 -17
  8. package/api/accounts-routes.d.ts +1 -1
  9. package/api/accounts-routes.js +1 -1
  10. package/api/agent-admin-routes.d.ts +1 -1
  11. package/api/agent-admin-routes.js +2 -2
  12. package/api/agent-model.d.ts +1 -1
  13. package/api/agent-status-routes.d.ts +1 -3
  14. package/api/agent-status-routes.d.ts.map +1 -1
  15. package/api/agent-status-routes.js +0 -2
  16. package/api/approval-routes.d.ts +38 -0
  17. package/api/approval-routes.d.ts.map +1 -0
  18. package/api/approval-routes.js +223 -0
  19. package/api/background-routes.d.ts +13 -0
  20. package/api/background-routes.d.ts.map +1 -0
  21. package/api/background-routes.js +91 -0
  22. package/api/binance-skill-helpers.d.ts +2 -2
  23. package/api/binance-skill-helpers.js +2 -2
  24. package/api/builtin-views.d.ts.map +1 -1
  25. package/api/builtin-views.js +44 -4
  26. package/api/character-routes.d.ts +1 -1
  27. package/api/chat-augmentation.d.ts.map +1 -1
  28. package/api/chat-augmentation.js +17 -0
  29. package/api/chat-routes.d.ts +29 -2
  30. package/api/chat-routes.d.ts.map +1 -1
  31. package/api/chat-routes.js +76 -1
  32. package/api/commands-routes.d.ts +10 -8
  33. package/api/commands-routes.d.ts.map +1 -1
  34. package/api/commands-routes.js +17 -59
  35. package/api/config-routes.d.ts +1 -1
  36. package/api/config-routes.d.ts.map +1 -1
  37. package/api/config-routes.js +0 -2
  38. package/api/connector-routes.d.ts +1 -1
  39. package/api/conversation-metadata.d.ts +1 -1
  40. package/api/conversation-metadata.d.ts.map +1 -1
  41. package/api/conversation-metadata.js +0 -1
  42. package/api/conversation-routes.d.ts +4 -3
  43. package/api/conversation-routes.d.ts.map +1 -1
  44. package/api/conversation-routes.js +34 -1
  45. package/api/documents-service-loader.d.ts +0 -4
  46. package/api/documents-service-loader.d.ts.map +1 -1
  47. package/api/documents-service-loader.js +0 -2
  48. package/api/files-routes.d.ts +14 -0
  49. package/api/files-routes.d.ts.map +1 -0
  50. package/api/files-routes.js +47 -0
  51. package/api/first-run-routes.d.ts +1 -1
  52. package/api/health-routes.d.ts +2 -2
  53. package/api/index.d.ts +40 -39
  54. package/api/index.d.ts.map +1 -1
  55. package/api/index.js +1 -0
  56. package/api/interactions-routes.d.ts +33 -0
  57. package/api/interactions-routes.d.ts.map +1 -0
  58. package/api/interactions-routes.js +63 -0
  59. package/api/media-runtime.d.ts +2 -1
  60. package/api/media-runtime.d.ts.map +1 -1
  61. package/api/media-runtime.js +64 -7
  62. package/api/media-store.d.ts +36 -0
  63. package/api/media-store.d.ts.map +1 -1
  64. package/api/media-store.js +141 -2
  65. package/api/memory-bounds.d.ts +0 -1
  66. package/api/memory-bounds.d.ts.map +1 -1
  67. package/api/memory-bounds.js +0 -1
  68. package/api/misc-routes.d.ts +1 -1
  69. package/api/model-provider-helpers.d.ts +2 -2
  70. package/api/model-provider-helpers.js +2 -2
  71. package/api/permissions-routes-extra.d.ts +1 -1
  72. package/api/permissions-routes.d.ts +1 -1
  73. package/api/permissions-routes.d.ts.map +1 -1
  74. package/api/permissions-routes.js +8 -7
  75. package/api/plugin-discovery-helpers.d.ts +5 -6
  76. package/api/plugin-discovery-helpers.d.ts.map +1 -1
  77. package/api/plugin-discovery-helpers.js +3 -4
  78. package/api/plugin-runtime-apply.d.ts +2 -2
  79. package/api/plugin-runtime-apply.d.ts.map +1 -1
  80. package/api/plugin-runtime-apply.js +74 -0
  81. package/api/provider-switch-config.d.ts +1 -1
  82. package/api/provider-switch-routes.d.ts +2 -2
  83. package/api/registry-routes.d.ts +1 -1
  84. package/api/registry-service.d.ts +1 -1
  85. package/api/remote-capability-routes.d.ts +2 -2
  86. package/api/remote-capability-routes.d.ts.map +1 -1
  87. package/api/remote-capability-routes.js +19 -0
  88. package/api/server-autonomy-helpers.d.ts +2 -2
  89. package/api/server-helpers-auth.d.ts +10 -0
  90. package/api/server-helpers-auth.d.ts.map +1 -1
  91. package/api/server-helpers-auth.js +16 -210
  92. package/api/server-helpers-config.d.ts +1 -1
  93. package/api/server-helpers-mcp.d.ts +2 -2
  94. package/api/server-helpers-plugin.d.ts +1 -1
  95. package/api/server-helpers-swarm.d.ts +3 -3
  96. package/api/server-helpers-swarm.d.ts.map +1 -1
  97. package/api/server-helpers-swarm.js +15 -5
  98. package/api/server-helpers-wallet.d.ts +1 -1
  99. package/api/server-helpers.d.ts +4 -4
  100. package/api/server-lazy-routes.d.ts +40 -38
  101. package/api/server-lazy-routes.d.ts.map +1 -1
  102. package/api/server-lazy-routes.js +7 -0
  103. package/api/server-route-dispatch.d.ts +2 -2
  104. package/api/server-route-dispatch.d.ts.map +1 -1
  105. package/api/server-route-dispatch.js +7 -0
  106. package/api/server-types.d.ts +9 -7
  107. package/api/server-types.d.ts.map +1 -1
  108. package/api/server.d.ts +19 -19
  109. package/api/server.d.ts.map +1 -1
  110. package/api/server.js +111 -17
  111. package/api/static-file-server.d.ts +2 -2
  112. package/api/static-file-server.js +2 -2
  113. package/api/subscription-routes.d.ts +4 -4
  114. package/api/subscription-routes.js +3 -4
  115. package/api/suggestions-routes.d.ts +1 -1
  116. package/api/suggestions-routes.d.ts.map +1 -1
  117. package/api/suggestions-routes.js +2 -3
  118. package/api/terminal-execution-routing.d.ts +1 -1
  119. package/api/training-service-like.d.ts +1 -1
  120. package/api/trajectory-fallback-routes.d.ts.map +1 -1
  121. package/api/trajectory-fallback-routes.js +21 -1
  122. package/api/update-routes.d.ts +1 -1
  123. package/api/view-registry-types.d.ts +1 -1
  124. package/api/views-registry.d.ts +14 -4
  125. package/api/views-registry.d.ts.map +1 -1
  126. package/api/views-registry.js +50 -26
  127. package/api/views-routes.d.ts +1 -1
  128. package/api/views-routes.d.ts.map +1 -1
  129. package/api/views-routes.js +131 -14
  130. package/api/views-search-index.d.ts +1 -1
  131. package/api/wallet-capability.d.ts +3 -3
  132. package/api/wallet-rpc.d.ts +1 -1
  133. package/api/wallet.d.ts +3 -3
  134. package/api/wallet.d.ts.map +1 -1
  135. package/api/wallet.js +4 -3
  136. package/api/workbench-context.d.ts +1 -1
  137. package/api/workbench-helpers.d.ts +3 -3
  138. package/api/workbench-helpers.js +3 -3
  139. package/api/workbench-routes.d.ts +2 -2
  140. package/api/workbench-vfs-routes.d.ts +1 -1
  141. package/api/ws-event-replay.d.ts +1 -2
  142. package/api/ws-event-replay.d.ts.map +1 -1
  143. package/api/ws-event-replay.js +1 -2
  144. package/api/x-relay-routes.d.ts +2 -2
  145. package/api/x402-route-validation.d.ts +4 -0
  146. package/api/x402-route-validation.d.ts.map +1 -0
  147. package/api/x402-route-validation.js +6 -0
  148. package/assets/view-heroes/background.png +0 -0
  149. package/auth/account-storage.d.ts +1 -1
  150. package/auth/anthropic.d.ts +1 -1
  151. package/auth/credentials.d.ts +2 -2
  152. package/auth/index.d.ts +7 -7
  153. package/auth/oauth-flow.d.ts +2 -2
  154. package/auth/openai-codex.d.ts +1 -1
  155. package/awareness/index.d.ts +1 -1
  156. package/config/config.js +0 -1
  157. package/config/env-vars.d.ts +1 -1
  158. package/config/env-vars.d.ts.map +1 -1
  159. package/config/env-vars.js +0 -1
  160. package/config/index.d.ts +10 -10
  161. package/config/model-metadata.d.ts +1 -1
  162. package/config/owner-contacts.d.ts +1 -1
  163. package/config/schema.d.ts +1 -1
  164. package/hooks/discovery.d.ts +1 -1
  165. package/hooks/eligibility.d.ts +2 -2
  166. package/hooks/index.d.ts +2 -2
  167. package/hooks/loader.d.ts +2 -2
  168. package/hooks/registry.d.ts +1 -1
  169. package/index.d.ts +87 -85
  170. package/index.d.ts.map +1 -1
  171. package/index.js +11 -3
  172. package/package.json +54 -44
  173. package/providers/media-provider.d.ts +1 -1
  174. package/providers/page-scoped-context.d.ts.map +1 -1
  175. package/providers/page-scoped-context.js +1 -70
  176. package/providers/relevant-conversations.d.ts.map +1 -1
  177. package/providers/relevant-conversations.js +8 -9
  178. package/providers/workspace.d.ts +1 -1
  179. package/runtime/actions/web-fetch.d.ts.map +1 -1
  180. package/runtime/actions/web-fetch.js +23 -3
  181. package/runtime/actions/web-search.d.ts +32 -0
  182. package/runtime/actions/web-search.d.ts.map +1 -0
  183. package/runtime/actions/web-search.js +245 -0
  184. package/runtime/advanced-capabilities-config.d.ts +1 -1
  185. package/runtime/boot-telemetry.d.ts +1 -1
  186. package/runtime/conversation-compactor-runtime.d.ts +1 -1
  187. package/runtime/conversation-compactor-runtime.js +1 -1
  188. package/runtime/conversation-compactor.d.ts +1 -1
  189. package/runtime/core-plugins.d.ts.map +1 -1
  190. package/runtime/core-plugins.js +9 -0
  191. package/runtime/custom-actions.d.ts +18 -9
  192. package/runtime/custom-actions.d.ts.map +1 -1
  193. package/runtime/custom-actions.js +85 -23
  194. package/runtime/eliza-plugin.d.ts.map +1 -1
  195. package/runtime/eliza-plugin.js +15 -1
  196. package/runtime/eliza.d.ts +9 -7
  197. package/runtime/eliza.d.ts.map +1 -1
  198. package/runtime/eliza.js +86 -23
  199. package/runtime/first-time-setup.d.ts +1 -3
  200. package/runtime/first-time-setup.d.ts.map +1 -1
  201. package/runtime/first-time-setup.js +0 -2
  202. package/runtime/index.d.ts +18 -18
  203. package/runtime/load-plugin-from-vfs.d.ts +2 -2
  204. package/runtime/mobile-dns.d.ts.map +1 -1
  205. package/runtime/mobile-dns.js +2 -5
  206. package/runtime/operations/classifier.d.ts +1 -1
  207. package/runtime/operations/cold-strategy.d.ts +1 -1
  208. package/runtime/operations/health-checks.d.ts +1 -1
  209. package/runtime/operations/health.d.ts +1 -1
  210. package/runtime/operations/index.d.ts +10 -10
  211. package/runtime/operations/manager.d.ts +3 -3
  212. package/runtime/operations/reload-hot.d.ts +1 -1
  213. package/runtime/operations/repository.d.ts +1 -1
  214. package/runtime/operations/vault-bridge.d.ts +1 -1
  215. package/runtime/plugin-collector.d.ts +6 -1
  216. package/runtime/plugin-collector.d.ts.map +1 -1
  217. package/runtime/plugin-collector.js +11 -28
  218. package/runtime/plugin-lifecycle.d.ts.map +1 -1
  219. package/runtime/plugin-lifecycle.js +1 -0
  220. package/runtime/plugin-resolver.d.ts +2 -2
  221. package/runtime/plugin-resolver.d.ts.map +1 -1
  222. package/runtime/plugin-resolver.js +113 -65
  223. package/runtime/plugin-types.d.ts +1 -1
  224. package/runtime/prompt-optimization.d.ts +4 -4
  225. package/runtime/remote-coding-runner-gate.d.ts +7 -0
  226. package/runtime/remote-coding-runner-gate.d.ts.map +1 -0
  227. package/runtime/remote-coding-runner-gate.js +36 -0
  228. package/runtime/roles/src/index.d.ts +4 -4
  229. package/runtime/roles.d.ts +2 -2
  230. package/runtime/sandbox-character.d.ts +1 -1
  231. package/runtime/tool-call-cache/cache.d.ts +1 -1
  232. package/runtime/tool-call-cache/disk-store.d.ts +1 -1
  233. package/runtime/tool-call-cache/index.d.ts +6 -6
  234. package/runtime/tool-call-cache/key.d.ts +1 -1
  235. package/runtime/tool-call-cache/redact.d.ts +1 -1
  236. package/runtime/tool-call-cache/registry.d.ts +1 -1
  237. package/runtime/tool-call-cache-wrapper.d.ts +7 -9
  238. package/runtime/tool-call-cache-wrapper.d.ts.map +1 -1
  239. package/runtime/tool-call-cache-wrapper.js +6 -11
  240. package/runtime/trajectory-export.d.ts +3 -3
  241. package/runtime/trajectory-internals.d.ts +2 -1
  242. package/runtime/trajectory-internals.d.ts.map +1 -1
  243. package/runtime/trajectory-persistence.d.ts +5 -5
  244. package/runtime/trajectory-steps-reader.d.ts +1 -1
  245. package/runtime/trajectory-steps-writer.d.ts +1 -1
  246. package/runtime/trajectory-storage.d.ts +4 -4
  247. package/runtime/view-action-affinity.d.ts +18 -15
  248. package/runtime/view-action-affinity.d.ts.map +1 -1
  249. package/runtime/view-action-affinity.js +26 -29
  250. package/runtime/web-search-tools.d.ts +4 -1
  251. package/runtime/web-search-tools.d.ts.map +1 -1
  252. package/runtime/web-search-tools.js +37 -9
  253. package/security/index.d.ts +3 -3
  254. package/services/approval/index.d.ts +9 -0
  255. package/services/approval/index.d.ts.map +1 -0
  256. package/services/approval/index.js +8 -0
  257. package/services/approval/service.d.ts +35 -0
  258. package/services/approval/service.d.ts.map +1 -0
  259. package/services/approval/service.js +40 -0
  260. package/services/approval/sql.d.ts +18 -0
  261. package/services/approval/sql.d.ts.map +1 -0
  262. package/services/approval/sql.js +104 -0
  263. package/services/approval/store.d.ts +39 -0
  264. package/services/approval/store.d.ts.map +1 -0
  265. package/services/approval/store.js +534 -0
  266. package/services/approval/types.d.ts +207 -0
  267. package/services/approval/types.d.ts.map +1 -0
  268. package/services/approval/types.js +34 -0
  269. package/services/character-persistence.d.ts +2 -2
  270. package/services/client-chat-sender.d.ts +1 -1
  271. package/services/config-plugin-manager.d.ts +2 -2
  272. package/services/connector-setup-service.d.ts +1 -1
  273. package/services/cove-quote-x509.d.ts +1 -1
  274. package/services/cove-quote.d.ts +2 -2
  275. package/services/dstack-tee-provider.d.ts +1 -1
  276. package/services/file-storage.d.ts +20 -0
  277. package/services/file-storage.d.ts.map +1 -0
  278. package/services/file-storage.js +70 -0
  279. package/services/global-pause/index.d.ts +8 -0
  280. package/services/global-pause/index.d.ts.map +1 -0
  281. package/services/global-pause/index.js +7 -0
  282. package/services/global-pause/service.d.ts +29 -0
  283. package/services/global-pause/service.d.ts.map +1 -0
  284. package/services/global-pause/service.js +34 -0
  285. package/services/global-pause/store.d.ts +31 -0
  286. package/services/global-pause/store.d.ts.map +1 -0
  287. package/services/global-pause/store.js +83 -0
  288. package/services/handoff/index.d.ts +8 -0
  289. package/services/handoff/index.d.ts.map +1 -0
  290. package/services/handoff/index.js +7 -0
  291. package/services/handoff/service.d.ts +29 -0
  292. package/services/handoff/service.d.ts.map +1 -0
  293. package/services/handoff/service.js +34 -0
  294. package/services/handoff/store.d.ts +76 -0
  295. package/services/handoff/store.d.ts.map +1 -0
  296. package/services/handoff/store.js +148 -0
  297. package/services/index.d.ts +30 -31
  298. package/services/index.d.ts.map +1 -1
  299. package/services/index.js +0 -6
  300. package/services/js-runtime-bridge.d.ts.map +1 -1
  301. package/services/js-runtime-bridge.js +8 -2
  302. package/services/knowledge-graph/index.d.ts +4 -4
  303. package/services/knowledge-graph/service.d.ts +2 -2
  304. package/services/pending-prompts/index.d.ts +8 -0
  305. package/services/pending-prompts/index.d.ts.map +1 -0
  306. package/services/pending-prompts/index.js +7 -0
  307. package/services/pending-prompts/service.d.ts +34 -0
  308. package/services/pending-prompts/service.d.ts.map +1 -0
  309. package/services/pending-prompts/service.js +68 -0
  310. package/services/pending-prompts/store.d.ts +70 -0
  311. package/services/pending-prompts/store.d.ts.map +1 -0
  312. package/services/pending-prompts/store.js +191 -0
  313. package/services/plugin-compiler.d.ts +1 -1
  314. package/services/plugin-installer.d.ts.map +1 -1
  315. package/services/plugin-installer.js +21 -11
  316. package/services/plugin-manager-types.d.ts +1 -1
  317. package/services/proactive-interaction-decider.d.ts +62 -11
  318. package/services/proactive-interaction-decider.d.ts.map +1 -1
  319. package/services/proactive-interaction-decider.js +223 -35
  320. package/services/push/apns-provider.d.ts +1 -1
  321. package/services/push/fcm-provider.d.ts +1 -1
  322. package/services/push/notification-push-service.d.ts +2 -2
  323. package/services/registry-client-app-meta.d.ts +1 -1
  324. package/services/registry-client-endpoints.d.ts +2 -2
  325. package/services/registry-client-local.d.ts +1 -1
  326. package/services/registry-client-network.d.ts +1 -1
  327. package/services/registry-client-queries.d.ts +1 -1
  328. package/services/registry-client.d.ts +3 -3
  329. package/services/relationships-graph.d.ts +1 -1
  330. package/services/remote-capability-cloud-sandbox.d.ts +3 -3
  331. package/services/remote-capability-endpoint-conformance.d.ts +1 -1
  332. package/services/remote-capability-endpoint-provider.d.ts +4 -4
  333. package/services/remote-capability-url-endpoint-providers.d.ts +1 -1
  334. package/services/remote-plugin-adapter.d.ts.map +1 -1
  335. package/services/remote-plugin-adapter.js +3 -0
  336. package/services/remote-plugin-bridge.d.ts.map +1 -1
  337. package/services/remote-plugin-bridge.js +97 -26
  338. package/services/remote-signing-service.d.ts +4 -4
  339. package/services/research-task-executor.d.ts +1 -1
  340. package/services/sandbox-manager.d.ts +1 -1
  341. package/services/self-updater.d.ts +1 -1
  342. package/services/self-updater.d.ts.map +1 -1
  343. package/services/self-updater.js +23 -9
  344. package/services/shell-execution-router.d.ts +1 -1
  345. package/services/shell-execution-router.d.ts.map +1 -1
  346. package/services/shell-execution-router.js +19 -2
  347. package/services/tee-boot-gate-state.d.ts +1 -1
  348. package/services/tee-boot-gate.d.ts +4 -4
  349. package/services/tee-confidential-inference.d.ts +3 -3
  350. package/services/tee-key-release.d.ts +2 -2
  351. package/services/tee-model-key-boot.d.ts +4 -4
  352. package/services/tee-policy.d.ts +1 -1
  353. package/services/tee-production-profile.d.ts +1 -1
  354. package/services/tee-release-policy.d.ts +1 -1
  355. package/services/tee-revocation.d.ts +2 -2
  356. package/services/tee-runtime-config.d.ts +1 -1
  357. package/services/tee-sealed-volume.d.ts +3 -3
  358. package/services/tee-signer-backend.d.ts +3 -3
  359. package/services/update-checker.d.ts +1 -1
  360. package/services/vault-signer-backend.d.ts +1 -1
  361. package/services/vfs-git.d.ts +1 -1
  362. package/test-support/index.d.ts +3 -3
  363. package/triggers/runtime.d.ts +1 -1
  364. package/triggers/scheduling.d.ts +3 -22
  365. package/triggers/scheduling.d.ts.map +1 -1
  366. package/triggers/scheduling.js +2 -214
  367. package/tui/agent-terminal-tui.d.ts.map +1 -1
  368. package/tui/agent-terminal-tui.js +174 -72
  369. package/types/index.d.ts +3 -3
  370. package/api/nfa-routes.d.ts +0 -6
  371. package/api/nfa-routes.d.ts.map +0 -1
  372. package/api/nfa-routes.js +0 -125
  373. package/api/server-auth.d.ts +0 -46
  374. package/api/server-auth.d.ts.map +0 -1
  375. package/api/server-auth.js +0 -504
  376. package/runtime/restart.d.ts +0 -9
  377. package/runtime/restart.d.ts.map +0 -1
  378. package/runtime/restart.js +0 -8
  379. package/test-utils/sqlite-compat.d.ts +0 -23
  380. package/test-utils/sqlite-compat.d.ts.map +0 -1
  381. package/test-utils/sqlite-compat.js +0 -214
@@ -8,12 +8,13 @@
8
8
  * added each package is recorded so `resolvePlugins` (`plugin-resolver.ts`)
9
9
  * can explain optional load failures (config vs env vs feature flag).
10
10
  *
11
- * Extracted from eliza.ts to reduce file size.
12
- *
13
11
  * @module plugin-collector
14
12
  */
15
13
  import { existsSync } from "node:fs";
16
14
  import path from "node:path";
15
+ import channelPluginMap from "@elizaos/registry/first-party/channel-plugin-map.json" with {
16
+ type: "json"
17
+ };
17
18
  import { hasExplicitCanonicalRuntimeConfig, isAndroidMobile, isMobilePlatform, migrateLegacyRuntimeConfig, resolveDeploymentTargetInConfig, resolveElizaCloudTopology, resolveServiceRoutingInConfig, } from "@elizaos/shared";
18
19
  import { CORE_PLUGINS, ELIZAOS_ANDROID_CORE_PLUGINS, ELIZAOS_ANDROID_TERMINAL_PLUGINS, LEAN_CHAT_EXCLUDED_PLUGINS, LEAN_CHAT_PLUGINS, MOBILE_CORE_PLUGINS, MOBILE_VIEW_PLUGINS, OPTIONAL_CORE_PLUGINS, } from "./core-plugins.js";
19
20
  const OPTIONAL_CORE_PLUGIN_NAMES = new Set(OPTIONAL_CORE_PLUGINS);
@@ -119,36 +120,18 @@ function isStoreBuildVariant() {
119
120
  process.env.ELIZA_BUILD_VARIANT?.trim();
120
121
  return raw?.toLowerCase() === "store";
121
122
  }
122
- /** Maps Eliza channel names to plugin package names. */
123
- export const CHANNEL_PLUGIN_MAP = {
124
- bluebubbles: "@elizaos/plugin-bluebubbles",
125
- discord: "@elizaos/plugin-discord",
126
- discordLocal: "@elizaos/plugin-discord-local",
127
- telegram: "@elizaos/plugin-telegram",
128
- slack: "@elizaos/plugin-slack",
129
- x: "@elizaos/plugin-x",
130
- // Backward-compat alias: legacy "twitter" channel resolves to plugin-x.
131
- twitter: "@elizaos/plugin-x",
132
- // Internal connector built from src/plugins/whatsapp (not an npm package).
133
- whatsapp: "@elizaos/plugin-whatsapp",
134
- // Internal connector built from src/plugins/signal (not an npm package).
135
- signal: "@elizaos/plugin-signal",
136
- imessage: "@elizaos/plugin-imessage",
137
- farcaster: "@elizaos/plugin-farcaster",
138
- lens: "@elizaos/plugin-lens",
139
- msteams: "@elizaos/plugin-msteams",
140
- feishu: "@elizaos/plugin-feishu",
141
- matrix: "@elizaos/plugin-matrix",
142
- nostr: "@elizaos/plugin-nostr",
143
- blooio: "@elizaos/plugin-blooio",
144
- twitch: "@elizaos/plugin-twitch",
145
- mattermost: "@elizaos/plugin-mattermost",
146
- googlechat: "@elizaos/plugin-google-chat",
147
- };
123
+ /**
124
+ * Maps Eliza channel names to plugin package names. Derived at registry build
125
+ * time from each connector entry's `channels` (e.g. x -> ["x", "twitter"]); see
126
+ * packages/registry/src/first-party. To add/rename a channel, edit the owning
127
+ * connector's registry-entry.json `channels` and regenerate — not this list.
128
+ */
129
+ export const CHANNEL_PLUGIN_MAP = channelPluginMap;
148
130
  /** Maps environment variable names to model-provider plugin packages. */
149
131
  export const PROVIDER_PLUGIN_MAP = {
150
132
  ANTHROPIC_API_KEY: "@elizaos/plugin-anthropic",
151
133
  OPENAI_API_KEY: "@elizaos/plugin-openai",
134
+ CEREBRAS_API_KEY: "@elizaos/plugin-openai",
152
135
  GEMINI_API_KEY: "@elizaos/plugin-google-genai",
153
136
  GOOGLE_API_KEY: "@elizaos/plugin-google-genai",
154
137
  GOOGLE_GENERATIVE_AI_API_KEY: "@elizaos/plugin-google-genai",
@@ -1 +1 @@
1
- {"version":3,"file":"plugin-lifecycle.d.ts","sourceRoot":"","sources":["../../src/runtime/plugin-lifecycle.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,YAAY,EACZ,MAAM,EAGN,eAAe,EAIhB,MAAM,eAAe,CAAC;AAwEvB,MAAM,MAAM,sBAAsB,GAAG,eAAe,CAAC;AAErD,KAAK,0BAA0B,GAAG,YAAY,GAAG;IAC/C,+BAA+B,CAAC,EAAE,OAAO,CAAC;IAC1C,8BAA8B,CAAC,EAAE,OAAO,CAAC;IACzC,sBAAsB,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,sBAAsB,CAAC,CAAC;IAC7D,YAAY,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,sBAAsB,GAAG,IAAI,CAAC,CAAC;IAC9E,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACjD,iBAAiB,CAAC,EAAE,CAClB,UAAU,EAAE,MAAM,EAClB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAC3B,OAAO,CAAC,OAAO,CAAC,CAAC;IACtB,kBAAkB,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,sBAAsB,GAAG,IAAI,CAAC;IAC3E,qBAAqB,CAAC,EAAE,MAAM,sBAAsB,EAAE,CAAC;CACxD,CAAC;AAijBF,wBAAgB,6BAA6B,CAAC,OAAO,EAAE,YAAY,GAAG,IAAI,CAwTzE;AAED,wBAAgB,8BAA8B,CAC5C,OAAO,EAAE,YAAY,GAAG,IAAI,GAC3B,OAAO,IAAI,0BAA0B,CAUvC"}
1
+ {"version":3,"file":"plugin-lifecycle.d.ts","sourceRoot":"","sources":["../../src/runtime/plugin-lifecycle.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,YAAY,EACZ,MAAM,EAGN,eAAe,EAIhB,MAAM,eAAe,CAAC;AAwEvB,MAAM,MAAM,sBAAsB,GAAG,eAAe,CAAC;AAErD,KAAK,0BAA0B,GAAG,YAAY,GAAG;IAC/C,+BAA+B,CAAC,EAAE,OAAO,CAAC;IAC1C,8BAA8B,CAAC,EAAE,OAAO,CAAC;IACzC,sBAAsB,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,sBAAsB,CAAC,CAAC;IAC7D,YAAY,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,sBAAsB,GAAG,IAAI,CAAC,CAAC;IAC9E,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACjD,iBAAiB,CAAC,EAAE,CAClB,UAAU,EAAE,MAAM,EAClB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAC3B,OAAO,CAAC,OAAO,CAAC,CAAC;IACtB,kBAAkB,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,sBAAsB,GAAG,IAAI,CAAC;IAC3E,qBAAqB,CAAC,EAAE,MAAM,sBAAsB,EAAE,CAAC;CACxD,CAAC;AAkjBF,wBAAgB,6BAA6B,CAAC,OAAO,EAAE,YAAY,GAAG,IAAI,CAwTzE;AAED,wBAAgB,8BAA8B,CAC5C,OAAO,EAAE,YAAY,GAAG,IAAI,GAC3B,OAAO,IAAI,0BAA0B,CAUvC"}
@@ -98,6 +98,7 @@ function createEmptyOwnership(plugin) {
98
98
  events: [],
99
99
  models: [],
100
100
  services: [],
101
+ shortcuts: [],
101
102
  sendHandlerSources: [],
102
103
  hasAdapter: false,
103
104
  registeredAt: Date.now(),
@@ -1,5 +1,5 @@
1
- import { type ElizaConfig } from "../config/config.ts";
2
- import { type PluginModuleShape, type ResolvedPlugin } from "./plugin-types.ts";
1
+ import { type ElizaConfig } from "../config/config.js";
2
+ import { type PluginModuleShape, type ResolvedPlugin } from "./plugin-types.js";
3
3
  export declare function resolveRuntimePluginImportSpecifier(pluginName: string): string;
4
4
  /**
5
5
  * Import a plugin module from its install directory on disk.
@@ -1 +1 @@
1
- {"version":3,"file":"plugin-resolver.d.ts","sourceRoot":"","sources":["../../src/runtime/plugin-resolver.ts"],"names":[],"mappings":"AAgCA,OAAO,EAAE,KAAK,WAAW,EAAmB,MAAM,qBAAqB,CAAC;AAiBxE,OAAO,EAML,KAAK,iBAAiB,EACtB,KAAK,cAAc,EAMpB,MAAM,mBAAmB,CAAC;AAmD3B,wBAAgB,mCAAmC,CACjD,UAAU,EAAE,MAAM,GACjB,MAAM,CAMR;AAmlBD;;;;;;;;;;GAUG;AACH,wBAAsB,0BAA0B,CAC9C,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,EACnB,aAAa,SAAM,GAClB,OAAO,CAAC,iBAAiB,CAAC,CAqD5B;AAoCD,wBAAgB,wBAAwB,IAAI,MAAM,EAAE,CAMnD;AAED;;;;;GAKG;AACH,wBAAgB,0BAA0B,IAAI,KAAK,CAAC;IAClD,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf,CAAC,CAMD;AAyQD;;;;;;;;;;;;GAYG;AACH,wBAAsB,yBAAyB,CAC7C,cAAc,EAAE,MAAM,EACtB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,IAAI,CAAC,CAqCf;AAwXD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,qBAAqB,GAAG,KAAK,GAAG,UAAU,GAAG,UAAU,CAAC;AAEpE,wBAAsB,cAAc,CAClC,MAAM,EAAE,WAAW,EACnB,IAAI,CAAC,EAAE;IACL,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,KAAK,CAAC,EAAE,qBAAqB,CAAC;IAC9B,uBAAuB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CAC7C,GACA,OAAO,CAAC,cAAc,EAAE,CAAC,CAihB3B"}
1
+ {"version":3,"file":"plugin-resolver.d.ts","sourceRoot":"","sources":["../../src/runtime/plugin-resolver.ts"],"names":[],"mappings":"AA8BA,OAAO,EAAE,KAAK,WAAW,EAAmB,MAAM,qBAAqB,CAAC;AAiBxE,OAAO,EAML,KAAK,iBAAiB,EACtB,KAAK,cAAc,EAMpB,MAAM,mBAAmB,CAAC;AAoD3B,wBAAgB,mCAAmC,CACjD,UAAU,EAAE,MAAM,GACjB,MAAM,CAMR;AA2mBD;;;;;;;;;;GAUG;AACH,wBAAsB,0BAA0B,CAC9C,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,EACnB,aAAa,SAAM,GAClB,OAAO,CAAC,iBAAiB,CAAC,CAsD5B;AAoCD,wBAAgB,wBAAwB,IAAI,MAAM,EAAE,CAMnD;AAED;;;;;GAKG;AACH,wBAAgB,0BAA0B,IAAI,KAAK,CAAC;IAClD,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf,CAAC,CAMD;AAuPD;;;;;;;;;;;;GAYG;AACH,wBAAsB,yBAAyB,CAC7C,cAAc,EAAE,MAAM,EACtB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,IAAI,CAAC,CAqCf;AAoaD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,qBAAqB,GAAG,KAAK,GAAG,UAAU,GAAG,UAAU,CAAC;AAEpE,wBAAsB,cAAc,CAClC,MAAM,EAAE,WAAW,EACnB,IAAI,CAAC,EAAE;IACL,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,KAAK,CAAC,EAAE,qBAAqB,CAAC;IAC9B,uBAAuB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CAC7C,GACA,OAAO,CAAC,cAAc,EAAE,CAAC,CA4hB3B"}
@@ -14,8 +14,6 @@ var __rewriteRelativeImportExtension = (this && this.__rewriteRelativeImportExte
14
14
  * directories. Each plugin is wrapped in an error boundary so a single
15
15
  * failing plugin cannot crash the agent startup.
16
16
  *
17
- * Extracted from eliza.ts to reduce file size.
18
- *
19
17
  * @module plugin-resolver
20
18
  */
21
19
  import crypto from "node:crypto";
@@ -37,6 +35,7 @@ import { CUSTOM_PLUGINS_DIRNAME, EJECTED_PLUGINS_DIRNAME, ensureBrowserServerLin
37
35
  const LAST_FAILED_PLUGIN_NAMES = Symbol.for("@elizaos/plugin-resolver/last-failed-plugin-names");
38
36
  const LAST_FAILED_PLUGIN_DETAILS = Symbol.for("@elizaos/plugin-resolver/last-failed-plugin-details");
39
37
  const RUNTIME_APP_PLUGIN_SUBPATHS = new Set([
38
+ "@elizaos/plugin-calendar",
40
39
  "@elizaos/plugin-companion",
41
40
  "@elizaos/plugin-contacts",
42
41
  "@elizaos/plugin-elizamaker",
@@ -429,6 +428,25 @@ async function hasNonSymlinkWorkspaceNodeModulesPackage(pluginName) {
429
428
  }
430
429
  return false;
431
430
  }
431
+ async function resolveWorkspaceNodeModulesPackageRoot(packageName) {
432
+ for (const workspaceRoot of uniquePaths([
433
+ process.cwd(),
434
+ ...resolveWorkspaceRoots(),
435
+ ])) {
436
+ const candidate = path.join(workspaceRoot, "node_modules", ...packageName.split("/"));
437
+ try {
438
+ const stat = await fs.lstat(candidate);
439
+ if (stat.isDirectory() || stat.isSymbolicLink())
440
+ return candidate;
441
+ }
442
+ catch (error) {
443
+ if (error.code !== "ENOENT") {
444
+ throw error;
445
+ }
446
+ }
447
+ }
448
+ return null;
449
+ }
432
450
  // ---------------------------------------------------------------------------
433
451
  // Plugin error boundary wrapper
434
452
  // ---------------------------------------------------------------------------
@@ -516,14 +534,15 @@ export async function importPluginModuleFromPath(installPath, packageName, expor
516
534
  /* git layout — pkgRoot stays as absPath */
517
535
  }
518
536
  const packageRelativePath = pkgRoot === absPath ? [] : ["node_modules", ...packageName.split("/")];
519
- // Cold-boot fast-path (opt-in): on the FIRST import of this package in this
520
- // process there is no ESM module record to bust, so staging's recursive
521
- // `fs.cp` copy is pure I/O waste + unbounded `.runtime-imports/` growth.
522
- // Import in place from the real package root instead, but ONLY when a stable
523
- // built `dist/` exists. Any re-import (name already in the set) falls back to
524
- // staging so hot-reloads still force a fresh module evaluation.
525
- const useColdFastPath = coldImportInPlaceEnabled() &&
526
- !importedPluginPackageNames.has(packageName) &&
537
+ // Cold-boot fast-path: on the FIRST import of this package in this process
538
+ // there is no ESM module record to bust, so staging's recursive `fs.cp` copy
539
+ // is pure I/O waste + unbounded `.runtime-imports/` growth. Import in place
540
+ // from the real package root instead, but ONLY when a stable built `dist/`
541
+ // exists. Any re-import (name already in the set) falls back to staging so
542
+ // hot-reloads still force a fresh module evaluation. This is a single
543
+ // behavior for every boot — local dev and the container resolve plugins
544
+ // identically.
545
+ const useColdFastPath = !importedPluginPackageNames.has(packageName) &&
527
546
  existsSync(path.join(pkgRoot, "dist"));
528
547
  const importRoot = useColdFastPath
529
548
  ? pkgRoot
@@ -782,24 +801,6 @@ function stageFullPluginPackageEnabled() {
782
801
  const normalized = raw.trim().toLowerCase();
783
802
  return normalized === "1" || normalized === "true" || normalized === "yes";
784
803
  }
785
- /**
786
- * Cold-boot fast-path opt-in. When enabled, the *first* import of a given
787
- * plugin package in this process is loaded in place from its real package root
788
- * — skipping the `fs.cp` staging copy — provided a built `dist/` is present.
789
- *
790
- * Staging exists only to bust the ESM module graph when hot-reloading a mutated
791
- * plugin (a fresh staged URL forces re-evaluation since ESM has no
792
- * cache-eviction API). On a cold boot the plugin was never imported, so there
793
- * is no module record to bust and staging is pure I/O waste. Default OFF; only
794
- * the literal "1"/"true"/"yes" enables it.
795
- */
796
- function coldImportInPlaceEnabled() {
797
- const raw = process.env.ELIZA_PLUGIN_COLD_IMPORT_IN_PLACE;
798
- if (!raw)
799
- return false;
800
- const normalized = raw.trim().toLowerCase();
801
- return normalized === "1" || normalized === "true" || normalized === "yes";
802
- }
803
804
  const DEFAULT_PLUGIN_INSTANCE_KEEP = 3;
804
805
  function pluginInstanceKeepCount() {
805
806
  const raw = process.env.ELIZA_PLUGIN_INSTANCE_KEEP;
@@ -1031,36 +1032,58 @@ function computeVerdictFingerprint(config, isNativePlatform) {
1031
1032
  return `${isNativePlatform ? "1" : "0"}${env}${JSON.stringify(config)}`;
1032
1033
  }
1033
1034
  /**
1034
- * Cheap signature over the directories {@link discoverPluginCandidates} scans:
1035
- * the mtimeMs of each `node_modules/@elizaos` and `plugins` root. Adding or
1036
- * removing a package mutates the containing directory's mtime, invalidating the
1037
- * cache. Missing directories contribute a sentinel so the signature still
1038
- * changes when one appears.
1035
+ * Cheap signature over the directories {@link discoverPluginCandidates} scans.
1036
+ * Adding/removing a package mutates either `node_modules`, the package scope
1037
+ * dir, or `plugins`, invalidating the cache. Missing directories contribute a
1038
+ * sentinel so the signature still changes when one appears.
1039
1039
  */
1040
1040
  async function computePluginCandidateSignature() {
1041
1041
  const parts = [];
1042
1042
  for (const root of resolveWorkspaceRoots()) {
1043
- for (const dir of [
1044
- path.join(root, "node_modules", "@elizaos"),
1045
- path.join(root, "plugins"),
1046
- ]) {
1047
- try {
1048
- const stat = await fs.stat(dir);
1049
- parts.push(`${dir}:${stat.mtimeMs}`);
1050
- }
1051
- catch (err) {
1052
- if (err.code === "ENOENT") {
1053
- parts.push(`${dir}:absent`);
1054
- continue;
1055
- }
1056
- throw err;
1057
- }
1043
+ await addDirectorySignature(parts, path.join(root, "node_modules"));
1044
+ for (const scopeDir of await listNodeModulesScopeDirs(root)) {
1045
+ await addDirectorySignature(parts, scopeDir);
1058
1046
  }
1047
+ await addDirectorySignature(parts, path.join(root, "plugins"));
1059
1048
  }
1060
1049
  return parts.join("|");
1061
1050
  }
1051
+ async function addDirectorySignature(parts, dir) {
1052
+ try {
1053
+ const stat = await fs.stat(dir);
1054
+ parts.push(`${dir}:${stat.mtimeMs}`);
1055
+ }
1056
+ catch (err) {
1057
+ if (err.code === "ENOENT") {
1058
+ parts.push(`${dir}:absent`);
1059
+ return;
1060
+ }
1061
+ throw err;
1062
+ }
1063
+ }
1064
+ async function listNodeModulesScopeDirs(root) {
1065
+ const nodeModulesDir = path.join(root, "node_modules");
1066
+ let entries;
1067
+ try {
1068
+ entries = (await fs.readdir(nodeModulesDir, {
1069
+ withFileTypes: true,
1070
+ }));
1071
+ }
1072
+ catch (err) {
1073
+ if (err.code === "ENOENT")
1074
+ return [];
1075
+ throw err;
1076
+ }
1077
+ return entries
1078
+ .filter((entry) => entry.name.startsWith("@") &&
1079
+ (entry.isDirectory() || entry.isSymbolicLink()))
1080
+ .map((entry) => path.join(nodeModulesDir, entry.name));
1081
+ }
1082
+ function isPluginPackageDirName(name) {
1083
+ return name.startsWith("plugin-") || name.startsWith("app-");
1084
+ }
1062
1085
  /**
1063
- * Walk the @elizaos scope in node_modules + workspace `plugins/` dirs and
1086
+ * Walk plugin/app packages in node_modules + workspace `plugins/` dirs and
1064
1087
  * return every package that has a `package.json`. The manifest evaluator
1065
1088
  * filters these down to the ones that actually declare an `elizaos.plugin`
1066
1089
  * block — this discovery step is intentionally cheap (a single readdir + stat
@@ -1087,13 +1110,13 @@ async function discoverPluginCandidatesUncached() {
1087
1110
  seen.add(pkgName);
1088
1111
  candidates.push({ packageName: pkgName, packageRoot: pkgRoot });
1089
1112
  };
1090
- // 1. node_modules/@elizaos/* — covers npm-installed plugins and dev symlinks
1091
- // pointing at workspace packages.
1113
+ // 1. node_modules plugin/app packages — covers npm-installed official and
1114
+ // third-party plugins plus dev symlinks pointing at workspace packages.
1092
1115
  for (const root of resolveWorkspaceRoots()) {
1093
- const elizaScope = path.join(root, "node_modules", "@elizaos");
1116
+ const nodeModulesDir = path.join(root, "node_modules");
1094
1117
  let entries;
1095
1118
  try {
1096
- entries = (await fs.readdir(elizaScope, {
1119
+ entries = (await fs.readdir(nodeModulesDir, {
1097
1120
  withFileTypes: true,
1098
1121
  }));
1099
1122
  }
@@ -1105,16 +1128,34 @@ async function discoverPluginCandidatesUncached() {
1105
1128
  for (const entry of entries) {
1106
1129
  if (!entry.isDirectory() && !entry.isSymbolicLink())
1107
1130
  continue;
1108
- if (entry.name.startsWith("."))
1109
- continue;
1110
- // Only plugin/app packages — skip core, shared, agent, ui, etc. (those
1111
- // aren't auto-enable participants and reading their package.json is
1112
- // wasted work).
1113
- if (!entry.name.startsWith("plugin-") && !entry.name.startsWith("app-")) {
1131
+ if (entry.name.startsWith("@")) {
1132
+ const scopeDir = path.join(nodeModulesDir, entry.name);
1133
+ let scopedEntries;
1134
+ try {
1135
+ scopedEntries = (await fs.readdir(scopeDir, {
1136
+ withFileTypes: true,
1137
+ }));
1138
+ }
1139
+ catch (err) {
1140
+ if (err.code === "ENOENT")
1141
+ continue;
1142
+ throw err;
1143
+ }
1144
+ for (const scopedEntry of scopedEntries) {
1145
+ if (!scopedEntry.isDirectory() && !scopedEntry.isSymbolicLink()) {
1146
+ continue;
1147
+ }
1148
+ if (!isPluginPackageDirName(scopedEntry.name))
1149
+ continue;
1150
+ const pkgRoot = path.join(scopeDir, scopedEntry.name);
1151
+ await tryAdd(pkgRoot, `${entry.name}/${scopedEntry.name}`);
1152
+ }
1114
1153
  continue;
1115
1154
  }
1116
- const pkgRoot = path.join(elizaScope, entry.name);
1117
- await tryAdd(pkgRoot, `@elizaos/${entry.name}`);
1155
+ if (!isPluginPackageDirName(entry.name))
1156
+ continue;
1157
+ const pkgRoot = path.join(nodeModulesDir, entry.name);
1158
+ await tryAdd(pkgRoot, entry.name);
1118
1159
  }
1119
1160
  }
1120
1161
  // 2. workspace `plugins/` dir — covers cases where the plugin is in the
@@ -1186,8 +1227,8 @@ export async function resolvePlugins(config, opts) {
1186
1227
  // silently dropped. Capture the result and assign back so both the allow
1187
1228
  // list and any downstream config reads see the mutation.
1188
1229
  //
1189
- // Auto-enable is sourced exclusively from per-plugin manifests: walk every
1190
- // @elizaos/* package.json on disk and run each plugin's
1230
+ // Auto-enable is sourced exclusively from per-plugin manifests: walk plugin
1231
+ // and app package.json files on disk and run each plugin's
1191
1232
  // autoEnableModule.shouldEnable(ctx). Each plugin owns its own enable
1192
1233
  // conditions in auto-enable.ts — no central map exists.
1193
1234
  //
@@ -1336,6 +1377,13 @@ export async function resolvePlugins(config, opts) {
1336
1377
  const staticElizaPlugin = await resolveStaticElizaPlugin(pluginName);
1337
1378
  const exportSubpath = runtimePluginExportSubpath(pluginName);
1338
1379
  const importOfficialPluginFromNodeModules = async () => (await import(__rewriteRelativeImportExtension(resolveRuntimePluginImportSpecifier(pluginName))));
1380
+ const importPluginFromWorkspaceNodeModules = async () => {
1381
+ const packageRoot = await resolveWorkspaceNodeModulesPackageRoot(pluginName);
1382
+ if (!packageRoot) {
1383
+ return (await import(__rewriteRelativeImportExtension(runtimePluginImportSpecifier(pluginName))));
1384
+ }
1385
+ return importPluginModuleFromPath(packageRoot, pluginName, exportSubpath);
1386
+ };
1339
1387
  // Pre-flight: opportunistically prepare special plugin dependencies.
1340
1388
  // For plugin-browser, stagehand-server is only needed by the optional
1341
1389
  // `stagehand` backend. The app workspace and Chrome/Safari bridge backends
@@ -1426,7 +1474,7 @@ export async function resolvePlugins(config, opts) {
1426
1474
  const staticMod = await resolveStaticElizaPlugin(pluginName);
1427
1475
  mod = staticMod
1428
1476
  ? staticMod
1429
- : (await import(__rewriteRelativeImportExtension(runtimePluginImportSpecifier(pluginName))));
1477
+ : await importPluginFromWorkspaceNodeModules();
1430
1478
  if (repairBrokenInstallRecord(config, pluginName)) {
1431
1479
  repairedInstallRecords.add(pluginName);
1432
1480
  }
@@ -1450,7 +1498,7 @@ export async function resolvePlugins(config, opts) {
1450
1498
  // node_modules resolution).
1451
1499
  mod = staticElizaPlugin
1452
1500
  ? staticElizaPlugin
1453
- : (await import(__rewriteRelativeImportExtension(runtimePluginImportSpecifier(pluginName))));
1501
+ : await importPluginFromWorkspaceNodeModules();
1454
1502
  }
1455
1503
  const pluginInstance = findRuntimePluginExport(mod);
1456
1504
  if (pluginInstance) {
@@ -1,5 +1,5 @@
1
1
  import { type Plugin } from "@elizaos/core";
2
- import type { PluginInstallRecord } from "../config/types.eliza.ts";
2
+ import type { PluginInstallRecord } from "../config/types.eliza.js";
3
3
  /** A successfully resolved plugin ready for AgentRuntime registration. */
4
4
  export interface ResolvedPlugin {
5
5
  /** npm package name (e.g. "@elizaos/plugin-anthropic"). */
@@ -5,10 +5,10 @@
5
5
  * and optional prompt tracing/capture. Controlled via ELIZA_* env vars.
6
6
  */
7
7
  import { type AgentRuntime } from "@elizaos/core";
8
- import type { ElizaConfig } from "../config/types.ts";
9
- import type { CompactorMessage, CompactorModelCall } from "./conversation-compactor.types.ts";
10
- import { type ApplyConversationCompactionResult, type ApplyConversationMessageCompactionResult } from "./conversation-compactor-runtime.ts";
11
- export { buildFullParamActionSet, compactActionsForIntent, detectIntentCategories, } from "./prompt-compaction.ts";
8
+ import type { ElizaConfig } from "../config/types.js";
9
+ import type { CompactorMessage, CompactorModelCall } from "./conversation-compactor.types.js";
10
+ import { type ApplyConversationCompactionResult, type ApplyConversationMessageCompactionResult } from "./conversation-compactor-runtime.js";
11
+ export { buildFullParamActionSet, compactActionsForIntent, detectIntentCategories, } from "./prompt-compaction.js";
12
12
  export interface CapturedModelUsage {
13
13
  promptTokens: number;
14
14
  completionTokens: number;
@@ -0,0 +1,7 @@
1
+ interface RuntimeSettingSource {
2
+ getSetting(key: string): unknown;
3
+ }
4
+ type EnvSource = Record<string, string | undefined>;
5
+ export declare function shouldLoadRemoteCodingRunnerForBoot(runtime: RuntimeSettingSource, env?: EnvSource): boolean;
6
+ export {};
7
+ //# sourceMappingURL=remote-coding-runner-gate.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"remote-coding-runner-gate.d.ts","sourceRoot":"","sources":["../../src/runtime/remote-coding-runner-gate.ts"],"names":[],"mappings":"AAAA,UAAU,oBAAoB;IAC5B,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CAClC;AAED,KAAK,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;AAoCpD,wBAAgB,mCAAmC,CACjD,OAAO,EAAE,oBAAoB,EAC7B,GAAG,GAAE,SAAuB,GAC3B,OAAO,CAQT"}
@@ -0,0 +1,36 @@
1
+ const RUNNER_SETTING_KEYS = [
2
+ "ELIZA_CODING_REMOTE_RUNNER",
3
+ "ELIZA_REMOTE_RUNNER",
4
+ ];
5
+ const REMOTE_RUNNER_URL_KEYS = [
6
+ "ELIZA_CLOUD_SANDBOX_BASE_URL",
7
+ "ELIZA_CLOUD_REMOTE_RUNNER_URL",
8
+ "ELIZA_CLOUD_RUNNER_URL",
9
+ "ELIZA_HOME_REMOTE_RUNNER_URL",
10
+ "ELIZA_HOME_RUNNER_URL",
11
+ ];
12
+ function readSetting(runtime, env, key) {
13
+ const fromRuntime = runtime.getSetting(key);
14
+ if (typeof fromRuntime === "string" && fromRuntime.trim().length > 0) {
15
+ return fromRuntime.trim();
16
+ }
17
+ const fromEnv = env[key];
18
+ if (typeof fromEnv === "string" && fromEnv.trim().length > 0) {
19
+ return fromEnv.trim();
20
+ }
21
+ return undefined;
22
+ }
23
+ function truthySetting(value) {
24
+ if (!value)
25
+ return false;
26
+ return ["1", "true", "yes", "on"].includes(value.toLowerCase());
27
+ }
28
+ export function shouldLoadRemoteCodingRunnerForBoot(runtime, env = process.env) {
29
+ if (RUNNER_SETTING_KEYS.some((key) => readSetting(runtime, env, key))) {
30
+ return true;
31
+ }
32
+ if (truthySetting(readSetting(runtime, env, "ELIZA_E2B_REMOTE_RUNNER"))) {
33
+ return true;
34
+ }
35
+ return REMOTE_RUNNER_URL_KEYS.some((key) => readSetting(runtime, env, key));
36
+ }
@@ -14,10 +14,10 @@
14
14
  * }
15
15
  */
16
16
  import { type Plugin, roleAction } from "@elizaos/core";
17
- export { rolesProvider } from "./provider.ts";
18
- export type { ConnectorAdminWhitelist, RoleCheckResult, RoleGrantSource, RoleName, RolesConfig, RolesWorldMetadata, } from "./types.ts";
19
- export { ROLE_RANK } from "./types.ts";
20
- export { canModifyRole, checkSenderPrivateAccess, checkSenderRole, getConfiguredOwnerEntityIds, getConnectorAdminWhitelist, getEntityRole, hasConfiguredCanonicalOwner, matchEntityToConnectorAdminWhitelist, normalizeRole, resolveCanonicalOwnerId, resolveCanonicalOwnerIdForMessage, resolveEntityRole, resolveWorldForMessage, setConnectorAdminWhitelist, setEntityRole, } from "./utils.ts";
17
+ export { rolesProvider } from "./provider.js";
18
+ export type { ConnectorAdminWhitelist, RoleCheckResult, RoleGrantSource, RoleName, RolesConfig, RolesWorldMetadata, } from "./types.js";
19
+ export { ROLE_RANK } from "./types.js";
20
+ export { canModifyRole, checkSenderPrivateAccess, checkSenderRole, getConfiguredOwnerEntityIds, getConnectorAdminWhitelist, getEntityRole, hasConfiguredCanonicalOwner, matchEntityToConnectorAdminWhitelist, normalizeRole, resolveCanonicalOwnerId, resolveCanonicalOwnerIdForMessage, resolveEntityRole, resolveWorldForMessage, setConnectorAdminWhitelist, setEntityRole, } from "./utils.js";
21
21
  export { roleAction };
22
22
  declare const rolesPlugin: Plugin;
23
23
  export default rolesPlugin;
@@ -1,3 +1,3 @@
1
- export * from "./roles/src/index.ts";
2
- export { default } from "./roles/src/index.ts";
1
+ export * from "./roles/src/index.js";
2
+ export { default } from "./roles/src/index.js";
3
3
  //# sourceMappingURL=roles.d.ts.map
@@ -14,7 +14,7 @@
14
14
  * config unchanged when the env var is absent or unparseable,
15
15
  * so it is inert for every non-provisioned runtime.
16
16
  */
17
- import type { ElizaConfig } from "../config/config.ts";
17
+ import type { ElizaConfig } from "../config/config.js";
18
18
  /**
19
19
  * Whether this container should own (connect directly to) its platform
20
20
  * connectors. Default false: the gateway owns the connection and forwards
@@ -14,7 +14,7 @@
14
14
  * forces this — a process-only cache could rely on the surrounding
15
15
  * trajectory filter, but a shared on-disk store cannot.
16
16
  */
17
- import type { CacheableToolDescriptor, PrivacyRedactor, ToolArgs, ToolCacheEntry, ToolOutput } from "./types.ts";
17
+ import type { CacheableToolDescriptor, PrivacyRedactor, ToolArgs, ToolCacheEntry, ToolOutput } from "./types.js";
18
18
  export interface ToolCallCacheOptions {
19
19
  /** Root directory for the on-disk tier. Defaults to `<stateDir>/tool-cache`. */
20
20
  diskRoot?: string;
@@ -9,7 +9,7 @@
9
9
  * already cross network or shell boundaries, so a small fs touch is in the
10
10
  * noise. Writes go through the privacy redactor before serialisation.
11
11
  */
12
- import type { PrivacyRedactor, ToolCacheEntry } from "./types.ts";
12
+ import type { PrivacyRedactor, ToolCacheEntry } from "./types.js";
13
13
  export declare class DiskStore {
14
14
  private readonly root;
15
15
  private readonly redact;
@@ -1,7 +1,7 @@
1
- export type { ToolCallCacheOptions } from "./cache.ts";
2
- export { ToolCallCache } from "./cache.ts";
3
- export { buildCacheKey, canonicalizeJson } from "./key.ts";
4
- export { defaultPrivacyRedactor } from "./redact.ts";
5
- export { CACHEABLE_TOOL_REGISTRY, isCacheable, resolveToolDescriptor, } from "./registry.ts";
6
- export type { CacheableToolDescriptor, PrivacyRedactor, ToolArgs, ToolCacheEntry, ToolOutput, } from "./types.ts";
1
+ export type { ToolCallCacheOptions } from "./cache.js";
2
+ export { ToolCallCache } from "./cache.js";
3
+ export { buildCacheKey, canonicalizeJson } from "./key.js";
4
+ export { defaultPrivacyRedactor } from "./redact.js";
5
+ export { CACHEABLE_TOOL_REGISTRY, isCacheable, resolveToolDescriptor, } from "./registry.js";
6
+ export type { CacheableToolDescriptor, PrivacyRedactor, ToolArgs, ToolCacheEntry, ToolOutput, } from "./types.js";
7
7
  //# sourceMappingURL=index.d.ts.map
@@ -5,7 +5,7 @@
5
5
  * argument shapes (e.g. `{a:1,b:2}` and `{b:2,a:1}`) collide on the same
6
6
  * key. The final key is `sha256(toolName + ':' + canonicalJson)`.
7
7
  */
8
- import type { ToolArgs } from "./types.ts";
8
+ import type { ToolArgs } from "./types.js";
9
9
  export declare function canonicalizeJson(value: unknown): string;
10
10
  export declare function buildCacheKey(toolName: string, args: ToolArgs): string;
11
11
  //# sourceMappingURL=key.d.ts.map
@@ -12,6 +12,6 @@
12
12
  * - environment-variable values whose key name looks like a secret
13
13
  * - geographic coordinates (matching the Location-plugin patterns)
14
14
  */
15
- import type { PrivacyRedactor } from "./types.ts";
15
+ import type { PrivacyRedactor } from "./types.js";
16
16
  export declare const defaultPrivacyRedactor: PrivacyRedactor;
17
17
  //# sourceMappingURL=redact.d.ts.map
@@ -11,7 +11,7 @@
11
11
  * against a working tree) get short TTLs; tools whose results are stable
12
12
  * across days (search results, immutable web archives) get longer ones.
13
13
  */
14
- import type { CacheableToolDescriptor } from "./types.ts";
14
+ import type { CacheableToolDescriptor } from "./types.js";
15
15
  export declare const CACHEABLE_TOOL_REGISTRY: Record<string, CacheableToolDescriptor>;
16
16
  export declare function resolveToolDescriptor(name: string, overrides?: Partial<Pick<CacheableToolDescriptor, "ttlMs" | "version">>): CacheableToolDescriptor;
17
17
  export declare function isCacheable(name: string): boolean;
@@ -4,16 +4,15 @@
4
4
  * Wraps the `handler` of every registered Action that the cache registry
5
5
  * marks as `cacheable: true` so the result of a (toolName, args) pair is
6
6
  * served from the two-tier `ToolCallCache` instead of re-running the
7
- * underlying tool. Side-effect tools and any tool not listed in
8
- * `CACHEABLE_TOOL_REGISTRY` pass through unchanged.
7
+ * underlying tool. Side-effect tools and any tool not in the cacheable-tool
8
+ * registry pass through unchanged.
9
9
  *
10
- * Hooked into the runtime via `wrapActionsWithCache(actions, cache)` which
11
- * the eliza loader calls after collecting plugin actions and before handing
12
- * them to `AgentRuntime`. Per-tool TTL overrides come from the `tools.cache`
13
- * config block (see `zod-schema.agent-runtime.ts`).
10
+ * `plugin-lifecycle.ts` calls `wrapActionWithCache(action, cache, cfg)` per
11
+ * action after building the cache from config. Per-tool TTL overrides come
12
+ * from the `tools.cache` config block (see `zod-schema.agent-runtime.ts`).
14
13
  */
15
14
  import type { Action } from "@elizaos/core";
16
- import { CACHEABLE_TOOL_REGISTRY, ToolCallCache } from "./tool-call-cache/index.ts";
15
+ import { ToolCallCache } from "./tool-call-cache/index.js";
17
16
  interface PerToolOverride {
18
17
  ttlMinutes?: number;
19
18
  version?: string;
@@ -34,6 +33,5 @@ export declare function createToolCallCacheFromConfig(cfg: ToolCacheConfig | und
34
33
  * Non-cacheable actions are returned unchanged.
35
34
  */
36
35
  export declare function wrapActionWithCache(action: Action, cache: ToolCallCache, cfg: ToolCacheConfig | undefined): Action;
37
- export declare function wrapActionsWithCache(actions: Action[], cache: ToolCallCache, cfg: ToolCacheConfig | undefined): Action[];
38
- export { CACHEABLE_TOOL_REGISTRY };
36
+ export {};
39
37
  //# sourceMappingURL=tool-call-cache-wrapper.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tool-call-cache-wrapper.d.ts","sourceRoot":"","sources":["../../src/runtime/tool-call-cache-wrapper.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EACV,MAAM,EAIP,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,uBAAuB,EAKvB,aAAa,EAEd,MAAM,4BAA4B,CAAC;AAEpC,UAAU,eAAe;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,eAAe;IAC9B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC;CAC3C;AAED;;;GAGG;AACH,wBAAgB,6BAA6B,CAC3C,GAAG,EAAE,eAAe,GAAG,SAAS,GAC/B,aAAa,GAAG,IAAI,CAOtB;AAyBD;;;GAGG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,aAAa,EACpB,GAAG,EAAE,eAAe,GAAG,SAAS,GAC/B,MAAM,CAwBR;AAED,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,MAAM,EAAE,EACjB,KAAK,EAAE,aAAa,EACpB,GAAG,EAAE,eAAe,GAAG,SAAS,GAC/B,MAAM,EAAE,CAEV;AAED,OAAO,EAAE,uBAAuB,EAAE,CAAC"}
1
+ {"version":3,"file":"tool-call-cache-wrapper.d.ts","sourceRoot":"","sources":["../../src/runtime/tool-call-cache-wrapper.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,KAAK,EACV,MAAM,EAIP,MAAM,eAAe,CAAC;AACvB,OAAO,EAKL,aAAa,EAEd,MAAM,4BAA4B,CAAC;AAEpC,UAAU,eAAe;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,eAAe;IAC9B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC;CAC3C;AAED;;;GAGG;AACH,wBAAgB,6BAA6B,CAC3C,GAAG,EAAE,eAAe,GAAG,SAAS,GAC/B,aAAa,GAAG,IAAI,CAOtB;AAyBD;;;GAGG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,aAAa,EACpB,GAAG,EAAE,eAAe,GAAG,SAAS,GAC/B,MAAM,CAwBR"}
@@ -4,15 +4,14 @@
4
4
  * Wraps the `handler` of every registered Action that the cache registry
5
5
  * marks as `cacheable: true` so the result of a (toolName, args) pair is
6
6
  * served from the two-tier `ToolCallCache` instead of re-running the
7
- * underlying tool. Side-effect tools and any tool not listed in
8
- * `CACHEABLE_TOOL_REGISTRY` pass through unchanged.
7
+ * underlying tool. Side-effect tools and any tool not in the cacheable-tool
8
+ * registry pass through unchanged.
9
9
  *
10
- * Hooked into the runtime via `wrapActionsWithCache(actions, cache)` which
11
- * the eliza loader calls after collecting plugin actions and before handing
12
- * them to `AgentRuntime`. Per-tool TTL overrides come from the `tools.cache`
13
- * config block (see `zod-schema.agent-runtime.ts`).
10
+ * `plugin-lifecycle.ts` calls `wrapActionWithCache(action, cache, cfg)` per
11
+ * action after building the cache from config. Per-tool TTL overrides come
12
+ * from the `tools.cache` config block (see `zod-schema.agent-runtime.ts`).
14
13
  */
15
- import { CACHEABLE_TOOL_REGISTRY, defaultPrivacyRedactor, isCacheable, resolveToolDescriptor, ToolCallCache, } from "./tool-call-cache/index.js";
14
+ import { defaultPrivacyRedactor, isCacheable, resolveToolDescriptor, ToolCallCache, } from "./tool-call-cache/index.js";
16
15
  /**
17
16
  * Build a ToolCallCache from agent runtime config. Returns null when the
18
17
  * cache is disabled so callers can skip the wrap-step entirely.
@@ -66,7 +65,3 @@ export function wrapActionWithCache(action, cache, cfg) {
66
65
  };
67
66
  return { ...action, handler: wrapped };
68
67
  }
69
- export function wrapActionsWithCache(actions, cache, cfg) {
70
- return actions.map((a) => wrapActionWithCache(a, cache, cfg));
71
- }
72
- export { CACHEABLE_TOOL_REGISTRY };