[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7C0RWHT8H9ZE8C919HFGN25":3,"skill-same:01M7C0RWHT8H9ZE8C919HFGN25":50},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":26,"repositoryHtmlUrl":27,"repositoryHomepageUrl":6,"ownerHtmlUrl":28,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":29,"install":30,"resources":43},"01M7C0RWHT8H9ZE8C919HFGN25","driving-claude-code-sessions",null,"Use when acting as a project manager that delegates tasks to other coding-agent sessions (Claude Code, Codex, or Pi) - launch workers, assign them work, monitor progress, review their tool calls, and collect results","zak-keown\u002Fmoe","zak-keown","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F320717241?v=4","01M7BZFXME0NW6TQX0H7AZM2KS","01M7BZFXN32VR0JN5AATRD53H4",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe-crew\u002F.cursor-plugin\u002Fskills\u002Fdriving-claude-code-sessions\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: driving-claude-code-sessions\ndescription: Use when acting as a project manager that delegates tasks to other coding-agent sessions (Claude Code, Codex, or Pi) - launch workers, assign them work, monitor progress, review their tool calls, and collect results\n---\n\n# Driving Coding-Agent Sessions\n\n## Overview\n\nYou can launch coding-agent sessions — Claude Code, Codex, or Pi — as \"workers\" in tmux, send them prompts, wait for them to finish, read their output, and hand them off to a human. Workers run with permissions bypassed, so they execute tool calls without prompting. Each worker emits lifecycle events to a JSONL file so the controller can observe what it's doing — Claude and Codex through their hook systems, Pi through a native extension `moe-crew` loads into it.\n\nAll operations go through a single CLI: `moe-crew`. After launching a worker, the controller receives a **shim path** at `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>` that bakes in the worker handle. Every per-worker operation goes through that path — no positional state to thread between calls, no absolute skill path to prepend. A small set of environment variables tune behavior; see [Environment variables](#environment-variables) at the bottom.\n\nThe shim path is deterministic: if you pick a memorable tmux name at launch, you can reconstruct `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>` whenever you need it. For agents driving via tool calls, that's the right model — shell state doesn't persist between calls, so a `SHIM=...; $SHIM cmd` pattern just adds noise. The examples below use the bare path.\n\n## Harnesses\n\nPick a harness with `--harness` at launch:\n\n```bash\n$SKILL\u002Fmoe-crew launch --harness codex my-task \u002Fpath\u002Fto\u002Fproject\n$SKILL\u002Fmoe-crew launch --harness pi    my-task \u002Fpath\u002Fto\u002Fproject\n```\n\nWithout `--harness`, `MOE_CREW_DEFAULT_HARNESS` wins; when it is unset,\n`moe-crew` selects the sole installed Claude Code, Codex, or Pi executable. It\nexits with usage code 2 and lists the installed choices when selection is\nambiguous. Packs can declare `defaultHarness`, and each worker's `harness`\nstill overrides every default.\n\nThe controller-facing command surface is **identical across all three harnesses** — `launch`, `send`, `converse`, `wait-for-turn`, `read-turn`, `read-events`, `status`, `stop`, and `handoff` behave the same regardless of harness. A few things differ:\n\n- **Auth.** Each harness authenticates from its own home — Claude `~\u002F.claude`, Codex `~\u002F.codex`, Pi `~\u002F.pi\u002Fagent`. `moe-crew` stages that login into the worker at launch, so to rotate credentials, relaunch.\n- **`adopt` is Claude-only.** Claude takes a caller-assigned session id, so a session can be resumed by id (`claude --resume`). Codex and Pi mint their own ids on the first prompt and offer no resume-by-id — relaunch them instead.\n- **Codex isn't queryable until its first prompt.** Codex mints its session id only when you send the first prompt, so between `launch` and the first `send`\u002F`converse` a codex worker's `status`, `session-id`, and `wait-for-turn` return `no worker known` — it *is* running, it just hasn't registered yet. `converse` handles this internally, so the typical launch→converse path is fine; only the lower-level commands see the gap. (Claude takes its id at launch and Pi registers at launch, so both are queryable immediately.)\n\n## Prerequisites\n\n- **tmux**\n- a harness CLI — at least the one you launch: **claude**, **codex**, or **pi**\n\n(No `jq` and no bash hooks: `moe-crew` is a TypeScript\u002Fnode tool and its hooks are node programs. `node` is required, but it's already present wherever Claude Code runs.)\n\n## Setup\n\nThe CLI lives at `\u003Cskill>\u002Fscripts\u002Fmoe-crew`. Top-level subcommands need the skill path:\n\n- `moe-crew launch [--harness \u003Cclaude|codex|pi>] \u003Ctmux-name> \u003Ccwd> [-- harness-args...]` — bootstrap a worker (default resolution is described under [Harnesses](#harnesses))\n- `moe-crew adopt \u003Ctmux-name> \u003Ccwd> \u003Csession-id> [-- claude-args...]` — re-adopt an existing Claude session as a worker (claude-only; see [Recovering workers](#recovering-workers-after-a-reboot))\n- `moe-crew list [--all]` — enumerate workers\n- `moe-crew grant-consent` — one-time consent for running workers with permissions bypassed\n\nOnce a worker is launched, run subsequent commands against `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>`:\n\n```bash\nSKILL=\u002Fabs\u002Fpath\u002Fto\u002Fskill\u002Fscripts\n$SKILL\u002Fmoe-crew grant-consent                          # one-time per machine\n$SKILL\u002Fmoe-crew launch my-task \u002Fpath\u002Fto\u002Fproject        # stdout: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task status               # use the shim directly\n```\n\nPick a memorable tmux name at launch; the shim path is then deterministic. (You *can* capture it into a shell variable in an interactive shell, but for agent-driven workflows the bare path is simpler — there's no shell state to lose between calls.)\n\n## Workflow\n\nIn examples below, `$SKILL` is the absolute path to `skills\u002Fdriving-claude-code-sessions\u002Fscripts`. `WORKER` is the bare shim path (e.g. `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task`) — substitute the deterministic path for your worker.\n\n### 1. Launch\n\n```bash\n$SKILL\u002Fmoe-crew launch my-task \u002Fpath\u002Fto\u002Fproject\n# stdout: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task\n# stderr: Worker launched. tmux\u002Fsession_id\u002Fcwd\u002Fevents\u002Freproduce\n```\n\n`moe-crew launch`:\n- Writes a 3-line shim at `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task`\n- Starts tmux and the harness in it\n- Blocks until the worker is ready — Claude (which takes a caller-assigned session id) waits for its `session_start` event; Codex and Pi mint their own ids on the first prompt, so launch settles their TUI and the worker's meta self-registers when it fires its first event\n- Prints the shim path on stdout (one line)\n- Prints a \"Worker launched\" panel on stderr — the `reproduce:` line is the exact command to relaunch with the same args\n\nPass harness CLI args after a `--` separator, or pick an explicit harness with `--harness`:\n```bash\n$SKILL\u002Fmoe-crew launch my-task \u002Fpath\u002Fto\u002Fproject -- --model sonnet\n$SKILL\u002Fmoe-crew launch --harness codex my-task \u002Fpath\u002Fto\u002Fproject\n```\n\n### 2. Converse (the typical case)\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse \"Refactor the auth module\" 300\n```\n\n`converse` sends the prompt, waits for the worker to finish, and prints the final assistant text on stdout. For tool-heavy turns where the bare text strips the interesting part, use `--with-turn` to get the full markdown:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse --with-turn \"Run the failing tests\" 600\n```\n\nMulti-turn just works — the wait tracks turn boundaries automatically:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse \"Write tests for the auth module\" 300\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse \"Add edge cases for expired tokens\" 300\n```\n\n### 3. Lower-level control\n\nIf you need to drive the worker more directly:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task send \"Refactor the auth module\"     # send without waiting\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task wait-for-turn 300                   # block until stop or session_end\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task status                              # idle | working | terminated | gone | unknown\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-turn                           # last turn as markdown (tool results truncated to 5 lines)\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-turn --full                    # last turn with complete tool results\n```\n\n### 4. Watching what the worker does\n\nEvery tool call emits a `pre_tool_use` event with the tool name and input. Tail the event stream to watch in real time:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events --follow &\nMONITOR_PID=$!\n# ... do other work ...\nkill $MONITOR_PID\n```\n\nOr pull events after the fact:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events                       # all events\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events --last 5\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events --type pre_tool_use\n```\n\n`--type` accepts one of: `session_start`, `user_prompt_submit`, `pre_tool_use`, `post_tool_use`, `stop`, `session_end`. Unknown event names fail fast. (Claude workers emit `pre_tool_use` but not `post_tool_use`; Codex and Pi emit both.)\n\nIf you see something you don't want, stop the worker:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task stop\n```\n\n### 5. Stop and clean up\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task stop\n```\n\nSends `\u002Fexit`, waits up to 10s for `session_end`, kills the tmux session if still running, and removes the meta, events, **and shim** files.\n\n`stop` is destructive: the worker is gone and the shim path stops working. If you wanted the worker around for follow-up turns or a parallel workflow, don't call `stop` until you're done with it. To resume work under the same name, relaunch — `moe-crew launch my-task \u002Fpath\u002Fto\u002Fproject` again — and you'll get a fresh worker at the same shim path.\n\nAfter `stop`, the shim no longer exists, so invoking it again surfaces a shell error along the lines of `no such file or directory: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task` (the exact wording depends on your shell). That's expected; the worker is gone.\n\n### 6. Hand off to a human\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task handoff\n```\n\nPrints attach instructions for a human to take over the tmux session.\n\n### Finding workers\n\n```bash\n$SKILL\u002Fmoe-crew list                      # live workers (idle\u002Fworking\u002Fterminated)\n$SKILL\u002Fmoe-crew list --all                # include 'gone' workers (tmux already exited)\n$SKILL\u002Fmoe-crew list api                  # substring filter on tmux name\n$SKILL\u002Fmoe-crew prune                     # remove dead workers + orphaned sidecars\u002Fshims\n```\n\n## Reference\n\n```\nmoe-crew launch [--harness \u003Cclaude|codex|pi>] \u003Ctmux-name> \u003Ccwd> [-- harness-args...]\nmoe-crew adopt \u003Ctmux-name> \u003Ccwd> \u003Csession-id> [-- claude-args...]   # claude-only\nmoe-crew list [--all] [\u003Cpattern>]\nmoe-crew prune                          # remove dead\u002Forphaned worker state\nmoe-crew grant-consent\n\n\u003Cshim> converse [--with-turn] \u003Cprompt> [timeout=120]\n\u003Cshim> send \u003Cprompt>\n\u003Cshim> wait-for-turn [timeout=60] [--after-line N]\n\u003Cshim> status\n\u003Cshim> read-events [--last N] [--type T] [--follow]   # --last caps the --follow backlog\n\u003Cshim> read-turn [--full]\n\u003Cshim> stop\n\u003Cshim> handoff\n\u003Cshim> session-id\n\u003Cshim> events-file\n```\n\n`\u003Cshim>` is `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>`. Run `moe-crew help` for the same surface.\n\n## Common Patterns\n\n### Fan-Out: Multiple Workers in Parallel\n\nEach worker gets its OWN linked git worktree — never a shared checkout. Two\nworkers writing into the same tree collide on the axis the parallel-\nimplementation worktree gate is built to prevent (see the `moe` plugin's\n`dispatch-agents`, \"Safe Parallel Implementation: The Worktree\nGate\", and its two-rung fallback ladder). Create all worktrees first, branched\nfrom one recorded base SHA. Before launching anything, validate every cwd has\none of the wave's pairwise-unique linked Git directories:\n\n```bash\n# One recorded base for the whole wave — every worker branches from it.\nBASE=$(git -C ~\u002Fproj rev-parse HEAD)\n\ngit -C ~\u002Fproj worktree add ~\u002Fproj-worktrees\u002Fworker-api -b feat\u002Fapi \"$BASE\"\ngit -C ~\u002Fproj worktree add ~\u002Fproj-worktrees\u002Fworker-ui  -b feat\u002Fui  \"$BASE\"\n\n# For each cwd, --git-dir and --git-common-dir must differ. The two --git-dir\n# results must also differ from each other.\ngit -C ~\u002Fproj-worktrees\u002Fworker-api rev-parse --path-format=absolute --git-dir\ngit -C ~\u002Fproj-worktrees\u002Fworker-api rev-parse --path-format=absolute --git-common-dir\ngit -C ~\u002Fproj-worktrees\u002Fworker-ui rev-parse --path-format=absolute --git-dir\ngit -C ~\u002Fproj-worktrees\u002Fworker-ui rev-parse --path-format=absolute --git-common-dir\n\n$SKILL\u002Fmoe-crew launch worker-api ~\u002Fproj-worktrees\u002Fworker-api\n$SKILL\u002Fmoe-crew launch worker-ui  ~\u002Fproj-worktrees\u002Fworker-ui\n\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-api send \"Add pagination to \u002Fusers\"\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-ui  send \"Add a loading spinner to the user list\"\n\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-api wait-for-turn 600\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-ui  wait-for-turn 600\n\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-api stop\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-ui  stop\n\n# Integrate the wave: merge each branch into BASE, run the suite, THEN start\n# the next wave from the merged head.\n```\n\n`moe-crew launch` accepts an arbitrary per-worker `cwd`; it does not create\nthe worktree for you and does not know about worktrees at all. That step is\ngit, done before dispatch. If two workers' declared work touches the same\nfile, a task is missing `Files:`, `Interfaces:`, `Consumes:`, or `Produces:`,\nor any worktree creation\u002Fvalidation command fails, do not fan them out. Missing\ntask metadata fails validation. A file collision or worktree failure selects\nthe second and only fallback rung: run the whole wave sequentially from the\ncontroller's validated tree. There is no unisolated-parallel rung and no\npartial parallel launch.\n\n### Pipeline: Worker A produces, Worker B consumes\n\n```bash\n$SKILL\u002Fmoe-crew launch spec ~\u002Fproj\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fspec converse \"Write an OpenAPI spec for \u002Fusers to \u002Ftmp\u002Fapi.yaml\" 300\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fspec stop\n\n$SKILL\u002Fmoe-crew launch impl ~\u002Fproj\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fimpl converse \"Implement the endpoint defined in \u002Ftmp\u002Fapi.yaml\" 600\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fimpl stop\n```\n\nDon't trust worker B's summary of what it did — check the produced file. A worker can report success while having written the wrong thing (see *Important Notes*).\n\n## Edge Cases\n\n### Worker crashes mid-turn\n\n`wait-for-turn` matches `stop` OR `session_end`, so it returns when the worker dies. Call `status` afterward: if it's `gone`, the worker crashed.\n\n### After a `converse` timeout, check `status` before `wait-for-turn`\n\nA bare `wait-for-turn` baselines at the *current* end of the events file and waits for the **next** turn-end. If a `converse` timed out, the worker often finishes during the gap — the `stop` has already landed, so a follow-up `wait-for-turn` blocks the entire timeout waiting for a turn that will never start. After a timeout, call `status` first: `idle` means the turn already ended (`read-turn` to read it); `working` means it's still going.\n\n### Recovering workers after a reboot\n\nWorker runtime state (the `meta`\u002F`events`\u002F`shim` files under `\u002Ftmp\u002Fmoe-crew-workers`) lives in `\u002Ftmp`, which macOS clears on reboot — and the tmux panes die with it. But the *conversations* survive: Claude Code persists each session transcript at `~\u002F.claude\u002Fprojects\u002F\u003Cencoded-cwd>\u002F\u003Csession-id>.jsonl`. `moe-crew adopt` brings one back as a live, driveable worker (this is **claude-only** — Codex and Pi mint their own session ids and offer no resume-by-id, so relaunch those instead):\n\n```bash\n$SKILL\u002Fmoe-crew adopt my-task \u002Fpath\u002Fto\u002Fproject \u003Csession-id>\n# stdout: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task   (same shim contract as launch)\n```\n\n**This is claude-only — codex\u002Fpi conversations do NOT survive `stop`.** Codex and Pi run under a staged per-worker home at `\u002Ftmp\u002Fmoe-crew-workers\u002Fhomes\u002F\u003Cname>\u002F` (config, auth, and the rollout\u002Fsession transcript), *not* your real `~\u002F.codex` \u002F `~\u002F.pi`. `stop` removes that home, so the transcript is gone and there is no recovery path — relaunch starts a fresh session. Only claude persists its transcript outside the worker dir (in `~\u002F.claude\u002Fprojects`), which is why only claude is adoptable.\n\n`adopt` pre-writes the meta keyed by `\u003Csession-id>`, starts `claude --resume \u003Csession-id>` (which preserves the id, so the worker emits events normally), and writes the shim — so the resumed conversation is fully driveable (`converse`\u002F`status`\u002F`read-turn`\u002F…), with all prior context intact. If a tmux session of that name already exists (e.g. restored by [tmux-resurrect](https:\u002F\u002Fgithub.com\u002Ftmux-plugins\u002Ftmux-resurrect) \u002F tmux-continuum), `adopt` respawns its pane *in place*, preserving the restored layout; otherwise it opens a new one.\n\nFind a worker's `\u003Csession-id>` from its working directory: the newest `*.jsonl` in `~\u002F.claude\u002Fprojects\u002F\u003Ccwd with every \u002F . _ replaced by ->`. For bulk recovery (e.g. pairing with tmux-continuum's `@continuum-boot`), `examples\u002Frecover-workers.sh` reads a tmux-resurrect snapshot, derives each id, and calls `adopt` per worker — run it with `--dry-run` first. Note: workers are restored as resumed sessions, not their original tool\u002FMCP state; re-pass any launch args (e.g. `-- --model …`) you depended on.\n\n### Lost the shim path\n\nIf you know the tmux name, the path is `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>`. If you don't, `moe-crew list` enumerates everything; `moe-crew list \u003Cpattern>` filters by tmux-name substring.\n\n### Long prompts\n\n`send` uses bracketed-paste, which handles multi-line and special characters. For prompts in the tens-of-KB range, write to a file and tell the worker to read it:\n\n```bash\necho \"Long instructions...\" > \u002Ftmp\u002Finstructions.txt\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task send \"Read \u002Ftmp\u002Finstructions.txt and follow it\"\n```\n\n## Important Notes\n\n- **One controller per worker.** Two controllers driving the same tmux session will collide.\n- **Workers don't share state with the controller** except via files on disk and the event stream.\n- **Shim paths bake in absolute skill paths.** A plugin reinstall at a new location breaks live workers; relaunch them.\n- **moe-crew is a transparent relay, not a validator.** `converse`\u002F`read-turn` return whatever the worker says — verbatim, including when the worker is confidently wrong. For correctness-critical handoffs, verify the produced **artifact on disk**, not the worker's prose self-report.\n\n## Environment variables\n\nThe `moe-crew` CLI honors a small set of env vars. All are optional.\n\n| Variable | Purpose |\n|---|---|\n| `MOE_CREW_DEFAULT_HARNESS` | Default harness after worker and command\u002Fpack selections. Must be `claude`, `codex`, or `pi`. |\n| `MOE_CREW_PLUGIN_ROOT` | Installed moe-crew plugin root. The launcher otherwise derives it from the running bundle. |\n| `MOE_CREW_CLAUDE_BIN` \u002F `MOE_CREW_CODEX_BIN` \u002F `MOE_CREW_PI_BIN` | Path to each harness binary. Default to `claude` \u002F `codex` \u002F `pi` (resolved via `PATH`). Set when a binary is not on `PATH` or you want to pin a specific version. |\n| `MOE_CREW_CODEX_MODEL` \u002F `MOE_CREW_PI_MODEL` | Optional model override for codex \u002F pi workers. Unset = the harness default (codex: `gpt-5.5`; pi: its configured default). |\n| `MOE_CREW_CONVERSE_DIAG_FILE` | When set, `moe-crew converse` writes a post-mortem diagnostic on timeout — `ps` tree, `tmux capture-pane`, last 30 lines of the worker's session JSONL, last 20 lines of the moe-crew events JSONL — to this path, then emits a `moe-crew-diagnostic: \u003Cpath>` pointer to stderr. The file is overwritten on each timeout. Unset = no diagnostic file. Useful when wrapping moe-crew in a harness that can ship the file off-box before the worker is reaped. |\n| `MOE_CREW_WORKER_DIR` | Override the worker dir (default `$XDG_RUNTIME_DIR\u002Fmoe-crew-workers`, or `~\u002F.local\u002Fstate\u002Fmoe-crew\u002Fworkers`). |\n| `MOE_CREW_SUBMIT_TIMEOUT` \u002F `MOE_CREW_SUBMIT_RETRY_INTERVAL` | `send`: seconds to wait for the worker to confirm a pasted prompt (default `10`) and seconds between retry-Enter resends (default `2`). Raise the timeout if a slow tmux session drops the paste. |\n| `MOE_CREW_REGISTER_TIMEOUT` | Seconds the FIRST `send`\u002F`converse` to a derive worker (codex\u002Fpi) waits for it to self-register its session id (default `15`). |\n| `XDG_STATE_HOME` | Durable Moe state root for one-time consent (`$XDG_STATE_HOME\u002Fmoe\u002Fcrew\u002Fconsent`; fallback `~\u002F.local\u002Fstate\u002Fmoe\u002Fcrew\u002Fconsent`). |\n| `HOME` | Harness-owned state root; Claude transcripts live under `~\u002F.claude\u002Fprojects\u002F`. |\n\n`moe-crew help` shows the same surface.\n","# Driving Coding-Agent Sessions\n\n## Overview\n\nYou can launch coding-agent sessions — Claude Code, Codex, or Pi — as \"workers\" in tmux, send them prompts, wait for them to finish, read their output, and hand them off to a human. Workers run with permissions bypassed, so they execute tool calls without prompting. Each worker emits lifecycle events to a JSONL file so the controller can observe what it's doing — Claude and Codex through their hook systems, Pi through a native extension `moe-crew` loads into it.\n\nAll operations go through a single CLI: `moe-crew`. After launching a worker, the controller receives a **shim path** at `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>` that bakes in the worker handle. Every per-worker operation goes through that path — no positional state to thread between calls, no absolute skill path to prepend. A small set of environment variables tune behavior; see [Environment variables](#environment-variables) at the bottom.\n\nThe shim path is deterministic: if you pick a memorable tmux name at launch, you can reconstruct `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>` whenever you need it. For agents driving via tool calls, that's the right model — shell state doesn't persist between calls, so a `SHIM=...; $SHIM cmd` pattern just adds noise. The examples below use the bare path.\n\n## Harnesses\n\nPick a harness with `--harness` at launch:\n\n```bash\n$SKILL\u002Fmoe-crew launch --harness codex my-task \u002Fpath\u002Fto\u002Fproject\n$SKILL\u002Fmoe-crew launch --harness pi    my-task \u002Fpath\u002Fto\u002Fproject\n```\n\nWithout `--harness`, `MOE_CREW_DEFAULT_HARNESS` wins; when it is unset,\n`moe-crew` selects the sole installed Claude Code, Codex, or Pi executable. It\nexits with usage code 2 and lists the installed choices when selection is\nambiguous. Packs can declare `defaultHarness`, and each worker's `harness`\nstill overrides every default.\n\nThe controller-facing command surface is **identical across all three harnesses** — `launch`, `send`, `converse`, `wait-for-turn`, `read-turn`, `read-events`, `status`, `stop`, and `handoff` behave the same regardless of harness. A few things differ:\n\n- **Auth.** Each harness authenticates from its own home — Claude `~\u002F.claude`, Codex `~\u002F.codex`, Pi `~\u002F.pi\u002Fagent`. `moe-crew` stages that login into the worker at launch, so to rotate credentials, relaunch.\n- **`adopt` is Claude-only.** Claude takes a caller-assigned session id, so a session can be resumed by id (`claude --resume`). Codex and Pi mint their own ids on the first prompt and offer no resume-by-id — relaunch them instead.\n- **Codex isn't queryable until its first prompt.** Codex mints its session id only when you send the first prompt, so between `launch` and the first `send`\u002F`converse` a codex worker's `status`, `session-id`, and `wait-for-turn` return `no worker known` — it *is* running, it just hasn't registered yet. `converse` handles this internally, so the typical launch→converse path is fine; only the lower-level commands see the gap. (Claude takes its id at launch and Pi registers at launch, so both are queryable immediately.)\n\n## Prerequisites\n\n- **tmux**\n- a harness CLI — at least the one you launch: **claude**, **codex**, or **pi**\n\n(No `jq` and no bash hooks: `moe-crew` is a TypeScript\u002Fnode tool and its hooks are node programs. `node` is required, but it's already present wherever Claude Code runs.)\n\n## Setup\n\nThe CLI lives at `\u003Cskill>\u002Fscripts\u002Fmoe-crew`. Top-level subcommands need the skill path:\n\n- `moe-crew launch [--harness \u003Cclaude|codex|pi>] \u003Ctmux-name> \u003Ccwd> [-- harness-args...]` — bootstrap a worker (default resolution is described under [Harnesses](#harnesses))\n- `moe-crew adopt \u003Ctmux-name> \u003Ccwd> \u003Csession-id> [-- claude-args...]` — re-adopt an existing Claude session as a worker (claude-only; see [Recovering workers](#recovering-workers-after-a-reboot))\n- `moe-crew list [--all]` — enumerate workers\n- `moe-crew grant-consent` — one-time consent for running workers with permissions bypassed\n\nOnce a worker is launched, run subsequent commands against `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>`:\n\n```bash\nSKILL=\u002Fabs\u002Fpath\u002Fto\u002Fskill\u002Fscripts\n$SKILL\u002Fmoe-crew grant-consent                          # one-time per machine\n$SKILL\u002Fmoe-crew launch my-task \u002Fpath\u002Fto\u002Fproject        # stdout: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task status               # use the shim directly\n```\n\nPick a memorable tmux name at launch; the shim path is then deterministic. (You *can* capture it into a shell variable in an interactive shell, but for agent-driven workflows the bare path is simpler — there's no shell state to lose between calls.)\n\n## Workflow\n\nIn examples below, `$SKILL` is the absolute path to `skills\u002Fdriving-claude-code-sessions\u002Fscripts`. `WORKER` is the bare shim path (e.g. `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task`) — substitute the deterministic path for your worker.\n\n### 1. Launch\n\n```bash\n$SKILL\u002Fmoe-crew launch my-task \u002Fpath\u002Fto\u002Fproject\n# stdout: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task\n# stderr: Worker launched. tmux\u002Fsession_id\u002Fcwd\u002Fevents\u002Freproduce\n```\n\n`moe-crew launch`:\n- Writes a 3-line shim at `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task`\n- Starts tmux and the harness in it\n- Blocks until the worker is ready — Claude (which takes a caller-assigned session id) waits for its `session_start` event; Codex and Pi mint their own ids on the first prompt, so launch settles their TUI and the worker's meta self-registers when it fires its first event\n- Prints the shim path on stdout (one line)\n- Prints a \"Worker launched\" panel on stderr — the `reproduce:` line is the exact command to relaunch with the same args\n\nPass harness CLI args after a `--` separator, or pick an explicit harness with `--harness`:\n```bash\n$SKILL\u002Fmoe-crew launch my-task \u002Fpath\u002Fto\u002Fproject -- --model sonnet\n$SKILL\u002Fmoe-crew launch --harness codex my-task \u002Fpath\u002Fto\u002Fproject\n```\n\n### 2. Converse (the typical case)\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse \"Refactor the auth module\" 300\n```\n\n`converse` sends the prompt, waits for the worker to finish, and prints the final assistant text on stdout. For tool-heavy turns where the bare text strips the interesting part, use `--with-turn` to get the full markdown:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse --with-turn \"Run the failing tests\" 600\n```\n\nMulti-turn just works — the wait tracks turn boundaries automatically:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse \"Write tests for the auth module\" 300\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task converse \"Add edge cases for expired tokens\" 300\n```\n\n### 3. Lower-level control\n\nIf you need to drive the worker more directly:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task send \"Refactor the auth module\"     # send without waiting\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task wait-for-turn 300                   # block until stop or session_end\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task status                              # idle | working | terminated | gone | unknown\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-turn                           # last turn as markdown (tool results truncated to 5 lines)\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-turn --full                    # last turn with complete tool results\n```\n\n### 4. Watching what the worker does\n\nEvery tool call emits a `pre_tool_use` event with the tool name and input. Tail the event stream to watch in real time:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events --follow &\nMONITOR_PID=$!\n# ... do other work ...\nkill $MONITOR_PID\n```\n\nOr pull events after the fact:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events                       # all events\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events --last 5\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task read-events --type pre_tool_use\n```\n\n`--type` accepts one of: `session_start`, `user_prompt_submit`, `pre_tool_use`, `post_tool_use`, `stop`, `session_end`. Unknown event names fail fast. (Claude workers emit `pre_tool_use` but not `post_tool_use`; Codex and Pi emit both.)\n\nIf you see something you don't want, stop the worker:\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task stop\n```\n\n### 5. Stop and clean up\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task stop\n```\n\nSends `\u002Fexit`, waits up to 10s for `session_end`, kills the tmux session if still running, and removes the meta, events, **and shim** files.\n\n`stop` is destructive: the worker is gone and the shim path stops working. If you wanted the worker around for follow-up turns or a parallel workflow, don't call `stop` until you're done with it. To resume work under the same name, relaunch — `moe-crew launch my-task \u002Fpath\u002Fto\u002Fproject` again — and you'll get a fresh worker at the same shim path.\n\nAfter `stop`, the shim no longer exists, so invoking it again surfaces a shell error along the lines of `no such file or directory: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task` (the exact wording depends on your shell). That's expected; the worker is gone.\n\n### 6. Hand off to a human\n\n```bash\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task handoff\n```\n\nPrints attach instructions for a human to take over the tmux session.\n\n### Finding workers\n\n```bash\n$SKILL\u002Fmoe-crew list                      # live workers (idle\u002Fworking\u002Fterminated)\n$SKILL\u002Fmoe-crew list --all                # include 'gone' workers (tmux already exited)\n$SKILL\u002Fmoe-crew list api                  # substring filter on tmux name\n$SKILL\u002Fmoe-crew prune                     # remove dead workers + orphaned sidecars\u002Fshims\n```\n\n## Reference\n\n```\nmoe-crew launch [--harness \u003Cclaude|codex|pi>] \u003Ctmux-name> \u003Ccwd> [-- harness-args...]\nmoe-crew adopt \u003Ctmux-name> \u003Ccwd> \u003Csession-id> [-- claude-args...]   # claude-only\nmoe-crew list [--all] [\u003Cpattern>]\nmoe-crew prune                          # remove dead\u002Forphaned worker state\nmoe-crew grant-consent\n\n\u003Cshim> converse [--with-turn] \u003Cprompt> [timeout=120]\n\u003Cshim> send \u003Cprompt>\n\u003Cshim> wait-for-turn [timeout=60] [--after-line N]\n\u003Cshim> status\n\u003Cshim> read-events [--last N] [--type T] [--follow]   # --last caps the --follow backlog\n\u003Cshim> read-turn [--full]\n\u003Cshim> stop\n\u003Cshim> handoff\n\u003Cshim> session-id\n\u003Cshim> events-file\n```\n\n`\u003Cshim>` is `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>`. Run `moe-crew help` for the same surface.\n\n## Common Patterns\n\n### Fan-Out: Multiple Workers in Parallel\n\nEach worker gets its OWN linked git worktree — never a shared checkout. Two\nworkers writing into the same tree collide on the axis the parallel-\nimplementation worktree gate is built to prevent (see the `moe` plugin's\n`dispatch-agents`, \"Safe Parallel Implementation: The Worktree\nGate\", and its two-rung fallback ladder). Create all worktrees first, branched\nfrom one recorded base SHA. Before launching anything, validate every cwd has\none of the wave's pairwise-unique linked Git directories:\n\n```bash\n# One recorded base for the whole wave — every worker branches from it.\nBASE=$(git -C ~\u002Fproj rev-parse HEAD)\n\ngit -C ~\u002Fproj worktree add ~\u002Fproj-worktrees\u002Fworker-api -b feat\u002Fapi \"$BASE\"\ngit -C ~\u002Fproj worktree add ~\u002Fproj-worktrees\u002Fworker-ui  -b feat\u002Fui  \"$BASE\"\n\n# For each cwd, --git-dir and --git-common-dir must differ. The two --git-dir\n# results must also differ from each other.\ngit -C ~\u002Fproj-worktrees\u002Fworker-api rev-parse --path-format=absolute --git-dir\ngit -C ~\u002Fproj-worktrees\u002Fworker-api rev-parse --path-format=absolute --git-common-dir\ngit -C ~\u002Fproj-worktrees\u002Fworker-ui rev-parse --path-format=absolute --git-dir\ngit -C ~\u002Fproj-worktrees\u002Fworker-ui rev-parse --path-format=absolute --git-common-dir\n\n$SKILL\u002Fmoe-crew launch worker-api ~\u002Fproj-worktrees\u002Fworker-api\n$SKILL\u002Fmoe-crew launch worker-ui  ~\u002Fproj-worktrees\u002Fworker-ui\n\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-api send \"Add pagination to \u002Fusers\"\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-ui  send \"Add a loading spinner to the user list\"\n\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-api wait-for-turn 600\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-ui  wait-for-turn 600\n\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-api stop\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fworker-ui  stop\n\n# Integrate the wave: merge each branch into BASE, run the suite, THEN start\n# the next wave from the merged head.\n```\n\n`moe-crew launch` accepts an arbitrary per-worker `cwd`; it does not create\nthe worktree for you and does not know about worktrees at all. That step is\ngit, done before dispatch. If two workers' declared work touches the same\nfile, a task is missing `Files:`, `Interfaces:`, `Consumes:`, or `Produces:`,\nor any worktree creation\u002Fvalidation command fails, do not fan them out. Missing\ntask metadata fails validation. A file collision or worktree failure selects\nthe second and only fallback rung: run the whole wave sequentially from the\ncontroller's validated tree. There is no unisolated-parallel rung and no\npartial parallel launch.\n\n### Pipeline: Worker A produces, Worker B consumes\n\n```bash\n$SKILL\u002Fmoe-crew launch spec ~\u002Fproj\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fspec converse \"Write an OpenAPI spec for \u002Fusers to \u002Ftmp\u002Fapi.yaml\" 300\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fspec stop\n\n$SKILL\u002Fmoe-crew launch impl ~\u002Fproj\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fimpl converse \"Implement the endpoint defined in \u002Ftmp\u002Fapi.yaml\" 600\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fimpl stop\n```\n\nDon't trust worker B's summary of what it did — check the produced file. A worker can report success while having written the wrong thing (see *Important Notes*).\n\n## Edge Cases\n\n### Worker crashes mid-turn\n\n`wait-for-turn` matches `stop` OR `session_end`, so it returns when the worker dies. Call `status` afterward: if it's `gone`, the worker crashed.\n\n### After a `converse` timeout, check `status` before `wait-for-turn`\n\nA bare `wait-for-turn` baselines at the *current* end of the events file and waits for the **next** turn-end. If a `converse` timed out, the worker often finishes during the gap — the `stop` has already landed, so a follow-up `wait-for-turn` blocks the entire timeout waiting for a turn that will never start. After a timeout, call `status` first: `idle` means the turn already ended (`read-turn` to read it); `working` means it's still going.\n\n### Recovering workers after a reboot\n\nWorker runtime state (the `meta`\u002F`events`\u002F`shim` files under `\u002Ftmp\u002Fmoe-crew-workers`) lives in `\u002Ftmp`, which macOS clears on reboot — and the tmux panes die with it. But the *conversations* survive: Claude Code persists each session transcript at `~\u002F.claude\u002Fprojects\u002F\u003Cencoded-cwd>\u002F\u003Csession-id>.jsonl`. `moe-crew adopt` brings one back as a live, driveable worker (this is **claude-only** — Codex and Pi mint their own session ids and offer no resume-by-id, so relaunch those instead):\n\n```bash\n$SKILL\u002Fmoe-crew adopt my-task \u002Fpath\u002Fto\u002Fproject \u003Csession-id>\n# stdout: \u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task   (same shim contract as launch)\n```\n\n**This is claude-only — codex\u002Fpi conversations do NOT survive `stop`.** Codex and Pi run under a staged per-worker home at `\u002Ftmp\u002Fmoe-crew-workers\u002Fhomes\u002F\u003Cname>\u002F` (config, auth, and the rollout\u002Fsession transcript), *not* your real `~\u002F.codex` \u002F `~\u002F.pi`. `stop` removes that home, so the transcript is gone and there is no recovery path — relaunch starts a fresh session. Only claude persists its transcript outside the worker dir (in `~\u002F.claude\u002Fprojects`), which is why only claude is adoptable.\n\n`adopt` pre-writes the meta keyed by `\u003Csession-id>`, starts `claude --resume \u003Csession-id>` (which preserves the id, so the worker emits events normally), and writes the shim — so the resumed conversation is fully driveable (`converse`\u002F`status`\u002F`read-turn`\u002F…), with all prior context intact. If a tmux session of that name already exists (e.g. restored by [tmux-resurrect](https:\u002F\u002Fgithub.com\u002Ftmux-plugins\u002Ftmux-resurrect) \u002F tmux-continuum), `adopt` respawns its pane *in place*, preserving the restored layout; otherwise it opens a new one.\n\nFind a worker's `\u003Csession-id>` from its working directory: the newest `*.jsonl` in `~\u002F.claude\u002Fprojects\u002F\u003Ccwd with every \u002F . _ replaced by ->`. For bulk recovery (e.g. pairing with tmux-continuum's `@continuum-boot`), `examples\u002Frecover-workers.sh` reads a tmux-resurrect snapshot, derives each id, and calls `adopt` per worker — run it with `--dry-run` first. Note: workers are restored as resumed sessions, not their original tool\u002FMCP state; re-pass any launch args (e.g. `-- --model …`) you depended on.\n\n### Lost the shim path\n\nIf you know the tmux name, the path is `\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002F\u003Ctmux-name>`. If you don't, `moe-crew list` enumerates everything; `moe-crew list \u003Cpattern>` filters by tmux-name substring.\n\n### Long prompts\n\n`send` uses bracketed-paste, which handles multi-line and special characters. For prompts in the tens-of-KB range, write to a file and tell the worker to read it:\n\n```bash\necho \"Long instructions...\" > \u002Ftmp\u002Finstructions.txt\n\u002Ftmp\u002Fmoe-crew-workers\u002Fbin\u002Fmy-task send \"Read \u002Ftmp\u002Finstructions.txt and follow it\"\n```\n\n## Important Notes\n\n- **One controller per worker.** Two controllers driving the same tmux session will collide.\n- **Workers don't share state with the controller** except via files on disk and the event stream.\n- **Shim paths bake in absolute skill paths.** A plugin reinstall at a new location breaks live workers; relaunch them.\n- **moe-crew is a transparent relay, not a validator.** `converse`\u002F`read-turn` return whatever the worker says — verbatim, including when the worker is confidently wrong. For correctness-critical handoffs, verify the produced **artifact on disk**, not the worker's prose self-report.\n\n## Environment variables\n\nThe `moe-crew` CLI honors a small set of env vars. All are optional.\n\n| Variable | Purpose |\n|---|---|\n| `MOE_CREW_DEFAULT_HARNESS` | Default harness after worker and command\u002Fpack selections. Must be `claude`, `codex`, or `pi`. |\n| `MOE_CREW_PLUGIN_ROOT` | Installed moe-crew plugin root. The launcher otherwise derives it from the running bundle. |\n| `MOE_CREW_CLAUDE_BIN` \u002F `MOE_CREW_CODEX_BIN` \u002F `MOE_CREW_PI_BIN` | Path to each harness binary. Default to `claude` \u002F `codex` \u002F `pi` (resolved via `PATH`). Set when a binary is not on `PATH` or you want to pin a specific version. |\n| `MOE_CREW_CODEX_MODEL` \u002F `MOE_CREW_PI_MODEL` | Optional model override for codex \u002F pi workers. Unset = the harness default (codex: `gpt-5.5`; pi: its configured default). |\n| `MOE_CREW_CONVERSE_DIAG_FILE` | When set, `moe-crew converse` writes a post-mortem diagnostic on timeout — `ps` tree, `tmux capture-pane`, last 30 lines of the worker's session JSONL, last 20 lines of the moe-crew events JSONL — to this path, then emits a `moe-crew-diagnostic: \u003Cpath>` pointer to stderr. The file is overwritten on each timeout. Unset = no diagnostic file. Useful when wrapping moe-crew in a harness that can ship the file off-box before the worker is reaped. |\n| `MOE_CREW_WORKER_DIR` | Override the worker dir (default `$XDG_RUNTIME_DIR\u002Fmoe-crew-workers`, or `~\u002F.local\u002Fstate\u002Fmoe-crew\u002Fworkers`). |\n| `MOE_CREW_SUBMIT_TIMEOUT` \u002F `MOE_CREW_SUBMIT_RETRY_INTERVAL` | `send`: seconds to wait for the worker to confirm a pasted prompt (default `10`) and seconds between retry-Enter resends (default `2`). Raise the timeout if a slow tmux session drops the paste. |\n| `MOE_CREW_REGISTER_TIMEOUT` | Seconds the FIRST `send`\u002F`converse` to a derive worker (codex\u002Fpi) waits for it to self-register its session id (default `15`). |\n| `XDG_STATE_HOME` | Durable Moe state root for one-time consent (`$XDG_STATE_HOME\u002Fmoe\u002Fcrew\u002Fconsent`; fallback `~\u002F.local\u002Fstate\u002Fmoe\u002Fcrew\u002Fconsent`). |\n| `HOME` | Harness-owned state root; Claude transcripts live under `~\u002F.claude\u002Fprojects\u002F`. |\n\n`moe-crew help` shows the same surface.\n",{"name":5,"description":7},"main","728894f3f85fbd4e788f015ddfd72bb6155d5dd5","plugins\u002Fmoe-crew\u002F.cursor-plugin\u002Fskills\u002Fdriving-claude-code-sessions",1,"https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe","https:\u002F\u002Fgithub.com\u002Fzak-keown","2026-09-05 06:29:06",{"source":8,"skillName":5,"commands":31,"prompt":41,"zipAvailable":42},[32,35,38],{"tool":33,"command":34},"npx","npx skills add zak-keown\u002Fmoe --skill driving-claude-code-sessions",{"tool":36,"command":37},"bunx","bunx skills add zak-keown\u002Fmoe --skill driving-claude-code-sessions",{"tool":39,"command":40},"pnpm","pnpm dlx skills add zak-keown\u002Fmoe --skill driving-claude-code-sessions","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe-crew\u002F.cursor-plugin\u002Fskills\u002Fdriving-claude-code-sessions\u002FSKILL.md",true,[44],{"path":45,"resourceType":46,"resourceTypeDesc":47,"sizeBytes":48,"sourceHtmlUrl":49},"scripts\u002Fmoe-crew.mjs","SCRIPT","脚本",835,"https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe-crew\u002F.cursor-plugin\u002Fskills\u002Fdriving-claude-code-sessions\u002Fscripts\u002Fmoe-crew.mjs",[51,58,65,72,79,86],{"skillNo":52,"name":53,"nameZh":6,"description":54,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":55,"categories":56,"keywords":57,"publishedAt":18},"01M7C1Z5362Y8NVRZ69HWP0ZD0","write-skill","Use when creating new skills, editing existing skills, or verifying skills work before deployment","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe\u002Fskills\u002Fwrite-skill\u002FSKILL.md",[],[],{"skillNo":59,"name":60,"nameZh":6,"description":61,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":62,"categories":63,"keywords":64,"publishedAt":18},"01M7C1YZ9966WK9R6ZRPCGWF3G","write-plan","Use when you have a spec or requirements for a multi-step task, before touching code","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe\u002Fskills\u002Fwrite-plan\u002FSKILL.md",[],[],{"skillNo":66,"name":67,"nameZh":6,"description":68,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":18},"01M7C1YMR4SJD7BPBBPXZCVGVH","write-clearly","Apply Strunk's timeless writing rules to ANY prose humans will read—documentation, commit messages, error messages, explanations, reports, or UI text. Makes your writing clearer, stronger, and more professional.","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe\u002Fskills\u002Fwrite-clearly\u002FSKILL.md",[],[],{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":18},"01M7C1YH9805YSM0N20VQAVSXF","windows-vm","Create, manage, or connect to a headless Windows 11 VM running in Docker with SSH access. Use when the user wants to spin up, stop, restart, or SSH into a Windows VM.","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe\u002Fskills\u002Fwindows-vm\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":18},"01M7C1YD87SCNEJ2C9B8HFR2NQ","verify-completion","Use when about to claim work is complete, fixed, or passing, before committing or creating MRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe\u002Fskills\u002Fverify-completion\u002FSKILL.md",[],[],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":18},"01M7C1YARDEHT0TJ9BRG30ZCF4","using-moe","Use when starting any conversation - establishes how to find and use skills, requiring skill invocation before ANY response including clarifying questions","https:\u002F\u002Fgithub.com\u002Fzak-keown\u002Fmoe\u002Fblob\u002Fmain\u002Fplugins\u002Fmoe\u002Fskills\u002Fusing-moe\u002FSKILL.md",[],[]]