AI Elements are patterns for building agentic interfaces. Each one is a composition of WebJs UI components that you copy into your project. The code is yours.
A Chat is a list of Message turns inside a Message Scroller. The steps an agent takes inside a turn, like Reasoning, Tool and Plan, are built on Trace, so every step has the same shape.
Building a chatbot? Start from the Chat pattern. It puts Message Scroller, Message and Prompt Input together, and the AI SDK page shows how a 'use server' action streams the reply into it, with tool calls and reasoning as parts.
Coming from elements.ai-sdk.dev? See Migrating from AI SDK Elements.
Patterns
Migrating from AI SDK Elements
If you used AI SDK Elements from elements.ai-sdk.dev, here is what changes.
Existing projects
When you installed components from elements.ai-sdk.dev, the code was copied into your project under components/ai-elements. In a WebJs app each of them is a pattern built from WebJs UI components, so moving to WebJs means rebuilding each one on those components.
Each pattern page has a Migrating from AI SDK Elements section that maps every export of the wrapper in components/ai-elements onto the parts of the pattern, so you can rebuild it on Trace, Code Block and the other WebJs UI components one export at a time.
For example, the Queue section rebuilds queue.tsx on Trace, and the Inline Citation section rebuilds inline-citation.tsx on Hover Card.
What replaces each element
Each file from AI SDK Elements, and the WebJs UI pattern or component that replaces it.
Elements without a replacement
Each of these elements is a small composition you can build from components WebJs UI already has, listed below.
If you need one of these, open an issue and we will help you build it.
New projects
Build from WebJs UI components instead.
Add the components
Copy a pattern
Open a pattern above and copy its code into your project. Each page lists any other components it needs.
Or ask your coding agent to do it:
Add the Reasoning pattern from https://webjs.dev/ui/llm/docs/ai-elements/reasoning to my chat.
Need another element? Open an issue and tell us what you need.