3 instantiations of LoggingChatClient
Microsoft.Extensions.AI (1)
ChatCompletion\LoggingChatClientBuilderExtensions.cs (1)
29
var chatClient = new
LoggingChatClient
(innerClient, logger);
Microsoft.Extensions.AI.Tests (2)
ChatCompletion\LoggingChatClientTests.cs (2)
19
Assert.Throws<ArgumentNullException>("innerClient", () => new
LoggingChatClient
(null!, NullLogger.Instance));
20
Assert.Throws<ArgumentNullException>("logger", () => new
LoggingChatClient
(new TestChatClient(), null!));
6 references to LoggingChatClient
Microsoft.Extensions.AI (6)
ChatCompletion\LoggingChatClient.cs (1)
28
/// <summary>Initializes a new instance of the <see cref="
LoggingChatClient
"/> class.</summary>
ChatCompletion\LoggingChatClientBuilderExtensions.cs (5)
11
/// <summary>Provides extensions for configuring <see cref="
LoggingChatClient
"/> instances.</summary>
19
/// <param name="configure">An optional callback that can be used to configure the <see cref="
LoggingChatClient
"/> instance.</param>
22
this ChatClientBuilder builder, ILogger? logger = null, Action<
LoggingChatClient
>? configure = null)
28
logger ??= services.GetRequiredService<ILoggerFactory>().CreateLogger(nameof(
LoggingChatClient
));
29
var
chatClient = new LoggingChatClient(innerClient, logger);