Struct Llm

Source
pub struct Llm {
    pub proc: Option<Arc<DaggerSessionProc>>,
    pub selection: Selection,
    pub graphql_client: DynGraphQLClient,
}

Fields§

§proc: Option<Arc<DaggerSessionProc>>§selection: Selection§graphql_client: DynGraphQLClient

Implementations§

Source§

impl Llm

Source

pub fn cache_volume(&self) -> CacheVolume

Retrieve a the current value in the LLM environment, of type CacheVolume

Source

pub fn container(&self) -> Container

Retrieve a the current value in the LLM environment, of type Container

Source

pub fn current_module(&self) -> CurrentModule

Retrieve a the current value in the LLM environment, of type CurrentModule

Source

pub async fn current_type(&self) -> Result<String, DaggerError>

returns the type of the current state

Source

pub fn directory(&self) -> Directory

Retrieve a the current value in the LLM environment, of type Directory

Source

pub fn enum_type_def(&self) -> EnumTypeDef

Retrieve a the current value in the LLM environment, of type EnumTypeDef

Source

pub fn enum_value_type_def(&self) -> EnumValueTypeDef

Retrieve a the current value in the LLM environment, of type EnumValueTypeDef

Source

pub fn error(&self) -> Error

Retrieve a the current value in the LLM environment, of type Error

Source

pub fn error_value(&self) -> ErrorValue

Retrieve a the current value in the LLM environment, of type ErrorValue

Source

pub fn field_type_def(&self) -> FieldTypeDef

Retrieve a the current value in the LLM environment, of type FieldTypeDef

Source

pub fn file(&self) -> File

Retrieve a the current value in the LLM environment, of type File

Source

pub fn function(&self) -> Function

Retrieve a the current value in the LLM environment, of type Function

Source

pub fn function_arg(&self) -> FunctionArg

Retrieve a the current value in the LLM environment, of type FunctionArg

Source

pub fn function_call(&self) -> FunctionCall

Retrieve a the current value in the LLM environment, of type FunctionCall

Source

pub fn function_call_arg_value(&self) -> FunctionCallArgValue

Retrieve a the current value in the LLM environment, of type FunctionCallArgValue

Source

pub fn generated_code(&self) -> GeneratedCode

Retrieve a the current value in the LLM environment, of type GeneratedCode

Source

pub fn get_cache_volume(&self, name: impl Into<String>) -> CacheVolume

Retrieve a variable in the llm environment, of type CacheVolume

§Arguments
  • name - The name of the variable
Source

pub fn get_container(&self, name: impl Into<String>) -> Container

Retrieve a variable in the llm environment, of type Container

§Arguments
  • name - The name of the variable
Source

pub fn get_current_module(&self, name: impl Into<String>) -> CurrentModule

Retrieve a variable in the llm environment, of type CurrentModule

§Arguments
  • name - The name of the variable
Source

pub fn get_directory(&self, name: impl Into<String>) -> Directory

Retrieve a variable in the llm environment, of type Directory

§Arguments
  • name - The name of the variable
Source

pub fn get_enum_type_def(&self, name: impl Into<String>) -> EnumTypeDef

Retrieve a variable in the llm environment, of type EnumTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_enum_value_type_def( &self, name: impl Into<String>, ) -> EnumValueTypeDef

Retrieve a variable in the llm environment, of type EnumValueTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_error(&self, name: impl Into<String>) -> Error

Retrieve a variable in the llm environment, of type Error

§Arguments
  • name - The name of the variable
Source

pub fn get_error_value(&self, name: impl Into<String>) -> ErrorValue

Retrieve a variable in the llm environment, of type ErrorValue

§Arguments
  • name - The name of the variable
Source

pub fn get_field_type_def(&self, name: impl Into<String>) -> FieldTypeDef

Retrieve a variable in the llm environment, of type FieldTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_file(&self, name: impl Into<String>) -> File

Retrieve a variable in the llm environment, of type File

§Arguments
  • name - The name of the variable
Source

pub fn get_function(&self, name: impl Into<String>) -> Function

Retrieve a variable in the llm environment, of type Function

§Arguments
  • name - The name of the variable
Source

pub fn get_function_arg(&self, name: impl Into<String>) -> FunctionArg

Retrieve a variable in the llm environment, of type FunctionArg

§Arguments
  • name - The name of the variable
Source

pub fn get_function_call(&self, name: impl Into<String>) -> FunctionCall

Retrieve a variable in the llm environment, of type FunctionCall

§Arguments
  • name - The name of the variable
Source

pub fn get_function_call_arg_value( &self, name: impl Into<String>, ) -> FunctionCallArgValue

Retrieve a variable in the llm environment, of type FunctionCallArgValue

§Arguments
  • name - The name of the variable
Source

pub fn get_generated_code(&self, name: impl Into<String>) -> GeneratedCode

Retrieve a variable in the llm environment, of type GeneratedCode

§Arguments
  • name - The name of the variable
Source

pub fn get_git_ref(&self, name: impl Into<String>) -> GitRef

Retrieve a variable in the llm environment, of type GitRef

§Arguments
  • name - The name of the variable
Source

pub fn get_git_repository(&self, name: impl Into<String>) -> GitRepository

Retrieve a variable in the llm environment, of type GitRepository

§Arguments
  • name - The name of the variable
Source

pub fn get_input_type_def(&self, name: impl Into<String>) -> InputTypeDef

Retrieve a variable in the llm environment, of type InputTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_interface_type_def( &self, name: impl Into<String>, ) -> InterfaceTypeDef

Retrieve a variable in the llm environment, of type InterfaceTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_llm(&self, name: impl Into<String>) -> Llm

Retrieve a variable in the llm environment, of type LLM

§Arguments
  • name - The name of the variable
Source

pub fn get_list_type_def(&self, name: impl Into<String>) -> ListTypeDef

Retrieve a variable in the llm environment, of type ListTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_module(&self, name: impl Into<String>) -> Module

Retrieve a variable in the llm environment, of type Module

§Arguments
  • name - The name of the variable
Source

pub fn get_module_config_client( &self, name: impl Into<String>, ) -> ModuleConfigClient

Retrieve a variable in the llm environment, of type ModuleConfigClient

§Arguments
  • name - The name of the variable
Source

pub fn get_module_source(&self, name: impl Into<String>) -> ModuleSource

Retrieve a variable in the llm environment, of type ModuleSource

§Arguments
  • name - The name of the variable
Source

pub fn get_object_type_def(&self, name: impl Into<String>) -> ObjectTypeDef

Retrieve a variable in the llm environment, of type ObjectTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_sdk_config(&self, name: impl Into<String>) -> SdkConfig

Retrieve a variable in the llm environment, of type SDKConfig

§Arguments
  • name - The name of the variable
Source

pub fn get_scalar_type_def(&self, name: impl Into<String>) -> ScalarTypeDef

Retrieve a variable in the llm environment, of type ScalarTypeDef

§Arguments
  • name - The name of the variable
Source

pub fn get_secret(&self, name: impl Into<String>) -> Secret

Retrieve a variable in the llm environment, of type Secret

§Arguments
  • name - The name of the variable
Source

pub fn get_service(&self, name: impl Into<String>) -> Service

Retrieve a variable in the llm environment, of type Service

§Arguments
  • name - The name of the variable
Source

pub fn get_socket(&self, name: impl Into<String>) -> Socket

Retrieve a variable in the llm environment, of type Socket

§Arguments
  • name - The name of the variable
Source

pub fn get_source_map(&self, name: impl Into<String>) -> SourceMap

Retrieve a variable in the llm environment, of type SourceMap

§Arguments
  • name - The name of the variable
Source

pub async fn get_string( &self, name: impl Into<String>, ) -> Result<String, DaggerError>

Get a string variable from the LLM’s environment

§Arguments
  • name - The variable name
Source

pub fn get_terminal(&self, name: impl Into<String>) -> Terminal

Retrieve a variable in the llm environment, of type Terminal

§Arguments
  • name - The name of the variable
Source

pub fn get_type_def(&self, name: impl Into<String>) -> TypeDef

Retrieve a variable in the llm environment, of type TypeDef

§Arguments
  • name - The name of the variable
Source

pub fn git_ref(&self) -> GitRef

Retrieve a the current value in the LLM environment, of type GitRef

Source

pub fn git_repository(&self) -> GitRepository

Retrieve a the current value in the LLM environment, of type GitRepository

Source

pub async fn history(&self) -> Result<Vec<String>, DaggerError>

return the llm message history

Source

pub async fn history_json(&self) -> Result<String, DaggerError>

return the raw llm message history as json

Source

pub async fn id(&self) -> Result<Llmid, DaggerError>

A unique identifier for this LLM.

Source

pub fn input_type_def(&self) -> InputTypeDef

Retrieve a the current value in the LLM environment, of type InputTypeDef

Source

pub fn interface_type_def(&self) -> InterfaceTypeDef

Retrieve a the current value in the LLM environment, of type InterfaceTypeDef

Source

pub fn l_lm(&self) -> Llm

Retrieve a the current value in the LLM environment, of type LLM

Source

pub async fn last_reply(&self) -> Result<String, DaggerError>

return the last llm reply from the history

Source

pub fn list_type_def(&self) -> ListTypeDef

Retrieve a the current value in the LLM environment, of type ListTypeDef

Source

pub fn loop(&self) -> Llm

synchronize LLM state

Source

pub async fn model(&self) -> Result<String, DaggerError>

return the model used by the llm

Source

pub fn module(&self) -> Module

Retrieve a the current value in the LLM environment, of type Module

Source

pub fn module_config_client(&self) -> ModuleConfigClient

Retrieve a the current value in the LLM environment, of type ModuleConfigClient

Source

pub fn module_source(&self) -> ModuleSource

Retrieve a the current value in the LLM environment, of type ModuleSource

Source

pub fn object_type_def(&self) -> ObjectTypeDef

Retrieve a the current value in the LLM environment, of type ObjectTypeDef

Source

pub async fn provider(&self) -> Result<String, DaggerError>

return the provider used by the llm

Source

pub fn scalar_type_def(&self) -> ScalarTypeDef

Retrieve a the current value in the LLM environment, of type ScalarTypeDef

Source

pub fn sdkconfig(&self) -> SdkConfig

Retrieve a the current value in the LLM environment, of type SDKConfig

Source

pub fn secret(&self) -> Secret

Retrieve a the current value in the LLM environment, of type Secret

Source

pub fn service(&self) -> Service

Retrieve a the current value in the LLM environment, of type Service

Source

pub fn set_cache_volume( &self, name: impl Into<String>, value: impl IntoID<CacheVolumeId>, ) -> Llm

Set a variable of type CacheVolume in the llm environment

§Arguments
  • name - The name of the variable
  • value - The CacheVolume value to assign to the variable
Source

pub fn set_container( &self, name: impl Into<String>, value: impl IntoID<ContainerId>, ) -> Llm

Set a variable of type Container in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Container value to assign to the variable
Source

pub fn set_current_module( &self, name: impl Into<String>, value: impl IntoID<CurrentModuleId>, ) -> Llm

Set a variable of type CurrentModule in the llm environment

§Arguments
  • name - The name of the variable
  • value - The CurrentModule value to assign to the variable
Source

pub fn set_directory( &self, name: impl Into<String>, value: impl IntoID<DirectoryId>, ) -> Llm

Set a variable of type Directory in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Directory value to assign to the variable
Source

pub fn set_enum_type_def( &self, name: impl Into<String>, value: impl IntoID<EnumTypeDefId>, ) -> Llm

Set a variable of type EnumTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The EnumTypeDef value to assign to the variable
Source

pub fn set_enum_value_type_def( &self, name: impl Into<String>, value: impl IntoID<EnumValueTypeDefId>, ) -> Llm

Set a variable of type EnumValueTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The EnumValueTypeDef value to assign to the variable
Source

pub fn set_error( &self, name: impl Into<String>, value: impl IntoID<ErrorId>, ) -> Llm

Set a variable of type Error in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Error value to assign to the variable
Source

pub fn set_error_value( &self, name: impl Into<String>, value: impl IntoID<ErrorValueId>, ) -> Llm

Set a variable of type ErrorValue in the llm environment

§Arguments
  • name - The name of the variable
  • value - The ErrorValue value to assign to the variable
Source

pub fn set_field_type_def( &self, name: impl Into<String>, value: impl IntoID<FieldTypeDefId>, ) -> Llm

Set a variable of type FieldTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The FieldTypeDef value to assign to the variable
Source

pub fn set_file( &self, name: impl Into<String>, value: impl IntoID<FileId>, ) -> Llm

Set a variable of type File in the llm environment

§Arguments
  • name - The name of the variable
  • value - The File value to assign to the variable
Source

pub fn set_function( &self, name: impl Into<String>, value: impl IntoID<FunctionId>, ) -> Llm

Set a variable of type Function in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Function value to assign to the variable
Source

pub fn set_function_arg( &self, name: impl Into<String>, value: impl IntoID<FunctionArgId>, ) -> Llm

Set a variable of type FunctionArg in the llm environment

§Arguments
  • name - The name of the variable
  • value - The FunctionArg value to assign to the variable
Source

pub fn set_function_call( &self, name: impl Into<String>, value: impl IntoID<FunctionCallId>, ) -> Llm

Set a variable of type FunctionCall in the llm environment

§Arguments
  • name - The name of the variable
  • value - The FunctionCall value to assign to the variable
Source

pub fn set_function_call_arg_value( &self, name: impl Into<String>, value: impl IntoID<FunctionCallArgValueId>, ) -> Llm

Set a variable of type FunctionCallArgValue in the llm environment

§Arguments
  • name - The name of the variable
  • value - The FunctionCallArgValue value to assign to the variable
Source

pub fn set_generated_code( &self, name: impl Into<String>, value: impl IntoID<GeneratedCodeId>, ) -> Llm

Set a variable of type GeneratedCode in the llm environment

§Arguments
  • name - The name of the variable
  • value - The GeneratedCode value to assign to the variable
Source

pub fn set_git_ref( &self, name: impl Into<String>, value: impl IntoID<GitRefId>, ) -> Llm

Set a variable of type GitRef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The GitRef value to assign to the variable
Source

pub fn set_git_repository( &self, name: impl Into<String>, value: impl IntoID<GitRepositoryId>, ) -> Llm

Set a variable of type GitRepository in the llm environment

§Arguments
  • name - The name of the variable
  • value - The GitRepository value to assign to the variable
Source

pub fn set_input_type_def( &self, name: impl Into<String>, value: impl IntoID<InputTypeDefId>, ) -> Llm

Set a variable of type InputTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The InputTypeDef value to assign to the variable
Source

pub fn set_interface_type_def( &self, name: impl Into<String>, value: impl IntoID<InterfaceTypeDefId>, ) -> Llm

Set a variable of type InterfaceTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The InterfaceTypeDef value to assign to the variable
Source

pub fn set_llm(&self, name: impl Into<String>, value: impl IntoID<Llmid>) -> Llm

Set a variable of type LLM in the llm environment

§Arguments
  • name - The name of the variable
  • value - The LLM value to assign to the variable
Source

pub fn set_list_type_def( &self, name: impl Into<String>, value: impl IntoID<ListTypeDefId>, ) -> Llm

Set a variable of type ListTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The ListTypeDef value to assign to the variable
Source

pub fn set_module( &self, name: impl Into<String>, value: impl IntoID<ModuleId>, ) -> Llm

Set a variable of type Module in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Module value to assign to the variable
Source

pub fn set_module_config_client( &self, name: impl Into<String>, value: impl IntoID<ModuleConfigClientId>, ) -> Llm

Set a variable of type ModuleConfigClient in the llm environment

§Arguments
  • name - The name of the variable
  • value - The ModuleConfigClient value to assign to the variable
Source

pub fn set_module_source( &self, name: impl Into<String>, value: impl IntoID<ModuleSourceId>, ) -> Llm

Set a variable of type ModuleSource in the llm environment

§Arguments
  • name - The name of the variable
  • value - The ModuleSource value to assign to the variable
Source

pub fn set_object_type_def( &self, name: impl Into<String>, value: impl IntoID<ObjectTypeDefId>, ) -> Llm

Set a variable of type ObjectTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The ObjectTypeDef value to assign to the variable
Source

pub fn set_sdk_config( &self, name: impl Into<String>, value: impl IntoID<SdkConfigId>, ) -> Llm

Set a variable of type SDKConfig in the llm environment

§Arguments
  • name - The name of the variable
  • value - The SDKConfig value to assign to the variable
Source

pub fn set_scalar_type_def( &self, name: impl Into<String>, value: impl IntoID<ScalarTypeDefId>, ) -> Llm

Set a variable of type ScalarTypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The ScalarTypeDef value to assign to the variable
Source

pub fn set_secret( &self, name: impl Into<String>, value: impl IntoID<SecretId>, ) -> Llm

Set a variable of type Secret in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Secret value to assign to the variable
Source

pub fn set_service( &self, name: impl Into<String>, value: impl IntoID<ServiceId>, ) -> Llm

Set a variable of type Service in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Service value to assign to the variable
Source

pub fn set_socket( &self, name: impl Into<String>, value: impl IntoID<SocketId>, ) -> Llm

Set a variable of type Socket in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Socket value to assign to the variable
Source

pub fn set_source_map( &self, name: impl Into<String>, value: impl IntoID<SourceMapId>, ) -> Llm

Set a variable of type SourceMap in the llm environment

§Arguments
  • name - The name of the variable
  • value - The SourceMap value to assign to the variable
Source

pub fn set_string( &self, name: impl Into<String>, value: impl Into<String>, ) -> Llm

Add a string variable to the LLM’s environment

§Arguments
  • name - The variable name
  • value - The variable value
Source

pub fn set_terminal( &self, name: impl Into<String>, value: impl IntoID<TerminalId>, ) -> Llm

Set a variable of type Terminal in the llm environment

§Arguments
  • name - The name of the variable
  • value - The Terminal value to assign to the variable
Source

pub fn set_type_def( &self, name: impl Into<String>, value: impl IntoID<TypeDefId>, ) -> Llm

Set a variable of type TypeDef in the llm environment

§Arguments
  • name - The name of the variable
  • value - The TypeDef value to assign to the variable
Source

pub fn socket(&self) -> Socket

Retrieve a the current value in the LLM environment, of type Socket

Source

pub fn source_map(&self) -> SourceMap

Retrieve a the current value in the LLM environment, of type SourceMap

Source

pub async fn sync(&self) -> Result<Llmid, DaggerError>

synchronize LLM state

Source

pub fn terminal(&self) -> Terminal

Retrieve a the current value in the LLM environment, of type Terminal

Source

pub async fn tools(&self) -> Result<String, DaggerError>

print documentation for available tools

Source

pub fn type_def(&self) -> TypeDef

Retrieve a the current value in the LLM environment, of type TypeDef

Source

pub fn variables(&self) -> Vec<LlmVariable>

list variables in the LLM environment

Source

pub fn with_cache_volume(&self, value: impl IntoID<CacheVolumeId>) -> Llm

Set a variable of type CacheVolume in the llm environment

§Arguments
  • value - The CacheVolume value to assign to the variable
Source

pub fn with_container(&self, value: impl IntoID<ContainerId>) -> Llm

Set a variable of type Container in the llm environment

§Arguments
  • value - The Container value to assign to the variable
Source

pub fn with_current_module(&self, value: impl IntoID<CurrentModuleId>) -> Llm

Set a variable of type CurrentModule in the llm environment

§Arguments
  • value - The CurrentModule value to assign to the variable
Source

pub fn with_directory(&self, value: impl IntoID<DirectoryId>) -> Llm

Set a variable of type Directory in the llm environment

§Arguments
  • value - The Directory value to assign to the variable
Source

pub fn with_enum_type_def(&self, value: impl IntoID<EnumTypeDefId>) -> Llm

Set a variable of type EnumTypeDef in the llm environment

§Arguments
  • value - The EnumTypeDef value to assign to the variable
Source

pub fn with_enum_value_type_def( &self, value: impl IntoID<EnumValueTypeDefId>, ) -> Llm

Set a variable of type EnumValueTypeDef in the llm environment

§Arguments
  • value - The EnumValueTypeDef value to assign to the variable
Source

pub fn with_error(&self, value: impl IntoID<ErrorId>) -> Llm

Set a variable of type Error in the llm environment

§Arguments
  • value - The Error value to assign to the variable
Source

pub fn with_error_value(&self, value: impl IntoID<ErrorValueId>) -> Llm

Set a variable of type ErrorValue in the llm environment

§Arguments
  • value - The ErrorValue value to assign to the variable
Source

pub fn with_field_type_def(&self, value: impl IntoID<FieldTypeDefId>) -> Llm

Set a variable of type FieldTypeDef in the llm environment

§Arguments
  • value - The FieldTypeDef value to assign to the variable
Source

pub fn with_file(&self, value: impl IntoID<FileId>) -> Llm

Set a variable of type File in the llm environment

§Arguments
  • value - The File value to assign to the variable
Source

pub fn with_function(&self, value: impl IntoID<FunctionId>) -> Llm

Set a variable of type Function in the llm environment

§Arguments
  • value - The Function value to assign to the variable
Source

pub fn with_function_arg(&self, value: impl IntoID<FunctionArgId>) -> Llm

Set a variable of type FunctionArg in the llm environment

§Arguments
  • value - The FunctionArg value to assign to the variable
Source

pub fn with_function_call(&self, value: impl IntoID<FunctionCallId>) -> Llm

Set a variable of type FunctionCall in the llm environment

§Arguments
  • value - The FunctionCall value to assign to the variable
Source

pub fn with_function_call_arg_value( &self, value: impl IntoID<FunctionCallArgValueId>, ) -> Llm

Set a variable of type FunctionCallArgValue in the llm environment

§Arguments
  • value - The FunctionCallArgValue value to assign to the variable
Source

pub fn with_generated_code(&self, value: impl IntoID<GeneratedCodeId>) -> Llm

Set a variable of type GeneratedCode in the llm environment

§Arguments
  • value - The GeneratedCode value to assign to the variable
Source

pub fn with_git_ref(&self, value: impl IntoID<GitRefId>) -> Llm

Set a variable of type GitRef in the llm environment

§Arguments
  • value - The GitRef value to assign to the variable
Source

pub fn with_git_repository(&self, value: impl IntoID<GitRepositoryId>) -> Llm

Set a variable of type GitRepository in the llm environment

§Arguments
  • value - The GitRepository value to assign to the variable
Source

pub fn with_input_type_def(&self, value: impl IntoID<InputTypeDefId>) -> Llm

Set a variable of type InputTypeDef in the llm environment

§Arguments
  • value - The InputTypeDef value to assign to the variable
Source

pub fn with_interface_type_def( &self, value: impl IntoID<InterfaceTypeDefId>, ) -> Llm

Set a variable of type InterfaceTypeDef in the llm environment

§Arguments
  • value - The InterfaceTypeDef value to assign to the variable
Source

pub fn with_llm(&self, value: impl IntoID<Llmid>) -> Llm

Set a variable of type LLM in the llm environment

§Arguments
  • value - The LLM value to assign to the variable
Source

pub fn with_list_type_def(&self, value: impl IntoID<ListTypeDefId>) -> Llm

Set a variable of type ListTypeDef in the llm environment

§Arguments
  • value - The ListTypeDef value to assign to the variable
Source

pub fn with_model(&self, model: impl Into<String>) -> Llm

swap out the llm model

§Arguments
  • model - The model to use
Source

pub fn with_module(&self, value: impl IntoID<ModuleId>) -> Llm

Set a variable of type Module in the llm environment

§Arguments
  • value - The Module value to assign to the variable
Source

pub fn with_module_config_client( &self, value: impl IntoID<ModuleConfigClientId>, ) -> Llm

Set a variable of type ModuleConfigClient in the llm environment

§Arguments
  • value - The ModuleConfigClient value to assign to the variable
Source

pub fn with_module_source(&self, value: impl IntoID<ModuleSourceId>) -> Llm

Set a variable of type ModuleSource in the llm environment

§Arguments
  • value - The ModuleSource value to assign to the variable
Source

pub fn with_object_type_def(&self, value: impl IntoID<ObjectTypeDefId>) -> Llm

Set a variable of type ObjectTypeDef in the llm environment

§Arguments
  • value - The ObjectTypeDef value to assign to the variable
Source

pub fn with_prompt(&self, prompt: impl Into<String>) -> Llm

append a prompt to the llm context

§Arguments
  • prompt - The prompt to send
Source

pub fn with_prompt_file(&self, file: impl IntoID<FileId>) -> Llm

append the contents of a file to the llm context

§Arguments
  • file - The file to read the prompt from
Source

pub fn with_prompt_var( &self, name: impl Into<String>, value: impl Into<String>, ) -> Llm

Add a string variable to the LLM’s environment

§Arguments
  • name - The variable name
  • value - The variable value
Source

pub fn with_query(&self) -> Llm

Provide the entire Query object to the LLM

Source

pub fn with_sdk_config(&self, value: impl IntoID<SdkConfigId>) -> Llm

Set a variable of type SDKConfig in the llm environment

§Arguments
  • value - The SDKConfig value to assign to the variable
Source

pub fn with_scalar_type_def(&self, value: impl IntoID<ScalarTypeDefId>) -> Llm

Set a variable of type ScalarTypeDef in the llm environment

§Arguments
  • value - The ScalarTypeDef value to assign to the variable
Source

pub fn with_secret(&self, value: impl IntoID<SecretId>) -> Llm

Set a variable of type Secret in the llm environment

§Arguments
  • value - The Secret value to assign to the variable
Source

pub fn with_service(&self, value: impl IntoID<ServiceId>) -> Llm

Set a variable of type Service in the llm environment

§Arguments
  • value - The Service value to assign to the variable
Source

pub fn with_socket(&self, value: impl IntoID<SocketId>) -> Llm

Set a variable of type Socket in the llm environment

§Arguments
  • value - The Socket value to assign to the variable
Source

pub fn with_source_map(&self, value: impl IntoID<SourceMapId>) -> Llm

Set a variable of type SourceMap in the llm environment

§Arguments
  • value - The SourceMap value to assign to the variable
Source

pub fn with_terminal(&self, value: impl IntoID<TerminalId>) -> Llm

Set a variable of type Terminal in the llm environment

§Arguments
  • value - The Terminal value to assign to the variable
Source

pub fn with_type_def(&self, value: impl IntoID<TypeDefId>) -> Llm

Set a variable of type TypeDef in the llm environment

§Arguments
  • value - The TypeDef value to assign to the variable

Trait Implementations§

Source§

impl Clone for Llm

Source§

fn clone(&self) -> Llm

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl IntoID<Llmid> for Llm

Source§

fn into_id( self, ) -> Pin<Box<dyn Future<Output = Result<Llmid, DaggerError>> + Send>>

Auto Trait Implementations§

§

impl Freeze for Llm

§

impl !RefUnwindSafe for Llm

§

impl Send for Llm

§

impl Sync for Llm

§

impl Unpin for Llm

§

impl !UnwindSafe for Llm

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more