Package com.google.genkit.ai.evaluation
Class EvalResponse
java.lang.Object
com.google.genkit.ai.evaluation.EvalResponse
Response from an evaluator for a single test case.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic EvalResponse.Builderbuilder()Gets the evaluation as a single Score.Gets the evaluation as a list of Scores.voidsetEvaluation(Object evaluation) voidsetSampleIndex(Integer sampleIndex) voidvoidsetTestCaseId(String testCaseId) voidsetTraceId(String traceId)
-
Constructor Details
-
EvalResponse
public EvalResponse()
-
-
Method Details
-
builder
-
getSampleIndex
-
setSampleIndex
-
getTestCaseId
-
setTestCaseId
-
getTraceId
-
setTraceId
-
getSpanId
-
setSpanId
-
getEvaluation
-
getEvaluationAsScore
Gets the evaluation as a single Score.- Returns:
- the score, or null if the evaluation is a list
-
getEvaluationAsScoreList
Gets the evaluation as a list of Scores.- Returns:
- the list of scores, or null if the evaluation is a single score
-
setEvaluation
-