Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.rkat.ai/llms.txt

Use this file to discover all available pages before exploring further.

For the full guide, see Mobs.
There are two different mob surfaces:
  • Host APIs: typed mob/* methods over JSON-RPC and the SDK-backed Mob classes
  • Agent-side tools: mob_* tools exposed inside a running agent session
This page focuses on the host control plane. It does not treat agent-side mob_* tools as if they were the public RPC/SDK API.

Create a mob

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "mob/create",
  "params": {
    "definition": {
      "id": "release-triage",
      "profiles": {
        "lead": {
          "model": "claude-opus-4-6",
          "peer_description": "Coordinates triage"
        },
        "analyst": {
          "model": "claude-sonnet-4-6",
          "peer_description": "Investigates issues"
        }
      },
      "flows": {
        "triage": {
          "steps": {
            "scan": { "role": "lead", "message": "Prioritize incoming issues." }
          }
        }
      }
    }
  }
}

Spawn members

The CLI currently exposes helper-oriented mob commands such as spawn-helper, fork-helper, run-flow, member-status, respawn, and wait-kickoff. It does not expose the raw host-side mob/spawn lifecycle directly.

Wire and unwire peers

{
  "jsonrpc": "2.0",
  "id": 4,
  "method": "mob/wire",
  "params": {
    "mob_id": "release-triage",
    "agent_identity": "lead-1",
    "peer": "analyst-1"
  }
}
{
  "jsonrpc": "2.0",
  "id": 5,
  "method": "mob/unwire",
  "params": {
    "mob_id": "release-triage",
    "agent_identity": "lead-1",
    "peer": "analyst-1"
  }
}

Send work to a member

Use the host control plane when an application needs to deliver content directly to a member session.
{
  "jsonrpc": "2.0",
  "id": 6,
  "method": "mob/member_send",
  "params": {
    "mob_id": "release-triage",
    "agent_identity": "lead-1",
    "content": "Decompose the task and assign work to the analysts.",
    "handling_mode": "queue"
  }
}

Submit tracked work

Use the work lane when you need a cancellable work reference rather than plain content delivery. The work lane uses the opaque member_ref returned by spawn, member list, or member send responses.
{
  "jsonrpc": "2.0",
  "id": 8,
  "method": "mob/submit_work",
  "params": {
    "member_ref": "member_ref_from_spawn_or_members",
    "content": "Review the flaky test history and summarize the top failure modes.",
    "origin": "external"
  }
}

Run a flow

rkat mob run-flow release-triage --flow triage --params '{"severity":"high"}'
rkat mob run-flow release-triage --flow triage --stream

Helper-oriented CLI flows

The current CLI is strongest for helper-style workflows on an existing mob:
rkat mob spawn-helper release-triage "Join as lead-1 and summarize the release status." --profile lead --agent-identity lead-1
rkat mob fork-helper release-triage lead-1 "Investigate the flaky test history." --profile analyst
rkat mob member-status release-triage lead-1 --json
rkat mob respawn release-triage analyst-2 --initial-message "Resume with a fresh runtime."
rkat mob wait-kickoff release-triage --json

Events and subscriptions

events = await mob.subscribe_member_events("lead-1")
async for event in events:
    print(event)
const events = await mob.subscribeMemberEvents("lead-1");
for await (const event of events) {
  console.log(event);
}

See also