delegate
Save premium tokens by offloading routine subtasks to cheaper models. Send a self-contained task with full context and receive the model's output directly.
Instructions
Offload a self-contained subtask to a cheaper model and return its output.
WHEN TO USE: hand off replaceable grunt work to save your premium tokens — boilerplate code, small bug fixes, formatting, translation, reading/summarizing long documents, drafting routine copy. Do NOT delegate judgment work (planning, architecture, final review, talking to the user) — keep that for yourself.
The delegated model sees ONLY the task string and has NO access to this
conversation. So make task fully self-contained (include all needed context).
Args: task: Complete, self-contained instruction for the cheap model. model: "auto" (default) routes by task — code→deepseek, long docs→kimi, Chinese→qwen, multi-step→mimo, quick chores→flash. Or force an alias (deepseek/mimo/flash/kimi/qwen) or a raw proxy model_name. max_tokens: Output cap. Default 4000 (kept large so reasoning models that spend budget on hidden thinking still return non-empty text).
Note: a call typically takes ~10-60s (longer for big inputs) and blocks until the cheap model returns, so prefer one focused task per call.
Returns: The model's text output, or a string starting with "[delegate-error]" on failure.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task | Yes | ||
| model | No | auto | |
| max_tokens | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |