script_run or Agent Completion: which for a GPT-6.1 Sol agent?

A GPT-6.1 Sol coding agent can call Sume via MCP script_run or Agent Completions. Which fits fan-out of known calls, and which fits open-ended tasks.

6 min readSume
All posts

Use script_run when your coding agent already knows the calls: three or more independent tool calls of the same shape, such as one image per scene. Use an Agent Completion when the task itself is open-ended and Sume's own agent should decide the steps. script_run runs in a bounded 5 to 55 second window on the MCP session; a completion is an asynchronous run with its own sandbox, started over the API with a required spend cap.

What each one is

MCP tools and gates describes script_run as a short JavaScript program run on the Sume side that calls listed tools in a loop, in parallel or conditionally, and returns one value. It is bounded by timeout_seconds (5 to 55), max_calls and max_paid_calls, and paid creates inside it still need their own idempotency_key. The Agent Completions page describes an unattended run of the Sume Agent with a sandbox, tools, an MCP bridge and media generation, answering 202 with a receipt you poll.

Side by side

Choosing between them (read 2026-10-04)
Question`script_run`Agent Completion
Who plans the steps?Your agent writes the scriptSume's agent decides
Entry pointHosted MCP toolPOST /v1/agent/completions
Time modelUp to 55 seconds, then jobs to wait onAsynchronous run, poll or webhook
Spend controlmax_paid_calls, max_spend_usd per callRequired generation_spend_cap_usd
CredentialOAuth with write, or an API keyAPI key with agent_completions:write (service-account keys are refused)
ResultReturned value, call journal, child jobsoutput, artifacts, usage

Rules of thumb

  • Fan-out of identical, well-specified calls: script_run. Six scene stills, ten caption passes.
  • Read-heavy discovery that needs judgment: let the coding agent call read tools directly.
  • A brief like "make a teaser from this URL" where the steps are unknown: Agent Completion.
  • Anything that must survive the coding session ending: Agent Completion, or save job ids from script_run and wait later.

Limits to remember

Discovery tools and script_run itself cannot be called from a script. script_run returns child jobs[] you still jobs_wait on, one call holding up to 55 seconds. A completion has no streaming and no thread continuation yet, and assistant turns in messages[] are rejected. If you need a saved, repeatable workflow with changing inputs, a Format is a third option, and Scheduled runs saved instructions on a clock.

Whichever route you use, the model on your side does not have to be GPT-6.1 Sol. The same split applies to any coding agent that can speak MCP or HTTP.

Sources

Related posts

More in Agents

All Agents posts

Written by Sume