handoff
Send a coding task to a separate agent (Codex or Antigravity) for independent execution and return the result.
Instructions
Hand a task off to a peer coding-agent CLI and return its answer (blocking).
Use this for tasks that finish in a few minutes. For long/agentic work,
prefer `handoff_start` + `handoff_status` so you get progress and don't block.
Choosing a backend (see `handoff_guidance` for detail):
- `codex` (OpenAI): code review, bug hunting, refactors, terminal-agentic
work, second opinion on code/text. Text & images (not PDFs).
- `antigravity` (Google Gemini 3): visual feedback (screenshots, diagrams,
PDFs), very-long-context reads (whole repos / huge docs), cheap bulk.
Hand off aggressively when the Claude/Fable usage limit is close — each
backend bills to a separate subscription pool.
Args:
prompt: What to do. The peer agent has NONE of this conversation's
context — be explicit and self-contained.
backend: "codex" or "antigravity".
files: Absolute/~ paths to attach. codex: text + images. antigravity:
text, images, and PDFs.
model: Optional model id override; empty = the CLI's own default
(e.g. "gpt-5.3-codex", "gemini-3.1-pro-preview").
cwd: A project directory the agent may read for extra context. The
process itself runs in a throwaway temp dir; originals are never
modified unless you set `approve=True`.
approve: Allow the agent to actually make edits (codex: workspace-write
sandbox; antigravity: --dangerously-skip-permissions). Default False
= read-only, right for reviews/opinions.
timeout: Seconds before abort.
Returns:
The peer agent's response, or a clear "[handoff error] …" string.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | ||
| files | No | ||
| model | No | ||
| prompt | Yes | ||
| approve | No | ||
| backend | Yes | ||
| timeout | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |