Class: OpenAI::Models::EvalListResponse::TestingCriterion::EvalGraderPython

Inherits:
Graders::PythonGrader show all
Defined in:
lib/openai/models/eval_list_response.rb,
sig/openai/models/eval_list_response.rbs

Instance Attribute Summary collapse

Attributes inherited from Graders::PythonGrader

#image_tag, #name, #source, #type

Attributes inherited from Internal::Type::BaseModel

#last_response

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, 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, coerce_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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 ⇒ EvalGraderPython

Returns a new instance of EvalGraderPython.

Parameters:

  • name —

    The name of the grader.

  • source —

    The source code of the python script.

  • image_tag —

    The image tag to use for the python script.

  • pass_threshold —

    The threshold for the score.

  • type —

    The object type, which is always python.

  • name: (String)
  • source: (String)
  • image_tag: (String)
  • pass_threshold: (Float)
  • type: (:python)


220
221
222
223
224
225
226
# File 'sig/openai/models/eval_list_response.rbs', line 220

def initialize: (
  name: String,
  source: String,
  ?image_tag: String,
  ?pass_threshold: Float,
  ?type: :python
) -> void

Instance Attribute Details

#pass_threshold ⇒ Float?

The threshold for the score.

Returns:

  • (Float, nil)


218
# File 'lib/openai/models/eval_list_response.rb', line 218

optional :pass_threshold, Float

Instance Method Details

#to_hash ⇒ { name: String, source: String, ?type: :python, ?image_tag: String, ?pass_threshold: Float }

Returns:

  • ({ name: String, source: String, ?type: :python, ?image_tag: String, ?pass_threshold: Float })


228
229
230
231
232
233
234
# File 'sig/openai/models/eval_list_response.rbs', line 228

def to_hash: -> {
  name: String,
  source: String,
  ?type: :python,
  ?image_tag: String,
  ?pass_threshold: Float
}