arrow
Return

Parse Trees Guided LLM Prompt Compression

delete2025-09-15
delete0
PRE
AI
W
Wenhao Mao
侯
侯诚彬 (Chengbin Hou)
T
Tianyu Zhang
X
Xinyu Lin
汤
汤珂 (Ke Tang)
H
Hairong Lv
DOI:10.1109/TPAMI.2025.3609956delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
Offering rich contexts to Large Language Models (LLMs) has shown to boost the performance in various tasks, but the resulting longer prompt would increase the computational cost and might exceed the input limit of LLMs. Recently, some prompt compression methods have been suggested to shorten the length of prompts by using language models to generate shorter prompts or by developing computational models to select important parts of original prompt. The generative compression methods would suffer from issues like hallucination, while the selective compression methods have not involved linguistic rules and overlook the global structure of prompt. To this end, we propose a novel selective compression method called PartPrompt. It first obtains a parse tree for each sentence based on linguistic rules, and calculates local information entropy for each node in a parse tree. These local parse trees are then organized into a global tree according to the hierarchical structure such as the dependency of sentences, paragraphs, and sections. After that, the root-ward propagation and leaf-ward propagation are proposed to adjust node values over the global tree. Finally, a recursive algorithm is developed to prune the global tree based on the adjusted node values. The experiments show that PartPrompt receives the state-of-the-art performance across various datasets, metrics, compression ratios, and target LLMs for inference. The in-depth ablation studies confirm the effectiveness of designs in PartPrompt, and other additional experiments also demonstrate its superiority in terms of the coherence of compressed prompts and in the extreme long prompt scenario.
Keywords:
Large language models
prompt compression
parse trees
prompt structure
text pattern analysis

Journal

IEEE Transactions on Pattern Analysis and Machine Intelligence cover
IEEE Transactions on Pattern Analysis and Machine Intelligence
IF:
18.6
Papers:
1.1K
Citations:
9.8W

Organization

T
tsinghua university
Scholars:
11.9W
Papers: 10.0W
Citations: 137
S
Southern University of Science and Technology
Scholars:
5.2K
Papers: 2.1K
Citations: 34
F
Fuyao University of Science and Technology
Scholars:
110
Papers: 89
Citations: 6
researcher View more organizations
Cited Papers

Cited Papers

BLEU
err2001-01-01
err0
errOAAI
errKishore Papineni; Salim Roukos; Todd Ward; Wei-Jing Zhu
errShare
errSave
LongBench: A Bilingual, Multitask Benchmark for Long Context Understanding
err2024-01-01
err0
PREAI
errYushi Bai; Xin Lv; Jiajie Zhang; Hongchang Lyu; Jiankai Tang; Zhidian Huang; Zhengxiao Du; Xiao Liu; Aohan Zeng; Lei Hou; Yuxiao Dong; Jie Tang; Juanzi Li
errShare
errSave
A Survey on In-context Learning
err2024-01-01
err0
PREAI
errQingxiu Dong; Lei Li; Damai Dai; Ce Zheng; Jingyuan Ma; Rui Li; Heming Xia; Jingjing Xu; Zhiyong Wu; Baobao Chang; Xu Sun; Lei Li; Zhifang Sui
errShare
errSave
errShare
errSave
SG-Net: Syntax Guided Transformer for Language Representation
err2022-06-01
err0
errOAAI
errZhuosheng Zhang; Yuwei Wu; Junru Zhou; Sufeng Duan; Hai Zhao; Rui Wang
errShare
errSave
LLMLingua-2: Data Distillation for Efficient and Faithful Task-Agnostic Prompt Compression
err2024-01-01
err0
PREAI
errZhuoshi Pan; Qianhui Wu; Huiqiang Jiang; Menglin Xia; Xufang Luo; Jue Zhang; Qingwei Lin; Victor Rühle; Yuqing Yang; Chin-Yew Lin; H. Vicky Zhao; Lili Qiu; Dongmei Zhang
errShare
errSave
errShare
errSave
Text Compression-aided Transformer Encoding
err2021-01-01
err0
errOAAI
errZuchao Li; Zhuosheng Zhang; Hai Zhao; Rui Wang; Kehai Chen; Masao Utiyama; Eiichiro Sumita
errShare
errSave
researcher View more