@assistant-ui/mcp-docs-server 0.1.35 → 0.1.38
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.
- package/.docs/organized/code-examples/waterfall.md +1 -1
- package/.docs/organized/code-examples/with-a2a.md +2 -2
- package/.docs/organized/code-examples/with-ag-ui.md +2 -2
- package/.docs/organized/code-examples/with-ai-sdk-v6.md +4 -4
- package/.docs/organized/code-examples/with-artifacts.md +4 -4
- package/.docs/organized/code-examples/with-assistant-transport.md +70 -54
- package/.docs/organized/code-examples/with-browser-extension.md +4 -4
- package/.docs/organized/code-examples/with-chain-of-thought.md +40 -89
- package/.docs/organized/code-examples/with-cloud-standalone.md +4 -4
- package/.docs/organized/code-examples/with-cloud.md +4 -4
- package/.docs/organized/code-examples/with-custom-thread-list.md +4 -4
- package/.docs/organized/code-examples/with-elevenlabs-conversational.md +7 -7
- package/.docs/organized/code-examples/with-elevenlabs-scribe.md +7 -7
- package/.docs/organized/code-examples/with-eve.md +343 -0
- package/.docs/organized/code-examples/with-expo.md +910 -933
- package/.docs/organized/code-examples/with-external-store.md +2 -2
- package/.docs/organized/code-examples/with-ffmpeg.md +5 -8
- package/.docs/organized/code-examples/with-generative-ui.md +6 -6
- package/.docs/organized/code-examples/with-google-adk.md +3 -3
- package/.docs/organized/code-examples/with-heat-graph.md +1 -1
- package/.docs/organized/code-examples/with-image-generation.md +4 -4
- package/.docs/organized/code-examples/with-interactables.md +166 -338
- package/.docs/organized/code-examples/with-langchain.md +4 -4
- package/.docs/organized/code-examples/with-langgraph.md +20 -157
- package/.docs/organized/code-examples/with-livekit.md +8 -8
- package/.docs/organized/code-examples/with-mcp.md +19 -10
- package/.docs/organized/code-examples/with-opencode.md +3 -3
- package/.docs/organized/code-examples/with-pi.md +9 -7
- package/.docs/organized/code-examples/with-react-hook-form.md +13 -6
- package/.docs/organized/code-examples/with-react-ink-web.md +5 -5
- package/.docs/organized/code-examples/with-react-ink.md +1 -1
- package/.docs/organized/code-examples/with-react-router.md +11 -11
- package/.docs/organized/code-examples/with-resumable-stream.md +5 -5
- package/.docs/organized/code-examples/with-store.md +1 -1
- package/.docs/organized/code-examples/with-tanstack.md +7 -7
- package/.docs/organized/code-examples/with-tap-runtime.md +2 -2
- package/.docs/organized/code-examples/with-virtualized-thread.md +44 -24
- package/.docs/raw/docs/(docs)/cli.mdx +5 -3
- package/.docs/raw/docs/(docs)/devtools.mdx +25 -2
- package/.docs/raw/docs/(docs)/index.mdx +5 -2
- package/.docs/raw/docs/(docs)/installation.mdx +5 -2
- package/.docs/raw/docs/(reference)/api-reference/external-store/message-conversion.mdx +16 -16
- package/.docs/raw/docs/(reference)/api-reference/hooks/composer-triggers.mdx +73 -42
- package/.docs/raw/docs/(reference)/api-reference/hooks/model-context.mdx +3 -20
- package/.docs/raw/docs/(reference)/api-reference/hooks/primitives.mdx +234 -166
- package/.docs/raw/docs/(reference)/api-reference/integrations/eve.mdx +51 -0
- package/.docs/raw/docs/(reference)/api-reference/integrations/index.mdx +4 -1
- package/.docs/raw/docs/(reference)/api-reference/integrations/react-ai-sdk.mdx +70 -38
- package/.docs/raw/docs/(reference)/api-reference/primitives/action-bar.mdx +30 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/attachment.mdx +7 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/branch-picker.mdx +26 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/chain-of-thought.mdx +15 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/composer.mdx +103 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/message-part.mdx +16 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/message.mdx +56 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/queue-item.mdx +12 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/selection-toolbar.mdx +12 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/suggestion.mdx +14 -0
- package/.docs/raw/docs/(reference)/api-reference/primitives/thread.mdx +57 -1
- package/.docs/raw/docs/(reference)/api-reference/tools/index.mdx +6 -0
- package/.docs/raw/docs/(reference)/api-reference/tools/interactables-legacy.mdx +55 -0
- package/.docs/raw/docs/(reference)/api-reference/tools/interactables.mdx +151 -0
- package/.docs/raw/docs/(reference)/api-reference/tools/rendering.mdx +15 -15
- package/.docs/raw/docs/(reference)/api-reference/tools/toolkits.mdx +20 -20
- package/.docs/raw/docs/(reference)/api-reference/utilities/miscellaneous.mdx +25 -9
- package/.docs/raw/docs/cloud/langgraph.mdx +1 -1
- package/.docs/raw/docs/guides/headless-composer-input.mdx +113 -0
- package/.docs/raw/docs/guides/latex.mdx +28 -22
- package/.docs/raw/docs/guides/mentions.mdx +32 -7
- package/.docs/raw/docs/guides/slash-commands.mdx +3 -6
- package/.docs/raw/docs/guides/speech.mdx +5 -7
- package/.docs/raw/docs/guides/virtualization.mdx +77 -7
- package/.docs/raw/docs/guides/voice.mdx +3 -2
- package/.docs/raw/docs/integrations/attachments/custom-adapter.mdx +4 -12
- package/.docs/raw/docs/integrations/auth/better-auth.mdx +7 -10
- package/.docs/raw/docs/integrations/auth/clerk.mdx +3 -9
- package/.docs/raw/docs/integrations/auth/next-auth.mdx +3 -8
- package/.docs/raw/docs/integrations/frameworks/ai-sdk.mdx +11 -8
- package/.docs/raw/docs/integrations/index.mdx +6 -13
- package/.docs/raw/docs/integrations/observability/helicone.mdx +3 -4
- package/.docs/raw/docs/integrations/observability/langfuse.mdx +3 -5
- package/.docs/raw/docs/integrations/observability/langsmith.mdx +5 -4
- package/.docs/raw/docs/integrations/persistence/custom-adapter.mdx +4 -3
- package/.docs/raw/docs/migrations/react-langgraph-v0-7.mdx +2 -2
- package/.docs/raw/docs/primitives/composer.mdx +8 -0
- package/.docs/raw/docs/primitives/thread-list.mdx +30 -6
- package/.docs/raw/docs/primitives/thread.mdx +24 -0
- package/.docs/raw/docs/runtimes/a2a/quickstart.mdx +1 -1
- package/.docs/raw/docs/runtimes/ag-ui/quickstart.mdx +1 -1
- package/.docs/raw/docs/runtimes/ag-ui/runtime-options.mdx +24 -1
- package/.docs/raw/docs/runtimes/ai-sdk/v6.mdx +1 -1
- package/.docs/raw/docs/runtimes/custom/external-store.mdx +54 -0
- package/.docs/raw/docs/runtimes/eve/overview.mdx +100 -0
- package/.docs/raw/docs/runtimes/eve/quickstart.mdx +143 -0
- package/.docs/raw/docs/runtimes/google-adk/quickstart.mdx +1 -1
- package/.docs/raw/docs/runtimes/langchain.mdx +388 -20
- package/.docs/raw/docs/runtimes/langgraph/quickstart.mdx +1 -1
- package/.docs/raw/docs/runtimes/langgraph/tutorial/part-1.mdx +1 -1
- package/.docs/raw/docs/runtimes/opencode/hooks.mdx +1 -1
- package/.docs/raw/docs/runtimes/pick-a-runtime.mdx +6 -0
- package/.docs/raw/docs/tools/defining-tools.mdx +9 -0
- package/.docs/raw/docs/tools/generative-ui.mdx +37 -0
- package/.docs/raw/docs/tools/interactables-legacy.mdx +410 -0
- package/.docs/raw/docs/tools/interactables.mdx +892 -223
- package/.docs/raw/docs/tools/mcp-apps.mdx +12 -3
- package/.docs/raw/docs/tools/mcp.mdx +9 -4
- package/.docs/raw/docs/tools/multi-agent.mdx +5 -0
- package/.docs/raw/docs/tools/user-managed-mcp.mdx +17 -3
- package/.docs/raw/docs/ui/composer-trigger-popover.mdx +2 -0
- package/.docs/raw/docs/ui/file.mdx +1 -1
- package/.docs/raw/docs/ui/follow-up-suggestions.mdx +80 -0
- package/.docs/raw/docs/ui/model-selector.mdx +38 -5
- package/.docs/raw/docs/ui/part-grouping.mdx +38 -0
- package/.docs/raw/docs/utilities/react-o11y.mdx +92 -6
- package/README.md +1 -1
- package/dist/constants.d.ts +2 -1
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +2 -1
- package/dist/constants.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +30 -2
- package/dist/index.js.map +1 -1
- package/dist/prepare-docs/copy-raw.d.ts.map +1 -1
- package/dist/prepare-docs/copy-raw.js +0 -4
- package/dist/prepare-docs/copy-raw.js.map +1 -1
- package/dist/tools/docs.d.ts.map +1 -1
- package/dist/tools/docs.js +18 -6
- package/dist/tools/docs.js.map +1 -1
- package/dist/tools/examples.d.ts +3 -1
- package/dist/tools/examples.d.ts.map +1 -1
- package/dist/tools/examples.js +1 -1
- package/dist/tools/examples.js.map +1 -1
- package/dist/tools/resources.d.ts +7 -0
- package/dist/tools/resources.d.ts.map +1 -0
- package/dist/tools/resources.js +74 -0
- package/dist/tools/resources.js.map +1 -0
- package/dist/tools/search.d.ts +33 -0
- package/dist/tools/search.d.ts.map +1 -0
- package/dist/tools/search.js +39 -0
- package/dist/tools/search.js.map +1 -0
- package/dist/tools/tests/test-setup.d.ts.map +1 -1
- package/dist/tools/tests/test-setup.js +3 -1
- package/dist/tools/tests/test-setup.js.map +1 -1
- package/dist/utils/mdx.d.ts +2 -1
- package/dist/utils/mdx.d.ts.map +1 -1
- package/dist/utils/mdx.js +19 -2
- package/dist/utils/mdx.js.map +1 -1
- package/dist/utils/paths.d.ts +2 -1
- package/dist/utils/paths.d.ts.map +1 -1
- package/dist/utils/paths.js +18 -1
- package/dist/utils/paths.js.map +1 -1
- package/dist/utils/search.d.ts +10 -0
- package/dist/utils/search.d.ts.map +1 -0
- package/dist/utils/search.js +97 -0
- package/dist/utils/search.js.map +1 -0
- package/package.json +4 -4
- package/src/constants.ts +2 -0
- package/src/index.ts +28 -6
- package/src/prepare-docs/copy-raw.ts +0 -5
- package/src/tools/docs.ts +30 -4
- package/src/tools/examples.ts +4 -2
- package/src/tools/resources.ts +114 -0
- package/src/tools/search.ts +46 -0
- package/src/tools/tests/completions.test.ts +46 -0
- package/src/tools/tests/directory-size-cap.test.ts +50 -0
- package/src/tools/tests/mcp-protocol.test.ts +21 -1
- package/src/tools/tests/resources.test.ts +102 -0
- package/src/tools/tests/search.test.ts +37 -0
- package/src/tools/tests/test-setup.ts +2 -0
- package/src/utils/mdx.ts +21 -1
- package/src/utils/paths.ts +22 -0
- package/src/utils/search.ts +131 -0
- package/.docs/raw/blog/2024-07-29-hello/index.mdx +0 -64
- package/.docs/raw/blog/2024-09-11/index.mdx +0 -10
- package/.docs/raw/blog/2024-12-15/index.mdx +0 -10
- package/.docs/raw/blog/2025-01-31-changelog/index.mdx +0 -127
- package/.docs/raw/blog/2026-03-launch-week/index.mdx +0 -258
|
@@ -68,6 +68,10 @@ time, the same way a live run never stores them.
|
|
|
68
68
|
|
|
69
69
|
`fromAgUiMessages` reconstructs the text, reasoning, and tool calls of each message. Multimodal user input (`image`, `audio`, `video`, and `document` parts, as well as legacy `binary` parts) is restored as attachments on the user message, so a backend that persists multimodal messages shows them again on reload and re-sends them on the next run. Legacy `binary` parts that only reference a file id are not restored.
|
|
70
70
|
|
|
71
|
+
An assistant message whose tool call has no matching tool result is reconstructed with `requires-action` status, the same status the runtime derives for a pending tool call, so a reloaded human-in-the-loop call (for example an `ask_user` tool) is actionable rather than stuck. This matches how every other external-store runtime surfaces a pending tool call on reload. The AG-UI wire snapshot carries no run outcome, so a tool call that a successful run intentionally left without a result is also surfaced as actionable.
|
|
72
|
+
|
|
73
|
+
Interrupts are restored when your backend persists them on the assistant message. The AG-UI message body has no interrupt field, so persist the runtime's own `metadata.custom.agui.interrupts` array alongside the message; `fromAgUiMessages` reads it back, reconstructs `requires-action` / `interrupt` status, and re-attaches the metadata, so `getPendingInterrupts`, `useAgUiInterrupts`, and `submitInterruptResponses` work on reload. When both a pending tool call and an interrupt are present on the same message, interrupt status wins. Without the persisted array, interrupt state cannot be reconstructed.
|
|
74
|
+
|
|
71
75
|
## Thread list (experimental)
|
|
72
76
|
|
|
73
77
|
<Callout type="warn">
|
|
@@ -131,6 +135,25 @@ await runtime.unstable_submitInterruptResponses(
|
|
|
131
135
|
);
|
|
132
136
|
```
|
|
133
137
|
|
|
138
|
+
### Steering away from an interrupt
|
|
139
|
+
|
|
140
|
+
When the user ignores the interrupt UI and just sends a new message, use the `useAgUiSteerAway` hook. Every open interrupt defaults to `status: "cancelled"`, the new message is appended, and the run resumes with `resume: ResumeEntry[]` on the wire. With no pending interrupts it behaves like a normal append.
|
|
141
|
+
|
|
142
|
+
```tsx
|
|
143
|
+
const steerAway = useAgUiSteerAway();
|
|
144
|
+
|
|
145
|
+
// the user typed a new message instead of answering the interrupt
|
|
146
|
+
await steerAway("actually, let's do something else");
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
The message accepts a plain string or a partial `AppendMessage` (the parent defaults to the current head, which is the interrupted assistant message). Pass `responses` to override the status of specific interrupts; the rest still default to cancelled.
|
|
150
|
+
|
|
151
|
+
```tsx
|
|
152
|
+
await steerAway("continue without the file", [
|
|
153
|
+
{ interruptId: "tool-1", status: "resolved", payload: { approved: true } },
|
|
154
|
+
]);
|
|
155
|
+
```
|
|
156
|
+
|
|
134
157
|
## Supported events
|
|
135
158
|
|
|
136
159
|
The runtime parses the AG-UI event stream and maps each event type to assistant-ui state.
|
|
@@ -178,7 +201,7 @@ The runtime parses the AG-UI event stream and maps each event type to assistant-
|
|
|
178
201
|
icon={<AguiIcon width={20} height={20} />}
|
|
179
202
|
title="AG-UI overview"
|
|
180
203
|
description="What AG-UI is and when to pick it."
|
|
181
|
-
href="/docs/runtimes/ag-ui"
|
|
204
|
+
href="/docs/runtimes/ag-ui/overview"
|
|
182
205
|
/>
|
|
183
206
|
<Card
|
|
184
207
|
title="Quickstart"
|
|
@@ -3,7 +3,7 @@ title: AI SDK v6
|
|
|
3
3
|
description: Integrate Vercel AI SDK v6 with assistant-ui for streaming chat.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
Current-version integration. Requires `ai@^6` and `@ai-sdk/react@^3`. For older versions see the [overview](/docs/runtimes/ai-sdk).
|
|
6
|
+
Current-version integration. Requires `ai@^6` and `@ai-sdk/react@^3`. For older versions see the [overview](/docs/runtimes/ai-sdk/overview).
|
|
7
7
|
|
|
8
8
|
## Quickstart
|
|
9
9
|
|
|
@@ -299,6 +299,54 @@ runtime.thread.import(repo);
|
|
|
299
299
|
|
|
300
300
|
Each message must have an explicit `id` and `parentId`; messages with the same `parentId` create branches. Parents must appear before children in the array.
|
|
301
301
|
|
|
302
|
+
### Exporting a snapshot
|
|
303
|
+
|
|
304
|
+
`thread.import()` has a counterpart, `thread.export()`, which captures the current thread (including its full branch tree) as a serializable `ExportedMessageRepository`. Use it to persist a conversation and re-import it later:
|
|
305
|
+
|
|
306
|
+
```tsx
|
|
307
|
+
// capture the current thread as a serializable snapshot
|
|
308
|
+
const repo = runtime.thread.export();
|
|
309
|
+
await saveToBackend(JSON.stringify(repo));
|
|
310
|
+
|
|
311
|
+
// later, restore it into a runtime
|
|
312
|
+
runtime.thread.import(repo);
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
The exported shape round-trips through `thread.import()` directly, so the same value is both your persistence format and what you load back.
|
|
316
|
+
|
|
317
|
+
### Persisting branch selection
|
|
318
|
+
|
|
319
|
+
If you store the full branch tree outside assistant-ui, persist the selected branch head too and pass it back as `messageRepository.headId`. `setMessages` still performs the branch switch; `unstable_onBranchChange` is an additional signal that fires after an explicit `switchToBranch` action, such as a BranchPicker click.
|
|
320
|
+
|
|
321
|
+
```tsx
|
|
322
|
+
const runtime = useExternalStoreRuntime({
|
|
323
|
+
messageRepository: {
|
|
324
|
+
messages: storedMessages,
|
|
325
|
+
headId: selectedHeadId,
|
|
326
|
+
},
|
|
327
|
+
setMessages: (messages) => {
|
|
328
|
+
setVisibleMessages(messages);
|
|
329
|
+
},
|
|
330
|
+
unstable_onBranchChange: ({ headId, visibleMessageIds }) => {
|
|
331
|
+
saveSelectedBranch({
|
|
332
|
+
headId,
|
|
333
|
+
visibleMessageIds,
|
|
334
|
+
});
|
|
335
|
+
},
|
|
336
|
+
onNew,
|
|
337
|
+
});
|
|
338
|
+
```
|
|
339
|
+
|
|
340
|
+
`headId` is the canonical persisted head of the visible branch. Optimistic or transient message ids are not surfaced there. `visibleMessageIds` is the currently visible path in order, which can include an optimistic leaf while `headId` points to its persisted ancestor.
|
|
341
|
+
|
|
342
|
+
The callback only fires for explicit branch switches, and consecutive switches that resolve to the same canonical head are de-duped. It does not fire on adapter resync, `messageRepository` reset, append, edit/regenerate, content-only updates, or while the thread is running.
|
|
343
|
+
|
|
344
|
+
<Callout type="warn">
|
|
345
|
+
`unstable_onBranchChange` is under active development and may change without
|
|
346
|
+
notice. It complements `setMessages`; it does not enable branch switching by
|
|
347
|
+
itself.
|
|
348
|
+
</Callout>
|
|
349
|
+
|
|
302
350
|
## Tool calling
|
|
303
351
|
|
|
304
352
|
Handle tool results by updating the matching tool-call entry:
|
|
@@ -717,6 +765,12 @@ useExternalStoreRuntime({
|
|
|
717
765
|
type: "(messages: readonly T[]) => void",
|
|
718
766
|
description: "Update messages (required for branch switching).",
|
|
719
767
|
},
|
|
768
|
+
{
|
|
769
|
+
name: "unstable_onBranchChange",
|
|
770
|
+
type: "(event: ExternalStoreBranchChange) => void",
|
|
771
|
+
description:
|
|
772
|
+
"Called after an explicit branch switch with the canonical persisted head id and visible message path. Complements setMessages and is unstable.",
|
|
773
|
+
},
|
|
720
774
|
{
|
|
721
775
|
name: "onEdit",
|
|
722
776
|
type: "(message: AppendMessage) => Promise<void>",
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Eve Runtime
|
|
3
|
+
description: Connect an Eve agent to assistant-ui with useEveAgentRuntime, eve/next, durable sessions, streaming messages, and human-in-the-loop approvals.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
import { VercelIcon } from "@/components/icons/vercel";
|
|
7
|
+
|
|
8
|
+
`@assistant-ui/eve` integrates assistant-ui with [Eve](https://eve.dev/), Vercel's filesystem-first framework for durable agents. It wraps Eve's `useEveAgent` hook and exposes it as an assistant-ui `ExternalStoreRuntime`, so Eve owns the session stream while assistant-ui renders messages, reasoning, dynamic tool calls, and approval requests.
|
|
9
|
+
|
|
10
|
+
## When to use it
|
|
11
|
+
|
|
12
|
+
Pick the Eve runtime when:
|
|
13
|
+
|
|
14
|
+
- You want your agent implementation to live under `agent/` and be served by `eve/next`.
|
|
15
|
+
- You want Eve sessions, continuation tokens, NDJSON streaming, and local development tooling.
|
|
16
|
+
- You want assistant-ui to render Eve messages and human-in-the-loop tool approvals without writing a custom runtime adapter.
|
|
17
|
+
|
|
18
|
+
## Architecture
|
|
19
|
+
|
|
20
|
+
The Next.js app mounts Eve with `withEve()` and assistant-ui's registry transform with `withAui()`:
|
|
21
|
+
|
|
22
|
+
```ts title="next.config.ts"
|
|
23
|
+
import { withAui } from "@assistant-ui/next";
|
|
24
|
+
import type { NextConfig } from "next";
|
|
25
|
+
import { withEve } from "eve/next";
|
|
26
|
+
|
|
27
|
+
const nextConfig: NextConfig = {};
|
|
28
|
+
|
|
29
|
+
export default withEve(withAui(nextConfig));
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
On the client, `useEveAgentRuntime()` calls Eve's React hook and converts Eve message parts into assistant-ui thread messages:
|
|
33
|
+
|
|
34
|
+
```tsx title="app/page.tsx"
|
|
35
|
+
"use client";
|
|
36
|
+
|
|
37
|
+
import { Thread } from "@/components/assistant-ui/thread";
|
|
38
|
+
import { useEveAgentRuntime } from "@assistant-ui/eve";
|
|
39
|
+
import { AssistantRuntimeProvider } from "@assistant-ui/react";
|
|
40
|
+
|
|
41
|
+
export default function Home() {
|
|
42
|
+
const runtime = useEveAgentRuntime();
|
|
43
|
+
|
|
44
|
+
return (
|
|
45
|
+
<AssistantRuntimeProvider runtime={runtime}>
|
|
46
|
+
<Thread />
|
|
47
|
+
</AssistantRuntimeProvider>
|
|
48
|
+
);
|
|
49
|
+
}
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
## Requirements
|
|
53
|
+
|
|
54
|
+
- Node.js 24 or higher.
|
|
55
|
+
- React 18 or 19.
|
|
56
|
+
- An Eve app mounted with `eve/next`.
|
|
57
|
+
- A model credential for the model configured in `agent/agent.ts`.
|
|
58
|
+
|
|
59
|
+
Eve's default gateway model ids route through the [Vercel AI Gateway](https://vercel.com/docs/ai-gateway). Use `AI_GATEWAY_API_KEY` or Vercel OIDC, or configure a direct provider `LanguageModel`.
|
|
60
|
+
|
|
61
|
+
## Install
|
|
62
|
+
|
|
63
|
+
<PlatformTabs>
|
|
64
|
+
<Tab value="React">
|
|
65
|
+
|
|
66
|
+
<InstallCommand npm={["@assistant-ui/react", "@assistant-ui/eve", "eve"]} />
|
|
67
|
+
|
|
68
|
+
</Tab>
|
|
69
|
+
<Tab value="React Native">
|
|
70
|
+
|
|
71
|
+
Eve's browser hook talks to the Eve HTTP channel. There is not a React Native Eve runtime package yet.
|
|
72
|
+
|
|
73
|
+
</Tab>
|
|
74
|
+
<Tab value="React Ink">
|
|
75
|
+
|
|
76
|
+
Use Eve's terminal UI directly for command-line agent sessions. There is not an Ink Eve runtime package yet.
|
|
77
|
+
|
|
78
|
+
</Tab>
|
|
79
|
+
</PlatformTabs>
|
|
80
|
+
|
|
81
|
+
## Auth note
|
|
82
|
+
|
|
83
|
+
Eve's built-in `eve` channel accepts localhost during development and trusted Vercel OIDC callers. It does not automatically admit browser users in production. Before deploying a public app, add `agent/channels/eve.ts` and wire the channel to your application auth.
|
|
84
|
+
|
|
85
|
+
## Next
|
|
86
|
+
|
|
87
|
+
<Cards>
|
|
88
|
+
<Card
|
|
89
|
+
icon={<VercelIcon width={20} height={20} />}
|
|
90
|
+
title="Quickstart"
|
|
91
|
+
description="Scaffold the Eve template or add Eve to an existing assistant-ui app."
|
|
92
|
+
href="/docs/runtimes/eve/quickstart"
|
|
93
|
+
/>
|
|
94
|
+
<Card
|
|
95
|
+
icon={<VercelIcon width={20} height={20} />}
|
|
96
|
+
title="Eve channel"
|
|
97
|
+
description="Routes, auth, session creation, and stream events in the default Eve HTTP channel."
|
|
98
|
+
href="https://eve.dev/docs/channels/eve"
|
|
99
|
+
/>
|
|
100
|
+
</Cards>
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Quickstart
|
|
3
|
+
description: From-template and manual setup paths to a working Eve agent chat in assistant-ui.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Two paths to a running Eve-powered assistant-ui app. The template is fastest; the manual path is what you adapt when integrating into an existing Next.js project.
|
|
7
|
+
|
|
8
|
+
## From the template
|
|
9
|
+
|
|
10
|
+
<PlatformTabs>
|
|
11
|
+
<Tab value="React">
|
|
12
|
+
|
|
13
|
+
```sh
|
|
14
|
+
npx create-assistant-ui@latest -t eve my-app
|
|
15
|
+
cd my-app
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Set a model credential:
|
|
19
|
+
|
|
20
|
+
```sh title=".env.local"
|
|
21
|
+
AI_GATEWAY_API_KEY=your-api-key
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
```sh
|
|
25
|
+
npm run dev
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Open http://localhost:3000 and send a message. The template includes:
|
|
29
|
+
|
|
30
|
+
- `agent/agent.ts` for Eve runtime config.
|
|
31
|
+
- `agent/instructions.md` for the always-on system prompt.
|
|
32
|
+
- `next.config.ts` with `withEve(withAui(nextConfig))`.
|
|
33
|
+
- `app/page.tsx` with `useEveAgentRuntime()`.
|
|
34
|
+
|
|
35
|
+
</Tab>
|
|
36
|
+
<Tab value="React Native">
|
|
37
|
+
|
|
38
|
+
There is not a React Native Eve template yet.
|
|
39
|
+
|
|
40
|
+
</Tab>
|
|
41
|
+
<Tab value="React Ink">
|
|
42
|
+
|
|
43
|
+
Use Eve's terminal UI directly for command-line agent sessions.
|
|
44
|
+
|
|
45
|
+
</Tab>
|
|
46
|
+
</PlatformTabs>
|
|
47
|
+
|
|
48
|
+
## Manual setup in an existing app
|
|
49
|
+
|
|
50
|
+
<Steps>
|
|
51
|
+
<Step>
|
|
52
|
+
|
|
53
|
+
### Install dependencies
|
|
54
|
+
|
|
55
|
+
<InstallCommand npm={["@assistant-ui/react", "@assistant-ui/eve", "eve"]} />
|
|
56
|
+
|
|
57
|
+
</Step>
|
|
58
|
+
<Step>
|
|
59
|
+
|
|
60
|
+
### Mount Eve in Next.js
|
|
61
|
+
|
|
62
|
+
```ts title="next.config.ts"
|
|
63
|
+
import { withAui } from "@assistant-ui/next";
|
|
64
|
+
import type { NextConfig } from "next";
|
|
65
|
+
import { withEve } from "eve/next";
|
|
66
|
+
|
|
67
|
+
const nextConfig: NextConfig = {};
|
|
68
|
+
|
|
69
|
+
export default withEve(withAui(nextConfig));
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
</Step>
|
|
73
|
+
<Step>
|
|
74
|
+
|
|
75
|
+
### Add an Eve agent
|
|
76
|
+
|
|
77
|
+
```ts title="agent/agent.ts"
|
|
78
|
+
import { defineAgent } from "eve";
|
|
79
|
+
|
|
80
|
+
export default defineAgent({
|
|
81
|
+
model: "anthropic/claude-sonnet-4.6",
|
|
82
|
+
});
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
```md title="agent/instructions.md"
|
|
86
|
+
You are a concise assistant. Use tools when they are available.
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
</Step>
|
|
90
|
+
<Step>
|
|
91
|
+
|
|
92
|
+
### Create the runtime
|
|
93
|
+
|
|
94
|
+
```tsx title="app/page.tsx"
|
|
95
|
+
"use client";
|
|
96
|
+
|
|
97
|
+
import { Thread } from "@/components/assistant-ui/thread";
|
|
98
|
+
import { useEveAgentRuntime } from "@assistant-ui/eve";
|
|
99
|
+
import { AssistantRuntimeProvider } from "@assistant-ui/react";
|
|
100
|
+
|
|
101
|
+
export default function Home() {
|
|
102
|
+
const runtime = useEveAgentRuntime();
|
|
103
|
+
|
|
104
|
+
return (
|
|
105
|
+
<AssistantRuntimeProvider runtime={runtime}>
|
|
106
|
+
<Thread />
|
|
107
|
+
</AssistantRuntimeProvider>
|
|
108
|
+
);
|
|
109
|
+
}
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
</Step>
|
|
113
|
+
</Steps>
|
|
114
|
+
|
|
115
|
+
## Production auth
|
|
116
|
+
|
|
117
|
+
The default Eve channel is convenient for local development. For production browser users, define `agent/channels/eve.ts` and replace the default auth policy with your app's auth.
|
|
118
|
+
|
|
119
|
+
```ts title="agent/channels/eve.ts"
|
|
120
|
+
import { localDev, vercelOidc } from "eve/channels/auth";
|
|
121
|
+
import { eveChannel } from "eve/channels/eve";
|
|
122
|
+
|
|
123
|
+
export default eveChannel({
|
|
124
|
+
auth: [localDev(), vercelOidc()],
|
|
125
|
+
});
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
That example keeps the development defaults. Swap in your Clerk, Auth.js, OIDC, or JWT verification before going live.
|
|
129
|
+
|
|
130
|
+
## Next
|
|
131
|
+
|
|
132
|
+
<Cards>
|
|
133
|
+
<Card
|
|
134
|
+
title="Eve overview"
|
|
135
|
+
description="Architecture, requirements, and runtime behavior."
|
|
136
|
+
href="/docs/runtimes/eve/overview"
|
|
137
|
+
/>
|
|
138
|
+
<Card
|
|
139
|
+
title="API reference"
|
|
140
|
+
description="useEveAgentRuntime and message conversion helpers."
|
|
141
|
+
href="/docs/api-reference/integrations/eve"
|
|
142
|
+
/>
|
|
143
|
+
</Cards>
|
|
@@ -3,7 +3,7 @@ title: Quickstart
|
|
|
3
3
|
description: Minimal API route and client setup with createAdkApiRoute.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
Four steps to a working ADK chat. Assumes you have already installed the package and have ADK ready on the server side; if not, start at [overview](/docs/runtimes/google-adk).
|
|
6
|
+
Four steps to a working ADK chat. Assumes you have already installed the package and have ADK ready on the server side; if not, start at [overview](/docs/runtimes/google-adk/overview).
|
|
7
7
|
|
|
8
8
|
<Steps>
|
|
9
9
|
<Step>
|