parameter

Function parameter 

Source
pub fn parameter<S: Into<String>>(
    name: S,
    type_: ParameterType,
) -> ParameterBuilder
Expand description

Creates a new ParameterBuilder with the specified name and type.

This is a convenience function that returns a ParameterBuilder instance initialized with the given name and type. You can then chain additional methods to configure the parameter before adding it to a tool.

ยงExample

use ic_llm::ParameterType;

// Basic usage
let location_param = ic_llm::parameter("location", ParameterType::String)
    .with_description("The location to get weather for")
    .is_required();