AgentSkillsCN

vercel-ai-sdk-development

针对使用 Vercel AI SDK 构建 AI 应用的专家级指导。内容涵盖流式处理、多模型支持、工具调用、React 集成以及最佳实践。适用于构建聊天界面、AI 代理,或任何基于 Vercel AI SDK 的应用时参考。

SKILL.md
--- frontmatter
name: vercel-ai-sdk-development
description: Expert guidance for building AI applications with Vercel AI SDK. Covers streaming, multi-model support, tool calling, React integration, and best practices. Use when building chat interfaces, AI agents, or any application using the Vercel AI SDK.
license: MIT
compatibility: Requires Node.js 18+, React 18+, Next.js 14+
metadata:
  author: badbsallyy
  version: "2.0.0"
  sdk-version: "3.4+"
  last-updated: "2026-01-26"
  categories: "ai, sdk, streaming, react, nextjs"

Vercel AI SDK Development Skill

[PLACEHOLDER: Full SKILL.md content should be pasted here from the chat]

This skill provides comprehensive guidance for building AI applications with the Vercel AI SDK.

Core Concepts

  • Provider Layer (OpenAI, Anthropic, Google, etc.)
  • Core Layer (streamText, generateText, generateObject)
  • Framework Layer (React hooks, Next.js integration)

Installation

bash
pnpm add ai @ai-sdk/openai

Basic Usage

typescript
import { streamText } from 'ai'
import { openai } from '@ai-sdk/openai'

const result = await streamText({
  model: openai('gpt-4o'),
  messages: [{ role: 'user', content: 'Hello' }],
})

for await (const chunk of result.textStream) {
  process.stdout.write(chunk)
}

See full documentation in this file and in references/ directory.