ReportingConfiguration constructor

ReportingConfiguration(
  1. Iterable<Evaluator> evaluators,
  2. EvaluationResultStore resultStore, {
  3. ChatConfiguration? chatConfiguration,
  4. EvaluationResponseCacheProvider? responseCacheProvider,
  5. Iterable<String>? cachingKeys,
  6. String? executionName,
  7. EvaluationMetricInterpretation? evaluationMetricInterpreter(
    1. EvaluationMetric
    )?,
  8. Iterable<String>? tags,
})

Creates a ReportingConfiguration.

evaluators are the evaluators to run for each scenario. resultStore persists results. chatConfiguration is required for AI-based evaluators. responseCacheProvider enables response caching when non-null. cachingKeys are extra strings hashed into response cache keys. executionName uniquely identifies this batch; defaults to "Default". evaluationMetricInterpreter overrides metric interpretations. tags are labels applied to every ScenarioRun.

Implementation

ReportingConfiguration(
  Iterable<Evaluator> evaluators,
  this.resultStore, {
  this.chatConfiguration,
  this.responseCacheProvider,
  Iterable<String>? cachingKeys,
  String? executionName,
  this.evaluationMetricInterpreter,
  Iterable<String>? tags,
})  : evaluators = List.unmodifiable(evaluators),
      cachingKeys = List.unmodifiable(cachingKeys ?? []),
      executionName = executionName ?? 'Default',
      tags = tags != null ? List.unmodifiable(tags) : null;