Max
Finds the maximum value of a score (with the given name) across all samples. Use this to surface best-case performance - for example, the highest judge score across all responses. Pair with Min and Mean for a complete picture of score distribution.
Output
A single metric named {field}_max by default, or the value of name if provided.
Examples
Example: RAG QA. Finds the highest judge score across all samples to identify the best-performing response in the run.
...
definition:
...
scorers:
- type: "model_as_a_judge_scorer"
model_key: "<< config.judge_model >>"
system_prompt: >
You are an evaluator assessing the << config.evaluation_dimension >> of a
model response to a question.
On a scale from 0 to 100, assign 100 if the response is fully
<< config.evaluation_dimension >> and 0 if it is not at all.
Return only the numeric score.
user_prompt: >
<context>{{ sample.context }}</context>
<response>{{ model_output.choices[0].message.content }}</response>
score_min: 0
score_max: 100
metrics:
- type: "mean"
field: "score"
name: "Mean Score"
- type: "min"
field: "score"
name: "Min Score"
- type: "max"
field: "score"
name: "Max Score"Configuration
Properties
type Literal "max" required
The type of the metric.
field string, TemplateValue required
The field over which to compute the max.
name string, TemplateValue
The name given to the metric value. If not specified, it is {field}_max
None
key string
Unique identifier assigned to the entity in AI GO!.
Default:None
