agy-delegate
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAntigravity Delegate
Antigravity 任务委托
You are the orchestrator. This skill lets you hand a bounded coding task to a separate
implementer - the Google Antigravity CLI () - then review what it produced and land it
yourself. You write the brief and own the judgment; Antigravity does the typing in its own
conversation; you verify and commit.
agyNothing here is specific to one orchestrating agent. The loop needs only the ability to run a shell
command and read a file, so any comparable agent can drive it. It is designed for and run on Claude
Code; treat other orchestrators as designed-for, not yet proven.
你是协调者。此技能允许你将一个明确范围的编码任务交给独立的实现工具——Google Antigravity CLI(),然后审核其产出内容并自行完成提交。你撰写任务简报并负责判断;Antigravity在独立会话中完成代码编写;你进行验证并提交。
agy此处内容并不针对特定的协调Agent。该流程仅需具备执行shell命令和读取文件的能力,因此任何类似的Agent都可驱动它。它专为Claude Code设计并运行;其他协调工具虽适配设计,但尚未经过验证。
When NOT to use this
请勿使用此技能的场景
- The task is small enough to just do inline - delegation overhead is not worth it.
- The CLI is not installed or not authenticated. Install it from Antigravity's CLI docs and run the first-launch setup.
agy - You want to write the code yourself, or you only need a review without edits. This relay does not expose a proven CLI-enforced read-only mode yet.
- 任务足够小,可以直接完成——委托的开销得不偿失。
- 未安装CLI或未完成身份验证。请从Antigravity的CLI文档安装它并完成首次启动设置。
agy - 你希望自行编写代码,或仅需审核而无需修改。此中继机制目前尚未提供经验证的CLI强制只读模式。
Prerequisites (check once)
前置条件(检查一次)
- succeeds. If not, install the Antigravity CLI and complete first-launch setup.
agy help - succeeds. That proves the CLI can authenticate and list the available model labels.
agy models - You are in (or will point at) the target git repository.
--cd
- 执行成功。若失败,请安装Antigravity CLI并完成首次启动设置。
agy help - 执行成功。这证明CLI可完成身份验证并列出可用的模型标签。
agy models - 你处于(或将指向)目标git仓库。
--cd
Choose the implementer model
选择实现工具模型
agy--modelagy--modelThe loop
执行流程
Run these five steps per task. Steps 1, 4, and 5 are your judgment; 2 and 3 are mechanical.
每个任务执行以下五个步骤。步骤1、4和5需要你的判断;步骤2和3为机械操作。
1. Write the brief
1. 撰写任务简报
Antigravity sees only the text you send plus what it can inspect in the workspace - no chat history, no
shared context. Everything the task needs goes in the brief: the goal, the current state, what to
change, what to leave untouched, the project's actual gate commands, and a report contract. Tell
Antigravity it will not commit (you will). Keep one task per brief. Full guidance and a template:
references/writing-the-brief.md.
Antigravity只能看到你发送的文本以及它可在工作区中检查的内容——无聊天历史,无共享上下文。任务所需的所有信息都需包含在简报中:目标、当前状态、需修改的内容、需保留的内容、项目的实际校验命令,以及报告约定。告知Antigravity它不会提交代码(由你完成)。每份简报对应一个任务。完整指南和模板:references/writing-the-brief.md。
2. Dispatch
2. 分发任务
Send the brief to Antigravity with the bundled helper. It wraps , captures the run, and
writes a structured - so your only job is "run a command, read a file." (
below is this skill's installed directory - the folder containing this .)
agy --printresult.json<skill-dir>SKILL.mdbash
node "<skill-dir>/scripts/relay.mjs" --brief brief.txt --cd /path/to/repo使用捆绑的辅助工具将简报发送给Antigravity。它封装了命令,捕获运行过程,并写入结构化的文件——因此你的工作仅为“执行命令,读取文件”。(下方的是此技能的安装目录——包含本文件的文件夹。)
agy --printresult.json<skill-dir>SKILL.mdbash
node "<skill-dir>/scripts/relay.mjs" --brief brief.txt --cd /path/to/repochoose a model label: add --model "<label from agy models>"
选择模型标签: 添加 --model "<label from agy models>"
enable Antigravity terminal sandbox: add --sandbox
启用Antigravity终端沙箱: 添加 --sandbox
resume the most recent conversation: add --resume-last (delta brief only)
恢复最近一次对话: 添加 --resume-last (仅需增量简报)
see all options: node .../relay.mjs --help
查看所有选项: node .../relay.mjs --help
The helper starts a fresh Antigravity project by default and passes `--add-dir <repo>` (the `--cd`
path, absolute) so `agy` has an explicit workspace. It does **not** pass `--dangerously-skip-permissions` by default.
Mechanics, flags, and the `result.json` shape: [references/dispatch-and-poll.md](references/dispatch-and-poll.md).
默认情况下,辅助工具会启动一个全新的Antigravity项目,并传递`--add-dir <repo>`(`--cd`指定的绝对路径),以便`agy`拥有明确的工作区。默认情况下**不会**传递`--dangerously-skip-permissions`参数。详细机制、标志和`result.json`结构:[references/dispatch-and-poll.md](references/dispatch-and-poll.md)。3. Wait for completion
3. 等待完成
The helper blocks until Antigravity finishes, so back it with whatever your orchestrator offers and
resume when it returns:
- Claude Code: run the Bash call with ; you are notified on completion.
run_in_background: true - Plain shell / other agents: run it in the foreground for short tasks, or background it and poll the result file.
Do not trust progress trackers over reality: a run is finished when is written and the
process has exited. Read the working tree, not a status line.
result.json辅助工具会阻塞直到Antigravity完成任务,因此请利用你的协调工具提供的后台运行能力,在任务完成后恢复操作:
- Claude Code: 使用执行Bash调用;完成后会收到通知。
run_in_background: true - 普通shell / 其他Agent: 短任务可在前台运行,长任务可后台运行并轮询结果文件。
不要过度依赖进度追踪器:只有当文件已写入且进程已退出时,任务才算完成。请查看工作树,而非状态行。
result.json4. Review - do not trust the self-report
4. 审核——不要轻信自我报告
Antigravity's includes its own final message and any gate claims. Re-verify, don't
accept:
result.json- Re-run the project's gates yourself (the test/lint/build commands from step 1).
- Read the diff against the brief: did Antigravity do what was asked, nothing more and nothing less?
in the result is your starting point.
touchedFiles - Run the relevant guard skills on the diff if you have them installed.
- For schema/migration changes, round-trip them; for removals, grep for dangling references.
Full checklist: references/review-and-land.md.
Antigravity的包含其最终消息和任何校验声明。请重新验证,不要直接接受:
result.json- 自行重新运行项目的校验命令(步骤1中的测试/ lint/构建命令)。
- 对照简报查看代码差异: Antigravity是否完全按要求执行,不多不少?结果中的是你的检查起点。
touchedFiles - 如果已安装相关守护技能,请针对差异运行它们。
- 对于架构/迁移变更,请进行往返验证;对于删除操作,请搜索是否存在悬空引用。
完整检查清单:references/review-and-land.md。
5. Land it
5. 完成提交
The implementer edits the working tree; the orchestrator commits. Only after the gates pass and the
diff holds:
- Commit the verified work yourself, with a clear message.
- If it needs changes, send a delta brief with and review again.
--resume-last
实现工具会修改工作树;协调者负责提交。只有在校验通过且差异符合要求后:
- 自行提交已验证的工作,并附上清晰的提交信息。
- 如果需要修改,请使用参数发送增量简报并再次审核。
--resume-last
Permission model
权限模型
Antigravity owns its own permission policy. The relay does not bypass it by default. Use
only when the human explicitly accepts that Antigravity may
auto-approve tool permission requests. Use when you want Antigravity's terminal sandbox
enabled for the run. Antigravity's own help says auto-approves all
tool permission requests without prompting, including a request to act outside the sandbox. Do not
treat as an enforced boundary when the flags are combined; treat the run as full access.
--dangerously-skip-permissions--sandbox--dangerously-skip-permissions--sandboxAntigravity拥有自己的权限策略。默认情况下,中继机制不会绕过该策略。仅当用户明确同意Antigravity可自动批准工具权限请求时,才使用参数。当你希望为运行启用Antigravity终端沙箱时,使用参数。Antigravity自身的帮助文档说明,会自动批准所有工具权限请求而无需提示,包括在沙箱外操作的请求。当这两个标志组合使用时,请勿将视为强制边界;应将此次运行视为拥有完全访问权限。
--dangerously-skip-permissions--sandbox--dangerously-skip-permissions--sandboxAuthorization model
授权模型
Delegation is something the human opts into. Once they have ("run this queue", "proceed"), committing
verified, gate-passing work is the agreed contract. Two limits on that mandate: surface, don't
absorb (report Antigravity's design decisions, defensible-but-unasked turns, and non-blocking
nitpicks rather than silently keeping them) and stop for scope changes (if correct completion needs
going beyond the brief, ask - don't expand the mandate yourself). The full treatment is in
references/review-and-land.md.
委托是用户主动选择的操作。一旦用户确认(“运行此队列”、“继续”),提交已验证且通过校验的工作就是约定的内容。此授权有两个限制:透明化,不隐瞒(报告Antigravity的设计决策、合理但未被要求的变更,以及不影响功能的小问题,而非默默保留);范围变更时停止(若正确完成任务需要超出简报范围的工作,请询问用户——不要自行扩大授权范围)。完整说明请见references/review-and-land.md。
References
参考资料
- references/writing-the-brief.md - how to write a brief Antigravity can execute blind: structure, XML blocks, the report contract, and real gate commands.
- references/dispatch-and-poll.md - flags, the
relay.mjscontract, backgrounding per orchestrator, and recovery when a run misbehaves.result.json - references/review-and-land.md - the review checklist, the commit
boundary, and the rework cycle via .
--resume-last - references/multi-task-queues.md - running a sequential queue: carrying constraints forward, progress tracking, and the end-of-run coherence check.
- references/writing-the-brief.md - 如何撰写Antigravity可独立执行的简报:结构、XML块、报告约定以及实际校验命令。
- references/dispatch-and-poll.md - 的标志、
relay.mjs的约定、各协调工具的后台运行方式,以及运行异常时的恢复方法。result.json - references/review-and-land.md - 审核检查清单、提交边界,以及通过进行返工的流程。
--resume-last - references/multi-task-queues.md - 运行顺序队列:传递约束条件、进度追踪,以及运行结束时的一致性检查。