arXiv:2606.10125stat.MLcs.DB2026-06

用主动学习选少样本例子,让大模型更准更省力。

Robust Active Learning for Few-Shot Example Selection in Text-to-SQL

论文配图:Robust Active Learning for Few-Shot Example Selection in Text-to-SQL
图 1 · 摘自论文原文
  • 分层贪心算法优化语义嵌入空间中的信息量选择
  • 减少标注量同时保持文本转SQL的高准确率
  • 适合需要高效标注的低资源数据库查询系统

少样本示例检索是将大语言模型(LLMs)应用于领域特定文本转SQL系统的主要范式。然而,标注示例库的质量直接决定系统准确性,而专家标注成本过高。本文将这些示例的主动选择形式化为语义查询嵌入内在低维流形上的约束实验设计问题。与标准主动学习框架不同,本设置面临三个关键挑战:依赖查询的标注可靠性差异(异方差性)、跨语义主题的空间多样性严格要求(划分拟阵约束),以及嵌入空间真实协方差结构未知(模型误设)。为此,我们提出一种分层贪心算法,最大化异方差互信息目标。我们证明该目标在内在流形上保持次模性且近似单调,从而获得理论上的常数倍近似保证。我们建立了谱界,表明当假设的代理核与真实数据生成过程偏离时,该近似保证仅渐进退化而非灾难性崩溃。实验证明,所提策略显著降低标注代价,同时维持高文本转SQL检索准确率。

原文摘要 · Abstract (English)

Few-shot example retrieval is the dominant paradigm for grounding large language models (LLMs) in domain-specific text-to-SQL systems. However, the quality of the annotated example bank directly governs system accuracy, and expert annotation is prohibitively expensive. We formalize the active selection of these examples as a constrained experimental design problem over the intrinsic, low-dimensional manifold of semantic query embeddings. Unlike standard active learning frameworks, our setting introduces three critical challenges: varying, query-dependent annotation reliability (heteroscedasticity), strict requirements for spatial diversity across semantic topics (partition matroid constraints), and the inherent reality that the true covariance structure of the embedding space is unknown (misspecification). To address these, we propose a stratified greedy algorithm that maximizes a heteroscedastic mutual information objective. We prove that this objective remains submodular and approximately monotonic on the intrinsic manifold, yielding a theoretical constant-factor approximation guarantee. We establish a spectral bound demonstrating that this approximation guarantee degrades gracefully, rather than catastrophically, when the assumed surrogate kernel diverges from the true underlying data-generating process. Empirical results demonstrate that the proposed strategy significantly reduces labeling effort while maintaining high text-to-SQL retrieval accuracy.

主动学习文本转SQL少样本学习大模型

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