Class: OpenAI::Models::ImagesResponse
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::ImagesResponse
- Defined in:
- lib/openai/models/images_response.rb
Overview
Defined Under Namespace
Modules: Background, OutputFormat, Quality, Size Classes: Usage
Instance Attribute Summary collapse
-
#background ⇒ Symbol, ...
The background parameter used for the image generation.
-
#created ⇒ Integer
The Unix timestamp (in seconds) of when the image was created.
-
#data ⇒ Array<OpenAI::Models::Image>?
The list of generated images.
-
#output_format ⇒ Symbol, ...
The output format of the image generation.
-
#quality ⇒ Symbol, ...
The quality of the image generated.
-
#size ⇒ Symbol, ...
The size of the image generated.
-
#usage ⇒ OpenAI::Models::ImagesResponse::Usage?
For
gpt-image-1
only, the token usage information for the image generation.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(created: , background: nil, data: nil, output_format: nil, quality: nil, size: nil, usage: nil) ⇒ void
constructor
Some parameter documentations has been truncated, see ImagesResponse for more details.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(created: , background: nil, data: nil, output_format: nil, quality: nil, size: nil, usage: nil) ⇒ void
Some parameter documentations has been truncated, see OpenAI::Models::ImagesResponse for more details.
The response from the image generation endpoint.
|
# File 'lib/openai/models/images_response.rb', line 51
|
Instance Attribute Details
#background ⇒ Symbol, ...
The background parameter used for the image generation. Either transparent
or
opaque
.
18 |
# File 'lib/openai/models/images_response.rb', line 18 optional :background, enum: -> { OpenAI::ImagesResponse::Background } |
#created ⇒ Integer
The Unix timestamp (in seconds) of when the image was created.
11 |
# File 'lib/openai/models/images_response.rb', line 11 required :created, Integer |
#data ⇒ Array<OpenAI::Models::Image>?
The list of generated images.
24 |
# File 'lib/openai/models/images_response.rb', line 24 optional :data, -> { OpenAI::Internal::Type::ArrayOf[OpenAI::Image] } |
#output_format ⇒ Symbol, ...
The output format of the image generation. Either png
, webp
, or jpeg
.
30 |
# File 'lib/openai/models/images_response.rb', line 30 optional :output_format, enum: -> { OpenAI::ImagesResponse::OutputFormat } |
#quality ⇒ Symbol, ...
The quality of the image generated. Either low
, medium
, or high
.
36 |
# File 'lib/openai/models/images_response.rb', line 36 optional :quality, enum: -> { OpenAI::ImagesResponse::Quality } |
#size ⇒ Symbol, ...
The size of the image generated. Either 1024x1024
, 1024x1536
, or
1536x1024
.
43 |
# File 'lib/openai/models/images_response.rb', line 43 optional :size, enum: -> { OpenAI::ImagesResponse::Size } |
#usage ⇒ OpenAI::Models::ImagesResponse::Usage?
For gpt-image-1
only, the token usage information for the image generation.
49 |
# File 'lib/openai/models/images_response.rb', line 49 optional :usage, -> { OpenAI::ImagesResponse::Usage } |
Class Method Details
.values ⇒ Array<Symbol>
|
# File 'lib/openai/models/images_response.rb', line 81
|