FodyChat

Articles

Engineering notes from building FodyChat: per-user data access, prompt-injection defense, file attachments, self-hosting and a portable core.

  1. We built four chats. Obviously, that was the sensible thing to do.

    How a tiny hotel FAQ chat multiplied into four parallel chat implementations—and how we finally made them share a component.

  2. How we gave an AI chat safe access to one user's data — without leaking everyone else's

    A signed, short-lived token plus a small contextParams trick lets a chatbot answer "what's my balance?" from live data without ever trusting the language model with identity.

  3. You can't fully stop prompt injection. Here's the layered defense we built instead.

    I talked a business chat into writing Python with nothing but persuasion. That's why we ship the rule we do: the prompt is not the security boundary — the architecture is.

  4. Files in an embeddable AI chat: two buttons, a presigned URL, and a malware scanner

    How FodyChat added guest file uploads, operator file exchange across Telegram/Slack/email, customer-owned storage, and large-file presigned uploads — and where the transcription actually belongs.

  5. Self-hosting, honestly: from a Cloudflare account to a docker compose up

    What 'self-host' actually means for an AI chat — and the ports-and-adapters work that turned it from a pricing-page promise into a real Docker image.

  6. From vendor lock-in to a portable core

    We built on Cloudflare Workers, D1, R2, KV and Vectorize. Then we drew ports through the codebase so the product could run anywhere. Here is the honest status.