Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

fleet-worker

БесплатноЗапускает вложенные скриптыНе проверен

One cheap headless Claude Code worker on a cheaper brain (GLM via z.ai, or Sonnet/Haiku) - full tool harness, isolated git worktree + CLAUDE_CONFIG_DIR…

0xDarkMatterот 0xDarkMatter★ 86 звёзд на GitHub

Об этом скилле

fleet-worker

Run a cheap headless Claude Code worker on a cheaper model and let an Opus orchestrator (this session) fan workers out in parallel, then verify and land their work. The worker keeps Claude Code's entire tool harness (Read/Write/Edit/Bash/Glob/Grep/Task/MCP/hooks) — only the brain is swapped to a cheaper model via env — a cheaper Anthropic model (Sonnet/Haiku) or a non-Anthropic endpoint. GLM-5.3 (glm-5.3) on z.ai is the default worked example; the mechanism is provider- and model-agnostic (any Anthropic-compatible endpoint).

Want to offload to Grok (xAI's grok CLI)? That's not this skill. Every fleet-worker brain is a claude -p process pointed at an Anthropic-compatible endpoint. Grok Build CLI is its own binary and protocol (grok -p, auth via GROK_DEPLOYMENT_KEY), not a claude -p wrapper — so it can't ride fleet-worker's launcher. Grok is a first-class worker in fleetflow instead (alongside Codex), which spawns heterogeneous OS-process workers of different binaries — now its own repo at 0xDarkMatter/fleetflow, mounted as the /fleetflow skill. Use fleetflow for a Grok lane or any mixed-provider fan-out.

This is the spawning layer. fleet-ops is the landing layer. fleet-worker produces branches cheaply; fleet-ops lands them through a test gate with your review. See references/fleet-ops-handoff.md.

The architecture crux: per-agent model = process isolation

ANTHROPIC_BASE_URL and the ANTHROPIC_DEFAULT_*_MODEL mapping vars are process-global — read once per claude process, applied to every model call it makes (including in-process Task subagents). There is no per-agent override. So you cannot keep one Opus session and have its subagents secretly run on GLM. The only way to pair a GLM-brained agent with an Opus orchestrator is a separate OS process with its own env block. That process is fleet-worker.

The load-bearing rule: auth isolation (do not skip)

On any machine also logged into a Claude.ai/Anthropic subscription, the naïve "just set ANTHROPIC_AUTH_TOKEN" launcher fails with 401 token expired or incorrect — the host's stored subscription OAuth token (~/.claude.json oauthAccount + forceLoginMethod) takes precedence and gets sent to the non-Anthropic endpoint, which rejects it. --settings overrides do not fix it. The fix is a dedicated, empty config dir:

export CLAUDE_CONFIG_DIR="$HOME/.fleet-worker/cfg"   # no inherited OAuth/hooks

The launcher sets this automatically. It also gives each worker a clean hook/permission/MCP profile so it can't trip the host's hooks. Full analysis in references/fleet-worker-spec.md §4.

Giving a worker skills

The isolated config dir starts clean — the worker inherits none of the host's skills, MCP servers, or hooks (that isolation is what keeps it off your credentials). So provision what a worker should have: drop skill dirs into the worker's own config ($FLEET_WORKER_CONFIG_DIR/skills/<name>/) or commit them to the project's .claude/skills/ in the worktree. The cheap brain then loads the same on-demand, progressively-disclosed procedural knowledge your orchestrator has — often the cheapest way to lift a weak model's output on a specialized task.

Setup

  1. Install — these scripts ship with the skill. After scripts/install.sh they live at ~/.claude/skills/fleet-worker/scripts/. Either call them by that path, or symlink onto PATH for convenience:
    ln -s ~/.claude/skills/fleet-worker/scripts/fleet-worker ~/.local/bin/fleet-worker
    ln -s ~/.claude/skills/fleet-worker/scripts/fleet-collect.sh ~/.local/bin/fleet-collect.sh
    
  2. Provide the key (the launcher never prints it; resolution order):
    • export ANTHROPIC_AUTH_TOKEN=<key>, or
    • export FLEET_WORKER_KEYRING_SERVICE=<svc> FLEET_WORKER_KEYRING_KEY=<name> (uses keyring get), or
    • export ZHIPU_API_KEY=<key> (or GLM_API_KEY).
  3. Preflight — bash scripts/fleet-doctor.sh --offline (structural) or --live (pings the endpoint, then runs one real claude turn through the launcher — the endpoint can accept a model id the CLI refuses; warns about the §4 oauth trap). The doctor and the launcher share one key resolver (scripts/fleet-lib.sh), so --live resolves exactly the key a lane would.

Config knobs (env, all optional)

Var Default Purpose
FLEET_WORKER_BASE_URL https://api.z.ai/api/anthropic Anthropic-compatible endpoint
FLEET_WORKER_MODEL glm-5.3 main model (opus+sonnet mapping); 5.3 reasoning levels are low/high/max via FLEET_WORKER_EFFORT (thinking cannot be disabled on 5.3)
FLEET_WORKER_SMALL_MODEL glm-4.5-air background/cheap model (haiku mapping)
FLEET_WORKER_CONFIG_DIR ~/.fleet-worker/cfg
Полный SKILL.md на GitHub

Установить fleet-worker в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Read
Bash
Glob
Grep
AskUserQuestion

Вложенные файлы

assets/route.jsassets/worker-settings.jsonreferences/fleet-ops-handoff.mdreferences/fleet-worker-spec.mdreferences/model-routing.mdscripts/fleet-collect.shscripts/fleet-doctor.shscripts/fleet-lib.shscripts/fleet-workerscripts/fleet-worker.ps1

FAQ

Что делает скилл fleet-worker?

One cheap headless Claude Code worker on a cheaper brain (GLM via z.ai, or Sonnet/Haiku) - full tool harness, isolated git worktree + CLAUDE_CONFIG_DIR - fanned out and gated by an Opus orchestrator. Triggers: fleet-worker, GLM worker, grunt worker, cheap parallel agent, offload to GLM, sonnet worker, haiku worker.

Как установить скилл fleet-worker?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл fleet-worker запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить fleet-worker с