@agent-native/core 0.90.10 → 0.91.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 (360) hide show
  1. package/corpus/README.md +2 -2
  2. package/corpus/core/CHANGELOG.md +30 -0
  3. package/corpus/core/docs/content/toolkit-settings.mdx +56 -3
  4. package/corpus/core/package.json +2 -1
  5. package/corpus/core/src/agent/durable-background.ts +5 -5
  6. package/corpus/core/src/agent/engine/ai-sdk-engine.ts +40 -8
  7. package/corpus/core/src/agent/engine/anthropic-engine.ts +25 -7
  8. package/corpus/core/src/agent/engine/output-tokens.ts +94 -0
  9. package/corpus/core/src/agent/production-agent.ts +34 -6
  10. package/corpus/core/src/agent/run-ownership.ts +29 -1
  11. package/corpus/core/src/agent/types.ts +3 -2
  12. package/corpus/core/src/changelog/parse.ts +78 -0
  13. package/corpus/core/src/chat-threads/schema.ts +43 -0
  14. package/corpus/core/src/chat-threads/store.ts +144 -12
  15. package/corpus/core/src/cli/workspace-dev.ts +25 -5
  16. package/corpus/core/src/client/AgentPanel.tsx +79 -14
  17. package/corpus/core/src/client/AssistantChat.tsx +359 -425
  18. package/corpus/core/src/client/analytics-session.ts +70 -0
  19. package/corpus/core/src/client/analytics.ts +175 -49
  20. package/corpus/core/src/client/chat/message-components.tsx +22 -2
  21. package/corpus/core/src/client/components/ui/message-scroller.tsx +131 -0
  22. package/corpus/core/src/client/conversation/AgentConversation.tsx +63 -41
  23. package/corpus/core/src/client/error-capture.ts +616 -0
  24. package/corpus/core/src/client/index.ts +12 -0
  25. package/corpus/core/src/client/session-replay.ts +57 -7
  26. package/corpus/core/src/client/settings/SettingsPanel.tsx +123 -1
  27. package/corpus/core/src/client/settings/SettingsTabsPage.tsx +292 -45
  28. package/corpus/core/src/client/settings/index.ts +1 -0
  29. package/corpus/core/src/client/sharing/ShareButton.tsx +14 -11
  30. package/corpus/core/src/client/sharing/ShareDialog.tsx +13 -10
  31. package/corpus/core/src/db/client.ts +12 -9
  32. package/corpus/core/src/mcp/builtin-tools.ts +29 -2
  33. package/corpus/core/src/server/agent-chat-plugin.ts +174 -79
  34. package/corpus/core/src/server/onboarding-html.ts +28 -16
  35. package/corpus/core/src/shared/reasoning-effort.ts +23 -0
  36. package/corpus/core/src/sharing/actions/list-resource-shares.ts +45 -1
  37. package/corpus/core/src/sharing/actions/share-resource.ts +9 -0
  38. package/corpus/core/src/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +4 -2
  39. package/corpus/core/src/templates/workspace-core/.agents/skills/changelog/SKILL.md +9 -6
  40. package/corpus/core/src/vite/client.ts +217 -35
  41. package/corpus/templates/analytics/.agents/skills/adhoc-analysis/SKILL.md +8 -7
  42. package/corpus/templates/analytics/.agents/skills/analysis-workspace/SKILL.md +14 -10
  43. package/corpus/templates/analytics/.agents/skills/bigquery/SKILL.md +15 -15
  44. package/corpus/templates/analytics/.agents/skills/cross-source-analysis/SKILL.md +1 -0
  45. package/corpus/templates/analytics/.agents/skills/dashboard-management/SKILL.md +38 -22
  46. package/corpus/templates/analytics/.agents/skills/data-programs/SKILL.md +114 -61
  47. package/corpus/templates/analytics/.agents/skills/data-querying/SKILL.md +1 -0
  48. package/corpus/templates/analytics/.agents/skills/gong/SKILL.md +7 -7
  49. package/corpus/templates/analytics/.agents/skills/hubspot/SKILL.md +1 -0
  50. package/corpus/templates/analytics/.agents/skills/prometheus/SKILL.md +1 -1
  51. package/corpus/templates/analytics/.builder/skills/bigquery/SKILL.md +17 -17
  52. package/corpus/templates/analytics/.builder/skills/gcloud/SKILL.md +5 -5
  53. package/corpus/templates/analytics/.builder/skills/github/SKILL.md +7 -7
  54. package/corpus/templates/analytics/.builder/skills/gong/SKILL.md +12 -12
  55. package/corpus/templates/analytics/.builder/skills/grafana/SKILL.md +7 -7
  56. package/corpus/templates/analytics/.builder/skills/sentry/SKILL.md +7 -7
  57. package/corpus/templates/analytics/.builder/skills/slack/SKILL.md +6 -6
  58. package/corpus/templates/analytics/.builder/skills/stripe/SKILL.md +7 -7
  59. package/corpus/templates/analytics/AGENTS.md +47 -2
  60. package/corpus/templates/analytics/actions/add-status-page-monitor.ts +36 -0
  61. package/corpus/templates/analytics/actions/capture-test-error.ts +33 -0
  62. package/corpus/templates/analytics/actions/delete-monitor.ts +24 -0
  63. package/corpus/templates/analytics/actions/delete-status-page.ts +23 -0
  64. package/corpus/templates/analytics/actions/get-error-issue.ts +36 -0
  65. package/corpus/templates/analytics/actions/get-monitor-stats.ts +55 -0
  66. package/corpus/templates/analytics/actions/get-monitor.ts +27 -0
  67. package/corpus/templates/analytics/actions/get-public-status-page.ts +41 -0
  68. package/corpus/templates/analytics/actions/get-status-page.ts +29 -0
  69. package/corpus/templates/analytics/actions/list-error-issues.ts +40 -0
  70. package/corpus/templates/analytics/actions/list-monitors.ts +21 -0
  71. package/corpus/templates/analytics/actions/list-status-pages.ts +21 -0
  72. package/corpus/templates/analytics/actions/match-error-issues.ts +51 -0
  73. package/corpus/templates/analytics/actions/navigate.ts +58 -4
  74. package/corpus/templates/analytics/actions/remove-status-page-monitor.ts +22 -0
  75. package/corpus/templates/analytics/actions/reorder-status-page-monitors.ts +25 -0
  76. package/corpus/templates/analytics/actions/resolve-error-issue.ts +38 -0
  77. package/corpus/templates/analytics/actions/run-monitor-check.ts +23 -0
  78. package/corpus/templates/analytics/actions/save-analysis.ts +1 -0
  79. package/corpus/templates/analytics/actions/save-monitor.ts +145 -0
  80. package/corpus/templates/analytics/actions/save-status-page.ts +47 -0
  81. package/corpus/templates/analytics/actions/view-screen.ts +212 -0
  82. package/corpus/templates/analytics/app/components/layout/Header.tsx +1 -0
  83. package/corpus/templates/analytics/app/components/layout/Layout.tsx +10 -1
  84. package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +134 -39
  85. package/corpus/templates/analytics/app/components/monitoring/PublicStatusView.tsx +351 -0
  86. package/corpus/templates/analytics/app/components/monitoring/ResponseTimeChart.tsx +174 -0
  87. package/corpus/templates/analytics/app/components/monitoring/UptimeStatCards.tsx +85 -0
  88. package/corpus/templates/analytics/app/components/monitoring/UptimeTimelineBars.tsx +106 -0
  89. package/corpus/templates/analytics/app/components/monitoring/chart-utils.ts +101 -0
  90. package/corpus/templates/analytics/app/components/monitoring/index.ts +28 -0
  91. package/corpus/templates/analytics/app/components/monitoring/types.ts +42 -0
  92. package/corpus/templates/analytics/app/hooks/use-navigation-state.ts +34 -0
  93. package/corpus/templates/analytics/app/i18n/zh-TW.ts +6 -0
  94. package/corpus/templates/analytics/app/i18n-data.ts +33 -0
  95. package/corpus/templates/analytics/app/pages/DataSources.tsx +28 -0
  96. package/corpus/templates/analytics/app/pages/Settings.tsx +77 -9
  97. package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/SqlChartCard.tsx +3 -3
  98. package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/dashboard-layout.ts +7 -0
  99. package/corpus/templates/analytics/app/pages/monitoring/ErrorsPanel.tsx +205 -0
  100. package/corpus/templates/analytics/app/pages/monitoring/MonitoringPage.tsx +100 -0
  101. package/corpus/templates/analytics/app/pages/monitoring/UptimePanel.tsx +475 -0
  102. package/corpus/templates/analytics/app/pages/monitoring/errors/IssueDetail.tsx +372 -0
  103. package/corpus/templates/analytics/app/pages/monitoring/errors/IssueList.tsx +360 -0
  104. package/corpus/templates/analytics/app/pages/monitoring/errors/Sparkline.tsx +55 -0
  105. package/corpus/templates/analytics/app/pages/monitoring/errors/i18n.ts +106 -0
  106. package/corpus/templates/analytics/app/pages/monitoring/errors/types.ts +75 -0
  107. package/corpus/templates/analytics/app/pages/monitoring/errors/utils.ts +132 -0
  108. package/corpus/templates/analytics/app/pages/monitoring/uptime/MonitorDetail.tsx +535 -0
  109. package/corpus/templates/analytics/app/pages/monitoring/uptime/MonitorFormPage.tsx +1026 -0
  110. package/corpus/templates/analytics/app/pages/monitoring/uptime/MonitorList.tsx +311 -0
  111. package/corpus/templates/analytics/app/pages/monitoring/uptime/i18n.ts +235 -0
  112. package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/StatusPageEditor.tsx +661 -0
  113. package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/StatusPagesView.tsx +355 -0
  114. package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/i18n.ts +106 -0
  115. package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/slug.ts +24 -0
  116. package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/types.ts +20 -0
  117. package/corpus/templates/analytics/app/pages/monitoring/uptime/status-summary.ts +87 -0
  118. package/corpus/templates/analytics/app/pages/monitoring/uptime/types.ts +161 -0
  119. package/corpus/templates/analytics/app/pages/monitoring/uptime/utils.ts +210 -0
  120. package/corpus/templates/analytics/app/pages/sessions/SessionDetailPage.tsx +76 -1
  121. package/corpus/templates/analytics/app/pages/sessions/SessionDevToolsPanel.tsx +74 -9
  122. package/corpus/templates/analytics/app/pages/sessions/SessionsPage.tsx +197 -20
  123. package/corpus/templates/analytics/app/root.tsx +33 -1
  124. package/corpus/templates/analytics/app/routes/monitoring._index.tsx +10 -0
  125. package/corpus/templates/analytics/app/routes/status.$slug.tsx +118 -0
  126. package/corpus/templates/analytics/changelog/2026-07-08-add-uptime-monitors-that-ping-your-urls-and-alert-you-when-t.md +6 -0
  127. package/corpus/templates/analytics/changelog/2026-07-08-analytics-chats-keep-large-data-dictionaries-compact-so-prov.md +6 -0
  128. package/corpus/templates/analytics/changelog/2026-07-08-create-public-status-pages-that-share-the-live-health-of-cho.md +6 -0
  129. package/corpus/templates/analytics/changelog/2026-07-08-dashboard-extension-panels-use-clearer-open-copy.md +6 -0
  130. package/corpus/templates/analytics/changelog/2026-07-08-error-capture.md +6 -0
  131. package/corpus/templates/analytics/changelog/2026-07-08-fixed-single-panel-dashboard-drags-so-they-no-longer-rewrite.md +6 -0
  132. package/corpus/templates/analytics/changelog/2026-07-08-jump-straight-from-an-error-in-a-session-recording-to-its-fu.md +6 -0
  133. package/corpus/templates/analytics/changelog/2026-07-08-monitor-detail-and-list-now-show-colorful-uptime-timelines-r.md +6 -0
  134. package/corpus/templates/analytics/changelog/2026-07-08-pinned-ask-chats-now-show-a-pin-icon-in-the-sidebar.md +6 -0
  135. package/corpus/templates/analytics/changelog/2026-07-08-publish-a-public-uptime-status-page-with-colorful-uptime-tim.md +6 -0
  136. package/corpus/templates/analytics/changelog/2026-07-08-sessions-now-hide-visitor-emails-in-demo-mode-and-show-clean.md +6 -0
  137. package/corpus/templates/analytics/changelog/2026-07-08-settings-are-cleaner-searchable-and-alerts-have-their-own-tab.md +5 -0
  138. package/corpus/templates/analytics/changelog/2026-07-08-sidebar-sections-stay-collapsed-until-opened.md +5 -0
  139. package/corpus/templates/analytics/changelog/2026-07-08-the-uptime-monitor-list-now-has-a-current-status-overview-wi.md +6 -0
  140. package/corpus/templates/analytics/docs/error-capture.md +172 -0
  141. package/corpus/templates/analytics/docs/uptime-monitoring.md +150 -0
  142. package/corpus/templates/analytics/server/db/schema-errors.ts +150 -0
  143. package/corpus/templates/analytics/server/db/schema-monitoring.ts +177 -0
  144. package/corpus/templates/analytics/server/db/schema.ts +6 -0
  145. package/corpus/templates/analytics/server/jobs/uptime-monitors.ts +123 -0
  146. package/corpus/templates/analytics/server/lib/agent-chat-plan-mode.ts +41 -0
  147. package/corpus/templates/analytics/server/lib/data-dictionary-context.ts +55 -12
  148. package/corpus/templates/analytics/server/lib/error-capture.ts +1331 -0
  149. package/corpus/templates/analytics/server/lib/first-party-analytics.ts +47 -1
  150. package/corpus/templates/analytics/server/lib/monitor-stats.ts +494 -0
  151. package/corpus/templates/analytics/server/lib/status-pages.ts +798 -0
  152. package/corpus/templates/analytics/server/lib/uptime-monitors.ts +1665 -0
  153. package/corpus/templates/analytics/server/plugins/agent-chat.ts +7 -37
  154. package/corpus/templates/analytics/server/plugins/auth.ts +11 -1
  155. package/corpus/templates/analytics/server/plugins/db.ts +408 -0
  156. package/corpus/templates/analytics/server/plugins/uptime-monitor-jobs.ts +63 -0
  157. package/corpus/templates/assets/app/routes/_index.tsx +1 -1
  158. package/corpus/templates/assets/app/routes/settings.tsx +22 -1
  159. package/corpus/templates/assets/changelog/2026-07-08-recent-drafts-keep-comfortable-side-padding.md +6 -0
  160. package/corpus/templates/assets/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  161. package/corpus/templates/brain/app/routes/settings.tsx +43 -5
  162. package/corpus/templates/brain/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  163. package/corpus/templates/calendar/app/pages/Settings.tsx +44 -6
  164. package/corpus/templates/calendar/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  165. package/corpus/templates/chat/app/routes/settings.tsx +16 -1
  166. package/corpus/templates/chat/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  167. package/corpus/templates/clips/actions/lib/audio-only-transcription.ts +79 -37
  168. package/corpus/templates/clips/actions/regenerate-chapters.ts +7 -0
  169. package/corpus/templates/clips/app/components/player/player-controls.tsx +35 -0
  170. package/corpus/templates/clips/app/components/player/video-player.tsx +162 -18
  171. package/corpus/templates/clips/app/hooks/use-auto-title.ts +15 -5
  172. package/corpus/templates/clips/app/routes/_app.settings._index.tsx +63 -6
  173. package/corpus/templates/clips/app/routes/download.tsx +12 -4
  174. package/corpus/templates/clips/app/routes/r.$recordingId.tsx +1 -0
  175. package/corpus/templates/clips/app/routes/record.tsx +18 -1
  176. package/corpus/templates/clips/changelog/2026-07-07-auto-generated-chapter-requests-now-open-the-matching-agent-.md +6 -0
  177. package/corpus/templates/clips/changelog/2026-07-07-shared-clips-start-playback-reliably-from-the-first-play-click.md +6 -0
  178. package/corpus/templates/clips/changelog/2026-07-07-the-clips-desktop-download-page-now-uses-the-agent-native-ap.md +6 -0
  179. package/corpus/templates/clips/changelog/2026-07-08-chrome-extension-camera-and-microphone-menus-now-show-which-.md +6 -0
  180. package/corpus/templates/clips/changelog/2026-07-08-chrome-extension-copies-new-clip-links-after-saving.md +6 -0
  181. package/corpus/templates/clips/changelog/2026-07-08-chrome-extension-recordings-now-continue-after-granting-came.md +6 -0
  182. package/corpus/templates/clips/changelog/2026-07-08-mobile-shared-clips-now-have-loom-style-tap-and-skip-controls.md +6 -0
  183. package/corpus/templates/clips/changelog/2026-07-08-recordings-and-uploads-copy-links-after-saving.md +6 -0
  184. package/corpus/templates/clips/changelog/2026-07-08-settings-are-cleaner-searchable-and-collapse-s3-with-builder.md +5 -0
  185. package/corpus/templates/clips/changelog/2026-07-08-transcripts-are-more-reliable-for-longer-desktop-recordings-.md +6 -0
  186. package/corpus/templates/clips/chrome-extension/public/manifest.json +1 -0
  187. package/corpus/templates/clips/chrome-extension/src/background.ts +162 -13
  188. package/corpus/templates/clips/chrome-extension/src/content-script.ts +14 -0
  189. package/corpus/templates/clips/chrome-extension/src/offscreen.ts +36 -0
  190. package/corpus/templates/clips/chrome-extension/src/overlay.ts +99 -25
  191. package/corpus/templates/clips/chrome-extension/src/permission.ts +63 -14
  192. package/corpus/templates/clips/chrome-extension/src/popup.ts +123 -23
  193. package/corpus/templates/content/actions/_builder-cms-read-client.ts +47 -0
  194. package/corpus/templates/content/actions/_database-source-utils.ts +33 -4
  195. package/corpus/templates/content/actions/add-content-database-source-field-property.ts +214 -29
  196. package/corpus/templates/content/actions/attach-content-database-source.ts +3 -0
  197. package/corpus/templates/content/actions/change-content-database-source-role.ts +1 -0
  198. package/corpus/templates/content/app/components/editor/DocumentProperties.tsx +42 -32
  199. package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +352 -81
  200. package/corpus/templates/content/app/components/editor/database/settings.tsx +49 -24
  201. package/corpus/templates/content/app/routes/_app.settings.tsx +19 -1
  202. package/corpus/templates/content/changelog/2026-07-07-builder-source-tag-fields-now-import-as-multi-select.md +6 -0
  203. package/corpus/templates/content/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  204. package/corpus/templates/content/shared/api.ts +3 -0
  205. package/corpus/templates/content/shared/properties.ts +42 -0
  206. package/corpus/templates/design/actions/generate-design.ts +3 -0
  207. package/corpus/templates/design/actions/get-design-system.ts +147 -1
  208. package/corpus/templates/design/app/routes/settings.tsx +16 -1
  209. package/corpus/templates/design/changelog/2026-07-08-design-generation-now-follows-hydrated-builder-design-system.md +6 -0
  210. package/corpus/templates/design/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  211. package/corpus/templates/dispatch/app/routes/settings.tsx +23 -2
  212. package/corpus/templates/dispatch/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  213. package/corpus/templates/forms/app/routes/_app.settings.tsx +16 -1
  214. package/corpus/templates/forms/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  215. package/corpus/templates/macros/app/routes/settings.tsx +16 -1
  216. package/corpus/templates/macros/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  217. package/corpus/templates/mail/app/components/settings/GmailFiltersSection.tsx +1 -1
  218. package/corpus/templates/mail/app/components/settings/SnippetsSection.tsx +1 -1
  219. package/corpus/templates/mail/app/pages/SettingsPage.tsx +123 -105
  220. package/corpus/templates/mail/changelog/2026-07-08-settings-redesigned-with-a-consistent-searchable-layout.md +5 -0
  221. package/corpus/templates/plan/app/routes/settings.tsx +23 -2
  222. package/corpus/templates/plan/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  223. package/corpus/templates/slides/actions/add-slide.ts +1 -0
  224. package/corpus/templates/slides/actions/get-design-system.ts +147 -1
  225. package/corpus/templates/slides/app/pages/Index.tsx +46 -1
  226. package/corpus/templates/slides/app/routes/settings.tsx +16 -1
  227. package/corpus/templates/slides/changelog/2026-07-08-deck-generation-now-follows-hydrated-builder-design-system-g.md +6 -0
  228. package/corpus/templates/slides/changelog/2026-07-08-settings-are-cleaner-and-searchable.md +5 -0
  229. package/dist/agent/durable-background.d.ts +1 -1
  230. package/dist/agent/durable-background.d.ts.map +1 -1
  231. package/dist/agent/durable-background.js +5 -3
  232. package/dist/agent/durable-background.js.map +1 -1
  233. package/dist/agent/engine/ai-sdk-engine.d.ts.map +1 -1
  234. package/dist/agent/engine/ai-sdk-engine.js +24 -4
  235. package/dist/agent/engine/ai-sdk-engine.js.map +1 -1
  236. package/dist/agent/engine/anthropic-engine.d.ts.map +1 -1
  237. package/dist/agent/engine/anthropic-engine.js +13 -3
  238. package/dist/agent/engine/anthropic-engine.js.map +1 -1
  239. package/dist/agent/engine/output-tokens.d.ts +27 -0
  240. package/dist/agent/engine/output-tokens.d.ts.map +1 -1
  241. package/dist/agent/engine/output-tokens.js +70 -0
  242. package/dist/agent/engine/output-tokens.js.map +1 -1
  243. package/dist/agent/production-agent.d.ts.map +1 -1
  244. package/dist/agent/production-agent.js +28 -7
  245. package/dist/agent/production-agent.js.map +1 -1
  246. package/dist/agent/run-ownership.d.ts +6 -0
  247. package/dist/agent/run-ownership.d.ts.map +1 -1
  248. package/dist/agent/run-ownership.js +11 -1
  249. package/dist/agent/run-ownership.js.map +1 -1
  250. package/dist/agent/types.d.ts +3 -2
  251. package/dist/agent/types.d.ts.map +1 -1
  252. package/dist/agent/types.js.map +1 -1
  253. package/dist/changelog/parse.d.ts +7 -0
  254. package/dist/changelog/parse.d.ts.map +1 -1
  255. package/dist/changelog/parse.js +64 -0
  256. package/dist/changelog/parse.js.map +1 -1
  257. package/dist/chat-threads/schema.d.ts +445 -0
  258. package/dist/chat-threads/schema.d.ts.map +1 -0
  259. package/dist/chat-threads/schema.js +39 -0
  260. package/dist/chat-threads/schema.js.map +1 -0
  261. package/dist/chat-threads/store.d.ts +12 -0
  262. package/dist/chat-threads/store.d.ts.map +1 -1
  263. package/dist/chat-threads/store.js +99 -10
  264. package/dist/chat-threads/store.js.map +1 -1
  265. package/dist/cli/workspace-dev.d.ts.map +1 -1
  266. package/dist/cli/workspace-dev.js +20 -5
  267. package/dist/cli/workspace-dev.js.map +1 -1
  268. package/dist/client/AgentPanel.d.ts.map +1 -1
  269. package/dist/client/AgentPanel.js +35 -7
  270. package/dist/client/AgentPanel.js.map +1 -1
  271. package/dist/client/AssistantChat.d.ts.map +1 -1
  272. package/dist/client/AssistantChat.js +105 -183
  273. package/dist/client/AssistantChat.js.map +1 -1
  274. package/dist/client/analytics-session.d.ts +3 -0
  275. package/dist/client/analytics-session.d.ts.map +1 -0
  276. package/dist/client/analytics-session.js +66 -0
  277. package/dist/client/analytics-session.js.map +1 -0
  278. package/dist/client/analytics.d.ts +32 -0
  279. package/dist/client/analytics.d.ts.map +1 -1
  280. package/dist/client/analytics.js +116 -46
  281. package/dist/client/analytics.js.map +1 -1
  282. package/dist/client/chat/message-components.d.ts +2 -1
  283. package/dist/client/chat/message-components.d.ts.map +1 -1
  284. package/dist/client/chat/message-components.js +16 -6
  285. package/dist/client/chat/message-components.js.map +1 -1
  286. package/dist/client/components/ui/message-scroller.d.ts +16 -0
  287. package/dist/client/components/ui/message-scroller.d.ts.map +1 -0
  288. package/dist/client/components/ui/message-scroller.js +25 -0
  289. package/dist/client/components/ui/message-scroller.js.map +1 -0
  290. package/dist/client/conversation/AgentConversation.d.ts +1 -1
  291. package/dist/client/conversation/AgentConversation.d.ts.map +1 -1
  292. package/dist/client/conversation/AgentConversation.js +3 -8
  293. package/dist/client/conversation/AgentConversation.js.map +1 -1
  294. package/dist/client/error-capture.d.ts +99 -0
  295. package/dist/client/error-capture.d.ts.map +1 -0
  296. package/dist/client/error-capture.js +437 -0
  297. package/dist/client/error-capture.js.map +1 -0
  298. package/dist/client/index.d.ts +2 -2
  299. package/dist/client/index.d.ts.map +1 -1
  300. package/dist/client/index.js +3 -1
  301. package/dist/client/index.js.map +1 -1
  302. package/dist/client/session-replay.d.ts +22 -0
  303. package/dist/client/session-replay.d.ts.map +1 -1
  304. package/dist/client/session-replay.js +45 -4
  305. package/dist/client/session-replay.js.map +1 -1
  306. package/dist/client/settings/SettingsPanel.d.ts.map +1 -1
  307. package/dist/client/settings/SettingsPanel.js +100 -5
  308. package/dist/client/settings/SettingsPanel.js.map +1 -1
  309. package/dist/client/settings/SettingsTabsPage.d.ts +49 -1
  310. package/dist/client/settings/SettingsTabsPage.d.ts.map +1 -1
  311. package/dist/client/settings/SettingsTabsPage.js +131 -19
  312. package/dist/client/settings/SettingsTabsPage.js.map +1 -1
  313. package/dist/client/settings/index.d.ts +1 -1
  314. package/dist/client/settings/index.d.ts.map +1 -1
  315. package/dist/client/settings/index.js.map +1 -1
  316. package/dist/client/sharing/ShareButton.d.ts.map +1 -1
  317. package/dist/client/sharing/ShareButton.js +13 -8
  318. package/dist/client/sharing/ShareButton.js.map +1 -1
  319. package/dist/client/sharing/ShareDialog.d.ts.map +1 -1
  320. package/dist/client/sharing/ShareDialog.js +12 -7
  321. package/dist/client/sharing/ShareDialog.js.map +1 -1
  322. package/dist/collab/routes.d.ts +1 -1
  323. package/dist/collab/struct-routes.d.ts +1 -1
  324. package/dist/db/client.d.ts.map +1 -1
  325. package/dist/db/client.js +12 -7
  326. package/dist/db/client.js.map +1 -1
  327. package/dist/mcp/builtin-tools.d.ts.map +1 -1
  328. package/dist/mcp/builtin-tools.js +21 -2
  329. package/dist/mcp/builtin-tools.js.map +1 -1
  330. package/dist/notifications/routes.d.ts +1 -1
  331. package/dist/observability/routes.d.ts +5 -5
  332. package/dist/org/schema.d.ts +15 -15
  333. package/dist/progress/routes.d.ts +1 -1
  334. package/dist/provider-api/corpus-jobs.d.ts +2 -2
  335. package/dist/resources/handlers.d.ts +3 -3
  336. package/dist/secrets/routes.d.ts +9 -9
  337. package/dist/server/agent-chat-plugin.d.ts.map +1 -1
  338. package/dist/server/agent-chat-plugin.js +109 -73
  339. package/dist/server/agent-chat-plugin.js.map +1 -1
  340. package/dist/server/agent-engine-api-key-route.d.ts +1 -1
  341. package/dist/server/onboarding-html.d.ts.map +1 -1
  342. package/dist/server/onboarding-html.js +28 -16
  343. package/dist/server/onboarding-html.js.map +1 -1
  344. package/dist/shared/reasoning-effort.d.ts +1 -0
  345. package/dist/shared/reasoning-effort.d.ts.map +1 -1
  346. package/dist/shared/reasoning-effort.js +18 -0
  347. package/dist/shared/reasoning-effort.js.map +1 -1
  348. package/dist/sharing/actions/list-resource-shares.js +30 -1
  349. package/dist/sharing/actions/list-resource-shares.js.map +1 -1
  350. package/dist/sharing/actions/share-resource.js +6 -0
  351. package/dist/sharing/actions/share-resource.js.map +1 -1
  352. package/dist/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +4 -2
  353. package/dist/templates/workspace-core/.agents/skills/changelog/SKILL.md +9 -6
  354. package/dist/vite/client.d.ts.map +1 -1
  355. package/dist/vite/client.js +192 -30
  356. package/dist/vite/client.js.map +1 -1
  357. package/docs/content/toolkit-settings.mdx +56 -3
  358. package/package.json +2 -1
  359. package/src/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +4 -2
  360. package/src/templates/workspace-core/.agents/skills/changelog/SKILL.md +9 -6
@@ -73,7 +73,7 @@ ad-hoc analysis) plus two things: a stored, named identity, and a small
73
73
  same dry-run path, no persisted row. Use this while tuning a script before
74
74
  calling `save-data-program` again.
75
75
  6. **Refresh on demand** with `run-data-program(programId, params?,
76
- forceRefresh?, includeRows?)` — this is what the agent calls to get a
76
+ forceRefresh?, includeRows?)` — this is what the agent calls to get a
77
77
  compact proof-of-result (`rowCount`, `columns`, `sampleRows`) without
78
78
  waiting for a panel view. Pass `includeRows: true` only when you need the
79
79
  full (capped) row set back in context.
@@ -101,13 +101,13 @@ addition:
101
101
 
102
102
  Caps enforced on every run (not configurable per-program):
103
103
 
104
- | Limit | Value |
105
- | --- | --- |
106
- | Max emitted rows | 10,000 (rows beyond this are dropped, `truncated: true`) |
107
- | Max emitted result size | 4 MiB (rows dropped from the end to fit; a single row over 4 MiB is a hard `result_too_large` failure — nothing to safely keep) |
108
- | Max active programs per app | 200 (archive unused ones to free room) |
109
- | Minimum refresh TTL | 60,000 ms |
110
- | Run rows kept per (program, params) | 5 most recent (older ones are pruned automatically) |
104
+ | Limit | Value |
105
+ | ----------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
106
+ | Max emitted rows | 10,000 (rows beyond this are dropped, `truncated: true`) |
107
+ | Max emitted result size | 4 MiB (rows dropped from the end to fit; a single row over 4 MiB is a hard `result_too_large` failure — nothing to safely keep) |
108
+ | Max active programs per app | 200 (archive unused ones to free room) |
109
+ | Minimum refresh TTL | 60,000 ms |
110
+ | Run rows kept per (program, params) | 5 most recent (older ones are pruned automatically) |
111
111
 
112
112
  Truncation is always honest: a partial result comes back with
113
113
  `truncated: true`, never a silent drop.
@@ -118,16 +118,16 @@ Every `(programId, paramsHash)` pair (params are canonicalized and hashed, so
118
118
  equivalent param objects share a cache entry) has its own run history. What
119
119
  happens on each call to `runDataProgram` / a panel view:
120
120
 
121
- | Situation | Behavior |
122
- | --- | --- |
123
- | Fresh cache hit (younger than `refreshTtlMs`, or `refreshMode: "manual"` with any prior success) | Returns cached rows instantly, `cacheHit: true` |
124
- | Cache is older than the TTL | Re-executes synchronously (panel views get a 25s budget; agent/manual calls get 120s), replacing the cache on success |
125
- | `refreshMode: "manual"` | Never auto-refreshes; only `forceRefresh: true` (or `manual_refresh` from the UI) re-runs it |
126
- | No cache yet | Executes synchronously like a normal first fetch |
127
- | `background: true` program, no fresh cache | Serves the last good run immediately with `stale: true` and enqueues a durable background execution (10-minute budget); the *next* call finalizes it if it has completed |
128
- | Background program, execution still running, no prior success | `background_pending` failure — the panel shows an explicit "running in background" error card, never a blank chart |
129
- | Execution fails (timeout, sandbox error, bad `emit()` shape) | Failure result with a structured error code; if a previous successful run exists, it is attached as `lastGoodRun` so the panel can stale-serve instead of going blank |
130
- | Program was archived (`delete-data-program`) | Explicit `archived` failure — panels show "This data program was archived", never a silent blank |
121
+ | Situation | Behavior |
122
+ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
123
+ | Fresh cache hit (younger than `refreshTtlMs`, or `refreshMode: "manual"` with any prior success) | Returns cached rows instantly, `cacheHit: true` |
124
+ | Cache is older than the TTL | Re-executes synchronously (panel views get a 25s budget; agent/manual calls get 120s), replacing the cache on success |
125
+ | `refreshMode: "manual"` | Never auto-refreshes; only `forceRefresh: true` (or `manual_refresh` from the UI) re-runs it |
126
+ | No cache yet | Executes synchronously like a normal first fetch |
127
+ | `background: true` program, no fresh cache | Serves the last good run immediately with `stale: true` and enqueues a durable background execution (10-minute budget); the _next_ call finalizes it if it has completed |
128
+ | Background program, execution still running, no prior success | `background_pending` failure — the panel shows an explicit "running in background" error card, never a blank chart |
129
+ | Execution fails (timeout, sandbox error, bad `emit()` shape) | Failure result with a structured error code; if a previous successful run exists, it is attached as `lastGoodRun` so the panel can stale-serve instead of going blank |
130
+ | Program was archived (`delete-data-program`) | Explicit `archived` failure — panels show "This data program was archived", never a silent blank |
131
131
 
132
132
  Use `background: true` only for programs that routinely take longer than the
133
133
  foreground budget (multi-provider joins over large cohorts, deep pagination).
@@ -136,18 +136,18 @@ serves fresh data faster.
136
136
 
137
137
  ## Error codes
138
138
 
139
- | Code | Meaning | What to do |
140
- | --- | --- | --- |
141
- | `program_not_found` | No program with that id | Check the id via `list-data-programs` |
142
- | `access_denied` | Caller can't see this program | Don't leak existence; ask the owner to share it |
143
- | `archived` | Program was soft-deleted | Repoint the panel or unarchive by resaving under the same name |
144
- | `timeout` | Didn't finish within the run's budget | Reduce scope, page in fewer items, or mark `background: true` |
145
- | `emit_missing` | Script never called `emit(...)` | Add the `emit(rows, schema?)` call at the end |
146
- | `emit_shape_invalid` | `emit()` args weren't `(array-of-plain-objects, optional-schema-array)` | Fix the shape; check for a stray second `emit()` call |
147
- | `result_too_large` | A single row (or the whole result) exceeds the byte cap | Trim large string fields before emitting |
148
- | `sandbox_error` | Uncaught exception in the script | Read the thrown message; guard optional provider fields |
149
- | `run_code_unavailable` | The run-code module isn't available in this build | Not something a program author can fix |
150
- | `background_pending` | Background program has no result yet | Wait and retry, or check `lastGoodRun` if present |
139
+ | Code | Meaning | What to do |
140
+ | ---------------------- | ----------------------------------------------------------------------- | -------------------------------------------------------------- |
141
+ | `program_not_found` | No program with that id | Check the id via `list-data-programs` |
142
+ | `access_denied` | Caller can't see this program | Don't leak existence; ask the owner to share it |
143
+ | `archived` | Program was soft-deleted | Repoint the panel or unarchive by resaving under the same name |
144
+ | `timeout` | Didn't finish within the run's budget | Reduce scope, page in fewer items, or mark `background: true` |
145
+ | `emit_missing` | Script never called `emit(...)` | Add the `emit(rows, schema?)` call at the end |
146
+ | `emit_shape_invalid` | `emit()` args weren't `(array-of-plain-objects, optional-schema-array)` | Fix the shape; check for a stray second `emit()` call |
147
+ | `result_too_large` | A single row (or the whole result) exceeds the byte cap | Trim large string fields before emitting |
148
+ | `sandbox_error` | Uncaught exception in the script | Read the thrown message; guard optional provider fields |
149
+ | `run_code_unavailable` | The run-code module isn't available in this build | Not something a program author can fix |
150
+ | `background_pending` | Background program has no result yet | Wait and retry, or check `lastGoodRun` if present |
151
151
 
152
152
  Every failure is a structured `{ code, message }`, never a bare string — treat
153
153
  `code` as the thing to branch on, `message` as the thing to show a human.
@@ -156,7 +156,7 @@ Every failure is a structured `{ code, message }`, never a bare string — treat
156
156
 
157
157
  - **Credentials are always the viewer's, never the author's.** When a shared
158
158
  program's panel is viewed, `providerFetch` inside it resolves auth using the
159
- *viewing* user's own configured provider credentials — not the program
159
+ _viewing_ user's own configured provider credentials — not the program
160
160
  author's. A teammate missing a HubSpot key sees a HubSpot auth error on that
161
161
  panel, not someone else's data.
162
162
  - **Only share programs you trust.** Because execution uses the viewer's
@@ -204,7 +204,8 @@ const HIGH_RISK_SENTIMENTS = ["frustrated", "high_risk_detractor"];
204
204
 
205
205
  function chunk(items, size) {
206
206
  const out = [];
207
- for (let i = 0; i < items.length; i += size) out.push(items.slice(i, i + size));
207
+ for (let i = 0; i < items.length; i += size)
208
+ out.push(items.slice(i, i + size));
208
209
  return out;
209
210
  }
210
211
 
@@ -217,19 +218,42 @@ async function main() {
217
218
  {
218
219
  method: "POST",
219
220
  body: {
220
- filterGroups: [{
221
- filters: [
222
- { propertyName: "risk_status", operator: "IN", values: riskStatuses },
223
- { propertyName: "closedate", operator: "GT", value: String(Date.now()) },
224
- ],
225
- }],
226
- properties: ["dealname", "risk_status", "risk_summary", "risk_category",
227
- "hs_next_step", "churn_notes", "total_contract_value",
228
- "customer_success_owner", "dealstage", "closedate"],
221
+ filterGroups: [
222
+ {
223
+ filters: [
224
+ {
225
+ propertyName: "risk_status",
226
+ operator: "IN",
227
+ values: riskStatuses,
228
+ },
229
+ {
230
+ propertyName: "closedate",
231
+ operator: "GT",
232
+ value: String(Date.now()),
233
+ },
234
+ ],
235
+ },
236
+ ],
237
+ properties: [
238
+ "dealname",
239
+ "risk_status",
240
+ "risk_summary",
241
+ "risk_category",
242
+ "hs_next_step",
243
+ "churn_notes",
244
+ "total_contract_value",
245
+ "customer_success_owner",
246
+ "dealstage",
247
+ "closedate",
248
+ ],
229
249
  limit: 100,
230
250
  },
231
251
  itemsPath: "results",
232
- pagination: { cursorBodyPath: "after", nextCursorPath: "paging.next.after", maxPages: 20 },
252
+ pagination: {
253
+ cursorBodyPath: "after",
254
+ nextCursorPath: "paging.next.after",
255
+ maxPages: 20,
256
+ },
233
257
  },
234
258
  );
235
259
  const deals = dealSearch.items || [];
@@ -241,28 +265,38 @@ async function main() {
241
265
  for (const batch of chunk(dealIds, 100)) {
242
266
  if (batch.length === 0) continue;
243
267
  const assoc = await providerFetch(
244
- "hubspot", "/crm/v3/associations/deals/companies/batch/read",
268
+ "hubspot",
269
+ "/crm/v3/associations/deals/companies/batch/read",
245
270
  { method: "POST", body: { inputs: batch.map((id) => ({ id })) } },
246
271
  );
247
272
  for (const r of (assoc && assoc.results) || []) {
248
273
  const dealId = r && r.from && r.from.id;
249
- const companyId = r && Array.isArray(r.to) && r.to.length > 0 ? r.to[0].id : null;
274
+ const companyId =
275
+ r && Array.isArray(r.to) && r.to.length > 0 ? r.to[0].id : null;
250
276
  if (dealId && companyId) companyByDeal[dealId] = companyId;
251
277
  }
252
278
  }
253
279
 
254
280
  // 3. Batched company -> domain lookup.
255
- const companyIds = Array.from(new Set(Object.values(companyByDeal))).filter(Boolean);
281
+ const companyIds = Array.from(new Set(Object.values(companyByDeal))).filter(
282
+ Boolean,
283
+ );
256
284
  const domainByCompany = {};
257
285
  for (const batch of chunk(companyIds, 100)) {
258
286
  if (batch.length === 0) continue;
259
287
  const companies = await providerFetch(
260
- "hubspot", "/crm/v3/objects/companies/batch/read",
261
- { method: "POST", body: { inputs: batch.map((id) => ({ id })), properties: ["domain"] } },
288
+ "hubspot",
289
+ "/crm/v3/objects/companies/batch/read",
290
+ {
291
+ method: "POST",
292
+ body: { inputs: batch.map((id) => ({ id })), properties: ["domain"] },
293
+ },
262
294
  );
263
295
  for (const r of (companies && companies.results) || []) {
264
- const domain = r && r.properties && r.properties.domain
265
- ? String(r.properties.domain).toLowerCase() : null;
296
+ const domain =
297
+ r && r.properties && r.properties.domain
298
+ ? String(r.properties.domain).toLowerCase()
299
+ : null;
266
300
  if (r && r.id && domain) domainByCompany[r.id] = domain;
267
301
  }
268
302
  }
@@ -270,15 +304,25 @@ async function main() {
270
304
  // 4. A second, unrelated provider — zero bespoke glue action required.
271
305
  const pylonAccounts = await providerFetchAll("pylon", "/accounts", {
272
306
  itemsPath: "data",
273
- pagination: { cursorParam: "cursor", nextCursorPath: "pagination.cursor", maxPages: 20 },
307
+ pagination: {
308
+ cursorParam: "cursor",
309
+ nextCursorPath: "pagination.cursor",
310
+ maxPages: 20,
311
+ },
274
312
  });
275
313
  const sentimentByDomain = {};
276
314
  for (const account of pylonAccounts.items || []) {
277
315
  if (!account) continue;
278
- const domain = typeof account.domain === "string" ? account.domain.toLowerCase() : null;
316
+ const domain =
317
+ typeof account.domain === "string" ? account.domain.toLowerCase() : null;
279
318
  if (!domain) continue;
280
- if (params.enterpriseOnly && account.account_profile !== "Enterprise Active Customer") continue;
281
- if (account.general_sentiment) sentimentByDomain[domain] = account.general_sentiment;
319
+ if (
320
+ params.enterpriseOnly &&
321
+ account.account_profile !== "Enterprise Active Customer"
322
+ )
323
+ continue;
324
+ if (account.general_sentiment)
325
+ sentimentByDomain[domain] = account.general_sentiment;
282
326
  }
283
327
 
284
328
  // 5. Join + emit. csm_name is computed HERE — never baked into a generic
@@ -303,18 +347,27 @@ async function main() {
303
347
  closedate: props.closedate || null,
304
348
  domain: domain || null,
305
349
  pylon_sentiment: sentiment,
306
- cross_source_flag: Boolean(domain && HIGH_RISK_SENTIMENTS.includes(sentiment)),
350
+ cross_source_flag: Boolean(
351
+ domain && HIGH_RISK_SENTIMENTS.includes(sentiment),
352
+ ),
307
353
  };
308
354
  });
309
355
 
310
356
  emit(rows, [
311
- { name: "deal_id", type: "string" }, { name: "deal_name", type: "string" },
312
- { name: "risk_status", type: "string" }, { name: "risk_summary", type: "string" },
313
- { name: "risk_category", type: "string" }, { name: "next_step", type: "string" },
314
- { name: "churn_notes", type: "string" }, { name: "arr", type: "number" },
315
- { name: "csm_name", type: "string" }, { name: "dealstage", type: "string" },
316
- { name: "closedate", type: "string" }, { name: "domain", type: "string" },
317
- { name: "pylon_sentiment", type: "string" }, { name: "cross_source_flag", type: "boolean" },
357
+ { name: "deal_id", type: "string" },
358
+ { name: "deal_name", type: "string" },
359
+ { name: "risk_status", type: "string" },
360
+ { name: "risk_summary", type: "string" },
361
+ { name: "risk_category", type: "string" },
362
+ { name: "next_step", type: "string" },
363
+ { name: "churn_notes", type: "string" },
364
+ { name: "arr", type: "number" },
365
+ { name: "csm_name", type: "string" },
366
+ { name: "dealstage", type: "string" },
367
+ { name: "closedate", type: "string" },
368
+ { name: "domain", type: "string" },
369
+ { name: "pylon_sentiment", type: "string" },
370
+ { name: "cross_source_flag", type: "boolean" },
318
371
  ]);
319
372
  }
320
373
 
@@ -111,6 +111,7 @@ For complete answers, combine data from multiple sources:
111
111
  ## After Completing an Analysis — Capture New Knowledge
112
112
 
113
113
  When you complete an analysis and discover:
114
+
114
115
  - A new confirmed metric definition or how a field is actually calculated
115
116
  - A provider gotcha (wrong column name, API quirk, unexpected behavior)
116
117
  - A schema discovery (table exists but wasn't in the dictionary, a column name differs)
@@ -110,8 +110,8 @@ negative. Use this two-step pattern:
110
110
  `provider-api-catalog(provider: "gong")` and its `corpusRecipes` if you need
111
111
  the exact shape. The canonical request is `POST /calls/transcript` with
112
112
  `batch.itemBodyPath: "filter.callIds"`, `batch.responseItemsPath:
113
- "callTranscripts"`, `batch.batchSize: 20`, `search.textPaths:
114
- ["transcript"]`, and `search.idPaths: ["callId"]`. Feed the staged/discovered
113
+ "callTranscripts"`, `batch.batchSize: 20`, `search.textPaths:
114
+ ["transcript"]`, and `search.idPaths: ["callId"]`. Feed the staged/discovered
115
115
  call IDs through `batch.inputDatasetId` + `batch.inputValuePath` or through
116
116
  `batch.items`.
117
117
 
@@ -126,11 +126,11 @@ matches found. Never turn "I inspected a sample" into "no call mentions X".
126
126
 
127
127
  ## Limits (Current)
128
128
 
129
- | Parameter | Default | Max |
130
- |---|---|---|
131
- | `limit` (calls returned) | 8 | 200 |
132
- | `transcriptLimit` | 3 | 50 |
133
- | `transcriptMaxChars` | 8 000 | 100 000 |
129
+ | Parameter | Default | Max |
130
+ | ------------------------ | ------- | ------- |
131
+ | `limit` (calls returned) | 8 | 200 |
132
+ | `transcriptLimit` | 3 | 50 |
133
+ | `transcriptMaxChars` | 8 000 | 100 000 |
134
134
 
135
135
  For large account deep-dives or competitive analyses spanning many calls, use
136
136
  `limit: 50-200` and `transcriptLimit: 20-50`. For very large datasets, the
@@ -54,6 +54,7 @@ To discover stage IDs, call `hubspot-pipelines` first and read the `stageId`
54
54
  fields in the returned pipeline structure.
55
55
 
56
56
  Example use: to count deals that reached "Qualified Opportunity" stage in Q1:
57
+
57
58
  ```
58
59
  provider-api-request(
59
60
  provider: "hubspot",
@@ -101,7 +101,7 @@ issues (spikes, outages, errors, performance degradation):
101
101
 
102
102
  1. **Query actual metrics FIRST** — use Prometheus/Grafana, Sentry, and Cloud
103
103
  Logging before looking at code. Real data tells you what happened; code only
104
- tells you what *could* happen.
104
+ tells you what _could_ happen.
105
105
  2. **Check upstream dependencies** — many incidents are caused by provider-side
106
106
  degradation (LLM APIs, external services), not local code. Query latency
107
107
  metrics for each upstream call.
@@ -12,7 +12,7 @@ description: >
12
12
  **`bigquery` is available directly in the agent's tool list as a native callable tool.**
13
13
 
14
14
  - If you see `bigquery` in your available tools — **call it directly with your SQL**. Do not use HTTP workarounds, web-request hacks, or scripts as a substitute.
15
- - The `server/lib/bigquery.ts` description below is the *underlying implementation*. It does **not** mean BigQuery is only accessible via terminal commands or scripts.
15
+ - The `server/lib/bigquery.ts` description below is the _underlying implementation_. It does **not** mean BigQuery is only accessible via terminal commands or scripts.
16
16
  - **When uncertain if the tool works, call it — don't reason your way to "it won't work".** Empirically test by calling the tool.
17
17
  - Scripts (`pnpm action`) and the server lib are for dashboard UI code and CLI use. The agent calls BigQuery directly via its native tool.
18
18
 
@@ -71,16 +71,16 @@ description: >
71
71
 
72
72
  ### Sigma Blog Metadata Column Mapping
73
73
 
74
- | Cryptic Column | Meaning | Example Values |
75
- | -------------- | ------------------------ | ----------------------------------------------------------------- |
76
- | `SUOHFYGIOG` | Blog URL | `https://www.example.com/blog/sample-post` |
77
- | `H5YIATNDT5` | Author | Jane Doe, Alex Chen, Sam Patel, Taylor Kim |
78
- | `ZZJ6XRJAII` | Publish date (TIMESTAMP) | |
79
- | `FTRKLGZM1R` | Purpose | Acquisition, Awareness |
80
- | `IFHWPU1IDO` | Persona | Developers, Product Managers, Engineering Leaders, Designers |
81
- | `Z52LFY52AK` | Topic | AI, CMS, Web Development, Design |
82
- | `_DGCBJNKLE` | Sub-type | Tooling, Development, Prototyping |
83
- | `JQL-G1QE-B` | Sub-topic | AI Design, AI Prototyping, AI Tools |
74
+ | Cryptic Column | Meaning | Example Values |
75
+ | -------------- | ------------------------ | ------------------------------------------------------------ |
76
+ | `SUOHFYGIOG` | Blog URL | `https://www.example.com/blog/sample-post` |
77
+ | `H5YIATNDT5` | Author | Jane Doe, Alex Chen, Sam Patel, Taylor Kim |
78
+ | `ZZJ6XRJAII` | Publish date (TIMESTAMP) | |
79
+ | `FTRKLGZM1R` | Purpose | Acquisition, Awareness |
80
+ | `IFHWPU1IDO` | Persona | Developers, Product Managers, Engineering Leaders, Designers |
81
+ | `Z52LFY52AK` | Topic | AI, CMS, Web Development, Design |
82
+ | `_DGCBJNKLE` | Sub-type | Tooling, Development, Prototyping |
83
+ | `JQL-G1QE-B` | Sub-topic | AI Design, AI Prototyping, AI Tools |
84
84
 
85
85
  **Deduplication**: Table has duplicates (http:// vs https://). Always deduplicate: `REGEXP_EXTRACT(SUOHFYGIOG, r'/blog/([^/?#]+)')` with ROW_NUMBER or DISTINCT.
86
86
 
@@ -170,12 +170,12 @@ Use **Amplitude** (`amplitude.EVENTS_182198`) instead of `@app_events` — small
170
170
 
171
171
  ### Key agent chat event types
172
172
 
173
- | Event | Description |
174
- | ----------------------------------------- | ---------------------------------------- |
175
- | `agent chat message submitted` | User sends message in AI chat |
176
- | `visual editor ai chat message submitted` | User sends message in Visual Editor AI |
177
- | `agent chat message completed` | AI response completed |
178
- | `agent chat code applied` | User applied generated code |
173
+ | Event | Description |
174
+ | ----------------------------------------- | -------------------------------------- |
175
+ | `agent chat message submitted` | User sends message in AI chat |
176
+ | `visual editor ai chat message submitted` | User sends message in Visual Editor AI |
177
+ | `agent chat message completed` | AI response completed |
178
+ | `agent chat code applied` | User applied generated code |
179
179
 
180
180
  ### Customer agent chat message lookup pipeline
181
181
 
@@ -42,11 +42,11 @@ description: >
42
42
  Use `gcloud` for agent-facing Google Cloud work. Do not call
43
43
  `/api/gcloud/*` directly from the agent.
44
44
 
45
- | Mode | Args | Description |
46
- | --- | --- | --- |
47
- | `services` | | List Cloud Run services and Cloud Functions |
48
- | `metrics` | `service`, `serviceType`, `metric`, `period`, `extraFilter` | Query Cloud Monitoring |
49
- | `logs` | `service`, `serviceType`, `severity`, `limit` | Read Cloud Logging |
45
+ | Mode | Args | Description |
46
+ | ---------- | ----------------------------------------------------------- | ------------------------------------------- |
47
+ | `services` | | List Cloud Run services and Cloud Functions |
48
+ | `metrics` | `service`, `serviceType`, `metric`, `period`, `extraFilter` | Query Cloud Monitoring |
49
+ | `logs` | `service`, `serviceType`, `severity`, `limit` | Read Cloud Logging |
50
50
 
51
51
  ### Dashboard
52
52
 
@@ -33,14 +33,14 @@ description: >
33
33
 
34
34
  ### API Routes
35
35
 
36
- | Route | Description |
37
- | ------------------------------------------------------------------------ | -------------------------------------- |
38
- | `GET /api/github/search?q=...&type=pr\|issue&limit=30` | Full GitHub search syntax |
39
- | `GET /api/github/pr?owner=...&repo=...&number=...` | PR detail with commits, reviews, files |
40
- | `GET /api/github/issue?owner=...&repo=...&number=...` | Issue detail |
41
- | `GET /api/github/prs?owner=...&repo=...&state=open\|closed\|all` | List repo PRs |
36
+ | Route | Description |
37
+ | -------------------------------------------------------------------- | -------------------------------------- |
38
+ | `GET /api/github/search?q=...&type=pr\|issue&limit=30` | Full GitHub search syntax |
39
+ | `GET /api/github/pr?owner=...&repo=...&number=...` | PR detail with commits, reviews, files |
40
+ | `GET /api/github/issue?owner=...&repo=...&number=...` | Issue detail |
41
+ | `GET /api/github/prs?owner=...&repo=...&state=open\|closed\|all` | List repo PRs |
42
42
  | `GET /api/github/org-prs?org=<org>&q=...&state=OPEN\|CLOSED\|MERGED` | Org-wide PR search |
43
- | `POST /api/github/graphql` body: `{ query, variables? }` | Raw GraphQL |
43
+ | `POST /api/github/graphql` body: `{ query, variables? }` | Raw GraphQL |
44
44
 
45
45
  ## Script Usage
46
46
 
@@ -23,16 +23,16 @@ description: >
23
23
 
24
24
  ### Exported Functions
25
25
 
26
- | Function | Description |
27
- | --------------------------- | -------------------------------------------------------- |
28
- | `getCalls(filters?)` | List calls (cursor-paginated) |
29
- | `getCall(callId)` | Get single call detail |
30
- | `getCallTranscript(callId)` | Get one call transcript |
31
- | `getCallTranscripts(callIds)` | Batch-fetch call transcripts |
32
- | `getUsers()` | List Gong users |
33
- | `searchCalls(query, days)` | List + filter by title and external party name/email/domain |
34
- | `getCallDetail(callId)` | Get parties plus Gong brief/key points/outline |
35
- | `getEnrichedTranscript(id)` | Transcript mapped to Gong parties and external speakers |
26
+ | Function | Description |
27
+ | ----------------------------- | ----------------------------------------------------------- |
28
+ | `getCalls(filters?)` | List calls (cursor-paginated) |
29
+ | `getCall(callId)` | Get single call detail |
30
+ | `getCallTranscript(callId)` | Get one call transcript |
31
+ | `getCallTranscripts(callIds)` | Batch-fetch call transcripts |
32
+ | `getUsers()` | List Gong users |
33
+ | `searchCalls(query, days)` | List + filter by title and external party name/email/domain |
34
+ | `getCallDetail(callId)` | Get parties plus Gong brief/key points/outline |
35
+ | `getEnrichedTranscript(id)` | Transcript mapped to Gong parties and external speakers |
36
36
 
37
37
  ### UI API Routes
38
38
 
@@ -87,8 +87,8 @@ raw transcript corpus path:
87
87
  2. Prefer `provider-corpus-job` with `mode: "batch-search"` against
88
88
  `POST /calls/transcript`.
89
89
  3. Use `batch.itemBodyPath: "filter.callIds"`, `batch.responseItemsPath:
90
- "callTranscripts"`, `batch.batchSize: 20`, `search.textPaths:
91
- ["transcript"]`, and `search.idPaths: ["callId"]`.
90
+ "callTranscripts"`, `batch.batchSize: 20`, `search.textPaths:
91
+ ["transcript"]`, and `search.idPaths: ["callId"]`.
92
92
  4. Join the stored hits back to deals/accounts with `run-code` or staged-dataset
93
93
  queries, then report cohort size, call IDs discovered, transcript records
94
94
  scanned, hits, errors, and quota gaps.
@@ -45,13 +45,13 @@ description: >
45
45
  Use `grafana` for agent-facing Grafana work. Do not call `/api/grafana/*`
46
46
  directly from the agent.
47
47
 
48
- | Mode | Args | Description |
49
- | --- | --- | --- |
50
- | `dashboards` | `search` | Search dashboards |
51
- | `dashboard` | `uid` | Full dashboard JSON |
52
- | `datasources` | | List datasources |
53
- | `alerts` | | Alert rules and firing instances |
54
- | `query` | `datasourceUid`, `queries`, `from`, `to` | Query a datasource |
48
+ | Mode | Args | Description |
49
+ | ------------- | ---------------------------------------- | -------------------------------- |
50
+ | `dashboards` | `search` | Search dashboards |
51
+ | `dashboard` | `uid` | Full dashboard JSON |
52
+ | `datasources` | | List datasources |
53
+ | `alerts` | | Alert rules and firing instances |
54
+ | `query` | `datasourceUid`, `queries`, `from`, `to` | Query a datasource |
55
55
 
56
56
  ### Dashboard
57
57
 
@@ -34,13 +34,13 @@ description: >
34
34
  Use `sentry` for all agent-facing Sentry work. Do not call `/api/sentry/*`
35
35
  directly from the agent.
36
36
 
37
- | Mode | Args | Description |
38
- | --- | --- | --- |
39
- | `organizations` | | List organizations visible to the token |
40
- | `issues` | `statsPeriod`, `project`, `query`, `orgSlug` | Frequent issues, sorted by frequency |
41
- | `projects` | `orgSlug` | List projects |
42
- | `issue-events` | `issueId`, `orgSlug` | Events for a specific issue |
43
- | `stats` | `statsPeriod`, `category`, `orgSlug` | Org-level stats |
37
+ | Mode | Args | Description |
38
+ | --------------- | -------------------------------------------- | --------------------------------------- |
39
+ | `organizations` | | List organizations visible to the token |
40
+ | `issues` | `statsPeriod`, `project`, `query`, `orgSlug` | Frequent issues, sorted by frequency |
41
+ | `projects` | `orgSlug` | List projects |
42
+ | `issue-events` | `issueId`, `orgSlug` | Events for a specific issue |
43
+ | `stats` | `statsPeriod`, `category`, `orgSlug` | Org-level stats |
44
44
 
45
45
  ### API Routes
46
46
 
@@ -35,13 +35,13 @@ description: >
35
35
  Use `slack-messages` for agent-facing Slack reads. Do not call
36
36
  `/api/slack/*` directly from the agent.
37
37
 
38
- | Mode | Args | Description |
39
- | --- | --- | --- |
40
- | `team` | `workspace` | Get workspace info |
41
- | `channels` | `workspace` | List channels |
42
- | `history` | `workspace`, `channel`, `limit`, `cursor` | Read channel history |
38
+ | Mode | Args | Description |
39
+ | --------------- | ---------------------------------------------------- | ---------------------- |
40
+ | `team` | `workspace` | Get workspace info |
41
+ | `channels` | `workspace` | List channels |
42
+ | `history` | `workspace`, `channel`, `limit`, `cursor` | Read channel history |
43
43
  | `multi-history` | `workspace`, `channels`, `names`, `limit`, `cursors` | Read multiple channels |
44
- | `search` | `workspace`, `query` | Search messages |
44
+ | `search` | `workspace`, `query` | Search messages |
45
45
 
46
46
  ## Key Patterns & Gotchas
47
47
 
@@ -22,13 +22,13 @@ description: How to connect to and query the Stripe API for analytics data.
22
22
  Use `stripe` for agent-facing Stripe work. Do not call `/api/stripe/*`
23
23
  directly from the agent.
24
24
 
25
- | Mode | Args | Description |
26
- | --- | --- | --- |
27
- | `billing` | `email`, `customerId`, `query`, `months` | Invoices for a customer in timeframe |
28
- | `payment-status` | `email`, `customerId`, `query` | Recent charges + payment intents |
29
- | `refunds` | `email`, `customerId`, `query` | Refunds associated with customer |
30
- | `subscriptions` | `email`, `customerId`, `query` | Active subscriptions |
31
- | `billing-by-product` | `email`, `customerId`, `query`, `months` | Billing aggregated by product |
25
+ | Mode | Args | Description |
26
+ | -------------------- | ---------------------------------------- | ------------------------------------ |
27
+ | `billing` | `email`, `customerId`, `query`, `months` | Invoices for a customer in timeframe |
28
+ | `payment-status` | `email`, `customerId`, `query` | Recent charges + payment intents |
29
+ | `refunds` | `email`, `customerId`, `query` | Refunds associated with customer |
30
+ | `subscriptions` | `email`, `customerId`, `query` | Active subscriptions |
31
+ | `billing-by-product` | `email`, `customerId`, `query`, `months` | Billing aggregated by product |
32
32
 
33
33
  ## API Routes
34
34
 
@@ -159,8 +159,11 @@ details live in `.agents/skills/`.
159
159
  context.
160
160
  - `navigate` moves the user to the relevant analytics view, including
161
161
  `view="catalog"` for the template catalog, `view="sessions"` for session
162
- replay, and `view="agents"` / `agentsView="database"` with optional
163
- `dbAdminConnectionId` for agent monitoring or connected app database admin.
162
+ replay, `view="monitoring"` with `monitoringView="uptime|errors"` (plus the
163
+ `monitorId`, `statusPageId`, or `errorIssueId` deep links) for uptime checks,
164
+ public status pages, or error triage, and `view="agents"` /
165
+ `agentsView="database"` with optional `dbAdminConnectionId` for agent
166
+ monitoring or connected app database admin.
164
167
  - Use `view-screen` when the active dashboard/chart context is unclear.
165
168
 
166
169
  ## Session Replay
@@ -201,6 +204,48 @@ details live in `.agents/skills/`.
201
204
  `/sessions/:recordingId`; rows that only include `session_id` can link to a
202
205
  filtered `/sessions` search.
203
206
 
207
+ ## Monitoring
208
+
209
+ - `/monitoring` is the Monitoring tab (`app/routes/monitoring._index.tsx` →
210
+ `app/pages/monitoring/MonitoringPage.tsx`), a thin shell hosting two
211
+ independently-owned panels selected by `?view=uptime|errors` (defaults to
212
+ uptime). `navigation` mirrors it as `view="monitoring"` with `monitoringView`
213
+ (plus `monitorId`/`errorIssueId` when a row is open); each panel also writes
214
+ richer selection to the `monitoring` application-state key.
215
+ - Uptime (`app/pages/monitoring/UptimePanel.tsx`,
216
+ `app/pages/monitoring/uptime/**`) manages synthetic HTTP checks with
217
+ alerting. Actions: `list-monitors`, `get-monitor`, `save-monitor`,
218
+ `run-monitor-check`, `delete-monitor`. Checks/alerting run server-side in
219
+ `server/lib/uptime-monitors.ts` (sweep job `server/jobs/uptime-monitors.ts`,
220
+ scheduler `server/plugins/uptime-monitor-jobs.ts`) over
221
+ `server/db/schema-monitoring.ts`. Deep links: list `?view=uptime`, detail
222
+ `?view=uptime&monitor=<id>`, create `?view=uptime&monitor=new`, edit
223
+ `?view=uptime&monitor=<id>&edit=1`. See `docs/uptime-monitoring.md`.
224
+ - Status pages (`app/pages/monitoring/uptime/status-pages/**`) are a config
225
+ sub-view under Uptime that bundle chosen monitors under a public
226
+ `/status/<slug>` page. Actions: `list-status-pages`, `get-status-page`,
227
+ `save-status-page`, `delete-status-page`, `add-status-page-monitor`,
228
+ `remove-status-page-monitor`, `reorder-status-page-monitors`, plus the
229
+ unauthenticated `get-public-status-page`. Owner-scoped CRUD and the sanitized
230
+ public projection live in `server/lib/status-pages.ts` over
231
+ `server/db/schema-monitoring.ts`. Deep links: index
232
+ `?view=uptime&statuspage=list`, create `?view=uptime&statuspage=new`, edit
233
+ `?view=uptime&statuspage=<id>`.
234
+ - Errors (`app/pages/monitoring/ErrorsPanel.tsx`,
235
+ `app/pages/monitoring/errors/**`) is Sentry-style exception triage grouped
236
+ into issues by fingerprint. Actions: `list-error-issues`, `get-error-issue`,
237
+ `resolve-error-issue`, `capture-test-error`, `match-error-issues`.
238
+ Ingest/grouping lives in `server/lib/error-capture.ts` over
239
+ `server/db/schema-errors.ts`. Browser capture uses the SDK from
240
+ `@agent-native/core/client` (`captureException` / `captureMessage` /
241
+ `addErrorBreadcrumb`), auto-enabled by `configureTracking` and transported
242
+ through the first-party analytics ingest as a `$exception` event. Deep link:
243
+ `?view=errors&issue=<id>`. See `docs/error-capture.md`.
244
+ - Session replay ↔ Errors: a recording's devtools Console error lines link to
245
+ the grouped issue at `/monitoring?view=errors&issue=<id>`, resolved by
246
+ `match-error-issues` (exact fingerprint match, no heuristics); issues link
247
+ back to the originating recording at `/sessions/<recordingId>`.
248
+
204
249
  ## Dashboard Template Catalog
205
250
 
206
251
  - To build or extend a LARGE first-party dashboard, prefer `compose-dashboard`: