Estimating the reliability of responses generated by Large Language Models (LLMs) is a fundamental challenge for their deployment in real-world applications, particularly in edge scenarios with limited computational resources and strict efficiency constraints. Existing approaches based on semantic consistency typically rely on global graph-level summaries, such as semantic entropy or density measures computed over multiple sampled generations. In this thesis, we propose a shift from global uncertainty estimation to a local, setconditioned analysis of entailment structures. Given a small set of stochastic samples, we construct an entailment graph where nodes represent candidate responses and edges encode pairwise semantic support relations. From this graph, we derive two complementary node-level features: Local Semantic Entropy (LSE), capturing the distributional structure of semantic support, and Local Consensus Apex (LCA), measuring peak entailment strength. We show that these two features provide complementary but regime-dependent signals of reliability, with their relative contribution varying as a function of the sampling budget (N). In particular, increasing (N) induces a gradual shift from peak-based to distributionbased semantic evidence. The proposed method learns a non-linear combination of LSE and LCA via a lightweight classifier, enabling accurate calibration of response correctness. Experiments on multiple benchmarks, including factoid question answering and mathematical reasoning tasks, demonstrate consistent improvements in AUROC over existing semantic consistency baselines. Overall, the results suggest that uncertainty in LLM responses is not captured by a single global score, but emerges from a regime-dependent interaction between peak and distributional structure in the entailment graph.
La stima dell’affidabilità delle risposte generate dai Large Language Models (LLM) rappresenta una sfida fondamentale per il loro impiego in contesti reali, in particolare in scenari edge caratterizzati da risorse computazionali limitate e forti vincoli di efficienza. Gli approcci recenti basati sulla consistenza semantica sfruttano campioni multipli di generazioni e la costruzione di grafi di entailment, ricorrendo tipicamente a metriche globali di sintesi del grafo, come l’entropia semantica o misure di densità. In questa tesi proponiamo un passaggio da una stima globale dell’incertezza a un’analisi locale e set-condizionata delle strutture di entailment. A partire da un numero limitato di campioni stocastici, costruiamo un grafo in cui i nodi rappresentano le risposte candidate e gli archi codificano relazioni di supporto semantico tra risposte. Dal grafo estraiamo due caratteristiche complementari a livello di nodo: la Local Semantic Entropy (LSE), che cattura la struttura distribuzionale del supporto semantico, e la Local Consensus Apex (LCA), che misura l’intensità del massimo supporto di entailment. Mostriamo che tali caratteristiche forniscono segnali complementari ma dipendenti dal regime di campionamento, con un contributo relativo che varia al variare del budget di campionamento (N). In particolare, all’aumentare di (N) si osserva una transizione graduale da un regime dominato dal supporto massimo a uno dominato dalla struttura distribuzionale. Il metodo proposto combina in modo non lineare LSE e LCA tramite un classificatore leggero, consentendo una calibrazione accurata della probabilità di correttezza delle risposte. Gli esperimenti su diversi benchmark, inclusi task di question answering fattuale e di ragionamento matematico, mostrano miglioramenti consistenti in termini di AUROC rispetto ai principali baselines basati su consistenza semantica. Nel complesso, i risultati suggeriscono che l’incertezza nelle risposte degli LLM non può essere catturata da un singolo score globale, ma emerge dall’interazione dipendente dal regime tra struttura di picco e struttura distribuzionale nel grafo di entailment.
From global uncertainty to local reliability: graph-based answer scoring for Low-sampling Language Models
TURAZZA, ALESSANDRO
2025/2026
Abstract
Estimating the reliability of responses generated by Large Language Models (LLMs) is a fundamental challenge for their deployment in real-world applications, particularly in edge scenarios with limited computational resources and strict efficiency constraints. Existing approaches based on semantic consistency typically rely on global graph-level summaries, such as semantic entropy or density measures computed over multiple sampled generations. In this thesis, we propose a shift from global uncertainty estimation to a local, setconditioned analysis of entailment structures. Given a small set of stochastic samples, we construct an entailment graph where nodes represent candidate responses and edges encode pairwise semantic support relations. From this graph, we derive two complementary node-level features: Local Semantic Entropy (LSE), capturing the distributional structure of semantic support, and Local Consensus Apex (LCA), measuring peak entailment strength. We show that these two features provide complementary but regime-dependent signals of reliability, with their relative contribution varying as a function of the sampling budget (N). In particular, increasing (N) induces a gradual shift from peak-based to distributionbased semantic evidence. The proposed method learns a non-linear combination of LSE and LCA via a lightweight classifier, enabling accurate calibration of response correctness. Experiments on multiple benchmarks, including factoid question answering and mathematical reasoning tasks, demonstrate consistent improvements in AUROC over existing semantic consistency baselines. Overall, the results suggest that uncertainty in LLM responses is not captured by a single global score, but emerges from a regime-dependent interaction between peak and distributional structure in the entailment graph.| File | Dimensione | Formato | |
|---|---|---|---|
|
Thesis_Turazza_Alessandro.pdf
accessibile in internet solo dagli utenti autorizzati
Descrizione: Tesi
Dimensione
903.15 kB
Formato
Adobe PDF
|
903.15 kB | Adobe PDF | Visualizza/Apri |
|
Extended_Abstract_Turazza_Alessandro.pdf
accessibile in internet solo dagli utenti autorizzati
Descrizione: Extended Abstract
Dimensione
497.63 kB
Formato
Adobe PDF
|
497.63 kB | Adobe PDF | Visualizza/Apri |
I documenti in POLITesi sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.
https://hdl.handle.net/10589/261445