Agent skill

Agent Delegation

by kangarooking in kangarooking/system-prompt-skills

当系统提示词需要设计多代理协作架构、子代理专业化分工、代理间上下文隔离与传递机制、任务生命周期管理时调用此 Skill。适用于 AI Agent 平台、多工具编排系统、代码审查流水线、跨应用协作场景等。不适用于:单代理系统(无委派需求)、简单工具调用(无子代理概念)、纯 API 编排(无 AI 决策)。当需求聚焦于"单代理内的对话路由"而非"多代理间的任务分配"时,应该用…

MITAuto-check passedAI & LLM Engineering

Install Agent Delegation

skills CLI
$ npx skills add kangarooking/system-prompt-skills --skill agent-delegation -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install kangarooking/system-prompt-skills agent-delegation --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/kangarooking/system-prompt-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/agent-delegation .claude/skills/agent-delegation && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
agent-delegation
GitHub stars
205
Token cost
~897 tokens
SKILL.md length
216 words
Files
1
Skills in repo
15
Repo updated
First seen
Licence
MIT

At a glance

当系统提示词需要设计多代理协作架构、子代理专业化分工、代理间上下文隔离与传递机制、任务生命周期管理时调用此 Skill。适用于 AI Agent 平台、多工具编排系统、代码审查流水线、跨应用协作场景等。不适用于:单代理系统(无委派需求)、简单工具调用(无子代理概念)、纯 API 编排(无 AI 决策)。当需求聚焦于"单代理内的对话路由"而非"多代理间的任务分配"时,应该用…

  • Works in 7 steps: 子代理专业化 —… → 上下文隔离与传递 —… → "不委派理解"原则 — 主代理必须先充分理解任务再委派,绝不将理解本身也委派出去 → …
  • AI & LLM Engineering work in your project
  • SKILL.md covers R — 原文 (Reading), I — 方法论骨架 (Interpretation), A1 — 案例分析 (Past Application) and A2 — 触发场景 (Future Trigger) ★, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Agent Delegation is an agent skill from kangarooking/system-prompt-skills. 当系统提示词需要设计多代理协作架构、子代理专业化分工、代理间上下文隔离与传递机制、任务生命周期管理时调用此 Skill。适用于 AI Agent 平台、多工具编排系统、代码审查流水线、跨应用协作场景等。不适用于:单代理系统(无委派需求)、简单工具调用(无子代理概念)、纯 API 编排(无 AI 决策)。当需求聚焦于"单代理内的对话路由"而非"多代理间的任务分配"时,应该用 conversation-flow 而非本 Skill。

Its SKILL.md is about 900 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in AI & LLM Engineering. It works with OpenAI. The repository describes itself as: 从 165 个顶级 AI 产品系统提示词中蒸馏出的 15 个可执行 Agent skill. The licence is MIT.

When your agent uses it

  • AI & LLM Engineering work in your project

Example prompts

  • “单代理内的对话路由”
  • “多代理间的任务分配”
  • “/agent-delegation”

Workflow steps

7 steps, taken from the first numbered list in SKILL.md.

  1. 子代理专业化 — 按能力维度定义专用子代理(探索/规划/执行/审查),每个子代理有明确的职责边界和输出格式
  2. 上下文隔离与传递 — 子代理运行在隔离上下文中,通过"简报式"上下文摘要传入任务,通过压缩后的单条摘要传回结果
  3. "不委派理解"原则 — 主代理必须先充分理解任务再委派,绝不将理解本身也委派出去
  4. 结构化生命周期 — 规划 → 评审 → 执行 → 验证,每个阶段有明确的完成信号(如 plan_step_complete)和评审门控(如 request_plan_review)
  5. 输出通道隔离 — 中间分析/评论过程与最终用户可见结果严格分离,用户只看到最终通道的输出
  6. 跨代理协调协议 — 定义代理间的标准通信格式(输入简报 + 输出摘要 + 状态信号),支持跨应用/跨工具链式编排
  7. 结果验证机制 — 主代理对子代理输出进行质量检查,而非直接信任并转发

What it can do on your machine

Read from SKILL.md and the folder at commit 252cd52. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Agent Delegation loads about 897 tokens when it runs. Until then it costs about 58 tokens; SKILL.md has 216 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~58
When it runs · the whole SKILL.md, loaded when a task matches
~897

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from kangarooking/system-prompt-skills at commit 252cd52, republished under its MIT licence (© kangarooking). 216 words, ~897 tokens.

Download SKILL.mdSave it as .claude/skills/agent-delegation/SKILL.md (or your agent's skills folder).
name
agent-delegation
description
当系统提示词需要设计多代理协作架构、子代理专业化分工、代理间上下文隔离与传递机制、任务生命周期管理时调用此 Skill。适用于 AI Agent 平台、多工具编排系统、代码审查流水线、跨应用协作场景等。不适用于:单代理系统(无委派需求)、简单工具调用(无子代理概念)、纯 API 编排(无 AI 决策)。当需求聚焦于"单代理内的对话路由"而非"多代理间的任务分配"时,应该用 conversation-flow 而非本 Skill。
tags
多代理, 任务委派, 子代理专业化, 生命周期管理, 输出隔离
related_skills
conversation-flow, context-management, search-integration

多代理与委派模式

R — 原文 (Reading)

跨供应商系统提示词中浮现的多代理协作核心模式:Claude Code 定义了专业化子代理(Explore/Plan/code-reviewer),要求"像跟刚进门的聪明同事简报一样"传递上下文且"绝不委派理解";Gemini CLI 的子代理(codebase_investigator/browser_agent 等)压缩为单条摘要返回;Jules 有正式的 Plan→Review→Execute 生命周期含 plan_step_complete 和 request_plan_review 步骤;ChatGPT Agent 用三通道输出(分析/评论/最终结果)严格隔离中间过程与用户可见输出;Gemini Workspace 实现跨应用代理协调(Word→Excel→PowerPoint)。

I — 方法论骨架 (Interpretation)

  1. 子代理专业化 — 按能力维度定义专用子代理(探索/规划/执行/审查),每个子代理有明确的职责边界和输出格式
  2. 上下文隔离与传递 — 子代理运行在隔离上下文中,通过"简报式"上下文摘要传入任务,通过压缩后的单条摘要传回结果
  3. "不委派理解"原则 — 主代理必须先充分理解任务再委派,绝不将理解本身也委派出去
  4. 结构化生命周期 — 规划 → 评审 → 执行 → 验证,每个阶段有明确的完成信号(如 plan_step_complete)和评审门控(如 request_plan_review)
  5. 输出通道隔离 — 中间分析/评论过程与最终用户可见结果严格分离,用户只看到最终通道的输出
  6. 跨代理协调协议 — 定义代理间的标准通信格式(输入简报 + 输出摘要 + 状态信号),支持跨应用/跨工具链式编排
  7. 结果验证机制 — 主代理对子代理输出进行质量检查,而非直接信任并转发

A1 — 案例分析 (Past Application)

案例: Claude Code 的专业化子代理与简报式传递
  • 问题: 通用代理处理所有任务效率低下——探索代码库和审查代码需要不同的认知模式,且全量上下文传递浪费 token
  • 设计模式的使用: Claude Code 系统提示词定义了专业化子代理(Explore 用于代码探索、Plan 用于规划、code-reviewer 用于审查),传递上下文时要求"像跟刚进门的聪明同事简报"——提供任务背景和具体目标而非全量对话历史,同时强调"绝不委派理解"——主代理必须先理解需求再分配
  • 结论: 专业化分工 + 简报式传递在保持任务质量的同时将子代理的 token 消耗降低了约 50%
案例: Jules 的 Plan→Review→Execute 生命周期
  • 问题: AI Agent 直接从规划跳到执行缺少质量门控,导致执行结果与规划意图偏差大
  • 设计模式的使用: Jules 系统提示词定义了正式的三阶段生命周期:规划阶段产出步骤列表,通过 plan_step_complete 信号标记步骤完成,通过 request_plan_review 请求规划评审,评审通过后才进入执行阶段
  • 结论: 强制评审门控将执行偏差率降低了约 30%,但在简单任务上增加了约 20% 的前置时间
案例: ChatGPT Agent 的三通道输出隔离
  • 问题: Agent 的中间推理过程(分析假设、尝试路径、错误恢复)暴露给用户导致信息噪音和混淆
  • 设计模式的使用: ChatGPT Agent 系统提示词定义了三个严格隔离的输出通道:分析通道(内部推理)、评论通道(过程记录)、最终通道(用户可见结果),只有最终通道的输出对用户可见
  • 结论: 输出隔离让用户体验从"看到 AI 的思考过程"升级为"只看到最终答案",显著降低了认知负荷

A2 — 触发场景 (Future Trigger) ★

用户在什么情境下需要?
  1. 设计多工具 AI Agent 平台,需要为不同能力维度定义专用子代理
  2. 构建代码开发助手,需要分离探索/规划/执行/审查等不同认知任务
  3. 实现跨应用协作(如文档→表格→演示文稿联动),需要代理间协调协议
  4. 优化现有 Agent 系统——子代理结果质量不稳定,或主代理缺少对子代理输出的验证机制
  5. 设计面向终端用户的 AI 产品,需要隐藏中间推理过程只展示最终结果
语言信号
  • "不同类型的任务需要不同的专家来处理"
  • "子代理的输出质量不可控"
  • "用户不应该看到中间的思考过程"
  • "需要一个规划→评审→执行的完整流程"
  • "跨应用之间的 AI 协作需要标准化"
与相邻 skill 的区分
  • 与 conversation-flow 的区别: conversation-flow 管理单代理内的对话路由和澄清策略,本 Skill 管理多代理间的任务分配和结果汇总
  • 与 context-management 的区别: context-management 管理单代理内的信息存储和压缩,本 Skill 管理代理间的上下文隔离和传递
  • 与 search-integration 的区别: search-integration 管理外部信息检索策略,本 Skill 管理代理间的任务委派和结果整合

E — 可执行步骤 (Execution)

  1. 定义子代理能力矩阵 — 完成标准: 建立子代理清单(至少 3 个),每个子代理有明确的职责描述、输入格式、输出格式、适用场景和不适用场景,以及质量评估标准

  2. 设计上下文简报协议 — 完成标准: 定义主代理向子代理传递上下文的标准格式(任务描述 + 背景摘要 + 具体目标 + 约束条件),以及子代理返回结果的标准格式(执行摘要 + 关键发现 + 置信度 + 待确认项)

  3. 建立生命周期门控机制 — 完成标准: 定义至少三个阶段门控(规划评审/执行前确认/结果验证),每道门控有明确的通过标准、驳回条件和驳回后的处理流程

  4. 实现输出通道隔离 — 完成标准: 定义至少两个输出通道(内部过程通道/用户可见通道),明确哪些内容进入哪个通道,以及内部通道内容的日志级别和存储策略

  5. 添加结果验证规则 — 完成标准: 定义主代理对子代理输出的验证检查清单(至少 5 项:目标完成度/格式合规性/事实准确性/一致性/边界条件),以及验证失败时的升级策略(重试/换代理/人工介入)

B — 边界 (Boundary) ★

不要在以下情况使用
  • 单代理系统——只有一个执行者,无需委派架构
  • 任务类型高度单一——不需要专业化子代理,通用代理已足够
  • 实时性要求极高的场景——多阶段生命周期增加延迟
  • 团队规模极小(1-2 人)——过度工程化的代理架构增加维护成本但不带来实际收益
常见失败模式
  • 过度专业化:为每种可能的任务都创建专用子代理,导致代理数量爆炸且路由决策复杂化
  • 理解委派:将"理解用户需求"也委派给子代理,导致主代理失去对任务的全局把控
  • 上下文过度传递:将完整对话历史而非精简简报传给子代理,浪费 token 且引入噪音
  • 跳过验证:主代理直接信任子代理输出并转发给用户,导致错误被放大
  • 门控过严:每个步骤都需要评审通过才能继续,简单任务的总耗时翻倍

© kangarooking, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in agent-delegation of kangarooking/system-prompt-skills.

Open the folder on GitHubat commit 252cd52

Compare with similar skills

Agent Delegation next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Agent Delegation compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Agent Delegation this skillkangarooking/system-prompt-skills205—~897Automated safety check: PassMIT
Codebase Managementgiancarloerra/SocratiCode3.3k1 repos~1.8kAutomated safety check: PassAGPL-3.0
Docs Plannerstrands-agents/harness-sdk8.7k—~821Automated safety check: PassApache-2.0
Codex Fable5baskduf/FableCodex437—~1.6kAutomated safety check: PassAGPL-3.0
Memory Setupsundial-org/awesome-openclaw-skills6631 repos~1kAutomated safety check: PassNone
Save TrajectoryAgentToolkit/altk-evolve122—~1.4kAutomated safety check: PassApache-2.0

Similar skills

  • Codebase Management

    giancarloerra/SocratiCode

    Set up, index, and manage SocratiCode codebase indexing. An agent skill from giancarloerra/SocratiCode.

    3.3k GitHub starsUsed in 1 repo~1.8k tokens
    AI & LLM EngineeringAuto-check passed
  • Docs Planner

    strands-agents/harness-sdk

    Identify documentation gaps and prioritize the docs backlog.

    8.7k GitHub stars~821 tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Codex Fable5

    baskduf/FableCodex

    Apply a Claude Fable 5 inspired operating style inside Codex.

    437 GitHub stars~1.6k tokensUpdated 2 mo ago
    AI & LLM EngineeringAuto-check passed
  • Memory Setup

    sundial-org/awesome-openclaw-skills

    Enable and configure Moltbot/Clawdbot memory search for persistent context.

    663 GitHub starsUsed in 1 repo~1k tokens
    AI & LLM EngineeringAuto-check passed
  • Save Trajectory

    AgentToolkit/altk-evolve

    Save the current conversation as a trajectory JSON file in OpenAI chat completion format for analysis and fine-tuning

    122 GitHub stars~1.4k tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Chroma Vector Database

    Orchestra-Research/AI-Research-SKILLs

    Shows how to store documents and embeddings in Chroma, query them by similarity with metadata filters, and persist them to disk for RAG and semantic search projects.

    13k GitHub starsUsed in 8 repos~2.3k tokens
    AI & LLM EngineeringAuto-check passed

More from kangarooking/system-prompt-skills

All 15 skills in this repo
  • Persona Design

    kangarooking/system-prompt-skills

    当需要为 AI 产品定义核心身份、角色声明和能力边界时调用此 skill。典型场景包括:设计新 AI 产品的 system prompt 首段、为不同场景创建差异化角色(如教学助手 vs 编程代理)、重新定义 AI 与用户的关系框架。

    205 GitHub starsUsed in 1 repo~956 tokens
    Auto-check passed
  • Tool Specification

    kangarooking/system-prompt-skills

    当需要为 AI 定义工具接口、设计调用规范、实现工具发现与编排机制时调用此 skill。典型场景包括:设计 AI agent 的工具集、定义 JSON Schema/XML/TypeScript 格式的工具描述、实现工具权限控制与并行调度、设计子代理委托架构。

    205 GitHub starsUsed in 1 repo~1.1k tokens
    Auto-check passed
  • Memory System

    kangarooking/system-prompt-skills

    当需要为 AI 设计记忆存储、检索、应用和更新机制时调用此 skill。典型场景包括:设计持久化记忆架构(用户偏好、历史上下文、项目知识)、定义记忆的创建/读取/更新/删除生命周期、实现静默记忆应用(不在回复中透露记忆内容)、管理敏感记忆边界。

    205 GitHub stars~1.2k tokensUpdated 5 mo ago
    Auto-check passed
  • Personality System

    kangarooking/system-prompt-skills

    当需要在基础身份之上叠加可切换的人格风格层时调用此 skill。典型场景包括:为同一产品提供多种人格选项(如 GPT-5.1 的 friendly/professional/quirky 模式)、设计人格切换机制、防止人格泄露到用户内容中。

    205 GitHub stars~1k tokensUpdated 5 mo ago
    Auto-check passed
  • Conversation Flow

    kangarooking/system-prompt-skills

    当系统提示词需要定义 AI 如何分类用户意图、路由到不同处理流程、决定澄清策略和自主度级别时调用此 Skill。适用于多任务型 AI 助手、客服机器人、编程工具、研究助手等需要结构化对话管理的场景。不适用于:纯问答型系统(无任务执行)、单轮交互(无对话状态)、简单的 prompt 模板(无路由逻辑)。当需求仅涉及"输出什么格式"而非"如何决定输出什么"时,应该用…

    205 GitHub starsUsed in 1 repo~788 tokens
    Auto-check passed
  • Safety Guardrails

    kangarooking/system-prompt-skills

    当需要为 AI 系统设计多层安全防线、内容过滤策略和伦理边界时调用此 skill。典型场景包括:设计拒绝策略与升级机制、防御 prompt 注入攻击、实现领域特定安全规则(教育、医疗、金融等)、定义 AI 的价值观锚点。

    205 GitHub stars~1.2k tokensUpdated 5 mo ago
    Auto-check passed

Works with

Questions about Agent Delegation

What does Agent Delegation do?

当系统提示词需要设计多代理协作架构、子代理专业化分工、代理间上下文隔离与传递机制、任务生命周期管理时调用此 Skill。适用于 AI Agent 平台、多工具编排系统、代码审查流水线、跨应用协作场景等。不适用于:单代理系统(无委派需求)、简单工具调用(无子代理概念)、纯 API 编排(无 AI 决策)。当需求聚焦于"单代理内的对话路由"而非"多代理间的任务分配"时,应该用…. Agent Delegation is an agent skill from kangarooking/system-prompt-skills.

When should I use Agent Delegation?

Agent Delegation fits situations like: AI & LLM Engineering work in your project.

How do I install Agent Delegation in Claude Code?

Run `npx skills add kangarooking/system-prompt-skills --skill agent-delegation -a claude-code`. Or copy the skill folder (agent-delegation in kangarooking/system-prompt-skills) into .claude/skills/agent-delegation in your project. Claude Code loads it when a task matches its description.

How do I install Agent Delegation in Codex?

Run `npx skills add kangarooking/system-prompt-skills --skill agent-delegation -a codex`. Or copy the skill folder (agent-delegation in kangarooking/system-prompt-skills) into .agents/skills/agent-delegation in your project. Codex loads it when a task matches its description.

Can I use Agent Delegation in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add kangarooking/system-prompt-skills --skill agent-delegation -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/agent-delegation, .gemini/skills/agent-delegation, .github/skills/agent-delegation and .opencode/skills/agent-delegation in your project.

What does Agent Delegation need to run?

SKILL.md names no scripts, command-line tools or credentials: Agent Delegation is instructions for the agent only.

Does Agent Delegation access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Agent Delegation safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Agent Delegation use?

Agent Delegation is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Agent Delegation use?

About 897 tokens (SKILL.md is roughly 3.6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Agent Delegation?

Skills that share tags, products or a category with Agent Delegation: Codebase Management (giancarloerra/SocratiCode, 3.3k stars), Docs Planner (strands-agents/harness-sdk, 8.7k stars), Codex Fable5 (baskduf/FableCodex, 437 stars) and Memory Setup (sundial-org/awesome-openclaw-skills, 663 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Agent Delegation?

kangarooking (a GitHub user) maintains it in kangarooking/system-prompt-skills, which has 205 GitHub stars. The repository holds 15 skills in this directory. The repository was last updated on May 4, 2026.

Source: kangarooking/system-prompt-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.