Import @tanstack/ai-client/ui. Do not import it from the main client entry.
The subpath gives you:
Your adapter owns:
Do not add default markup. Do not add a new store. The app owns useAppChat from createChatHook, or useChat / createChat.
Call selectChatUI({ messages, interrupts, inlineToolNames }). Automatic traversal skips a tool-result only when matched is true. Keep unmatched results.
Warn once per missing runtime key in development. Each build tool detects development mode differently, so the adapter prints the warning.
See the React, Solid, Vue, and Svelte adapters for the public names to match: Chat, Provider, Messages, Message, Part, Interrupts, Interrupt, useChatContext, and createChatHookContexts.