@assistant-ui/mcp-docs-server 0.1.23 → 0.1.25

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 (137) hide show
  1. package/.docs/organized/code-examples/waterfall.md +5 -3
  2. package/.docs/organized/code-examples/with-a2a.md +676 -0
  3. package/.docs/organized/code-examples/with-ag-ui.md +7 -8
  4. package/.docs/organized/code-examples/with-ai-sdk-v6.md +28 -16
  5. package/.docs/organized/code-examples/with-artifacts.md +5 -5
  6. package/.docs/organized/code-examples/with-assistant-transport.md +3 -3
  7. package/.docs/organized/code-examples/with-chain-of-thought.md +34 -26
  8. package/.docs/organized/code-examples/with-cloud-standalone.md +10 -8
  9. package/.docs/organized/code-examples/with-cloud.md +5 -5
  10. package/.docs/organized/code-examples/with-custom-thread-list.md +7 -7
  11. package/.docs/organized/code-examples/with-elevenlabs-scribe.md +8 -8
  12. package/.docs/organized/code-examples/with-expo.md +571 -539
  13. package/.docs/organized/code-examples/with-external-store.md +3 -4
  14. package/.docs/organized/code-examples/with-ffmpeg.md +5 -5
  15. package/.docs/organized/code-examples/with-google-adk.md +353 -0
  16. package/.docs/organized/code-examples/with-heat-graph.md +304 -0
  17. package/.docs/organized/code-examples/with-langgraph.md +25 -23
  18. package/.docs/organized/code-examples/with-parent-id-grouping.md +4 -4
  19. package/.docs/organized/code-examples/with-react-hook-form.md +6 -9
  20. package/.docs/organized/code-examples/with-react-ink.md +265 -0
  21. package/.docs/organized/code-examples/with-react-router.md +10 -11
  22. package/.docs/organized/code-examples/with-store.md +29 -18
  23. package/.docs/organized/code-examples/with-tanstack.md +7 -7
  24. package/.docs/organized/code-examples/with-tap-runtime.md +6 -4
  25. package/.docs/raw/blog/2025-01-31-changelog/index.mdx +1 -1
  26. package/.docs/raw/blog/2026-03-launch-week/index.mdx +227 -0
  27. package/.docs/raw/docs/(docs)/architecture.mdx +1 -1
  28. package/.docs/raw/docs/(docs)/cli.mdx +14 -9
  29. package/.docs/raw/docs/(docs)/copilots/make-assistant-tool-ui.mdx +8 -3
  30. package/.docs/raw/docs/(docs)/copilots/make-assistant-tool.mdx +5 -1
  31. package/.docs/raw/docs/(docs)/copilots/{make-assistant-readable.mdx → make-assistant-visible.mdx} +14 -5
  32. package/.docs/raw/docs/(docs)/copilots/model-context.mdx +11 -11
  33. package/.docs/raw/docs/(docs)/copilots/motivation.mdx +2 -2
  34. package/.docs/raw/docs/(docs)/devtools.mdx +3 -2
  35. package/.docs/raw/docs/(docs)/guides/attachments.mdx +9 -11
  36. package/.docs/raw/docs/(docs)/guides/branching.mdx +11 -6
  37. package/.docs/raw/docs/(docs)/guides/chain-of-thought.mdx +18 -16
  38. package/.docs/raw/docs/(docs)/guides/context-api.mdx +81 -43
  39. package/.docs/raw/docs/(docs)/guides/dictation.mdx +5 -5
  40. package/.docs/raw/docs/(docs)/guides/editing.mdx +16 -7
  41. package/.docs/raw/docs/(docs)/guides/latex.mdx +3 -0
  42. package/.docs/raw/docs/(docs)/guides/message-timing.mdx +2 -1
  43. package/.docs/raw/docs/(docs)/guides/multi-agent.mdx +173 -0
  44. package/.docs/raw/docs/(docs)/guides/quoting.mdx +55 -206
  45. package/.docs/raw/docs/(docs)/guides/speech.mdx +1 -4
  46. package/.docs/raw/docs/(docs)/guides/suggestions.mdx +9 -15
  47. package/.docs/raw/docs/(docs)/guides/tool-ui.mdx +17 -7
  48. package/.docs/raw/docs/(docs)/guides/tools.mdx +24 -9
  49. package/.docs/raw/docs/(docs)/index.mdx +3 -3
  50. package/.docs/raw/docs/(docs)/installation.mdx +69 -46
  51. package/.docs/raw/docs/(reference)/api-reference/context-providers/text-message-part-provider.mdx +20 -6
  52. package/.docs/raw/docs/(reference)/api-reference/integrations/react-data-stream.mdx +24 -4
  53. package/.docs/raw/docs/(reference)/api-reference/integrations/react-hook-form.mdx +1 -1
  54. package/.docs/raw/docs/(reference)/api-reference/integrations/vercel-ai-sdk.mdx +20 -19
  55. package/.docs/raw/docs/(reference)/api-reference/overview.mdx +28 -53
  56. package/.docs/raw/docs/(reference)/api-reference/primitives/action-bar.mdx +4 -4
  57. package/.docs/raw/docs/(reference)/api-reference/primitives/assistant-modal.mdx +7 -1
  58. package/.docs/raw/docs/(reference)/api-reference/primitives/attachment.mdx +20 -14
  59. package/.docs/raw/docs/(reference)/api-reference/primitives/branch-picker.mdx +1 -1
  60. package/.docs/raw/docs/(reference)/api-reference/primitives/composer.mdx +99 -45
  61. package/.docs/raw/docs/(reference)/api-reference/primitives/message-part.mdx +52 -40
  62. package/.docs/raw/docs/(reference)/api-reference/primitives/message.mdx +343 -23
  63. package/.docs/raw/docs/(reference)/api-reference/primitives/suggestion.mdx +4 -6
  64. package/.docs/raw/docs/(reference)/api-reference/primitives/thread-list-item.mdx +4 -2
  65. package/.docs/raw/docs/(reference)/api-reference/primitives/thread-list.mdx +3 -5
  66. package/.docs/raw/docs/(reference)/api-reference/primitives/thread.mdx +169 -22
  67. package/.docs/raw/docs/(reference)/api-reference/runtimes/assistant-runtime.mdx +14 -4
  68. package/.docs/raw/docs/(reference)/api-reference/runtimes/attachment-runtime.mdx +15 -26
  69. package/.docs/raw/docs/(reference)/api-reference/runtimes/composer-runtime.mdx +39 -21
  70. package/.docs/raw/docs/(reference)/api-reference/runtimes/message-part-runtime.mdx +33 -9
  71. package/.docs/raw/docs/(reference)/api-reference/runtimes/message-runtime.mdx +48 -21
  72. package/.docs/raw/docs/(reference)/api-reference/runtimes/thread-list-item-runtime.mdx +36 -7
  73. package/.docs/raw/docs/(reference)/api-reference/runtimes/thread-list-runtime.mdx +30 -10
  74. package/.docs/raw/docs/(reference)/api-reference/runtimes/thread-runtime.mdx +12 -10
  75. package/.docs/raw/docs/(reference)/migrations/deprecation-policy.mdx +1 -1
  76. package/.docs/raw/docs/(reference)/migrations/react-langgraph-v0-7.mdx +9 -4
  77. package/.docs/raw/docs/(reference)/migrations/v0-11.mdx +7 -5
  78. package/.docs/raw/docs/(reference)/migrations/v0-12.mdx +9 -7
  79. package/.docs/raw/docs/(reference)/migrations/v0-14.mdx +159 -0
  80. package/.docs/raw/docs/(reference)/react-compatibility.mdx +5 -134
  81. package/.docs/raw/docs/cloud/ai-sdk-assistant-ui.mdx +89 -7
  82. package/.docs/raw/docs/cloud/ai-sdk.mdx +19 -5
  83. package/.docs/raw/docs/cloud/langgraph.mdx +13 -3
  84. package/.docs/raw/docs/ink/adapters.mdx +41 -0
  85. package/.docs/raw/docs/ink/custom-backend.mdx +203 -0
  86. package/.docs/raw/docs/ink/hooks.mdx +448 -0
  87. package/.docs/raw/docs/ink/index.mdx +239 -0
  88. package/.docs/raw/docs/ink/migration.mdx +140 -0
  89. package/.docs/raw/docs/ink/primitives.mdx +699 -0
  90. package/.docs/raw/docs/react-native/adapters.mdx +63 -87
  91. package/.docs/raw/docs/react-native/custom-backend.mdx +11 -14
  92. package/.docs/raw/docs/react-native/hooks.mdx +214 -232
  93. package/.docs/raw/docs/react-native/index.mdx +118 -159
  94. package/.docs/raw/docs/react-native/migration.mdx +144 -0
  95. package/.docs/raw/docs/react-native/primitives.mdx +431 -302
  96. package/.docs/raw/docs/runtimes/a2a/index.mdx +294 -0
  97. package/.docs/raw/docs/runtimes/ai-sdk/v4-legacy.mdx +9 -9
  98. package/.docs/raw/docs/runtimes/ai-sdk/v5-legacy.mdx +14 -3
  99. package/.docs/raw/docs/runtimes/ai-sdk/v6.mdx +53 -0
  100. package/.docs/raw/docs/runtimes/assistant-transport.mdx +59 -25
  101. package/.docs/raw/docs/runtimes/custom/custom-thread-list.mdx +13 -6
  102. package/.docs/raw/docs/runtimes/custom/external-store.mdx +138 -38
  103. package/.docs/raw/docs/runtimes/custom/local.mdx +184 -42
  104. package/.docs/raw/docs/runtimes/data-stream.mdx +92 -19
  105. package/.docs/raw/docs/runtimes/google-adk/index.mdx +624 -0
  106. package/.docs/raw/docs/runtimes/helicone.mdx +6 -6
  107. package/.docs/raw/docs/runtimes/langgraph/index.mdx +38 -27
  108. package/.docs/raw/docs/runtimes/langgraph/tutorial/introduction.mdx +1 -1
  109. package/.docs/raw/docs/runtimes/langgraph/tutorial/part-1.mdx +15 -20
  110. package/.docs/raw/docs/runtimes/langgraph/tutorial/part-2.mdx +7 -11
  111. package/.docs/raw/docs/runtimes/langgraph/tutorial/part-3.mdx +8 -11
  112. package/.docs/raw/docs/runtimes/langserve.mdx +6 -7
  113. package/.docs/raw/docs/runtimes/pick-a-runtime.mdx +18 -3
  114. package/.docs/raw/docs/ui/context-display.mdx +147 -0
  115. package/.docs/raw/docs/ui/file.mdx +5 -4
  116. package/.docs/raw/docs/ui/image.mdx +5 -4
  117. package/.docs/raw/docs/ui/markdown.mdx +3 -1
  118. package/.docs/raw/docs/ui/model-selector.mdx +8 -8
  119. package/.docs/raw/docs/ui/part-grouping.mdx +7 -10
  120. package/.docs/raw/docs/ui/quote.mdx +210 -0
  121. package/.docs/raw/docs/ui/reasoning.mdx +12 -11
  122. package/.docs/raw/docs/ui/sources.mdx +88 -17
  123. package/.docs/raw/docs/ui/streamdown.mdx +16 -7
  124. package/.docs/raw/docs/ui/thread-list.mdx +11 -13
  125. package/.docs/raw/docs/ui/thread.mdx +28 -33
  126. package/.docs/raw/docs/ui/tool-fallback.mdx +5 -6
  127. package/.docs/raw/docs/ui/tool-group.mdx +9 -8
  128. package/.docs/raw/docs/utilities/heat-graph.mdx +236 -0
  129. package/.docs/raw/docs/utilities/tw-shimmer.mdx +211 -0
  130. package/package.json +4 -4
  131. package/.docs/raw/docs/(reference)/legacy/styled/assistant-modal.mdx +0 -77
  132. package/.docs/raw/docs/(reference)/legacy/styled/decomposition.mdx +0 -635
  133. package/.docs/raw/docs/(reference)/legacy/styled/markdown.mdx +0 -77
  134. package/.docs/raw/docs/(reference)/legacy/styled/scrollbar.mdx +0 -72
  135. package/.docs/raw/docs/(reference)/legacy/styled/thread-width.mdx +0 -22
  136. package/.docs/raw/docs/(reference)/legacy/styled/thread.mdx +0 -77
  137. /package/.docs/raw/docs/cloud/{overview.mdx → index.mdx} +0 -0
@@ -167,7 +167,7 @@ graph TD
167
167
  } from "@assistant-ui/react";
168
168
  import { useState } from "react";
169
169
 
170
- const convertMessage = (message: ThreadMessageLike) => {
170
+ const convertMessage = (message: ThreadMessageLike, idx: number) => {
171
171
  return message;
172
172
  };
173
173
 
@@ -219,7 +219,7 @@ graph TD
219
219
  ### Use in Your App
220
220
 
221
221
  ```tsx title="app/page.tsx"
222
- import { Thread } from "@assistant-ui/react";
222
+ import { Thread } from "@/components/assistant-ui/thread";
223
223
  import { MyRuntimeProvider } from "./MyRuntimeProvider";
224
224
 
225
225
  export default function Page() {
@@ -265,13 +265,14 @@ For complex scenarios with performance optimization:
265
265
  import { useExternalMessageConverter } from "@assistant-ui/react";
266
266
 
267
267
  const convertedMessages = useExternalMessageConverter({
268
- messages,
269
- convertMessage: (message: MyMessage): ThreadMessageLike => ({
268
+ callback: (message: MyMessage): ThreadMessageLike => ({
270
269
  role: message.role,
271
270
  content: [{ type: "text", text: message.text }],
272
271
  id: message.id,
273
272
  createdAt: new Date(message.timestamp),
274
273
  }),
274
+ messages,
275
+ isRunning: false,
275
276
  joinStrategy: "concat-content", // Merge adjacent assistant messages
276
277
  });
277
278
 
@@ -387,9 +388,9 @@ const onNew = async (message: AppendMessage) => {
387
388
  Enable message editing by implementing the `onEdit` handler:
388
389
 
389
390
  <Callout type="info">
390
- You can also implement `onEdit(editedMessage)` and `onRemove(messageId)`
391
- callbacks to handle user-initiated edits or deletions in your external store.
392
- This enables features like "edit and re-run" on your backend.
391
+ You can implement `onEdit(editedMessage)` to handle user-initiated edits in
392
+ your external store. This enables features like "edit and re-run" on your
393
+ backend.
393
394
  </Callout>
394
395
 
395
396
  ```tsx
@@ -506,7 +507,7 @@ Enable file uploads with the attachment adapter:
506
507
  ```tsx
507
508
  const attachmentAdapter: AttachmentAdapter = {
508
509
  accept: "image/*,application/pdf,.txt,.md",
509
- async add(file) {
510
+ async add({ file }) {
510
511
  // Upload file to your server
511
512
  const formData = new FormData();
512
513
  formData.append("file", file);
@@ -516,13 +517,13 @@ const attachmentAdapter: AttachmentAdapter = {
516
517
  body: formData,
517
518
  });
518
519
 
519
- const { id, url } = await response.json();
520
+ const { id } = await response.json();
520
521
  return {
521
522
  id,
522
523
  type: "document",
523
524
  name: file.name,
524
525
  file,
525
- url,
526
+ status: { type: "requires-action", reason: "composer-send" },
526
527
  };
527
528
  },
528
529
  async remove(attachment) {
@@ -531,6 +532,14 @@ const attachmentAdapter: AttachmentAdapter = {
531
532
  method: "DELETE",
532
533
  });
533
534
  },
535
+ async send(attachment) {
536
+ // Convert pending attachment to complete attachment when message is sent
537
+ return {
538
+ ...attachment,
539
+ status: { type: "complete" },
540
+ content: [{ type: "text", text: `File: ${attachment.name}` }],
541
+ };
542
+ },
534
543
  };
535
544
 
536
545
  const runtime = useExternalStoreRuntime({
@@ -599,7 +608,7 @@ function ChatWithThreads() {
599
608
  const { currentThreadId, setCurrentThreadId, threads, setThreads } =
600
609
  useThreadContext();
601
610
  const [threadList, setThreadList] = useState<ExternalStoreThreadData[]>([
602
- { threadId: "default", status: "regular", title: "New Chat" },
611
+ { id: "default", status: "regular", title: "New Chat" },
603
612
  ]);
604
613
 
605
614
  // Get messages for current thread
@@ -615,7 +624,7 @@ function ChatWithThreads() {
615
624
  setThreadList((prev) => [
616
625
  ...prev,
617
626
  {
618
- threadId: newId,
627
+ id: newId,
619
628
  status: "regular",
620
629
  title: "New Chat",
621
630
  },
@@ -631,7 +640,7 @@ function ChatWithThreads() {
631
640
  onRename: (threadId, newTitle) => {
632
641
  setThreadList((prev) =>
633
642
  prev.map((t) =>
634
- t.threadId === threadId ? { ...t, title: newTitle } : t,
643
+ t.id === threadId ? { ...t, title: newTitle } : t,
635
644
  ),
636
645
  );
637
646
  },
@@ -639,13 +648,13 @@ function ChatWithThreads() {
639
648
  onArchive: (threadId) => {
640
649
  setThreadList((prev) =>
641
650
  prev.map((t) =>
642
- t.threadId === threadId ? { ...t, status: "archived" } : t,
651
+ t.id === threadId ? { ...t, status: "archived" } : t,
643
652
  ),
644
653
  );
645
654
  },
646
655
 
647
656
  onDelete: (threadId) => {
648
- setThreadList((prev) => prev.filter((t) => t.threadId !== threadId));
657
+ setThreadList((prev) => prev.filter((t) => t.id !== threadId));
649
658
  setThreads((prev) => {
650
659
  const next = new Map(prev);
651
660
  next.delete(threadId);
@@ -1074,18 +1083,18 @@ When `isRunning` becomes true, the runtime automatically shows an optimistic ass
1074
1083
  setIsRunning(true);
1075
1084
 
1076
1085
  // Runtime automatically:
1077
- // 1. Shows empty assistant message with "in_progress" status
1086
+ // 1. Shows empty assistant message with { type: "running" } status
1078
1087
  // 2. Displays typing indicator
1079
- // 3. Updates status to "complete" when isRunning becomes false
1088
+ // 3. Updates status to { type: "complete", reason: "unknown" } when isRunning becomes false
1080
1089
  ```
1081
1090
 
1082
1091
  ### Message Status Management
1083
1092
 
1084
1093
  Assistant messages get automatic status updates:
1085
1094
 
1086
- - `"in_progress"` - When `isRunning` is true
1087
- - `"complete"` - When `isRunning` becomes false
1088
- - `"cancelled"` - When cancelled via `onCancel`
1095
+ - `{ type: "running" }` - When `isRunning` is true
1096
+ - `{ type: "complete", reason: "unknown" }` - When `isRunning` becomes false
1097
+ - `{ type: "incomplete", reason: "cancelled" }` - When cancelled via `onCancel`
1089
1098
 
1090
1099
  ### Tool Result Matching
1091
1100
 
@@ -1129,7 +1138,7 @@ Use `getExternalStoreMessages` to access your original messages:
1129
1138
  import { getExternalStoreMessages } from "@assistant-ui/react";
1130
1139
 
1131
1140
  const MyComponent = () => {
1132
- const originalMessages = useMessage((m) => getExternalStoreMessages(m));
1141
+ const originalMessages = useAuiState((s) => getExternalStoreMessages(s.message));
1133
1142
  // originalMessages is MyMessage[] (your original type)
1134
1143
  };
1135
1144
  ```
@@ -1151,7 +1160,7 @@ const MyComponent = () => {
1151
1160
  ```tsx
1152
1161
  const ToolUI = makeAssistantToolUI({
1153
1162
  render: () => {
1154
- const originalMessages = useMessagePart((p) => getExternalStoreMessages(p));
1163
+ const originalMessages = useAuiState((s) => getExternalStoreMessages(s.part));
1155
1164
  // Access original message data for this message part
1156
1165
  },
1157
1166
  });
@@ -1421,7 +1430,7 @@ The main interface for connecting your state to assistant-ui.
1421
1430
  },
1422
1431
  {
1423
1432
  name: "setMessages",
1424
- type: "(messages: T[]) => void",
1433
+ type: "(messages: readonly T[]) => void",
1425
1434
  description: "Update messages (required for branch switching)",
1426
1435
  },
1427
1436
  {
@@ -1445,18 +1454,60 @@ The main interface for connecting your state to assistant-ui.
1445
1454
  type: "(options: AddToolResultOptions) => Promise<void> | void",
1446
1455
  description: "Handler for adding tool call results",
1447
1456
  },
1457
+ {
1458
+ name: "onResume",
1459
+ type: "(config: ResumeRunConfig) => Promise<void>",
1460
+ description:
1461
+ "Handler for resuming an interrupted run (e.g. after a page reload mid-generation)",
1462
+ },
1463
+ {
1464
+ name: "onResumeToolCall",
1465
+ type: "(options: { toolCallId: string; payload: unknown }) => void",
1466
+ description:
1467
+ "Handler for resuming a suspended tool call (used with human-in-the-loop tool execution)",
1468
+ },
1469
+ {
1470
+ name: "isLoading",
1471
+ type: "boolean",
1472
+ description:
1473
+ "Whether the adapter is in a loading state (e.g. initial data fetch). Displays a loading indicator instead of the composer",
1474
+ },
1475
+ {
1476
+ name: "messageRepository",
1477
+ type: "ExportedMessageRepository",
1478
+ description:
1479
+ "Pre-built message repository with branching history. Use instead of `messages` when you need to restore branch state",
1480
+ },
1481
+ {
1482
+ name: "state",
1483
+ type: "ReadonlyJSONValue",
1484
+ description:
1485
+ "Opaque serializable state passed to `onLoadExternalState` during thread import",
1486
+ },
1487
+ {
1488
+ name: "onImport",
1489
+ type: "(messages: readonly ThreadMessage[]) => void",
1490
+ description:
1491
+ "Called when the runtime imports messages into the external store (e.g. on thread switch)",
1492
+ },
1493
+ {
1494
+ name: "onExportExternalState",
1495
+ type: "() => any",
1496
+ description:
1497
+ "Called to retrieve external state when the runtime exports a thread snapshot",
1498
+ },
1499
+ {
1500
+ name: "onLoadExternalState",
1501
+ type: "(state: any) => void",
1502
+ description:
1503
+ "Called with previously exported external state when restoring a thread snapshot",
1504
+ },
1448
1505
  {
1449
1506
  name: "convertMessage",
1450
1507
  type: "(message: T, index: number) => ThreadMessageLike",
1451
1508
  description:
1452
1509
  "Convert your message format to assistant-ui format. Not needed if using ThreadMessage type",
1453
1510
  },
1454
- {
1455
- name: "joinStrategy",
1456
- type: '"concat-content" | "none"',
1457
- description: "How to join adjacent assistant messages when converting",
1458
- default: '"concat-content"',
1459
- },
1460
1511
  {
1461
1512
  name: "adapters",
1462
1513
  type: "object",
@@ -1475,6 +1526,11 @@ The main interface for connecting your state to assistant-ui.
1475
1526
  type: "SpeechSynthesisAdapter",
1476
1527
  description: "Enable text-to-speech",
1477
1528
  },
1529
+ {
1530
+ name: "dictation",
1531
+ type: "DictationAdapter",
1532
+ description: "Enable speech-to-text dictation",
1533
+ },
1478
1534
  {
1479
1535
  name: "feedback",
1480
1536
  type: "FeedbackAdapter",
@@ -1543,7 +1599,7 @@ A flexible message format that can be converted to assistant-ui's internal forma
1543
1599
  name: "status",
1544
1600
  type: "MessageStatus",
1545
1601
  description:
1546
- "Status of assistant messages (in_progress, complete, cancelled)",
1602
+ "Status of assistant messages ({ type: \"running\" }, { type: \"complete\" }, { type: \"incomplete\" })",
1547
1603
  },
1548
1604
  {
1549
1605
  name: "attachments",
@@ -1585,27 +1641,35 @@ Enable multi-thread support with custom thread management.
1585
1641
  {
1586
1642
  name: "threadId",
1587
1643
  type: "string",
1588
- description: "ID of the current active thread",
1644
+ description:
1645
+ "ID of the current active thread. **Deprecated** — this API is still under active development and might change without notice.",
1646
+ },
1647
+ {
1648
+ name: "isLoading",
1649
+ type: "boolean",
1650
+ description: "Whether the thread list is currently loading",
1589
1651
  },
1590
1652
  {
1591
1653
  name: "threads",
1592
- type: "readonly ExternalStoreThreadData[]",
1593
- description: "Array of regular threads with { threadId, title }",
1654
+ type: "readonly ExternalStoreThreadData<\"regular\">[]",
1655
+ description: "Array of active threads. Each entry is an `ExternalStoreThreadData` object.",
1594
1656
  },
1595
1657
  {
1596
1658
  name: "archivedThreads",
1597
- type: "readonly ExternalStoreThreadData[]",
1598
- description: "Array of archived threads",
1659
+ type: "readonly ExternalStoreThreadData<\"archived\">[]",
1660
+ description: "Array of archived threads. Each entry is an `ExternalStoreThreadData` object.",
1599
1661
  },
1600
1662
  {
1601
1663
  name: "onSwitchToNewThread",
1602
1664
  type: "() => Promise<void> | void",
1603
- description: "Handler for creating a new thread",
1665
+ description:
1666
+ "Handler for creating a new thread. **Deprecated** — this API is still under active development and might change without notice.",
1604
1667
  },
1605
1668
  {
1606
1669
  name: "onSwitchToThread",
1607
1670
  type: "(threadId: string) => Promise<void> | void",
1608
- description: "Handler for switching to an existing thread",
1671
+ description:
1672
+ "Handler for switching to an existing thread. **Deprecated** — this API is still under active development and might change without notice.",
1609
1673
  },
1610
1674
  {
1611
1675
  name: "onRename",
@@ -1635,6 +1699,43 @@ Enable multi-thread support with custom thread management.
1635
1699
  only manages the current conversation.
1636
1700
  </Callout>
1637
1701
 
1702
+ ### `ExternalStoreThreadData`
1703
+
1704
+ Represents a single thread entry in the thread list.
1705
+
1706
+ <ParametersTable
1707
+ type="ExternalStoreThreadData<TState>"
1708
+ parameters={[
1709
+ {
1710
+ name: "id",
1711
+ type: "string",
1712
+ description: "Unique local identifier for the thread",
1713
+ required: true,
1714
+ },
1715
+ {
1716
+ name: "status",
1717
+ type: '"regular" | "archived"',
1718
+ description: "Whether the thread is active or archived",
1719
+ required: true,
1720
+ },
1721
+ {
1722
+ name: "title",
1723
+ type: "string",
1724
+ description: "Display title for the thread",
1725
+ },
1726
+ {
1727
+ name: "remoteId",
1728
+ type: "string",
1729
+ description: "Remote/server-side identifier for the thread (used for persistence)",
1730
+ },
1731
+ {
1732
+ name: "externalId",
1733
+ type: "string",
1734
+ description: "External system identifier for the thread (e.g. from a third-party service)",
1735
+ },
1736
+ ]}
1737
+ />
1738
+
1638
1739
  ### Related Runtime APIs
1639
1740
 
1640
1741
  - [AssistantRuntime API](/docs/api-reference/runtimes/assistant-runtime) - Core runtime interface and methods
@@ -1643,7 +1744,6 @@ Enable multi-thread support with custom thread management.
1643
1744
 
1644
1745
  ## Related Resources
1645
1746
 
1646
- - [Runtime Layer Concepts](/docs/concepts/runtime-layer)
1647
1747
  - [Pick a Runtime Guide](/docs/runtimes/pick-a-runtime)
1648
1748
  - [`LocalRuntime` Documentation](/docs/runtimes/custom/local)
1649
1749
  - [Examples Repository](https://github.com/assistant-ui/assistant-ui/tree/main/examples/with-external-store)