pub struct ProviderNativeAgentGraph { /* private fields */ }Expand description
Compiled schemas, state machine, and declarative graph for one agent version.
Implementations§
Source§impl ProviderNativeAgentGraph
impl ProviderNativeAgentGraph
Sourcepub const MAX_CHECKPOINT_INVOCATION_REFERENCES: u64 = MAX_CHECKPOINT_INVOCATION_REFERENCES
pub const MAX_CHECKPOINT_INVOCATION_REFERENCES: u64 = MAX_CHECKPOINT_INVOCATION_REFERENCES
Maximum tool invocation references retained across one checkpoint.
Sourcepub fn compile(
descriptor: AgentDescriptor,
graph_identity: CapabilityIdentity,
reducer_identity: CapabilityIdentity,
state_schema_id: SchemaId,
input_security_label: SecurityLabel,
policy: Arc<dyn AgentToolPolicy>,
accounting: Arc<dyn AgentInvocationAccounting>,
) -> Result<Self, ProviderNativeAgentGraphBuildError>
pub fn compile( descriptor: AgentDescriptor, graph_identity: CapabilityIdentity, reducer_identity: CapabilityIdentity, state_schema_id: SchemaId, input_security_label: SecurityLabel, policy: Arc<dyn AgentToolPolicy>, accounting: Arc<dyn AgentInvocationAccounting>, ) -> Result<Self, ProviderNativeAgentGraphBuildError>
Compiles the supported v1 provider-native execution subset.
V1 deliberately rejects tool-call emulated final output. Model-native structured output supports finite durable repair turns. Sequential Tools and bounded parallel read-only Tools are supported without allowing writes or completion timing to reorder the durable transcript.
Sourcepub const fn graph(&self) -> &CompiledGraph
pub const fn graph(&self) -> &CompiledGraph
Returns the exact compiled graph.
Sourcepub const fn descriptor(&self) -> &AgentDescriptor
pub const fn descriptor(&self) -> &AgentDescriptor
Returns the immutable agent descriptor snapshot.
Sourcepub const fn contract_digest(&self) -> Digest
pub const fn contract_digest(&self) -> Digest
Returns the exact graph composition checksum.
Sourcepub fn register_schema(
&self,
builder: &mut JsonSchemaRegistryBuilder,
) -> Result<(), JsonSchemaRegistryError>
pub fn register_schema( &self, builder: &mut JsonSchemaRegistryBuilder, ) -> Result<(), JsonSchemaRegistryError>
Registers the generated state/update schema before the registry freezes.
Sourcepub fn register_executable(
&self,
builder: &mut ExecutableGraphRegistryBuilder,
store: PostgresStore,
invocation_executor: DurableInvocationExecutor,
schemas: JsonSchemaRegistry,
) -> Result<(), ProviderNativeAgentRegistrationError>
pub fn register_executable( &self, builder: &mut ExecutableGraphRegistryBuilder, store: PostgresStore, invocation_executor: DurableInvocationExecutor, schemas: JsonSchemaRegistry, ) -> Result<(), ProviderNativeAgentRegistrationError>
Registers the graph, reducer, and both executable nodes into one frozen deployment snapshot.
The supplied schema registry must be the exact registry used to create
builder and must already contain the generated state schema, the
descriptor input/output/tool schemas, and the standard invocation event
schema. Registry closure is rechecked again when the builder freezes.
Sourcepub fn initial_state(
&self,
) -> Result<CheckpointState, ProviderNativeAgentStateError>
pub fn initial_state( &self, ) -> Result<CheckpointState, ProviderNativeAgentStateError>
Generates a fresh bounded initial state before durable admission.
Sourcepub fn restore_state(
&self,
state: &CheckpointState,
) -> Result<ProviderNativeAgentState, ProviderNativeAgentStateError>
pub fn restore_state( &self, state: &CheckpointState, ) -> Result<ProviderNativeAgentState, ProviderNativeAgentStateError>
Decodes and revalidates a checkpoint against this exact compiled composition contract.
This is the supported inspection boundary for recovery tooling; callers never need to duplicate the generated schema or state invariants.
Trait Implementations§
Source§impl AgentServiceDeployment for ProviderNativeAgentGraph
impl AgentServiceDeployment for ProviderNativeAgentGraph
Source§fn descriptor(&self) -> &AgentDescriptor
fn descriptor(&self) -> &AgentDescriptor
Source§fn graph(&self) -> &CompiledGraph
fn graph(&self) -> &CompiledGraph
Source§fn initial_state(&self) -> Result<CheckpointState, AgentServiceDeploymentError>
fn initial_state(&self) -> Result<CheckpointState, AgentServiceDeploymentError>
Source§impl Clone for ProviderNativeAgentGraph
impl Clone for ProviderNativeAgentGraph
Auto Trait Implementations§
impl !RefUnwindSafe for ProviderNativeAgentGraph
impl !UnwindSafe for ProviderNativeAgentGraph
impl Forget for ProviderNativeAgentGraph
impl Freeze for ProviderNativeAgentGraph
impl Move for ProviderNativeAgentGraph
impl Send for ProviderNativeAgentGraph
impl Sync for ProviderNativeAgentGraph
impl Unpin for ProviderNativeAgentGraph
impl UnsafeUnpin for ProviderNativeAgentGraph
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more