Implemented interface members:
4 writes to
Microsoft.Extensions.AI.Abstractions (1)
UsageDetails.cs (1)
49
AdditionalCounts
[
kvp.Key] = AdditionalCounts.TryGetValue(kvp.Key, out var existingValue) ?
Microsoft.Extensions.AI.Abstractions.Tests (2)
AdditionalPropertiesDictionaryTests.cs (2)
76
d
[
"key"] = input;
88
d
[
"key"] = input;
Microsoft.Extensions.AI.OpenAI (1)
OpenAIModelMapper.ChatCompletion.cs (1)
350
additionalProperties
[
"Strict"] = strictValue;
33 references to
Microsoft.Extensions.AI.Abstractions.Tests (20)
AdditionalPropertiesDictionaryTests.cs (8)
39
Assert.Equal("value2", d
[
"key1"]);
40
Assert.Equal("value2", d
[
"kEY1"]);
42
Assert.Equal("value3", d
[
"key2"]);
43
Assert.Equal("value3", d
[
"KEY2"]);
45
Assert.Equal("value5", d
[
"Key3"]);
46
Assert.Equal("value5", d
[
"KEy3"]);
102
Assert.Equal("value", d
[
"key"]);
106
Assert.Equal("value", d
[
"key"]);
ChatCompletion\ChatMessageTests.cs (7)
307
Assert.Equal("message-metadata-value-1", deserializedMessage.AdditionalProperties
[
"message-metadata-key-1"]?.ToString());
317
Assert.Equal("metadata-value-1", textContent.AdditionalProperties
[
"metadata-key-1"]?.ToString());
325
Assert.Equal("metadata-value-2", imageContent.AdditionalProperties
[
"metadata-key-2"]?.ToString());
333
Assert.Equal("metadata-value-3", dataContent.AdditionalProperties
[
"metadata-key-3"]?.ToString());
341
Assert.Equal("metadata-value-4", audioContent.AdditionalProperties
[
"metadata-key-4"]?.ToString());
349
Assert.Equal("metadata-value-5", imageContent.AdditionalProperties
[
"metadata-key-5"]?.ToString());
356
Assert.Equal("metadata-value-6", textContent.AdditionalProperties
[
"metadata-key-6"]?.ToString());
ChatCompletion\StreamingChatCompletionUpdateExtensionsTests.cs (5)
76
Assert.Equal("b", message.AdditionalProperties
[
"a"]);
77
Assert.Equal("d", message.AdditionalProperties
[
"c"]);
84
Assert.Equal("h", message.AdditionalProperties
[
"g"]);
85
Assert.Equal("f", message.AdditionalProperties
[
"e"]);
86
Assert.Equal(42, message.AdditionalProperties
[
"i"]);
Microsoft.Extensions.AI.OpenAI.Tests (11)
OpenAIChatClientTests.cs (4)
211
Assert.Equal("fp_f85bea6784", response.AdditionalProperties
[
nameof(OpenAI.Chat.ChatCompletion.SystemFingerprint)]);
558
Assert.Equal("fp_f85bea6784", response.AdditionalProperties
[
nameof(OpenAI.Chat.ChatCompletion.SystemFingerprint)]);
657
Assert.Equal("fp_f85bea6784", response.AdditionalProperties
[
nameof(OpenAI.Chat.ChatCompletion.SystemFingerprint)]);
1028
Assert.Equal("fp_f85bea6784", response.AdditionalProperties
[
nameof(OpenAI.Chat.ChatCompletion.SystemFingerprint)]);
OpenAISerializationTests.cs (7)
142
Assert.Equal("user", request.Options.AdditionalProperties
[
"EndUserId"]);
143
Assert.True((bool)request.Options.AdditionalProperties
[
"IncludeLogProbabilities"]!);
144
Assert.Single((IDictionary<int, int>)request.Options.AdditionalProperties
[
"LogitBiases"]!);
145
Assert.True((bool)request.Options.AdditionalProperties
[
"AllowParallelToolCalls"]!);
146
Assert.Equal(42, request.Options.AdditionalProperties
[
"TopLogProbabilityCount"]!);
147
Assert.Single((IDictionary<string, string>)request.Options.AdditionalProperties
[
"Metadata"]!);
148
Assert.True((bool)request.Options.AdditionalProperties
[
"StoredOutputEnabled"]!);
Microsoft.Extensions.AI.Tests (2)
ChatCompletion\FunctionInvokingChatClientTests.cs (2)
631
Assert.Equal(expectedTotalTokenCounts, actualUsage.AdditionalCounts
[
"firstValue"]);
632
Assert.Equal(expectedTotalTokenCounts, actualUsage.AdditionalCounts
[
"secondValue"]);