Interface EvalCreateParams.TestingCriterion.Visitor
-
- All Implemented Interfaces:
public interface EvalCreateParams.TestingCriterion.Visitor<T extends Object>
An interface that defines how to map each variant of TestingCriterion to a value of type T.
-
-
Method Summary
Modifier and Type Method Description abstract T
visitLabelModel(EvalCreateParams.TestingCriterion.LabelModel labelModel)
A LabelModelGrader object which uses a model to assign labels to each item in the evaluation. abstract T
visitStringCheck(StringCheckGrader stringCheck)
A StringCheckGrader object that performs a string comparison between input and reference using a specified operation. abstract T
visitTextSimilarity(EvalCreateParams.TestingCriterion.TextSimilarity textSimilarity)
A TextSimilarityGrader object which grades text based on similarity metrics. abstract T
visitPython(EvalCreateParams.TestingCriterion.Python python)
A PythonGrader object that runs a python script on the input. abstract T
visitScoreModel(EvalCreateParams.TestingCriterion.ScoreModel scoreModel)
A ScoreModelGrader object that uses a model to assign a score to the input. T
unknown(JsonValue json)
Maps an unknown variant of TestingCriterion to a value of type T. -
-
Method Detail
-
visitLabelModel
abstract T visitLabelModel(EvalCreateParams.TestingCriterion.LabelModel labelModel)
A LabelModelGrader object which uses a model to assign labels to each item in the evaluation.
-
visitStringCheck
abstract T visitStringCheck(StringCheckGrader stringCheck)
A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.
-
visitTextSimilarity
abstract T visitTextSimilarity(EvalCreateParams.TestingCriterion.TextSimilarity textSimilarity)
A TextSimilarityGrader object which grades text based on similarity metrics.
-
visitPython
abstract T visitPython(EvalCreateParams.TestingCriterion.Python python)
A PythonGrader object that runs a python script on the input.
-
visitScoreModel
abstract T visitScoreModel(EvalCreateParams.TestingCriterion.ScoreModel scoreModel)
A ScoreModelGrader object that uses a model to assign a score to the input.
-
unknown
T unknown(JsonValue json)
Maps an unknown variant of TestingCriterion to a value of type T.
An instance of TestingCriterion can contain an unknown variant if it was deserialized from data that doesn't match any known variant. For example, if the SDK is on an older version than the API, then the API may respond with new variants that the SDK is unaware of.
-
-
-
-