Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

▢️execution

Struct CommittedToolResult

A tool result committed for a walk and held until payment settlement, tracking the accepted output, primary and secondary failure evidence, and per-leader gas records.

Fields

expected_vertex: nexus_interface::graph::RuntimeVertexvariant: nexus_interface::graph::OutputVariantvariant_ports_to_data: sui::vec_map::VecMap<nexus_interface::graph::OutputPort, nexus_primitives::data::NexusData>failure_evidence_kind: std::option::Option<nexus_interface::verifier::FailureEvidenceKind>primary_failure_evidence_kind: std::option::Option<nexus_interface::verifier::FailureEvidenceKind>secondary_failure_evidence_kind: std::option::Option<nexus_interface::verifier::FailureEvidenceKind>current_leader_cap_id: sui::object::IDhas_finalized_onchain_payload: boolleader_records: sui::vec_map::VecMap<sui::object::ID, nexus_workflow::execution::CommittedToolResultLeaderRecord>

Struct CommittedToolResultLeaderRecord

Per-leader commit metadata lives inside CommittedToolResult because settlement must atomically inspect the accepted payload and all submitted gas charges for a walk.

Fields

commit_tx_digest: vector<u8>recipient: addresscommit_gas_charge: std::option::Option<u64>settlement_gas_charge: std::option::Option<u64>

Struct CommittedToolResultKey

Dynamic field key for a walk's committed tool result awaiting settlement.

Fields

walk_index: u64

Struct OnchainToolResultKey

Dynamic field key for the per-walk on-chain result object ID; CommittedToolResultKey cannot be reused because committed outputs and pre-commit result IDs have different lifecycles.

Fields

walk_index: u64

Struct ExecutionPaymentInsufficientSettlementFieldKey

Dynamic field key for the record of walks blocked because the execution payment cannot cover their pending gas charges.

Fields

Struct ExecutionPaymentInsufficientSettlement

The set of walk indices whose settlement is blocked by insufficient execution payment.

Fields

walks: vector<u64>

Struct DAGExecution

Runtime execution of [DAG] comprises walking the graph by evaluating vertices and following the edges.

Fields

id: sui::object::UID

Struct DAGExecutionInnerV1

Version one stored layout for [DAGExecution].

Fields

dag: sui::object::IDDAG executed by this object.entry_group: nexus_interface::graph::EntryGroupEntry group selected when the execution starts.invoker: addressAddress that invoked the DAG.created_at: u64Clock timestamp when the execution was created.priority_fee_percentage: u64The normalized priority fee applied to the execution payment.agent_id: sui::object::IDAgent identity pinned by the resolved execution target.skill_id: u64Skill identity pinned by the resolved execution target.interface_version: nexus_interface::version::InterfaceVersionInterface version pinned for this execution.task_id: sui::object::IDTask that produced this execution.occurrence_id: u64Scheduled occurrence identity within the Task.last_request_for_execution_emitted_at_digest: vector<u8>Digest of the latest transaction that emitted an off-chain Tool request. Empty until the first [RequestWalkExecutionEvent] is emitted. Helps us guarantee that when a tx is over it will have emitted only valid events, not ones that were superseded by a newer request for execution. This would happen if e.g. two on-chain tools were invoked in a single tx. It's still possible, but thanks to emitted request tracking and this field we can skip emitting events for all but the last tool(s).last_request_for_execution_leaders: vector<sui::object::ID>Assigned leaders for the latest emitted [RequestWalkExecutionEvent]. Persist the assignment rather than recomputing it from the live registry so later submissions are checked against the original request leaders.network: sui::object::IDLeader network whose capabilities authorize request handling and result submission for this DAG. Only CloneableOwnerCap<leader_cap::OverNetwork> values bound to this ID carry that authority.evaluations: sui::object_table::ObjectTable<nexus_interface::graph::Vertex, nexus_interface::graph::VertexEvaluations>Submitted values that are fed to the relevant input ports. Dynamic object fields so that they can be queried.terminal_records: sui::vec_map::VecMap<u64, nexus_workflow::execution::TerminalErrEvalRecord>Authoritative per-walk _err_eval records keyed by walk index.submission_failure_records: sui::vec_map::VecMap<u64, vector<nexus_workflow::execution::SubmissionFailureRecord>>Persisted per-walk leader submission-failure records keyed by walk index.pending_retry_handoff_cap_ids: sui::vec_map::VecMap<u64, sui::object::ID>While a dedicated retry handoff is pending, only this cap may submit the affected walk.walk_request_authorities: sui::vec_map::VecMap<u64, nexus_workflow::execution::WalkRequestAuthority>Authoritative per-walk primary/secondary ownership and takeover state.pending_payment_settlements: sui::vec_map::VecMap<nexus_interface::graph::RuntimeVertex, nexus_workflow::execution_failure::VertexPaymentSettlement>Tool payment settlement directives keyed by evaluated runtime vertex.walks: vector<nexus_workflow::execution::DAGWalk>Concurrent [DAGWalk] values and their lifecycle states.active_walks: u64Count of walks currently waiting for a vertex result.pending_abort_walks: u64Count of walks whose abort is waiting on other active walks to settle.pending_settlement_walks: u64Count of walks with a committed result waiting for explicit settlement.successful_walks: u64Count of walks that reached an end state successfully.failed_walks: u64Count of walks that failed without aborting the whole execution.aborted_walks: u64Count of walks that terminally aborted the execution.consumed_walks: u64Count of walks consumed while waiting for converged inputs or spawned branches.cancelled_walks: u64Count of walks cancelled after another walk failed or aborted.

Struct AgentGrantFieldKey

Dynamic field key for a per-vertex agent authorization grant stored on an execution, discriminated by grant kind.

Fields

vertex: std::ascii::Stringkind: vector<u8>

Struct DagExecutionPaymentFieldKey

Dynamic object field key for the execution's attached TAP payment object.

Fields

Struct TerminalErrEvalRecord

The authoritative record of a walk's terminal _err_eval outcome, capturing the failing vertex, leader, failure class, resolved post-failure action, and the evidence hash used to converge duplicate submissions.

Fields

walk_index: u64vertex: nexus_interface::graph::RuntimeVertexleader: addressfailure_class: nexus_workflow::execution_failure::WorkflowFailureClassoutcome: std::option::Option<nexus_interface::graph::PostFailureAction>reason: std::ascii::Stringvariant_ports_to_data: sui::vec_map::VecMap<nexus_interface::graph::OutputPort, nexus_primitives::data::NexusData>err_eval_hash: vector<u8>

Struct SubmissionFailureRecord

A record of one leader's failed submission for a walk, naming the failed leader, the winning leader that took over if any, and the evidence hash.

Fields

walk_index: u64vertex: nexus_interface::graph::RuntimeVertexfailed_leader: addresswinning_leader: std::option::Option<address>reason: std::ascii::Stringerr_eval_hash: vector<u8>

Struct WalkRequestAuthority

Per-walk ownership state assigning a primary and secondary leader cap to the walk's requested vertex, its current authority phase, and whether a secondary takeover has been recorded.

Fields

vertex: nexus_interface::graph::RuntimeVertexprimary_cap_id: sui::object::IDsecondary_cap_id: sui::object::IDphase: nexus_workflow::execution::WalkRequestAuthorityPhasetakeover_recorded: bool

Enum DAGWalk

Each [DAGWalk] represents a unique path through the [DAG].

Variants

Variant Activenext_vertex: nexus_interface::graph::RuntimeVertexVertex that should be executed next.timeout_ms: u64Timeout for the walk, taken from the tool configuration.requires_vertex_authorization_grant: boolWhether this on-chain vertex requires an execution-child workflow authorization grant before it can be scheduled.created_at: u64Timestamp at which the current request stage began. Invocation authorization and executable Tool work are separate stages, so this value advances when authorization creates the executable request. Expiry is evaluated as `created_at + 2 Γ— timeout_ms`.Variant PendingSettlementnext_vertex: nexus_interface::graph::RuntimeVertexCommitted vertex waiting for payment settlement.timeout_ms: u64Timeout for the walk, taken from the tool configuration.requires_vertex_authorization_grant: boolWhether this on-chain vertex requires an execution-child workflow authorization grant before it can be scheduled.created_at: u64Creation timestamp used to determine pending-settlement expiry as `created_at + 2 Γ— timeout_ms`.Variant SuccessfulVariant FailedVariant Consumedat_vertex: nexus_interface::graph::RuntimeVertexVariant AbortedA walk is aborted when _err_eval resolves to Terminate. If an execution already contains an aborted walk, later active walks are still allowed to submit results but once they do, they are marked as [DAGWalk::Cancelled].at_vertex: nexus_interface::graph::RuntimeVertexVariant PendingAbortA walk is pending abort after double timeout when its vertex payment has been unlocked, but other active walks still need to settle.at_vertex: nexus_interface::graph::RuntimeVertexVariant Cancelled

Enum WalkRequestAuthorityPhase

The stage of leader ownership for a walk request: the primary leader's exclusive window, the secondary leader's takeover window, or a retry handed off exclusively to the secondary.

Variants

Variant PrimaryWindowVariant SecondaryWindowVariant SecondaryOnlyRetry

Constants

Function has_vertex_authorization_grant

Whether an agent vertex authorization grant is stored for the given runtime vertex.

Function assert_complete_authorization_bindings

Verifies that authorization bindings exactly cover the vertices that need them.

A binding is required for every [Vertex] whose onchain [ToolRegistry] definition requires workflow authorization. Bindings for any other vertex are rejected, including names that are absent from the [DAG]. Exact coverage makes missing authorization unreachable after execution admission.

Function interface_version

Interface version pinned when [DAGExecution] was created.

Function task_id

Returns the Task that produced this execution.

Function occurrence_id

Returns the scheduled occurrence identity.

Last updated