OpenAI::AssistantSupportedModels
Inherits Enum < Comparable < Value < Object
Constants
Gpt5 = 0
Gpt5Mini = 1
Gpt5Nano = 2
Gpt520250807 = 3
Gpt5Mini20250807 = 4
Gpt5Nano20250807 = 5
Gpt41 = 6
Gpt41Mini = 7
Gpt41Nano = 8
Gpt4120250414 = 9
Gpt41Mini20250414 = 10
Gpt41Nano20250414 = 11
O3Mini = 12
O3Mini20250131 = 13
O1 = 14
O120241217 = 15
Gpt4O = 16
Gpt4O20241120 = 17
Gpt4O20240806 = 18
Gpt4O20240513 = 19
Gpt4OMini = 20
Gpt4OMini20240718 = 21
Gpt45Preview = 22
Gpt45Preview20250227 = 23
Gpt4Turbo = 24
Gpt4Turbo20240409 = 25
Gpt40125Preview = 26
Gpt4TurboPreview = 27
Gpt41106Preview = 28
Gpt4VisionPreview = 29
Gpt4 = 30
Gpt40314 = 31
Gpt40613 = 32
Gpt432K = 33
Gpt432K0314 = 34
Gpt432K0613 = 35
Gpt35Turbo = 36
Gpt35Turbo16K = 37
Gpt35Turbo0613 = 38
Gpt35Turbo1106 = 39
Gpt35Turbo0125 = 40
Gpt35Turbo16K0613 = 41
Constructors
new(pull : JSON::PullParser) : self
SourceInstance methods
Serializes this enum member by name.
For non-flags enums, the serialization is a JSON string. The value is the
member name (see #to_s) transformed with String#underscore.
enum Stages
INITIAL
SECOND_STAGE
end
Stages::INITIAL.to_json # => %("initial")
Stages::SECOND_STAGE.to_json # => %("second_stage")
For flags enums, the serialization is a JSON array including every flagged
member individually serialized in the same way as a member of a non-flags enum.
None is serialized as an empty array, All as an array containing
all members.
@[Flags]
enum Sides
LEFT
RIGHT
end
Sides::LEFT.to_json # => %(["left"])
(Sides::LEFT | Sides::RIGHT).to_json # => %(["left","right"])
Sides::All.to_json # => %(["left","right"])
Sides::None.to_json # => %([])
ValueConverter.to_json offers a different serialization strategy based on the
member value.