jevragasscoremirrors ragas.faithfulness / autoevals.Faithfulness / uipath LegacyFaithfulnessEvaluator

Faithfulness

Faithfulness measures whether every claim in an output is supported by the retrieved context. It is the core RAG hallucination check (RAGAS faithfulness, autoevals Faithfulness, UiPath FaithfulnessEvaluator), answered by Jev as a 0–4 level with a probability per level.

Run this example in the console 1 jev question · answered inside one request
how it works // frame by frame

What the evaluator does

Jev treats `context` as the only source of truth and rates how much of `output` can be traced to it, from “most claims unsupported or contradicted” to “every claim traceable and nothing added”. The expected level, its distribution and a pass at 0.75 are returned.

frame 1/4 · the state
state
outputJev costs $42 per million input tokens.
contextPrice: $42 per billion input tokens ($0.042 per million). Output tokens are free.
question → jev

Rate how faithfully every claim in `output` is supported by `context`. Treat `context` as the only source of truth.

ordered levels
0
most claims unsupported or contradicted
82%
1
several claims go beyond the context
14%
2
nearly all supported, minor unsupported detail
3%
3
every claim traceable
1%
4
every claim traceable, nothing added
0%
0.2 / 4conf 82%fail · threshold 75%
exactly what jev is asked

The question, verbatim

This is the question the API sends for the example below, generated from the same code path the playground and API use. Jev sees the request fields as state and returns a probability for each outcome. Nothing is generated, so there is nothing to parse.

qscore · ordered rubric

Rate how faithfully every claim in `output` is supported by the retrieved `context`. Treat `context` as the only source of truth.

  1. 0Most claims in the output are not supported by the context or contradict it
  2. 1Several claims go beyond the context; some are supported
  3. 2Nearly all claims are supported by the context with minor unsupported detail
  4. 3Every claim in the output can be traced to the context
  5. 4Every claim is traceable and the output adds nothing the context does not state
when to use it

Reach for it when

  • Any RAG pipeline: did the answer stay inside the retrieved documents?
  • Summarisation: did the summary invent anything?
  • Agent reports that must cite sources.

Not the right tool when

  • The context is not meant to be complete (the model is allowed outside knowledge); then a low score is not a defect.
  • You need to know which claim failed; pair with chunk_support for per-chunk attribution.

Watch out for

  • Correct inferences from the context (unit conversions, arithmetic) are still faithful; the rubric allows them, but check your gold labels agree.
  • Unit swaps and order-of-magnitude slips are the failure mode that matters; the jeval benchmark includes them.
inputs and example

What to send

required fields
outputcontext
optional fields
input
in suites
RAGEverything
result shape

score 0–1 (expected level ÷ top level), label “x.x / n”, confidence, a probability per level, passed at 75% of the scale.

POST /api/v1/evaluateopen in console
{
  "evaluators": [
    "faithfulness"
  ],
  "input": "What does Jev cost?",
  "output": "Jev costs $42 per million input tokens.",
  "context": [
    "Context length: 64k tokens per request; 32k tokens for `state` plus the longest question.",
    "Rate limits: 250,000 tokens per second / 1,200 requests per minute.",
    "Price: $42 per billion input tokens ($0.042 per million). Output tokens are free."
  ]
}
expected

Level 0: the number is right but the unit is wrong (per billion), which contradicts the context.

rolling it up

Aggregate with

One result per item is a fact; a dataset of them is a metric. These are the aggregations that fit this evaluator's output shape.

related evaluators
questions people ask
What is faithfulness in RAG evaluation?
The share of an answer's claims that are supported by the retrieved context. jeval returns it as a 0–4 level from Jev with a probability per level, so a wrong unit on a right number scores near 0.
How is faithfulness different from answer correctness?
Faithfulness compares the answer with the context; correctness compares it with a reference answer. An answer can be faithful to bad context and still be wrong.