A hands-on workshop on building a Retrieval-Augmented Generation (RAG) application using Cloudflare Workers, Vectorize, D1, Workflows and Workers AI.
In this workshop, you’ll build a KnowledgeBase Assistant — a RAG-powered AI app that lets users upload content, ask questions about it, and receive context-aware answers grounded in their own documents.
In this hands-on project, you will:
- Create and deploy a Cloudflare Worker
- Add AI capabilities with Workers AI and AI Gateway
- Embed and search documents using Vectorize
- Store and retrieve metadata using D1
- Use Cloudflare Workflows to handle document processing and embedding
- Build a working Retrieval-Augmented Generation (RAG) app from scratch
- A free Cloudflare account
- Node.js (v18+) and npm installed
- Basic familiarity with JavaScript
- Wrangler CLI installed:
npm install -g wrangler
Clone the repo and install dependencies:
git clone https://github.com/lauragift21/cf-fullstack-ai-workshop.git
cd cf-fullstack-ai-workshop
npm install
Start the dev server:
wrangler dev
Deploy to Cloudflare:
wrangler deploy
- 🧱 Part 1: Cloudflare Workers Basics
- 🔗 Part 2: Integrating Hono Framework
- 🧠 Part 3: Add AI Capabilities
- 📄 Part 4: Uploading Documents & Automating with Workflows
- 💬 Part 5: Build the RAG Chat Endpoint
- 🚀 Part 6: Extra Enhancements
- Add Workers KV to cache responses
- Integrate external models (Anthropic/OpenAI)
- Deploy to a production domain