pub struct TellUserTool;Expand description
Tool for displaying messages to the user without expecting a response
This tool allows the LLM to send important intermediate information to the user as it works on completing their request. It’s useful for providing status updates, progress information, or other important messages during long-running operations.
§Examples
use mojentic::llm::tools::tell_user_tool::TellUserTool;
use mojentic::llm::tools::LlmTool;
use std::collections::HashMap;
use serde_json::json;
let tool = TellUserTool;
let mut args = HashMap::new();
args.insert("message".to_string(), json!("Processing your request..."));
let result = tool.run(&args).unwrap();
// Prints to stdout:
//
//
//
// MESSAGE FROM ASSISTANT:
// Processing your request...
//
// Returns: "Message delivered to user."Implementations§
Source§impl TellUserTool
impl TellUserTool
Trait Implementations§
Source§impl Clone for TellUserTool
impl Clone for TellUserTool
Source§fn clone(&self) -> TellUserTool
fn clone(&self) -> TellUserTool
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for TellUserTool
impl Default for TellUserTool
Auto Trait Implementations§
impl Freeze for TellUserTool
impl RefUnwindSafe for TellUserTool
impl Send for TellUserTool
impl Sync for TellUserTool
impl Unpin for TellUserTool
impl UnwindSafe for TellUserTool
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