Agent skill · software engineering · assistant-ui
primitives
Builds and customizes assistant-ui chat UI from composable, unstyled @assistant-ui/react primitives that follow Radix-style part composition: ThreadPrimitive (.Root, .Viewport, .ViewportProvider, .ViewportFooter, .Messages, .MessageByIndex, .Unstable_MessageById, .ScrollToBottom, .Suggestions), ComposerPrimitive (.Input, .Send, .Cancel, .Attachments, .AddAttachment, .AttachmentDropzone, .Quote, .Dictate, .Queue, the Unstable_TriggerPopover family for mentions and slash commands), MessagePrimitive (.Parts, .GroupedParts, .Attachments, .Quote, .GenerativeUI, .Error) and MessagePartPrimitive, ActionBarPrimitive plus ActionBarMorePrimitive, BranchPickerPrimitive, AttachmentPrimitive, ErrorPrimitive, AssistantModalPrimitive, ChainOfThoughtPrimitive, SelectionToolbarPrimitive, SuggestionPrimitive, QueueItemPrimitive, and the ThreadList primitives. Use when assembling or styling a custom Thread, Composer, message list, action bar, branch picker, mention or slash command popover, or suggestion grid from building blocks; when wiring headless composer input, input history, dictation, quoting, or file attachments; or when handling message editing, branching, timing, virtualization, custom scrollbars, or grouped chain of thought UI. Covers MessagePrimitive.Parts children render functions for text, image, file, reasoning, source, tool call, data, and generative UI parts, part grouping with groupPartByType (the mcp-app key was removed in 0.15, use standalone-tool-call), conditional rendering with AuiIf in selector form (the per-primitive .If props are deprecated), and gotchas such as wrapping in AssistantRuntimeProvider and adding className since primitives ship unstyled. For prebuilt drop-in UI and CLI scaffolding use setup, for the styled component catalog built on these primitives use elements, for multi-thread sidebar behavior use thread-list.
Why this skill is useful
Provides specific commands and patterns for building custom chat UI components that the AI wouldn't reliably generate on its own.
What it needs
About 7k tokens when loaded. Last updated 2026-08-02. 20 stars on the source repository.
What this skill does
assistant-ui Primitives Always consult assistant-ui.com/llms.txt for the latest API. Primitives are composable, unstyled components that follow Radix style part composition: a .Root provides context, .PartName children read it, and every part accepts asChild to merge its behavior onto your own element instead of rendering a wrapper. They ship with no styles and no opinions about layout, only behavior: keyboard shortcuts, auto scroll, streaming state, focus management, and disabled logic. Wrap your tree in AssistantRuntimeProvider (or a nested AuiProvider) before using any of them. References ./references/thread.md -- ThreadPrimitive: viewport, auto scroll, turn anchor, the messages iterator ./references/composer.md -- ComposerPrimitive: root, input, send, cancel, submit behavior ./references/message.md -- MessagePrimitive: the parts pipeline, tool resolution, attachments, quote, error ./references/action-bar.md -- ActionBarPrimitive and the ActionBarMorePrimitive overflow menu ./references/part-grouping.md -- GroupedParts, groupPartByType, chain of thought UI ./references/mentions.md -- @ mentions, / slash commands, custom trigger matchers ./references/composer-input.md -- headless input, input history, dictation, quoting, attachments ./references/messages.md -- editing, branching, message timing, virtualization, scrollbar, image parts ./references/suggestions.md -- Suggestions([...]), the suggestion adapter, ThreadPrimitive.Suggestions Import Primitive parts Primitive Parts ----------- ------- ThreadPrimitive .Root, .Viewport, .ViewportProvider, .ViewportFooter, .Messages, .MessageByIndex, .UnstableMessageById, .ScrollToBottom, .Suggestions, .SuggestionByIndex, .Suggestion, .Empty (deprecated), .If (deprecated) ComposerPrimitive .Root, .Input, .Send, .Cancel, .AddAttachment, .Attachments, .AttachmentByIndex, .AttachmentDropzone, .Dictate, .StopDictation, .DictationTranscript, .Quote, .QuoteText, .QuoteDismiss, .Queue, .UnstableTriggerPopoverRoot, .UnstableTriggerPo …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills assistant-ui/primitives