swarm-resume — скилл для Claude Code: что делает и как установить
Скилл swarm-resume для Claude Code восстанавливает состояние плана роя и очищает зависшие git-ветки, чтобы продолжить выполнение задач по готовому плану.
MIT ★ 539 обновлён 2026-10-29
npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a claude-codeЧто делает swarm-resume
Скилл содержит протокол режима RESUME для среды opencode-swarm. Архитектор загружает эту инструкцию по требованию, когда нужно продолжить выполнение задач из файла .swarm/plan.md либо переключить проект между локальным и облачным окружением.
Сначала агент сверяет поле Swarm в заголовке плана с текущим идентификатором роя. Если они совпадают, запускается утилита /swarm reset-session, которая вычищает зависшие каталоги .swarm-worktrees/ и ветки swarm-lane/*. Если идентификатор отличается, протокол удаляет чужой блок SME Cache из context.md, сбрасывает память предыдущего агента и прописывает активный рой.
Править .swarm/plan.md вручную нельзя: файл является производной проекцией, поэтому любые обновления заголовка разрешено выполнять только через инструмент save_plan.
Какие задачи решает
- продолжить прерванное выполнение задач по плану
.swarm/plan.md - очистить зависшие ветки
swarm-lane/*и папки.swarm-worktrees/ - перенести утверждённый план на другой идентификатор роя
- сбросить устаревший SME Cache в
context.mdперед стартом
Примеры запросов агенту
- Продолжи выполнение плана роя с текущей задачи
- Возобнови сессию роя и очисти старые ветки воркспейса
- Сверь идентификатор роя в .swarm/plan.md и переключи контекст
Как установить swarm-resume
1Через Skills CLI (Vercel)
npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a claude-code2Вручную: положить файлы
~/.claude/skills/swarm-resume/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/swarm-resume/
1Через Skills CLI (Vercel)
npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a codex2Вручную: положить файлы
.agents/skills/swarm-resume/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a cursor2Вручную: положить файлы
.cursor/skills/swarm-resume/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install ZaxbyHub/opencode-swarm .claude/skills/swarm-resume2Вручную: положить файлы
.github/skills/swarm-resume/SKILL.md1Через Skills CLI (Vercel)
npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a gemini-cli2Командой платформы
gemini skills install https://github.com/ZaxbyHub/opencode-swarm --path .claude/skills/swarm-resumeВручную: положить файлы
.devin/skills/swarm-resume/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о swarm-resume
Как установить swarm-resume в Claude Code?
Выполните команду npx skills add ZaxbyHub/opencode-swarm --skill swarm-resume -a claude-code в терминале проекта.
Что произойдёт, если файл .swarm/plan.md отсутствует?
Агент определит проект как новый и перейдёт в режим MODE: SPECIFY. В этом режиме он запустит утилиту complexity_hotspots за 90 дней и соберёт базовый состав зависимостей через sbom_generate с параметром scope='all'.
Зачем запускается сброс сессии перед возобновлением?
Команда /swarm reset-session удаляет оставшиеся от прошлой сессии каталоги .swarm-worktrees/ и ветки swarm-lane/*, чтобы агент не столкнулся с конфликтами файловой системы.
Исходный текст
SKILL.md · MIT
---
name: swarm-resume
description: >
Full execution protocol for MODE: RESUME -- continuing an existing approved plan safely from current state.
metadata:
audience: swarm-plugin
---
# Resume Protocol
This protocol is loaded on demand by the architect runtime. The architect prompt keeps only activation, action, and hard safety constraints; the full execution details live here.
### MODE: RESUME
If .swarm/plan.md exists:
1. Read plan.md header for "Swarm:" field
2. If Swarm field missing or matches the active swarm id:
- Reconcile stale worktree state before resuming: prune/adopt stale `.swarm-worktrees/` lane directories and `swarm-lane/*` git branches left from the prior session. Drive this via the `/swarm reset-session` recovery command (internal: `cleanupOrphanedBranches`) so the resumed run starts from a clean provisioning state.
- Resume at current task
3. If Swarm field differs (e.g., plan says "local" but the active swarm id is "cloud"):
- Update the plan's Swarm field to the active swarm id via `save_plan` (do not hand-edit plan.md — it is a derived projection).
- Purge any memory blocks (persona, agent_role, etc.) that reference a different swarm's identity — your identity comes from this system prompt only
- Delete the SME Cache section from context.md (stale from other swarm's agents)
- Update context.md Swarm field to the active swarm id
- Inform user: "Resuming project from [other] swarm. Cleared stale context. Ready to continue."
- Reconcile stale worktree state before resuming: prune/adopt stale `.swarm-worktrees/` lane directories and `swarm-lane/*` git branches left from the prior session. Drive this via the `/swarm reset-session` recovery command (internal: `cleanupOrphanedBranches`) so the resumed run starts from a clean provisioning state.
- Resume at current task
If .swarm/plan.md does not exist → New project, proceed to MODE: SPECIFY
If new project: Run `complexity_hotspots` tool (90 days) to generate a risk map. Note modules with recommendation "security_review" or "full_gates" in context.md for stricter QA gates during QA gate selection (stricter gates). Optionally run `todo_extract` to capture existing technical debt for plan consideration. After initial discovery, run `sbom_generate` with scope='all' to capture baseline dependency inventory (saved to .swarm/evidence/sbom/).
© ZaxbyHub · MIT · ZaxbyHub/opencode-swarm