pub struct WebSearch {
searxng_url_base: String,
}Expand description
Execute a web search via SearXNG.
Fields§
§searxng_url_base: StringURL base to query the SearXNG instance
Implementations§
Trait Implementations§
Source§impl CallableTool for WebSearch
impl CallableTool for WebSearch
Source§async fn execute(
&self,
_agent: &Agent,
arguments: WebSearchParams,
) -> Result<WebSearchResults>
async fn execute( &self, _agent: &Agent, arguments: WebSearchParams, ) -> Result<WebSearchResults>
Execute a tool call.
Source§impl Tool for WebSearch
impl Tool for WebSearch
Source§fn description(&self) -> Option<String>
fn description(&self) -> Option<String>
Tool description, if any
Source§fn execute_unparsed<'a>(
&'a self,
agent: &'a Agent,
arguments: &'a str,
) -> Pin<Box<dyn Future<Output = Result<String>> + 'a>>
fn execute_unparsed<'a>( &'a self, agent: &'a Agent, arguments: &'a str, ) -> Pin<Box<dyn Future<Output = Result<String>> + 'a>>
Execute this tool, arguments given in JSON format (unparsed)
Source§impl ToolState for WebSearch
impl ToolState for WebSearch
Source§type ParamType = WebSearchParams
type ParamType = WebSearchParams
Associated parameter type.
Source§type ResultType = WebSearchResults
type ResultType = WebSearchResults
Associated return type.
Auto Trait Implementations§
impl Freeze for WebSearch
impl RefUnwindSafe for WebSearch
impl Send for WebSearch
impl Sync for WebSearch
impl Unpin for WebSearch
impl UnsafeUnpin for WebSearch
impl UnwindSafe for WebSearch
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