Struct LLMMetryPlugin
pub struct LLMMetryPlugin { /* private fields */ }Expand description
Plugin that captures LLM and tool telemetry.
Implementations§
§impl LLMMetryPlugin
impl LLMMetryPlugin
pub fn new(sink: impl MetricsSink + 'static) -> LLMMetryPlugin
pub fn with_model(self, model: impl Into<String>) -> LLMMetryPlugin
pub fn with_provider(self, provider: impl Into<String>) -> LLMMetryPlugin
pub fn with_chat_options(self, opts: &ChatOptions) -> LLMMetryPlugin
Trait Implementations§
§impl AgentBehavior for LLMMetryPlugin
impl AgentBehavior for LLMMetryPlugin
fn id(&self) -> &str
fn run_start<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<LifecycleAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
LLMMetryPlugin: 'async_trait,
fn before_inference<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<BeforeInferenceAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
LLMMetryPlugin: 'async_trait,
fn after_inference<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<AfterInferenceAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
LLMMetryPlugin: 'async_trait,
fn before_tool_execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<BeforeToolExecuteAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
LLMMetryPlugin: 'async_trait,
fn after_tool_execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<AfterToolExecuteAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
LLMMetryPlugin: 'async_trait,
fn run_end<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<LifecycleAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
LLMMetryPlugin: 'async_trait,
fn behavior_ids(&self) -> Vec<&str>
Source§fn register_lattice_paths(&self, _registry: &mut LatticeRegistry)
fn register_lattice_paths(&self, _registry: &mut LatticeRegistry)
Register lattice (CRDT) paths with the registry.
Source§fn register_state_scopes(&self, _registry: &mut StateScopeRegistry)
fn register_state_scopes(&self, _registry: &mut StateScopeRegistry)
Register state scopes with the registry.
Source§fn register_state_action_deserializers(
&self,
_registry: &mut StateActionDeserializerRegistry,
)
fn register_state_action_deserializers( &self, _registry: &mut StateActionDeserializerRegistry, )
Register state-action deserializers for persisted intent-log replay and recovery.
fn step_start<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<LifecycleAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
fn step_end<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_ctx: &'life1 ReadOnlyContext<'life2>,
) -> Pin<Box<dyn Future<Output = ActionSet<LifecycleAction>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Auto Trait Implementations§
impl !Freeze for LLMMetryPlugin
impl !RefUnwindSafe for LLMMetryPlugin
impl Send for LLMMetryPlugin
impl Sync for LLMMetryPlugin
impl Unpin for LLMMetryPlugin
impl !UnwindSafe for LLMMetryPlugin
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
Mutably borrows from an owned value. Read more