The frontend library for AI agents.

Primitives and a runtime for production chat. Any backend, through adapters.

Read the docs
New chat

How can I help you today?

What you install

@assistant-ui/react

The runtime owns the thread, the stream, and the tools.

The setup

A provider, a hook, one component. The complete client, whatever runs behind it.

All runtimes →
import { AssistantRuntimeProvider } from "@assistant-ui/react";
import { useChatRuntime, AssistantChatTransport } from "@assistant-ui/ai-sdk";
import { Thread } from "@/components/assistant-ui/thread";

export default function App() {
  const runtime = useChatRuntime({
    transport: new AssistantChatTransport({ api: "/api/chat" }),
  });

  return (
    <AssistantRuntimeProvider runtime={runtime}>
      <Thread />
    </AssistantRuntimeProvider>
  );
}

Your route runs the model. The transport streams it back.

read the AI SDK guide →

What the runtime handles

The primitives

Yours to reshape. Every part is a component you compose; the CLI copies the UI source into your repo.

Customize the thread →
Root

Root · Owns the runtime context. Everything composes inside.

Works with AI SDK, LangGraph, and LangChain, or any backend through adapters. Ships for React, Native, and Ink. Elements extends it. Cloud hosts threads and persistence when you want them.

Anthropic
Google Cloud
Langchain
Builder.io
Paperclip
Unsloth

Get started

Start in the docs.

The command scaffolds a working thread. The docs take it from there.

npx assistant-ui init

@assistant-ui/[email protected] · MIT License