17 references to Text
Microsoft.Extensions.AI.Abstractions (3)
ChatCompletion\ChatOptions.cs (1)
38
/// This property can be set to <see cref="ChatResponseFormat.
Text
"/> to specify that the response should be unstructured text,
ChatCompletion\ChatResponseFormatText.cs (2)
10
/// Use <see cref="ChatResponseFormat.
Text
"/> to get an instance of <see cref="ChatResponseFormatText"/>.
16
/// <remarks> Use <see cref="ChatResponseFormat.
Text
"/> to get an instance of <see cref="ChatResponseFormatText"/>.</remarks>
Microsoft.Extensions.AI.Abstractions.Tests (14)
ChatCompletion\ChatResponseFormatTests.cs (14)
15
Assert.Same(ChatResponseFormat.
Text
, ChatResponseFormat.
Text
);
48
Assert.True(ChatResponseFormat.
Text
== ChatResponseFormat.
Text
);
49
Assert.True(ChatResponseFormat.
Text
.Equals(ChatResponseFormat.
Text
));
50
Assert.Equal(ChatResponseFormat.
Text
.GetHashCode(), ChatResponseFormat.
Text
.GetHashCode());
51
Assert.False(ChatResponseFormat.
Text
.Equals(ChatResponseFormat.Json));
52
Assert.False(ChatResponseFormat.
Text
.Equals(new ChatResponseFormatJson(null)));
53
Assert.False(ChatResponseFormat.
Text
.Equals(new ChatResponseFormatJson("{}")));
57
Assert.False(ChatResponseFormat.Json.Equals(ChatResponseFormat.
Text
));
83
string json = JsonSerializer.Serialize(ChatResponseFormat.
Text
, TestJsonSerializerContext.Default.ChatResponseFormat);
87
Assert.Equal(ChatResponseFormat.
Text
, result);