Skip to content

Sub-agent spawning: agents that start agents #61

Open

Description

@melvincarvalho

openclaw supports spawning sub-agent sessions (isolated or forked context). Rung 8 of the autonomy ladder (jsclaw/docs#1): a manager agent runs a team. jsclaw has the primitives — IPC send_message, per-agent folders, the queue — but no spawn tool. Scope: a spawn_agent IPC tool (creates/targets an agent folder, runs a prompt, returns the result or streams progress), depth/count limits, sandbox posture inheritance (#42).

Activity

  1. Keesan12 commented on Jun 18, 2026

    @Keesan12

    One design choice that matters earlier than it seems is whether spawned agents are first-class runs or just helper invocations.

    If they are first-class, a lot of the scary cases get simpler:

    • each child gets its own budget and timeout
    • the parent receives a typed end-state instead of raw streaming text
    • depth and fan-out limits become policy instead of convention
    • sandbox inheritance is explicit and inspectable per child

    The failure mode I would watch for is manager agents creating more children as a substitute for making a decision. We have had much better luck when spawning is gated by a small receipt: why this child exists, what artifact it must return, and what should stop the parent from spawning another one. MartinLoop keeps nudging me toward that shape because it turns 'team of agents' from a vibe into something you can actually audit.

    Curious whether you are imagining spawn_agent as synchronous by default with a returned artifact handle, or more like fire-and-track jobs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions