@agent-native/core 0.153.2 → 0.153.5

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 (92) hide show
  1. package/corpus/README.md +1 -1
  2. package/corpus/templates/analytics/AGENTS.md +4 -0
  3. package/corpus/templates/analytics/actions/account-deep-dive.ts +1 -0
  4. package/corpus/templates/analytics/actions/bigquery-query.ts +1 -0
  5. package/corpus/templates/analytics/actions/bigquery.ts +1 -0
  6. package/corpus/templates/analytics/actions/content-calendar-schema.ts +1 -0
  7. package/corpus/templates/analytics/actions/content-calendar.ts +1 -0
  8. package/corpus/templates/analytics/actions/gcloud.ts +1 -0
  9. package/corpus/templates/analytics/actions/get-data-program.ts +1 -0
  10. package/corpus/templates/analytics/actions/get-error-issue.ts +1 -0
  11. package/corpus/templates/analytics/actions/get-monitor-stats.ts +1 -0
  12. package/corpus/templates/analytics/actions/get-monitor.ts +1 -0
  13. package/corpus/templates/analytics/actions/get-session-replay-events.ts +1 -0
  14. package/corpus/templates/analytics/actions/get-session-replay-summary.ts +1 -0
  15. package/corpus/templates/analytics/actions/get-session-replay-timeline.ts +1 -0
  16. package/corpus/templates/analytics/actions/gong-calls.ts +1 -0
  17. package/corpus/templates/analytics/actions/gong-native-insights.ts +1 -0
  18. package/corpus/templates/analytics/actions/grafana.ts +1 -0
  19. package/corpus/templates/analytics/actions/hubspot-deals.ts +1 -0
  20. package/corpus/templates/analytics/actions/hubspot-metrics.ts +1 -0
  21. package/corpus/templates/analytics/actions/hubspot-pipelines.ts +1 -0
  22. package/corpus/templates/analytics/actions/hubspot-records.ts +1 -0
  23. package/corpus/templates/analytics/actions/jira-search.ts +1 -0
  24. package/corpus/templates/analytics/actions/jira.ts +1 -0
  25. package/corpus/templates/analytics/actions/list-error-issues.ts +1 -0
  26. package/corpus/templates/analytics/actions/list-monitors.ts +1 -0
  27. package/corpus/templates/analytics/actions/list-session-recordings.ts +1 -0
  28. package/corpus/templates/analytics/actions/match-error-issues.ts +1 -0
  29. package/corpus/templates/analytics/actions/prometheus.ts +1 -0
  30. package/corpus/templates/analytics/actions/pylon-issues.ts +1 -0
  31. package/corpus/templates/analytics/actions/query-agent-native-analytics.ts +1 -0
  32. package/corpus/templates/analytics/actions/query-dashboard-panel.ts +1 -0
  33. package/corpus/templates/analytics/actions/query-inbound-forms.ts +1 -0
  34. package/corpus/templates/analytics/actions/run-monitor-check.ts +1 -0
  35. package/corpus/templates/analytics/actions/sentry.ts +1 -0
  36. package/corpus/templates/analytics/actions/seo-blog-pages.ts +1 -0
  37. package/corpus/templates/analytics/actions/seo-page-keywords.ts +1 -0
  38. package/corpus/templates/analytics/actions/seo-top-keywords.ts +1 -0
  39. package/corpus/templates/analytics/actions/slack-messages.ts +1 -0
  40. package/corpus/templates/analytics/actions/stripe.ts +1 -0
  41. package/corpus/templates/analytics/actions/test-custom-api-connection.ts +1 -0
  42. package/corpus/templates/analytics/server/lib/real-data-actions.ts +38 -47
  43. package/corpus/templates/analytics/server/plugins/agent-chat.ts +41 -34
  44. package/corpus/templates/clips/desktop/src-tauri/src/native_screen.rs +9 -6
  45. package/corpus/templates/clips/desktop/src-tauri/src/rewind_clip.rs +70 -10
  46. package/corpus/templates/forms/AGENTS.md +6 -0
  47. package/corpus/templates/forms/server/plugins/agent-chat.ts +1 -0
  48. package/corpus/templates/mail/AGENTS.md +5 -4
  49. package/corpus/templates/mail/actions/get-automation-settings.ts +17 -6
  50. package/corpus/templates/mail/actions/send-email.ts +17 -9
  51. package/corpus/templates/mail/actions/send-queued-drafts.ts +21 -11
  52. package/corpus/templates/mail/actions/update-automation-settings.ts +20 -6
  53. package/corpus/templates/mail/app/i18n/en-US.ts +5 -0
  54. package/corpus/templates/mail/app/pages/SettingsPage.tsx +68 -7
  55. package/corpus/templates/mail/server/lib/automation-settings.ts +27 -0
  56. package/corpus/templates/mail/server/plugins/agent-chat.ts +2 -0
  57. package/corpus/templates/slides/app/components/editor/EditorSidebar.tsx +3 -3
  58. package/corpus/templates/slides/app/components/presentation/PresentationView.tsx +17 -4
  59. package/corpus/templates/slides/app/context/DeckContext.tsx +3 -2
  60. package/corpus/templates/slides/app/pages/DeckEditor.tsx +44 -0
  61. package/corpus/templates/slides/changelog/2026-08-12-arrow-key-navigation-in-the-slide-film-strip-now-scrolls-sli.md +6 -0
  62. package/corpus/templates/slides/changelog/2026-08-12-duplicate-a-slide-from-the-film-strip-with-cmd-ctrl-c-then-c.md +6 -0
  63. package/corpus/templates/slides/changelog/2026-08-12-presenting-a-deck-now-returns-you-to-the-slide-you-were-view.md +6 -0
  64. package/dist/action.d.ts +13 -0
  65. package/dist/action.js +3 -0
  66. package/dist/agent/engine/tool-call-journal-seed.d.ts +27 -10
  67. package/dist/agent/engine/tool-call-journal-seed.js +46 -32
  68. package/dist/agent/production-agent.d.ts +33 -0
  69. package/dist/agent/production-agent.js +172 -57
  70. package/dist/agent/run-loop-with-resume.d.ts +1 -1
  71. package/dist/agent/run-loop-with-resume.js +49 -35
  72. package/dist/client/agent-chat-adapter.js +204 -273
  73. package/dist/client/resources/mcp-integration-catalog.d.ts +7 -0
  74. package/dist/client/resources/mcp-integration-catalog.js +14 -1
  75. package/dist/client/settings/AgentsSection.js +46 -30
  76. package/dist/client/sse-event-processor.d.ts +7 -0
  77. package/dist/client/sse-event-processor.js +21 -1
  78. package/dist/collab/awareness.d.ts +2 -2
  79. package/dist/collab/routes.d.ts +1 -1
  80. package/dist/collab/struct-routes.d.ts +1 -1
  81. package/dist/notifications/routes.d.ts +1 -1
  82. package/dist/observability/routes.d.ts +3 -3
  83. package/dist/provider-api/actions/github-repo-files.js +1 -0
  84. package/dist/provider-api/actions/provider-api.js +1 -0
  85. package/dist/provider-api/actions/staged-datasets.js +1 -0
  86. package/dist/provider-api/corpus-jobs.js +1 -0
  87. package/dist/server/action-discovery.js +2 -0
  88. package/dist/server/agent-chat-plugin.js +1 -0
  89. package/dist/server/agent-engine-api-key-route.d.ts +1 -1
  90. package/dist/server/realtime-token.d.ts +1 -1
  91. package/dist/server/transcribe-voice.d.ts +1 -1
  92. package/package.json +3 -3
@@ -675,6 +675,16 @@ export const DEFAULT_MCP_INTEGRATIONS = [
675
675
  docsUrl: "https://developer.box.com/guides/box-mcp",
676
676
  setupNoteKey: "mcpIntegrations.catalog.box.setupNote",
677
677
  keywords: ["files", "folders", "documents", "enterprise content"],
678
+ // "Box" alone collides with everyday nouns (text box, checkbox, bounding
679
+ // box), so require a qualified phrase before suggesting the connection.
680
+ promptAliases: [
681
+ "Box.com",
682
+ "Box file",
683
+ "Box files",
684
+ "Box folder",
685
+ "Box folders",
686
+ "Box drive",
687
+ ],
678
688
  },
679
689
  {
680
690
  id: "builder-cms",
@@ -947,7 +957,10 @@ export function findMcpIntegrationForText(text, integrations = getDefaultMcpInte
947
957
  isMcpConnectionFailureText(normalizedText);
948
958
  if (!hasResourceIntent)
949
959
  return null;
950
- const matchesCanonicalName = (integration) => [integration.name, ...(integration.brandAliases ?? [])].some((alias) => textContainsTerm(normalizedText, alias));
960
+ const matchesCanonicalName = (integration) => [
961
+ ...(integration.promptAliases ?? [integration.name]),
962
+ ...(integration.brandAliases ?? []),
963
+ ].some((alias) => textContainsTerm(normalizedText, alias));
951
964
  const canonicalMatch = integrations.find(matchesCanonicalName);
952
965
  if (canonicalMatch)
953
966
  return canonicalMatch;
@@ -165,12 +165,20 @@ function AgentAddPopover({ initialName = "", initialUrl = "", initialDescription
165
165
  if (!trimmedName || !trimmedUrl)
166
166
  return;
167
167
  const trimmedDescription = description.trim();
168
- const ok = await onAdd(trimmedName, trimmedUrl, trimmedDescription);
169
- if (ok) {
170
- setAdded({
171
- name: trimmedName,
172
- url: trimmedUrl,
173
- description: trimmedDescription,
168
+ try {
169
+ const ok = await onAdd(trimmedName, trimmedUrl, trimmedDescription);
170
+ if (ok) {
171
+ setAdded({
172
+ name: trimmedName,
173
+ url: trimmedUrl,
174
+ description: trimmedDescription,
175
+ });
176
+ }
177
+ }
178
+ catch (error) {
179
+ setCheck({
180
+ status: "error",
181
+ message: error instanceof Error ? error.message : "Could not add agent",
174
182
  });
175
183
  }
176
184
  };
@@ -236,8 +244,12 @@ export function AgentsSection() {
236
244
  const [showAdd, setShowAdd] = useState(false);
237
245
  const [prefill, setPrefill] = useState(null);
238
246
  const [probeById, setProbeById] = useState(null);
239
- const { data: org } = useOrg();
247
+ const orgQuery = useOrg();
248
+ const { data: org } = orgQuery;
240
249
  const syncSecret = useSyncA2ASecret();
250
+ const canManageSharedAgents = !orgQuery.isLoading &&
251
+ !orgQuery.isError &&
252
+ (!org?.orgId || org.role === "owner" || org.role === "admin");
241
253
  // Landing from a peer's "register back" deep link (see
242
254
  // buildPeerRegisterBackLink): the open route only echoes `f_*` params onto
243
255
  // the redirect URL, so read those here and open the Add popover prefilled.
@@ -343,26 +355,30 @@ export function AgentsSection() {
343
355
  url,
344
356
  color: "#6B7280",
345
357
  }, null, 2);
346
- try {
347
- const res = await fetch(agentNativePath("/_agent-native/resources"), {
348
- method: "POST",
349
- headers: { "Content-Type": "application/json" },
350
- body: JSON.stringify({
351
- path: remoteAgentResourcePath(id),
352
- content: agentJson,
353
- shared: true,
354
- }),
355
- });
356
- // Deliberately don't close the popover here — a successful add shows a
357
- // follow-up state (registration is one-way; the peer doesn't know
358
- // about us yet) that the user dismisses explicitly.
359
- if (res.ok)
360
- fetchAgents();
361
- return res.ok;
362
- }
363
- catch {
364
- return false;
358
+ const res = await fetch(agentNativePath("/_agent-native/resources"), {
359
+ method: "POST",
360
+ headers: { "Content-Type": "application/json" },
361
+ body: JSON.stringify({
362
+ path: remoteAgentResourcePath(id),
363
+ content: agentJson,
364
+ shared: true,
365
+ }),
366
+ });
367
+ if (!res.ok) {
368
+ let body;
369
+ try {
370
+ body = (await res.json());
371
+ }
372
+ catch {
373
+ throw new Error(`Add failed (${res.status})`);
374
+ }
375
+ throw new Error(body?.error ?? body?.message ?? `Add failed (${res.status})`);
365
376
  }
377
+ // Deliberately don't close the popover here — a successful add shows a
378
+ // follow-up state (registration is one-way; the peer doesn't know
379
+ // about us yet) that the user dismisses explicitly.
380
+ fetchAgents();
381
+ return true;
366
382
  };
367
383
  const handleSave = async (agent) => {
368
384
  const agentJson = JSON.stringify({
@@ -398,13 +414,13 @@ export function AgentsSection() {
398
414
  }
399
415
  catch { }
400
416
  };
401
- return (_jsxs("div", { children: [_jsx("div", { className: "mb-3 flex flex-wrap items-center justify-end gap-3", children: _jsxs("div", { className: "relative", children: [_jsxs("button", { onClick: () => {
417
+ return (_jsxs("div", { children: [_jsx("div", { className: "mb-3 flex flex-wrap items-center justify-end gap-3", children: canManageSharedAgents ? (_jsxs("div", { className: "relative", children: [_jsxs("button", { onClick: () => {
402
418
  setShowAdd(!showAdd);
403
419
  setEditingAgent(null);
404
420
  }, className: "inline-flex items-center gap-1.5 rounded-md border border-border px-3 py-1.5 text-xs font-medium text-foreground hover:bg-accent", children: [showAdd ? _jsx(IconX, { size: 13 }) : _jsx(IconPlus, { size: 13 }), showAdd ? "Cancel" : "Connect agent"] }), showAdd && (_jsx(AgentAddPopover, { initialName: prefill?.name, initialUrl: prefill?.url, initialDescription: prefill?.description, secretSet: org?.a2aSecretSet, syncSecret: syncSecret, onAdd: handleAdd, onClose: () => {
405
421
  setShowAdd(false);
406
422
  setPrefill(null);
407
- } }))] }) }), _jsx(A2ASecretStatusRow, { org: org, syncSecret: syncSecret }), loading ? (_jsxs("div", { className: "space-y-1.5", role: "status", "aria-busy": "true", "aria-label": "Loading connected agents", children: [_jsx(Skeleton, { className: "h-6 w-full bg-muted/50" }), _jsx(Skeleton, { className: "h-6 w-3/4 bg-muted/50" })] })) : agents.length === 0 ? (_jsxs("div", { className: "flex flex-col items-center rounded-xl border border-border/70 bg-card px-5 py-8 text-center", children: [_jsx("span", { className: "mb-2 flex size-9 items-center justify-center rounded-full bg-muted text-muted-foreground", children: _jsx(IconTopologyRing2, { size: 17 }) }), _jsx("p", { className: "text-sm font-medium text-foreground", children: "No connected agents yet" }), _jsx("p", { className: "mt-1 max-w-sm text-xs leading-5 text-muted-foreground", children: "Connect an A2A agent to delegate work from chat." }), _jsxs("button", { onClick: () => setShowAdd(true), className: "mt-4 inline-flex items-center gap-1.5 rounded-md border border-border px-3 py-1.5 text-xs font-medium text-foreground hover:bg-accent", children: [_jsx(IconPlus, { size: 13 }), "Connect agent"] })] })) : (_jsx("div", { className: "overflow-hidden rounded-xl border border-border/70 bg-card text-card-foreground", children: _jsx("div", { className: "divide-y divide-border/60 px-4", children: agents.map((agent) => {
423
+ } }))] })) : !orgQuery.isLoading ? (_jsx("span", { className: "text-[10px] text-muted-foreground", children: "Only workspace owners and admins can connect agents." })) : null }), _jsx(A2ASecretStatusRow, { org: org, syncSecret: syncSecret }), loading ? (_jsxs("div", { className: "space-y-1.5", role: "status", "aria-busy": "true", "aria-label": "Loading connected agents", children: [_jsx(Skeleton, { className: "h-6 w-full bg-muted/50" }), _jsx(Skeleton, { className: "h-6 w-3/4 bg-muted/50" })] })) : agents.length === 0 ? (_jsxs("div", { className: "flex flex-col items-center rounded-xl border border-border/70 bg-card px-5 py-8 text-center", children: [_jsx("span", { className: "mb-2 flex size-9 items-center justify-center rounded-full bg-muted text-muted-foreground", children: _jsx(IconTopologyRing2, { size: 17 }) }), _jsx("p", { className: "text-sm font-medium text-foreground", children: "No connected agents yet" }), _jsx("p", { className: "mt-1 max-w-sm text-xs leading-5 text-muted-foreground", children: "Connect an A2A agent to delegate work from chat." }), canManageSharedAgents ? (_jsxs("button", { onClick: () => setShowAdd(true), className: "mt-4 inline-flex items-center gap-1.5 rounded-md border border-border px-3 py-1.5 text-xs font-medium text-foreground hover:bg-accent", children: [_jsx(IconPlus, { size: 13 }), "Connect agent"] })) : !orgQuery.isLoading ? (_jsx("p", { className: "mt-4 text-xs text-muted-foreground", children: "Ask a workspace owner or admin to connect an agent." })) : null] })) : (_jsx("div", { className: "overflow-hidden rounded-xl border border-border/70 bg-card text-card-foreground", children: _jsx("div", { className: "divide-y divide-border/60 px-4", children: agents.map((agent) => {
408
424
  const probe = probeById?.get(getRemoteAgentIdFromPath(agent.path).toLowerCase());
409
425
  const dotState = !probe
410
426
  ? null
@@ -413,9 +429,9 @@ export function AgentsSection() {
413
429
  : "warn";
414
430
  return (_jsxs("div", { className: "group relative", children: [_jsxs("div", { className: "flex w-full items-center gap-3 py-4", children: [_jsx("span", { className: "flex size-8 shrink-0 items-center justify-center rounded-lg border border-border bg-background text-muted-foreground", children: _jsx(IconTopologyRing2, { size: 15 }) }), dotState ? (_jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx("span", { className: `h-1.5 w-1.5 shrink-0 rounded-full ${dotState === "ok"
415
431
  ? "bg-primary"
416
- : "bg-destructive"}` }) }), _jsx(TooltipContent, { children: probe && describeProbeTooltip(probe) })] })) : (_jsx("span", { className: "h-1.5 w-1.5 shrink-0 rounded-full bg-transparent" })), _jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("span", { className: "block truncate text-sm font-medium text-foreground", children: agent.name }), _jsx("span", { className: "mt-0.5 block truncate text-xs text-muted-foreground", children: agent.url })] }), _jsx("button", { onClick: () => {
432
+ : "bg-destructive"}` }) }), _jsx(TooltipContent, { children: probe && describeProbeTooltip(probe) })] })) : (_jsx("span", { className: "h-1.5 w-1.5 shrink-0 rounded-full bg-transparent" })), _jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("span", { className: "block truncate text-sm font-medium text-foreground", children: agent.name }), _jsx("span", { className: "mt-0.5 block truncate text-xs text-muted-foreground", children: agent.url })] }), canManageSharedAgents ? (_jsx("button", { onClick: () => {
417
433
  setEditingAgent(editingAgent === agent.id ? null : agent.id);
418
434
  setShowAdd(false);
419
- }, className: "shrink-0 rounded-md border border-border px-2.5 py-1.5 text-xs font-medium text-foreground hover:bg-accent", children: "Manage" })] }), editingAgent === agent.id && (_jsx(AgentEditPopover, { agent: agent, onSave: handleSave, onDelete: handleDelete, onClose: () => setEditingAgent(null) }))] }, agent.id));
435
+ }, className: "shrink-0 rounded-md border border-border px-2.5 py-1.5 text-xs font-medium text-foreground hover:bg-accent", children: "Manage" })) : null] }), canManageSharedAgents && editingAgent === agent.id && (_jsx(AgentEditPopover, { agent: agent, onSave: handleSave, onDelete: handleDelete, onClose: () => setEditingAgent(null) }))] }, agent.id));
420
436
  }) }) }))] }));
421
437
  }
@@ -110,6 +110,13 @@ export interface AgentAutoContinueErrorInfo {
110
110
  recoverable?: boolean;
111
111
  upgradeUrl?: string;
112
112
  }
113
+ /**
114
+ * Kept verbatim in sync with `INTERRUPTED_TOOL_RESULT_MARKER`
115
+ * (agent/production-agent.ts): the server matches this substring in replayed
116
+ * history to count how many times a write tool was interrupted, which is the
117
+ * only thing that tells "we do not know if it landed" apart from "it failed".
118
+ */
119
+ export declare const INTERRUPTED_TOOL_RESULT = "Interrupted before this tool returned a result.";
113
120
  export declare function settleInterruptedToolCalls(content: ContentPart[], result?: string, options?: {
114
121
  includeActivity?: boolean;
115
122
  activityResult?: string;
@@ -2,7 +2,13 @@ import { LLM_MISSING_CREDENTIALS_ERROR_CODE, LLM_MISSING_CREDENTIALS_MESSAGE, }
2
2
  import { emitChatFirstOpenApp } from "./chat-first.js";
3
3
  import { formatChatErrorText, normalizeChatError } from "./error-format.js";
4
4
  import { humanizeToolLabelText, humanizeToolName, runningToolLabel, } from "./tool-display.js";
5
- const INTERRUPTED_TOOL_RESULT = "Interrupted before this tool returned a result.";
5
+ /**
6
+ * Kept verbatim in sync with `INTERRUPTED_TOOL_RESULT_MARKER`
7
+ * (agent/production-agent.ts): the server matches this substring in replayed
8
+ * history to count how many times a write tool was interrupted, which is the
9
+ * only thing that tells "we do not know if it landed" apart from "it failed".
10
+ */
11
+ export const INTERRUPTED_TOOL_RESULT = "Interrupted before this tool returned a result.";
6
12
  const INTERRUPTED_ACTIVITY_RESULT = "Stopped before this action started.";
7
13
  /**
8
14
  * Maximum number of assistant-ui repository updates we deliver in one browser
@@ -1542,11 +1548,25 @@ export function processEvent(ev, content, toolCallCounter, tabId, state) {
1542
1548
  }
1543
1549
  return { action: "continue" };
1544
1550
  }
1551
+ /**
1552
+ * Drop the draft the server is about to re-emit — the narration since the last
1553
+ * completed tool, not the whole turn. A `clear` arrives on a final-answer-guard
1554
+ * retry or a continuation, both of which resume AFTER the last completed tool
1555
+ * call, so anything before that boundary is settled multi-step narration the
1556
+ * retry will never re-send. Wiping it read to users as "it deleted its reply
1557
+ * and started over", and `thread-data-builder` replays this same scoping on
1558
+ * rebuild, so the loss survived a reload.
1559
+ */
1545
1560
  function clearAssistantDraftContent(content) {
1546
1561
  for (let index = content.length - 1; index >= 0; index--) {
1547
1562
  const part = content[index];
1548
1563
  if (!part)
1549
1564
  continue;
1565
+ if (part.type === "tool-call" &&
1566
+ part.activity !== true &&
1567
+ part.result !== undefined) {
1568
+ return;
1569
+ }
1550
1570
  if (part.type === "text" || part.type === "reasoning") {
1551
1571
  content.splice(index, 1);
1552
1572
  continue;
@@ -62,11 +62,11 @@ export declare const postAwareness: import("h3").EventHandlerWithFetch<import("h
62
62
  error: string;
63
63
  states?: undefined;
64
64
  } | {
65
- error?: undefined;
66
65
  states: {
67
66
  clientId: number;
68
67
  state: string;
69
68
  }[];
69
+ error?: undefined;
70
70
  }>>;
71
71
  /**
72
72
  * GET /_agent-native/collab/:docId/users
@@ -77,9 +77,9 @@ export declare const getActiveUsers: import("h3").EventHandlerWithFetch<import("
77
77
  error: string;
78
78
  users?: undefined;
79
79
  } | {
80
- error?: undefined;
81
80
  users: {
82
81
  clientId: number;
83
82
  lastSeen: number;
84
83
  }[];
84
+ error?: undefined;
85
85
  }>>;
@@ -26,8 +26,8 @@ export declare const getCollabState: import("h3").EventHandlerWithFetch<import("
26
26
  * Body: { update: string (base64), requestSource?: string }
27
27
  */
28
28
  export declare const postCollabUpdate: import("h3").EventHandlerWithFetch<import("h3").EventHandlerRequest, Promise<{
29
- error: string;
30
29
  ok?: undefined;
30
+ error: string;
31
31
  } | {
32
32
  error?: undefined;
33
33
  ok: boolean;
@@ -13,8 +13,8 @@
13
13
  * Body: { json: any, fieldName?: string, type?: "map"|"array", requestSource?: string }
14
14
  */
15
15
  export declare const postCollabJson: import("h3").EventHandlerWithFetch<import("h3").EventHandlerRequest, Promise<{
16
- ok?: undefined;
17
16
  error: string;
17
+ ok?: undefined;
18
18
  } | {
19
19
  error?: undefined;
20
20
  ok: boolean;
@@ -28,6 +28,6 @@ export declare function createNotificationsHandler(): import("h3").EventHandlerW
28
28
  } | {
29
29
  count?: undefined;
30
30
  updated?: undefined;
31
- ok: boolean;
32
31
  error?: undefined;
32
+ ok: boolean;
33
33
  }>>;
@@ -41,16 +41,16 @@ export declare function createObservabilityHandler(): import("h3").EventHandlerW
41
41
  thumbsUpRate: number;
42
42
  avgEvalScore: number;
43
43
  } | {
44
- error?: undefined;
45
44
  summary: import("./types.js").TraceSummary;
46
45
  spans: import("./types.js").TraceSpan[];
47
46
  id?: undefined;
47
+ error?: undefined;
48
48
  ok?: undefined;
49
49
  } | {
50
- error?: undefined;
51
50
  summary?: undefined;
52
51
  spans?: undefined;
53
52
  id: string;
53
+ error?: undefined;
54
54
  ok?: undefined;
55
55
  } | {
56
56
  summary?: undefined;
@@ -59,9 +59,9 @@ export declare function createObservabilityHandler(): import("h3").EventHandlerW
59
59
  error: any;
60
60
  ok?: undefined;
61
61
  } | {
62
- error?: undefined;
63
62
  summary?: undefined;
64
63
  spans?: undefined;
65
64
  id?: undefined;
66
65
  ok: boolean;
66
+ error?: undefined;
67
67
  }>>;
@@ -130,6 +130,7 @@ export function createGitHubRepoFilesAction(runtime, options = {}) {
130
130
  needsApproval: requireApprovalForWrites
131
131
  ? (args) => args.operation === "write" || args.operation === "delete"
132
132
  : false,
133
+ grounding: true,
133
134
  run: async (args) => {
134
135
  if (args.operation === "list") {
135
136
  return runtime.listGitHubRepositoryFiles({
@@ -231,6 +231,7 @@ export function createProviderApiRequestAction(runtime, options = {}) {
231
231
  }),
232
232
  summary: (args) => buildProviderApiAuditSummary(args),
233
233
  },
234
+ grounding: true,
234
235
  run: async (rawArgs) => {
235
236
  const args = rawArgs;
236
237
  if (args.stageAs) {
@@ -120,6 +120,7 @@ export function createQueryStagedDatasetAction(options = {}) {
120
120
  schema,
121
121
  http: options.http ?? false,
122
122
  readOnly: true,
123
+ grounding: true,
123
124
  run: async (rawArgs) => {
124
125
  const args = rawArgs;
125
126
  const scope = resolveScope("query-staged-dataset", args, options);
@@ -205,6 +205,7 @@ export function createProviderCorpusJobAction(options) {
205
205
  "When status is paused or quota_wait, call operation=continue with the jobId after the indicated time/budget. Report coverage counts, paginationComplete, and any remaining gaps; a max-pages stop is not exhaustive.",
206
206
  schema: ProviderCorpusJobSchema,
207
207
  http: false,
208
+ grounding: true,
208
209
  run: async (args) => runProviderCorpusJobAction(args, options),
209
210
  });
210
211
  }
@@ -168,6 +168,8 @@ function preserveActionFlags(entry) {
168
168
  }
169
169
  if (typeof entry.readOnly === "boolean")
170
170
  out.readOnly = entry.readOnly;
171
+ if (typeof entry.grounding === "boolean")
172
+ out.grounding = entry.grounding;
171
173
  if (typeof entry.allowInPlanMode === "boolean") {
172
174
  out.allowInPlanMode = entry.allowInPlanMode;
173
175
  }
@@ -2285,6 +2285,7 @@ export function createAgentChatPlugin(options) {
2285
2285
  const leanActionEntries = {
2286
2286
  ...templateScripts,
2287
2287
  ...resourceScripts,
2288
+ ...workspaceFileActions,
2288
2289
  ...refreshScreenTool,
2289
2290
  ...urlTools,
2290
2291
  ...chatScripts,
@@ -27,10 +27,10 @@ export declare function resolveAgentEngineApiKeyWriteTarget(event: H3Event, scop
27
27
  export declare function createAgentEngineApiKeyHandler(): import("h3").EventHandlerWithFetch<import("h3").EventHandlerRequest, Promise<{
28
28
  error: any;
29
29
  } | {
30
- error?: undefined;
31
30
  ok: boolean;
32
31
  key: string;
33
32
  baseUrlKey?: string;
34
33
  scope: AgentEngineApiKeyScope;
34
+ error?: undefined;
35
35
  }>>;
36
36
  export {};
@@ -26,8 +26,8 @@ export declare function createRealtimeTokenHandler(): import("h3").EventHandlerW
26
26
  expiresAt?: undefined;
27
27
  ttlSeconds?: undefined;
28
28
  } | {
29
- error?: undefined;
30
29
  token: string;
31
30
  expiresAt: string;
32
31
  ttlSeconds: number;
32
+ error?: undefined;
33
33
  }>>;
@@ -20,6 +20,6 @@ export declare function createTranscribeVoiceHandler(): import("h3").EventHandle
20
20
  error: string;
21
21
  text?: undefined;
22
22
  } | {
23
- error?: undefined;
24
23
  text: string;
24
+ error?: undefined;
25
25
  }>>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-native/core",
3
- "version": "0.153.2",
3
+ "version": "0.153.5",
4
4
  "description": "Framework for agent-native application development — where AI agents and UI share SQL state, actions, and context",
5
5
  "homepage": "https://github.com/BuilderIO/agent-native#readme",
6
6
  "bugs": {
@@ -421,8 +421,8 @@
421
421
  "y-protocols": "^1.0.7",
422
422
  "yjs": "^13.6.31",
423
423
  "zod": "^4.3.6",
424
- "@agent-native/recap-cli": "0.5.4",
425
- "@agent-native/toolkit": "^0.14.1"
424
+ "@agent-native/toolkit": "^0.14.1",
425
+ "@agent-native/recap-cli": "0.5.4"
426
426
  },
427
427
  "devDependencies": {
428
428
  "@ai-sdk/anthropic": "^3.0.71",