ai-sdk
Prerequisites
Before searching docs, check if node_modules/ai/docs/ exists. If not, install only the ai package using the project's package manager (e.g., bun add ai).
Do not install other packages at this stage. Provider packages (e.g., @ai-sdk/openai) and client packages (e.g., @ai-sdk/react) should be installed later when needed based on user requirements.
Monorepo path note
In Bun / pnpm / Yarn workspace monorepos, dependencies are usually not hoisted to the repo root — they live inside each app's node_modules/. If node_modules/ai/docs/ doesn't exist at the working directory, check workspace locations before assuming docs are missing:
apps/*/node_modules/ai/docs/(e.g.apps/web/node_modules/ai/docs/)packages/*/node_modules/ai/docs/
Glob from the repo root: apps/*/node_modules/ai/docs/ or **/node_modules/ai/docs/. Substitute the resolved path everywhere this skill says node_modules/ai/docs/ or node_modules/ai/src/. The same applies to provider docs at node_modules/@ai-sdk/<provider>/docs/.
Critical: Do Not Trust Internal Knowledge
Everything you know about the AI SDK is outdated or wrong. Your training data contains obsolete APIs, deprecated patterns, and incorrect usage.
More from laguagu/claude-code-nextjs-skills
nextjs-seo
Next.js SEO optimization guide. Use when building Next.js apps, optimizing for search engines, fixing Google indexing issues, implementing metadata, sitemaps, robots.txt, JSON-LD, or auditing SEO.
1.1Knextjs-shadcn
Creates Next.js frontends with shadcn/ui. Use when building React UIs, components, pages, or applications with shadcn, Tailwind, or modern frontend patterns. Also use when the user asks to create a new Next.js project, add UI components, style pages, or build any web interface — even if they don't mention shadcn explicitly.
494openai-agents-sdk
OpenAI Agents SDK (Python) development. Use when building AI agents, multi-agent handoffs, function tools, guardrails, sessions, streaming, or tracing with the `openai-agents` / `agents` Python package — including Azure OpenAI via LiteLLM. Triggers on imports from `agents`, uses of `Runner.run_sync`/`Runner.run_streamed`, `@function_tool`, `AgentOutputSchema`, `SQLiteSession`, or questions about the openai-agents-python SDK.
320postgres-semantic-search
|
96ai-sdk-6
Vercel AI SDK v6 development. Use when building AI agents, chatbots, tool integrations, streaming apps, or structured output with the ai package. Covers ToolLoopAgent, useChat, generateText, streamText, tool approval, smoothStream, provider tools, MCP integration, and Output patterns.
93react-best-practices
React and Next.js performance optimization guide from Vercel Engineering (70 rules in 8 categories). Use when writing, reviewing, or refactoring React/Next.js code to eliminate waterfalls, reduce bundle size, prevent re-renders, optimize Server Components, or fix performance bottlenecks. Triggers on data fetching, Promise.all, Suspense, useMemo, dynamic imports, bundle analysis, code-splitting, and rendering performance tasks.
88