1. OpenAI Dots, Open-Source
โถ 0:00OpenAI recently released dots โ always-on agents, each specialized in a use case: a research assistant, a personal assistant with access to your email and calendar, and so on. They perform tasks for you and ping you when something matters. This tutorial shows how to build the same thing with open-source models, hosted on your own always-on machine โ a VPS, a home desktop you leave running, or a DGX Spark if you want to run the models locally.
The architecture is explicitly inspired by what Hermes and OpenClaw do with a message gateway. By the end you have two agents: Andre, a research agent with Firecrawl tools and a research-assistant system prompt, and Bunny, a personal assistant powered by the Space Bunny model with access to Gmail and Calendar โ able to read email, triage an inbox, and create calendar events. You can create as many as you want, give each its own tools, and run them on your own keys with any model.
2. Agents Are Just Directories
โถ 1:55The elegant core of the setup: an agent is just a directory. Inside an agents folder, each agent is its own directory containing an AGENTS.md file โ the context that tells the agent what it is โ plus its skills. The personal assistant's AGENTS.md says it helps organize work with Google Workspace through the Google Workspace CLI, so it can read and summarize email, create calendar events, and send messages. The research agent gets a different personality and different tools.
The harness shown is Tau, Hugging Face's Python port of Pi's minimalist coding agent โ and you can do the same in Pi itself. Because Pi works per-directory, each agent runs with the skills, tools, and context defined in its own folder, which is what gives every agent its own isolated "computer."
3. Skills and Google Workspace Access
โถ 3:49Skills are added with npx skills add, pulling from the Google Workspace CLI โ calendar and agenda access, Google Drive read and upload, and full email handling. The install is scoped to the specific agent's project and symlinked in, so only that agent gains the abilities. The same mechanism adds Firecrawl scrape and search skills so the assistant can search the web.
The Google Workspace CLI itself is the heavyweight here โ a single command-line tool for Drive, Gmail, Calendar, Sheets, Docs, and more, dynamically built from Google's Discovery Service and shipping AI agent skills. Live it sits at 31,236 stars, Apache-2.0, Rust.
4. Testing the Personal Assistant
โถ 5:20With the skills installed, the assistant already works locally: ask "what are the recent unread emails in my inbox" and it reads Gmail and answers. The point of the whole exercise, though, is that you should not have to SSH or connect through Herdr every time you want an answer โ which is why the next step is wiring it to Telegram so you can text it from your phone.
Each agent is then an independent, always-reachable worker: the personal assistant knows your email and calendar, and a separate research agent can be given a different model and a different toolset later.
5. The Message Gateway and Session Routing
โถ 7:12This is the piece that made Hermes and OpenClaw click for people: a message gateway โ a background process on the always-on machine that listens for messages across platforms (Telegram, WhatsApp, email, Slack). You talk to your assistant through the same apps you use to talk to humans, instead of a terminal. This tutorial's gateway supports Telegram today, with other platforms left as future work.
The routing is simple and clever. When Telegram sends a message, the gateway builds an ID from three parts: the source (Telegram), the agent name, and the Pi session ID. That ID is stored in a local SQLite database. If no session exists for that key, the gateway creates one; on the next message it recognizes the same session and routes it to the matching Pi session in that agent's directory โ so the message runs with the right skills and context. Sending /new in Telegram creates a fresh session entry, letting you start a new conversation without touching the server.
6. Installing pi-gateway and Wiring Telegram
โถ 11:42The gateway is pi-gateway โ a deliberately minimalist gateway, about 34 commits to reach its current state, installed with uv tool install pi-gateway and initialized with pi gateway init inside the agent's directory. A fair caveat for anyone adopting it: it is a young personal project, currently 4 stars with no license file โ fine for a tutorial, but check the repo before building production on it.
Telegram setup runs through BotFather: /newbot to create a bot (he names his "Bunny"), which returns a token you paste into the gateway. Critically, you also configure an allowlist โ your Telegram user ID (looked up via a user-info bot) โ so only you can contact the agent. Then the gateway asks which directory the session should run in, which model to use (Space Bunny via OpenRouter), the thinking level, and a name for the instance.
7. Starting the Gateway and Chatting
โถ 15:03Start the instance with pi gateway start -i bunny, then check pi gateway status and list running bots with pi gateway instances. From there it is just a Telegram conversation: hit start on the bot, ask "who are you and what are you capable of doing?", and the personal assistant answers from a terminal harness running on the VPS, with access to Gmail, Calendar, Drive, and contacts. You can now text it every day.
Two features are worth noting for the road map. The gateway runs as a background process, so the assistant stays reachable even when you are away from the machine. And because it is your own stack, the obvious extension is automations โ schedule a morning job that checks email, summarizes it, and organizes the inbox before you are even awake.
8. The Research Agent and Where to Extend
โถ 16:56The second agent is created the same way: initialize a new bot, name it "Andre", point it at the researcher directory, and pick a different model โ Kimi K3 โ then start it with pi gateway start -i andre. Now Andre is a research agent with Firecrawl available, and the two instances (Bunny and Andre) run side by side, each specialized and each reachable from your phone.
The recap lands the "dots" comparison: every agent has its own computer because it has its own workspace, where it can create files, write, and perform research โ just like OpenAI's dots, except the model, the tools, and the hosting are yours. The homework is concrete: add more tools via MCP or custom tools, explore the pi-gateway repo and add your own platforms (WhatsApp, email), and when you do, take inspiration from open-source gateways that already solve it โ OpenClaw and Hermes.
Key Takeaways
- An agent is just a directory. An
AGENTS.mdfile plus skills and tools โ and Pi runs per-directory, so each agent gets an isolated workspace. - The message gateway is the magic. A background process that listens on Telegram and routes messages to the right Pi session is what makes an assistant "always on" in your pocket.
- Session routing is three-part IDs in SQLite โ source, agent name, and Pi session ID โ with
/newspawning a fresh conversation. - Google Workspace CLI gives a personal assistant real powers โ Gmail, Calendar, Drive โ installed as skills via
npx skills add, scoped to one agent. - Any model per agent: Space Bunny for the personal assistant, Kimi K3 for the research agent, all through OpenRouter.
- Allowlist your Telegram user ID so only you can reach the agent โ a small but important security step.
- pi-gateway is a young personal project (4 stars, no license) โ good for a tutorial, worth a license check before production.
- The roadmap writes itself: scheduled automations, more platforms, and more tools via MCP โ with Hermes and OpenClaw as the reference implementations.
Timestamp Index
- 0:00 โ Build your own open-source dots
- 1:55 โ Always-on agents and workspaces
- 3:49 โ Skills and Google Workspace access
- 5:20 โ Testing the personal assistant
- 7:12 โ Message gateway architecture
- 11:42 โ Installing pi-gateway
- 12:43 โ Connecting Telegram and configuring
- 15:03 โ Starting the gateway and chatting
- 16:56 โ Research agent with Kimi K3
- 19:09 โ Recap and extensions