Welcome to UICP
UICP (User Interface Context Protocol) enables LLM-based agents to describe and render UI components dynamically in chat interfaces. Instead of only returning text, AI agents can discover, create, and render rich UI components like cards, tables, charts, and custom interfaces.
What is UICP?
UICP is a protocol and set of tools that bridges the gap between AI text generation and rich user interfaces. It allows AI agents to:
- π Discover available UI components and their schemas
- π¨ Create structured component blocks that render as rich UI
- β‘ Render these components inline with text responses
- π§ Validate component data against defined schemas
Why UICP?
Traditional AI chat interfaces are limited to text and markdown. UICP unlocks:
- Richer User Experiences: Display data in cards, tables, charts, forms, and custom UI
- Better Information Presentation: Structure complex information in appropriate UI components
- Interactive Elements: Enable user interactions beyond simple text input
- Consistent Design: Components follow your design system automatically
- Type Safety: Full TypeScript support with runtime validation
Getting Started
Installation
Install UICP packages and set up your project
Quick Start
Get up and running in 5 minutes
Key Concepts
Understand core UICP concepts
Architecture
βββββββββββββββββββ
β AI Agent β
β (OpenAI, etc) β
ββββββββββ¬βββββββββ
β
β Uses Tools
βΌ
βββββββββββββββββββ ββββββββββββββββββββ
β @uicp/tools βββΆβ definitions.json β
β (Backend) β β Component Specs β
ββββββββββ¬βββββββββ ββββββββββββββββββββ
β
β Returns UICP Blocks
βΌ
βββββββββββββββββββ
β Chat Response β
β (Text + UICP) β
ββββββββββ¬βββββββββ
β
β Parse & Render
βΌ
βββββββββββββββββββ ββββββββββββββββββββ
β @uicp/parser βββΆβ React Components β
β (Frontend) β β Your UI Library β
βββββββββββββββββββ ββββββββββββββββββββUse Cases
- Data Visualization: Tables, charts, and graphs for data analysis
- E-commerce: Product cards, pricing tables, shopping carts
- Documentation: Code examples, API references, interactive tutorials
- Dashboards: Metrics, KPIs, status indicators
- Forms: Dynamic form generation and validation
- Notifications: Alerts, warnings, success messages
- Content Cards: News articles, blog posts, media galleries