次の方法で共有


HuggingFaceTextGenerationService Constructors

Definition

Overloads

HuggingFaceTextGenerationService(Uri, String, HttpClient, ILoggerFactory)

Initializes a new instance of the HuggingFaceTextGenerationService class.

HuggingFaceTextGenerationService(String, Uri, String, HttpClient, ILoggerFactory)

Initializes a new instance of the HuggingFaceTextGenerationService class.

HuggingFaceTextGenerationService(Uri, String, HttpClient, ILoggerFactory)

Initializes a new instance of the HuggingFaceTextGenerationService class.

public HuggingFaceTextGenerationService (Uri endpoint, string? apiKey = default, System.Net.Http.HttpClient? httpClient = default, Microsoft.Extensions.Logging.ILoggerFactory? loggerFactory = default);
new Microsoft.SemanticKernel.Connectors.HuggingFace.HuggingFaceTextGenerationService : Uri * string * System.Net.Http.HttpClient * Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.SemanticKernel.Connectors.HuggingFace.HuggingFaceTextGenerationService
Public Sub New (endpoint As Uri, Optional apiKey As String = Nothing, Optional httpClient As HttpClient = Nothing, Optional loggerFactory As ILoggerFactory = Nothing)

Parameters

endpoint
Uri

The uri endpoint including the port where HuggingFace server is hosted

apiKey
String

Optional API key for accessing the HuggingFace service.

httpClient
HttpClient

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

loggerFactory
ILoggerFactory

Optional logger factory to be used for logging.

Applies to

HuggingFaceTextGenerationService(String, Uri, String, HttpClient, ILoggerFactory)

Initializes a new instance of the HuggingFaceTextGenerationService class.

public HuggingFaceTextGenerationService (string model, Uri? endpoint = default, string? apiKey = default, System.Net.Http.HttpClient? httpClient = default, Microsoft.Extensions.Logging.ILoggerFactory? loggerFactory = default);
new Microsoft.SemanticKernel.Connectors.HuggingFace.HuggingFaceTextGenerationService : string * Uri * string * System.Net.Http.HttpClient * Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.SemanticKernel.Connectors.HuggingFace.HuggingFaceTextGenerationService
Public Sub New (model As String, Optional endpoint As Uri = Nothing, Optional apiKey As String = Nothing, Optional httpClient As HttpClient = Nothing, Optional loggerFactory As ILoggerFactory = Nothing)

Parameters

model
String

The HuggingFace model for the text generation service.

endpoint
Uri

The uri endpoint including the port where HuggingFace server is hosted

apiKey
String

Optional API key for accessing the HuggingFace service.

httpClient
HttpClient

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

loggerFactory
ILoggerFactory

Optional logger factory to be used for logging.

Applies to