pub struct ASKit { /* private fields */ }Implementations§
Source§impl ASKit
impl ASKit
pub fn new() -> Self
pub fn init() -> Result<Self, AgentError>
pub async fn ready(&self) -> Result<(), AgentError>
pub fn quit(&self)
pub fn register_agent(&self, def: AgentDefinition)
pub fn get_agent_definitions(&self) -> AgentDefinitions
pub fn get_agent_definition(&self, def_name: &str) -> Option<AgentDefinition>
pub fn get_agent_default_config( &self, def_name: &str, ) -> Option<Vec<(String, AgentConfigEntry)>>
pub fn get_agent_flows(&self) -> AgentFlows
pub fn new_agent_flow(&self, name: &str) -> Result<AgentFlow, AgentError>
pub fn rename_agent_flow( &self, old_name: &str, new_name: &str, ) -> Result<String, AgentError>
pub fn unique_flow_name(&self, name: &str) -> String
pub fn add_agent_flow(&self, agent_flow: &AgentFlow) -> Result<(), AgentError>
pub async fn remove_agent_flow(&self, flow_name: &str) -> Result<(), AgentError>
pub fn insert_agent_flow(&self, flow: AgentFlow) -> Result<(), AgentError>
pub fn add_agent_flow_node( &self, flow_name: &str, node: &AgentFlowNode, ) -> Result<(), AgentError>
pub fn add_agent_flow_edge( &self, flow_name: &str, edge: &AgentFlowEdge, ) -> Result<(), AgentError>
pub async fn remove_agent_flow_node( &self, flow_name: &str, node_id: &str, ) -> Result<(), AgentError>
pub fn remove_agent_flow_edge( &self, flow_name: &str, edge_id: &str, ) -> Result<(), AgentError>
pub fn copy_sub_flow( &self, nodes: &Vec<AgentFlowNode>, edges: &Vec<AgentFlowEdge>, ) -> (Vec<AgentFlowNode>, Vec<AgentFlowEdge>)
pub async fn start_agent_flow(&self, name: &str) -> Result<(), AgentError>
pub async fn start_agent(&self, agent_id: &str) -> Result<(), AgentError>
pub async fn stop_agent(&self, agent_id: &str) -> Result<(), AgentError>
pub async fn set_agent_config( &self, agent_id: String, config: AgentConfig, ) -> Result<(), AgentError>
pub fn get_global_config(&self, def_name: &str) -> Option<AgentConfig>
pub fn set_global_config(&self, def_name: &str, config: AgentConfig)
pub async fn agent_input( &self, agent_id: String, ctx: AgentContext, data: AgentData, ) -> Result<(), AgentError>
pub async fn send_agent_out( &self, agent_id: String, ctx: AgentContext, data: AgentData, ) -> Result<(), AgentError>
pub fn try_send_agent_out( &self, agent_id: String, ctx: AgentContext, data: AgentData, ) -> Result<(), AgentError>
pub fn try_send_board_out( &self, name: String, ctx: AgentContext, data: AgentData, ) -> Result<(), AgentError>
pub fn subscribe(&self, observer: Box<dyn ASKitObserver + Sync + Send>) -> usize
pub fn unsubscribe(&self, observer_id: usize)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ASKit
impl RefUnwindSafe for ASKit
impl Send for ASKit
impl Sync for ASKit
impl Unpin for ASKit
impl UnwindSafe for ASKit
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