ai-sdk
๐ฏSkillfrom vercel/ai
The official Vercel AI SDK skill for Claude Code that provides guidance on building AI-powered features using generateText, streamText, ToolLoopAgent, tool calling, structured output, and framework-specific streaming patterns.
Overview
ai-sdk is the official Claude Code skill from Vercel for the AI SDK (formerly known as Vercel AI SDK). It provides Claude Code with up-to-date documentation lookup strategies, API usage patterns, and agent-building guidance so that generated code always reflects the latest SDK version. The skill is uniquely designed around a "do not trust internal knowledge" principle, instructing Claude Code to always verify APIs against the bundled docs in node_modules or the ai-sdk.dev documentation site rather than relying on potentially outdated training data.
Key Features
- Documentation-first workflow that directs Claude Code to search
node_modules/ai/docs/andnode_modules/ai/src/for current APIs (ai@6.0.34+), or fall back to the ai-sdk.dev search endpoint for earlier versions, ensuring generated code never uses deprecated patterns. - Agent building with ToolLoopAgent pattern, including type-safe agent definitions, tool creation with
inputSchema, and end-to-end type safety usingInferAgentUIMessagefor consuming agents withuseChat. - Common errors reference covering renamed parameters (maxTokens to maxOutputTokens, maxSteps to stopWhen, parameters to inputSchema, and many more), preventing frequent type errors and build failures.
- Vercel AI Gateway integration guidance for accessing multiple AI providers (OpenAI, Anthropic, Google) through a single unified API with automatic model ID fetching to always use the latest models.
- Framework-specific consumption patterns with instructions to detect the project's stack via package.json and follow the appropriate quickstart for streaming, API routes, and client integration. Includes DevTools setup for local debugging of LLM requests and multi-step interactions.
Who is this for?
This skill is essential for any developer building AI-powered features with the Vercel AI SDK, whether creating chatbots, agentic workflows, RAG systems, or text generation pipelines. It is especially valuable for teams using React hooks like useChat and useCompletion, developers working with tool calling and structured output, and anyone integrating multiple AI providers through the AI Gateway. The skill ensures Claude Code produces correct, up-to-date code even as the AI SDK API evolves rapidly between versions.
Same repository
vercel/ai(10 items)
Installation
npx vibeindex add vercel/ai --skill ai-sdknpx skills add vercel/ai --skill ai-sdk~/.claude/skills/ai-sdk/SKILL.mdSKILL.md
More from this repository9
Demonstrates AI function development with Vercel AI SDK using multiple model providers for text generation and interactive interfaces
Captures and stores API responses as test fixtures for the Vercel AI SDK, enabling reproducible testing of AI provider integrations.
Lists and inspects the file structure and contents of npm packages for the Vercel AI SDK, helping developers understand package composition.
Skill
Skill
Skill
Skill
Lists and explores contents of npm packages, revealing file structures, dependencies, and package metadata for quick project insights.
Skill