Components / Reasoning / Source
Source
An inline citation chip that opens a hover card with the linked page's details.
Installation
Install the Source React component with the shadcn CLI (after adding the @ai-primitive registry and theme, see Installation):
npx shadcn@latest add @ai-primitive/source
Usage
import { Source, SourceTrigger, SourceContent } from "@/components/ui/source"
Related components
- Reasoning - A collapsible "thinking" block that auto-opens while streaming and closes when done.
- Chain of Thought - A vertical trail of collapsible reasoning steps, connected by a line.
- Steps - A collapsible, numbered list of completed steps with a side rail.
- Tool - A collapsible tool-call card showing its state, input, output, or error.