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

RITFIS:面向基于大语言模型的智能软件的鲁棒输入测试框架

RITFIS: Robust input testing framework for LLMs-based intelligent software

College of Computer Science and Software Engineering, Hohai University(河海大学计算机与软件学院);School of Cyber Science and Technology, Shenzhen Campus of Sun Yat-sen University(中山大学深圳校区网络空间科学与技术学院);School of Computing Technologies, RMIT University(RMIT大学计算技术学院)

Mingxuan Xiao, Yan Xiao, Hai Dong, Shunhui Ji, Pengcheng Zhang

AI总结:

本文提出首个面向基于LLM的智能软件自然语言输入鲁棒性测试框架RITFIS,将测试建模为组合优化问题,适配17种自动化测试方法并基于五项指标给出优化策略。

摘要:

自然语言处理(NLP)智能软件对大语言模型(LLMs)的依赖日益突出,凸显了鲁棒性测试的必要性。当前的测试方法仅关注基于LLM的软件对提示词(prompts)的鲁棒性。鉴于现实世界输入的复杂性和多样性,研究基于LLM的软件在处理综合输入(包括提示词和示例)时的鲁棒性,对于全面理解其性能至关重要。为此,本文提出了RITFIS,一个面向基于LLM的智能软件的鲁棒输入测试框架。据我们所知,RITFIS是首个旨在评估基于LLM的智能软件对自然语言输入鲁棒性的框架。该框架基于给定的威胁模型和提示词,主要将测试过程定义为一个组合优化问题。成功的测试用例由目标函数确定,通过扰动手段为原始示例创建变换空间,并采用一系列搜索方法筛选出同时满足测试目标和语言约束的用例。RITFIS凭借其模块化设计,为评估基于LLM的智能软件的鲁棒性提供了一种全面的方法。RITFIS将17种最初为基于深度神经网络(DNN)的智能软件设计的自动化测试方法适配到基于LLM的软件测试场景中。通过实证验证,证明了RITFIS在评估基于LLM的智能软件方面的有效性。然而,现有方法普遍存在局限性,尤其是在处理长文本和结构复杂的威胁模型时。因此,我们基于五项指标进行了全面分析,并提供了具有洞察力的测试方法优化策略,使研究人员和日常用户都能从中受益。

英文摘要:

The dependence of Natural Language Processing (NLP) intelligent software on Large Language Models (LLMs) is increasingly prominent, underscoring the necessity for robustness testing. Current testing methods focus solely on the robustness of LLM-based software to prompts. Given the complexity and diversity of real-world inputs, studying the robustness of LLMbased software in handling comprehensive inputs (including prompts and examples) is crucial for a thorough understanding of its performance. To this end, this paper introduces RITFIS, a Robust Input Testing Framework for LLM-based Intelligent Software. To our knowledge, RITFIS is the first framework designed to assess the robustness of LLM-based intelligent software against natural language inputs. This framework, based on given threat models and prompts, primarily defines the testing process as a combinatorial optimization problem. Successful test cases are determined by a goal function, creating a transformation space for the original examples through perturbation means, and employing a series of search methods to filter cases that meet both the testing objectives and language constraints. RITFIS, with its modular design, offers a comprehensive method for evaluating the robustness of LLMbased intelligent software. RITFIS adapts 17 automated testing methods, originally designed for Deep Neural Network (DNN)-based intelligent software, to the LLM-based software testing scenario. It demonstrates the effectiveness of RITFIS in evaluating LLM-based intelligent software through empirical validation. However, existing methods generally have limitations, especially when dealing with lengthy texts and structurally complex threat models. Therefore, we conducted a comprehensive analysis based on five metrics and provided insightful testing method optimization strategies, benefiting both researchers and everyday users.

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

↑