agentleFS
aaronnat23aaronnat23/disp8ch/skills/code-dispatch/SKILL.md

code-dispatch

Skill99 starsChanged 5 months agoMITView on GitHub

Delegate coding, file-system, and research tasks to a real CLI agent running on the user's machine. The orchestrator stays clean — no token overhead, no context window bloat. The specialist executes. Agent ID: Always agent: "claude" (not "claude-code"). Use "gemini" or "codex" only when explicitly requested. Mode selection by channel: - Discord: mode: "session" + thread: true for multi-step work; mode: "run" for one-shot - Telegram / WhatsApp / Slack / Teams / BlueBubbles / WebChat: Always mode: "run" —…

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Agent ID: Always agent: "claude" (not "claude-code").

    line 15
  2. Very specific:

    Timeout: Always set timeout_seconds (default 120, max 300).

    line 26
  3. Very specific:

    Never nest: Do not call sessions_spawn from within a spawned session.

    line 28
  4. Very specific:

    Working directory: Always specify cwd pointing to the relevant project directory.

    line 30

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Code Dispatch (ACP-style Coding Agent Delegation)

Delegate coding, file-system, and research tasks to a real CLI agent running on the user's machine. The orchestrator stays clean — no token overhead, no context window bloat. The specialist executes.

When to use

  • Complex coding tasks that require multi-file edits, running tests, or reading the repo
  • File-system operations beyond simple read/write (refactors, scaffolding, migrations)
  • Research tasks that benefit from live CLI tools (git, grep, compilers, package managers)
  • Any task where Claude Code's local tools + MCP servers give better results than inline agent calls

Rules

Agent ID: Always agent: "claude" (not "claude-code"). Use "gemini" or "codex" only when explicitly requested.

Mode selection by channel:

  • Discord: mode: "session" + thread: true for multi-step work; mode: "run" for one-shot
  • Telegram / WhatsApp / Slack / Teams / BlueBubbles / WebChat: Always mode: "run" — async thread binding is not available on these channels

Permission mode:

  • permission_mode: "approve-reads" (default): allows reads, prompts for writes/exec — safe for most tasks
  • permission_mode: "approve-all": auto-approves all tool calls — only use for trusted, well-defined tasks
  • permission_mode: "deny-all": read-only (Read, Glob, Grep, LS only) — use for audits or safe exploration

Timeout: Always set timeout_seconds (default 120, max 300). For complex refactors use 300.

Never nest: Do not call sessions_spawn from within a spawned session. The orchestrator dispatches; the specialist does the work.

Working directory: Always specify cwd pointing to the relevant project directory.

Example — Discord multi-step session

{
  "tool": "sessions_spawn",
  "agent": "claude",
  "mode": "session",
  "thread": true,
  "permission_mode": "approve-all",
  "cwd": "/path/to/project",
  "task": "Refactor the auth module to use JWT. Run tests after each file change.",
  "timeout_seconds": 300,
  "label": "Auth JWT refactor"
}

Example — one-shot on any channel

{
  "tool": "sessions_spawn",
  "agent": "claude",
  "mode": "run",
  "stream_to": "parent",
  "permission_mode": "approve-all",
  "cwd": "/path/to/project",
  "task": "Add a greet() function to src/utils.ts and export it.",
  "timeout_seconds": 120
}

After dispatch

  • Confirm task receipt to the user: "Dispatched to Claude Code — working on it."
  • On mode: "run": relay the result directly in your reply.
  • On mode: "session" + Discord: tell the user they can continue in the created thread.
  • On error: summarize the failure and suggest breaking the task into smaller steps.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.