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)
704Arguments = new(callContent.Arguments) { Services = FunctionInvocationServices },
ChatCompletion\OpenTelemetryChatClient.cs (1)
534JsonSerializer.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)
494JsonSerializer.Serialize(callRequest.Arguments, AIJsonUtilities.DefaultOptions.GetTypeInfo(typeof(IDictionary<string, object>))))));
Microsoft.Extensions.AI.AzureAIInference.Tests (2)
AzureAIInferenceChatClientTests.cs (2)
1269AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments); 1361AssertExtensions.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)
175fc.Arguments, options.GetTypeInfo(typeof(IDictionary<string, object?>))))));
OpenAIResponseChatClient.cs (1)
487callContent.Arguments,
Microsoft.Extensions.AI.OpenAI.Tests (2)
OpenAIChatClientTests.cs (2)
1112AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments); 1292AssertExtensions.EqualFunctionCallParameters(new Dictionary<string, object?> { ["personName"] = "Alice" }, fcc.Arguments);
Microsoft.Extensions.AI.Tests (10)
ChatCompletion\DistributedCachingChatClientTest.cs (4)
757JsonSerializer.Serialize(expectedFcc.Arguments, TestJsonSerializerContext.Default.Options), 758JsonSerializer.Serialize(actualFcc.Arguments, TestJsonSerializerContext.Default.Options)); 791JsonSerializer.Serialize(expectedFcc.Arguments, TestJsonSerializerContext.Default.Options), 792JsonSerializer.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"])), 995AssertExtensions.EqualFunctionCallParameters(expectedFunctionCall.Arguments, chatFunctionCall.Arguments); 1089AssertExtensions.EqualFunctionCallParameters(expectedFunctionCall.Arguments, chatFunctionCall.Arguments);