arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2501.07824cs.CLcs.AIcs.LG
收藏

语言模型文本生成的高效实时精炼

Efficient Real-time Refinement of Language Model Text Generation

KAIST(韩国科学技术院)

Joonho Ko, Jinheon Baek, Sung Ju Hwang

AI总结:

本文提出Streaming-VR方法,在LLM逐标记生成过程中由另一LLM实时验证和纠正错误,以提升事实准确性并显著提高精炼效率。

摘要:

大型语言模型(LLMs)在广泛的自然语言任务中展现了卓越的性能。然而,一个关键的挑战仍然存在,即它们有时会生成事实错误的答案。为了解决这一问题,虽然许多先前的工作侧重于识别其生成中的错误并进一步精炼,但它们在部署上较慢,因为这些方法被设计为仅在LLMs完成整个生成(从第一个到最后一个标记)之后才验证其响应。此外,我们观察到,一旦LLMs在早期生成了错误的标记,后续标记也更有可能在事实上不正确。为此,在这项工作中,我们提出了Streaming-VR(流式验证与精炼),这是一种旨在提高LLM输出验证和精炼效率的新方法。具体来说,所提出的Streaming-VR能够在标记生成的同时进行即时验证和纠正,类似于流式处理过程,确保在LLM构建其响应时,每个标记子集都由另一个LLM实时检查和精炼。通过在多个数据集上的全面评估,我们证明了我们的方法不仅提高了LLMs的事实准确性,而且与先前的精炼方法相比,提供了一种更高效的解决方案。

英文摘要:

Large language models (LLMs) have shown remarkable performance across a wide range of natural language tasks. However, a critical challenge remains in that they sometimes generate factually incorrect answers. To address this, while many previous work has focused on identifying errors in their generation and further refining them, they are slow in deployment since they are designed to verify the response from LLMs only after their entire generation (from the first to last tokens) is done. Further, we observe that once LLMs generate incorrect tokens early on, there is a higher likelihood that subsequent tokens will also be factually incorrect. To this end, in this work, we propose Streaming-VR (Streaming Verification and Refinement), a novel approach designed to enhance the efficiency of verification and refinement of LLM outputs. Specifically, the proposed Streaming-VR enables on-the-fly verification and correction of tokens as they are being generated, similar to a streaming process, ensuring that each subset of tokens is checked and refined in real-time by another LLM as the LLM constructs its response. Through comprehensive evaluations on multiple datasets, we demonstrate that our approach not only enhances the factual accuracy of LLMs, but also offers a more efficient solution compared to prior refinement methods.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑