Share via


GoogleAIGeminiChatCompletionService Constructor

Definition

Initializes a new instance of the GoogleAIGeminiChatCompletionService class.

public GoogleAIGeminiChatCompletionService (string modelId, string apiKey, Microsoft.SemanticKernel.Connectors.Google.GoogleAIVersion apiVersion = Microsoft.SemanticKernel.Connectors.Google.GoogleAIVersion.V1_Beta, System.Net.Http.HttpClient? httpClient = default, Microsoft.Extensions.Logging.ILoggerFactory? loggerFactory = default);
new Microsoft.SemanticKernel.Connectors.Google.GoogleAIGeminiChatCompletionService : string * string * Microsoft.SemanticKernel.Connectors.Google.GoogleAIVersion * System.Net.Http.HttpClient * Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.SemanticKernel.Connectors.Google.GoogleAIGeminiChatCompletionService
Public Sub New (modelId As String, apiKey As String, Optional apiVersion As GoogleAIVersion = Microsoft.SemanticKernel.Connectors.Google.GoogleAIVersion.V1_Beta, Optional httpClient As HttpClient = Nothing, Optional loggerFactory As ILoggerFactory = Nothing)

Parameters

modelId
String

The Gemini model for the chat completion service.

apiKey
String

The API key for authentication.

apiVersion
GoogleAIVersion

Version of the Google API

httpClient
HttpClient

Optional HTTP client to be used for communication with the Gemini API.

loggerFactory
ILoggerFactory

Optional logger factory to be used for logging.

Applies to