From f6a206c98231104f516be07d154946cbaa662f2b Mon Sep 17 00:00:00 2001 From: Genevieve Warren <24882762+gewarren@users.noreply.github.com> Date: Fri, 2 May 2025 15:20:34 -0700 Subject: [PATCH 1/3] add see also links to conceptual docs --- .../ChatCompletion/ChatOptions.cs | 3 ++ .../ChatCompletion/ChatResponse.cs | 1 + .../ChatCompletion/DelegatingChatClient.cs | 1 + .../ChatCompletion/IChatClient.cs | 3 ++ .../IEmbeddingGenerator{TInput,TEmbedding}.cs | 2 ++ .../ChatCompletion/ChatClientBuilder.cs | 8 +++-- .../ChatClientStructuredOutputExtensions.cs | 35 ++++++++----------- ...igureOptionsChatClientBuilderExtensions.cs | 1 + 8 files changed, 32 insertions(+), 22 deletions(-) diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs index 8b3bef838dd..25711cb7d90 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs @@ -7,6 +7,7 @@ namespace Microsoft.Extensions.AI; /// Represents the options for a chat request. +/// Provide options public class ChatOptions { /// Gets or sets an optional identifier used to associate a request with an existing conversation. @@ -20,6 +21,7 @@ public string? ChatThreadId } /// Gets or sets an optional identifier used to associate a request with an existing conversation. + /// Stateless vs. stateful clients public string? ConversationId { get; set; } /// Gets or sets the temperature for generating chat responses. @@ -115,6 +117,7 @@ public string? ChatThreadId public ChatToolMode? ToolMode { get; set; } /// Gets or sets the list of tools to include with a chat request. + /// Tool calling [JsonIgnore] public IList? Tools { get; set; } diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs index 92be7a5145c..24fba443f7e 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs @@ -92,6 +92,7 @@ public string? ChatThreadId /// or may not differ on every response, depending on whether the underlying provider uses a fixed ID for each conversation /// or updates it for each message. /// + /// Stateless vs. stateful clients public string? ConversationId { get; set; } /// Gets or sets the model ID used in the creation of the chat response. diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs index 23768dd8da7..f477132ba0b 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs @@ -16,6 +16,7 @@ namespace Microsoft.Extensions.AI; /// This is recommended as a base type when building clients that can be chained around an underlying . /// The default implementation simply passes each call to the inner client instance. /// +/// Custom IChatClient middleware public class DelegatingChatClient : IChatClient { /// diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs index bb0fe6a428c..0a8cc599c06 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs @@ -24,6 +24,7 @@ namespace Microsoft.Extensions.AI; /// /// /// Build an AI chat app with .NET. +/// The IChatClient interface public interface IChatClient : IDisposable { /// Sends chat messages and returns the response. @@ -32,6 +33,7 @@ public interface IChatClient : IDisposable /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// is . + /// Request a chat response Task GetResponseAsync( IEnumerable messages, ChatOptions? options = null, @@ -43,6 +45,7 @@ Task GetResponseAsync( /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// is . + /// Request a streaming chat response IAsyncEnumerable GetStreamingResponseAsync( IEnumerable messages, ChatOptions? options = null, diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs index ff3910ae737..d189f074ee3 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs @@ -24,6 +24,7 @@ namespace Microsoft.Extensions.AI; /// no instances are used which might employ such mutation. /// /// +/// The IEmbeddingGenerator interface public interface IEmbeddingGenerator : IEmbeddingGenerator where TEmbedding : Embedding { @@ -33,6 +34,7 @@ public interface IEmbeddingGenerator : IEmbeddingGenerato /// The to monitor for cancellation requests. The default is . /// The generated embeddings. /// is . + /// Create embeddings Task> GenerateAsync( IEnumerable values, EmbeddingGenerationOptions? options = null, diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs index bae7d58e4f9..c8ad1f97c2c 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs @@ -66,6 +66,7 @@ public IChatClient Build(IServiceProvider? services = null) /// The client factory function. /// The updated instance. /// is . + /// Pipelines of functionality public ChatClientBuilder Use(Func clientFactory) { _ = Throw.IfNull(clientFactory); @@ -77,6 +78,7 @@ public ChatClientBuilder Use(Func clientFactory) /// The client factory function. /// The updated instance. /// is . + /// Pipelines of functionality public ChatClientBuilder Use(Func clientFactory) { _ = Throw.IfNull(clientFactory); @@ -98,10 +100,11 @@ public ChatClientBuilder Use(Func cl /// /// The updated instance. /// - /// This overload may be used when the anonymous implementation needs to provide pre- and/or post-processing, but doesn't + /// This overload can be used when the anonymous implementation needs to provide pre-processing and/or post-processing, but doesn't /// need to interact with the results of the operation, which will come from the inner client. /// /// is . + /// Pipelines of functionality public ChatClientBuilder Use(Func, ChatOptions?, Func, ChatOptions?, CancellationToken, Task>, CancellationToken, Task> sharedFunc) { _ = Throw.IfNull(sharedFunc); @@ -125,7 +128,7 @@ public ChatClientBuilder Use(Func, ChatOptions?, Func /// The updated instance. /// - /// One or both delegates may be provided. If both are provided, they will be used for their respective methods: + /// One or both delegates can be provided. If both are provided, they will be used for their respective methods: /// will provide the implementation of , and /// will provide the implementation of . /// If only one of the delegates is provided, it will be used for both methods. That means that if @@ -135,6 +138,7 @@ public ChatClientBuilder Use(Func, ChatOptions?, Func will be implemented by combining the updates from . /// /// Both and are . + /// Pipelines of functionality public ChatClientBuilder Use( Func, ChatOptions?, IChatClient, CancellationToken, Task>? getResponseFunc, Func, ChatOptions?, IChatClient, CancellationToken, IAsyncEnumerable>? getStreamingResponseFunc) diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs index 90fe7ac1157..aa14ff2f766 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs @@ -18,6 +18,7 @@ namespace Microsoft.Extensions.AI; /// /// Provides extension methods on that simplify working with structured output. /// +/// Request a response with structured output public static class ChatClientStructuredOutputExtensions { private static readonly AIJsonSchemaCreateOptions _inferenceOptions = new() @@ -33,9 +34,8 @@ public static class ChatClientStructuredOutputExtensions /// The chat content to send. /// The chat options to configure the request. /// - /// Optionally specifies whether to set a JSON schema on the . - /// This improves reliability if the underlying model supports native structured output with a schema, but may cause an error if the model does not support it. - /// If not specified, the default value is . + /// to set a JSON schema on the ; otherwise, . The default is . + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -53,14 +53,15 @@ public static Task> GetResponseAsync( /// The text content for the chat message to send. /// The chat options to configure the request. /// - /// Optionally specifies whether to set a JSON schema on the . - /// This improves reliability if the underlying model supports native structured output with a schema, but may cause an error if the model does not support it. + /// to set a JSON schema on the ; otherwise, . + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. /// If not specified, the default value is determined by the implementation. /// If a specific value is required, it must be specified by the caller. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// The type of structured output to request. + /// Request a response with structured output public static Task> GetResponseAsync( this IChatClient chatClient, string chatMessage, @@ -74,9 +75,8 @@ public static Task> GetResponseAsync( /// The chat message to send. /// The chat options to configure the request. /// - /// Optionally specifies whether to set a JSON schema on the . - /// This improves reliability if the underlying model supports native structured output with a schema, but may cause an error if the model does not support it. - /// If not specified, the default value is . + /// to set a JSON schema on the ; otherwise, . The default is . + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -95,9 +95,8 @@ public static Task> GetResponseAsync( /// The JSON serialization options to use. /// The chat options to configure the request. /// - /// Optionally specifies whether to set a JSON schema on the . - /// This improves reliability if the underlying model supports native structured output with a schema, but may cause an error if the model does not support it. - /// If not specified, the default value is . + /// to set a JSON schema on the ; otherwise, . The default is . + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -117,9 +116,8 @@ public static Task> GetResponseAsync( /// The JSON serialization options to use. /// The chat options to configure the request. /// - /// Optionally specifies whether to set a JSON schema on the . - /// This improves reliability if the underlying model supports native structured output with a schema, but may cause an error if the model does not support it. - /// If not specified, the default value is . + /// to set a JSON schema on the ; otherwise, . The default is . + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -139,16 +137,13 @@ public static Task> GetResponseAsync( /// The JSON serialization options to use. /// The chat options to configure the request. /// - /// Optionally specifies whether to set a JSON schema on the . - /// This improves reliability if the underlying model supports native structured output with a schema, but may cause an error if the model does not support it. - /// If not specified, the default value is . + /// to set a JSON schema on the ; otherwise, . The default is . + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// The type of structured output to request. - /// is . - /// is . - /// is . + /// or or is . public static async Task> GetResponseAsync( this IChatClient chatClient, IEnumerable messages, diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs index d76b2ba1a2e..ef730c0587b 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs @@ -27,6 +27,7 @@ public static class ConfigureOptionsChatClientBuilderExtensions /// The . /// is . /// is . + /// Provide options public static ChatClientBuilder ConfigureOptions( this ChatClientBuilder builder, Action configure) { From d718d6501dc471a338515ad04c092d73905ca643 Mon Sep 17 00:00:00 2001 From: Genevieve Warren <24882762+gewarren@users.noreply.github.com> Date: Fri, 2 May 2025 15:31:16 -0700 Subject: [PATCH 2/3] can -> might --- .../ChatClientStructuredOutputExtensions.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs index aa14ff2f766..54052417a9b 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs @@ -35,7 +35,7 @@ public static class ChatClientStructuredOutputExtensions /// The chat options to configure the request. /// /// to set a JSON schema on the ; otherwise, . The default is . - /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but might cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -54,7 +54,7 @@ public static Task> GetResponseAsync( /// The chat options to configure the request. /// /// to set a JSON schema on the ; otherwise, . - /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but might cause an error if the model does not support it. /// If not specified, the default value is determined by the implementation. /// If a specific value is required, it must be specified by the caller. /// @@ -76,7 +76,7 @@ public static Task> GetResponseAsync( /// The chat options to configure the request. /// /// to set a JSON schema on the ; otherwise, . The default is . - /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but might cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -96,7 +96,7 @@ public static Task> GetResponseAsync( /// The chat options to configure the request. /// /// to set a JSON schema on the ; otherwise, . The default is . - /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but might cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -117,7 +117,7 @@ public static Task> GetResponseAsync( /// The chat options to configure the request. /// /// to set a JSON schema on the ; otherwise, . The default is . - /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but might cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. @@ -138,7 +138,7 @@ public static Task> GetResponseAsync( /// The chat options to configure the request. /// /// to set a JSON schema on the ; otherwise, . The default is . - /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but can cause an error if the model does not support it. + /// Using a JSON schema improves reliability if the underlying model supports native structured output with a schema, but might cause an error if the model does not support it. /// /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. From b5271c55edfd9ed5f10839991720f839d3e80d10 Mon Sep 17 00:00:00 2001 From: Genevieve Warren <24882762+gewarren@users.noreply.github.com> Date: Mon, 5 May 2025 09:26:14 -0700 Subject: [PATCH 3/3] add missing periods --- .../ChatCompletion/ChatOptions.cs | 6 +++--- .../ChatCompletion/ChatResponse.cs | 2 +- .../ChatCompletion/DelegatingChatClient.cs | 2 +- .../ChatCompletion/IChatClient.cs | 6 +++--- .../Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs | 4 ++-- .../ChatCompletion/ChatClientBuilder.cs | 8 ++++---- .../ChatClientStructuredOutputExtensions.cs | 4 ++-- .../ConfigureOptionsChatClientBuilderExtensions.cs | 2 +- 8 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs index 25711cb7d90..ac5fba99ae5 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatOptions.cs @@ -7,7 +7,7 @@ namespace Microsoft.Extensions.AI; /// Represents the options for a chat request. -/// Provide options +/// Provide options. public class ChatOptions { /// Gets or sets an optional identifier used to associate a request with an existing conversation. @@ -21,7 +21,7 @@ public string? ChatThreadId } /// Gets or sets an optional identifier used to associate a request with an existing conversation. - /// Stateless vs. stateful clients + /// Stateless vs. stateful clients. public string? ConversationId { get; set; } /// Gets or sets the temperature for generating chat responses. @@ -117,7 +117,7 @@ public string? ChatThreadId public ChatToolMode? ToolMode { get; set; } /// Gets or sets the list of tools to include with a chat request. - /// Tool calling + /// Tool calling. [JsonIgnore] public IList? Tools { get; set; } diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs index 24fba443f7e..5e0e80beac9 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/ChatResponse.cs @@ -92,7 +92,7 @@ public string? ChatThreadId /// or may not differ on every response, depending on whether the underlying provider uses a fixed ID for each conversation /// or updates it for each message. /// - /// Stateless vs. stateful clients + /// Stateless vs. stateful clients. public string? ConversationId { get; set; } /// Gets or sets the model ID used in the creation of the chat response. diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs index f477132ba0b..112e846d41f 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/DelegatingChatClient.cs @@ -16,7 +16,7 @@ namespace Microsoft.Extensions.AI; /// This is recommended as a base type when building clients that can be chained around an underlying . /// The default implementation simply passes each call to the inner client instance. /// -/// Custom IChatClient middleware +/// Custom IChatClient middleware. public class DelegatingChatClient : IChatClient { /// diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs index 0a8cc599c06..b4354e22a43 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/ChatCompletion/IChatClient.cs @@ -24,7 +24,7 @@ namespace Microsoft.Extensions.AI; /// /// /// Build an AI chat app with .NET. -/// The IChatClient interface +/// The IChatClient interface. public interface IChatClient : IDisposable { /// Sends chat messages and returns the response. @@ -33,7 +33,7 @@ public interface IChatClient : IDisposable /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// is . - /// Request a chat response + /// Request a chat response. Task GetResponseAsync( IEnumerable messages, ChatOptions? options = null, @@ -45,7 +45,7 @@ Task GetResponseAsync( /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// is . - /// Request a streaming chat response + /// Request a streaming chat response. IAsyncEnumerable GetStreamingResponseAsync( IEnumerable messages, ChatOptions? options = null, diff --git a/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs b/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs index d189f074ee3..ad6b9951642 100644 --- a/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs +++ b/src/Libraries/Microsoft.Extensions.AI.Abstractions/Embeddings/IEmbeddingGenerator{TInput,TEmbedding}.cs @@ -24,7 +24,7 @@ namespace Microsoft.Extensions.AI; /// no instances are used which might employ such mutation. /// /// -/// The IEmbeddingGenerator interface +/// The IEmbeddingGenerator interface. public interface IEmbeddingGenerator : IEmbeddingGenerator where TEmbedding : Embedding { @@ -34,7 +34,7 @@ public interface IEmbeddingGenerator : IEmbeddingGenerato /// The to monitor for cancellation requests. The default is . /// The generated embeddings. /// is . - /// Create embeddings + /// Create embeddings. Task> GenerateAsync( IEnumerable values, EmbeddingGenerationOptions? options = null, diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs index c8ad1f97c2c..c557ba524ff 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientBuilder.cs @@ -66,7 +66,7 @@ public IChatClient Build(IServiceProvider? services = null) /// The client factory function. /// The updated instance. /// is . - /// Pipelines of functionality + /// Pipelines of functionality. public ChatClientBuilder Use(Func clientFactory) { _ = Throw.IfNull(clientFactory); @@ -78,7 +78,7 @@ public ChatClientBuilder Use(Func clientFactory) /// The client factory function. /// The updated instance. /// is . - /// Pipelines of functionality + /// Pipelines of functionality. public ChatClientBuilder Use(Func clientFactory) { _ = Throw.IfNull(clientFactory); @@ -104,7 +104,7 @@ public ChatClientBuilder Use(Func cl /// need to interact with the results of the operation, which will come from the inner client. /// /// is . - /// Pipelines of functionality + /// Pipelines of functionality. public ChatClientBuilder Use(Func, ChatOptions?, Func, ChatOptions?, CancellationToken, Task>, CancellationToken, Task> sharedFunc) { _ = Throw.IfNull(sharedFunc); @@ -138,7 +138,7 @@ public ChatClientBuilder Use(Func, ChatOptions?, Func will be implemented by combining the updates from . /// /// Both and are . - /// Pipelines of functionality + /// Pipelines of functionality. public ChatClientBuilder Use( Func, ChatOptions?, IChatClient, CancellationToken, Task>? getResponseFunc, Func, ChatOptions?, IChatClient, CancellationToken, IAsyncEnumerable>? getStreamingResponseFunc) diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs index 54052417a9b..0e7b20bade6 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ChatClientStructuredOutputExtensions.cs @@ -18,7 +18,7 @@ namespace Microsoft.Extensions.AI; /// /// Provides extension methods on that simplify working with structured output. /// -/// Request a response with structured output +/// Request a response with structured output. public static class ChatClientStructuredOutputExtensions { private static readonly AIJsonSchemaCreateOptions _inferenceOptions = new() @@ -61,7 +61,7 @@ public static Task> GetResponseAsync( /// The to monitor for cancellation requests. The default is . /// The response messages generated by the client. /// The type of structured output to request. - /// Request a response with structured output + /// Request a response with structured output. public static Task> GetResponseAsync( this IChatClient chatClient, string chatMessage, diff --git a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs index ef730c0587b..5f9c2f988c0 100644 --- a/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs +++ b/src/Libraries/Microsoft.Extensions.AI/ChatCompletion/ConfigureOptionsChatClientBuilderExtensions.cs @@ -27,7 +27,7 @@ public static class ConfigureOptionsChatClientBuilderExtensions /// The . /// is . /// is . - /// Provide options + /// Provide options. public static ChatClientBuilder ConfigureOptions( this ChatClientBuilder builder, Action configure) {