New advertisers: 50% off your first month with code FIRSTMONTHSee slots
vercel avatar

Ai Sdk

vercel/aiOfficial

Official toolkit for building AI features with generateText, streamText, agents, tools, and embeddings across model providers.

skills.sh installs
70.5K
GitHub stars
28.1K
last updated
Aug 21, 2026
View on GitHub

What it does

  • Covers text generation, streaming, structured output, tool calling, agents, embeddings, and React hooks such as useChat and useCompletion
  • Points to version-matched docs and source bundled in node_modules/ai/ so code reflects the installed release rather than memory
  • Enforces verification of every API and model ID against bundled docs or the AI Gateway model list before writing code
  • Designed for developers adding AI to a TypeScript app, with AI Gateway setup, agent guidance, DevTools, and a version-currency check

Install

$ npx -y skills add vercel/ai --skill ai-sdk -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

What the AI SDK Is

The AI SDK by Vercel (the ai package on npm) is a TypeScript toolkit for building AI applications. It provides a unified API across model providers for text generation, structured output, tool calling, agents, embeddings, and framework UI integrations.

Critical: Do Not Trust Your Own Memory

Whatever you remember about the AI SDK is likely outdated. The SDK changes frequently across versions - APIs are renamed, removed, and added. Your training data almost certainly contains obsolete APIs, deprecated patterns, and model IDs that no longer exist. UI hooks like useChat are among the most frequently changed APIs, so be especially careful with client code.

Never write AI SDK code from memory. Always verify every API, option, and pattern against the documentation and source code for the version that is actually installed in the project.

Use the Bundled, Version-Matched Docs

The ai package ships its full documentation and source code inside node_modules. These always match the installed version, so trust them over anything you remember.

Details

Repository
github.com/vercel/ai
Categories
AI Agents & LLM Apps, Frontend & UI Code

More from vercel/ai

All 8

Similar to Ai Sdk

More AI Agents & LLM Apps