mit einem Klick
swarm
Parallel attempts.
Mit Codex oder Claude installieren Kopieren Sie diesen Prompt, fügen Sie ihn in Codex, Claude oder einen anderen Assistant ein und lassen Sie die Skill-Seite prüfen und installieren.
Menü
Parallel attempts.
Mit Codex oder Claude installieren Kopieren Sie diesen Prompt, fügen Sie ihn in Codex, Claude oder einen anderen Assistant ein und lassen Sie die Skill-Seite prüfen und installieren.
Basierend auf der SOC-Berufsklassifikation
| name | swarm |
| argument-hint | <the goal for the swarm, e.g. "optimize bundle size"> |
| description | Parallel attempts. |
Launches N parallel attempts at the same task in isolated worktrees — each runs independently; the best result wins. For N tries at a hard problem rather than one sequential run (/orchestrate for that).
/swarm <goal> — the text after /swarm IS the goal, use it verbatim, never re-ask it.
Invoked bare (no argument) → ask ONE free-text AskUserQuestion: "What should the swarm work on?"
Whatever the phrasing — a task, or a question about swarm itself — it's the goal to launch;
never substitute a hand-written explanation for actually calling the swarm surface (step 4).
orchestrate run unclear → AskUserQuestion first.AskUserQuestion, up to 4 related unknowns per call.lc swarm ... or the matching service API) — never a new custom runtime.run_id + the exact status/log/apply surface to use next.Fill the launch contract from explicit args + repo inference first (see Elicitation); map onto:
spec_path, or spec_mode="inline" with spec_contentproviderrunner and runner_model (or provider model)runner_options — runner options that materially change launch behaviorrunscontinuousmax_wavesevaluator_backend, optional evaluator_modelmax_evaluator_failureskeep_worktreeseffortSwarm = fan out N isolated candidates → reduce by a pluggable selector → (optionally) iterate in waves. Pick --reducer/--mode per the goal; defaults (--reducer merge --mode edit) reproduce classic solve-task behavior exactly.
| goal | --reducer | --mode | each child produces |
|---|---|---|---|
| solve a task (default) | merge | edit | a patch; LLM judge merges compatible winners |
| optimize / tune an objective | best | edit | a patch, scored by a measured fitness |
| search / audit / find-bugs | union | readonly | findings, de-duped by signature |
| verify / consensus / repro | vote | readonly | an answer; kept iff ≥ quorum agree |
merge — semantic evaluator: accept compatible candidates, reject duplicates/conflicts, emit next-wave directives, judge convergence.best — rank by fitness, accept the top. --fitness-cmd = measured per candidate; without = heuristic run-quality score.union — collect every candidate's findings, de-duplicate by signature.vote — group answers; accept the group reaching --quorum (0 = simple majority). Supports "N skeptics try to refute; keep if a majority fail"./swarm "optimize <X>" (--reducer best --fitness-cmd ...) needs a real measurement. Resolve in order:
npm run build && stat -c%s dist/bundle.js, pytest -q | tail -1, hyperfine ./bin.Map it onto flags: --fitness-cmd (command run in each worktree), --metric-parse (json:<dotted.key> | regex:<pat> | stdout_float | exit_code), --direction (min/max), --gate-cmd (correctness gate that must exit 0), --baseline (auto measures HEAD once before wave 1, or a number), --improve-margin, --search-space (globs candidates may change).
Validate the fitness before any wave runs (mandatory). A buggy objective silently optimizes the wrong thing:
Only a fitness that passes validation may drive a search.
Resolve the job from the goal: (1) explicit args, (2) repo inference (test/build/bench/lint commands, an existing benchmark skill), (3) ≤3 questions for what's still missing — typically what command measures the objective?, what must not regress?, which files/knobs may candidates change?. Project-specific knowledge lives in the elicited commands, not the engine.
--reducer/--mode/fitness flags when the goal calls for optimize/search/verify.Autonomous unattended mode.
Minimal-toolset mode.
Main coding mode.
Isolated plan execution mode.
Read-only codebase explorer mode.
General-purpose catch-all mode.