openai/openai-dotnet

Public

mirrored from https://github.com/openai/openai-dotnetAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
OpenAI_2.0.0-beta.12

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

src/Custom/Images/GeneratedImageFormat.cs

37lines · modecode

1namespace OpenAI.Images;
2
3// CUSTOM:
4// - Renamed enum and its members.
5// - Converted extensible enum into an enum.
6// - Edited doc comment.
7/// <summary>
8/// Represents the available output methods for generated images.
9/// <list type="bullet">
10/// <item>
11/// <c>url</c> - <see cref="GeneratedImageFormat.Uri"/> - Default, provides a temporary internet location that
12/// the generated image can be retrieved from.
13/// </item>
14/// <item>
15/// <c>b64_json</c> - <see cref="GeneratedImageFormat.Bytes"/> - Provides the full image data on the response,
16/// encoded in the result as a base64 string. This offers the fastest round trip time but can drastically
17/// increase the size of response payloads.
18/// </item>
19/// </list>
20/// </summary>
21[CodeGenModel("CreateImageRequestResponseFormat")]
22public enum GeneratedImageFormat
23{
24 /// <summary>
25 /// Instructs the request to return image data directly on the response, encoded as a base64 string in the response
26 /// JSON. This minimizes availability time but drastically increases the size of responses, required bandwidth, and
27 /// immediate memory needs. This is equivalent to <c>b64_json</c> in the REST API.
28 /// </summary>
29 [CodeGenMember("B64Json")]
30 Bytes,
31 /// <summary>
32 /// The default setting that instructs the request to return a temporary internet location from which the image can
33 /// be retrieved.
34 /// </summary>
35 [CodeGenMember("Url")]
36 Uri,
37}