comparar · AI
Both work with Next.js. In a kit you pick one, and your agent gets the rule to use only that one.
| OpenAI | Vercel AI SDK | |
|---|---|---|
| What it is | Official OpenAI SDK for server-side model calls. | Streaming, chat and tools with any model (Claude by default). |
| Frameworks | Node.js, Bun, Nuxt, SvelteKit, Next.js | Next.js |
| Paquetes | openai@^7.57.0 | ai @ai-sdk/anthropic @ai-sdk/react |
| Skill oficial | — | vercel/ai@ai-sdk |
| How your agent uses it | Create the SDK client only inside server code when OPENAI_API_KEY is present. Bound tokens, timeouts and spend; validate model output before taking actions. | Call models from Route Handlers or Server Actions with `streamText` / `generateText` from `ai` and the `anthropic("claude-opus-5-5")` provider. On the client use `useChat` from `@ai-sdk/react`. There's an example in `src/app/api/chat/route.ts`. |
| Kits that offer it | api-elysia, api-express, api-fastify, api-hono, api-nestjs, cli-node, discord-bot, github-action, mcp-server-ts, saas-ai-next, saas-next-better-auth, saas-next-supabase, saas-nuxt, saas-sveltekit, saas-t3, slack-app, web-next, web-nuxt, web-sveltekit | saas-ai-next, saas-next-better-auth, saas-next-supabase, saas-t3, web-next |
| Chosen in | 0 installs | 0 installs |