Langfuse JS/TS SDKs
    Preparing search index...

    Type Alias EvaluationRuleMappingSource

    EvaluationRuleMappingSource:
        | "input"
        | "output"
        | "metadata"
        | "expected_output"
        | "experiment_item_metadata"

    Source field used to populate a prompt variable.

    Use these values when mapping evaluator prompt variables to live data.

    Target-specific rules:

    • target=observation supports input, output, and metadata
    • target=experiment supports input, output, metadata, expected_output, and experiment_item_metadata

    Source semantics:

    • input: the observation or experiment input payload
    • output: the observation or experiment output payload
    • metadata: the metadata object for the target. Combine with jsonPath when you need one nested field instead of the whole object.
    • expected_output: the experiment item's expected output. Only valid for target=experiment.
    • experiment_item_metadata: the experiment item's metadata object. Only valid for target=experiment.