2 writes to Arguments
Microsoft.Extensions.AI.Abstractions (1)
Contents\FunctionCallContent.cs (1)
30Arguments = arguments;
Microsoft.Extensions.AI.Abstractions.Tests (1)
Contents\FunctionCallContentTests..cs (1)
67c.Arguments = args;
37 references to Arguments
Microsoft.Extensions.AI (2)
ChatCompletion\FunctionInvokingChatClient.cs (1)
688Arguments = new(callContent.Arguments) { Services = _functionInvocationServices },
ChatCompletion\OpenTelemetryChatClient.cs (1)
529JsonSerializer.SerializeToNode(fc.Arguments, _jsonSerializerOptions.GetTypeInfo(typeof(IDictionary<string, object?>))) :
Microsoft.Extensions.AI.Abstractions (2)
Contents\FunctionCallContent.cs (2)
116display += Arguments is not null ? 117$"{Name}({string.Join(", ", Arguments)})" :
Microsoft.Extensions.AI.Abstractions.Tests (13)
ChatCompletion\ChatMessageTests.cs (3)
314Assert.NotNull(functionCallContent.Arguments); 315Assert.Single(functionCallContent.Arguments); 316Assert.Equal("argument", functionCallContent.Arguments["parameter"]?.ToString());
Contents\FunctionCallContentTests..cs (10)
29Assert.Null(c.Arguments); 45Assert.Same(args, c.Arguments); 65Assert.Null(c.Arguments); 68Assert.Same(args, c.Arguments); 91Assert.NotNull(deserializedSut.Arguments); 92Assert.Single(deserializedSut.Arguments); 269Assert.NotNull(content.Arguments); 270Assert.Equal(5, content.Arguments.Count); 271Assert.Collection(content.Arguments, 310Assert.Null(content.Arguments);
Microsoft.Extensions.AI.AzureAIInference (1)
AzureAIInferenceChatClient.cs (1)
475JsonSerializer.Serialize(callRequest.Arguments, AIJsonUtilities.DefaultOptions.GetTypeInfo(typeof(IDictionary<string, object>))))));
Microsoft.Extensions.AI.AzureAIInference.Tests (2)
AzureAIInferenceChatClientTests.cs (2)
796AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments); 888AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments);
Microsoft.Extensions.AI.Integration.Tests (1)
PromptBasedFunctionCallingChatClient.cs (1)
76var toolCallJson = JsonSerializer.Serialize(new { fcc.CallId, fcc.Name, fcc.Arguments }, _jsonOptions);
Microsoft.Extensions.AI.Ollama (1)
OllamaChatClient.cs (1)
452Arguments = JsonSerializer.SerializeToElement(fcc.Arguments, ToolCallJsonSerializerOptions.GetTypeInfo(typeof(IDictionary<string, object?>))),
Microsoft.Extensions.AI.Ollama.Tests (1)
OllamaChatClientTests.cs (1)
393AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments);
Microsoft.Extensions.AI.OpenAI (2)
OpenAIChatClient.cs (1)
165callRequest.Arguments,
OpenAIResponseChatClient.cs (1)
504callContent.Arguments,
Microsoft.Extensions.AI.OpenAI.Tests (2)
OpenAIChatClientTests.cs (2)
770AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments); 959AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments);
Microsoft.Extensions.AI.Tests (10)
ChatCompletion\DistributedCachingChatClientTest.cs (4)
751JsonSerializer.Serialize(expectedFcc.Arguments, TestJsonSerializerContext.Default.Options), 752JsonSerializer.Serialize(actualFcc.Arguments, TestJsonSerializerContext.Default.Options)); 785JsonSerializer.Serialize(expectedFcc.Arguments, TestJsonSerializerContext.Default.Options), 786JsonSerializer.Serialize(actualFcc.Arguments, TestJsonSerializerContext.Default.Options));
ChatCompletion\FunctionInvokingChatClientTests.cs (6)
622c => Assert.Equal("Input 1", Assert.IsType<FunctionCallContent>(c).Arguments!["text"]), 623c => Assert.Equal("Input 2", Assert.IsType<FunctionCallContent>(c).Arguments!["text"])), 997AssertExtensions.EqualFunctionCallParameters(expectedFunctionCall.Arguments, chatFunctionCall.Arguments); 1091AssertExtensions.EqualFunctionCallParameters(expectedFunctionCall.Arguments, chatFunctionCall.Arguments);