Method AddLMKitChatCompletion
- Namespace
- LMKit.Integrations.SemanticKernel
- Assembly
- LM-Kit.NET.Integrations.SemanticKernel.dll
AddLMKitChatCompletion(IKernelBuilder, LM, LMKitPromptExecutionSettings)
Adds the LMKit chat completion service to the kernel builder using the specified LM model. This method creates an instance of LMKitChatCompletion with the provided model and registers it.
public static void AddLMKitChatCompletion(this IKernelBuilder builder, LM model, LMKitPromptExecutionSettings defaultPromptExecutionSettings = null)
Parameters
builder
IKernelBuilderThe kernel builder to which the chat completion service is added.
model
LMThe LMKit model used for chat completion.
defaultPromptExecutionSettings
LMKitPromptExecutionSettingsAn optional instance of LMKitPromptExecutionSettings that provides default settings for text generation. If not provided, a new instance will be created using the specified model.
AddLMKitChatCompletion(IKernelBuilder, LMKitChatCompletion)
Adds the specified LMKit chat completion instance to the kernel builder. The instance is registered as a singleton service implementing Microsoft.SemanticKernel.ChatCompletion.IChatCompletionService.
public static void AddLMKitChatCompletion(this IKernelBuilder builder, LMKitChatCompletion chatCompletion)
Parameters
builder
IKernelBuilderThe kernel builder to which the chat completion service is added.
chatCompletion
LMKitChatCompletionAn instance of LMKitChatCompletion to register.