@assistant-ui/mcp-docs-server 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (187) hide show
  1. package/.docs/organized/code-examples/waterfall.md +3 -3
  2. package/.docs/organized/code-examples/with-a2a.md +5 -4
  3. package/.docs/organized/code-examples/with-ag-ui.md +7 -6
  4. package/.docs/organized/code-examples/with-ai-sdk-v7.md +14 -13
  5. package/.docs/organized/code-examples/with-artifacts.md +12 -11
  6. package/.docs/organized/code-examples/with-assistant-transport.md +6 -5
  7. package/.docs/organized/code-examples/with-browser-extension.md +6 -6
  8. package/.docs/organized/code-examples/with-chain-of-thought.md +16 -14
  9. package/.docs/organized/code-examples/with-cloud-standalone.md +7 -7
  10. package/.docs/organized/code-examples/with-cloud.md +11 -10
  11. package/.docs/organized/code-examples/with-custom-thread-list.md +11 -10
  12. package/.docs/organized/code-examples/with-elevenlabs-conversational.md +14 -13
  13. package/.docs/organized/code-examples/with-elevenlabs-scribe.md +15 -14
  14. package/.docs/organized/code-examples/with-eve.md +6 -5
  15. package/.docs/organized/code-examples/with-expo.md +213 -36
  16. package/.docs/organized/code-examples/with-external-store.md +6 -5
  17. package/.docs/organized/code-examples/with-ffmpeg.md +11 -10
  18. package/.docs/organized/code-examples/with-generative-ui.md +263 -29
  19. package/.docs/organized/code-examples/with-google-adk.md +5 -4
  20. package/.docs/organized/code-examples/with-heat-graph.md +3 -3
  21. package/.docs/organized/code-examples/with-image-generation.md +8 -7
  22. package/.docs/organized/code-examples/with-interactables.md +11 -10
  23. package/.docs/organized/code-examples/with-langchain.md +10 -9
  24. package/.docs/organized/code-examples/with-langgraph.md +7 -6
  25. package/.docs/organized/code-examples/with-livekit.md +15 -14
  26. package/.docs/organized/code-examples/with-mcp.md +14 -12
  27. package/.docs/organized/code-examples/with-nuxt.md +511 -575
  28. package/.docs/organized/code-examples/with-opencode.md +4 -4
  29. package/.docs/organized/code-examples/with-openui.md +450 -0
  30. package/.docs/organized/code-examples/with-pi.md +6 -5
  31. package/.docs/organized/code-examples/with-react-hook-form.md +16 -13
  32. package/.docs/organized/code-examples/with-react-ink-web.md +65 -15
  33. package/.docs/organized/code-examples/with-react-ink.md +5 -4
  34. package/.docs/organized/code-examples/with-react-router.md +8 -7
  35. package/.docs/organized/code-examples/with-resumable-stream.md +13 -12
  36. package/.docs/organized/code-examples/with-store.md +3 -3
  37. package/.docs/organized/code-examples/with-svelte.md +415 -0
  38. package/.docs/organized/code-examples/with-sveltekit.md +1061 -0
  39. package/.docs/organized/code-examples/with-tanstack.md +10 -9
  40. package/.docs/organized/code-examples/with-tap-runtime.md +5 -4
  41. package/.docs/organized/code-examples/with-virtualized-thread.md +6 -5
  42. package/.docs/organized/code-examples/with-vue.md +2 -2
  43. package/.docs/raw/docs/{(docs) → (getting-started)}/cli.mdx +6 -1
  44. package/.docs/raw/docs/{(docs) → (getting-started)}/devtools.mdx +1 -1
  45. package/.docs/raw/docs/{(docs) → (getting-started)}/index.mdx +4 -2
  46. package/.docs/raw/docs/{(docs) → (getting-started)}/installation.mdx +26 -26
  47. package/.docs/raw/docs/(reference)/api-reference/adapters/suggestions.mdx +6 -0
  48. package/.docs/raw/docs/(reference)/api-reference/context-providers/assistant-runtime-provider.mdx +1 -1
  49. package/.docs/raw/docs/(reference)/api-reference/external-store/message-conversion.mdx +6 -1
  50. package/.docs/raw/docs/(reference)/api-reference/generative-ui/slack.mdx +5 -1
  51. package/.docs/raw/docs/(reference)/api-reference/generative-ui/teams.mdx +9 -2
  52. package/.docs/raw/docs/(reference)/api-reference/hooks/primitives.mdx +2 -2
  53. package/.docs/raw/docs/(reference)/api-reference/integrations/{react-ai-sdk.mdx → ai-sdk.mdx} +43 -18
  54. package/.docs/raw/docs/(reference)/api-reference/integrations/eve.mdx +61 -2
  55. package/.docs/raw/docs/(reference)/api-reference/integrations/index.mdx +3 -3
  56. package/.docs/raw/docs/(reference)/api-reference/overview.mdx +2 -2
  57. package/.docs/raw/docs/(reference)/api-reference/primitives/composer.mdx +20 -2
  58. package/.docs/raw/docs/(reference)/api-reference/tools/interactables.mdx +1 -1
  59. package/.docs/raw/docs/(reference)/api-reference/tools/status.mdx +1 -1
  60. package/.docs/raw/docs/(reference)/api-reference/transport/frame.mdx +1 -1
  61. package/.docs/raw/docs/(reference)/api-reference/utilities/miscellaneous.mdx +32 -1
  62. package/.docs/raw/docs/(reference)/api-reference/voice/session.mdx +1 -1
  63. package/.docs/raw/docs/cloud/ai-sdk-assistant-ui.mdx +10 -10
  64. package/.docs/raw/docs/cloud/ai-sdk.mdx +4 -2
  65. package/.docs/raw/docs/cloud/index.mdx +1 -1
  66. package/.docs/raw/docs/copilots/assistant-frame.mdx +19 -8
  67. package/.docs/raw/docs/guides/attachments.mdx +4 -4
  68. package/.docs/raw/docs/guides/branching.mdx +1 -1
  69. package/.docs/raw/docs/guides/chatgpt-subscription.mdx +1 -1
  70. package/.docs/raw/docs/guides/context-api.mdx +15 -17
  71. package/.docs/raw/docs/guides/dictation.mdx +2 -2
  72. package/.docs/raw/docs/guides/electron.mdx +1 -1
  73. package/.docs/raw/docs/guides/latex.mdx +1 -1
  74. package/.docs/raw/docs/guides/mentions.mdx +2 -0
  75. package/.docs/raw/docs/guides/message-timing.mdx +11 -5
  76. package/.docs/raw/docs/guides/quoting.mdx +1 -1
  77. package/.docs/raw/docs/guides/resumable-streams.mdx +3 -3
  78. package/.docs/raw/docs/guides/speech.mdx +1 -1
  79. package/.docs/raw/docs/guides/suggestions.mdx +8 -5
  80. package/.docs/raw/docs/guides/voice.mdx +1 -1
  81. package/.docs/raw/docs/ink/hooks.mdx +1 -1
  82. package/.docs/raw/docs/ink/index.mdx +3 -2
  83. package/.docs/raw/docs/ink/migration.mdx +1 -1
  84. package/.docs/raw/docs/ink/primitives.mdx +1 -1
  85. package/.docs/raw/docs/integrations/attachments/custom-adapter.mdx +3 -3
  86. package/.docs/raw/docs/integrations/frameworks/ai-sdk.mdx +3 -3
  87. package/.docs/raw/docs/integrations/frameworks/{cloudflare-agents/overview.mdx → cloudflare-agents.mdx} +4 -3
  88. package/.docs/raw/docs/integrations/frameworks/mastra/overview.mdx +1 -1
  89. package/.docs/raw/docs/integrations/frameworks/mastra/separate-server.mdx +1 -1
  90. package/.docs/raw/docs/integrations/index.mdx +2 -2
  91. package/.docs/raw/docs/integrations/persistence/custom-adapter.mdx +149 -131
  92. package/.docs/raw/docs/migrations/toolkit-tools.mdx +2 -2
  93. package/.docs/raw/docs/migrations/v0-15.mdx +34 -0
  94. package/.docs/raw/docs/primitives/action-bar.mdx +1 -1
  95. package/.docs/raw/docs/primitives/assistant-modal.mdx +1 -1
  96. package/.docs/raw/docs/primitives/attachment.mdx +1 -1
  97. package/.docs/raw/docs/primitives/branch-picker.mdx +1 -1
  98. package/.docs/raw/docs/primitives/chain-of-thought.mdx +3 -3
  99. package/.docs/raw/docs/primitives/composer.mdx +1 -1
  100. package/.docs/raw/docs/primitives/error.mdx +1 -1
  101. package/.docs/raw/docs/primitives/message.mdx +1 -1
  102. package/.docs/raw/docs/primitives/selection-toolbar.mdx +1 -1
  103. package/.docs/raw/docs/primitives/suggestion.mdx +4 -2
  104. package/.docs/raw/docs/primitives/thread-list.mdx +1 -1
  105. package/.docs/raw/docs/primitives/thread.mdx +2 -2
  106. package/.docs/raw/docs/react-native/adapters.mdx +1 -1
  107. package/.docs/raw/docs/react-native/index.mdx +2 -2
  108. package/.docs/raw/docs/react-native/migration.mdx +2 -2
  109. package/.docs/raw/docs/react-native/primitives.mdx +142 -5
  110. package/.docs/raw/docs/runtimes/ag-ui/runtime-options.mdx +48 -6
  111. package/.docs/raw/docs/runtimes/ai-sdk/overview.mdx +3 -3
  112. package/.docs/raw/docs/runtimes/ai-sdk/v4-legacy.mdx +4 -4
  113. package/.docs/raw/docs/runtimes/ai-sdk/v7.mdx +31 -16
  114. package/.docs/raw/docs/runtimes/claude-managed-agents.mdx +118 -0
  115. package/.docs/raw/docs/runtimes/concepts/adapters.mdx +3 -3
  116. package/.docs/raw/docs/runtimes/concepts/architecture.mdx +3 -3
  117. package/.docs/raw/docs/runtimes/concepts/stability.mdx +2 -1
  118. package/.docs/raw/docs/runtimes/concepts/threads.mdx +73 -33
  119. package/.docs/raw/docs/runtimes/custom/assistant-transport.mdx +1 -1
  120. package/.docs/raw/docs/runtimes/custom/external-store.mdx +6 -2
  121. package/.docs/raw/docs/runtimes/langchain.mdx +2 -2
  122. package/.docs/raw/docs/runtimes/langgraph/streaming.mdx +4 -0
  123. package/.docs/raw/docs/runtimes/opencode/quickstart.mdx +1 -1
  124. package/.docs/raw/docs/runtimes/pick-a-runtime.mdx +9 -2
  125. package/.docs/raw/docs/tools/backend.mdx +4 -4
  126. package/.docs/raw/docs/tools/defining-tools.mdx +21 -2
  127. package/.docs/raw/docs/tools/generative-ui-primitive.mdx +180 -0
  128. package/.docs/raw/docs/tools/generative-ui-slack.mdx +167 -0
  129. package/.docs/raw/docs/tools/generative-ui-teams.mdx +160 -0
  130. package/.docs/raw/docs/tools/generative-ui.mdx +224 -211
  131. package/.docs/raw/docs/tools/index.mdx +2 -1
  132. package/.docs/raw/docs/tools/interactables.mdx +8 -7
  133. package/.docs/raw/docs/tools/mcp-apps.mdx +18 -1
  134. package/.docs/raw/docs/tools/mcp.mdx +2 -2
  135. package/.docs/raw/docs/tools/openui.mdx +175 -0
  136. package/.docs/raw/docs/tools/tool-ui.mdx +18 -7
  137. package/.docs/raw/docs/tools/user-managed-mcp.mdx +7 -3
  138. package/.docs/raw/docs/ui/assistant-modal.mdx +3 -3
  139. package/.docs/raw/docs/ui/assistant-sidebar.mdx +1 -1
  140. package/.docs/raw/docs/ui/attachment.mdx +50 -3
  141. package/.docs/raw/docs/ui/composer-trigger-popover.mdx +36 -1
  142. package/.docs/raw/docs/ui/context-display.mdx +1 -1
  143. package/.docs/raw/docs/ui/directive-text.mdx +1 -1
  144. package/.docs/raw/docs/ui/file.mdx +2 -2
  145. package/.docs/raw/docs/ui/follow-up-suggestions.mdx +1 -1
  146. package/.docs/raw/docs/ui/image.mdx +2 -2
  147. package/.docs/raw/docs/ui/markdown.mdx +40 -1
  148. package/.docs/raw/docs/ui/mermaid.mdx +1 -1
  149. package/.docs/raw/docs/ui/message-timing.mdx +1 -1
  150. package/.docs/raw/docs/ui/model-selector.mdx +4 -4
  151. package/.docs/raw/docs/ui/part-grouping.mdx +1 -1
  152. package/.docs/raw/docs/ui/quote.mdx +3 -3
  153. package/.docs/raw/docs/ui/reasoning.mdx +31 -3
  154. package/.docs/raw/docs/ui/scrollbar.mdx +1 -1
  155. package/.docs/raw/docs/ui/sources.mdx +10 -1
  156. package/.docs/raw/docs/ui/streamdown.mdx +2 -2
  157. package/.docs/raw/docs/ui/syntax-highlighting.mdx +1 -1
  158. package/.docs/raw/docs/ui/thread-list.mdx +40 -1
  159. package/.docs/raw/docs/ui/thread.mdx +49 -2
  160. package/.docs/raw/docs/ui/tool-fallback.mdx +23 -9
  161. package/.docs/raw/docs/ui/tool-group.mdx +1 -1
  162. package/.docs/raw/docs/ui/voice.mdx +1 -1
  163. package/.docs/raw/docs/utilities/react-o11y.mdx +2 -2
  164. package/dist/xulux/catalog-client.d.ts.map +1 -1
  165. package/dist/xulux/catalog-client.js +51 -6
  166. package/dist/xulux/catalog-client.js.map +1 -1
  167. package/dist/xulux/types.d.ts +7 -7
  168. package/dist/xulux/types.d.ts.map +1 -1
  169. package/dist/xulux/types.js.map +1 -1
  170. package/package.json +5 -5
  171. package/src/tools/tests/docs.test.ts +10 -7
  172. package/src/tools/tests/path-traversal.test.ts +5 -2
  173. package/src/tools/tests/xulux-templates.test.ts +63 -0
  174. package/src/xulux/catalog-client.ts +68 -23
  175. package/src/xulux/types.ts +17 -13
  176. package/.docs/raw/docs/tools/interactables-legacy.mdx +0 -423
  177. package/.docs/raw/docs/ui/accordion.mdx +0 -266
  178. package/.docs/raw/docs/ui/badge.mdx +0 -150
  179. package/.docs/raw/docs/ui/diff-viewer.mdx +0 -280
  180. package/.docs/raw/docs/ui/dot-matrix.mdx +0 -133
  181. package/.docs/raw/docs/ui/number-roll.mdx +0 -154
  182. package/.docs/raw/docs/ui/select.mdx +0 -254
  183. package/.docs/raw/docs/ui/tabs.mdx +0 -271
  184. /package/.docs/raw/docs/{(docs) → (getting-started)}/architecture.mdx +0 -0
  185. /package/.docs/raw/docs/{(docs) → (getting-started)}/base-ui.mdx +0 -0
  186. /package/.docs/raw/docs/{(docs) → (getting-started)}/llm.mdx +0 -0
  187. /package/.docs/raw/docs/{(docs) → (getting-started)}/rtl.mdx +0 -0
@@ -4,7 +4,7 @@
4
4
 
5
5
  ```typescript
6
6
  import { openai } from "@ai-sdk/openai";
7
- import { frontendTools } from "@assistant-ui/react-ai-sdk";
7
+ import { frontendTools } from "@assistant-ui/ai-sdk";
8
8
  import { convertToModelMessages, streamText } from "ai";
9
9
 
10
10
  export const maxDuration = 30;
@@ -13,7 +13,7 @@ export async function POST(req: Request) {
13
13
  const { messages, system, tools } = await req.json();
14
14
 
15
15
  const result = streamText({
16
- model: openai("gpt-5.4-nano"),
16
+ model: openai("gpt-5.6-luna"),
17
17
  messages: await convertToModelMessages(messages),
18
18
  system,
19
19
  tools: {
@@ -190,7 +190,7 @@ export default function RootLayout({
190
190
 
191
191
  import { AssistantRuntimeProvider, generateId } from "@assistant-ui/react";
192
192
  import type { AttachmentAdapter } from "@assistant-ui/react";
193
- import { useChatRuntime } from "@assistant-ui/react-ai-sdk";
193
+ import { useChatRuntime } from "@assistant-ui/ai-sdk";
194
194
  import { lastAssistantMessageIsCompleteWithToolCalls } from "ai";
195
195
 
196
196
  const attachmentAdapter: AttachmentAdapter = {
@@ -720,18 +720,18 @@ export default withAui(nextConfig);
720
720
  "start": "next start"
721
721
  },
722
722
  "dependencies": {
723
- "@ai-sdk/openai": "^4.0.34",
723
+ "@ai-sdk/openai": "^4.0.46",
724
+ "@assistant-ui/ai-sdk": "workspace:*",
724
725
  "@assistant-ui/react": "workspace:*",
725
- "@assistant-ui/react-ai-sdk": "workspace:*",
726
726
  "@assistant-ui/react-markdown": "workspace:*",
727
727
  "@assistant-ui/ui": "workspace:*",
728
728
  "@ffmpeg/ffmpeg": "^0.12.15",
729
729
  "@ffmpeg/util": "^0.12.2",
730
- "ai": "^7.0.56",
730
+ "ai": "^7.0.77",
731
731
  "class-variance-authority": "^0.7.1",
732
732
  "clsx": "^2.1.1",
733
- "lucide-react": "^1.29.0",
734
- "next": "^16.3.0",
733
+ "lucide-react": "^1.33.0",
734
+ "next": "^16.3.2",
735
735
  "react": "^19.2.8",
736
736
  "react-dom": "^19.2.8",
737
737
  "tailwind-merge": "^3.6.0",
@@ -741,9 +741,9 @@ export default withAui(nextConfig);
741
741
  "@assistant-ui/next": "workspace:*",
742
742
  "@assistant-ui/x-buildutils": "workspace:*",
743
743
  "@tailwindcss/postcss": "^4.3.3",
744
- "@types/node": "^26.1.2",
744
+ "@types/node": "^26.2.0",
745
745
  "@types/react": "^19.2.18",
746
- "@types/react-dom": "^19.2.4",
746
+ "@types/react-dom": "^19.2.5",
747
747
  "postcss": "^8.5.26",
748
748
  "tailwindcss": "^4.3.3",
749
749
  "tw-animate-css": "^1.4.0",
@@ -809,6 +809,7 @@ npm run dev
809
809
  "@/components/assistant-ui/*": [
810
810
  "../../packages/ui/src/components/assistant-ui/*"
811
811
  ],
812
+ "@/hooks/*": ["../../packages/ui/src/hooks/*"],
812
813
  "@/components/ui/*": [
813
814
  "../../packages/ui/src/components/ui/base/*",
814
815
  "../../packages/ui/src/components/ui/radix/*"
@@ -16,7 +16,7 @@ import { z } from "zod";
16
16
  import {
17
17
  AISDKToolkit,
18
18
  type AISDKToolkitToolsOptions,
19
- } from "@assistant-ui/react-ai-sdk";
19
+ } from "@assistant-ui/ai-sdk";
20
20
  import {
21
21
  renderGuiToolDescription,
22
22
  renderGuiToolInputSchema,
@@ -45,7 +45,7 @@ export async function POST(req: Request) {
45
45
  });
46
46
 
47
47
  const result = streamText({
48
- model: openai("gpt-5.4-nano"),
48
+ model: openai("gpt-5.6-luna"),
49
49
  messages: await convertToModelMessages(messages),
50
50
  stopWhen: stepCountIs(10),
51
51
  ...(system ? { system } : {}),
@@ -112,6 +112,50 @@ export async function POST(req: Request) {
112
112
 
113
113
  ```
114
114
 
115
+ ## app/api/present/route.ts
116
+
117
+ ```typescript
118
+ import { openai } from "@ai-sdk/openai";
119
+ import { streamText, convertToModelMessages, stepCountIs } from "ai";
120
+ import type { UIMessage } from "ai";
121
+ import {
122
+ AISDKToolkit,
123
+ type AISDKToolkitToolsOptions,
124
+ } from "@assistant-ui/ai-sdk";
125
+ import presentToolkit from "../../present-toolkit";
126
+
127
+ export const maxDuration = 30;
128
+
129
+ const aiToolkit = new AISDKToolkit({ toolkit: presentToolkit });
130
+
131
+ type FrontendToolDefs = NonNullable<AISDKToolkitToolsOptions["frontend"]>;
132
+
133
+ export async function POST(req: Request) {
134
+ const {
135
+ messages,
136
+ system,
137
+ tools: clientTools,
138
+ }: {
139
+ messages: UIMessage[];
140
+ system?: string;
141
+ tools?: FrontendToolDefs;
142
+ } = await req.json();
143
+
144
+ const result = streamText({
145
+ model: openai("gpt-5.6-luna"),
146
+ messages: await convertToModelMessages(messages),
147
+ stopWhen: stepCountIs(10),
148
+ ...(system ? { system } : {}),
149
+ tools: await aiToolkit.tools({
150
+ ...(clientTools && { frontend: clientTools }),
151
+ }),
152
+ });
153
+
154
+ return result.toUIMessageStreamResponse();
155
+ }
156
+
157
+ ```
158
+
115
159
  ## app/globals.css
116
160
 
117
161
  ```css
@@ -257,7 +301,7 @@ import {
257
301
  Suggestions,
258
302
  useAssistantInstructions,
259
303
  } from "@assistant-ui/react";
260
- import { useChatRuntime } from "@assistant-ui/react-ai-sdk";
304
+ import { useChatRuntime } from "@assistant-ui/ai-sdk";
261
305
  import { lastAssistantMessageIsCompleteWithToolCalls } from "ai";
262
306
  import { renderGuiChatInstructions } from "@/lib/render-gui-tool";
263
307
 
@@ -325,12 +369,13 @@ export default function GuiChatPage() {
325
369
 
326
370
  ```tsx
327
371
  import type { Metadata } from "next";
372
+ import { GenerativeUIStyle } from "@/components/generative-ui-style";
328
373
  import "./globals.css";
329
374
 
330
375
  export const metadata: Metadata = {
331
376
  title: "assistant-ui Generative UI Example",
332
377
  description:
333
- "Example showcasing generative UI tool components: charts, date pickers, forms, and maps",
378
+ "Example showcasing model-composed interfaces with the present tool and a custom component vocabulary",
334
379
  };
335
380
 
336
381
  export default function RootLayout({
@@ -340,6 +385,9 @@ export default function RootLayout({
340
385
  }>) {
341
386
  return (
342
387
  <html lang="en">
388
+ <head>
389
+ <GenerativeUIStyle />
390
+ </head>
343
391
  <body className="h-dvh">{children}</body>
344
392
  </html>
345
393
  );
@@ -359,13 +407,14 @@ import {
359
407
  Suggestions,
360
408
  Tools,
361
409
  } from "@assistant-ui/react";
362
- import { useChatRuntime } from "@assistant-ui/react-ai-sdk";
410
+ import { AssistantChatTransport, useChatRuntime } from "@assistant-ui/ai-sdk";
363
411
  import { lastAssistantMessageIsCompleteWithToolCalls } from "ai";
364
412
  import { ExampleNav } from "@/components/example-nav";
365
- import toolkit from "./toolkit";
413
+ import toolkit from "./present-toolkit";
366
414
 
367
415
  export default function Home() {
368
416
  const runtime = useChatRuntime({
417
+ transport: new AssistantChatTransport({ api: "/api/present" }),
369
418
  sendAutomaticallyWhen: lastAssistantMessageIsCompleteWithToolCalls,
370
419
  });
371
420
 
@@ -373,26 +422,28 @@ export default function Home() {
373
422
  tools: Tools({ toolkit }),
374
423
  suggestions: Suggestions([
375
424
  {
376
- title: "Show a bar chart",
377
- label: "of quarterly revenue",
425
+ title: "Sales dashboard",
426
+ label: "for last quarter",
378
427
  prompt:
379
- "Create a bar chart showing quarterly revenue: Q1 $45k, Q2 $52k, Q3 $61k, Q4 $58k",
428
+ "Show me a Q2 2026 sales dashboard. Revenue was $412k in April, $488k in May and $551k in June, on 1,284 orders, at a 3.4% conversion rate.",
380
429
  },
381
430
  {
382
- title: "Pick a date",
383
- label: "for a meeting",
384
- prompt: "I need to schedule a meeting. Ask me to pick a date.",
431
+ title: "Product analytics",
432
+ label: "activation and retention",
433
+ prompt:
434
+ "How did we trend over the last six weeks? Activation went 41%, 44%, 43%, 48%, 52%, 55%, and week-4 retention went 22%, 24%, 23%, 27%, 29%, 31%.",
385
435
  },
386
436
  {
387
- title: "Collect my contact info",
388
- label: "name, email, phone",
437
+ title: "Support overview",
438
+ label: "tickets and response time",
389
439
  prompt:
390
- "I want to sign up for the newsletter. Ask for my name, email, and phone number.",
440
+ "Give me a support overview. Open tickets: 12 urgent, 38 high, 91 normal, 24 low. Median first response is 47 minutes, down from 62 last week.",
391
441
  },
392
442
  {
393
- title: "Show me on the map",
394
- label: "the Eiffel Tower",
395
- prompt: "Show me the Eiffel Tower on a map",
443
+ title: "Channel performance",
444
+ label: "compare acquisition sources",
445
+ prompt:
446
+ "Compare our acquisition channels. Search: $18k spend, 420 conversions. Social: $11k, 260. Email: $3k, 190. Referral: $6k, 150.",
396
447
  },
397
448
  ]),
398
449
  });
@@ -411,6 +462,60 @@ export default function Home() {
411
462
 
412
463
  ```
413
464
 
465
+ ## app/present-toolkit.tsx
466
+
467
+ ```tsx
468
+ "use generative";
469
+
470
+ import { defineToolkit } from "@assistant-ui/react";
471
+ import {
472
+ JSONGenerativeUI,
473
+ defaultGenerativeUILibrary,
474
+ defineGenerativeComponents,
475
+ } from "@assistant-ui/react-generative-ui";
476
+ import { styledGenerativeUILibrary } from "@/components/assistant-ui/generative-ui";
477
+ import { DashboardHeader } from "@/components/dashboard-header";
478
+ import { z } from "zod";
479
+
480
+ const markdown = defaultGenerativeUILibrary.Markdown!;
481
+
482
+ const generative = new JSONGenerativeUI({
483
+ library: {
484
+ ...defaultGenerativeUILibrary,
485
+ ...defineGenerativeComponents({
486
+ Markdown: {
487
+ properties: markdown.properties,
488
+ streamProperties: markdown.streamProperties,
489
+ description:
490
+ "A markdown string, rendered with GitHub-flavored markdown.",
491
+ render: styledGenerativeUILibrary.Markdown!.render,
492
+ },
493
+ DashboardHeader: {
494
+ description:
495
+ "A heading for a dashboard, with an optional description and reporting period.",
496
+ properties: z.object({
497
+ title: z.string().describe("The dashboard title."),
498
+ description: z
499
+ .string()
500
+ .optional()
501
+ .describe("A short description of the dashboard."),
502
+ period: z
503
+ .string()
504
+ .optional()
505
+ .describe("The reporting period shown beside the title."),
506
+ }),
507
+ render: (props) => <DashboardHeader {...props} />,
508
+ },
509
+ }),
510
+ },
511
+ });
512
+
513
+ export default defineToolkit({
514
+ present: generative.present({ display: "standalone" }),
515
+ });
516
+
517
+ ```
518
+
414
519
  ## app/primitive/page.tsx
415
520
 
416
521
  ```tsx
@@ -512,6 +617,70 @@ export default function GenerativeUIPrimitivePage() {
512
617
 
513
618
  ```
514
619
 
620
+ ## app/tool-ui/page.tsx
621
+
622
+ ```tsx
623
+ "use client";
624
+
625
+ import { Thread } from "@/components/assistant-ui/thread";
626
+ import {
627
+ AssistantRuntimeProvider,
628
+ AuiConfig,
629
+ Suggestions,
630
+ Tools,
631
+ } from "@assistant-ui/react";
632
+ import { useChatRuntime } from "@assistant-ui/ai-sdk";
633
+ import { lastAssistantMessageIsCompleteWithToolCalls } from "ai";
634
+ import { ExampleNav } from "@/components/example-nav";
635
+ import toolkit from "../toolkit";
636
+
637
+ export default function Home() {
638
+ const runtime = useChatRuntime({
639
+ sendAutomaticallyWhen: lastAssistantMessageIsCompleteWithToolCalls,
640
+ });
641
+
642
+ const config = AuiConfig({
643
+ tools: Tools({ toolkit }),
644
+ suggestions: Suggestions([
645
+ {
646
+ title: "Show a bar chart",
647
+ label: "of quarterly revenue",
648
+ prompt:
649
+ "Create a bar chart showing quarterly revenue: Q1 $45k, Q2 $52k, Q3 $61k, Q4 $58k",
650
+ },
651
+ {
652
+ title: "Pick a date",
653
+ label: "for a meeting",
654
+ prompt: "I need to schedule a meeting. Ask me to pick a date.",
655
+ },
656
+ {
657
+ title: "Collect my contact info",
658
+ label: "name, email, phone",
659
+ prompt:
660
+ "I want to sign up for the newsletter. Ask for my name, email, and phone number.",
661
+ },
662
+ {
663
+ title: "Show me on the map",
664
+ label: "the Eiffel Tower",
665
+ prompt: "Show me the Eiffel Tower on a map",
666
+ },
667
+ ]),
668
+ });
669
+
670
+ return (
671
+ <AssistantRuntimeProvider config={config} runtime={runtime}>
672
+ <div className="flex h-full flex-col">
673
+ <ExampleNav />
674
+ <main className="min-h-0 flex-1">
675
+ <Thread />
676
+ </main>
677
+ </div>
678
+ </AssistantRuntimeProvider>
679
+ );
680
+ }
681
+
682
+ ```
683
+
515
684
  ## app/toolkit.tsx
516
685
 
517
686
  ```tsx
@@ -1069,6 +1238,41 @@ export const ContactFormToolUI: ToolCallMessagePartComponent<
1069
1238
 
1070
1239
  ```
1071
1240
 
1241
+ ## components/dashboard-header.tsx
1242
+
1243
+ ```tsx
1244
+ "use client";
1245
+
1246
+ type DashboardHeaderProps = {
1247
+ title: string;
1248
+ description?: string;
1249
+ period?: string;
1250
+ };
1251
+
1252
+ export function DashboardHeader({
1253
+ title,
1254
+ description,
1255
+ period,
1256
+ }: DashboardHeaderProps) {
1257
+ return (
1258
+ <header className="flex flex-wrap items-start justify-between gap-3">
1259
+ <div className="min-w-0">
1260
+ <h2 className="text-lg font-semibold tracking-tight">{title}</h2>
1261
+ {description ? (
1262
+ <p className="text-muted-foreground mt-1 text-sm">{description}</p>
1263
+ ) : null}
1264
+ </div>
1265
+ {period ? (
1266
+ <span className="bg-muted text-muted-foreground rounded-full px-2.5 py-1 text-xs font-medium">
1267
+ {period}
1268
+ </span>
1269
+ ) : null}
1270
+ </header>
1271
+ );
1272
+ }
1273
+
1274
+ ```
1275
+
1072
1276
  ## components/date-picker-tool-ui.tsx
1073
1277
 
1074
1278
  ```tsx
@@ -1141,9 +1345,10 @@ export const DatePickerToolUI: ToolCallMessagePartComponent<
1141
1345
  import Link from "next/link";
1142
1346
 
1143
1347
  const links = [
1144
- { href: "/", label: "Tool UI demo" },
1145
- { href: "/primitive", label: "Static primitive" },
1146
- { href: "/gui-chat", label: "GUI chat" },
1348
+ { href: "/", label: "Generative UI" },
1349
+ { href: "/tool-ui", label: "Tool UI" },
1350
+ { href: "/primitive", label: "Static primitive (legacy)" },
1351
+ { href: "/gui-chat", label: "GUI chat (legacy)" },
1147
1352
  ] as const;
1148
1353
 
1149
1354
  export function ExampleNav() {
@@ -1165,6 +1370,33 @@ export function ExampleNav() {
1165
1370
 
1166
1371
  ```
1167
1372
 
1373
+ ## components/generative-ui-style.tsx
1374
+
1375
+ ```tsx
1376
+ import {
1377
+ generativeUiCssText,
1378
+ generativeUiThemeVars,
1379
+ } from "@assistant-ui/ui/lib/generative-ui-vocabulary-css";
1380
+
1381
+ function themeVarsBlock(selector: string, vars: Record<string, string>) {
1382
+ const body = Object.entries(vars)
1383
+ .map(([name, value]) => ` ${name}: ${value};`)
1384
+ .join("\n");
1385
+ return `${selector} {\n${body}\n}`;
1386
+ }
1387
+
1388
+ export function GenerativeUIStyle() {
1389
+ const css = [
1390
+ themeVarsBlock(":root", generativeUiThemeVars.light),
1391
+ themeVarsBlock(".dark", generativeUiThemeVars.dark),
1392
+ generativeUiCssText(),
1393
+ ].join("\n\n");
1394
+
1395
+ return <style>{css}</style>;
1396
+ }
1397
+
1398
+ ```
1399
+
1168
1400
  ## components/gui/index.tsx
1169
1401
 
1170
1402
  ```tsx
@@ -1500,15 +1732,16 @@ export default withAui(nextConfig);
1500
1732
  "test": "vitest run"
1501
1733
  },
1502
1734
  "dependencies": {
1503
- "@ai-sdk/openai": "^4.0.34",
1735
+ "@ai-sdk/openai": "^4.0.46",
1736
+ "@assistant-ui/ai-sdk": "workspace:*",
1504
1737
  "@assistant-ui/react": "workspace:*",
1505
- "@assistant-ui/react-ai-sdk": "workspace:*",
1738
+ "@assistant-ui/react-generative-ui": "workspace:*",
1506
1739
  "@assistant-ui/ui": "workspace:*",
1507
- "ai": "^7.0.56",
1740
+ "ai": "^7.0.77",
1508
1741
  "class-variance-authority": "^0.7.1",
1509
1742
  "clsx": "^2.1.1",
1510
- "lucide-react": "^1.29.0",
1511
- "next": "^16.3.0",
1743
+ "lucide-react": "^1.33.0",
1744
+ "next": "^16.3.2",
1512
1745
  "react": "^19.2.8",
1513
1746
  "react-dom": "^19.2.8",
1514
1747
  "recharts": "^3.10.1",
@@ -1519,14 +1752,14 @@ export default withAui(nextConfig);
1519
1752
  "@assistant-ui/next": "workspace:*",
1520
1753
  "@assistant-ui/x-buildutils": "workspace:*",
1521
1754
  "@tailwindcss/postcss": "^4.3.3",
1522
- "@types/node": "^26.1.2",
1755
+ "@types/node": "^26.2.0",
1523
1756
  "@types/react": "^19.2.18",
1524
- "@types/react-dom": "^19.2.4",
1757
+ "@types/react-dom": "^19.2.5",
1525
1758
  "postcss": "^8.5.26",
1526
1759
  "tailwindcss": "^4.3.3",
1527
1760
  "tw-animate-css": "^1.4.0",
1528
1761
  "typescript": "^7.0.2",
1529
- "vitest": "^4.1.10"
1762
+ "vitest": "^4.1.11"
1530
1763
  }
1531
1764
  }
1532
1765
 
@@ -1543,6 +1776,7 @@ export default withAui(nextConfig);
1543
1776
  "@/components/assistant-ui/*": [
1544
1777
  "../../packages/ui/src/components/assistant-ui/*"
1545
1778
  ],
1779
+ "@/hooks/*": ["../../packages/ui/src/hooks/*"],
1546
1780
  "@/components/ui/*": [
1547
1781
  "../../packages/ui/src/components/ui/base/*",
1548
1782
  "../../packages/ui/src/components/ui/radix/*"
@@ -314,8 +314,8 @@ export default withAui(nextConfig);
314
314
  "@google/adk": "^1.6.0",
315
315
  "class-variance-authority": "^0.7.1",
316
316
  "clsx": "^2.1.1",
317
- "lucide-react": "^1.29.0",
318
- "next": "^16.3.0",
317
+ "lucide-react": "^1.33.0",
318
+ "next": "^16.3.2",
319
319
  "react": "^19.2.8",
320
320
  "react-dom": "^19.2.8",
321
321
  "tailwind-merge": "^3.6.0",
@@ -325,9 +325,9 @@ export default withAui(nextConfig);
325
325
  "@assistant-ui/next": "workspace:*",
326
326
  "@assistant-ui/x-buildutils": "workspace:*",
327
327
  "@tailwindcss/postcss": "^4.3.3",
328
- "@types/node": "^26.1.2",
328
+ "@types/node": "^26.2.0",
329
329
  "@types/react": "^19.2.18",
330
- "@types/react-dom": "^19.2.4",
330
+ "@types/react-dom": "^19.2.5",
331
331
  "postcss": "^8.5.26",
332
332
  "tailwindcss": "^4.3.3",
333
333
  "tw-animate-css": "^1.4.0",
@@ -348,6 +348,7 @@ export default withAui(nextConfig);
348
348
  "@/components/assistant-ui/*": [
349
349
  "../../packages/ui/src/components/assistant-ui/*"
350
350
  ],
351
+ "@/hooks/*": ["../../packages/ui/src/hooks/*"],
351
352
  "@/components/ui/*": [
352
353
  "../../packages/ui/src/components/ui/base/*",
353
354
  "../../packages/ui/src/components/ui/radix/*"
@@ -269,7 +269,7 @@ export default withAui(nextConfig);
269
269
  },
270
270
  "dependencies": {
271
271
  "heat-graph": "workspace:*",
272
- "next": "^16.3.0",
272
+ "next": "^16.3.2",
273
273
  "react": "^19.2.8",
274
274
  "react-dom": "^19.2.8"
275
275
  },
@@ -277,9 +277,9 @@ export default withAui(nextConfig);
277
277
  "@assistant-ui/next": "workspace:*",
278
278
  "@assistant-ui/x-buildutils": "workspace:*",
279
279
  "@tailwindcss/postcss": "^4.3.3",
280
- "@types/node": "^26.1.2",
280
+ "@types/node": "^26.2.0",
281
281
  "@types/react": "^19.2.18",
282
- "@types/react-dom": "^19.2.4",
282
+ "@types/react-dom": "^19.2.5",
283
283
  "postcss": "^8.5.26",
284
284
  "tailwindcss": "^4.3.3",
285
285
  "typescript": "^7.0.2"
@@ -359,7 +359,7 @@ export default function Home() {
359
359
  import { withAui } from "@assistant-ui/next";
360
360
  /** @type {import('next').NextConfig} */
361
361
  const nextConfig = {
362
- transpilePackages: ["@assistant-ui/react", "@assistant-ui/react-ai-sdk"],
362
+ transpilePackages: ["@assistant-ui/react", "@assistant-ui/ai-sdk"],
363
363
  };
364
364
 
365
365
  export default withAui(nextConfig);
@@ -380,14 +380,14 @@ export default withAui(nextConfig);
380
380
  "start": "next start"
381
381
  },
382
382
  "dependencies": {
383
- "@ai-sdk/openai": "^4.0.34",
383
+ "@ai-sdk/openai": "^4.0.46",
384
384
  "@assistant-ui/react": "workspace:*",
385
385
  "@assistant-ui/ui": "workspace:*",
386
- "ai": "^7.0.56",
386
+ "ai": "^7.0.77",
387
387
  "class-variance-authority": "^0.7.1",
388
388
  "clsx": "^2.1.1",
389
- "lucide-react": "^1.29.0",
390
- "next": "^16.3.0",
389
+ "lucide-react": "^1.33.0",
390
+ "next": "^16.3.2",
391
391
  "react": "^19.2.8",
392
392
  "react-dom": "^19.2.8",
393
393
  "tailwind-merge": "^3.6.0"
@@ -396,9 +396,9 @@ export default withAui(nextConfig);
396
396
  "@assistant-ui/next": "workspace:*",
397
397
  "@assistant-ui/x-buildutils": "workspace:*",
398
398
  "@tailwindcss/postcss": "^4.3.3",
399
- "@types/node": "^26.1.2",
399
+ "@types/node": "^26.2.0",
400
400
  "@types/react": "^19.2.18",
401
- "@types/react-dom": "^19.2.4",
401
+ "@types/react-dom": "^19.2.5",
402
402
  "postcss": "^8.5.26",
403
403
  "tailwindcss": "^4.3.3",
404
404
  "tw-animate-css": "^1.4.0",
@@ -443,6 +443,7 @@ Then open `http://localhost:3000`.
443
443
  "@/components/assistant-ui/*": [
444
444
  "../../packages/ui/src/components/assistant-ui/*"
445
445
  ],
446
+ "@/hooks/*": ["../../packages/ui/src/hooks/*"],
446
447
  "@/components/ui/*": [
447
448
  "../../packages/ui/src/components/ui/base/*",
448
449
  "../../packages/ui/src/components/ui/radix/*"
@@ -10,7 +10,7 @@ import {
10
10
  frontendTools,
11
11
  type FrontendTools,
12
12
  unstable_injectInteractableContext,
13
- } from "@assistant-ui/react-ai-sdk";
13
+ } from "@assistant-ui/ai-sdk";
14
14
 
15
15
  export const maxDuration = 30;
16
16
 
@@ -30,7 +30,7 @@ export async function POST(req: Request) {
30
30
  );
31
31
 
32
32
  const result = streamText({
33
- model: openai("gpt-5.4-nano"),
33
+ model: openai("gpt-5.6-luna"),
34
34
  messages: modelMessages,
35
35
  stopWhen: stepCountIs(10),
36
36
  ...(system ? { system } : {}),
@@ -212,7 +212,7 @@ import {
212
212
  useAui,
213
213
  unstable_useInteractable,
214
214
  } from "@assistant-ui/react";
215
- import { useChatRuntime } from "@assistant-ui/react-ai-sdk";
215
+ import { useChatRuntime } from "@assistant-ui/ai-sdk";
216
216
  import { lastAssistantMessageIsCompleteWithToolCalls } from "ai";
217
217
  import {
218
218
  CheckCircle2Icon,
@@ -626,15 +626,15 @@ export default nextConfig;
626
626
  "start": "next start"
627
627
  },
628
628
  "dependencies": {
629
- "@ai-sdk/openai": "^4.0.34",
629
+ "@ai-sdk/openai": "^4.0.46",
630
+ "@assistant-ui/ai-sdk": "workspace:*",
630
631
  "@assistant-ui/react": "workspace:*",
631
- "@assistant-ui/react-ai-sdk": "workspace:*",
632
632
  "@assistant-ui/ui": "workspace:*",
633
- "ai": "^7.0.56",
633
+ "ai": "^7.0.77",
634
634
  "class-variance-authority": "^0.7.1",
635
635
  "clsx": "^2.1.1",
636
- "lucide-react": "^1.29.0",
637
- "next": "^16.3.0",
636
+ "lucide-react": "^1.33.0",
637
+ "next": "^16.3.2",
638
638
  "react": "^19.2.8",
639
639
  "react-dom": "^19.2.8",
640
640
  "tailwind-merge": "^3.6.0",
@@ -643,9 +643,9 @@ export default nextConfig;
643
643
  "devDependencies": {
644
644
  "@assistant-ui/x-buildutils": "workspace:*",
645
645
  "@tailwindcss/postcss": "^4.3.3",
646
- "@types/node": "^26.1.2",
646
+ "@types/node": "^26.2.0",
647
647
  "@types/react": "^19.2.18",
648
- "@types/react-dom": "^19.2.4",
648
+ "@types/react-dom": "^19.2.5",
649
649
  "postcss": "^8.5.26",
650
650
  "tailwindcss": "^4.3.3",
651
651
  "tw-animate-css": "^1.4.0",
@@ -713,6 +713,7 @@ Open [http://localhost:3000](http://localhost:3000) to see the example.
713
713
  "@/components/assistant-ui/*": [
714
714
  "../../packages/ui/src/components/assistant-ui/*"
715
715
  ],
716
+ "@/hooks/*": ["../../packages/ui/src/hooks/*"],
716
717
  "@/components/ui/*": [
717
718
  "../../packages/ui/src/components/ui/base/*",
718
719
  "../../packages/ui/src/components/ui/radix/*"