📱

Get Our Mobile App

Take your business learning on the go!

Download on the App StoreGet it on Google Play

OpenClaw Multi-Agent System (Full Tutorial)

Openclaw Labs1:04:57

Transcription

Open Claw is one of the most powerful tools available right now. It's also one of the most misunderstood because everyone shows you how to install it, but nobody is showing you how to actually build with it, and that changes today. Here's what I see happening over and over again. Someone hears about Open Claw, they get excited, they install it, and then they spend 3 hours debugging trying to figure it out and never actually build anything. Or they get one agent working and it's kind of cool, but it's not improving their life or business in any real way. That's not an Open Claw problem. That's a setup problem and a strategy problem.

So in this video, we're doing the whole thing from scratch, no assumptions about what you already know. We're going to get Open Claw installed and configured properly. We're going to set it up in Slack so you can message it remotely, and I'll show you two ways to set up memory. We'll start with native memory and then add in QMD and lossless cloth. And then we're going to build your first multi-agent setup. Not just one agent talking to itself, but a real system where agents have roles, they hand off tasks, and they produce results you can use. And we will build the system out so they can complete long-running tasks without your intervention.

By the end of this, you're not going to have a chatbot, you're going to have a real workforce, and you'll understand how you can create more of these for yourself. So some quick context on who I am and why I'm the person walking you through this. I'm a software engineer and I built out a free school community where I've been documenting everything, what works, what breaks, what actually moves the needle. And this isn't a "let me read the docs" at you tutorial. Everything in this video I've personally built out and tested.

Here's what we're covering today. Part one, setup. Getting Open Claw installed, configured, and stable. We'll be doing this on a Mac Mini. Part two, I'll show you how to set up memory using the native memory, but also how to set up QMD and lossless cloth for improved memory and context. We'll also go over how to navigate the configuration and file structure. And then part three will be your first multi-agent system. We're going to build an orchestrator with dedicated sub-agents. I'll show you roles, routing, memory, and we'll walk through a real use case so you can see exactly how it runs.

This video is long, and I want it to be because I'm not going to cut corners and leave you stuck. I'm going to debug issues as they come up so you can see how to approach these problems on your own. If you're brand new to this, I'd recommend watching start to finish because the multi-agent sections build directly on the setup choices we make at the beginning. Stick around for part three especially because the way I structure these agent teams is different from what you'll see in most tutorials, and it's the thing that actually makes these systems run on their own. And if you want to go deeper, I will post a companion PDF for this video in my community on school. It'll have prompts, guides, breakdowns, and more documentation. So make sure to join and get the resources because they will help answer any questions that you might have. And if you get value from this, hit subscribe. I post every week on Open Claw multi-agent systems and how to use this stuff to build a real advantage. All right, let's get into it.

Okay, guys, we're starting on a completely fresh Mac Mini. I have some recording software installed on here, but that's about it. And from there, we're going to install a completely fresh instance of Open Claw, and then we're going to build out our first multi-agent system, which I have mapped out right here. And essentially, we'll have a CTO agent that we can speak with directly, an orchestrator agent that delegates tasks to three sub-agents, and those sub-agents will be a back-end agent, an iOS agent, or a front-end agent in our case, and then a QA agent. And those will perform Ralph loops so that they can do long-running tasks, and I'll talk a little bit more about that coming up.

Okay, so the first thing we need to do is install Visual Studio Code, which I already have here, but just to kind of show you how to do that, you'll just go to Visual or type in Visual Studio Code into Google. You can go to their website and click download for Mac OS. This is going to be really great because it's going to allow us to edit our files. It's going to allow us to see our folder structure easier. And essentially, what it is, it's called an IDE, and it essentially allows us to manage files, and it's used for like coding projects often. And let's see. We're not going to do that right now. So this is what it looks like, and it'll make more sense in a second once we get Open Claw installed.

So we're going to go to our terminal, and this is where we're going to install Open Claw. We're going to go back to Chrome, type in Open Claw. We're going to. Looks like there's some sponsored results. Be careful because you don't want to download something from someone pretending to be Open Claw. And then we're going to go to Open Claw .ai, and this is the one-line command that lets us install Open Claw on our machine. So we're going to go back into our terminal. We're going to paste that here. You can see I just clicked the copy button right there. And we're going to paste that into our terminal. And it installs. So we're going to wait a second and see. This might take a minute. And there we go. All right.

So now we can see we have gateway, gateway auth. Generate and configure gateway auth token now? Yes, we want to do this. This is important for security. Um, we we also want to do this. This seems to be a new security setting. Important. Um, yes. Enable GS H shell completion for Open Claw? Yes. Install gateway service now? Yes. Yes, we want to use node. And now we wait. Now we will get this Open Claw setup walk-through, and you'll see the first step is a security warning. So make sure to go through that. Um, for now, we're just going to click yes, I understand this. And we will do setup mode quick start. We will do config handling use existing values. And then we're going to go to Anthropic, um, because that is the model provider that I'm going to use for setup. I like to use um Opus to set up Open Claw because Opus is the best model to use. It is expensive, but for setup, um, I think it's important to use like the most capable model.

Then from here, what we're going to do is select Anthropic API key. And I'm going to paste in my API key there. And then we can scroll through here and select the models we want to use. And I'm going to do Opus 46 to start with. And I just clicked enter. And then we are going to set up Slack. So we're going to Slack set socket mode. And we will do modify settings. And enter Slack bot token. So in here, we'll go to api.slack.com, create an app. And we will click from scratch. And then we will give it an app name and an app name. So I'll just call it Open Claw bot. And I'll select the workspace that I've already created. And we'll create an app. Then I'll scroll down to OAuth and permissions. And I'm going to give it the permissions that I want it to have. So add OAuth scope. I want it to have chat, write, app mentions read. And I also want it to have channel channels history. So those are the permissions that we're going to need to get started with. And then we're going to go to install to Open Claw workspace or whatever your workspace is called. We'll click allow. And from there, we can get our bot token. And so we're just going to copy this. And then go back here where it says enter Slack bot token, click enter. Slack bot token already configured. I might have already set one up earlier, but we're going to set up a new one. And then I'm just going to paste my Slack bot token. Click enter. And then enter Slack app token. So we're going to need an app token as well. And we will go into our basic information page. We're going to click generate tokens and scopes. Add scope, connections write. And then we're going to give it a name so socket. Um, we'll just call it socket token. And we're going to generate. And then we're going to copy that. So then once we copy that, we will go in here. It says Slack app token already configured. That's because I already have one configured for this. But so we're going to set up a new one for now. And then enter Slack app token, and I'll paste that in.

So the other thing we're going to need to to add is go to app home. And [snorts] you're going to click this checkbox right here, which will allow us to send messages. Okay, so we also need to go to socket mode. And we should turn on enable socket mode. And then we'll go back to event subscriptions and we'll enable event subscriptions. And then we're going to go to subscribe to bot events. And we can enable any kind of subscriptions that we want. So we want message.im. We'll save those changes. And then we need to go back to OAuth and permissions. We need to reinstall to Open Claw workspace. Click allow. And okay, we're looking pretty good. Update Slack channels access. >> [clears throat] >> Yes. Allow list. Um, Slack channels allow list. Enter. And there we go. And now we're going to click a search provider. And we'll do Brave search for now. So Brave search is going to allow us to search the internet. So I created an API key and I'm just going to paste that in there and click enter. Configure skills now. We can go through this too if we want. Um, and it'll give us some options for skills. You know, different things. Um, model usage, nano, PDF. I think this creates PDFs. For right now, I'm not really super interested in any of these. But yeah, just so you know that they're there. We'll actually skip this for now. Set Google Places API key um for Go Places. No, we don't really need that. Notion API key for Notion. No, we don't really need that. Um, set open API key for open AI whisper API. That's all right. We don't need that for now. And then 11 Labs. So this is cool if you want to add give your agent or give your agent the ability to speak. You can add 11 Labs. But for now, we'll skip that as well. And then enable hooks. For now, we'll skip this as well. I'm clicking space by the way and to select and then enter when I'm ready to go or ready to move on. And gateway service already installed. Um, I already have this set up, so that's why it's saying that. But we're just going to do restart for you. Um, it'll probably look different. And then it'll ask, "How do we want to hatch our bot?" And I'll say hatch in TUI, which is recommended. So it's going to walk you through. I just came online. Looks like this is a fresh start. I've got a bootstrap file telling me to configure who I am. So who are you? Who do you want me to be? Um, let's sort out the basics. What should I call you? So, Hello. This is important because this is going to be like the the core of how it operates from here going forward. You can of course change this um in like the actual agents.md file. But for now, we're going to make sure it's configured um how we want it going forward. Okay, so, Hello. My name is Max. I'm a content creator, specifically creating content on how to use Open Claw. You are a demo agent meant to help me create demos for my audience. Um, typically, you'll want to be even more kind of specific here, but for for this use case, I think this is fine. And that's it. So we have our agent all set up now.

Okay, so now that we have our agent fully set up, if you want the full PDF guide, you can find it in our school community. That's completely free for now. The link is in the description. From here, we're going to take a look at the file structure, how Open Claw actually organizes folders, how to navigate it, how to edit files. And this is really important because as you're managing your Open Claw agents, you're going to need to use these files. So it's important that you know where they are and what they do. So that's what we're going to go through right now. We're going to do a quick walk-through of what the file structure actually looks like. So if we go into our main home file, right? So demo is the name of this of the actual user. So if you look at your user, um, you'll see your main main folders right here. And by default, the Open Claw folder is hidden. So what we're going to do is click command shift period, and we'll see all the hidden folders. And you'll see right here is a dot Open Claw folder, and this is where everything revolving around Open Claw lives. You can see our agents folders. Um, see our crons. See identity, logs, workspace. Um, so this is kind of one way that you can see all of your folders. But if you'll remember earlier, we set up Virtual Studio Code, which makes it a lot easier for us to see everything that we need to see. So I'll go in here and I'll click open folder. And we'll go to our home. And then again, click command shift period. Hold all those down together, and you'll see all the hidden folders. And we will click Open Claw. Open. And then we can see everything in here. Click yes, I trust the authors. Um, how do I make this a little I think I'm going to do command plus. Yeah, all right. Make it a little bigger so you guys can see it. And then in here, we can see all of our folders. So we have our agents folders. Agent sessions. So I'm pretty sure those are just the logs when it's running. Um, we are a way for it to kind of store memory while it's running. But we're going to look at our workspace because this is where our core kind of infrastructure for our Open Claw agent is going to live. Um, and then actually before we do that, let's look at Open Claw.json because this is where all of our configurations live. Um, you can see our models that we have are here. And this is just this is JSON. Don't let it scare you too much. We won't be working in here that often. Um, but yeah, this is really important to be aware of because it'll also have like our memory infrastructure. Um, everything that we need in order to kind of work with Open Claw. So yeah, this will have memory. Um, you know, all of our models, all of our different agents. Everything that Open Claw needs to work properly is set up in here. You need to be really careful when you're editing the Open Claw.json because um, if you, you know, miss a bracket, accidentally delete a bracket, or um, you know, something small like a colon, then everything will fail and your Open Claw agent won't work. So be really careful. The nice thing about VS Code is it lets us know so you can see an error when something's missing or not correct. So yeah, be careful. Um, there's backup files too for for Open Claw. So if you do make a mistake, you can go back theoretically, but I wouldn't rely on that too much. Um, then from here, what I would do is actually open up a new window. So we're going to go to file new window. And then we're going to do file open folder. And let's see. Command shift period. You can see Open Claw. Um, and what we're going to do is open up just our specific workspace. And if you have Git um GitHub, this is what you'll be actually like pushing to GitHub is the workspaces, not the entire Open Claw setup. And you can see here we have our agents.md. So this is like the main system prompt. This is everything that feeds to the agent, and a lot of this goes on almost every request. So only keep very important information here. But if you need something like core to your agent, this is where you can update it. You have identity.md. Tells it a little bit about who it is. So that's where you can update that. Soul. So this is more like characteristics, how you want it to talk to you, things like that. >> [snorts] >> And then tools. So this is tools that you'll have available to it. Um, we'll get more into that later. And um, this is information about me, the user. So that's kind of in the standard information that allows Open Claw to know what it's doing, who you are, who it is, and its core objectives. So that's important to keep in mind. If you want the full documentation on the file structure, if you want to learn more about what each file does, how to organize them, you'll find the full guide in our free school community. The link is in the description. So make sure to join.

So from here, we're going to finish up our Slack integration because there's a few things that we need to complete to make it fully functional so that we can talk to our agent remotely. Let's check out our Slack application. So go back into the workspace. We have our demo agent right here. And if we type hi, so we have access not configured. So your Slack user ID and pairing code. So ask the bot owner to approve. Okay, so what we're going to need to do in here is in our channels object, we'll find Slack. And then we're going to just going to to add a property here that says allow from. And then we'll paste in our ID. So, we'll go here and get our user ID. Paste that in. And actually, this needs to be an array. So, we'll just change those quotations to two brackets. We need the quotes, too. And then the other thing we're going to need to do is approve the pairing. So, you can see right here I clicked or I wrote open claw pairing approve Slack. And then we need to paste in our pairing code from Slack that it gave us earlier. So, we have it right here. Just copy that. And then we'll paste it in here. And let's see. Approved Slack sender. So, now we have that. We're going to restart the gateway. Open claw gateway restart. And then great. So, now we have Now, let's try this again. So, that looks pretty good. Hey, I'm ready to help test. Hey, I'm ready to help, but I need access. Could you run open claw pairing approve Slack on your end? Let's see. Already did that. I don't think it would be able to respond if that wasn't approved. So, it should be a good now. Perfect. Looks like the pairing went through on my end now, too. Thanks for confirming. What can I help you with next? Sweet. So, this is looking pretty good. And now we have Slack set up. And again, if you want all the documentation, all the specific things that you need to do in the full walk through um with the PDF guide, then make sure to join our school community because we'll have it all in there.

So, now we're going to get into memory. We're going to set it up in two ways. We will set it up the native way initially, the way that is standard for open claw out of the box. And then we are going to implement QMD and lossless claw for an enhanced memory system.

Okay, so now we're going to work on setting up memory. Um, the first thing we're going to do is set up the local core memory. And then from there, we're going to enhance it by using QMD. And then we're also going to enable lossless claw, which is a new kind of plugin using um a new feature from open claw. And we'll talk more about that in a little bit. But the first thing to kind of know is that since we set it up sit since we set up our open claw using Anthropic, Anthropic doesn't work with the memory embeddings in um open claw. So, the first thing we're going to need to do is give it an API key that it can actually use for memory embeddings, or we could technically use like a local model. But for this, we're going to use OpenAI. And I'm just going to go in here and I'm going to go to the config once again. Open claw config. And we will do local this machine. And we'll do model. And then we're going to go to OpenAI. And >> [clears throat] >> we are going to go to open a API OpenAI API key. And then paste API key now. And then I'm just going to paste in my OpenAI API key that I set up earlier. And And then we're going to give it access to a smaller model. Like 4040 mini. We'll try out a few different things. And yeah, let's see how that goes. And then we're going to click continue because we don't need to set up anything else. And our we now have our OpenAI um API set up. So, now we can go to open claw TUI to pull up our agent.

Okay, so now we'll just tell it I want to set up memory according to the agents .md. And if we go into our workspace folder, we can see we now have a memory folder with our daily do- notes and our memory.md. So, now that we have memory working, we're going to set up QMD for a stronger backend. And then we're going to also set up lossless claw. And I'll explain a little bit more about what that does in a bit.

Okay, so what we're going to do next is actually set up QMD, which is a little bit more of an advanced memory system. Um, I have a video kind of explaining the difference between the memory core, which is the native memory, and what QMD does. Um, but for now, we're just going to kind of So, you can go back and look at that if you want. But for now, we're just going to set it up. And I have this documentation that kind of goes through step by step how you can set it up and like what changes in your config and everything. And you can find this resource in our school community. But we're actually going to cheat a little bit. And what I'm going to do is I'm just going to get this GitHub link. So, this is the GitHub of QMD. And you can see here there's documentation about what it does, how to install it and everything. But what I'm going to do is actually just feed it to our open claw agent and tell it, "Can you use QMD according to the documentation?" And we'll paste in the GitHub link. It says it says QMD isn't installed yet. So, it's saying, "Let me install it and configure open claw to use it." QMD is installed. Now, let me set up collection and configuration or configure open claw to use it as the memory backend. Embeddings generated. >> [sighs] >> Let me test QMD. Search QMD is working great. Way better than the built-in. Now, let me configure open claw to use QMD as the memory backend. Done. Here's what I set up. Installed QMD. Created a collection. Added context. Generated local embeddings and switched open claw's memory backend to QMD in config. So, there we go. Pretty pretty simple to do it that way. And then we can go into our openclaw.json and theoretically, we can see what it changed here. So, we can see memory backend is set to QMD.

So, the next thing we're going to do is install lossless claw, which is actually a plugin that was recommended by Peter Steinberger, who is the founder or creator of open claw. Um, and we can go into the GitHub and we're going to do it the same way that we did with QMD. And essentially, what we're going to do is just paste in the GitHub and tell it to set it up. >> [snorts] >> So, it says, "Set Can you set up lossless claw as well?" And just paste paste in the GitHub. Installed. Now, let me configure it with sensible defaults and use a cheaper model for summaration summarization then restart. All set. So, it's using Claude high Q 4 5 fresh tail. 32 messages always kept raw. Talk context threshold. 75% compaction triggers before hitting the window. Incremental depth. Cron sessions excluded. Session idle timeout. What this means in practice, instead of losing old messages when the context window fills, LCM or lossless claw summarizes them into a DAG structure. Every message stays in SQLite, and you get tools like LCM grep, LCM describe, and LCM expand to drill back into anything that was compacted. The agent effectively never forgets. Gateway is restarting now to load the plugin. Great. So, if we go into here, so if we go into here, we can now see plugins entries lossless claw enable true configured. And it added some parameters as well for us. So, that's looking pretty good. And I think one thing we're missing is the context engine slot. So, I'm just going to ask it about that real quick. I don't see the context engine slot set up in openclaw.json. adjacent Do we need this? I could call Um, that was the missing piece without plugins. dot slots dot context engine lossless claw. The plugin was installed and enabled, but open claw was still using its built-in sliding window compaction. The slot assignment is what tells open claw to route context assembly and compaction through LCM instead. So now we have plugins, slots, and context engine.

Okay, so this is looking pretty good. We now have lossless claw set up for our context engine, and we have QMD set up as our memory backend, as well as memory folders that will index our memories. So you can see Max asked to set up memory per agent, created memory dot markdown in memory directory. Then I can go here and save save all relevant information to memory. And we want to make sure to do this every once in a while. Done. Updated both files. Detailed daily log of everything we did. QMD install and config, LCM install config. The missing slot lessons learned curated long-term with setup details, key decisions, and lessons, especially the slot assignment gotcha. Future me will thank us for that one. And then we can go back into our memory file and we can see it added everything that we needed. So looking pretty good. And if you want more information about memory, memory architecture, how it works, and what to keep in mind, make sure to join our free school community. The link is in the description.

From here, we're going to actually build out the multi-agent system. We're going to be talking about sub-agents, multi-agents, Ralph loops, long-running tasks, and PRDs. So let's get into it.

So what we're going to do from here is we're going to start building out this infrastructure. So what we're going to do is we're going to set up a new agent, which is going to be our CTO agent. Um, and the CTO agent is going to help us draft PRDs or product products requirement documents. And then that CTO agent is going to delegate it the PRD once it's created to an orchestrator agent, who's going to delegate it to the individual tasks to back-end agent, the front-end agent, or iOS agent. Um, in our case, it'll be a front-end, not iOS. Um, and then a QA agent. And each one of those will be running Ralph loops so that will spin up a new new sub-agent for each one of the tasks. And we'll talk more about like why that's important um in a little bit. Yeah, so let's get into it. So CTO agent is going to be kind of So as we do this, we'll talk about scaling horizontally versus vertically. Um, CTO agent is going to be similar to main agent in order in a sense that we can talk to it and have a conversation with it. And then our orchestrator agent is going to be a sub-agent, and these three will be sub-agents within the CTO agent agent as well.

So the first step we want to do is create the CTO agent. And in order to do that, we'll we'll just create a new terminal. So we'll go to shell, new window. Um, and then from here, what we want to do is use the open claw agents add command, and then we'll type in the name of our new agent, which is CTO. Workspace directory is workspace-CTO. So this is just setting up a new workspace for it. Copy auth profile from main. We want yes. And then configure model auth for this agent now? Yes. And we want to use Anthropic, the same as our last one. We're going to use the same API key that we used from our last one. So we're just going to paste in the same API key that we were already using. And we want to configure channels. Um, so for this demo, I'm not going to configure channels because we're just going to be talking to it directly in our TUI. So I'm not going to do that. And you can see agent CTO is ready now. So if we go back into our file system, we'll see a new workspace, which is workspace-CTO. And you'll see we have new agents, new bootstrap, heartbeat, identity, soul, tools, and user. And then what we're going to do is we're going to go back into our previous terminal terminal where we can talk to our agent. We're going to go slash model or sorry, slash agents. And then we're going to going to. You can see in this it's kind of a weird UI. I think it's a bug. But what we're going to do is we're going to click um use our arrows to click CTO. And then now we're able to talk to our CTO agent. So, "Hey, I just came online. Who am I and who are you?" So we're setting up a new agent. So this is going to be similar to what we were doing with our previous agent. What I'm going to do is actually paste in a prompt from our document that we have. Okay, so this is a What I like to do is um create kind of the system prompt myself in the beginning and then as I'm speaking with the agent, I will refine it and make it better. But essentially, what I'm telling you is that you are Max's CTO. Your job is to make an app app idea for Max and turn it into complete PRD products requirement document. So this is what we'll we'll be passing to the sub-agents. Ask clarifying questions if the idea is vague. And then once the PRD is approved, delegate it to the orchestrator agent. Um, which we will be creating in a little bit. So, and then we will report it back. Should be Max, not Richard. Um, on progress and then tag and then we're telling you the tech stack as well. So we want to use React. You don't have to use React. That's what I'm going to use for this. Tailwind back-end database we're going to use Supabase. Um, and then for deployment we're going to use Vercel. And then when Max gives you an app idea, draft a PRD using the template in docs/templates um PRD-template.md and then save it to workspace projects um current PRD markdown and then present it to Max for approval. And then once it's approved, we're going to hand it down to orchestrator to begin building. What you don't do is you don't write code yourself. It's important to give it guardrails so it knows what not to do. So you don't write code yourself, you don't deploy anything, you plan, delegate, and track progress. So we're going to pass this along to our open claw agent. So I can create this. Got it. I'm your CTO. Let me set up properly, updating my identity files, and then I'm ready to work. So it's going to create the directory structure and a solid PRD template now. Here's how we work together. You bring an idea, even a rough one is fine. I ask questions if I need to fill in the gaps. I draft a PRD using your templates. You approve it. I hand it to an orchestrator as we build.

Okay, so that's good. Let's check out our CTO workspace. So what we're going to do, I like to just open a new folder because I think it's easier to manage. So we'll do that. New folder. Um, a new new window, sorry. And then open folder. dot open claw. And then workspace CTO. >> [gasps] >> That way we can see this and we will get a little bigger for us. So then we have our workspace projects. So it already created a projects folder. We have our docs, templates, PRD template um, which it looks like it created a template for us, which is awesome. And that's about it. So that's a good start. Now we need to create our sub-agents. So what I'm going to do is sometimes I like to create the sub-agents myself, but I think for this this one I'm going to have um open claw do it and see how it goes. So first, we need to create our sub-agents. Let's start with the orchestrator. I'll paste in the system prompt. And we'll go back to my document here. And we have our orchestrator system prompt. But I'm just going to paste that in here. On it. Let me set up the orchestrator workspace um mirroring the structure of the CTO workspace so it boots cleanly. Actually, I don't think that's what we want to do. So it looks like it's trying to set up a separate workspace, which isn't what we want. So maybe we'll have to do this um ourselves. Yeah. >> [snorts] >> Okay, so this didn't do it what we wanted. Let's see. No, we want the orchestrator as a sub-agent within the CTO workspace. Here is the system prompt again. Yeah, okay. So, it gets it now. The orchestrator is the sub agent that I spawn from within the CTO workspace, not a separate top-level agent. Let me fix that. First, undo separate orchestrator agent. Um, so, that's good. So, it's going to delete the orchestrator agent that I created. Okay, so that's cool. So, it's creating the sub agents file. It's kind of cool because [snorts] you can see it in real time like what it's creating. Um, so, you know, the sub agents file that we just created with our orchestrator, it has our system prompt. Sweet. And then it's also creating the Ralph loops. Um, which this shouldn't be iOS, it should be front end for our use case, but we'll fix that later. Sweet. So, it looks like it's done. Um, now let's create the back end sub agent in the same way.

Okay, so we're going to use this as our system prompt for the back end agent. So, you build back end functionality using It's actually needed to be Supabase, not Convex. Using Supabase, your responsibility to find and create Supabase write Supabase functions, queries, mutations, actions, set up authentication if needed, implement business logic, and follow the PRD exactly. Um, blah blah blah. And we will just paste this back into our orchestrator or our CTO agent. Tell it to create it. And I want to change this because it's not an iOS agent. That was originally for um creating iOS applications like phone applications, but this is just going to be a regular front end agent. So, we want to do iOS agent should actually be a front end agent. Please update the file in the orchestrator if necessary. Okay, so it updated that correctly. So, now we're going to add in our iOS system prompt. We're just going to copy this from here. So, you build front end using React with Tailwind, build screens, navigation, connect with Supabase back end, implement UI UX per um the PRD, and follow the PRD exactly. Make sure it calls all screens are responsive, write component tests, update Ralph loop checklist as you complete tests, and when you finish notify the orchestrator. So, we're just going to paste that in. And I called this iOS and it should be front end, so let's just fix that. Sweet. So, it updated it and now it's just QA left. So, the QA have our QA agent system prompt. You verify what what matches the PRD, meets quality standards, run all tests, unit integration, verify features, PRD requirements, check for security issues, verify this needs to be Supabase. Schema patterns, expected data model, check We don't need this right now. And receive completed work from the orchestrator. Um, run tests, compare output against PRD requirements. If passed, report orchestrator with summary. If failed, report orchestrator with specific failures. So, that will be our QA agent. We'll just go back to Open Claw and paste this in.

Okay, so the whole pipeline lives in workspace CTO sub agents. When you approve a PRD, I spawn orchestrator with cascades down to back end, QA, front end, QA, integration check. Okay, so ready to build something? What's the first app idea? So, that's pretty cool. We also need a deployment agent to deploy to Vertex when the app is finished. And it do on that Vercel, not Vertex. And then to add a So, Ralph loops need a separate script run, so see I'm not sure if it actually already created this or not, so we're just going to ask. Do we need to add Ralph loops script somewhere?

One other thing that we should do is set up routing for our sub agents. So, I'm going to leave our CTO agent on Opus because it's going to need to plan things, it's going to be need to create things, and I think it's going to need the most amount of power behind that agent. What I want to do is set up our sub agents to use Sonnet. Um, so that we're not burning as many tokens because I don't think those tasks need as much power, and I think they can be handled by um a lesser model. So, what I'm going to do here is I want to set up model routing for our sub agents. Let's make sure that the orchestrator QA back end and front end agents all use Sonnet when running. So, it's doing a little bit of research. So, let me update the orchestrator prompt to explicitly specify the model when spawning each agent. Now, let me also add a model to note uh a model note to each of the individual agent prompts. Okay, so this is right. Model routing is the orchestrator's job in the CTO O's when spawning the orchestrator. Let me add metadata header to each with their intended model, so it's clear when reading them. And also update agents.md to document this convention. Now, let me commit this. Done. Here's what's set up. So, I added the model header comment as self-documentation, so it's obvious at a glance what model each agent is intended to run on. And cool. Okay, is the deployment agent So, we need to set the deployment agent as well. So, yes, the deployment agent should be Sonnet as well. All five agents, orchestrator, back end, front end, QA, and deployment are now pinned to Sonnet. Spelled Sonnet wrong. But, I think we're good.

Okay, so that's that. Okay, so the next thing we're going to do is set up our API keys. And in order to do that, we're going to set up three API three keys or secrets for um Supabase and then one for Vercel. So, Supabase is our database where we're going to actually be storing data. Um, and in order to do this, we're just going to do export Supabase API key equals and then we'll paste our API key. And then we'll do We'll add these one at a time, so then we'll go into our openclaw.json. I've already created this. So, we'll have an environment object and a variables object or vars object. And in here, we will just essentially say >> [snorts] >> um Super Need to use cool quotations. And then we'll paste that API key. Oh, actually, we don't want to paste the API key. We want to use environment variable. So, we'll do this. And Super base API key. We'll do the rest for the rest of these now. So, export Supabase anon key. Make sure we're referencing it in here. >> [snorts] >> There's quote. >> [sighs] >> Okay, so we got our super base API keys. Now we just need our verse cell. Sorry, they're not all API keys, but you get you get the point.

Okay, so now we have our API keys set up. So I want to do a couple of things. One, I want to update the PRD template so that it's more specific on exactly what it's going to create. So we're just going to copy this template that I already created and I'm going to go into our template that open claw created and I'm going to delete that and paste our template in. And you can see the one I made is a lot more specific. Um, it has hard rules, has content tone, has um essentially what it should deploy to the back end agent, what it should deploy to the front end agent, um talks about design system, uh design layer, um global components. So it's just a lot more specific and it's going to kind of tell our open claw agent the level of depth we want when it creates the PRD.

So now that I created this, I'm going to talk to our open claw agent CTO and I'm going to tell it I created a new template for the PRD. Check it and let me know if you understand. Got it. Use the checklist sessions as task breakdown for back end and front end CM chain. Each section becomes a discrete work package. It's clearly aimed at marketing websites builds rather than app dashboards visual. Should I use it as is for future website projects and keep a separate format for app builds or do you want this to be a universal PRD template? Um, so I wanted to know this is just a template. You can change the specific tasks based on the app dashboard um website. So got it. Structure back and front end QA tracks the checklist is the universal universal format and the actual task inside this each section flex to fit whatever is being built, website, dashboard, API, whatever. I'll use this template for all PRDs going forward.

Now I want to make sure it understands how to use the Ralph loops as well. So for the Ralph loops, each task in the PRD has a checkbox. And the Ralph loop should check off each task as it is completed. Make sense? The Ralph loop checks off the corresponding box in the PRD. So instead of Ralph files being a separate summary, they're tightly coupled to the PRD check checkboxes. Okay. The Ralph state files ralph.md would then just track in the agent levels. I'll document this convention to the orchestrator and all subject follows in the system. Want me to update the orchestrator's um prompt in the agents.md to lock this in? Yes. Now I have everything updating all files at once. agents.md to document the convention all updated. Here's what changed. Next, build the PRD will be live pro the live progress board. Open it at any point and the checkboxes show exactly where things stand, and that's exactly what we want.

So I'll go back in here and I created a prompt that I'm going to give it for our application and tell it to build a PRD for it. Build a PRD for this app. I'll just paste the prompt. Love the scope. A few quick questions I have before I write it up. One, is this a sales demo? Um, show prospects open claw looks like deployed or an internal tool actually used day-to-day. Make this an internal tool. Two, um, real data or simulated or mock? Is the model program actually hitting the Anthropic API or is it a convincing demo with canned responses? So we want real data. And three, um, yeah, we'll make it password protected. And four, specific to a firm. This is for our internal use. And then five, same stack. Now it's going to generate our PRD for it, and I think it's going to look pretty good. Six pages all behind super base auth, dashboard home, model playground, deployment pipeline, security and compliance, data connections hub, costs and analytics. Key architecture decisions. Um, big 10 Anthropic API calls are server-side only. Edge functions never from the client. Super base real-time metrics, deploys and audit log no pulling for live tables. Background cron jobs keep all data fresh automatically.

So three open questions before I mark this approved. One, roles, full access for everyone on the team or admin? Um, full access is fine for now. Two, data connection, are the these real live integrations or status managed ourselves in super base? Um, we will connect live integrations later. It's where you can if you want to connect to certain tools, you can do that here. Um, you know, you can put in your API keys, tell it what tools you want to connect to, is your CRM, um, your ERP, whatever it might be. And then domain for the domain, we'll just use a verse cell auto URL because I don't want to create a domain right now. And that should be good. Data connection. Okay, so perfect. Locking in.

Decisions and handing off. Orchestrator is running. Here's what it's in motion. Okay, so it already started the development. Cool. Full access. Normally I'd like to approve it first, so maybe we can add that in to let it know that um I need you to approve it before it hands it off. But [snorts] full access for all team members, data connections managed in super base, verse cell auto URL, build pipeline started, um back end first, QA gate, front end QA gate, deploy. [snorts] So that looks good.

Progress is tracked live in our task current PRD.md and checkboxes get ticked as each task completes. Ask me build status at any point and I'll read the PRD and report back. I'll ping you with the live URL when it's done. Okay, great. So let's take a look at our current PRD. So this is what it created. So you can see it has back end sections. Created super base schemas for us, super base edge functions, background sync, deployment environment, security, front end design system, um global layout, page, dashboard. So it's very specific about what we want. So this should create a much better application than just kind of giving it one prompt and and hoping for the best. Authentication test testing, dashboard home, model playground, deployment pipeline, security and compliance. Um and we should see it start checking things off. Great. So build status still early on, but kicked off 3 minutes ago. Here's the snapshot. Back end working, front end waiting, QA waiting, deployment waiting. Um so back end agent still mid build, nothing to ticked off yet. So we'll check back later and see see how it's going.

Okay, so let's see what it did. Um we're live. Open Claw Ops dashboard deployed. It's set up. User credentials, it set up the back end. Eight tables with RLS triggers, Superbase auth, real-time enabled on metrics. It also deployed it by the way to Vercel, as you can see here. So, all six pages, dashboard, playground, deployments, security, data connections, cost and usage, 12 shared components, full auth protection every route, dark design system, row charts, dark themed throughout, and mobile responsive. PRD 195 out of 212 tasks complete, 92%. The remaining 97 17 are non-blockers deferred to V2, gateway sync, edge functions, cron job, custom domain, and a few UI polish items. Um so, go take it for a spin and let me know what needs tweaking. Want me to log the 17 deferred items as a V2 task list. Okay.

So, let's look [snorts] at the PRD and see what it did. So, we can see as it was working, it went through and it marked off the items that it completed. And these are some of the items that I mentioned it didn't finish. Um but yeah, it's pretty satisfying to see it just went through and one by one marked off all these. And then, let's check out the actual application. Um new window. And [clears throat] this is the app that it built for us. Pretty cool. Pretty nifty. Okay. So, we have some cool little charts here. CPU and memory. Um system events. We have our playground. We have deployments. Security. Data connections and cost and usage. So, some of these APIs like data connections, obviously it made some stuff up here because we don't have these APIs ready. But, once we do configure um it'll we'll be able be able to see all that here. Cost and usage. Pretty cool. Not [snorts] too bad. Not too bad. So, you can see when you use a PRD, it's able to do way more complicated tasks because you're not just one shotting it. You're telling it the exact steps that you want it to take and key details that you want in the application. So, from here let's tell it to finish the remaining 17 items.

Okay, so we're back and it looks like Orchestrator V2, all tasks complete, live URL. And there we go. We have a deployed application. Let's check it out one time. There we go. Everything is complete and the application is good to go. Um and then from here, obviously we'll need to configure different API connections. If you have more details on the application that you actually want to build, the more complex the application can be cuz you know, through these PRDs, you can have it running for hours at a time and um it'll be able to create pretty much anything you want. So, this is really a great way to kind of build out applications instead of just trying to like one shot them.

Okay, so you've gone from a blank screen to a fully wired multi-agent system, setup done, orchestrator running, sub-agents with real roles, real memory, handing off real tasks. And most people who download Open Claw are still on agent number one wondering why it keeps forgetting what they told it 5 minutes ago. You're not that person anymore. The gap between someone who has Open Claw and someone who uses Open Claw is exactly what we just built together. But, here's what I want you to understand before you close this tab. What we built today is a foundation. It works, but the systems that actually move the needle for your personal life and business, the ones that run pre-call research, qualify leads, surface buyer signals while you sleep, those are a layer on top of this. And building the next layer on your own from scratch with no one to check, that's where most people stall. I've stalled there. I've debugged those systems at 11:00 p.m. wondering why my orchestrator was looping and I've figured it out. That's exactly why I built out my school community. It's where we share Open Claw setups, blueprints, and knowledge about what actually works and how to get real benefits. Inside, you get detailed guides on setup prompts and debugging PDFs that you can actually feed directly to your agent, a community of people building the same systems you are. So, when your orchestrator starts behaving like it's lost its mind, you have people who've been there before. And direct access to me because I'm in there every week answering questions and helping people get unstuck. This is not just a course, it's a roomful of people who are actively building. The link is in the description, come find me in there. If this video helped you, make sure to like and subscribe. I post every week on Open Claw, multi-agent systems, and how to build real leverage with AI. And if you have any questions about anything we covered today, drop them in the comments. I read them and sometimes they become the next video. That's it. Go build something.