Getting it into your agent
There is no command for this one: it runs only inside a plugin, and the catalogue could not identify which plugin ships it. The source is linked below.
Wrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/majiayu000/claude-skill-registry/agent-builder-vercel-sdk)<a href="https://agentmods.dev/skills/majiayu000/claude-skill-registry/agent-builder-vercel-sdk"><img src="https://agentmods.dev/badge/skills/majiayu000/claude-skill-registry/agent-builder-vercel-sdk/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/majiayu000/claude-skill-registry/agent-builder-vercel-sdk"><img src="https://agentmods.dev/badge/skills/majiayu000/claude-skill-registry/agent-builder-vercel-sdk.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00039 | $0.02149 |
| Opus 5 | $0.00019 | $0.01074 |
| Sonnet 5 | $0.00008 | $0.00430 |
| Haiku 4.5 | $0.00004 | $0.00215 |
Grade A, and why
agent-builder-vercel-sdk scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
This is a copy
100% identical to agent-builder-vercel-sdk — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.
How it starts
The opening of the file, as written. The whole thing — 367 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Vercel AI SDK Agent Builder
Purpose
Create streaming AI chat interfaces with minimal code using Vercel AI SDK and OpenRouter provider.
When to Use
- Building Next.js frontend with chat UI
- Need streaming responses with SSE
- Want type-safe tool calling in TypeScript
- Switching between multiple AI providers
- Building agentic loops with stopWhen/prepareStep
Quick Start
Installation
npm install ai @openrouter/ai-sdk-provider zod
Environment Variables
OPENROUTER_API_KEY=sk-or-v1-...
NEXT_PUBLIC_SITE_URL=http://localhost:3000
Backend Setup (Route Handler)
Basic Chat Endpoint
// app/api/chat/route.ts
import { OpenRouter } from '@openrouter/ai-sdk-provider'
import { streamText } from 'ai'
const openrouter = new OpenRouter({
apiKey: process.env.OPENROUTER_API_KEY
})
export async function POST(req: Request) {
const { messages } = await req.json()
const result = streamText({
model: openrouter('openai/gpt-4o'),
system: 'You are a helpful assistant',
messages,
})
return result.toDataStreamResponse()
}
With Tool Calling
import { z } from 'zod'
import { tool } from 'ai'
const tools = {
generateImage: tool({
description: 'Generate images using AI',
parameters: z.object({
prompt: z.string().describe('Image description'),
numImages: z.number().min(1).max(10).default(1)
}),
execute: async ({ prompt, numImages }) => {
// Your implementation
const images = await generateImages(prompt, numImages)
return { images }
}
})
}
export async function POST(req: Request) {
const { messages } = await req.json()
const result = streamText({
model: openrouter('openai/gpt-4o'),
system: 'You are a helpful assistant',
messages,
tools,
maxSteps: 5 // Enable agentic loop
})
return result.toDataStreamResponse()
}
Frontend Integration
Using useChat Hook
'use client'
import { useChat } from 'ai/react'
export default function Chat() {
const { messages, input, handleInputChange, handleSubmit, isLoading } = useChat()
return (
<div className="flex flex-col h-screen">
{/* Messages */}
<div className="flex-1 overflow-y-auto p-4">
{messages.map(m => (
<div key={m.id} className={m.role === 'user' ? 'text-right' : 'text-left'}>
<div className="inline-block p-3 rounded-lg">
{m.content}
</div>
</div>
))}
</div>
{/* Input */}
<form onSubmit={handleSubmit} className="p-4 border-t">
<input
value={input}
onChange={handleInputChange}
placeholder="Type a message..."
disabled={isLoading}
className="w-full px-4 py-2 border rounded"
/>
</form>
</div>
)
}
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 367 lines · 39 tokens per session scan A bfc9f41948a7
agent-builder-vercel-sdk is a skill published in the GitHub repository majiayu000/claude-skill-registry (604 stars, last pushed yesterday), licensed MIT. It adds 39 tokens to every session and 2,149 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 100% identical to agent-builder-vercel-sdk, differing in 0 lines, and is treated as a copy.
Other skills, from other repositories
prompt-testing
Use this skill when you need to test prompt behavior, regression risk, and output boundaries across versions; triggers include prompt testing.
agent-platform-prompt-management
Manages and orchestrates prompts in Agent Platform. Use when you need to create, list, retrieve, version, or delete managed prompts in Agent Platform. Don't use for model training, model deployment to endpoints, or managing non-Agent Platform prompts.
claude-api-in-prototypes
Call Claude from your HTML artifacts via window.claude.complete.
gemini-api-dev
Use this skill when writing code that calls the Gemini API for text generation, multi-turn chat, multimodal understanding, image generation, video generation, streaming responses, background research tasks, function calling, structured output, or migrating from the old generateContent API. Covers SDK usage and best…
baoyu-imagine
AI image generation with OpenAI GPT Image 2, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream and Replicate APIs. Supports text-to-image, reference images, aspect ratios, and batch generation from saved prompt files. Sequential by default; use batch parallel generation when the…
prompt-lab
LLM prompt engineering: analyzes failure modes, generates variants (direct, few-shot, CoT), designs rubrics, produces test suites. Triggers on: "prompt engineering", "generate prompt variants", "A/B test prompts", "optimize prompt", "improve this prompt". NOT for SKILL.md files, use skill-evaluator.