Table of Contents
Fetching ...

A Dialectic Pipeline for Improving LLM Robustness

Sara Candussio

TL;DR

This work tackles the problem of hallucinations and robustness in large language models by proposing a dialectic pipeline that adds a self-dialogue mechanism (thesis, antithesis, synthesis) to generate, critique, and finalize answers. The method leverages context grounding via oracle-RAG settings, with analyses of summarization and filtering of context to assess their impact. Empirical results show the dialectic pipeline substantially outperforms standard model outputs and Chain-of-Thought prompting across multiple model families and multi-hop QA datasets. The approach offers a resource-efficient, grounding-rich alternative to domain-specific fine-tuning, with broad implications for scalable, reliable LLM deployment in complex reasoning tasks.

Abstract

Assessing ways in which Language Models can reduce their hallucinations and improve the outputs' quality is crucial to ensure their large-scale use. However, methods such as fine-tuning on domain-specific data or the training of a separate \textit{ad hoc} verifier require demanding computational resources (not feasible for many user applications) and constrain the models to specific fields of knowledge. In this thesis, we propose a dialectic pipeline that preserves LLMs' generalization abilities while improving the quality of its answer via self-dialogue, enabling it to reflect upon and correct tentative wrong answers. We experimented with different pipeline settings, testing our proposed method on different datasets and on different families of models. All the pipeline stages are enriched with the relevant context (in an oracle-RAG setting) and a study on the impact of its summarization or its filtering is conducted. We find that our proposed dialectic pipeline is able to outperform by significative margins the standard model answers and that it consistently achieves higher performances than Chain-of-Thought only prompting.

A Dialectic Pipeline for Improving LLM Robustness

TL;DR

This work tackles the problem of hallucinations and robustness in large language models by proposing a dialectic pipeline that adds a self-dialogue mechanism (thesis, antithesis, synthesis) to generate, critique, and finalize answers. The method leverages context grounding via oracle-RAG settings, with analyses of summarization and filtering of context to assess their impact. Empirical results show the dialectic pipeline substantially outperforms standard model outputs and Chain-of-Thought prompting across multiple model families and multi-hop QA datasets. The approach offers a resource-efficient, grounding-rich alternative to domain-specific fine-tuning, with broad implications for scalable, reliable LLM deployment in complex reasoning tasks.

Abstract

Assessing ways in which Language Models can reduce their hallucinations and improve the outputs' quality is crucial to ensure their large-scale use. However, methods such as fine-tuning on domain-specific data or the training of a separate \textit{ad hoc} verifier require demanding computational resources (not feasible for many user applications) and constrain the models to specific fields of knowledge. In this thesis, we propose a dialectic pipeline that preserves LLMs' generalization abilities while improving the quality of its answer via self-dialogue, enabling it to reflect upon and correct tentative wrong answers. We experimented with different pipeline settings, testing our proposed method on different datasets and on different families of models. All the pipeline stages are enriched with the relevant context (in an oracle-RAG setting) and a study on the impact of its summarization or its filtering is conducted. We find that our proposed dialectic pipeline is able to outperform by significative margins the standard model answers and that it consistently achieves higher performances than Chain-of-Thought only prompting.
Paper Structure (74 sections, 35 equations, 50 figures, 4 tables)

This paper contains 74 sections, 35 equations, 50 figures, 4 tables.

Figures (50)

  • Figure 1: A schematic representation of Multi-Head Attention (MHA); each head is provided with its own set of key, query and value matrices. The outputs of all the heads are first concatenated and consequently projected to $W_O$ (taken from Jurafsky2009).
  • Figure 2: taken from Jurafsky2009
  • Figure 3: The Language Model Head: the circuit at the top of the last Transformer block maps the output embedding for token $N$ from the last layer $h^L_N$ to a probability distribution over words of the vocabulary $V$ (taken from Jurafsky2009).
  • Figure 4: Creating the word embedded matrix $W \in \mathbb{R}^{N \times d}$ for the input sequence of tokens by multiplying a one-hot matrix of dimensions $N \times |V|$ by the embedding matrix $E \in \mathbb{R}^{|V| \times d}$ (taken from Jurafsky2009).
  • Figure 5: A simple way to model position: add an embedding of the absolute position to the token embedding to produce a new embedding of the same dimensionality (taken from Jurafsky2009).
  • ...and 45 more figures