Class EvalResult.Builder

java.lang.Object
dev.dokimos.core.EvalResult.Builder
Enclosing class:
EvalResult

public static class EvalResult.Builder extends Object
Builder for constructing evaluation results.
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • name

      public EvalResult.Builder name(String name)
      Sets the evaluator name.
      Parameters:
      name - the evaluator name
      Returns:
      this builder
    • score

      public EvalResult.Builder score(double score)
      Sets the numeric score.
      Parameters:
      score - the score value
      Returns:
      this builder
    • threshold

      public EvalResult.Builder threshold(double threshold)
      Sets the success threshold.
      Parameters:
      threshold - the threshold value
      Returns:
      this builder
    • reason

      public EvalResult.Builder reason(String reason)
      Sets the reason or explanation.
      Parameters:
      reason - the reason text
      Returns:
      this builder
    • metadata

      public EvalResult.Builder metadata(Map<String,Object> metadata)
      Sets the metadata.
      Parameters:
      metadata - the metadata map
      Returns:
      this builder
    • build

      public EvalResult build()
      Builds the result.
      Returns:
      a new evaluation result