AspireOllamaChatClientExtensions Methods
Class Methods 6 members
Extension methos for configuring the
AI.IChatClient from an OllamaApiClient AddChatClient(AspireOllamaApiClientBuilder) Section titled AddChatClient(AspireOllamaApiClientBuilder) extension ChatClientBuilder Registers a singleton
AI.IChatClient in the services provided by the builder. public static class AspireOllamaChatClientExtensions{ public static ChatClientBuilder AddChatClient( this AspireOllamaApiClientBuilder builder) { // ... }}Parameters
Returns
ChatClientBuilder A AI.ChatClientBuilder that can be used to build a pipeline around the inner AI.IChatClient. AddChatClient(AspireOllamaApiClientBuilder, Action<OpenTelemetryChatClient>) Section titled AddChatClient(AspireOllamaApiClientBuilder, Action<OpenTelemetryChatClient>) extension ChatClientBuilder Registers a singleton
AI.IChatClient in the services provided by the builder. public static class AspireOllamaChatClientExtensions{ public static ChatClientBuilder AddChatClient( this AspireOllamaApiClientBuilder builder, Action<OpenTelemetryChatClient>? configureOpenTelemetry) { // ... }}Parameters
configureOpenTelemetry Action<OpenTelemetryChatClient> An optional delegate that can be used for customizing the OpenTelemetry chat client. Returns
ChatClientBuilder A AI.ChatClientBuilder that can be used to build a pipeline around the inner AI.IChatClient. AddKeyedChatClient(AspireOllamaApiClientBuilder) Section titled AddKeyedChatClient(AspireOllamaApiClientBuilder) extension ChatClientBuilder Registers a keyed singleton
AI.IChatClient in the services provided by the builder. public static class AspireOllamaChatClientExtensions{ public static ChatClientBuilder AddKeyedChatClient( this AspireOllamaApiClientBuilder builder) { // ... }}Parameters
Returns
ChatClientBuilder A AI.ChatClientBuilder that can be used to build a pipeline around the inner AI.IChatClient. AddKeyedChatClient(AspireOllamaApiClientBuilder, Action<OpenTelemetryChatClient>) Section titled AddKeyedChatClient(AspireOllamaApiClientBuilder, Action<OpenTelemetryChatClient>) extension ChatClientBuilder Registers a keyed singleton
AI.IChatClient in the services provided by the builder. public static class AspireOllamaChatClientExtensions{ public static ChatClientBuilder AddKeyedChatClient( this AspireOllamaApiClientBuilder builder, Action<OpenTelemetryChatClient>? configureOpenTelemetry) { // ... }}Parameters
configureOpenTelemetry Action<OpenTelemetryChatClient> An optional delegate that can be used for customizing the OpenTelemetry chat client. Returns
ChatClientBuilder A AI.ChatClientBuilder that can be used to build a pipeline around the inner AI.IChatClient. AddKeyedChatClient(AspireOllamaApiClientBuilder, object) Section titled AddKeyedChatClient(AspireOllamaApiClientBuilder, object) extension ChatClientBuilder Registers a keyed singleton
AI.IChatClient in the services provided by the builder using the specified service key. public static class AspireOllamaChatClientExtensions{ public static ChatClientBuilder AddKeyedChatClient( this AspireOllamaApiClientBuilder builder, object serviceKey) { // ... }}Parameters
serviceKey object The service key to use for registering the AI.IChatClient. Returns
ChatClientBuilder A AI.ChatClientBuilder that can be used to build a pipeline around the inner AI.IChatClient. AddKeyedChatClient(AspireOllamaApiClientBuilder, object, Action<OpenTelemetryChatClient>) Section titled AddKeyedChatClient(AspireOllamaApiClientBuilder, object, Action<OpenTelemetryChatClient>) extension ChatClientBuilder Registers a keyed singleton
AI.IChatClient in the services provided by the builder using the specified service key. public static class AspireOllamaChatClientExtensions{ public static ChatClientBuilder AddKeyedChatClient( this AspireOllamaApiClientBuilder builder, object serviceKey, Action<OpenTelemetryChatClient>? configureOpenTelemetry) { // ... }}Parameters
serviceKey object The service key to use for registering the AI.IChatClient. configureOpenTelemetry Action<OpenTelemetryChatClient> An optional delegate that can be used for customizing the OpenTelemetry chat client. Returns
ChatClientBuilder A AI.ChatClientBuilder that can be used to build a pipeline around the inner AI.IChatClient.