Judgment Labs Logo
Python

ScorerData

The result from a single scorer for one example.

The result from a single scorer for one example.

Each ScoringResult contains a list of ScorerData -- one per scorer that was run. Inspect value for the scorer's output.

Attributes

name

:

str

Scorer name (e.g. "faithfulness").

value

:

Optional[Union[str, float]]

The scorer result. Binary scorers use "Yes" or "No"; categorical scorers use their selected category.

Default:

None

score_type

:

Optional[str]

Result type returned by the scorer.

Default:

None

minimum_score_range

:

float

Lower bound of the scoring scale.

Default:

0

maximum_score_range

:

float

Upper bound of the scoring scale.

Default:

1

evaluation_model

:

Optional[str]

The LLM used to produce the score.

Default:

None

error

:

Optional[str]

Error message if scoring failed.

Default:

None

additional_metadata

:

Dict[str, Any]

Extra metadata from the scorer.

Default:

field(default_factory=dict)

id

:

Optional[str]

Unique identifier for this result.

Default:

None

success

:

Optional[bool]

Outcome of a client-side pass condition for the row this scorer result belongs to. None when no pass condition was evaluated.

Default:

None


to_dict()

Serialize to a dictionary, omitting None fields.

def to_dict() -> Dict[str, Any]:

Returns

Dict[str, Any]