Selecting What Matters: Semantic Compression-Guided Selective Pooling for Long-Context Embeddings

Zifeng Cheng, Jie Zheng, Zhiwei Jiang, Shuwen Wang, Fei Shen +2 more
9/29/2026
cs.CL

No confident code implementation found for this paper.

Abstract

Large language models (LLMs) have shown strong potential as training-free text encoders for long-context embeddings. Existing approaches primarily improve information flow under causal attention and typically construct embeddings by uniformly averaging all token representations. However, for long documents, such mean pooling can dilute salient semantic information with abundant redundant or weakly informative content. To this end, we propose SCSP, a training-free framework that leverages semantic compression for informative token selection in long-context embedding. Specifically, SCSP first partitions a document into sentence-aware chunks and appends a semantic compression prompt to each chunk. A prompt-isolated attention mask preserves information flow among document tokens while restricting each prompt to its corresponding local context. We then use the attention patterns elicited by these prompts to estimate token importance, select informative tokens, and aggregate their intermediate-layer representations into the final embedding. Extensive experiments on long-context embedding benchmarks demonstrate that SCSP can be integrated into both zero-shot and fine-tuned models in a plug-and-play manner, consistently improving their performance.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{cheng2026selecting,
  title  = {Selecting What Matters: Semantic Compression-Guided Selective Pooling for Long-Context Embeddings},
  author = {Zifeng Cheng and Jie Zheng and Zhiwei Jiang and Shuwen Wang and Fei Shen and Shiping Ge and Qing Gu},
  year   = {2026},
  eprint = {2609.37782},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2609.37782v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2609.37782.svg)](https://codeofpaper.com/paper/2609.37782)

Discussion