Class: OpenAI::Models::CompletionChoice::Logprobs

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/completion_choice.rb

Overview

See Also:

Instance Attribute Summary collapse

Instance Method Summary collapse

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, 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(text_offset: nil, token_logprobs: nil, tokens: nil, top_logprobs: nil) ⇒ Object

Parameters:

  • text_offset (Array<Integer>) (defaults to: nil)
  • token_logprobs (Array<Float>) (defaults to: nil)
  • tokens (Array<String>) (defaults to: nil)
  • top_logprobs (Array<Hash{Symbol=>Float}>) (defaults to: nil)


# File 'lib/openai/models/completion_choice.rb', line 81

Instance Attribute Details

#text_offsetArray<Integer>?

Returns:

  • (Array<Integer>, nil)


64
# File 'lib/openai/models/completion_choice.rb', line 64

optional :text_offset, OpenAI::Internal::Type::ArrayOf[Integer]

#token_logprobsArray<Float>?

Returns:

  • (Array<Float>, nil)


69
# File 'lib/openai/models/completion_choice.rb', line 69

optional :token_logprobs, OpenAI::Internal::Type::ArrayOf[Float]

#tokensArray<String>?

Returns:

  • (Array<String>, nil)


74
# File 'lib/openai/models/completion_choice.rb', line 74

optional :tokens, OpenAI::Internal::Type::ArrayOf[String]

#top_logprobsArray<Hash{Symbol=>Float}>?

Returns:

  • (Array<Hash{Symbol=>Float}>, nil)


79
# File 'lib/openai/models/completion_choice.rb', line 79

optional :top_logprobs, OpenAI::Internal::Type::ArrayOf[OpenAI::Internal::Type::HashOf[Float]]