2025-10-10 15:12:59 +00:00
|
|
|
using System.Text.Json.Serialization;
|
|
|
|
|
|
2024-07-01 18:11:19 +00:00
|
|
|
namespace AIStudio.Provider.Mistral;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// The OpenAI chat request model.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="Model">Which model to use for chat completion.</param>
|
|
|
|
|
/// <param name="Messages">The chat messages.</param>
|
|
|
|
|
/// <param name="Stream">Whether to stream the chat completion.</param>
|
|
|
|
|
/// <param name="RandomSeed">The seed for the chat completion.</param>
|
|
|
|
|
/// <param name="SafePrompt">Whether to inject a safety prompt before all conversations.</param>
|
|
|
|
|
public readonly record struct ChatRequest(
|
|
|
|
|
string Model,
|
|
|
|
|
IList<RegularMessage> Messages,
|
|
|
|
|
bool Stream,
|
|
|
|
|
int RandomSeed,
|
|
|
|
|
bool SafePrompt = false
|
2025-10-10 15:12:59 +00:00
|
|
|
)
|
|
|
|
|
{
|
2025-10-23 13:06:02 +00:00
|
|
|
[JsonExtensionData]
|
2025-11-13 16:20:44 +00:00
|
|
|
public required IDictionary<string, object> AdditionalApiParameters { get; init; }
|
2025-10-10 15:12:59 +00:00
|
|
|
}
|