Basic Usage
run_id, forked_from_run_id pointing at the source, and forked_from_message_index recording where it cut.
Where to Fork From
continue_from chooses the message boundary.
For valid integer indices on a specific run, call the checkpoints endpoint. Every index it returns is pair-safe.
Forking vs Regenerating
If you want a cheap “try again with steering” without re-running tools, use Regenerate. If you want to rewind further (drop tools, drop intermediate turns, change the prompt entirely), fork.
Auto-Fork on COMPLETED
Continuing a completed run always produces a newrun_id, even without fork=True:
Pair-Safe Truncation
Integercontinue_from=K snaps down to a “pair-safe” boundary when K lands mid-tool-batch.
Given the transcript:
The fork response’s
forked_from_message_index reflects the actual boundary used. If it differs from what you sent, the dispatch snapped the index down.
Indices returned by the checkpoints endpoint are always pair-safe by construction.
Teams
Team.continue_run(fork=True, continue_from=...) works the same way:
parent_run_id. The fork starts fresh and may produce new member runs.
HTTP
continue_from accepts "end", "last_user", or a numeric string (e.g. "4").