In the last post I wrote about running a team of agents instead of piling every job onto one.
There was a catch I did not dwell on then. The way I first built it, you drew the whole org chart up front. Every person who could talk to an agent, granted ahead of time. Every agent-to-agent line, wired by hand.
This post is what running it taught me about that, and what I ended up changing.
The map you don’t know yet
Drawing the map up front works when the team is three agents and you know exactly who talks to whom.
It stops working the moment the team is real.
People show up you did not plan for. A coworker hears about your assistant and messages it. You spin up a new agent on a Saturday and it needs to ask an older one for help.
None of those edges were on the map, because the map was a guess.
I kept ending up in the same bind. Draw it too tight and I spent the week rewiring. Too loose and everything could talk to everything. Neither sat right.
Cast 0.2.0 handled new people with pairing codes. Meet someone, generate a code, send it over, they redeem it. It worked, and it was busywork. Every introduction went through me by hand.
A connection forms when someone knocks
What I landed on in 0.3.0 was to change when an edge gets made: at first contact, instead of at setup.
Someone new messages your agent. Nothing silently opens. The message is held, and the agent turns to you and asks.
The ask lands in your own chat, with the message they sent, so you decide with the actual words in front of you. The sender just sees that their message is waiting.
Approve, and they are in. Reject, and the door stays shut.
Approving once creates a standing grant. The next message flows without asking you again, and you can revoke it later from the access tab.
Agents knock the same way
The same gate covers the agents themselves.
When one agent wants help from another and there is no line between them yet, the request is held exactly like a stranger’s first message. You say yes, and the org chart grows a line.
What builds up over the weeks is the map of who actually works with whom. Not the one I guessed at setup. Every line on it exists because someone needed it once and I approved it.
You can still draw by hand
Pre-wiring still works. When you already know two agents belong together, write the grant and they are connected from day one.
The difference is you no longer need the whole picture before you start. The chart begins as small as you like and fills in as the work arrives.
The org chart stopped being a diagram I maintain. It became a record of what my team actually does.
Try it
Cast v0.3.0 is up on GitHub.
git clone https://github.com/yaodub/cast
pnpm start
Coming from 0.2.0, the migration scripts under scripts/migrations/0.2-to-0.3/ carry your paired users and grants over to the new model.
Still developer alpha, still rough in places. If something breaks, tell me.
Originally published on the Cast blog.