pub struct OperatorDef {
pub name: String,
pub display_name: Option<String>,
pub kind: Option<OperatorKind>,
pub spec: Value,
pub profile: Option<AgentProfile>,
pub meta: Option<AgentMeta>,
}Expand description
Design-time definition of an Operator role (first-class).
AgentDef.spec.operator_ref references this struct’s name as a logical role name.
Binding to a runtime backend (WS session / SDK / pool, etc.) is established via the
attach path; the BP side only declares “under this logical name we expect an Operator
of this Kind”.
spec is an escape hatch for kind-specific config (WS endpoint / SDK profile / pool
binding, etc.). Even when empty, declaring name + kind alone is enough for
compile-time validation to succeed (= it guarantees that agent operator_ref values
reference an existing definition).
Fields§
§name: StringLogical role name (= design-time symbol referenced from AgentDef.spec.operator_ref).
display_name: Option<String>Display name for UI / docs (optional).
kind: Option<OperatorKind>Kind axis of the Operator (MainAi / Automate / Composite) — the “BP
Agent-level” tier of the 4-tier OperatorKind cascade (see
Blueprint.default_operator_kind for the full tier list). None
when this OperatorDef does not declare a kind; the resolver then
falls through to BP Global / Default Fallback for agents referencing
this role via AgentDef.spec.operator_ref.
spec: ValueKind-specific config (WS endpoint / SDK profile / pool binding, etc.). Interpreted by the factory.
profile: Option<AgentProfile>Operator persona information (e.g. system_prompt template). Same shape as
AgentDef.profile. Used as a template when the Operator itself plays a “role”.
If None, the agent-side profile is used instead.
meta: Option<AgentMeta>Operator-level metadata (description / version / tags).
Trait Implementations§
Source§impl Clone for OperatorDef
impl Clone for OperatorDef
Source§fn clone(&self) -> OperatorDef
fn clone(&self) -> OperatorDef
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for OperatorDef
impl Debug for OperatorDef
Source§impl<'de> Deserialize<'de> for OperatorDef
impl<'de> Deserialize<'de> for OperatorDef
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<OperatorDef, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<OperatorDef, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl JsonSchema for OperatorDef
impl JsonSchema for OperatorDef
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 moreSource§impl PartialEq for OperatorDef
impl PartialEq for OperatorDef
Source§fn eq(&self, other: &OperatorDef) -> bool
fn eq(&self, other: &OperatorDef) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for OperatorDef
impl Serialize for OperatorDef
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for OperatorDef
Auto Trait Implementations§
impl Freeze for OperatorDef
impl RefUnwindSafe for OperatorDef
impl Send for OperatorDef
impl Sync for OperatorDef
impl Unpin for OperatorDef
impl UnsafeUnpin for OperatorDef
impl UnwindSafe for OperatorDef
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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