cloudflare-workers-ai
Run LLMs and AI models on Cloudflare's global GPU network with Workers AI. Includes Llama, Flux image generation, BGE embeddings, and streaming support with AI Gateway for caching and logging. Use when: implementing LLM inference, generating images with Flux/Stable Diffusion, building RAG with embeddings, streaming AI responses, using AI Gateway for cost tracking, or troubleshooting AI_ERROR, rate limits, model not found, token limits, or neurons exceeded. ai inference, cloudflare llm, ai streaming, text generation ai, ai embeddings, image generation ai, workers ai rag, ai gateway, llama worke
npx skills add majiayu000/claude-skill-registry --skill cloudflare-workers-ai --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Cloudflare Workers AI - Complete Reference Production-ready knowledge domain for building AI-powered applications with Cloudflare Workers AI. **Status**: Production Ready ✅ **Last Updated**: 2025-10-21 **Dependencies**: cloudflare-worker-base (for Worker setup) **Latest Versions**: wrangler@4.43.0, @cloudflare/workers-types@4.20251014.0 --- ## Table of Contents 1. [Quick Start (5 minutes)](#quick-start-5-minutes) 2. [Workers AI API Reference](#workers-ai-api-reference) 3. [Model Selection Guide](#model-selection-guide) 4. [Common Patterns](#common-patterns) 5. [AI Gateway Integration](#ai-gateway-integration) 6. [Rate Limits & Pricing](#rate-limits--pricing) 7. [Production Checklist](#production-checklist) --- ## Quick Start (5 minutes) ### 1. Add AI Binding **wrangler.jsonc:** ```jsonc { "ai": { "binding": "AI" } } ``` ### 2. Run Your First Model ```typescript export interface Env { AI: Ai; } export default { async fetch(request: Request, env: Env): Promise<Response> { const response = await env.AI.run('@cf/meta/llama-3.1-8b-instruct', { prompt: 'What is Cloudflare?', }); return Response.json(response); }, }; ``` ### 3. Add Streaming (Recommended) ```typescript const stream = aw
- Table of Contents
- Quick Start (5 minutes)
- 1. Add AI Binding
- 2. Run Your First Model
- 3. Add Streaming (Recommended)
- Workers AI API Reference
- env.AI.run()
- Text Generation Models
- Text Embeddings Models
- Image Generation Models
- Vision Models
- Model Selection Guide
- Text Generation (LLMs)
- Text Embeddings
npm install workers-ai-provider ai
What does the cloudflare-workers-ai skill do?
Run LLMs and AI models on Cloudflare's global GPU network with Workers AI. Includes Llama, Flux image generation, BGE embeddings, and streaming support with AI Gateway for caching and logging. Use when: implementing LLM inference, generating images with Flux/Stable Diffusion, building RAG with embeddings, streaming AI responses, using AI Gateway for cost tracking, or troubleshooting AI_ERROR, rate limits, model not found, token limits, or neurons exceeded. ai inference, cloudflare llm, ai streaming, text generation ai, ai embeddings, image generation ai, workers ai rag, ai gateway, llama worke
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill cloudflare-workers-ai --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.
