Fidelity-Enriched Contrastive Search: Reconciling the Faithfulness-Diversity Trade-Off in Text Generation (2023)

Abstract: In this paper, we address the hallucination problem commonly found in natural language generation tasks. Language models often generate fluent and convincing content but can lack consistency with the provided source, resulting in potential inaccuracies. We propose a new decoding method called Fidelity-Enriched Contrastive Search (FECS), which augments the contrastive search framework with context-aware regularization terms. FECS promotes tokens that are semantically similar to the provided source while penalizing repetitiveness in the generated text. We demonstrate its effectiveness across two tasks prone to hallucination: abstractive summarization and dialogue generation. Results show that FECS consistently enhances faithfulness across various language model sizes while maintaining output diversity comparable to well-performing decoding algorithms.

## introduction language models (lms) have achieved remarkable success in generating human-like text, fostering advancements across numerous natural language processing (nlp) applications. despite the fluent and seemingly convincing outputs produced by lms, these models can occasionally generate content that is factually inconsistent with the provided source @xcite @xcite , an issue known as the hallucination problem @xcite . methods to mitigate hallucination have been explored from various facets, including data perspectives @xcite @xcite , model architectures @xcite @xcite , and training strategies @xcite @xcite . in this work, we turn to a less investigated lens-decoding-to improve faithfulness, foot_0 and introduces a novel decoding method named fidelity-enriched contrastive search (fecs). decoding algorithms can be categorized into deterministic and stochastic groups. deterministic methods such as beam search and greedy decoding aim to generate the most probable text continuations. while these methods might appear to be less unfaithful, they are often degenerated. that is, the outputs are uninformative, monotonous, or repetitive @xcite @xcite . conversely, stochastic methods such as top-k @xcite and nucleus sampling @xcite inject randomness into the generation process, thereby promoting the diversity. yet, these sampling-based approaches often come at the cost of coherency and semantic consistency @xcite @xcite , where increasing the output diversity positively correlates with hallucinating @xcite . to reconcile this faithfulness-diversity trade-off, we proposed fecs-a simple yet effective decoding strategy which extends the contrastive search framework @xcite and introduces context-aware regularization terms to enhance faithfulness and penalize degeneration. specifically, a candidate token which exhibits (1) a great semantic similarity with tokens from the provided source and (2) a low semantic similarity with previously generated tokens is rewarded with a higher score to promote its selection. importantly, fecs can be readily applied to existing lms offthe-shelf, without requiring further training. we evaluate fecs on two tasks particularly prone to text hallucination: abstractive summarization and dialogue generation @xcite . experimental results show that fecs consistently improves faithfulness across various lm sizes while preserving a level of diversity comparable to predominant decoding algorithms. ## methodology in this section, we present preliminary information on contrastive search @xcite before detailing our proposed fecs. ## human evaluation in addition to the automatic evaluation, we also perform human evaluation to assess the faithfulness of our proposed fecs on the abstractive summarization task. we compare fecs against contrastive search, and ask annotators to vote which response is considered more faithful to the provided source (i.e., the text to be summarized). specifically, we randomly sample 20 instance for each of the three model sizes, with a total of 60 instances for the evaluation. more details including the full evaluation protocol are provided in appendix a.2. we present the results in figure 2 . as observed, fecs shows superior results, recording more than 60% of the votes, and outperforms contrastive search with more than twice the votes. the results support ## conclusion this paper introduces a novel decoding approach, fidelity-enriched contrastive search (fecs), designed to enhance faithfulness in text generation. our experimental results on abstractive summarization and dialogue generation demonstrated the efficacy of fecs. it consistently improved faithfulness across various lm scales while preserving a level of diversity that is comparable to other leading decoding algorithms. particularly when using larger lms, it notably enhances faithfulness with only a minor impact on diversity. this indicates that fecs performs effectively when larger lms are employed in dialogue generation tasks. in the future, we plan to explore how fecs performs with different kinds of source content, including erroneous or ambiguous inputs.