Efficient and Effective In-context Demonstration Selection with Coreset

Zihua Wang, Jiarui Wang, Haiyang Xu, Ming Yan, Fei Huang +4 more
11/12/2025
cs.CV

No confident code implementation found for this paper.

Abstract

In-context learning (ICL) has emerged as a powerful paradigm for Large Visual Language Models (LVLMs), enabling them to leverage a few examples directly from input contexts. However, the effectiveness of this approach is heavily reliant on the selection of demonstrations, a process that is NP-hard. Traditional strategies, including random, similarity-based sampling and infoscore-based sampling, often lead to inefficiencies or suboptimal performance, struggling to balance both efficiency and effectiveness in demonstration selection. In this paper, we propose a novel demonstration selection framework named Coreset-based Dual Retrieval (CoDR). We show that samples within a diverse subset achieve a higher expected mutual information. To implement this, we introduce a cluster-pruning method to construct a diverse coreset that aligns more effectively with the query while maintaining diversity. Additionally, we develop a dual retrieval mechanism that enhances the selection process by achieving global demonstration selection while preserving efficiency. Experimental results demonstrate that our method significantly improves the ICL performance compared to the existing strategies, providing a robust solution for effective and efficient demonstration selection.

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{wang2025efficient,
  title  = {Efficient and Effective In-context Demonstration Selection with Coreset},
  author = {Zihua Wang and Jiarui Wang and Haiyang Xu and Ming Yan and Fei Huang and Xu Yang and Xiu-Shen Wei and Siya Mi and Yu Zhang},
  year   = {2025},
  eprint = {2511.08977},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2511.08977v1}
}

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/2511.08977.svg)](https://codeofpaper.com/paper/2511.08977)

Discussion