# ai-sdk-6-skills

This skill gives coding assistants patterns for AI SDK 6 Beta, covering agent loops and Groq setups. It speeds up migration from v5.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 481 installs · ★ 23
- Author: gocallum
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/gocallum/nextjs16-agent-skills/tree/HEAD/skills/ai-sdk-6-skills/SKILL.md
- Updated: 2026-01-21
- HTML: https://affpapa.org/en/nevibecode/skills/ai-sdk-6-skills

## What it does

This skill provides code patterns for AI SDK 6 Beta features. It details the `ToolLoopAgent` abstraction, which controls tool calling loops and keeps state. It also covers structured outputs via Zod and document reranking through Cohere. For sensitive actions, tools can require explicit user approval before running.

The guide outlines Groq provider setups for open-weight models. It includes Llama 3.3 configurations, reasoning formats, and multimodal inputs.

Beta releases break often. Lock package versions strictly in your dependencies so patch updates do not disrupt working code. Groq models also require a valid `GROQ_API_KEY`.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add gocallum/nextjs16-agent-skills --skill ai-sdk-6-skills -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/ai-sdk-6-skills/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/ai-sdk-6-skills/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add gocallum/nextjs16-agent-skills --skill ai-sdk-6-skills -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/ai-sdk-6-skills/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add gocallum/nextjs16-agent-skills --skill ai-sdk-6-skills -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/ai-sdk-6-skills/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install gocallum/nextjs16-agent-skills ai-sdk-6-skills
```

2. **Manually: put the files in place**
- File: `.github/skills/ai-sdk-6-skills/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add gocallum/nextjs16-agent-skills --skill ai-sdk-6-skills -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/gocallum/nextjs16-agent-skills --path skills/ai-sdk-6-skills
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/ai-sdk-6-skills/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add gocallum/nextjs16-agent-skills --skill ai-sdk-6-skills -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/gocallum/nextjs16-agent-skills/tree/HEAD/skills/ai-sdk-6-skills/SKILL.md

## When to use it
- migrate legacy agent workflows from AI SDK v5 to v6
- configure user confirmation prompts before executing sensitive tools
- build autonomous loops using ToolLoopAgent with structured outputs
- integrate Groq open-weight models into AI SDK workflows

## Example prompts
- Show me how to require user approval for a tool in AI SDK 6.
- Create a ToolLoopAgent setup with Groq Llama 3.3 and a structured output schema.
- Implement document reranking with Cohere using AI SDK v6 helpers.

## Similar
- [ai-sdk](https://affpapa.org/en/nevibecode/skills/vercel-ai-sdk.md) — skill · 66100 installs
- [workflow](https://affpapa.org/en/nevibecode/skills/vercel-inc-workflow.md) — skill · 5300 installs
- [vercel-development](https://affpapa.org/en/nevibecode/skills/vercel-development.md) — skill · 712 installs
- [ai-elements](https://affpapa.org/en/nevibecode/skills/ai-elements.md) — skill · 7 installs
- [ai-gateway](https://affpapa.org/en/nevibecode/skills/ai-gateway.md) — skill · 6 installs
- [huawei-cloud-openviking-embedding-switch](https://affpapa.org/en/nevibecode/skills/huawei-cloud-openviking-embedding-switch.md) — skill · 15900 installs

From the same set: [gocallum/nextjs16-agent-skills](https://affpapa.org/en/nevibecode/by/gocallum/nextjs16-agent-skills.md) — 7 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
