← Latest papers
📊 statistics

A Semantic-Sampling Framework for Evaluating Calibration in Open-Ended Question Answering

This paper introduces Sem-ECE, a novel framework that evaluates calibration in open-ended question answering by sampling model outputs and grouping them into semantic classes to provide an unbiased, robust metric that outperforms existing verbalized and sampling-based methods, particularly when internal model probabilities are unavailable.

Original authors: Zhanliang Wang, Jiancong Xiao, Ruochen Jin, Shu Yang, Bojian Hou, Li Shen

Published 2026-05-12
📖 6 min read🧠 Deep dive

Original authors: Zhanliang Wang, Jiancong Xiao, Ruochen Jin, Shu Yang, Bojian Hou, Li Shen

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you are hiring a team of experts to answer difficult trivia questions. You want to know not just what they answer, but how sure they are about their answers. If an expert says, "I'm 90% sure the capital is Paris," you want to know if they are actually right 90% of the time. This alignment between confidence and accuracy is called calibration.

In the world of AI (Large Language Models), this is tricky. When a model gives a short, multiple-choice answer, we can easily check its math. But when it writes a long, open-ended essay or a creative story, checking its confidence is like trying to measure the temperature of a cloud.

This paper introduces a new way to measure that "temperature" called Sem-ECE. Here is how it works, broken down into simple analogies.

The Problem: The "Overconfident Student"

Current ways to check AI confidence are flawed:

  1. Asking the AI directly: If you ask an AI, "How confident are you?" it often lies or guesses, usually saying it's more sure than it actually is. It's like a student who raises their hand and shouts, "I'm 100% sure!" even when they are just guessing.
  2. Looking at the code (Logits): Sometimes, we can peek inside the AI's brain to see its internal math. But most commercial AI services (like the ones used by doctors or lawyers) don't let us see this. It's like trying to judge a magician's trick by looking at their hands, but they are wearing gloves.
  3. Repeating the question: If you ask an AI the same question 50 times, it might give 50 slightly different answers. If 49 of them say "Paris" and 1 says "London," we might guess it's pretty sure about Paris. But existing methods for doing this are messy and rely on rigid rules that break when the AI uses different words to say the same thing.

The Solution: The "Sem-ECE" Framework

The authors propose a new method called Sem-ECE (Semantic-Sampling Expected Calibration Error). Think of it as a Taste-Test Panel.

Instead of asking the AI once, you ask it 50 times.

  1. The Sampling: You get 50 different answers.
  2. The Grouping (Semantic Clustering): You don't just count exact word matches. You use a smart judge (another AI) to group answers that mean the same thing.
    • Example: "The capital is Paris," "It's Paris," and "Paris, France" all get put into the same "Paris" bucket.
  3. The Frequency: If 40 out of 50 answers end up in the "Paris" bucket, the AI's confidence is 80%.

The Two New Estimators: "Same-Sample" vs. "Held-Out"

The paper introduces two specific ways to calculate this confidence, comparing them to two different ways of grading a test.

1. Sem1-ECE: The "Same-Sample" Score (The Biased Judge)

This method picks the most popular answer from the 50 samples and uses the same 50 samples to calculate the confidence.

  • The Flaw: This is like a teacher grading a test using the same students who took the test to determine the passing score. Because the teacher picked the "winner" from that specific group, they are likely to overestimate how good that winner is. In statistics, this is called the "Winner's Curse." The AI looks more confident than it really is because it's judging itself on the very data it used to pick the answer.

2. Sem2-ECE: The "Held-Out" Score (The Fair Judge)

This method splits the 50 samples into two groups:

  • Group A (25 samples): Used to pick the "winning" answer.
  • Group B (25 samples): Used only to count how often that winning answer appears.
  • The Advantage: This is like a teacher picking the best essay from the first half of the class, then grading that specific essay using the second half of the class as a reference. Because Group B didn't help pick the winner, the confidence score is fairer and more accurate. It avoids the "Winner's Curse."

The Big Discovery: Easy vs. Hard Questions

The paper proves mathematically that:

  • On Easy Questions: Both methods agree. The AI is so sure that the "Winner's Curse" doesn't matter much.
  • On Hard Questions: The methods diverge. The "Same-Sample" method (Sem1) stays overly optimistic, while the "Held-Out" method (Sem2) correctly lowers the confidence score.
  • The Gap as a Diagnostic: The difference between the two scores acts as a difficulty meter. If the two scores are far apart, the question is hard and the AI is struggling. If they are close, the question is easy.

The Results: What They Found

The authors tested this on five major AI models (like GPT-4, Claude, Gemini) across three difficult question sets (ranging from simple facts to expert-level science).

  • Sem2-ECE won: In almost every case, the "Held-Out" method (Sem2) gave a more accurate picture of the AI's true reliability than asking the AI directly or using the "Same-Sample" method.
  • It works without "gloves": This method works even if you can't see the AI's internal math (logits). You just need to ask it questions and read the answers.
  • It catches overconfidence: The study showed that when models are wrong, they often think they are right. Sem-ECE exposes this by showing that the AI's "confidence" (how often it repeats an answer) doesn't match its actual "accuracy" (how often that answer is correct).

Summary

Imagine you are a pilot flying a plane. You need to know if your navigation system is trustworthy.

  • Old way: Ask the system, "Are you sure?" (It says "Yes!" but might be wrong).
  • New way (Sem-ECE): Ask the system to plot the course 50 times. Group the similar paths. If 40 paths go left and 10 go right, you know it's 80% sure. But to be really sure, you check those 40 paths against a fresh set of 25 new simulations (Sem2) to make sure the system isn't just fooling itself.

This paper provides the toolkit to do exactly that for AI, ensuring that when a model says it's confident, it actually is.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →