Expand description
Execute use case: prepare a session for agent execution.
Functions§
- billable_
user_ turn_ count - Count the number of billable user turns in a session — i.e. user messages that were actually initiated by the human, excluding runtime-injected resume messages from child completion, retry, or conclusion-with-options.
- consume_
pending_ conclusion_ with_ options_ resume - evaluate_
client_ sync - has_
pending_ conclusion_ with_ options_ resume - has_
pending_ retry_ resume - has_
pending_ user_ message - Whether the session has resumable user work (pending tool response, retry, or last message is from user).
- is_
billable_ user_ turn - Returns true when the message represents a billable end-user turn.
- is_
system_ resume_ message - Returns true if the message was synthesized by the runtime to resume a suspended root session (child completion, retry, conclusion-with-options).
- prepare_
execute - Prepare an execute: load session, resolve model/reasoning, validate, update metadata, return outcome.