pub enum NodeInvocationBinding {
Model {
activation: NodeActivation,
head: ModelInvocationHead,
},
Tool {
activation: NodeActivation,
head: ToolInvocationHead,
},
}Expand description
Exact terminal external invocation consumed by one node result.
The embedded activation makes cross-node substitution locally detectable. A durable adapter must additionally reload the exact full invocation revision and prove that its intent activation equals this value before it accepts the reference.
Variants§
Model
Exact terminal model invocation.
Both successful and known-failed model outcomes are consumable when a node has deterministic semantics for the failure. Ambiguous or unfinished provider outcomes remain ineligible.
Fields
activation: NodeActivationActivation recorded by the full invocation intent.
head: ModelInvocationHeadCompact terminal model revision identity.
Tool
Exact terminal tool invocation.
Both successful and known-failed tool outcomes are consumable: a model transcript must be able to observe a deterministic tool error. Ambiguous or unfinished tool outcomes remain ineligible.
Fields
activation: NodeActivationActivation recorded by the full invocation intent.
head: ToolInvocationHeadCompact terminal tool revision identity.
Implementations§
Source§impl NodeInvocationBinding
impl NodeInvocationBinding
Sourcepub fn from_model(
invocation: &ModelInvocation,
) -> Result<Self, NodeInvocationBindingError>
pub fn from_model( invocation: &ModelInvocation, ) -> Result<Self, NodeInvocationBindingError>
Constructs a binding from a fully validated terminal model invocation.
§Errors
Returns NodeInvocationBindingError unless the invocation is
committed or known-failed and its journal anchor strictly follows its
base checkpoint.
Sourcepub fn from_tool(
invocation: &ToolInvocation,
) -> Result<Self, NodeInvocationBindingError>
pub fn from_tool( invocation: &ToolInvocation, ) -> Result<Self, NodeInvocationBindingError>
Constructs a binding from a fully validated terminal tool invocation.
§Errors
Returns NodeInvocationBindingError unless the invocation is
committed or known-failed and its journal anchor strictly follows its
base checkpoint.
Sourcepub const fn kind(&self) -> NodeInvocationBindingKind
pub const fn kind(&self) -> NodeInvocationBindingKind
Returns the external invocation kind.
Sourcepub const fn activation(&self) -> &NodeActivation
pub const fn activation(&self) -> &NodeActivation
Returns the exact owning node activation.
Sourcepub const fn invocation_id(&self) -> InvocationId
pub const fn invocation_id(&self) -> InvocationId
Returns the stable logical invocation identity.
Sourcepub const fn journal_head(&self) -> &JournalHead
pub const fn journal_head(&self) -> &JournalHead
Returns the exact journal head that committed the external result.
Sourcepub const fn model_head(&self) -> Option<&ModelInvocationHead>
pub const fn model_head(&self) -> Option<&ModelInvocationHead>
Returns the model head for a model binding.
Sourcepub const fn tool_head(&self) -> Option<&ToolInvocationHead>
pub const fn tool_head(&self) -> Option<&ToolInvocationHead>
Returns the tool head for a tool binding.
Trait Implementations§
Source§impl Clone for NodeInvocationBinding
impl Clone for NodeInvocationBinding
Source§impl Debug for NodeInvocationBinding
impl Debug for NodeInvocationBinding
Source§impl<'de> Deserialize<'de> for NodeInvocationBinding
impl<'de> Deserialize<'de> for NodeInvocationBinding
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
impl Eq for NodeInvocationBinding
Source§impl JsonSchema for NodeInvocationBinding
impl JsonSchema for NodeInvocationBinding
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read more