8 references to AsChatClient
Aspire.OpenAI (1)
AspireOpenAIClientBuilderChatClientExtensions.cs (1)
57var result = openAiClient.AsChatClient(deploymentName);
Microsoft.Extensions.AI.OpenAI.Tests (7)
OpenAIChatClientIntegrationTests.cs (1)
12?.AsChatClient(Environment.GetEnvironmentVariable("OPENAI_CHAT_MODEL") ?? "gpt-4o-mini");
OpenAIChatClientTests.cs (6)
54Assert.Throws<ArgumentNullException>("openAIClient", () => ((OpenAIClient)null!).AsChatClient("model")); 58Assert.Throws<ArgumentNullException>("modelId", () => client.AsChatClient(null!)); 59Assert.Throws<ArgumentException>("modelId", () => client.AsChatClient(" ")); 74IChatClient chatClient = client.AsChatClient(model); 89IChatClient chatClient = openAIClient.AsChatClient("model"); 927.AsChatClient(modelId);