Validate and debug Vercel AI SDK provider configurations including API keys, environment setup, model compatibility, and rate limiting. Use when encountering provider errors, authentication failures, API key issues, missing environment variables, model compatibility problems, rate limiting errors, or when user mentions provider setup, configuration debugging, or SDK connection issues.
/plugin marketplace add vanman2024/ai-dev-marketplace/plugin install vercel-ai-sdk@ai-dev-marketplaceThis skill is limited to using the following tools:
README.mdexamples/troubleshooting-guide.mdscripts/check-model-compatibility.shscripts/generate-fix.shscripts/test-provider-connection.shscripts/validate-provider.shtemplates/env-template.txttemplates/error-handler-template.tstemplates/gitignore-template.txtPurpose: Autonomously validate, diagnose, and fix Vercel AI SDK provider configurations.
Activation Triggers:
Key Resources:
scripts/validate-provider.sh - Full validation (packages, keys, env)scripts/check-model-compatibility.sh - Validate model namesscripts/generate-fix.sh - Generate fixes for common issuesscripts/test-provider-connection.sh - Test real API connectionexamples/troubleshooting-guide.md - Comprehensive troubleshooting (10+ scenarios)templates/ - .env, .gitignore, error handler code templatesIdentify error from symptoms:
# Main validation - checks everything
./scripts/validate-provider.sh <provider>
# Examples:
./scripts/validate-provider.sh openai
./scripts/validate-provider.sh anthropic
Checks performed:
ai) installed./scripts/check-model-compatibility.sh <provider> <model>
# Examples:
./scripts/check-model-compatibility.sh openai gpt-4o
./scripts/check-model-compatibility.sh anthropic claude-sonnet-4-5-20250929
Shows valid models if name is wrong, suggests closest matches.
./scripts/generate-fix.sh <issue-type> <provider>
# Issue types:
# - missing-api-key → Creates .env with correct format
# - wrong-format → Shows valid key format
# - missing-package → Installs provider package
# - model-compatibility → Lists valid models
# - rate-limiting → Adds retry helper with exponential backoff
# - import-error → Fixes import statements
# Verify API credentials work
./scripts/test-provider-connection.sh <provider>
Makes real API call with minimal tokens to verify setup.
OpenAI:
@ai-sdk/openaiOPENAI_API_KEYsk-proj-... or sk-...Anthropic:
@ai-sdk/anthropicANTHROPIC_API_KEYsk-ant-api03-...Google:
@ai-sdk/googleGOOGLE_GENERATIVE_AI_API_KEYAIza...xAI:
@ai-sdk/xaiXAI_API_KEYxai-...# Create .env with correct structure
./scripts/generate-fix.sh missing-api-key openai
# Then add actual key from provider dashboard
# Check valid models
./scripts/check-model-compatibility.sh anthropic claude-v3-opus
# Shows: Did you mean? → claude-opus-4-20250514
# Generate retry helper
./scripts/generate-fix.sh rate-limiting openai
# Creates retryHelper.ts with exponential backoff
# Install provider package
./scripts/generate-fix.sh missing-package anthropic
# Runs: npm install ai @ai-sdk/anthropic
Scripts: All scripts in scripts/ directory are executable and documented in README.md
Templates: templates/ contains .env, .gitignore, and error-handler-template.ts
Examples: examples/troubleshooting-guide.md has detailed solutions for 10+ scenarios including CORS, streaming, TypeScript, and provider-specific issues
Supported Providers: OpenAI, Anthropic, Google, xAI, Groq, Mistral, Cohere, DeepSeek
Version: 1.0.0 SDK Compatibility: Vercel AI SDK 5+
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.