Right now, I'm using the Vercel ai SDK's useChat hook because it makes chat state management much easier. However, this requires that I have an API route (e.g., app/api/chat/route.ts).
I would like to be able to use the useChat hook client-side with a client-provided API key instead of an API route. This would make it possible to easily use the AI SDK in static sites (frontend-only).
What do you think? ![]()