Salvato in:
Dettagli Bibliografici
Autori principali: Cao, Yun-Hao, Wang, Yangsong, Hao, Shuzheng, Li, Zhenxing, Zhan, Chengjun, Liu, Sichao, Hu, Yi-Qi
Natura: Preprint
Pubblicazione: 2025
Soggetti:
Accesso online:https://arxiv.org/abs/2503.07956
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866916649469214720
author Cao, Yun-Hao
Wang, Yangsong
Hao, Shuzheng
Li, Zhenxing
Zhan, Chengjun
Liu, Sichao
Hu, Yi-Qi
author_facet Cao, Yun-Hao
Wang, Yangsong
Hao, Shuzheng
Li, Zhenxing
Zhan, Chengjun
Liu, Sichao
Hu, Yi-Qi
contents The emergence of large language models (LLMs) like GPT-4 has revolutionized natural language processing (NLP), enabling diverse, complex tasks. However, extensive token counts lead to high computational and financial burdens. To address this, we propose Efficient and Flexible Prompt Compression (EFPC), a novel method unifying task-aware and task-agnostic compression for a favorable accuracy-efficiency trade-off. EFPC uses GPT-4 to generate compressed prompts and integrates them with original prompts for training. During training and inference, we selectively prepend user instructions and compress prompts based on predicted probabilities. EFPC is highly data-efficient, achieving significant performance with minimal data. Compared to the state-of-the-art method LLMLingua-2, EFPC achieves a 4.8% relative improvement in F1-score with 1% additional data at a 4x compression rate, and an 11.4% gain with 10% additional data on the LongBench single-doc QA benchmark. EFPC's unified framework supports broad applicability and enhances performance across various models, tasks, and domains, offering a practical advancement in NLP.
format Preprint
id arxiv_https___arxiv_org_abs_2503_07956
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle EFPC: Towards Efficient and Flexible Prompt Compression
Cao, Yun-Hao
Wang, Yangsong
Hao, Shuzheng
Li, Zhenxing
Zhan, Chengjun
Liu, Sichao
Hu, Yi-Qi
Computation and Language
Artificial Intelligence
The emergence of large language models (LLMs) like GPT-4 has revolutionized natural language processing (NLP), enabling diverse, complex tasks. However, extensive token counts lead to high computational and financial burdens. To address this, we propose Efficient and Flexible Prompt Compression (EFPC), a novel method unifying task-aware and task-agnostic compression for a favorable accuracy-efficiency trade-off. EFPC uses GPT-4 to generate compressed prompts and integrates them with original prompts for training. During training and inference, we selectively prepend user instructions and compress prompts based on predicted probabilities. EFPC is highly data-efficient, achieving significant performance with minimal data. Compared to the state-of-the-art method LLMLingua-2, EFPC achieves a 4.8% relative improvement in F1-score with 1% additional data at a 4x compression rate, and an 11.4% gain with 10% additional data on the LongBench single-doc QA benchmark. EFPC's unified framework supports broad applicability and enhances performance across various models, tasks, and domains, offering a practical advancement in NLP.
title EFPC: Towards Efficient and Flexible Prompt Compression
topic Computation and Language
Artificial Intelligence
url https://arxiv.org/abs/2503.07956