Demos and architectures
Learn how you can use Workers within your existing application and architecture.
Explore the following demo applications for Workers.
- Gamertown Customer Support Assistant: A RAG based AI Chat app that uses Vectorize to access video game data for employees of Gamertown.
- shrty.dev: A URL shortener that makes use of KV and Workers Analytics Engine. The admin interface uses Function Calling. Go Shorty!
- Homie - Home Automation using Function Calling: A home automation tool that uses AI Function calling to change the color of lightbulbs in your home.
- Hackathon Helper: A series of starters for Hackathons. Get building quicker! Python, Streamlit, Workers, and Pages starters for all your AI needs!
- Multimodal AI Translator: This application uses Cloudflare Workers AI to perform multimodal translation of languages via audio and text in the browser.
- Floor is Llava: This is an example repo to explore using the AI Vision model Llava hosted on Cloudflare Workers AI. This is a SvelteKit app hosted on Pages.
- Workers AI Object Detector: Detect objects from a webcam in a Cloudflare Worker web app with detr-resnet-50 hosted on Cloudflare using Cloudflare Workers AI.
- JavaScript-native RPC on Cloudflare Workers <> Named Entrypoints: This is a collection of examples of communicating between multiple Cloudflare Workers using the remote-procedure call (RPC) system that is built into the Workers runtime.
- Workers for Platforms Example Project: Explore how you could manage thousands of Workers with a single Cloudflare Workers account.
- Whatever-ify: Turn yourself into...whatever. Take a photo, get a description, generate a scene and character, then generate an image based on that calendar.
- Cloudflare Workers Chat Demo: This is a demo app written on Cloudflare Workers utilizing Durable Objects to implement real-time chat with stored history.
- Phoney AI: This application uses Cloudflare Workers AI, Twilio, and AssemblyAI. Your phone is an input and output device.
- Vanilla JavaScript Chat Application using Cloudflare Workers AI: A web based chat interface built on Cloudflare Pages that allows for exploring Text Generation models on Cloudflare Workers AI. Design is built using tailwind.
- Turnstile Demo: A simple demo with a Turnstile-protected form, using Cloudflare Workers. With the code in this repository, we demonstrate implicit rendering and explicit rendering.
- Wildebeest: Wildebeest is an ActivityPub and Mastodon-compatible server whose goal is to allow anyone to operate their Fediverse server and identity on their domain without needing to keep infrastructure, with minimal setup and maintenance, and running in minutes.
- D1 Northwind Demo: This is a demo of the Northwind dataset, running on Cloudflare Workers, and D1 - Cloudflare's SQL database, running on SQLite.
- Multiplayer Doom Workers: A WebAssembly Doom port with multiplayer support running on top of Cloudflare's global network using Workers, WebSockets, Pages, and Durable Objects.
- Queues Web Crawler: An example use-case for Queues, a web crawler built on Browser Rendering and Puppeteer. The crawler finds the number of links to Cloudflare.com on the site, and archives a screenshot to Workers KV.
- DMARC Email Worker: A Cloudflare worker script to process incoming DMARC reports, store them, and produce analytics.
- Access External Auth Rule Example Worker: This is a worker that allows you to quickly setup an external evalutation rule in Cloudflare Access.
Explore the following reference architectures that use Workers:
- Cloudflare Security Architecture : This document provides insight into how this network and platform are architected from a security perspective, how they are operated, and what services are available for businesses to address their own security challenges.
- Composable AI architecture : The architecture diagram illustrates how AI applications can be built end-to-end on Cloudflare, or single services can be integrated with external infrastructure and services.
- Retrieval Augmented Generation (RAG) : Retrieval-Augmented Generation (RAG) is an innovative approach in natural language processing that integrates retrieval mechanisms with generative models to enhance text generation.
- Automatic captioning for video uploads : By integrating automatic speech recognition technology into video platforms, content creators, publishers, and distributors can reach a broader audience, including individuals with hearing impairments or those who prefer to consume content in different languages.
- Ingesting BigQuery Data into Workers AI : You can connect a Cloudflare Worker to get data from Google BigQuery and pass it to Workers AI, to run AI Models, powered by serverless GPUs. This will allow you to enhance data with AI-generated responses, such as detecting the sentiment score of some text or generating tags for an article. This document describes a simple way to get started if you are looking to give Workers AI a try and see how the new and different AI models would perform with your data hosted in BigQuery.
- Extend ZTNA with external authorization and serverless computing : Companies using Zero Trust Network Access (ZTNA) services build policies to determine if a user can access a protected resource such as a privately hosted Wiki server or source code repository. Policies typically use group membership, authentication methods, device security posture to determine which users can access which resources.
- A/B-testing using Workers : A/B testing, also known as split testing, is a fundamental technique in the realm of web development, allowing teams to iteratively refine and optimize their digital experiences. A/B testing involves comparing two versions of a web page or app feature to determine which one performs better in achieving a predefined goal, such as increasing conversions, engagement, or user satisfaction.
- Fullstack applications : Full-stack web applications leverage a combination of frontend and backend technologies, collectively forming a stack that powers the entire application. This technology stack encompasses various tools, frameworks, and languages, each serving a specific purpose within the development ecosystem.
- Serverless ETL pipelines : Extract, Transform, Load (ETL) pipelines are a cornerstone in the realm of data engineering, facilitating the seamless flow of data from its raw state to a structured, usable format. ETL pipelines are instrumental in the data processing journey, particularly in scenarios where data needs to be collected, cleansed, and transformed before being loaded into a target destination.
- Serverless global APIs : Serverless APIs represent a modern approach to building and deploying scalable and reliable application programming interfaces (APIs) without the need to manage traditional server infrastructure. These APIs are designed to handle incoming requests from users or other systems, execute the necessary logic or operations, and return a response, all without the need for developers to provision or manage underlying servers.
- Serverless image content management : In this reference architecture diagram, we reveal how to leverage various components of Cloudflare’s ecosystem to construct a scalable image management solution. This solution integrates moderation principles via Cloudflare’s Workers AI platform and performs image classification through inference at the edge. The storage of images is handled by Cloudflare’s R2 product, an S3 API-like object storage system, while metadata is stored in a key/value store to enable content augmentation.
- Egress-free object storage in multi-cloud setups : Object storage is a modern data storage approach that stores data as objects rather than in a hierarchical structure like traditional file systems, making object storage highly scalable and flexible for managing vast amounts of data across diverse applications and environments.