# Multi Cli Spawn

> >

- **Type:** Skill
- **Install:** `agentstack add skill-iml1s-agent-cli-skills-multi-cli-spawn`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [ImL1s](https://agentstack.voostack.com/s/iml1s)
- **Installs:** 0
- **Category:** [AI & ML](https://agentstack.voostack.com/c/ai-and-ml)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [ImL1s](https://github.com/ImL1s)
- **Source:** https://github.com/ImL1s/agent-cli-skills/tree/main/skills/multi-cli-spawn
- **Website:** https://iml1s.github.io/agent-cli-skills/

## Install

```sh
agentstack add skill-iml1s-agent-cli-skills-multi-cli-spawn
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Multi-CLI Spawn (cross-provider parallel seats)

## When to use

- Need **several providers** to answer the **same brief** in parallel
- Multi-LLM **council** / second opinions / cross-vendor review
- You already have (or will install) the per-CLI `*-cli-agent` wrappers

This is **not** a substitute for vendor-native multi-agent inside one CLI (`-T` / ultracode /
teamwork). Use those for fan-out *within* one provider; use this skill to fan-out *across* providers.

## Why

Each vendor has **native** multi-agent inside one CLI (agy teamwork, Claude ultracode, Codex
subagents, Grok spawn_subagent, …). This skill is the **cross-CLI** layer: one brief → N
providers → N answer files.

## Usage

```bash
./spawn.sh --outdir /tmp/council-$$ \
  -f /tmp/brief.md \
  --seat agy:readonly \
  --seat claude:ultracode \
  --seat codex:team \
  --seat grok \
  --seat kimi:readonly \
  --seat qwen:readonly \
  -C /path/to/repo \
  -t 1200s
```

Seat forms: `name`, `name:readonly`, `name:ultracode|team`, `name:readonly,team`, `name@label`
(unique output key when duplicating a CLI).

Seat modifiers (comma-separated after `:`): `readonly`/`r`, `team`/`ultracode`/`T`.

### Outputs

| File | Meaning |
|------|---------|
| `.log` | Live CLI stdout/stderr |
| `.md` | Final answer, or `BLOCKED:…` stub (written when the seat finishes) |
| `.pid` | Seat process-group id (kill target) |
| `.rc` | Seat exit code |
| `.status` | `RUNNING` → `DONE rc=0` \| `BLOCKED rc=N` (atomic) |
| `spawn.pid` / `spawn.status` | Parent: `RUNNING` → `DONE`, or `SPAWNED` if `--no-wait` |
| `brief.md` | Copied/normalized brief inside outdir |

## Waiting contract

1. **Default: do not poll.** Run `spawn.sh` in the foreground (wait mode). Its exit code and
   `CLI_AGENT_RESULT: PASS|BLOCKED ` lines are the completion signal.
2. **`--no-wait` / external watcher:** wait until every seat `.status` is terminal
   (`DONE` / `BLOCKED`), e.g.:
   ```bash
   while grep -qlE '^RUNNING' "$OUTDIR"/*.status 2>/dev/null; do sleep 15; done
   ```
   Do **not** treat missing `*.md` or a dead `*.pid` alone as "no answer" — `.md` appears only
   when the seat finishes; pidfiles can look dead if the parent spawn was killed while seats
   continue.
3. Kill only via numeric PIDs in seat `*.pid` files (process groups). Skip `spawn.pid` when
   iterating kill targets unless you intend to stop the parent. Never `pkill -f` long patterns.

## Hard rules

1. **PID files only** — never `pkill -f` with a pattern that also appears in the launcher argv
2. **Quota fail-open** — provider errors / empty output → `BLOCKED` stub; do not retry-loop
3. **agy needs PTY** — handled inside `agy-exec.sh`
4. **Orchestrator owns git** — spawn always passes `--no-git`
5. Parallel **writers** should use separate worktrees (`-C` per seat) to avoid collisions
6. Seat `rc != 0` is `BLOCKED` (missing binary is not a council vote)

## Synthesize

Read `*.md` only for seats whose `.status` is terminal. Strictest blockers win. Divergent
findings are high value. Re-run only BLOCKED seats after the user refreshes quota/auth.

See also: [docs/CORRECTNESS.md](../../docs/CORRECTNESS.md), [docs/FEATURES.md](../../docs/FEATURES.md).

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [ImL1s](https://github.com/ImL1s)
- **Source:** [ImL1s/agent-cli-skills](https://github.com/ImL1s/agent-cli-skills)
- **License:** MIT
- **Homepage:** https://iml1s.github.io/agent-cli-skills/

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** yes
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-iml1s-agent-cli-skills-multi-cli-spawn
- Seller: https://agentstack.voostack.com/s/iml1s
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
