arXiv:2410.11786cs.CLcs.AI2024-10EMNLP被引 9

提出自监督提示压缩方法,提升模型泛化与效率

Selection-p: Self-Supervised Task-Agnostic Prompt Compression for Faithfulness and Transferability

  • 通过自监督预训练,为每个输入标记生成保留或丢弃概率
  • 压缩率最高达10倍,性能仅下降0.8%且跨模型迁移性强
  • 适用于多种任务,尤其适合长上下文场景下保持推理质量

大型语言模型(LLMs)在利用上下文学习时展现出强大能力。为降低上下文学习带来的计算与成本开销,已有多种提示压缩方法被提出。然而,这些方法常因模型特定压缩策略导致泛化性差,或依赖外部训练数据(如GPT-4)。本文研究了LLM通过自监督预训练实现统一压缩的能力,提出一种离散化无信息标记的机制。通过在持续预训练中引入少量参数,Selection-p为每个输入标记生成保留/丢弃概率。实验表明,该方法在多个分类任务上达到当前最优性能,压缩率最高达10倍,性能仅下降0.8%,且对不同模型表现出更强的迁移能力。此外,我们进一步分析其在长上下文场景中维持上下文学习性能的作用。

原文摘要 · Abstract (English)

Large Language Models (LLMs) have demonstrated impressive capabilities in a wide range of natural language processing tasks when leveraging in-context learning. To mitigate the additional computational and financial costs associated with in-context learning, several prompt compression methods have been proposed to compress the in-context learning prompts. Despite their success, these methods face challenges with transferability due to model-specific compression, or rely on external training data, such as GPT-4. In this paper, we investigate the ability of LLMs to develop a unified compression method that discretizes uninformative tokens, utilizing a self-supervised pre-training technique. By introducing a small number of parameters during the continual pre-training, the proposed Selection-p produces a probability for each input token, indicating whether to preserve or discard it. Experiments show Selection-p achieves state-of-the-art performance across numerous classification tasks, achieving compression rates of up to 10 times while experiencing only a marginal 0.8% decrease in performance. Moreover, it exhibits superior transferability to different models compared to prior work. Additionally, we further analyze how Selection-p helps maintain performance on in-context learning with long contexts.

提示压缩自监督模型迁移大模型

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。