@agent-native/core 0.91.1 → 0.92.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (383) hide show
  1. package/blueprints/action/crud.md +1 -1
  2. package/blueprints/channel/discord.md +1 -1
  3. package/blueprints/provider/stripe.md +1 -1
  4. package/blueprints/sandbox/docker.md +1 -1
  5. package/corpus/README.md +2 -2
  6. package/corpus/core/CHANGELOG.md +31 -0
  7. package/corpus/core/blueprints/action/crud.md +1 -1
  8. package/corpus/core/blueprints/channel/discord.md +1 -1
  9. package/corpus/core/blueprints/provider/stripe.md +1 -1
  10. package/corpus/core/blueprints/sandbox/docker.md +1 -1
  11. package/corpus/core/docs/content/faq.mdx +17 -0
  12. package/corpus/core/docs/content/notifications.mdx +12 -6
  13. package/corpus/core/package.json +6 -5
  14. package/corpus/core/src/agent/production-agent.ts +140 -46
  15. package/corpus/core/src/agent/run-manager.ts +23 -2
  16. package/corpus/core/src/agent/run-store.ts +2 -2
  17. package/corpus/core/src/agent/tool-search.ts +71 -4
  18. package/corpus/core/src/cli/add.ts +1 -1
  19. package/corpus/core/src/cli/create.ts +8 -3
  20. package/corpus/core/src/cli/index.ts +25 -4
  21. package/corpus/core/src/cli/upgrade.ts +798 -0
  22. package/corpus/core/src/client/AssistantChat.tsx +1 -1
  23. package/corpus/core/src/client/HighlightedCodeBlock.tsx +20 -3
  24. package/corpus/core/src/client/agent-chat-adapter.ts +31 -6
  25. package/corpus/core/src/client/chat/message-components.tsx +85 -8
  26. package/corpus/core/src/client/chat/tool-call-display.tsx +355 -144
  27. package/corpus/core/src/client/code-agent-chat-adapter.ts +2 -9
  28. package/corpus/core/src/client/extensions/ExtensionSlot.tsx +7 -0
  29. package/corpus/core/src/client/settings/SettingsPanel.tsx +533 -389
  30. package/corpus/core/src/client/settings/SettingsSection.tsx +154 -17
  31. package/corpus/core/src/client/sse-event-processor.ts +29 -2
  32. package/corpus/core/src/extensions/actions.ts +113 -5
  33. package/corpus/core/src/jobs/scheduler.ts +30 -1
  34. package/corpus/core/src/localization/default-messages.ts +21 -0
  35. package/corpus/core/src/notifications/channels.ts +88 -25
  36. package/corpus/core/src/notifications/registry.ts +17 -3
  37. package/corpus/core/src/notifications/types.ts +4 -1
  38. package/corpus/core/src/server/agent-chat-plugin.ts +7 -3
  39. package/corpus/core/src/server/request-context.ts +7 -0
  40. package/corpus/core/src/styles/agent-conversation.css +1 -1
  41. package/corpus/core/src/templates/default/.agents/skills/self-modifying-code/SKILL.md +20 -2
  42. package/corpus/core/src/templates/default/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  43. package/corpus/core/src/templates/default/AGENTS.md +10 -3
  44. package/corpus/core/src/templates/default/app/i18n/ar-SA.ts +21 -0
  45. package/corpus/core/src/templates/default/app/i18n/de-DE.ts +21 -0
  46. package/corpus/core/src/templates/default/app/i18n/en-US.ts +21 -0
  47. package/corpus/core/src/templates/default/app/i18n/es-ES.ts +21 -0
  48. package/corpus/core/src/templates/default/app/i18n/fr-FR.ts +21 -0
  49. package/corpus/core/src/templates/default/app/i18n/hi-IN.ts +20 -0
  50. package/corpus/core/src/templates/default/app/i18n/ja-JP.ts +21 -0
  51. package/corpus/core/src/templates/default/app/i18n/ko-KR.ts +20 -0
  52. package/corpus/core/src/templates/default/app/i18n/pt-BR.ts +21 -0
  53. package/corpus/core/src/templates/default/app/i18n/zh-CN.ts +20 -0
  54. package/corpus/core/src/templates/default/app/i18n/zh-TW.ts +19 -0
  55. package/corpus/core/src/templates/default/package.json +4 -3
  56. package/corpus/core/src/templates/headless/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  57. package/corpus/core/src/templates/headless/AGENTS.md +9 -3
  58. package/corpus/core/src/templates/headless/package.json +4 -3
  59. package/corpus/core/src/templates/workspace-core/.agents/skills/self-modifying-code/SKILL.md +20 -2
  60. package/corpus/core/src/templates/workspace-core/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  61. package/corpus/core/src/templates/workspace-core/package.json +6 -6
  62. package/corpus/core/src/templates/workspace-root/AGENTS.md +10 -4
  63. package/corpus/core/src/templates/workspace-root/package.json +3 -2
  64. package/corpus/core/src/triggers/dispatcher.ts +30 -2
  65. package/corpus/core/src/vite/client.ts +96 -1
  66. package/corpus/templates/analytics/.agents/skills/self-modifying-code/SKILL.md +20 -2
  67. package/corpus/templates/analytics/.agents/skills/session-replay/SKILL.md +20 -2
  68. package/corpus/templates/analytics/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  69. package/corpus/templates/analytics/AGENTS.md +7 -5
  70. package/corpus/templates/analytics/actions/save-monitor.ts +14 -0
  71. package/corpus/templates/analytics/app/components/dashboard/DataTable.tsx +41 -6
  72. package/corpus/templates/analytics/app/components/dashboard/SqlChart.tsx +122 -11
  73. package/corpus/templates/analytics/app/global.css +26 -10
  74. package/corpus/templates/analytics/app/i18n/zh-TW.ts +2 -0
  75. package/corpus/templates/analytics/app/i18n-data.ts +25 -0
  76. package/corpus/templates/analytics/app/pages/monitoring/MonitoringPage.tsx +8 -2
  77. package/corpus/templates/analytics/app/pages/monitoring/uptime/MonitorFormPage.tsx +151 -32
  78. package/corpus/templates/analytics/app/pages/monitoring/uptime/i18n.ts +17 -2
  79. package/corpus/templates/analytics/app/pages/monitoring/uptime/types.ts +4 -0
  80. package/corpus/templates/analytics/app/pages/sessions/SessionDetailPage.tsx +461 -286
  81. package/corpus/templates/analytics/app/pages/sessions/SessionDevToolsPanel.tsx +285 -294
  82. package/corpus/templates/analytics/changelog/2026-07-08-console-details-expand-inline-under-each-row-and-the-event-t.md +6 -0
  83. package/corpus/templates/analytics/changelog/2026-07-08-dashboard-tables-keep-their-size-while-loading.md +6 -0
  84. package/corpus/templates/analytics/changelog/2026-07-08-monitoring-uptime-and-errors-tabs-now-clearly-show-which-view-is-active.md +6 -0
  85. package/corpus/templates/analytics/changelog/2026-07-08-session-replay-keeps-a-usable-stage-when-dev-tools-is-open-a.md +6 -0
  86. package/corpus/templates/analytics/changelog/2026-07-08-session-replay-resumes-after-scrubbing-and-expands-console-r.md +6 -0
  87. package/corpus/templates/analytics/changelog/2026-07-08-session-replay-uses-stock-rrweb-sizing-again-so-recorded.md +6 -0
  88. package/corpus/templates/analytics/changelog/2026-07-08-session-replays-wait-for-full-load-keep-a-normal-viewport-an.md +6 -0
  89. package/corpus/templates/analytics/changelog/2026-07-08-sidebar-dashboard-menus-now-open-above-the-dashboard-canvas.md +6 -0
  90. package/corpus/templates/analytics/changelog/2026-07-08-uptime-alerting-clarifies-in-app-inbox-vs-email-and-lets-you-paste-slack-or-webhook-urls-per-monitor.md +6 -0
  91. package/corpus/templates/analytics/docs/uptime-monitoring.md +13 -11
  92. package/corpus/templates/analytics/package.json +2 -2
  93. package/corpus/templates/analytics/server/db/schema-monitoring.ts +4 -0
  94. package/corpus/templates/analytics/server/lib/uptime-monitors.ts +60 -12
  95. package/corpus/templates/analytics/server/plugins/db.ts +10 -0
  96. package/corpus/templates/assets/.agents/skills/self-modifying-code/SKILL.md +20 -2
  97. package/corpus/templates/assets/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  98. package/corpus/templates/assets/package.json +2 -2
  99. package/corpus/templates/brain/.agents/skills/self-modifying-code/SKILL.md +20 -2
  100. package/corpus/templates/brain/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  101. package/corpus/templates/brain/package.json +2 -2
  102. package/corpus/templates/calendar/.agents/skills/self-modifying-code/SKILL.md +20 -2
  103. package/corpus/templates/calendar/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  104. package/corpus/templates/calendar/AGENTS.md +10 -0
  105. package/corpus/templates/calendar/actions/create-event.ts +5 -1
  106. package/corpus/templates/calendar/actions/event-action-helpers.ts +41 -0
  107. package/corpus/templates/calendar/actions/get-attendee-timezones.ts +28 -0
  108. package/corpus/templates/calendar/actions/set-attendee-timezone.ts +68 -0
  109. package/corpus/templates/calendar/app/components/calendar/EventAttendeesSection.tsx +150 -11
  110. package/corpus/templates/calendar/app/components/calendar/EventDetailPanel.tsx +36 -1
  111. package/corpus/templates/calendar/app/components/calendar/EventDetailPopover.tsx +32 -0
  112. package/corpus/templates/calendar/app/hooks/use-attendee-timezones.ts +24 -0
  113. package/corpus/templates/calendar/app/i18n/zh-TW.ts +2 -0
  114. package/corpus/templates/calendar/app/i18n-data.ts +20 -0
  115. package/corpus/templates/calendar/app/lib/attendee-local-time.ts +122 -0
  116. package/corpus/templates/calendar/changelog/2026-07-08-event-details-now-support-extension-widgets-and-you-can-see-.md +6 -0
  117. package/corpus/templates/calendar/changelog/2026-07-08-when-you-invite-guests-to-a-new-event-you-now-appear-in.md +6 -0
  118. package/corpus/templates/calendar/package.json +2 -2
  119. package/corpus/templates/calendar/server/handlers/events.ts +5 -1
  120. package/corpus/templates/calendar/shared/api.ts +6 -0
  121. package/corpus/templates/chat/.agents/skills/self-modifying-code/SKILL.md +20 -2
  122. package/corpus/templates/chat/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  123. package/corpus/templates/chat/package.json +2 -2
  124. package/corpus/templates/clips/.agents/skills/meetings/SKILL.md +6 -2
  125. package/corpus/templates/clips/.agents/skills/self-modifying-code/SKILL.md +20 -2
  126. package/corpus/templates/clips/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  127. package/corpus/templates/clips/actions/create-meeting.ts +8 -3
  128. package/corpus/templates/clips/actions/list-meetings.ts +31 -3
  129. package/corpus/templates/clips/changelog/2026-07-08-after-finishing-a-desktop-recording-reopening-clips-restor.md +6 -0
  130. package/corpus/templates/clips/changelog/2026-07-08-clips-now-pops-up-to-take-notes-when-you-join-an-adhoc-zoom-.md +6 -0
  131. package/corpus/templates/clips/changelog/2026-07-08-desktop-clip-recordings-are-louder-after-capture-mic-only.md +6 -0
  132. package/corpus/templates/clips/changelog/2026-07-08-desktop-meeting-notes-stay-active-from-tray-and-shortcut-controls.md +6 -0
  133. package/corpus/templates/clips/changelog/2026-07-08-desktop-meeting-popovers-can-start-notes-and-join-the-meetin.md +6 -0
  134. package/corpus/templates/clips/changelog/2026-07-08-meeting-notes-keep-their-recording-state-when-the-desktop.md +6 -0
  135. package/corpus/templates/clips/changelog/2026-07-08-meeting-reminder-dropdowns-now-expand-fully-instead-of-being.md +6 -0
  136. package/corpus/templates/clips/changelog/2026-07-08-meeting-reminders-now-appear-1-minute-before-start-stay-unti.md +6 -0
  137. package/corpus/templates/clips/changelog/2026-07-08-the-desktop-meetings-panel-has-room-for-its-drop-shadow-and-.md +6 -0
  138. package/corpus/templates/clips/chrome-extension/package.json +2 -2
  139. package/corpus/templates/clips/desktop/package.json +2 -2
  140. package/corpus/templates/clips/desktop/src/app.tsx +214 -37
  141. package/corpus/templates/clips/desktop/src/hooks/useMeetingTranscription.ts +30 -6
  142. package/corpus/templates/clips/desktop/src/lib/meeting-notification-timing.ts +83 -0
  143. package/corpus/templates/clips/desktop/src/lib/native-recording-warm.ts +21 -0
  144. package/corpus/templates/clips/desktop/src/lib/recorder.ts +98 -20
  145. package/corpus/templates/clips/desktop/src/overlays/meeting-notification.tsx +197 -50
  146. package/corpus/templates/clips/desktop/src/styles.css +150 -53
  147. package/corpus/templates/clips/desktop/src-tauri/src/adhoc_meetings_watcher.rs +362 -0
  148. package/corpus/templates/clips/desktop/src-tauri/src/clips/mod.rs +41 -7
  149. package/corpus/templates/clips/desktop/src-tauri/src/lib.rs +9 -2
  150. package/corpus/templates/clips/desktop/src-tauri/src/meetings_watcher.rs +89 -11
  151. package/corpus/templates/clips/desktop/src-tauri/src/native_screen.rs +71 -17
  152. package/corpus/templates/clips/desktop/src-tauri/src/native_speech.rs +36 -1
  153. package/corpus/templates/clips/desktop/src-tauri/src/notifications.rs +62 -10
  154. package/corpus/templates/clips/desktop/src-tauri/src/shortcuts.rs +3 -3
  155. package/corpus/templates/clips/desktop/src-tauri/src/silence_detector.rs +1 -25
  156. package/corpus/templates/clips/desktop/src-tauri/src/state.rs +5 -0
  157. package/corpus/templates/clips/desktop/src-tauri/src/tray.rs +18 -6
  158. package/corpus/templates/clips/desktop/src-tauri/src/util.rs +36 -1
  159. package/corpus/templates/clips/package.json +2 -2
  160. package/corpus/templates/content/.agents/skills/self-modifying-code/SKILL.md +20 -2
  161. package/corpus/templates/content/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  162. package/corpus/templates/content/actions/_batch-utils.ts +8 -0
  163. package/corpus/templates/content/actions/_builder-cms-read-client.ts +7 -5
  164. package/corpus/templates/content/actions/_content-database-personal-view.ts +80 -0
  165. package/corpus/templates/content/actions/_database-source-utils.ts +776 -319
  166. package/corpus/templates/content/actions/_database-utils.ts +6 -1
  167. package/corpus/templates/content/actions/_property-utils.ts +168 -0
  168. package/corpus/templates/content/actions/add-content-database-source-field-property.ts +19 -12
  169. package/corpus/templates/content/actions/bind-content-database-source-field.ts +19 -12
  170. package/corpus/templates/content/actions/delete-document.ts +9 -13
  171. package/corpus/templates/content/actions/get-content-database-personal-view.ts +27 -0
  172. package/corpus/templates/content/actions/refresh-content-database-source.ts +5 -5
  173. package/corpus/templates/content/actions/update-content-database-personal-view.ts +31 -0
  174. package/corpus/templates/content/actions/update-content-database-view.ts +3 -0
  175. package/corpus/templates/content/app/components/editor/DocumentProperties.tsx +1 -1
  176. package/corpus/templates/content/app/components/editor/body-hydration.ts +35 -11
  177. package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +2631 -551
  178. package/corpus/templates/content/app/components/editor/database/filter-sort.ts +220 -18
  179. package/corpus/templates/content/app/hooks/use-content-database.ts +32 -0
  180. package/corpus/templates/content/app/hooks/use-documents.ts +8 -2
  181. package/corpus/templates/content/app/i18n/zh-TW.ts +16 -0
  182. package/corpus/templates/content/app/i18n-data.ts +154 -0
  183. package/corpus/templates/content/changelog/2026-07-08-builder-source-sync-now-completes-reliably-on-hosted-databases.md +6 -0
  184. package/corpus/templates/content/changelog/2026-07-08-database-filters-now-support-notion-style-reset-save-for-eve.md +6 -0
  185. package/corpus/templates/content/changelog/2026-07-08-date-filters-can-now-target-a-between-range.md +6 -0
  186. package/corpus/templates/content/changelog/2026-07-08-fixed-builder-database-sync-so-large-sources-continue-past-t.md +6 -0
  187. package/corpus/templates/content/package.json +2 -2
  188. package/corpus/templates/content/parity/matrix.md +1 -1
  189. package/corpus/templates/content/parity/matrix.ts +2 -0
  190. package/corpus/templates/content/server/plugins/db.ts +19 -0
  191. package/corpus/templates/content/shared/api.ts +24 -0
  192. package/corpus/templates/design/.agents/skills/self-modifying-code/SKILL.md +20 -2
  193. package/corpus/templates/design/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  194. package/corpus/templates/design/package.json +2 -2
  195. package/corpus/templates/dispatch/.agents/skills/self-modifying-code/SKILL.md +20 -2
  196. package/corpus/templates/dispatch/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  197. package/corpus/templates/dispatch/app/i18n/zh-TW.ts +34 -1
  198. package/corpus/templates/dispatch/app/i18n-data.ts +387 -10
  199. package/corpus/templates/dispatch/app/routes/automations.tsx +1 -0
  200. package/corpus/templates/dispatch/changelog/2026-07-08-added-an-automations-page-to-review-pause-and-create.md +6 -0
  201. package/corpus/templates/dispatch/changelog/2026-07-08-destinations-now-shows-outbound-delivery-queue-health.md +6 -0
  202. package/corpus/templates/dispatch/package.json +2 -2
  203. package/corpus/templates/forms/.agents/skills/self-modifying-code/SKILL.md +20 -2
  204. package/corpus/templates/forms/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  205. package/corpus/templates/forms/package.json +2 -2
  206. package/corpus/templates/macros/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  207. package/corpus/templates/macros/package.json +2 -2
  208. package/corpus/templates/mail/.agents/skills/self-modifying-code/SKILL.md +20 -2
  209. package/corpus/templates/mail/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  210. package/corpus/templates/mail/app/hooks/use-emails.ts +56 -44
  211. package/corpus/templates/mail/app/lib/gmail-mutation-queue.ts +325 -0
  212. package/corpus/templates/mail/changelog/2026-07-08-rapid-archive-and-mark-read-now-batch-gmail-updates-so-the-i.md +6 -0
  213. package/corpus/templates/mail/package.json +2 -2
  214. package/corpus/templates/plan/.agents/skills/self-modifying-code/SKILL.md +20 -2
  215. package/corpus/templates/plan/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  216. package/corpus/templates/plan/package.json +2 -2
  217. package/corpus/templates/slides/.agents/skills/self-modifying-code/SKILL.md +20 -2
  218. package/corpus/templates/slides/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  219. package/corpus/templates/slides/app/components/editor/ImageDropPromptPopover.tsx +46 -29
  220. package/corpus/templates/slides/app/context/DeckContext.tsx +45 -18
  221. package/corpus/templates/slides/app/i18n/ar-SA.ts +4 -0
  222. package/corpus/templates/slides/app/i18n/de-DE.ts +4 -0
  223. package/corpus/templates/slides/app/i18n/en-US.ts +4 -0
  224. package/corpus/templates/slides/app/i18n/es-ES.ts +4 -0
  225. package/corpus/templates/slides/app/i18n/fr-FR.ts +4 -0
  226. package/corpus/templates/slides/app/i18n/hi-IN.ts +4 -0
  227. package/corpus/templates/slides/app/i18n/ja-JP.ts +4 -0
  228. package/corpus/templates/slides/app/i18n/ko-KR.ts +4 -0
  229. package/corpus/templates/slides/app/i18n/pt-BR.ts +4 -0
  230. package/corpus/templates/slides/app/i18n/zh-CN.ts +4 -0
  231. package/corpus/templates/slides/app/i18n/zh-TW.ts +4 -0
  232. package/corpus/templates/slides/app/lib/image-drop-to-agent.ts +115 -0
  233. package/corpus/templates/slides/app/pages/DeckEditor.tsx +22 -13
  234. package/corpus/templates/slides/changelog/2026-07-08-dropping-an-image-onto-a-slide-and-sending-it-to-the-agent-w.md +6 -0
  235. package/corpus/templates/slides/changelog/2026-07-08-undo-works-after-the-agent-edits-a-slide-so-you-can-reverse.md +6 -0
  236. package/corpus/templates/slides/package.json +2 -2
  237. package/corpus/templates/videos/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  238. package/corpus/templates/voice/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  239. package/dist/agent/production-agent.d.ts +5 -1
  240. package/dist/agent/production-agent.d.ts.map +1 -1
  241. package/dist/agent/production-agent.js +112 -42
  242. package/dist/agent/production-agent.js.map +1 -1
  243. package/dist/agent/run-manager.d.ts.map +1 -1
  244. package/dist/agent/run-manager.js +23 -2
  245. package/dist/agent/run-manager.js.map +1 -1
  246. package/dist/agent/run-store.js +2 -2
  247. package/dist/agent/run-store.js.map +1 -1
  248. package/dist/agent/tool-search.d.ts +2 -0
  249. package/dist/agent/tool-search.d.ts.map +1 -1
  250. package/dist/agent/tool-search.js +60 -4
  251. package/dist/agent/tool-search.js.map +1 -1
  252. package/dist/catalog.json +2 -2
  253. package/dist/cli/add.js +1 -1
  254. package/dist/cli/add.js.map +1 -1
  255. package/dist/cli/create.d.ts.map +1 -1
  256. package/dist/cli/create.js +8 -3
  257. package/dist/cli/create.js.map +1 -1
  258. package/dist/cli/index.js +24 -4
  259. package/dist/cli/index.js.map +1 -1
  260. package/dist/cli/upgrade.d.ts +100 -0
  261. package/dist/cli/upgrade.d.ts.map +1 -0
  262. package/dist/cli/upgrade.js +678 -0
  263. package/dist/cli/upgrade.js.map +1 -0
  264. package/dist/client/AssistantChat.js +1 -1
  265. package/dist/client/AssistantChat.js.map +1 -1
  266. package/dist/client/HighlightedCodeBlock.d.ts +2 -0
  267. package/dist/client/HighlightedCodeBlock.d.ts.map +1 -1
  268. package/dist/client/HighlightedCodeBlock.js +10 -1
  269. package/dist/client/HighlightedCodeBlock.js.map +1 -1
  270. package/dist/client/agent-chat-adapter.d.ts.map +1 -1
  271. package/dist/client/agent-chat-adapter.js +32 -4
  272. package/dist/client/agent-chat-adapter.js.map +1 -1
  273. package/dist/client/chat/message-components.d.ts.map +1 -1
  274. package/dist/client/chat/message-components.js +61 -8
  275. package/dist/client/chat/message-components.js.map +1 -1
  276. package/dist/client/chat/tool-call-display.d.ts +12 -0
  277. package/dist/client/chat/tool-call-display.d.ts.map +1 -1
  278. package/dist/client/chat/tool-call-display.js +136 -42
  279. package/dist/client/chat/tool-call-display.js.map +1 -1
  280. package/dist/client/code-agent-chat-adapter.js +2 -9
  281. package/dist/client/code-agent-chat-adapter.js.map +1 -1
  282. package/dist/client/extensions/ExtensionSlot.js +6 -0
  283. package/dist/client/extensions/ExtensionSlot.js.map +1 -1
  284. package/dist/client/settings/SettingsPanel.d.ts.map +1 -1
  285. package/dist/client/settings/SettingsPanel.js +52 -19
  286. package/dist/client/settings/SettingsPanel.js.map +1 -1
  287. package/dist/client/settings/SettingsSection.d.ts +19 -4
  288. package/dist/client/settings/SettingsSection.d.ts.map +1 -1
  289. package/dist/client/settings/SettingsSection.js +33 -4
  290. package/dist/client/settings/SettingsSection.js.map +1 -1
  291. package/dist/client/sse-event-processor.d.ts +9 -0
  292. package/dist/client/sse-event-processor.d.ts.map +1 -1
  293. package/dist/client/sse-event-processor.js +20 -2
  294. package/dist/client/sse-event-processor.js.map +1 -1
  295. package/dist/collab/routes.d.ts +1 -1
  296. package/dist/collab/struct-routes.d.ts +1 -1
  297. package/dist/extensions/actions.d.ts.map +1 -1
  298. package/dist/extensions/actions.js +85 -5
  299. package/dist/extensions/actions.js.map +1 -1
  300. package/dist/file-upload/actions/upload-image.d.ts +1 -1
  301. package/dist/jobs/scheduler.js +26 -1
  302. package/dist/jobs/scheduler.js.map +1 -1
  303. package/dist/localization/default-messages.d.ts +19 -0
  304. package/dist/localization/default-messages.d.ts.map +1 -1
  305. package/dist/localization/default-messages.js +19 -0
  306. package/dist/localization/default-messages.js.map +1 -1
  307. package/dist/notifications/channels.d.ts +8 -3
  308. package/dist/notifications/channels.d.ts.map +1 -1
  309. package/dist/notifications/channels.js +61 -22
  310. package/dist/notifications/channels.js.map +1 -1
  311. package/dist/notifications/registry.d.ts.map +1 -1
  312. package/dist/notifications/registry.js +14 -3
  313. package/dist/notifications/registry.js.map +1 -1
  314. package/dist/notifications/routes.d.ts +1 -1
  315. package/dist/notifications/types.d.ts +4 -1
  316. package/dist/notifications/types.d.ts.map +1 -1
  317. package/dist/notifications/types.js.map +1 -1
  318. package/dist/observability/routes.d.ts +1 -1
  319. package/dist/provider-api/corpus-jobs.d.ts +2 -2
  320. package/dist/resources/handlers.d.ts +3 -3
  321. package/dist/server/agent-chat-plugin.d.ts +5 -1
  322. package/dist/server/agent-chat-plugin.d.ts.map +1 -1
  323. package/dist/server/agent-chat-plugin.js +2 -2
  324. package/dist/server/agent-chat-plugin.js.map +1 -1
  325. package/dist/server/agent-engine-api-key-route.d.ts +1 -1
  326. package/dist/server/request-context.d.ts +7 -0
  327. package/dist/server/request-context.d.ts.map +1 -1
  328. package/dist/server/request-context.js.map +1 -1
  329. package/dist/styles/agent-conversation.css +1 -1
  330. package/dist/templates/default/.agents/skills/self-modifying-code/SKILL.md +20 -2
  331. package/dist/templates/default/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  332. package/dist/templates/default/AGENTS.md +10 -3
  333. package/dist/templates/default/app/i18n/ar-SA.ts +21 -0
  334. package/dist/templates/default/app/i18n/de-DE.ts +21 -0
  335. package/dist/templates/default/app/i18n/en-US.ts +21 -0
  336. package/dist/templates/default/app/i18n/es-ES.ts +21 -0
  337. package/dist/templates/default/app/i18n/fr-FR.ts +21 -0
  338. package/dist/templates/default/app/i18n/hi-IN.ts +20 -0
  339. package/dist/templates/default/app/i18n/ja-JP.ts +21 -0
  340. package/dist/templates/default/app/i18n/ko-KR.ts +20 -0
  341. package/dist/templates/default/app/i18n/pt-BR.ts +21 -0
  342. package/dist/templates/default/app/i18n/zh-CN.ts +20 -0
  343. package/dist/templates/default/app/i18n/zh-TW.ts +19 -0
  344. package/dist/templates/default/package.json +4 -3
  345. package/dist/templates/headless/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  346. package/dist/templates/headless/AGENTS.md +9 -3
  347. package/dist/templates/headless/package.json +4 -3
  348. package/dist/templates/workspace-core/.agents/skills/self-modifying-code/SKILL.md +20 -2
  349. package/dist/templates/workspace-core/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  350. package/dist/templates/workspace-core/package.json +6 -6
  351. package/dist/templates/workspace-root/AGENTS.md +10 -4
  352. package/dist/templates/workspace-root/package.json +3 -2
  353. package/dist/triggers/dispatcher.js +27 -2
  354. package/dist/triggers/dispatcher.js.map +1 -1
  355. package/dist/vite/client.d.ts.map +1 -1
  356. package/dist/vite/client.js +70 -1
  357. package/dist/vite/client.js.map +1 -1
  358. package/docs/content/faq.mdx +17 -0
  359. package/docs/content/notifications.mdx +12 -6
  360. package/package.json +7 -6
  361. package/src/templates/default/.agents/skills/self-modifying-code/SKILL.md +20 -2
  362. package/src/templates/default/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  363. package/src/templates/default/AGENTS.md +10 -3
  364. package/src/templates/default/app/i18n/ar-SA.ts +21 -0
  365. package/src/templates/default/app/i18n/de-DE.ts +21 -0
  366. package/src/templates/default/app/i18n/en-US.ts +21 -0
  367. package/src/templates/default/app/i18n/es-ES.ts +21 -0
  368. package/src/templates/default/app/i18n/fr-FR.ts +21 -0
  369. package/src/templates/default/app/i18n/hi-IN.ts +20 -0
  370. package/src/templates/default/app/i18n/ja-JP.ts +21 -0
  371. package/src/templates/default/app/i18n/ko-KR.ts +20 -0
  372. package/src/templates/default/app/i18n/pt-BR.ts +21 -0
  373. package/src/templates/default/app/i18n/zh-CN.ts +20 -0
  374. package/src/templates/default/app/i18n/zh-TW.ts +19 -0
  375. package/src/templates/default/package.json +4 -3
  376. package/src/templates/headless/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  377. package/src/templates/headless/AGENTS.md +9 -3
  378. package/src/templates/headless/package.json +4 -3
  379. package/src/templates/workspace-core/.agents/skills/self-modifying-code/SKILL.md +20 -2
  380. package/src/templates/workspace-core/.agents/skills/upgrade-agent-native/SKILL.md +87 -0
  381. package/src/templates/workspace-core/package.json +6 -6
  382. package/src/templates/workspace-root/AGENTS.md +10 -4
  383. package/src/templates/workspace-root/package.json +3 -2
@@ -1,17 +1,22 @@
1
1
  /**
2
2
  * Built-in notification channels.
3
3
  *
4
- * Set environment variables to auto-register the webhook channel at startup.
4
+ * Webhook and Slack are always registered. Delivery uses (in order):
5
+ * 1. per-notification `metadata.webhookUrl` / `metadata.slackWebhookUrl`
6
+ * 2. the matching `NOTIFICATIONS_*` env URL (workspace default)
7
+ * If neither is set, that channel no-ops for the emission.
8
+ *
5
9
  * Extra channels can be registered at any time via
6
10
  * `registerNotificationChannel()` from a server plugin.
7
11
  *
8
- * NOTIFICATIONS_WEBHOOK_URL → POST notifications as JSON to this URL.
12
+ * NOTIFICATIONS_WEBHOOK_URL → default POST JSON URL when metadata omits one.
9
13
  * Supports `${keys.NAME}` substitution — the raw
10
14
  * value never enters the agent context.
11
15
  * NOTIFICATIONS_WEBHOOK_AUTH → optional `Authorization` header value (also
12
16
  * supports `${keys.NAME}`).
13
17
  * NOTIFICATIONS_SLACK_WEBHOOK_URL
14
- * → POST notifications to a Slack incoming webhook.
18
+ * → default Slack incoming webhook when metadata
19
+ * omits `slackWebhookUrl`.
15
20
  * Supports `${keys.NAME}` substitution.
16
21
  * NOTIFICATIONS_EMAIL_CHANNEL=1
17
22
  * → enable the built-in email channel for
@@ -30,7 +35,7 @@ import {
30
35
  } from "../secrets/substitution.js";
31
36
  import { sendEmail } from "../server/email.js";
32
37
  import { registerNotificationChannel } from "./registry.js";
33
- import type { NotificationChannel } from "./types.js";
38
+ import type { NotificationChannel, NotificationInput } from "./types.js";
34
39
 
35
40
  let _registered = false;
36
41
 
@@ -38,30 +43,38 @@ export function registerBuiltinNotificationChannels(): void {
38
43
  if (_registered) return;
39
44
  _registered = true;
40
45
 
41
- const url = process.env.NOTIFICATIONS_WEBHOOK_URL;
42
- if (url) {
43
- registerNotificationChannel(createWebhookChannel(url));
44
- }
45
-
46
- const slackUrl = process.env.NOTIFICATIONS_SLACK_WEBHOOK_URL;
47
- if (slackUrl) {
48
- registerNotificationChannel(createSlackWebhookChannel(slackUrl));
49
- }
50
-
51
- const emailRecipients = process.env.NOTIFICATIONS_EMAIL_RECIPIENTS?.trim();
52
- if (process.env.NOTIFICATIONS_EMAIL_CHANNEL === "1" || emailRecipients) {
53
- registerNotificationChannel(createEmailChannel());
54
- }
46
+ registerNotificationChannel(
47
+ createWebhookChannel(process.env.NOTIFICATIONS_WEBHOOK_URL),
48
+ );
49
+ registerNotificationChannel(
50
+ createSlackWebhookChannel(process.env.NOTIFICATIONS_SLACK_WEBHOOK_URL),
51
+ );
52
+ // Email is always registered so per-notification `metadata.emailRecipients`
53
+ // work without a workspace-wide env flag (same pattern as webhook/slack).
54
+ registerNotificationChannel(createEmailChannel());
55
55
  }
56
56
 
57
- function createWebhookChannel(urlTemplate: string): NotificationChannel {
57
+ function createWebhookChannel(
58
+ envUrlTemplate: string | undefined,
59
+ ): NotificationChannel {
58
60
  const authTemplate = process.env.NOTIFICATIONS_WEBHOOK_AUTH;
59
61
  return {
60
62
  name: "webhook",
61
63
  async deliver(input, meta) {
64
+ const overrideUrlTemplate = deliveryMetadataString(
65
+ input.metadata,
66
+ "webhookUrl",
67
+ );
68
+ const urlTemplate =
69
+ overrideUrlTemplate ??
70
+ metadataString(input.metadata, "webhookUrl") ??
71
+ envUrlTemplate?.trim();
72
+ // No-op when neither a per-notification nor workspace URL is set —
73
+ // mirrors email's empty-recipients behavior so notify-all stays quiet.
74
+ if (!urlTemplate) return false;
62
75
  const { url, headers } = await resolveWebhookRequest(
63
76
  urlTemplate,
64
- authTemplate,
77
+ overrideUrlTemplate ? undefined : authTemplate,
65
78
  meta.owner,
66
79
  "webhook",
67
80
  );
@@ -74,7 +87,7 @@ function createWebhookChannel(urlTemplate: string): NotificationChannel {
74
87
  severity: input.severity,
75
88
  title: input.title,
76
89
  body: input.body,
77
- metadata: input.metadata,
90
+ metadata: scrubDeliveryMetadata(input.metadata),
78
91
  owner: meta.owner,
79
92
  emittedAt: new Date().toISOString(),
80
93
  }),
@@ -92,14 +105,25 @@ function createWebhookChannel(urlTemplate: string): NotificationChannel {
92
105
  };
93
106
  }
94
107
 
95
- function createSlackWebhookChannel(urlTemplate: string): NotificationChannel {
108
+ function createSlackWebhookChannel(
109
+ envUrlTemplate: string | undefined,
110
+ ): NotificationChannel {
96
111
  const authTemplate = process.env.NOTIFICATIONS_SLACK_WEBHOOK_AUTH;
97
112
  return {
98
113
  name: "slack",
99
114
  async deliver(input, meta) {
115
+ const overrideUrlTemplate = deliveryMetadataString(
116
+ input.metadata,
117
+ "slackWebhookUrl",
118
+ );
119
+ const urlTemplate =
120
+ overrideUrlTemplate ??
121
+ metadataString(input.metadata, "slackWebhookUrl") ??
122
+ envUrlTemplate?.trim();
123
+ if (!urlTemplate) return false;
100
124
  const { url, headers } = await resolveWebhookRequest(
101
125
  urlTemplate,
102
- authTemplate,
126
+ overrideUrlTemplate ? undefined : authTemplate,
103
127
  meta.owner,
104
128
  "Slack webhook",
105
129
  );
@@ -159,7 +183,7 @@ function createEmailChannel(): NotificationChannel {
159
183
  name: "email",
160
184
  async deliver(input) {
161
185
  const recipients = notificationEmailRecipients(input.metadata);
162
- if (recipients.length === 0) return;
186
+ if (recipients.length === 0) return false;
163
187
  const subject =
164
188
  typeof input.metadata?.emailSubject === "string" &&
165
189
  input.metadata.emailSubject.trim()
@@ -240,6 +264,41 @@ async function resolveWebhookRequest(
240
264
  return { url, headers };
241
265
  }
242
266
 
267
+ function metadataString(
268
+ metadata: NotificationInput["metadata"],
269
+ key: string,
270
+ ): string | undefined {
271
+ const value = metadata?.[key];
272
+ if (typeof value !== "string") return undefined;
273
+ const trimmed = value.trim();
274
+ return trimmed || undefined;
275
+ }
276
+
277
+ function deliveryMetadataString(
278
+ metadata: NotificationInput["metadata"],
279
+ key: string,
280
+ ): string | undefined {
281
+ const delivery = metadata?.delivery;
282
+ if (!delivery || typeof delivery !== "object" || Array.isArray(delivery)) {
283
+ return undefined;
284
+ }
285
+ const value = (delivery as Record<string, unknown>)[key];
286
+ if (typeof value !== "string") return undefined;
287
+ const trimmed = value.trim();
288
+ return trimmed || undefined;
289
+ }
290
+
291
+ function scrubDeliveryMetadata(
292
+ metadata: Record<string, unknown> | undefined,
293
+ ): Record<string, unknown> | undefined {
294
+ if (!metadata) return undefined;
295
+ const entries = Object.entries(metadata).filter(
296
+ ([key]) =>
297
+ key !== "delivery" && key !== "webhookUrl" && key !== "slackWebhookUrl",
298
+ );
299
+ return entries.length ? Object.fromEntries(entries) : undefined;
300
+ }
301
+
243
302
  function notificationEmailRecipients(
244
303
  metadata: Record<string, unknown> | undefined,
245
304
  ): string[] {
@@ -275,7 +334,11 @@ function scrubEmailMetadata(
275
334
  ): Record<string, unknown> | null {
276
335
  if (!metadata) return null;
277
336
  const entries = Object.entries(metadata).filter(
278
- ([key]) => key !== "emailRecipients" && key !== "emailSubject",
337
+ ([key]) =>
338
+ key !== "emailRecipients" &&
339
+ key !== "emailSubject" &&
340
+ key !== "webhookUrl" &&
341
+ key !== "slackWebhookUrl",
279
342
  );
280
343
  return entries.length ? Object.fromEntries(entries) : null;
281
344
  }
@@ -105,6 +105,7 @@ export async function notifyWithDelivery(
105
105
  body: truncate(input.body, MAX_BODY_LEN),
106
106
  };
107
107
  const channels = selectChannels(input.channels);
108
+ const storedMetadata = scrubStoredMetadata(input.metadata);
108
109
 
109
110
  // The inbox channel is always included unless explicitly excluded.
110
111
  const runInbox = !input.channels || input.channels.includes("inbox");
@@ -120,7 +121,7 @@ export async function notifyWithDelivery(
120
121
  severity: input.severity,
121
122
  title: input.title,
122
123
  body: input.body,
123
- metadata: input.metadata,
124
+ metadata: storedMetadata,
124
125
  deliveredChannels: ["inbox"],
125
126
  });
126
127
  delivered.push("inbox");
@@ -132,13 +133,15 @@ export async function notifyWithDelivery(
132
133
  // Await every channel so a 500-ing webhook doesn't end up in `delivered`.
133
134
  const results = await Promise.allSettled(
134
135
  channels.map(async (channel) => {
135
- await channel.deliver(input, meta);
136
+ const delivered = await channel.deliver(input, meta);
137
+ // Explicit `false` means the channel skipped (no URL / recipients).
138
+ if (delivered === false) return null;
136
139
  return channel.name;
137
140
  }),
138
141
  );
139
142
  results.forEach((r, i) => {
140
143
  if (r.status === "fulfilled") {
141
- delivered.push(r.value);
144
+ if (r.value) delivered.push(r.value);
142
145
  } else {
143
146
  console.error(
144
147
  `[notifications] channel "${channels[i].name}" failed:`,
@@ -181,6 +184,17 @@ export async function notifyWithDelivery(
181
184
  return { notification: stored, deliveredChannels: delivered };
182
185
  }
183
186
 
187
+ function scrubStoredMetadata(
188
+ metadata: Record<string, unknown> | undefined,
189
+ ): Record<string, unknown> | undefined {
190
+ if (!metadata) return undefined;
191
+ const entries = Object.entries(metadata).filter(
192
+ ([key]) =>
193
+ key !== "delivery" && key !== "webhookUrl" && key !== "slackWebhookUrl",
194
+ );
195
+ return entries.length ? Object.fromEntries(entries) : undefined;
196
+ }
197
+
184
198
  function selectChannels(allowlist?: string[]): NotificationChannel[] {
185
199
  const registry = getRegistry();
186
200
  const all = Array.from(registry.values());
@@ -41,9 +41,12 @@ export interface NotificationChannel {
41
41
  /**
42
42
  * Deliver the notification. Must be best-effort — throwing will be logged
43
43
  * but will not block other channels from running.
44
+ *
45
+ * Return `false` to skip (e.g. no URL / no recipients configured) so the
46
+ * channel is not recorded in `deliveredChannels`.
44
47
  */
45
48
  deliver(
46
49
  input: NotificationInput,
47
50
  meta: NotificationMeta,
48
- ): void | Promise<void>;
51
+ ): void | boolean | Promise<void | boolean>;
49
52
  }
@@ -2739,7 +2739,11 @@ export interface AgentChatPluginOptions {
2739
2739
  * agent starts with only these tools plus `tool-search`; the live registry
2740
2740
  * remains searchable, and matching schemas from `tool-search` results are
2741
2741
  * loaded into the next model request. Use this for domain-focused apps that
2742
- * have a few common actions and many rare framework utilities.
2742
+ * have a few common actions and many rare framework utilities. Common
2743
+ * provider/corpus/code-execution tools are promoted automatically when present
2744
+ * in the current app/mode registry, so broad integration guidance stays
2745
+ * immediately callable without overloading apps that do not expose those
2746
+ * tools.
2743
2747
  */
2744
2748
  initialToolNames?: string[];
2745
2749
  /**
@@ -3127,7 +3131,7 @@ Keep \`create-extension\` payloads compact enough to finish quickly. For complex
3127
3131
 
3128
3132
  Generated UI content can use appAction(), appFetch(), dbQuery(), extensionFetch(), extensionData, agentNative.ui.output(value, opts?), and agentNative.chat.send(...)/sendToAgentChat(...). Use appAction() for app data writes, and dbQuery() only for read-only inspection of known app SQL tables. It can receive chat inputs through slotContext/window.onSlotContext. Use agentNative.ui.output for passive current values from knobs, sliders, selections, and controls; it writes application state at \`inline-ui:<extensionId>:output\` scoped to the inline extension id returned by \`render-inline-extension\` or \`show-extension-inline\`. When the user later says "use that value", "apply the current setting", or similar, read it with \`readAppState("inline-ui:<id>:output")\` instead of asking them to send it again. Use agentNative.chat.send for visible submit/apply actions that should put a message into chat. Transient extensionData is browser-local and not agent-readable, synced, promoted, or garbage-collected; use application_state/appFetch, appAction, ui.output, or chat.send for anything the agent or app must observe. Use semantic Tailwind classes like bg-background, text-foreground, bg-primary, border-border, and text-muted-foreground so the UI inherits the parent app theme.
3129
3133
 
3130
- If the user asks to change, edit, fix, style, rename, or add behavior to an existing extension/widget/dashboard/calculator/mini-app, use the current extension id from \`<current-screen>\` or \`<current-url>\` when present. Call \`get-extension\` only if you need to inspect its content, then \`update-extension\` with that id. Use \`list-extensions\` only when no current id/name is available. Existing extension edits are SQL data updates, not source-code changes, even when the request says "change the UI" or "fix this". Do **NOT** call \`connect-builder\` for existing extension edits.
3134
+ If the user asks to change, edit, fix, style, rename, or add behavior to an existing extension/widget/dashboard/calculator/mini-app, use the current extension id from \`<current-screen>\` or \`<current-url>\` when present. Call \`get-extension\` only if you need to inspect its content, then \`update-extension\` with that id. After one content read, keep the body in working memory and move to focused \`update-extension\` \`edits\`/\`patches\`; do not loop on repeated \`get-extension\` + \`run-code\` string scans before writing. Use \`list-extensions\` only when no current id/name is available. Existing extension edits are SQL data updates, not source-code changes, even when the request says "change the UI" or "fix this". Do **NOT** call \`connect-builder\` for existing extension edits.
3131
3135
 
3132
3136
  In Act mode, when in doubt — if the request asks for a new small interactive utility and does not need reuse, choose \`render-inline-extension\`; if it mentions saving/reuse or asks for an extension/widget/dashboard/calculator/mini-app, choose \`create-extension\`. If it references an existing one or the current extension page, choose \`update-extension\`. Do **not** preface the call with planning text like "let me build the dashboard…" — just call the right extension action directly.
3133
3137
 
@@ -3165,7 +3169,7 @@ Keep the first \`create-extension\` call compact and working. If the request is
3165
3169
 
3166
3170
  Generated UI can read chat inputs from slotContext/window.onSlotContext, see/update app state through appFetch/appAction, use extensionData, record passive current values through agentNative.ui.output(value, opts?), and send visible results through agentNative.chat.send(...) or sendToAgentChat(...). ui.output writes \`inline-ui:<extensionId>:output\` in application state; when the user asks to use the current slider/selection/value, read \`readAppState("inline-ui:<id>:output")\`. Transient extensionData is browser-local only, so do not rely on it for values the agent or app must observe. Use semantic Tailwind theme classes.
3167
3171
 
3168
- If the user asks to change, edit, fix, style, rename, or add behavior to an existing extension/widget/dashboard/calculator/mini-app, use the current extension id from \`<current-screen>\` or \`<current-url>\` when present. Call \`get-extension\` only if you need to inspect its content, then \`update-extension\` with that id. Use \`list-extensions\` only when no current id/name is available. Existing extension edits are SQL data updates, not source-code changes. Do NOT call \`connect-builder\` for them.
3172
+ If the user asks to change, edit, fix, style, rename, or add behavior to an existing extension/widget/dashboard/calculator/mini-app, use the current extension id from \`<current-screen>\` or \`<current-url>\` when present. Call \`get-extension\` only if you need to inspect its content, then \`update-extension\` with that id. After one content read, use focused \`update-extension\` \`edits\`/\`patches\`; do not repeatedly re-read and scan the same HTML with \`run-code\` before writing. Use \`list-extensions\` only when no current id/name is available. Existing extension edits are SQL data updates, not source-code changes. Do NOT call \`connect-builder\` for them.
3169
3173
 
3170
3174
  For existing extensions, use \`get-extension\` or \`update-extension\` directly when \`<current-screen>\` or \`<current-url>\` provides an \`extensionId\`. Use \`list-extensions\` only to browse or resolve an unknown name. Use \`hide-extension\` when the user wants a shared extension removed only from their own view. Do not query the legacy \`tools\` table directly.
3171
3175
 
@@ -118,6 +118,13 @@ export interface RequestRunContext {
118
118
  toolCalls?: Array<{ name: string; input: unknown }>;
119
119
  /** Tool results returned so far in the current agent loop. */
120
120
  toolResults?: Array<{ name: string; content: string; isError: boolean }>;
121
+ /** Per-run fingerprints for large extension bodies already sent to the LLM. */
122
+ extensionContentReads?: Record<string, string>;
123
+ /** Per-run fingerprints for repeated tool-search calls already sent to the LLM. */
124
+ toolSearchReads?: Record<
125
+ string,
126
+ { totalTools: number; resultNames: string[] }
127
+ >;
121
128
  }
122
129
 
123
130
  export interface RequestContext {
@@ -684,7 +684,7 @@
684
684
  }
685
685
  }
686
686
 
687
- /* Tool-code viewer that uses shiki inside the ToolDetailViewer. */
687
+ /* Tool-code viewer that uses shiki inside the Codex-style gray box. */
688
688
  .agent-tool-code .agent-markdown-shiki {
689
689
  margin: 0;
690
690
  border-radius: 0;
@@ -28,7 +28,19 @@ Not all modifications are equal. Use this to decide what level of care is needed
28
28
  | 1: Data | Files in `data/` | JSON state, generated content, markdown | Nothing — these are routine |
29
29
  | 2: Source | App code | Components, routes, styles, scripts | Run `pnpm typecheck && pnpm lint` |
30
30
  | 3: Config | Project config | `package.json`, `tsconfig.json`, `vite.config.*` | Ask for explicit approval first |
31
- | 4: Off limits | Secrets and framework | `.env`, `@agent-native/core` internals | Never modify these |
31
+ | 4: Off limits | Secrets and framework | `.env`, `@agent-native/*` packages & overrides | Never modify these |
32
+
33
+ Tier 4 includes **all** of the following — not only editing package source:
34
+
35
+ - Files under `node_modules/@agent-native/*` (core, dispatch, scheduling, …)
36
+ - `pnpm.overrides`, `overrides`, `resolutions`, or `patchedDependencies` that
37
+ target any `@agent-native/*` package
38
+ - Local patches, vendored copies, or invented "dispatch/core behavior"
39
+ shims meant to paper over a version skew or failed upgrade
40
+
41
+ When an older branch needs current packages, use **`agent-native upgrade`**
42
+ (see the `upgrade-agent-native` skill). If upgrade or typecheck fails, fix
43
+ **app** code or stop and ask — do not patch the framework.
32
44
 
33
45
  ## Git Checkpoint Pattern
34
46
 
@@ -74,13 +86,19 @@ inline strings in components.
74
86
  ## Don't
75
87
 
76
88
  - Don't modify `.env` files or files containing secrets
77
- - Don't modify `@agent-native/core` package internals
89
+ - Don't modify `@agent-native/core`, `@agent-native/dispatch`, or other
90
+ `@agent-native/*` package internals (including under `node_modules`)
91
+ - Don't add `pnpm.overrides` / `patchedDependencies` / `resolutions` for
92
+ `@agent-native/*` to "make the app run" after a version bump
93
+ - Don't invent local dispatch/core behavior overrides when upgrade fails —
94
+ run `npx @agent-native/core@latest upgrade`, then fix app-level errors only
78
95
  - Don't modify `.agents/skills/` or `AGENTS.md` unless explicitly requested
79
96
  - Don't skip the typecheck/lint step after editing source code
80
97
  - Don't make source changes without a git checkpoint to roll back to
81
98
 
82
99
  ## Related Skills
83
100
 
101
+ - **upgrade-agent-native** — supported path to bring an older app/workspace current
84
102
  - **storing-data** — Tier 1 modifications (data files) are the safest and most common
85
103
  - **actions** — The agent can create or modify actions to add new capabilities
86
104
  - **delegate-to-agent** — Self-modification requests come through the agent chat
@@ -0,0 +1,87 @@
1
+ ---
2
+ name: upgrade-agent-native
3
+ description: >-
4
+ Bring an older Agent Native app or workspace current. Use when updating
5
+ @agent-native/core, fixing a broken upgrade, or when tempted to patch or
6
+ override core/dispatch packages to make an old branch run.
7
+ scope: dev
8
+ metadata:
9
+ internal: true
10
+ ---
11
+
12
+ # Upgrade Agent Native
13
+
14
+ ## Rule
15
+
16
+ When an older Agent Native app/branch needs to run on current packages, use
17
+ `agent-native upgrade`. Never "fix" upgrade breakage with
18
+ `pnpm.overrides`, `patchedDependencies`, `resolutions`, local patches, or
19
+ edits under `node_modules/@agent-native/*` — especially not against
20
+ `@agent-native/core` or `@agent-native/dispatch`.
21
+
22
+ ## Why
23
+
24
+ Agents often respond to a failed core bump by inventing framework patches and
25
+ dispatch behavior overrides. That hides the real app-level break, drifts from
26
+ upstream, and makes the next upgrade worse. The supported path is bump →
27
+ install → refresh scaffold skills → verify, then fix **app** code only.
28
+
29
+ ## How
30
+
31
+ 1. **Doctor first (optional but recommended)**
32
+
33
+ ```bash
34
+ npx @agent-native/core@latest upgrade check
35
+ ```
36
+
37
+ This reports framework overrides/patches and pending `@agent-native/*`
38
+ bumps. If overrides/patches are present, remove them before continuing.
39
+
40
+ 2. **Run the upgrade**
41
+
42
+ ```bash
43
+ npx @agent-native/core@latest upgrade
44
+ ```
45
+
46
+ Or from an already-installed CLI: `pnpm exec agent-native upgrade` /
47
+ `agent-native upgrade`.
48
+
49
+ What it does:
50
+
51
+ - Blocks (unless `--force`) when `@agent-native/*` overrides/patches exist
52
+ - Rewrites non-local `@agent-native/*` dependency pins to `latest`
53
+ - Runs the package manager install
54
+ - Runs `skills update scaffold --project`
55
+ - Runs `typecheck` when the project has that script
56
+
57
+ 3. **If upgrade or typecheck fails**
58
+
59
+ - Read the concrete error
60
+ - Fix **app** source, actions, config, or env — not framework packages
61
+ - Re-run `agent-native upgrade` or `pnpm typecheck`
62
+ - Stop and ask the user if you cannot fix the app-level error
63
+
64
+ 4. **Dry-run / partial runs**
65
+
66
+ ```bash
67
+ agent-native upgrade --dry-run
68
+ agent-native upgrade --skip-verify
69
+ agent-native upgrade --skip-install # package.json bumps only
70
+ ```
71
+
72
+ ## Don't
73
+
74
+ - Don't add `pnpm.overrides`, `overrides`, `resolutions`, or
75
+ `patchedDependencies` for any `@agent-native/*` package
76
+ - Don't edit `node_modules/@agent-native/core` or
77
+ `node_modules/@agent-native/dispatch`
78
+ - Don't invent local "dispatch behavior" shims to paper over version skew
79
+ - Don't keep iterating with more framework patches after a failed install
80
+ - Don't skip `skills update scaffold --project` after a core bump (the
81
+ upgrade command does this for you)
82
+
83
+ ## Related Skills
84
+
85
+ - **self-modifying-code** — Tier 4: framework packages are off limits
86
+ - **agent-native-docs** — version-matched docs after the bump
87
+ - **portability** — keep app code provider-agnostic across upgrades
@@ -38,9 +38,15 @@ Read these local package docs before implementing advanced Agent Native
38
38
  features. Prefer this app's own `AGENTS.md` and `.agents/skills/` for
39
39
  app-specific rules, then use the corpus for reusable framework/template
40
40
  patterns.
41
- After updating `@agent-native/core`, run `pnpm skills:update` or
42
- `npx @agent-native/core@latest skills update scaffold --project` from the app
43
- root to refresh framework-provided `.agents/skills` and repair `CLAUDE.md` /
41
+ To bring an older app current, run `pnpm upgrade:agent-native` or
42
+ `npx @agent-native/core@latest upgrade` from the app root. That bumps
43
+ `@agent-native/*` deps, installs, refreshes scaffold skills, and typechecks.
44
+ Do **not** add `pnpm.overrides` / patches against `@agent-native/*` or edit
45
+ `node_modules/@agent-native/*` when an upgrade fails — fix app code or ask.
46
+ See the `upgrade-agent-native` and `self-modifying-code` skills.
47
+ After a manual core bump only, `pnpm skills:update` (or
48
+ `npx @agent-native/core@latest skills update scaffold --project`) still
49
+ refreshes framework-provided `.agents/skills` and repairs `CLAUDE.md` /
44
50
  `.claude/skills` compatibility links.
45
51
 
46
52
  ### Database Code
@@ -150,6 +156,7 @@ Skills in `.agents/skills/` provide detailed guidance for each architectural rul
150
156
  | `delegate-to-agent` | Before adding LLM calls or AI delegation |
151
157
  | `actions` | Before creating or modifying actions |
152
158
  | `self-modifying-code` | Before editing source, components, or styles |
159
+ | `upgrade-agent-native` | Before updating an older app/branch or when tempted to patch `@agent-native/*` |
153
160
  | `capture-learnings` | Before recording user preferences or corrections |
154
161
  | `frontend-design` | Before building or restyling any UI component, page, or layout |
155
162
  | `shadcn-ui` | Before adding, updating, or debugging shadcn/ui components |
@@ -41,6 +41,8 @@ const messages = {
41
41
  destinations: "Destinations",
42
42
  identities: "Identities",
43
43
  approvals: "الموافقات",
44
+ automations: "الأتمتة",
45
+ delivery: "التسليم",
44
46
  audit: "Audit",
45
47
  dreams: "Dreams",
46
48
  threadDebug: "تصحيح الموضوع",
@@ -159,6 +161,22 @@ const messages = {
159
161
  activeUsers: "المستخدمين النشطين",
160
162
  workspaceAppsStat: "تطبيقات مساحة العمل",
161
163
  chatThreads: "مواضيع الدردشة",
164
+ also: "أيضًا",
165
+ workspaceShortcutsAria: "اختصارات مساحة العمل",
166
+ deliveryQueue: "قائمة انتظار التسليم",
167
+ failedLastHour: "{{count}} فشل خلال الساعة الماضية",
168
+ processingCount: "{{count}} قيد المعالجة",
169
+ queued: "في الانتظار",
170
+ active: "نشط",
171
+ done1h: "تم خلال ساعة",
172
+ failed1h: "فشل خلال ساعة",
173
+ oldestQueued: "الأقدم في الانتظار: {{age}}",
174
+ queueAgeNone: "لا شيء",
175
+ queueFailureHint:
176
+ "تحقق من بيانات الاعتماد والوجهات وأخطاء قائمة الانتظار الأخيرة.",
177
+ unknownPlatform: "غير معروف",
178
+ attemptsCount: "{{count}} محاولات",
179
+ noErrorMessage: "(لا توجد رسالة خطأ)",
162
180
  },
163
181
  },
164
182
  agentPanel: {
@@ -346,6 +364,9 @@ const messages = {
346
364
  contactSidebarWidget: "الاتصال القطعة الشريط الجانبي",
347
365
  contactSidebarDescription:
348
366
  "يظهر بجانب المحادثة الحالية مع سياق جهة الاتصال وسلسلة المحادثات.",
367
+ eventDetailWidget: "أداة تفاصيل الحدث",
368
+ eventDetailDescription:
369
+ "تظهر أسفل حدث التقويم المفتوح مع سياق الحدث والحضور.",
349
370
  addWidgetHere: "أضف القطعة هنا",
350
371
  back: "رجوع",
351
372
  editExtension: "تحرير التمديد",
@@ -43,6 +43,8 @@ const messages = {
43
43
  destinations: "Destinations",
44
44
  identities: "Identities",
45
45
  approvals: "Zulassungen",
46
+ automations: "Automatisierungen",
47
+ delivery: "Zustellung",
46
48
  audit: "Audit",
47
49
  dreams: "Dreams",
48
50
  threadDebug: "Thread-Debug",
@@ -160,6 +162,22 @@ const messages = {
160
162
  activeUsers: "Aktive Benutzer",
161
163
  workspaceAppsStat: "Workspace-Apps",
162
164
  chatThreads: "Chat-Threads",
165
+ also: "Außerdem",
166
+ workspaceShortcutsAria: "Workspace-Kurzbefehle",
167
+ deliveryQueue: "Zustellungswarteschlange",
168
+ failedLastHour: "{{count}} fehlgeschlagen in der letzten Stunde",
169
+ processingCount: "{{count}} in Bearbeitung",
170
+ queued: "Warteschlange",
171
+ active: "Aktiv",
172
+ done1h: "Erledigt 1 Std.",
173
+ failed1h: "Fehlgeschlagen 1 Std.",
174
+ oldestQueued: "Älteste Warteschlange: {{age}}",
175
+ queueAgeNone: "keine",
176
+ queueFailureHint:
177
+ "Prüfe Anmeldedaten, Ziele und aktuelle Warteschlangenfehler.",
178
+ unknownPlatform: "unbekannt",
179
+ attemptsCount: "{{count}} Versuche",
180
+ noErrorMessage: "(keine Fehlermeldung)",
163
181
  },
164
182
  },
165
183
  agentPanel: {
@@ -339,6 +357,9 @@ const messages = {
339
357
  contactSidebarWidget: "Kontakt-Sidebar-Widget",
340
358
  contactSidebarDescription:
341
359
  "Erscheint neben der aktuellen Konversation mit Kontakt- und Thread-Kontext.",
360
+ eventDetailWidget: "Ereignisdetail-Widget",
361
+ eventDetailDescription:
362
+ "Erscheint unter dem geöffneten Kalenderereignis mit Ereignis- und Teilnehmerkontext.",
342
363
  addWidgetHere: "Widget hier hinzufügen",
343
364
  back: "Zurück",
344
365
  editExtension: "Erweiterung bearbeiten",
@@ -42,6 +42,8 @@ const messages = {
42
42
  destinations: "Destinations",
43
43
  identities: "Identities",
44
44
  approvals: "Approvals",
45
+ automations: "Automations",
46
+ delivery: "Delivery",
45
47
  audit: "Audit",
46
48
  dreams: "Dreams",
47
49
  threadDebug: "Thread Debug",
@@ -156,6 +158,22 @@ const messages = {
156
158
  activeUsers: "Active users",
157
159
  workspaceAppsStat: "Workspace apps",
158
160
  chatThreads: "Chat threads",
161
+ also: "Also",
162
+ workspaceShortcutsAria: "Workspace shortcuts",
163
+ deliveryQueue: "Delivery queue",
164
+ failedLastHour: "{{count}} failed in the last hour",
165
+ processingCount: "{{count}} processing",
166
+ queued: "Queued",
167
+ active: "Active",
168
+ done1h: "Done 1h",
169
+ failed1h: "Failed 1h",
170
+ oldestQueued: "Oldest queued: {{age}}",
171
+ queueAgeNone: "none",
172
+ queueFailureHint:
173
+ "Check credentials, destinations, and recent queue errors.",
174
+ unknownPlatform: "unknown",
175
+ attemptsCount: "{{count}} attempts",
176
+ noErrorMessage: "(no error message)",
159
177
  },
160
178
  },
161
179
  agentPanel: {
@@ -330,6 +348,9 @@ const messages = {
330
348
  contactSidebarWidget: "Contact sidebar widget",
331
349
  contactSidebarDescription:
332
350
  "Appears beside the current conversation with contact and thread context.",
351
+ eventDetailWidget: "Event detail widget",
352
+ eventDetailDescription:
353
+ "Appears below the open calendar event with event and attendee context.",
333
354
  addWidgetHere: "Add widget here",
334
355
  back: "Back",
335
356
  editExtension: "Edit Extension",
@@ -43,6 +43,8 @@ const messages = {
43
43
  destinations: "Destinations",
44
44
  identities: "Identities",
45
45
  approvals: "Aprobaciones",
46
+ automations: "Automatizaciones",
47
+ delivery: "Entrega",
46
48
  audit: "Audit",
47
49
  dreams: "Dreams",
48
50
  threadDebug: "Depuración de subprocesos",
@@ -161,6 +163,22 @@ const messages = {
161
163
  activeUsers: "Usuarios activos",
162
164
  workspaceAppsStat: "Aplicaciones de espacio de trabajo",
163
165
  chatThreads: "Hilos de chat",
166
+ also: "También",
167
+ workspaceShortcutsAria: "Accesos directos del espacio de trabajo",
168
+ deliveryQueue: "Cola de entrega",
169
+ failedLastHour: "{{count}} fallos en la última hora",
170
+ processingCount: "{{count}} en proceso",
171
+ queued: "En cola",
172
+ active: "Activo",
173
+ done1h: "Hecho 1 h",
174
+ failed1h: "Fallido 1 h",
175
+ oldestQueued: "Más antiguo en cola: {{age}}",
176
+ queueAgeNone: "ninguno",
177
+ queueFailureHint:
178
+ "Revisa las credenciales, los destinos y los errores recientes de la cola.",
179
+ unknownPlatform: "desconocido",
180
+ attemptsCount: "{{count}} intentos",
181
+ noErrorMessage: "(sin mensaje de error)",
164
182
  },
165
183
  },
166
184
  agentPanel: {
@@ -344,6 +362,9 @@ const messages = {
344
362
  contactSidebarWidget: "Widget de la barra lateral de contacto",
345
363
  contactSidebarDescription:
346
364
  "Aparece junto a la conversación actual con el contexto del contacto y del hilo.",
365
+ eventDetailWidget: "Widget de detalle del evento",
366
+ eventDetailDescription:
367
+ "Aparece debajo del evento de calendario abierto con el contexto del evento y los asistentes.",
347
368
  addWidgetHere: "Añadir widget aquí",
348
369
  back: "Volver",
349
370
  editExtension: "Editar extensión",