Building a Personal AI Agent on Cloudflare's Free Tier — the Talorys Architecture
By Arash Latifi
The open-source Talorys project shows how to run a full personal AI assistant — chat, memory, tasks, automations — inside your own Cloudflare account with no server, no database, no subscription.
TL;DR — Talorys, an open-source personal AI agent that hit the HN front page on October 10 (301 points, 137 comments when I checked), demonstrates that a full agent — streaming chat, durable memory, tasks, scheduled automations — fits on Cloudflare's free plan: Pages for the frontend, a private Worker for the API, a Durable Object with SQLite for data and scheduling, and Workers AI for the chat model.
The architecture: four services, zero paid ones
From the project's official README:
Browser ──HTTPS──▶ Cloudflare Pages (React + /api Pages Function)
│ service binding (no public URL)
▼
Private Worker (Hono router)
│ getAgentByName("personal-agent")
▼
Durable Object (Cloudflare Agents SDK)
├─ SQLite: conversations, memories, tasks, automations
├─ Workers AI: @cf/zai-org/glm-4.7-flash
└─ Alarms: reminders and recurring schedules
| Cloudflare service | Role | Free plan | | --- | --- | --- | | Pages | Frontend + Pages Function | Yes | | Workers | Private API Worker | Yes | | Durable Objects (SQLite) | All data + alarm scheduling | Yes | | Workers AI | Chat model | Yes, daily allocation |
Details worth stealing for your own builds:
- The Worker has no public URL. It deploys with
workers_dev: false; the browser only talks to the*.pages.devsite, and/api/*requests are forwarded via a service binding. The API simply isn't reachable from the open internet. - Auth lives in the Worker, not the frontend. The owner password is hashed locally with PBKDF2-SHA256 and stored only as a Cloudflare secret.
- Chat streams as SSE end-to-end through the whole chain.
- Durable Object alarms power reminders — nothing has to stay online to run a schedule. No external cron.
Does the free plan actually hold up?
Workers AI is billed in a unit called Neurons. Per the official pricing docs (updated October 9, 2026):
- Price: $0.011 per 1,000 Neurons
- Free plan: 10,000 Neurons per day at no charge
- Beyond that requires the Workers Paid plan
For single-person daily use — chat, summaries, a few tool calls — that fits comfortably. Push it to heavy or multi-user workloads and you'll hit the ceiling fast. Talorys plans for this: tasks, notes, memories and reminders keep working if Workers AI is unavailable or the free quota is exhausted.
The best part of the HN thread: what "self-hosted" means
The maker framed it as "without relying on someone else's hosted service." The comments immediately pounced — "So instead of relying on someone's hosted service, this is relying on someone's 4 hosted services?" — with one dry classic: "Where do I download cloudflare?"
The debate has a practical lesson. When your architecture holds personal data (memories, tasks, conversations), the right questions aren't "is it on my own metal?" but:
- Where is data stored? (Here: SQLite inside your own Durable Object, exportable.)
- Who holds access keys? (Here: only your account's secrets.)
- If the platform repriced or shut down, how hard is the migration? (Here: the Hono logic is portable, but the Durable Object is a hard coupling to Cloudflare.)
"Self-owned on a cloud platform" is the honest label — not self-hosted in the classic sense.
Building your own — checklist
- [ ] Cloudflare account, Node.js 22+ (Wrangler ships bundled)
- [ ] Create a Durable Object with the SQLite backend; keep all state there, not in scattered KV
- [ ] Deploy the Worker with
workers_dev: falseand reach it from a Pages Function via a service binding - [ ] Call Workers AI through a binding and stream SSE back
- [ ] Implement reminders with
alarm(), not an external cron - [ ] Surface the daily Neuron quota in the UI so users know when the free allocation runs out
- [ ] Test the degraded no-AI mode — tasks and notes must work without the model
When to reach for this pattern
Anywhere you need durable state + scheduling + streaming and don't want to babysit a server: internal tools, personal dashboards, notification bots. It's a genuine low-cost alternative to VPS + managed DB + cron — with the tradeoff that your lock-in is Cloudflare's primitives rather than your own infrastructure.
FAQ
Q: Is the free plan viable for production?
For a single user, yes — that's Talorys's explicit design goal: single-user, no signup, no teams. For a multi-user product you'd need to seriously model Workers AI and Durable Object limits and likely land on a paid plan.
Q: Where does my data actually live?
In SQLite inside a Durable Object in your own Cloudflare account. The developer operates no server or database at all — there's no backend of theirs in the path.
Q: Which model does it use, and why not a big one?
@cf/zai-org/glm-4.7-flash, a lightweight model in the Workers AI catalog. For a personal assistant with simple tools (tasks, memory, reminders) it's enough; heavy reasoning is where you'll feel the limit.