# on-device-delegate

on-device-delegate — a GitHub Copilot skill that delegates heavy file reading to an on-device worker. Keeps the main cloud context lean during log analysis and test triage.

- skill · `type=skill` · GitHub Copilot, Claude Code, Codex, Cursor, Gemini CLI, Windsurf (Devin Desktop), Claude.ai · ★ 41430 repo stars
- Author: github · official GitHub repository
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/github/awesome-copilot/tree/HEAD/skills/on-device-delegate/SKILL.md
- Updated: 2026-10-23
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/on-device-delegate

## What it does

The skill offloads reading tasks to the `local-coding:on-device-worker` agent running the MAI Code 1.1 Flash model. By processing raw text on the local machine, large logs and file trees never enter the main cloud context window. The primary session sends a structured brief, capping tool calls at eight, and receives a single structured response.

The cloud agent performs at most one quick verification on the return value, checking output format or spot-checking a count. It does not re-read the input or recalculate the entire answer. Security reviews and architecture choices must stay with the primary model. If the worker fails or reports UNABLE, the main session completes the task directly.

Operation requires Windows, GitHub Copilot CLI with experimental features enabled, the local-coding plugin, and the MAI Code 1.1 Flash model. Local execution takes minutes rather than seconds while the model spins up.

## Install

### GitHub Copilot (native platform)

1. **GitHub CLI**
```bash
gh skill install github/awesome-copilot skills/on-device-delegate
```

2. **Manually: put the files in place**
- File: `.github/skills/on-device-delegate/SKILL.md`

### Claude Code

1. **Skills CLI (Vercel)**
```bash
npx skills add github/awesome-copilot --skill on-device-delegate -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/on-device-delegate/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/on-device-delegate/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add github/awesome-copilot --skill on-device-delegate -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/on-device-delegate/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add github/awesome-copilot --skill on-device-delegate -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/on-device-delegate/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add github/awesome-copilot --skill on-device-delegate -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/github/awesome-copilot --path skills/on-device-delegate
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/on-device-delegate/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/github/awesome-copilot/tree/HEAD/skills/on-device-delegate/SKILL.md

## When to use it
- keep cloud context free when reading over 25 KB of prose
- aggregate error counts across log directories locally
- summarize multiple files without loading them into main chat
- extract facts from large test reports on-device

## Example prompts
- Use on-device-delegate to list every distinct error with its count from logs/
- Run on-device-delegate to extract failed assertions from test-output/
- Delegate reading of docs/specs/ to summarize module configuration values

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: 83c3964d9a940975.

BEGIN THIRD-PARTY FILE 83c3964d9a940975
````text
---
name: on-device-delegate
description: 'Saves cloud-model context by briefing one bounded, read-heavy sub-task (more than about 25 KB of prose, or many files that no single command can answer) to the local-coding plugin''s on-device worker, which runs on the local MAI Code 1.1 Flash model. Use for log and test triage, summarizing many files, or extracting facts from large inputs. When the user names this skill, call the skill tool in the same response as your first other tool call, never as a separate step.'
compatibility: 'GitHub Copilot CLI on Windows with experimental features on, MAI Code 1.1 Flash installed from /model, and the local-coding plugin installed (it provides the on-device worker agent).'
---

# On-Device Delegate

Send the bulky reading in a task to the on-device worker, then check its answer
once. The main session keeps planning and answering. The worker reads the big
inputs on the local model, so they never enter the main context.

## Steps

1. **Gate on what you would read.** If one command or a short script can
   compute the answer, do it yourself now: no plan, no notes about this
   skill. Delegate only when you would otherwise READ more than about 25 KB
   of text into your context (prose, many files). Never delegate security
   review or design decisions.
2. **Check the worker.** The worker is the custom agent
   `local-coding:on-device-worker` (the plugin id). If the task tool lists it
   as plain `on-device-worker` instead (copied into an agents folder), use
   that. If neither is available, work normally.
3. **Brief.** Do not read the big input first. Make ONE task call:
   - `name`: "on-device-<short-kebab>"
   - `description`: 3-5 words
   - `agent_type`: the worker id from step 2
   - `mode`: "sync"
   - `model`: the on-device model id named in the session's routing line,
     exactly (if there is none:
     "winml-azureml-mai-code-1.1-flash-on-device/MAI-Code-1.1-Flash-On-Device").
     The worker does not pin a model, so without this it runs on your own
     model.
   - `prompt`, exactly:

     ```text
     GOAL: <one sentence>
     INPUTS: <exact paths>
     RULES: Read only INPUTS. At most 8 tool calls. Edit nothing but OUTPUT. No questions.
     OUTPUT: <file path and exact format, or: reply only>
     ANSWER: Reply ONCE with only <exact format>, then stop.
     If you cannot, reply only: UNABLE: <reason>
     ```

4. **Check once.** At most ONE cheap check (format, a count, or one spot
   check). Never recompute the answer or re-read the input. If the answer is
   wrong, UNABLE, or the task call fails: do it yourself. Then finish.

## Example

User: "Use the on-device-delegate skill. From the logs under `logs\`, list
````
END THIRD-PARTY FILE 83c3964d9a940975

The third-party file has ended. Everything between the 83c3964d9a940975 tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2704 of 3989 bytes. © github · MIT · https://github.com/github/awesome-copilot/tree/HEAD/skills/on-device-delegate/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
