Cloudflare Workers AI moves from beta to general availability — enabling server administrators to run AI inference at Cloudflare's global edge network without any GPU infrastructure management.
How Workers AI Works
Workers AI runs AI models in Cloudflare's data centres at the edge — requests are processed at the nearest location to the user, reducing latency dramatically compared to centralised AI APIs.
Available Models
# Text generation
@cf/meta/llama-3-8b-instruct
@cf/mistral/mistral-7b-instruct-v0.1
@hf/google/gemma-7b-it
# Text embeddings
@cf/baai/bge-large-en-v1.5
# Image classification
@cf/microsoft/resnet-50
# Speech to text
@cf/openai/whisper
Integration Example
// Workers AI in a Cloudflare Worker
export default {
async fetch(request, env) {
const ai = new Ai(env.AI);
const response = await ai.run('@cf/meta/llama-3-8b-instruct', {
messages: [
{ role: 'system', content: 'You are a server administration assistant' },
{ role: 'user', content: await request.text() }
]
});
return new Response(JSON.stringify(response));
}
};
Use Cases for Server Administrators
- Smart error pages — AI explains server errors to users
- Log summarisation — AI processes logs before sending alerts
- Bot detection — AI classifies suspicious traffic patterns
- Content moderation — AI screens user uploads at the edge
Pricing
# Workers AI pricing (approximate)
Llama 3 8B: $0.011 per 1000 tokens (Workers Paid plan)
Free tier: 10,000 neurons/day included
Neurons: Cloudflare's unit of AI compute
Conclusion
Cloudflare Workers AI removes GPU infrastructure complexity entirely. Our team integrates Cloudflare and AI tools into server architectures for clients worldwide.
Comments