agentleFS
Magnus-GilleMagnus-Gille/claude-skills/m5-delegate/SKILL.md

m5-delegate

Skill5 starsChanged 33 days agoMITView on GitHub

Delegate a self-contained task to Magnus's M5 when local inference is requested or the project's delegation policy applies.

The file

We split this skill into the rules it gives an agent

11 rules. About 0 are common, 5 are distinctive, and 6 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 6

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when local inference is requested or an applicable delegation policy calls for a self-contained leaf.

    line 8
  2. Very specific:

    Prefer a fast non-thinking model such as mellum for short classify/extract/summarize/simple-codegen.

    line 26
  3. Very specific:

    Use qwen3-coder-next-80b for harder coding or agentic-coding leaves.

    line 27
  4. Very specific:

    Use gemma4 for general or multimodal tasks when relevant.

    line 28
  5. Very specific:

    Prefer purpose-built MCP tools if they are available in the current agent session, such as list_models, ask, or code_loop_*.

    line 34
  6. Distinctive:

    Always pass the cloud delegator model when you know it:

    line 36
  7. Distinctive:

    Use the actual frontier/conductor model for the current task, not a generic default.

    line 41
  8. Distinctive:

    If writing a harness that talks to the gateway directly:

    line 43
  9. Very specific:

    Call gateway-root routes as "$M5_GATEWAY_URL/delegate" or "$M5_GATEWAY_URL/ledger".

    line 46
  10. Very specific:

    Never derive the gateway root by stripping /v1 from M5_BASE_URL.

    line 47
  11. Distinctive:

    When a delegated answer matters, capture whether it was useful:

    line 63

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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

M5 Local Delegation

Use this skill when local inference is requested or an applicable delegation policy calls for a self-contained leaf. The goal is to save frontier tokens and produce useful real delegation data for the home-server project.

When To Use It

Once activated, suitable leaves include:

  • Summarize, classify, extract, rewrite, draft.
  • Short, bounded reasoning where an approximate answer is acceptable.
  • Single-shot code generation with a clear spec.
  • Batch harnesses that can run on the M5 box itself.

Avoid it:

  • Work needing the full current repo or conversation context.
  • Security-critical reasoning or tasks where a wrong answer is costly to detect.
  • Multi-step code edits unless a caged code-loop style tool is explicitly available.
  • Private content unless it will stay on a local-only path.

Model/Runtime Guidance

  • Prefer a fast non-thinking model such as mellum for short classify/extract/summarize/simple-codegen.
  • Use qwen3-coder-next-80b for harder coding or agentic-coding leaves.
  • Use gemma4 for general or multimodal tasks when relevant.
  • Discover available models and current tool schemas before choosing; the names above are examples, not an availability guarantee. Size output budgets to the task and detect truncated or empty results.
  • Batch independent same-model calls when supported to avoid unnecessary model swaps; measure runtime rather than assuming fixed latency.

Access Paths

Prefer purpose-built MCP tools if they are available in the current agent session, such as list_models, ask, or code_loop_*.

Always pass the cloud delegator model when you know it:

  • MCP ask: include delegator_model_id, for example "delegator_model_id": "openai/gpt-5.5".
  • Direct /delegate: include delegatorModelId, for example "delegatorModelId": "openai/gpt-5.5".
  • Homeserver CLI: pass --delegator <cloud-model-id>.

Use the actual frontier/conductor model for the current task, not a generic default. This is what lets the M5 ledger measure actual savings rather than only premium-baseline savings. If the cloud delegator is unknown, omit the field instead of guessing.

If writing a harness that talks to the gateway directly:

  • Heavy/batch harnesses should run on the M5 box and call llama-swap on loopback: http://127.0.0.1:8091/v1. This needs no bearer token.
  • For an authenticated laptop call, load the canonical bases with eval "$(m5-auth --env --tailnet)" (or omit --tailnet when the public gateway is required).
  • Call gateway-root routes as "$M5_GATEWAY_URL/delegate" or "$M5_GATEWAY_URL/ledger". Call the OpenAI-compatible route as "$M5_OPENAI_BASE_URL/chat/completions".
  • Never derive the gateway root by stripping /v1 from M5_BASE_URL. M5_BASE_URL remains a compatibility alias for M5_OPENAI_BASE_URL; it is not valid for /delegate or /ledger.
  • Get the owner bearer token only through m5-auth and macOS Keychain. Never scrape MCP config and never write tokens to tracked or scratch files.

One-Shot Prompt Shape

The runtime sees only the prompt string. Make it self-contained:

  1. One sentence of role/framing.
  2. Clearly delimited input.
  3. Exact requested output.
  4. Constraints, schema, length cap, and things to avoid.

For JSON or structured output, specify the schema and ask for only that output.

Feedback Loop

When a delegated answer matters, capture whether it was useful:

  • pass: used as-is or with trivial edits.
  • partial: useful but needed edits.
  • redo: wrong shape, retry might work.
  • wrong: wrong runtime choice; escalate.

This feedback is part of the routing-evidence loop that the project exists to improve.

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.