arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2610.28187cs.SEcs.LG
收藏

前言:基于雅可比视角的大语言模型测试失败的预生成预测与表征

Foreword: Pre-Generation Prediction and Characterisation of LLM Test Failures using the Jacobian Lens

KAIST(韩国科学技术院);Chalmers University of Technology(查尔姆斯理工大学)

Somin Kim, Robert Feldt, Shin Yoo

AI总结:

本研究提出Foreword框架,基于雅可比视角结合通过与失败参考学习,在10个任务和3个开放权重LLM上,其失败预测与测试优先级排序性能优于现有方法Clotho,且小模型生成的优先级可迁移至专有模型,还能表征失败语义。

摘要:

测试基于大语言模型(LLM)的软件成本高昂:每个输入需要多个采样响应,每个响应都需由成本高昂的预言机评判。此外,每次提示或模型变更都需要重新测试。预生成充分性度量通过基于模型内部状态对输入按失败风险排序来降低这种成本。然而,现有技术Clotho仅对通过的参考输入进行建模,其隐藏状态表示无法说明输入失败的原因。我们提出了Foreword框架,该框架基于两个核心思想:同时从通过和失败的参考中学习,以及通过雅可比视角(J-lens,一种将中间激活读取为词汇标记分数的可解释性技术)表示输入。Foreword将这些表示与两个估计器配对:稀疏逻辑回归探针或双高斯混合模型(dual GMMs),这两个估计器还能生成参考密度(用于标记参考未覆盖的输入)和失败类分量(用于对相似失败进行分组)。在10个任务和3个开放权重LLM上,所有四种表示与估计器的组合在平均性能上均优于Clotho,无论是失败预测(ROC-AUC平均提升0.14,最高提升0.31)还是测试优先级排序(平均在排名前100的输入中多发现15%的失败,最高达33%)。使用小模型获得的优先级排序还能更好地迁移到专有模型(在优先级排序输入的前四分之一中,平均多发现22%的失败,最高达41%)。重要的是,我们的定性案例研究表明,Foreword通过指出标签或任务规范中的歧义,支持对失败进行语义表征。总体而言,Foreword可支持测试人员对输入进行优先级排序、检查对预测的支持以及表征特定失败,且无需生成输出。

英文摘要:

Testing LLM-based software is expensive: each input needs several sampled responses, each judged by a costly oracle. Further, every prompt or model change calls for re-testing. Pre-generation adequacy measures cut this cost by ranking inputs by failure risk based on the model's internal state. However, the state of the art, Clotho, models only passing reference inputs, and its hidden-state representation says nothing about why inputs fail. We present Foreword, a framework built on two ideas: learn from both passing and failing references, and represent inputs through the Jacobian lens (J-lens), an interpretability technique that reads intermediate activations out as scores over vocabulary tokens. Foreword pairs these representations with two estimators: a sparse logistic-regression probe or dual Gaussian Mixture Models (dual GMMs), which also yield a reference density (to flag inputs the references do not cover) and failing-class components (to group similar failures). On ten tasks and three open-weight LLMs, all four combinations of representations and estimators outperform Clotho on average, both for prediction of failure (ROC-AUC improves by 0.14 on average and by up to 0.31) and test prioritisation (15% more failures among the 100 top-ranked inputs on average, up to 33%). Prioritisation obtained using small models also transfers better to proprietary models (on average 22% and up to 41% more failures in the first quarter of prioritised inputs). Importantly, our qualitative case study shows that Foreword supports semantic characterisation of failures by pointing to ambiguities in labels or task specifications. Combined, Foreword can support testers for prioritising inputs, checking support for a prediction, and characterising specific failures, all without generating output.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑