> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bead.run/llms.txt
> Use this file to discover all available pages before exploring further.

# bead swarm CLI commands

> Look up bead swarm CLI commands for results, polling, cancellation, and cleanup, alongside CI subcommands.

Run bead swarm CLI commands to distribute commands across temporary machines. CI commands connect GitHub repositories and inspect assigned jobs.

## Start a swarm

```bash theme={null}
bead swarm run 'echo hello' --template base --size small --count 2
bead swarm run 'printf "%s\n" "$BEAD_SWARM_INPUT"' --inputs inputs.json --concurrency 8
```

`--inputs` reads a JSON array and cannot be combined with `--count`. Without either, count defaults to 1. The guest receives `BEAD_SWARM_INPUT` and zero-based `BEAD_SWARM_INDEX`.

| Flag | Default |
| - | - |
| `--template` | `agents` |
| `--size` | `medium` |
| `--concurrency` | `8` |
| `--time-limit-seconds` | `300` |
| `--retries` | `0` |
| `--output-file PATH` | None; repeat for multiple files. |

Prepare code in a template or snapshot, or fetch it in your command. Swarm does not upload your local checkout.

## Inspect and collect

```bash theme={null}
bead swarm status "$SWARM_ID"
bead swarm results "$SWARM_ID" --output results.jsonl
bead swarm cancel "$SWARM_ID"
```

Results remain available for 24 hours after completion. Task machines are deleted after their commands. Inspect member outcomes before deciding whether another run is needed. See [parallel work](https://docs.bead.run/use-cases/parallel-work.md).

## GitHub CI commands

| Command | Purpose |
| - | - |
| `bead ci` | Overview. |
| `bead ci connect --config selection.json` | Install and confirm selected repositories. |
| `bead ci repos` | List repositories. |
| `bead ci job ID` | Inspect a job. |
| `bead ci logs ID [--follow]` | Read or follow logs. |
| `bead ci public ACCOUNT on --users alice,bob` | Allow selected public-repository actors. |
| `bead ci public ACCOUNT on --anyone` | Allow any actor. |
| `bead ci public ACCOUNT off` | Disable public-repository jobs. |
| `bead ci disconnect INSTALLATION` | Disable provisioning and retire owned machines. |

For the selection file and workflow, read [GitHub Actions runners](https://docs.bead.run/ci/github-runners.md). For a single job from any CI system, use [bead run](https://docs.bead.run/ci/portable.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.