@assistant-ui/mcp-docs-server 0.1.32 → 0.1.34

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 (134) hide show
  1. package/.docs/organized/code-examples/waterfall.md +20 -22
  2. package/.docs/organized/code-examples/with-a2a.md +24 -24
  3. package/.docs/organized/code-examples/with-ag-ui.md +30 -25
  4. package/.docs/organized/code-examples/with-ai-sdk-v6.md +11 -9
  5. package/.docs/organized/code-examples/with-artifacts.md +49 -37
  6. package/.docs/organized/code-examples/with-assistant-transport.md +63 -51
  7. package/.docs/organized/code-examples/with-browser-extension.md +22 -10
  8. package/.docs/organized/code-examples/with-chain-of-thought.md +406 -87
  9. package/.docs/organized/code-examples/with-cloud-standalone.md +25 -24
  10. package/.docs/organized/code-examples/with-cloud.md +11 -9
  11. package/.docs/organized/code-examples/with-custom-thread-list.md +14 -12
  12. package/.docs/organized/code-examples/with-elevenlabs-conversational.md +23 -21
  13. package/.docs/organized/code-examples/with-elevenlabs-scribe.md +14 -13
  14. package/.docs/organized/code-examples/with-expo.md +44 -29
  15. package/.docs/organized/code-examples/with-external-store.md +9 -7
  16. package/.docs/organized/code-examples/with-ffmpeg.md +322 -285
  17. package/.docs/organized/code-examples/with-generative-ui.md +1066 -256
  18. package/.docs/organized/code-examples/with-google-adk.md +10 -8
  19. package/.docs/organized/code-examples/with-heat-graph.md +13 -11
  20. package/.docs/organized/code-examples/with-image-generation.md +19 -17
  21. package/.docs/organized/code-examples/with-interactables.md +317 -239
  22. package/.docs/organized/code-examples/with-langchain.md +14 -12
  23. package/.docs/organized/code-examples/with-langgraph.md +91 -83
  24. package/.docs/organized/code-examples/with-livekit.md +24 -22
  25. package/.docs/organized/code-examples/with-mcp.md +18 -12
  26. package/.docs/organized/code-examples/with-opencode.md +66 -66
  27. package/.docs/organized/code-examples/with-react-hook-form.md +19 -17
  28. package/.docs/organized/code-examples/with-react-ink.md +297 -102
  29. package/.docs/organized/code-examples/with-react-router.md +17 -15
  30. package/.docs/organized/code-examples/with-resumable-stream.md +15 -14
  31. package/.docs/organized/code-examples/with-store.md +78 -76
  32. package/.docs/organized/code-examples/with-tanstack.md +13 -14
  33. package/.docs/organized/code-examples/with-tap-runtime.md +26 -24
  34. package/.docs/raw/docs/(docs)/architecture.mdx +94 -42
  35. package/.docs/raw/docs/(docs)/cli.mdx +1 -2
  36. package/.docs/raw/docs/(docs)/installation.mdx +1 -1
  37. package/.docs/raw/docs/(reference)/api-reference/adapters/persistence.mdx +5 -1
  38. package/.docs/raw/docs/(reference)/api-reference/external-store/message-conversion.mdx +15 -15
  39. package/.docs/raw/docs/(reference)/api-reference/external-store/runtime.mdx +14 -1
  40. package/.docs/raw/docs/(reference)/api-reference/generative-ui/index.mdx +18 -0
  41. package/.docs/raw/docs/(reference)/api-reference/generative-ui/rendering.mdx +33 -0
  42. package/.docs/raw/docs/(reference)/api-reference/generative-ui/spec.mdx +45 -0
  43. package/.docs/raw/docs/(reference)/api-reference/hooks/composer-triggers.mdx +41 -41
  44. package/.docs/raw/docs/(reference)/api-reference/hooks/model-context.mdx +19 -1
  45. package/.docs/raw/docs/(reference)/api-reference/hooks/primitives.mdx +122 -122
  46. package/.docs/raw/docs/(reference)/api-reference/integrations/react-ai-sdk.mdx +43 -2
  47. package/.docs/raw/docs/(reference)/api-reference/model-context/context.mdx +6 -0
  48. package/.docs/raw/docs/(reference)/api-reference/overview.mdx +4 -6
  49. package/.docs/raw/docs/(reference)/api-reference/primitives/message.mdx +30 -0
  50. package/.docs/raw/docs/(reference)/api-reference/tools/component-tools.mdx +20 -3
  51. package/.docs/raw/docs/(reference)/api-reference/tools/index.mdx +8 -8
  52. package/.docs/raw/docs/(reference)/api-reference/tools/rendering.mdx +52 -4
  53. package/.docs/raw/docs/(reference)/api-reference/tools/toolkits.mdx +100 -10
  54. package/.docs/raw/docs/(reference)/api-reference/utilities/miscellaneous.mdx +7 -59
  55. package/.docs/raw/docs/cloud/ai-sdk.mdx +0 -2
  56. package/.docs/raw/docs/{(docs)/copilots → copilots}/model-context.mdx +34 -26
  57. package/.docs/raw/docs/{(docs)/copilots → copilots}/motivation.mdx +32 -26
  58. package/.docs/raw/docs/guides/chain-of-thought.mdx +7 -9
  59. package/.docs/raw/docs/guides/context-api.mdx +2 -1
  60. package/.docs/raw/docs/guides/index.mdx +3 -12
  61. package/.docs/raw/docs/guides/mentions.mdx +4 -4
  62. package/.docs/raw/docs/guides/slash-commands.mdx +1 -1
  63. package/.docs/raw/docs/guides/suggestions.mdx +1 -1
  64. package/.docs/raw/docs/ink/adapters.mdx +23 -1
  65. package/.docs/raw/docs/ink/hooks.mdx +101 -85
  66. package/.docs/raw/docs/ink/migration.mdx +1 -1
  67. package/.docs/raw/docs/ink/primitives.mdx +2 -2
  68. package/.docs/raw/docs/integrations/frameworks/ai-sdk.mdx +1 -1
  69. package/.docs/raw/docs/integrations/index.mdx +2 -2
  70. package/.docs/raw/docs/integrations/persistence/custom-adapter.mdx +17 -2
  71. package/.docs/raw/docs/migrations/toolkit-tools.mdx +232 -0
  72. package/.docs/raw/docs/primitives/chain-of-thought.mdx +10 -16
  73. package/.docs/raw/docs/primitives/message.mdx +9 -10
  74. package/.docs/raw/docs/react-native/hooks.mdx +62 -79
  75. package/.docs/raw/docs/react-native/migration.mdx +1 -1
  76. package/.docs/raw/docs/react-native/primitives.mdx +2 -2
  77. package/.docs/raw/docs/runtimes/a2a/client-and-hooks.mdx +3 -0
  78. package/.docs/raw/docs/runtimes/ag-ui/runtime-options.mdx +41 -0
  79. package/.docs/raw/docs/runtimes/ai-sdk/v6.mdx +122 -1
  80. package/.docs/raw/docs/runtimes/concepts/architecture.mdx +46 -4
  81. package/.docs/raw/docs/runtimes/concepts/threads.mdx +7 -1
  82. package/.docs/raw/docs/runtimes/custom/assistant-transport.mdx +54 -12
  83. package/.docs/raw/docs/runtimes/custom/external-store.mdx +62 -4
  84. package/.docs/raw/docs/runtimes/custom/local-runtime.mdx +30 -7
  85. package/.docs/raw/docs/runtimes/google-adk/hooks.mdx +108 -38
  86. package/.docs/raw/docs/runtimes/langgraph/generative-ui.mdx +2 -2
  87. package/.docs/raw/docs/runtimes/langgraph/streaming.mdx +14 -1
  88. package/.docs/raw/docs/runtimes/langgraph/tutorial/part-2.mdx +64 -50
  89. package/.docs/raw/docs/runtimes/langgraph/tutorial/part-3.mdx +98 -86
  90. package/.docs/raw/docs/tools/backend.mdx +144 -0
  91. package/.docs/raw/docs/tools/defining-tools.mdx +538 -0
  92. package/.docs/raw/docs/tools/dynamic-tools.mdx +110 -0
  93. package/.docs/raw/docs/tools/generative-ui.mdx +214 -0
  94. package/.docs/raw/docs/tools/index.mdx +71 -0
  95. package/.docs/raw/docs/{guides → tools}/interactables.mdx +1 -1
  96. package/.docs/raw/docs/{integrations/tools → tools}/mcp.mdx +145 -50
  97. package/.docs/raw/docs/{guides → tools}/multi-agent.mdx +15 -17
  98. package/.docs/raw/docs/tools/tool-ui.mdx +967 -0
  99. package/.docs/raw/docs/{integrations/tools/react-mcp.mdx → tools/user-managed-mcp.mdx} +7 -7
  100. package/.docs/raw/docs/ui/directive-text.mdx +3 -3
  101. package/.docs/raw/docs/ui/mcp-config.mdx +4 -4
  102. package/.docs/raw/docs/ui/mermaid.mdx +16 -9
  103. package/.docs/raw/docs/ui/part-grouping.mdx +84 -50
  104. package/.docs/raw/docs/ui/reasoning.mdx +4 -5
  105. package/.docs/raw/docs/ui/tool-fallback.mdx +16 -0
  106. package/.docs/raw/docs/ui/tool-group.mdx +5 -6
  107. package/.docs/raw/docs/utilities/heat-graph.mdx +1 -1
  108. package/.docs/raw/docs/utilities/react-o11y.mdx +2 -2
  109. package/dist/constants.js.map +1 -1
  110. package/dist/index.d.ts.map +1 -1
  111. package/dist/index.js.map +1 -1
  112. package/dist/prepare-docs/code-examples.d.ts.map +1 -1
  113. package/dist/prepare-docs/code-examples.js.map +1 -1
  114. package/dist/prepare-docs/copy-raw.d.ts.map +1 -1
  115. package/dist/prepare-docs/copy-raw.js.map +1 -1
  116. package/dist/prepare-docs/prepare.js.map +1 -1
  117. package/dist/stdio.js.map +1 -1
  118. package/dist/tools/docs.js.map +1 -1
  119. package/dist/tools/examples.js.map +1 -1
  120. package/dist/tools/tests/test-setup.js.map +1 -1
  121. package/dist/utils/mdx.js.map +1 -1
  122. package/dist/utils/paths.d.ts.map +1 -1
  123. package/dist/utils/paths.js.map +1 -1
  124. package/package.json +5 -5
  125. package/.docs/organized/code-examples/with-parent-id-grouping.md +0 -596
  126. package/.docs/raw/docs/(docs)/copilots/make-assistant-tool-ui.mdx +0 -151
  127. package/.docs/raw/docs/(docs)/copilots/make-assistant-tool.mdx +0 -230
  128. package/.docs/raw/docs/guides/generative-ui.mdx +0 -142
  129. package/.docs/raw/docs/guides/tool-ui.mdx +0 -858
  130. package/.docs/raw/docs/guides/tools.mdx +0 -736
  131. /package/.docs/raw/docs/{(docs)/copilots → copilots}/assistant-frame.mdx +0 -0
  132. /package/.docs/raw/docs/{(docs)/copilots → copilots}/make-assistant-visible.mdx +0 -0
  133. /package/.docs/raw/docs/{(docs)/copilots → copilots}/use-assistant-instructions.mdx +0 -0
  134. /package/.docs/raw/docs/{guides → tools}/mcp-apps.mdx +0 -0
@@ -98,7 +98,7 @@ import {
98
98
  } from "@assistant-ui/react-native";
99
99
  import { useAppRuntime } from "@/hooks/use-app-runtime";
100
100
  import { ThreadListDrawer } from "@/components/thread-list/ThreadListDrawer";
101
- import { expoToolkit } from "@/components/assistant-ui/tools";
101
+ import toolkit from "@/components/assistant-ui/tools";
102
102
 
103
103
  function NewChatButton() {
104
104
  const aui = useAui();
@@ -146,7 +146,7 @@ export default function RootLayout() {
146
146
  const [fontsLoaded] = useFonts(Ionicons.font);
147
147
  const runtime = useAppRuntime();
148
148
  const aui = useAui({
149
- tools: Tools({ toolkit: expoToolkit }),
149
+ tools: Tools({ toolkit }),
150
150
  });
151
151
 
152
152
  if (!fontsLoaded) return null;
@@ -219,6 +219,7 @@ import {
219
219
  Platform,
220
220
  StyleSheet,
221
221
  useColorScheme,
222
+ type TextStyle,
222
223
  } from "react-native";
223
224
  import { Ionicons } from "@expo/vector-icons";
224
225
  import * as ImagePicker from "expo-image-picker";
@@ -402,11 +403,11 @@ const styles = StyleSheet.create({
402
403
  maxHeight: 120,
403
404
  alignSelf: "center",
404
405
  paddingVertical: 0,
405
- ...Platform.select({
406
+ ...(Platform.select({
406
407
  web: { paddingHorizontal: 4, outlineStyle: "none" },
407
408
  default: {},
408
- }),
409
- },
409
+ }) as object),
410
+ } as TextStyle,
410
411
  button: {
411
412
  width: 30,
412
413
  height: 30,
@@ -418,6 +419,7 @@ const styles = StyleSheet.create({
418
419
  stopButton: {
419
420
  backgroundColor: "#ff453a",
420
421
  },
422
+ sendButton: {},
421
423
  stopIcon: {
422
424
  width: 12,
423
425
  height: 12,
@@ -921,10 +923,12 @@ const styles = StyleSheet.create({
921
923
  ## components/assistant-ui/tools.tsx
922
924
 
923
925
  ```tsx
926
+ "use generative";
927
+
924
928
  import { View, Text, StyleSheet, useColorScheme } from "react-native";
925
- import type {
926
- Toolkit,
927
- ToolCallMessagePartProps,
929
+ import {
930
+ defineToolkit,
931
+ type ToolCallMessagePartProps,
928
932
  } from "@assistant-ui/react-native";
929
933
  import { z } from "zod";
930
934
 
@@ -1255,14 +1259,16 @@ function WeatherToolUI(
1255
1259
 
1256
1260
  // Toolkit definition
1257
1261
 
1258
- export const expoToolkit: Toolkit = {
1262
+ export default defineToolkit({
1259
1263
  geocode_location: {
1260
1264
  description: "Geocode a location using Open-Meteo's geocoding API",
1261
1265
  parameters: z.object({
1262
1266
  query: z.string(),
1263
1267
  }),
1264
- execute: async (args: { query: string }) =>
1265
- geocodeLocationWithOpenMeteo(args.query),
1268
+ execute: async (args: { query: string }) => {
1269
+ "use client";
1270
+ return geocodeLocationWithOpenMeteo(args.query);
1271
+ },
1266
1272
  render: GeocodeToolUI,
1267
1273
  },
1268
1274
  weather_search: {
@@ -1277,10 +1283,13 @@ export const expoToolkit: Toolkit = {
1277
1283
  query: string;
1278
1284
  longitude: number;
1279
1285
  latitude: number;
1280
- }) => fetchWeatherFromOpenMeteo(args),
1286
+ }) => {
1287
+ "use client";
1288
+ return fetchWeatherFromOpenMeteo(args);
1289
+ },
1281
1290
  render: WeatherToolUI,
1282
1291
  },
1283
- };
1292
+ });
1284
1293
 
1285
1294
  const styles = StyleSheet.create({
1286
1295
  card: {
@@ -1466,7 +1475,7 @@ import { FlatList, View, StyleSheet, useColorScheme } from "react-native";
1466
1475
  import { useSafeAreaInsets } from "react-native-safe-area-context";
1467
1476
  import { useAui, useAuiState } from "@assistant-ui/react-native";
1468
1477
  import { ThreadListItem } from "./ThreadListItem";
1469
- import type { DrawerContentComponentProps } from "@react-navigation/drawer";
1478
+ import type { DrawerContentComponentProps } from "expo-router/build/react-navigation/drawer/types";
1470
1479
 
1471
1480
  export function ThreadListDrawer({ navigation }: DrawerContentComponentProps) {
1472
1481
  const aui = useAui();
@@ -1684,12 +1693,12 @@ export function IconSymbol({
1684
1693
  // Fallback for using MaterialIcons on Android and web.
1685
1694
 
1686
1695
  import MaterialIcons from "@expo/vector-icons/MaterialIcons";
1687
- import type { SymbolWeight, SymbolViewProps } from "expo-symbols";
1696
+ import type { SymbolWeight, SFSymbol } from "expo-symbols";
1688
1697
  import type { ComponentProps } from "react";
1689
1698
  import type { OpaqueColorValue, StyleProp, TextStyle } from "react-native";
1690
1699
 
1691
1700
  type IconMapping = Record<
1692
- SymbolViewProps["name"],
1701
+ SFSymbol,
1693
1702
  ComponentProps<typeof MaterialIcons>["name"]
1694
1703
  >;
1695
1704
  type IconSymbolName = keyof typeof MAPPING;
@@ -1869,7 +1878,8 @@ export function useThemeColor(
1869
1878
  props: { light?: string; dark?: string },
1870
1879
  colorName: keyof typeof Colors.light & keyof typeof Colors.dark,
1871
1880
  ) {
1872
- const theme = useColorScheme() ?? "light";
1881
+ const scheme = useColorScheme();
1882
+ const theme: "light" | "dark" = scheme === "dark" ? "dark" : "light";
1873
1883
  const colorFromProps = props[theme];
1874
1884
 
1875
1885
  if (colorFromProps) {
@@ -1885,6 +1895,7 @@ export function useThemeColor(
1885
1895
 
1886
1896
  ```javascript
1887
1897
  const { getDefaultConfig } = require("expo/metro-config");
1898
+ const { withAui } = require("@assistant-ui/metro");
1888
1899
  const path = require("node:path");
1889
1900
 
1890
1901
  const projectRoot = __dirname;
@@ -1925,7 +1936,7 @@ config.resolver.resolveRequest = (context, moduleName, platform) => {
1925
1936
  return context.resolveRequest(context, moduleName, platform);
1926
1937
  };
1927
1938
 
1928
- module.exports = config;
1939
+ module.exports = withAui(config);
1929
1940
 
1930
1941
  ```
1931
1942
 
@@ -1944,23 +1955,24 @@ module.exports = config;
1944
1955
  "export:web": "expo export --platform web && node scripts/flatten-assets.mjs"
1945
1956
  },
1946
1957
  "dependencies": {
1947
- "@ai-sdk/openai": "^3.0.64",
1948
- "@ai-sdk/react": "^3.0.190",
1958
+ "@ai-sdk/openai": "^3.0.68",
1959
+ "@ai-sdk/react": "^3.0.199",
1949
1960
  "@assistant-ui/react-ai-sdk": "workspace:*",
1950
1961
  "@assistant-ui/react-native": "workspace:*",
1951
1962
  "@expo/vector-icons": "^15.1.1",
1952
1963
  "@react-navigation/drawer": "7.9.4",
1953
1964
  "@react-navigation/native": "7.1.33",
1954
- "ai": "^6.0.188",
1955
- "expo": "~56.0.4",
1956
- "expo-constants": "~56.0.15",
1965
+ "ai": "^6.0.197",
1966
+ "expo": "~56.0.9",
1967
+ "expo-constants": "~56.0.17",
1957
1968
  "expo-font": "~56.0.5",
1958
- "expo-image-picker": "~56.0.13",
1959
- "expo-linking": "~56.0.11",
1960
- "expo-router": "~56.2.6",
1961
- "expo-server": "~56.0.4",
1969
+ "expo-image-picker": "~56.0.16",
1970
+ "expo-linking": "~56.0.13",
1971
+ "expo-router": "~56.2.9",
1972
+ "expo-server": "~56.0.5",
1962
1973
  "expo-splash-screen": "~56.0.10",
1963
1974
  "expo-status-bar": "~56.0.4",
1975
+ "expo-symbols": "^56.0.6",
1964
1976
  "expo-system-ui": "~56.0.5",
1965
1977
  "react": "19.2.3",
1966
1978
  "react-dom": "19.2.3",
@@ -1974,7 +1986,8 @@ module.exports = config;
1974
1986
  "zod": "^4.4.3"
1975
1987
  },
1976
1988
  "devDependencies": {
1977
- "@types/react": "~19.2.15",
1989
+ "@assistant-ui/metro": "workspace:*",
1990
+ "@types/react": "~19.2.17",
1978
1991
  "typescript": "~6.0.3"
1979
1992
  },
1980
1993
  "private": true
@@ -2058,7 +2071,9 @@ Join our community of developers creating universal apps.
2058
2071
 
2059
2072
  ```json
2060
2073
  {
2061
- "buildCommand": "cd ../.. && pnpm turbo build --filter=@assistant-ui/react-native --filter=@assistant-ui/react-ai-sdk && cd examples/with-expo && pnpm run export:web",
2074
+ "$schema": "https://openapi.vercel.sh/vercel.json",
2075
+ "ignoreCommand": "bash ../../scripts/vercel-ignore-changeset-release.sh",
2076
+ "buildCommand": "cd ../.. && pnpm turbo build --filter=@assistant-ui/react-native --filter=@assistant-ui/react-ai-sdk --filter=@assistant-ui/metro && cd examples/with-expo && pnpm run export:web",
2062
2077
  "outputDirectory": "dist",
2063
2078
  "framework": null
2064
2079
  }
@@ -290,13 +290,14 @@ export default function Home() {
290
290
  ## next.config.ts
291
291
 
292
292
  ```typescript
293
+ import { withAui } from "@assistant-ui/next";
293
294
  import type { NextConfig } from "next";
294
295
 
295
296
  const nextConfig: NextConfig = {
296
297
  /* config options here */
297
298
  };
298
299
 
299
- export default nextConfig;
300
+ export default withAui(nextConfig);
300
301
 
301
302
  ```
302
303
 
@@ -319,17 +320,18 @@ export default nextConfig;
319
320
  "@assistant-ui/ui": "workspace:*",
320
321
  "class-variance-authority": "^0.7.1",
321
322
  "clsx": "^2.1.1",
322
- "lucide-react": "^1.16.0",
323
- "next": "^16.2.6",
324
- "react": "^19.2.6",
325
- "react-dom": "^19.2.6",
323
+ "lucide-react": "^1.17.0",
324
+ "next": "^16.2.7",
325
+ "react": "^19.2.7",
326
+ "react-dom": "^19.2.7",
326
327
  "tailwind-merge": "^3.6.0"
327
328
  },
328
329
  "devDependencies": {
330
+ "@assistant-ui/next": "workspace:*",
329
331
  "@assistant-ui/x-buildutils": "workspace:*",
330
332
  "@tailwindcss/postcss": "^4.3.0",
331
- "@types/node": "^25.9.1",
332
- "@types/react": "^19.2.15",
333
+ "@types/node": "^25.9.2",
334
+ "@types/react": "^19.2.17",
333
335
  "@types/react-dom": "^19.2.3",
334
336
  "postcss": "^8.5.15",
335
337
  "tailwindcss": "^4.3.0",