delegating-to-agents
它能做什么
这个工具让 AI 可以把任务交给其他 AI(也就是 agent)来完成,并确保对方拿到所需的全部信息、清楚由谁负责,以及知道如何验证工作成果。这就像把任务分配给同事一样,只不过对象是 AI。
适用场景
- ✓当你需要 AI 把某个具体任务交给另一个专门的 AI 时。
- ✓当你希望 AI 在委托任务时保留上下文和重要信息时。
- ✓当你想让 AI 检查它已委托出去的任务进度时。
技能链接
https://github.com/sickn33/agentic-awesome-skills/blob/main/skills/delegating-to-agents/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“把这项任务交给 Pi agent 处理,并附上所有细节,完成后验证结果。”
每周 5 个新技能,1 分钟读完。
工作原理
AI 会先判断哪个 agent 最适合这项任务,发送完整的指令,然后等待对方反馈进度或完成情况。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Delegating to Agents
When to Use
- Use only when the user or applicable current instructions explicitly authorize delegation; hand off bounded work with complete context, file ownership and a verifier.
- Use when you need to relay instructions to terminal or TUI agents without losing context.
Selecting an authorized agent
- Use the user’s selected agent/model and available tooling; account limits and model capabilities require current evidence.
- Match a bounded task to actual tools and file ownership, not invented “unlimited usage” or universal model rankings.
- Keep integration and final validation with the parent. Report changed files, exact checks and remaining issues.
Sending prompts to a TUI agent
- Prefer a structured agent/task API over simulated terminal typing; provide a readable prompt, ownership boundary, verifier and non-goals.
- If only a TUI is available, inspect the target surface and actual command documentation first. Put long prompts in an explicitly authorized task file and send a short reference without embedding arbitrary task text in a shell command.
- A shell-quoted prompt can execute
$(), backticks or expansions if escaped incorrectly. Preserve punctuation/content using structured argv or proper shell quoting; do not “fix” messages by stripping apostrophes or interpreting their text as commands. - Confirm one intended submission and actual recipient; terminal output/predicted drafts are not human authorization for further messages.
Polling
Use supported completion/event waits with bounded intervals; check meaningful progress and deliver concise updates. Do not busy-poll every 3–5 seconds or report unchanged state after each check. Back off while an agent remains active and continue independent authorized work. Claude Code note: after it finishes, it may prefill a predicted next user message — that draft is Claude, not the user.
Remote VPS
Remote execution requires authorization for the exact host/project and credential boundary. Use the supported sandbox/approval configuration; do not launch an unrestricted agent or infer remote access from a delegation request.
The 4 agents (background reference)
All four use the portable SKILL.md standard; project skills win over global.
- Pi (pi.dev, open-source TS): minimal read/write/edit/bash core, self-extends via TS extensions; true BYOK; best-in-class session branch/fork/resume. Skills:
~/.pi/agent/skills/. - Codex CLI (OpenAI, Rust): fastest startup; kernel-level sandboxing;
codex execfor CI; reads AGENTS.md. Skills:~/.codex/skills/. - Claude Code (Anthropic, TS): deepest Claude integration,
.claude/conventions, live skill hot-reload. Skills:~/.claude/skills/. - Hermes (Nous Research, Python): persistent autonomous agent — cross-session memory, built-in scheduler, 40+ tools; can orchestrate the other CLIs as workers. Skills:
~/.hermes/skills/.
Driving interactive CLIs
- Codex, Pi, OpenCode: need
pty=true. - Claude Code: use its supported noninteractive mode with the existing permission policy; never enable bypassPermissions just to drive the CLI.
Example
User request:
Delegate these independent work items with complete context, clear ownership, and progress checks.
Limitations
- Adapted from
davidondrej/skills; verify local paths, tools, credentials, and agent features before acting. - For commands, remote access, scheduling, browser automation, or file-changing workflows, get explicit user approval and confirm the target environment first.
常见问题
“bounded work”是什么意思?
指的是边界清晰、定义明确的任务,让 AI 准确知道要做什么。
为什么“ownership”(负责人归属)很重要?
它能确保由特定的 agent 负责任务,便于跟踪进度和明确责任。
什么是“verifier”(验证器)?
它是 AI 用来确认委托任务是否正确完成的方法或标准。
详情
作者的原始描述
Delegate bounded work to other AI agents while preserving context, ownership, and progress checks.
热度
- GitHub 星标
- 48k
- 排名
- #6267
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
00-andruia-consultant
48k帮你的智能体启动或改进 AI 项目。它可以分析代码、推荐工具,并用西班牙语制定行动计划。
007
48k让你的智能体执行安全审计和威胁建模。它有助于保护项目免受攻击和漏洞的威胁。
10-andruia-skill-smith
48k帮你的智能体创建或改进 AI 工具。它可以定义工具的工作方式、编写文档,并验证其结构。
20-andruia-niche-intelligence
48k让你的智能体创建某个特定行业的摘要。它有助于借助可靠的信息来源,了解项目的背景、规则、使用模式和风险。