Goober Swarm » Docs » UCP-1 protocol Edit on GitHub

UCP-1 protocol

Goobers never touch files or git themselves: they answer in UCP-1, a tiny tag protocol, and the orchestrator carries it out. Tags must start a line; everything else in a reply is ignored.

Tags

TagMeaningWho
@READ:pathfile or directory; contents come back next turneveryone
@WRITE:pathfollowed by a fenced code block with the FULL file contenteveryone
@RUN:commandrun a shell command in the repo (tests, builds); output comes back next turneveryone
@SEARCH:regex|globripgrep the repo (glob optional, e.g. *.py); matching lines come backeveryone
@DIFF:pathuncommitted changes (git diff; path optional)everyone
@SHOT:target size | stepsrepo file (page.html) or http://localhost:PORT; size = mobile|tablet|desktop|WxH (+ full); steps optional: click #id; type #q hi; press Enter; scroll 600; wait 500; shot; record 6 250 (= 6 frames, 250ms apart). You get a layout report (+ the images if you can see them); the user sees them. Use it to check and iterate on anything visual.everyone
@SHOW:path|captionshow an image, GIF or video you made (e.g. with ffmpeg/ImageMagick) to the usereveryone
@SERVE:command|PORTstart a dev server in the background (for @SHOT); stops when the task endseveryone
@FETCH:urla web page (docs, references), rendered in a real browser, as markdowneveryone
@ASK:questionask the user something only they can answer; wait for the replyeveryone
@SPLIT:brief|filesone sizeable independent part; the orchestrator picks who does it (parallel)lead
@TO:NAME|briefgive a part to one specific teammatelead
@GIT:STATUS or @GIT:COMMIT:message(commit + push)everyone
@DONE:summarywhen your work is completeeveryone
@BLOCKED:reasonwhen you cannot continueeveryone

@SHOT example: the page at phone size, then click a button and record its animation:

@SHOT:demos/pricing/index.html mobile | click #billing-switch; record 6 250

@WRITE is followed by a fenced code block containing the full file:

@WRITE:src/hello.py
‍```python
def hello(name):
    return f"Hello, {name}!"
‍```
@DONE:Added hello()

What the orchestrator does

Prompts

The lead is told its teammates' talents, the repo tree, the goal, the subtasks so far and the latest message, and to delegate only sizeable independent parts. A helper sees the overall goal as context, its own brief, and the rule to do only that part. See build_prompt in orchestrator/protocol.py.

Limits

LimitValueDefined in
Agent turns per work task60protocol.MAX_STEPS
Nudges when a lead answers without tags2protocol.MAX_NUDGES
Feed messages kept in memory500protocol.FEED_SIZE
Reroutes per message before giving up2SwarmOrchestrator._reroute
Seconds one @RUN command may take180protocol.RUN_TIMEOUT
Seconds a Goober gets to answer a bid60protocol.BID_TIMEOUT
Bid round ends early after (seconds, once 3 bids are in)20protocol.BID_ENOUGH
Background dev servers per task (@SERVE)3protocol.MAX_SERVERS
Seconds a browser action (@SHOT / @FETCH) may take90browser.SHOT_TIMEOUT
Cooldown after a rate limit15 minAgentManager._settle