ai-sdk-6

Solid

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.

AI & Automation 39 stars 14 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 86/100

Stars 20%
53
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Vercel AI SDK v6 Development Guide Use this skill when developing AI-powered features using Vercel AI SDK v6 (`ai` package). > **Docs location**: bundled in `node_modules/ai/docs/`. In Bun/pnpm/Yarn workspace monorepos deps aren't hoisted — use `apps/*/node_modules/ai/docs/` or `packages/*/node_modules/ai/docs/` instead. ## Quick Reference ### Installation ```bash bun add ai @ai-sdk/openai zod # or @ai-sdk/anthropic, @ai-sdk/google, etc. ``` ### Core Functions | Function | Purpose | | -------------- | ----------------------------------------------------------------- | | `generateText` | Non-streaming text generation (+ structured output with `Output`) | | `streamText` | Streaming text generation (+ structured output with `Output`) | > **v6 Note**: `generateObject`/`streamObject` are deprecated. > Use `generateText`/`streamText` with `output: Output.object({ schema })` instead. ### Structured Output (v6) ```typescript import { generateText, Output } from "ai"; import { z } from "zod"; const { output } = await generateText({ model: anthropic("claude-sonnet-4-6"), output: Output.object({ schema: z.object({ sentiment: z.enum(["positive", "neutral", "negative"]), topics: z.array(z.string()), }), }), prompt: "Analyze this feedback...", }); ``` Output types: `Output.object()`, `Output.array()`, `Output.choice()`, `Output.json()` ### Agent Class (v6 Key Feature) ```typ...

Details

Author
laguagu
Repository
laguagu/claude-code-nextjs-skills
Created
4 months ago
Last Updated
yesterday
Language
TypeScript
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category

AI & Automation Listed

ai-sdk

Answer questions about the AI SDK and help build AI-powered features. Use when developers: (1) Ask about AI SDK functions like generateText, streamText, ToolLoopAgent, embed, or tools, (2) Want to build AI agents, chatbots, RAG systems, or text generation features, (3) Have questions about AI providers (OpenAI, Anthropic, Google, etc.), streaming, tool calling, structured output, or embeddings, (4) Use React hooks like useChat or useCompletion. Triggers on: "AI SDK", "Vercel AI SDK", "generateText", "streamText", "add AI to my app", "build an agent", "tool calling", "structured output", "useChat".

1 Updated 5 days ago
build-with-dhiraj
AI & Automation Listed

ai-sdk

Answer questions about the AI SDK and help build AI-powered features. Use when developers: (1) Ask about AI SDK functions like generateText, streamText, ToolLoopAgent, embed, or tools, (2) Want to build AI agents, chatbots, RAG systems, or text generation features, (3) Have questions about AI providers (OpenAI, Anthropic, Google, etc.), streaming, tool calling, structured output, or embeddings, (4) Use React hooks like useChat or useCompletion. Triggers on: "AI SDK", "Vercel AI SDK", "generateText", "streamText", "add AI to my app", "build an agent", "tool calling", "structured output", "useChat".

335 Updated today
aiskillstore
AI & Automation Listed

ai-sdk-handler

Integrate Vercel AI SDK for LLMs, Chatbots, Generative UI, and Agentic Workflows.

335 Updated today
aiskillstore
AI & Automation Solid

ai-sdk

Answer questions about the AI SDK and help build AI-powered features. Use when developers: (1) Ask about AI SDK functions like generateText, streamText, ToolLoopAgent, embed, or tools, (2) Want to build AI agents, chatbots, RAG systems, or text generation features, (3) Have questions about AI providers (OpenAI, Anthropic, Google, etc.), streaming, tool calling, structured output, or embeddings, (4) Use React hooks like useChat or useCompletion. Triggers on: "AI SDK", "Vercel AI SDK", "generateText", "streamText", "add AI to my app", "build an agent", "tool calling", "structured output", "useChat".

39 Updated yesterday
laguagu
AI & Automation Featured

vercel-ai-sdk-expert

Expert in the Vercel AI SDK. Covers Core API (generateText, streamText), UI hooks (useChat, useCompletion), tool calling, and streaming UI components with React and Next.js.

39,350 Updated today
sickn33