An all-in-one AI chat framework that makes building conversational experiences dead simple.
🤔 Still building chat UIs from scratch? Managing message state manually? Implementing streaming yourself?
Let ChatKit handle the heavy lifting. Get a complete AI chat experience up and running in minutes.
- Save Time: Integrate a full-featured chat in 30 minutes, not weeks
- Flexible: Works with React, Vue, vanilla JS—customize themes your way
- Complete: Streaming, tools, uploads, threads—all built in
Config environment by copying .env.example to .env and filling in your values.
from fastapi import FastAPI
app = FastAPI()
@app.post("/api/chatkit/session")
async def create_session():
return {"client_secret": "your_session_token"}Full example: pnpm managed-chatkit:dev
npm install @xpert-ai/chatkit-reactConfig environment by copying .env.example to .env and filling in your values.
import { ChatKit, useChatKit } from '@xpert-ai/chatkit-react';
export function MyChat() {
const { control } = useChatKit({
api: {
async getClientSecret() {
const res = await fetch('/api/chatkit/session', { method: 'POST' });
const { client_secret } = await res.json();
return client_secret;
},
},
theme: { colorScheme: 'light', radius: 'round' },
});
return <ChatKit control={control} className="h-[600px]" />;
}- 🎨 Deep Customization - Control colors, fonts, spacing—make it yours
- ⚡ Real-time Streaming - Messages flow in smoothly, token by token
- 🔧 Tool Integration - Seamless client and server tool support
- 📎 File Uploads - Attach files and images with flexible config
- 💬 Thread Management - Switch conversations, track history
- 🌍 i18n Ready - 68+ locales out of the box
- 🎯 Framework Agnostic - React/Vue/Angular/vanilla JS all work
chatkit-js/
├── packages/
│ ├── chatkit/ # Core type definitions
│ ├── chatkit-react/ # React bindings
│ ├── chatkit-ui/ # Complete UI library
│ └── web-component/ # Web Component (framework-agnostic)
├── examples/
│ └── managed-chatkit/ # Full-stack example
└── docs/ # Documentation
# Install dependencies
pnpm install
# Build all packages
pnpm build
# Run full-stack example
pnpm managed-chatkit:dev
# Dev UI components
pnpm dev:ui
# Run tests
pnpm test
# Lint code
pnpm lintTo publish a specific package (like @xpert-ai/chatkit-vue), run:
pnpm -r publish --filter @xpert-ai/chatkit-vue... --access public- Chrome/Edge 90+
- Firefox 88+
- Safari 14+
- Modern mobile browsers
- Core message streaming
- Thread management
- File attachments
- Advanced theming
- Tool call visualization
- Voice I/O
- WebSocket support
We love contributions!
- Fork the project
- Create a branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
- 📖 Documentation
- 🐛 Issues
- 💬 Discussions
Apache License 2.0
Built with ❤️ by the Xpert AI team
Got questions? Want to chat? Feel free to open an issue or join the discussion