GeminiPromptExecutionSettings.FromExecutionSettings Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Converts a PromptExecutionSettings object to a GeminiPromptExecutionSettings object.
public static Microsoft.SemanticKernel.Connectors.Google.GeminiPromptExecutionSettings FromExecutionSettings (Microsoft.SemanticKernel.PromptExecutionSettings? executionSettings);
static member FromExecutionSettings : Microsoft.SemanticKernel.PromptExecutionSettings -> Microsoft.SemanticKernel.Connectors.Google.GeminiPromptExecutionSettings
Public Shared Function FromExecutionSettings (executionSettings As PromptExecutionSettings) As GeminiPromptExecutionSettings
Parameters
- executionSettings
- PromptExecutionSettings
The PromptExecutionSettings object to convert.
Returns
The converted GeminiPromptExecutionSettings object. If executionSettings
is null,
a new instance of GeminiPromptExecutionSettings is returned. If executionSettings
is already a GeminiPromptExecutionSettings object, it is casted and returned. Otherwise, the method
tries to deserialize executionSettings
to a GeminiPromptExecutionSettings object.
If deserialization is successful, the converted object is returned. If deserialization fails or the converted object
is null, an ArgumentException is thrown.