Class RunMetric
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<RunMetric.Builder,RunMetric>
A metric that a gate measures over the run's cases.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic RunMetric.Builderbuilder()final booleanfinal booleanequalsBySdkFields(Object obj) Indicates whether some other object is "equal to" this one by SDK fields.final EvaluatorRefThe average score of a numeric evaluator.final UnitThe cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have.static RunMetricfromEvaluatorAverage(Consumer<EvaluatorRef.Builder> evaluatorAverage) Create an instance of this class withevaluatorAverage()initialized to the given value.static RunMetricfromEvaluatorAverage(EvaluatorRef evaluatorAverage) Create an instance of this class withevaluatorAverage()initialized to the given value.static RunMetricfromFixedCases(Consumer<Unit.Builder> fixedCases) Create an instance of this class withfixedCases()initialized to the given value.static RunMetricfromFixedCases(Unit fixedCases) Create an instance of this class withfixedCases()initialized to the given value.static RunMetricfromNotScoredRate(Consumer<Unit.Builder> notScoredRate) Create an instance of this class withnotScoredRate()initialized to the given value.static RunMetricfromNotScoredRate(Unit notScoredRate) Create an instance of this class withnotScoredRate()initialized to the given value.static RunMetricfromPassRate(Consumer<Unit.Builder> passRate) Create an instance of this class withpassRate()initialized to the given value.static RunMetricfromPassRate(Unit passRate) Create an instance of this class withpassRate()initialized to the given value.static RunMetricfromRegressedCases(Consumer<Unit.Builder> regressedCases) Create an instance of this class withregressedCases()initialized to the given value.static RunMetricfromRegressedCases(Unit regressedCases) Create an instance of this class withregressedCases()initialized to the given value.static RunMetricfromRegressedScores(Consumer<Unit.Builder> regressedScores) Create an instance of this class withregressedScores()initialized to the given value.static RunMetricfromRegressedScores(Unit regressedScores) Create an instance of this class withregressedScores()initialized to the given value.static RunMetricfromUnpairedCaseRate(Consumer<Unit.Builder> unpairedCaseRate) Create an instance of this class withunpairedCaseRate()initialized to the given value.static RunMetricfromUnpairedCaseRate(Unit unpairedCaseRate) Create an instance of this class withunpairedCaseRate()initialized to the given value.final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz) final inthashCode()final UnitThe share of cases with no score.final UnitpassRate()The share of cases that pass.final UnitThe cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have.final UnitFails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run.static Class<? extends RunMetric.Builder> Take this object and create a builder that contains all of the current property values of this object.final StringtoString()Returns a string representation of this object.type()Retrieve an enum value representing which member of this object is populated.final UnitThe share of cases that are not judged on both the target and the control.Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
Method Details
-
passRate
The share of cases that pass. Higher is better.
- Returns:
- The share of cases that pass. Higher is better.
-
notScoredRate
The share of cases with no score. Lower is better. When no min or max gate names this metric, a max of 0.05 applies; a vsControl gate on it does not replace that default.
- Returns:
- The share of cases with no score. Lower is better. When no min or max gate names this metric, a max of 0.05 applies; a vsControl gate on it does not replace that default.
-
evaluatorAverage
The average score of a numeric evaluator. Higher is better, so the gate takes min, unless the evaluator's scoreDirection is LOWER_IS_BETTER, when it takes max.
- Returns:
- The average score of a numeric evaluator. Higher is better, so the gate takes min, unless the evaluator's scoreDirection is LOWER_IS_BETTER, when it takes max.
-
regressedCases
The cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Lower is better. Requires a control (RULE_CONTROL_REQUIRED).
- Returns:
- The cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Lower is better. Requires a control (RULE_CONTROL_REQUIRED).
-
fixedCases
The cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Higher is better. Requires a control (RULE_CONTROL_REQUIRED).
- Returns:
- The cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Higher is better. Requires a control (RULE_CONTROL_REQUIRED).
-
regressedScores
Fails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run. Requires a control (RULE_CONTROL_REQUIRED). Takes no bound.
- Returns:
- Fails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run. Requires a control (RULE_CONTROL_REQUIRED). Takes no bound.
-
unpairedCaseRate
The share of cases that are not judged on both the target and the control. Lower is better. Requires a control (RULE_CONTROL_REQUIRED). Checked only when the rule has a gate on it: comparing with a control adds no gate.
- Returns:
- The share of cases that are not judged on both the target and the control. Lower is better. Requires a control (RULE_CONTROL_REQUIRED). Checked only when the rule has a gate on it: comparing with a control adds no gate.
-
toBuilder
Description copied from interface:ToCopyableBuilderTake this object and create a builder that contains all of the current property values of this object.- Specified by:
toBuilderin interfaceToCopyableBuilder<RunMetric.Builder,RunMetric> - Returns:
- a builder for type T
-
builder
-
serializableBuilderClass
-
hashCode
-
equals
-
equalsBySdkFields
Description copied from interface:SdkPojoIndicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in anSdkPojoclass, and is generated based on a service model.If an
SdkPojoclass does not have any inherited fields,equalsBySdkFieldsandequalsare essentially the same.- Specified by:
equalsBySdkFieldsin interfaceSdkPojo- Parameters:
obj- the object to be compared with- Returns:
- true if the other object equals to this object by sdk fields, false otherwise.
-
toString
-
getValueForField
-
fromPassRate
Create an instance of this class withpassRate()initialized to the given value.The share of cases that pass. Higher is better.
- Parameters:
passRate- The share of cases that pass. Higher is better.
-
fromPassRate
Create an instance of this class withpassRate()initialized to the given value.The share of cases that pass. Higher is better.
- Parameters:
passRate- The share of cases that pass. Higher is better.
-
fromNotScoredRate
Create an instance of this class withnotScoredRate()initialized to the given value.The share of cases with no score. Lower is better. When no min or max gate names this metric, a max of 0.05 applies; a vsControl gate on it does not replace that default.
- Parameters:
notScoredRate- The share of cases with no score. Lower is better. When no min or max gate names this metric, a max of 0.05 applies; a vsControl gate on it does not replace that default.
-
fromNotScoredRate
Create an instance of this class withnotScoredRate()initialized to the given value.The share of cases with no score. Lower is better. When no min or max gate names this metric, a max of 0.05 applies; a vsControl gate on it does not replace that default.
- Parameters:
notScoredRate- The share of cases with no score. Lower is better. When no min or max gate names this metric, a max of 0.05 applies; a vsControl gate on it does not replace that default.
-
fromEvaluatorAverage
Create an instance of this class withevaluatorAverage()initialized to the given value.The average score of a numeric evaluator. Higher is better, so the gate takes min, unless the evaluator's scoreDirection is LOWER_IS_BETTER, when it takes max.
- Parameters:
evaluatorAverage- The average score of a numeric evaluator. Higher is better, so the gate takes min, unless the evaluator's scoreDirection is LOWER_IS_BETTER, when it takes max.
-
fromEvaluatorAverage
Create an instance of this class withevaluatorAverage()initialized to the given value.The average score of a numeric evaluator. Higher is better, so the gate takes min, unless the evaluator's scoreDirection is LOWER_IS_BETTER, when it takes max.
- Parameters:
evaluatorAverage- The average score of a numeric evaluator. Higher is better, so the gate takes min, unless the evaluator's scoreDirection is LOWER_IS_BETTER, when it takes max.
-
fromRegressedCases
Create an instance of this class withregressedCases()initialized to the given value.The cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Lower is better. Requires a control (RULE_CONTROL_REQUIRED).
- Parameters:
regressedCases- The cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Lower is better. Requires a control (RULE_CONTROL_REQUIRED).
-
fromRegressedCases
Create an instance of this class withregressedCases()initialized to the given value.The cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Lower is better. Requires a control (RULE_CONTROL_REQUIRED).
- Parameters:
regressedCases- The cases that pass on the control and fail on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Lower is better. Requires a control (RULE_CONTROL_REQUIRED).
-
fromFixedCases
Create an instance of this class withfixedCases()initialized to the given value.The cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Higher is better. Requires a control (RULE_CONTROL_REQUIRED).
- Parameters:
fixedCases- The cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Higher is better. Requires a control (RULE_CONTROL_REQUIRED).
-
fromFixedCases
Create an instance of this class withfixedCases()initialized to the given value.The cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Higher is better. Requires a control (RULE_CONTROL_REQUIRED).
- Parameters:
fixedCases- The cases that fail on the control and pass on the target, of the cases both runs have, each judged on both sides by the rule's criteria on the evaluators both runs have. Higher is better. Requires a control (RULE_CONTROL_REQUIRED).
-
fromRegressedScores
Create an instance of this class withregressedScores()initialized to the given value.Fails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run. Requires a control (RULE_CONTROL_REQUIRED). Takes no bound.
- Parameters:
regressedScores- Fails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run. Requires a control (RULE_CONTROL_REQUIRED). Takes no bound.
-
fromRegressedScores
Create an instance of this class withregressedScores()initialized to the given value.Fails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run. Requires a control (RULE_CONTROL_REQUIRED). Takes no bound.
- Parameters:
regressedScores- Fails the run when, for any case that both runs scored, on any evaluator that both runs have, the target scored worse than the control: lower, or higher for an evaluator whose scoreDirection is LOWER_IS_BETTER on the target run. Requires a control (RULE_CONTROL_REQUIRED). Takes no bound.
-
fromUnpairedCaseRate
Create an instance of this class withunpairedCaseRate()initialized to the given value.The share of cases that are not judged on both the target and the control. Lower is better. Requires a control (RULE_CONTROL_REQUIRED). Checked only when the rule has a gate on it: comparing with a control adds no gate.
- Parameters:
unpairedCaseRate- The share of cases that are not judged on both the target and the control. Lower is better. Requires a control (RULE_CONTROL_REQUIRED). Checked only when the rule has a gate on it: comparing with a control adds no gate.
-
fromUnpairedCaseRate
Create an instance of this class withunpairedCaseRate()initialized to the given value.The share of cases that are not judged on both the target and the control. Lower is better. Requires a control (RULE_CONTROL_REQUIRED). Checked only when the rule has a gate on it: comparing with a control adds no gate.
- Parameters:
unpairedCaseRate- The share of cases that are not judged on both the target and the control. Lower is better. Requires a control (RULE_CONTROL_REQUIRED). Checked only when the rule has a gate on it: comparing with a control adds no gate.
-
type
Retrieve an enum value representing which member of this object is populated. When this class is returned in a service response, this will beRunMetric.Type.UNKNOWN_TO_SDK_VERSIONif the service returned a member that is only known to a newer SDK version. When this class is created directly in your code, this will beRunMetric.Type.UNKNOWN_TO_SDK_VERSIONif zero members are set, andnullif more than one member is set. -
sdkFields
-
sdkFieldNameToField
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo- Returns:
- The mapping between the field name and its corresponding field.
-