> ## Documentation Index
> Fetch the complete documentation index at: https://agent-observability-docs.splunk.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Ground Truth Adherence

> Measure equivalence between model outputs and expected responses

Supported modalities:
Supported modalities: Text, Image/PDF, Audio

> [card]
>
> **Ground Truth Adherence** measures whether a model's response is equivalent to your expected response (Ground Truth), based on meaning and other relevant attributes.

Ground Truth Adherence is a boolean evaluator that indicates whether the response is equivalent to the Ground Truth.

This evaluator helps measure how closely your model's outputs match expected or ideal response content, which is particularly valuable for:

* Evaluating model performance against a benchmark dataset
* Ensuring consistency in critical applications
* Measuring the impact of model or prompt changes

> [!NOTE]
>
> This evaluator is only supported in experiments, and requires a Ground Truth to be set in the `output` column of your experiment's [dataset](https://agent-observability-docs.splunk.com/sdk-api/experiments/datasets.md).

## Calculation method

Ground Truth Adherence is computed through a multi-step process:

**1. Model Request**

Additional evaluation requests are sent to OpenAI's GPT4o model to analyze the semantic relationship between responses.

**2. Prompt Engineering**

A carefully engineered chain-of-thought prompt asks the model to evaluate whether the response and Ground Truth convey the same meaning and preserve relevant attributes.

**3. Multiple Evaluations**

The system requests multiple distinct responses to this prompt to ensure robust evaluation through consensus.

**4. Result Analysis**

Each evaluation generates both an explanation of the reasoning and a binary judgment (yes/no) on semantic equivalence.

**5. Result**

The evaluator returns `true` when the response is equivalent to the Ground Truth and `false` otherwise.

We also surface one of the generated explanations, always choosing one that aligns with the majority judgment among the responses.

> [!NOTE]
>
> This evaluator is computed by prompting an LLM multiple times, and thus requires additional LLM calls to compute, which may impact usage and billing.

## Understanding ground truth adherence

> [card]
>
> ### Differentiating from Other Evaluators
>
> It's important to understand how Ground Truth Adherence differs from related evaluators:
>
> **Ground Truth Adherence:** Measures equivalence to expected response, including relevant attributes.
>
> **Correctness:** Measures factual accuracy regardless of any input context/expected response.
>
> **Context Adherence:** Measures alignment with provided input context, not an expected response.

## Optimizing your AI system

> [card]
>
> ### Addressing Low Ground Truth Adherence
>
> When responses have low Ground Truth Adherence scores, your model is generating outputs that differ from your expected responses in meaning or relevant attributes. To improve your system:
>
> **Analyze divergence patterns:** Identify common ways in which responses differ from ground truth.
>
> **Refine your prompts:** Adjust instructions to guide the model toward your expected output format and content.
>
> **Consider few-shot examples:** Provide examples in your prompt that demonstrate the desired response pattern.
>
> **Evaluate ground truth quality:** Ensure your reference content is clear, consistent, and representative of ideal responses.

## Best practices

> [card] Maintain Diverse Ground Truths
>
> Create a varied set of reference content that covers different response styles and edge cases.

> [card] Set Clear Evaluation Criteria
>
> Define what constitutes semantic equivalence for your specific use case and domain.

> [card] Monitor Across Model Versions
>
> Track Ground Truth Adherence when upgrading models to ensure consistent performance.

> [card] Balance with Other Evaluators
>
> Use Ground Truth Adherence alongside evaluators like Correctness and Instruction Adherence for a complete evaluation.

> [!NOTE]
>
> When optimizing for Ground Truth Adherence, remember that there may be multiple valid ways to represent the same content. Consider whether strict adherence to specific wording or attributes is necessary for your use case.

## Performance Benchmarks

We evaluated Ground Truth Adherence against human expert labels on an internal dataset using top frontier models.

| Model | F1 (True) |
| :- | :-: |
| GPT-4.1 | 0.90 |
| GPT-4.1-mini (judges=3) | 0.91 |
| Claude Sonnet 4.5 | 0.91 |
| Gemini 3 Flash | 0.94 |

### GPT-4.1 Classification Report

> [!NOTE]
>
> Benchmarks based on internal evaluation dataset. Performance may vary by use case.

## Related Resources

If you would like to dive deeper or start implementing Ground Truth Adherence, check out the following resources:

### Related Concepts

* [Context Adherence](https://agent-observability-docs.splunk.com/concepts/evaluators/rag/generation-quality/context-adherence.md)
* [Context Relevance](https://agent-observability-docs.splunk.com/concepts/evaluators/rag/retrieval-quality/context-relevance.md)
* [Correctness](https://agent-observability-docs.splunk.com/concepts/evaluators/response-quality/correctness.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.