10 writes to ToolMode
Microsoft.Extensions.AI (2)
ChatCompletion\FunctionInvokingChatClient.cs (2)
280options.ToolMode = ChatToolMode.Auto; 396options.ToolMode = ChatToolMode.Auto;
Microsoft.Extensions.AI.Abstractions (1)
ChatCompletion\ChatOptions.cs (1)
83ToolMode = ToolMode,
Microsoft.Extensions.AI.Abstractions.Tests (2)
ChatCompletion\ChatOptionsTests.cs (2)
78options.ToolMode = ChatToolMode.RequireAny; 138options.ToolMode = ChatToolMode.RequireAny;
Microsoft.Extensions.AI.AzureAIInference.Tests (1)
AzureAIInferenceChatClientTests.cs (1)
769ToolMode = mode,
Microsoft.Extensions.AI.Integration.Tests (2)
ChatClientIntegrationTests.cs (2)
285ToolMode = ChatToolMode.RequireAny, 307ToolMode = ChatToolMode.RequireSpecific(shieldsUpTool.Metadata.Name),
Microsoft.Extensions.AI.OpenAI (2)
OpenAIModelMapper.ChatCompletion.cs (2)
213result.ToolMode = jsonElement.GetString() switch 223result.ToolMode = ChatToolMode.RequireSpecific(functionElement.GetString()!);
11 references to ToolMode
Microsoft.Extensions.AI (2)
ChatCompletion\FunctionInvokingChatClient.cs (2)
277case ContinueMode.Continue when options.ToolMode is RequiredChatToolMode: 393case ContinueMode.Continue when options.ToolMode is RequiredChatToolMode:
Microsoft.Extensions.AI.Abstractions (1)
ChatCompletion\ChatOptions.cs (1)
83ToolMode = ToolMode,
Microsoft.Extensions.AI.Abstractions.Tests (5)
ChatCompletion\ChatOptionsTests.cs (5)
26Assert.Same(ChatToolMode.Auto, options.ToolMode); 41Assert.Same(ChatToolMode.Auto, clone.ToolMode); 92Assert.Same(ChatToolMode.RequireAny, options.ToolMode); 107Assert.Same(ChatToolMode.RequireAny, clone.ToolMode); 162Assert.Equal(ChatToolMode.RequireAny, deserialized.ToolMode);
Microsoft.Extensions.AI.AzureAIInference (1)
AzureAIInferenceChatClient.cs (1)
349switch (options.ToolMode)
Microsoft.Extensions.AI.OpenAI (1)
OpenAIModelMapper.ChatCompletion.cs (1)
312switch (options.ToolMode)
Microsoft.Extensions.AI.OpenAI.Tests (1)
OpenAISerializationTests.cs (1)
336Assert.Equal(ChatToolMode.Auto, request.Options.ToolMode);