Agent skill · Data & Analytics

vercel-ai-sdk-v5

Expert-level Vercel AI SDK v5 patterns for production chatbots. Use for: (1) Chat persistence with Drizzle/PostgreSQL, (2) Generative UI with typed tool parts, (3) Human-in-the-loop tool confirmations, (4) Custom data streaming with reconciliation, (5) Anthropic provider with extended thinking/reasoning, (6) Type-safe message metadata with token tracking. Covers advanced patterns only - assumes basic AI SDK knowledge. NOT for AI SDK v6.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill vercel-ai-sdk-v5-horuz-ai-claude-plugins-3 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 4 KB
Bundled scripts: none
Path: skills/ai-llm/vercel-ai-sdk-v5-horuz-ai-claude-plugins-3/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Vercel AI SDK v5 Production patterns for AI chatbots with persistence, generative UI, and streaming. ## Quick Reference | Need | Reference | |------|-----------| | Database schema & persistence | `references/persistence.md` | | Tools & generative UI | `references/tools-and-generative-ui.md` | | Custom data streaming | `references/streaming.md` | | Type definitions | `references/types.md` | | Anthropic + reasoning | `references/anthropic-config.md` | | Working examples | `cookbook/` directory | ## Core Architecture ### Message Flow ``` Client (useChat) → API Route (streamText) → DB (Drizzle) ↑ ↓ └── UIMessageStream ←┘ ``` ### Key Imports ```typescript // Core import { streamText, convertToModelMessages, UIMessage } from 'ai' import { createUIMessageStream, createUIMessageStreamResponse } from 'ai' // Client import { useChat } from '@ai-sdk/react' import { DefaultChatTransport } from 'ai' // Provider import { anthropic } from '@ai-sdk/anthropic' ``` ## Decision Tree ### Streaming Response Type - Simple text streaming → `streamText().toUIMessageStreamResponse()` - Need custom data parts → `createUIMessageStream()` + `writer.write()` - Need both → `createUIMessageStream()` + `writer.

What's inside
Steps it walks through
  1. Quick Reference
  2. Core Architecture
  3. Message Flow
  4. Key Imports
  5. Decision Tree
  6. Streaming Response Type
  7. Tool Execution Location
  8. Data Attachment
  9. Naming Convention
  10. File Organization
  11. Essential Patterns
  12. 1. Send Only Last Message
  13. 2. Persist on Finish
  14. 3. Handle Disconnects
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the vercel-ai-sdk-v5 skill do?

Expert-level Vercel AI SDK v5 patterns for production chatbots. Use for: (1) Chat persistence with Drizzle/PostgreSQL, (2) Generative UI with typed tool parts, (3) Human-in-the-loop tool confirmations, (4) Custom data streaming with reconciliation, (5) Anthropic provider with extended thinking/reasoning, (6) Type-safe message metadata with token tracking. Covers advanced patterns only - assumes basic AI SDK knowledge. NOT for AI SDK v6.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill vercel-ai-sdk-v5-horuz-ai-claude-plugins-3 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going