Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork79
🤖 SDK that enhances your applications with AI capabilities
License
TanStack/ai
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
A powerful, type-safe AI SDK for building AI-powered applications.
- Provider-agnostic adapters (OpenAI, Anthropic, Gemini, Ollama, etc.)
- Multimodal content support - Send images, audio, video, and documents
- Chat completion, streaming, and agent loop strategies
- Headless chat state management with adapters (SSE, HTTP stream, custom)
- Isomorphic type-safe tools with server/client execution
- Enhanced integration with TanStack Start - Share implementations between AI tools and server functions
TanStack AI works withany framework (Next.js, Express, Remix, etc.).
With TanStack Start, you get a bonus: share implementations between AI tools and server functions withcreateServerFnTool:
import{createServerFnTool}from'@tanstack/ai-react'// Define once, get AI tool AND server function (TanStack Start only)constgetProducts=createServerFnTool({name:'getProducts',inputSchema:z.object({query:z.string()}),execute:async({ query})=>db.products.search(query),})// Use in AI chatchat({tools:[getProducts.server]})// Call directly from components (no API endpoint needed!)constproducts=awaitgetProducts.serverFn({query:'laptop'})
No duplicate logic, full type safety, automatic validation. TheserverFn feature requires TanStack Start. Seedocs for details.
- We welcome issues and pull requests!
- Participate inGitHub discussions
- Chat with the community onDiscord
- SeeCONTRIBUTING.md for setup instructions
We're looking for TanStack AI Partners to join our mission! Partner with us to push the boundaries of TanStack AI and build amazing things together.
LET'S CHAT- TanStack Config – Tooling for JS/TS packages
- TanStack DB – Reactive sync client store
- TanStack Devtools – Unified devtools panel
- TanStack Form – Type‑safe form state
- TanStack Pacer – Debouncing, throttling, batching
- TanStack Query – Async state & caching
- TanStack Ranger – Range & slider primitives
- TanStack Router – Type‑safe routing, caching & URL state
- TanStack Start – Full‑stack SSR & streaming
- TanStack Store – Reactive data store
- TanStack Table – Headless datagrids
- TanStack Virtual – Virtualized rendering
… and more atTanStack.com »
About
🤖 SDK that enhances your applications with AI capabilities
Resources
License
Code of conduct
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Sponsor this project
Uh oh!
There was an error while loading.Please reload this page.
Packages0
Uh oh!
There was an error while loading.Please reload this page.
