• Preparing search index...
  • The search index is not available
Arize Phoenix TS
  • Arize Phoenix TS
  • @arizeai/phoenix-evals
  • llm/createHallucinationEvaluator
  • createHallucinationEvaluator

Function createHallucinationEvaluator

  • createHallucinationEvaluator<
        RecordType extends
            Record<string, unknown> = HallucinationEvaluationRecord,
    >(
        args: HallucinationEvaluatorArgs<RecordType>,
    ): ClassificationEvaluator<RecordType>

    Type Parameters

    • RecordType extends Record<string, unknown> = HallucinationEvaluationRecord

    Parameters

    • args: HallucinationEvaluatorArgs<RecordType>

      The arguments for creating the hallucination evaluator.

    Returns ClassificationEvaluator<RecordType>

    A function that evaluates whether an answer is factual or hallucinated based on a query and reference text.

    Deprecated

    Use createFaithfulnessEvaluator instead.

    Creates a function that evaluates whether an answer is factual or hallucinated based on a query and reference text.

    Note: This is deprecated. Please use createFaithfulnessEvaluator which:

    • Uses 'faithful'/'unfaithful' labels instead of 'factual'/'hallucinated'
    • Maximizes the score (1.0 for faithful, 0.0 for unfaithful)
    • Defined in llm/createHallucinationEvaluator.ts:47

Settings

Member Visibility
Arize Phoenix TS
  • Loading...

Generated using TypeDoc