Class: Braintrust::Eval::Case

Inherits:
Struct
  • Object
show all
Defined in:
lib/braintrust/eval/case.rb

Overview

Case represents a single test case in an evaluation

Instance Attribute Summary collapse

Instance Attribute Details

#expectedObject?

The expected output (optional)

Returns:

  • (Object, nil)

    the current value of expected



12
13
14
# File 'lib/braintrust/eval/case.rb', line 12

def expected
  @expected
end

#inputObject

The input to the task

Returns:

  • (Object)

    the current value of input



12
13
14
# File 'lib/braintrust/eval/case.rb', line 12

def input
  @input
end

#metadataHash?

Optional metadata for the case

Returns:

  • (Hash, nil)

    the current value of metadata



12
13
14
# File 'lib/braintrust/eval/case.rb', line 12

def 
  @metadata
end

#originHash?

Origin pointer for cases from remote sources (e.g., datasets). Contains: object_type, object_id, id, _xact_id, created

Returns:

  • (Hash, nil)

    the current value of origin



12
13
14
# File 'lib/braintrust/eval/case.rb', line 12

def origin
  @origin
end

#tagsArray<String>?

Optional tags for filtering/grouping

Returns:

  • (Array<String>, nil)

    the current value of tags



12
13
14
# File 'lib/braintrust/eval/case.rb', line 12

def tags
  @tags
end