<Chat> do not require ChatProvider. Use them with your own AI SDK useChat call when your application owns transport, routing, or state management.
Message, MessagePart, TextPart, ReasoningPart, ToolPart, FilePart, SourcePart, DataPart, ChatHistory, ChatShell, and ChatStatus are also exported from @frogbotai/ui/chat for deeper composition.
Composer props
Composer is a Lexical plain-text editor. className goes on the surrounding form. Its / commands, @ mention sources, features and prompt history come from ChatProvider; without one it has no commands or mentions, the default features, and history in localStorage. See Composer commands, mentions and features.
Without an adapter that has
uploadAttachment, the composer has no attachment control, ignores dropped and pasted files, and keeps pastes over 650 characters in the browser as PasteAttachments. With one, pasted files become attachments, and any text copied with them is dropped. <Chat> passes the provider’s adapter and sets modelInputs and modelName from the selected model.
Composer prompt
ComposerPrompt is { text, mentions }. A mention chip stays in text as @label, and mentions lists each chip once, in order, as a ComposerMention:
composerParts(prompt, attachments) builds the parts <Chat> sends: a file-reference or data-paste part per attachment, a text part, then a data-mention part per chip with its ComposerMention as data. FrogBot’s server leaves data-mention parts out of the model’s messages, so the model reads @label in the text, and MessagePart renders nothing for them.
Composer attachments
ComposerAttachment is a FileReference or a PasteAttachment. Both types are exported from @frogbotai/ui/chat.
A FileReference is an uploaded file or a pasted text stored as a text asset. Send it as a file-reference part.
A
PasteAttachment is pasted text kept in the browser because the composer has no upload storage. Send it as a data-paste part with { text, filename }.
Message list props
MessageList also accepts any div attribute; className and the rest go on the scrolling element.
If custom message parts can appear, pass a
fallback to MessagePart. Unknown standard parts otherwise render a safe unsupported-part fallback.