arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2603.13950cs.CL
收藏

ToolFlood: 超越选择 -- 通过语义覆盖隐藏有效工具于LLM代理

ToolFlood: Beyond Selection -- Hiding Valid Tools from LLM Agents via Semantic Covering

Hussein Jawad, Nicolas J-B Brunel

AI总结:

研究针对LLM代理的检索层攻击,通过语义覆盖注入恶意工具,使有效工具被排除在外,实验显示攻击成功率高达95%。

摘要:

大型语言模型(LLM)代理越来越多地使用外部工具进行复杂任务,并依赖基于嵌入的检索来选择一小部分top-k工具进行推理。随着这些系统的发展,检索阶段的鲁棒性被忽视,尽管先前工作已研究了对工具选择的攻击。本文介绍了ToolFlood,一种针对工具增强LLM代理的检索层攻击。而非改变检索后选择的工具,ToolFlood通过注入少量由攻击者控制的工具,利用嵌入空间的几何特性,使这些工具语义覆盖许多用户查询,主导top-k结果,并将所有良性工具推离代理的上下文。ToolFlood采用两阶段对抗性工具生成策略。首先,从目标查询中采样子集,并使用LLM迭代生成多样化的工具名称和描述。然后,运行迭代贪心选择,选择在嵌入空间中最大化剩余查询覆盖的工具,受余弦距离阈值限制,直到所有查询被覆盖或预算耗尽。我们提供了检索饱和的理论分析,并在标准基准上证明,ToolFlood在低注入率(1%在ToolBench)下达到高达95%的攻击成功率。代码将在以下链接公开:https://github.com/as1-prog/ToolFlood

英文摘要:

Large Language Model (LLM) agents increasingly use external tools for complex tasks and rely on embedding-based retrieval to select a small top-$k$ subset for reasoning. Prior work on attacking these systems competes for tool selection, assuming benign tools remain in the retrieved set; the robustness of the retrieval stage that produces this set is underexplored. This paper introduces ToolFlood, a retrieval-layer attack on tool-augmented LLM agents. Rather than altering which tool is chosen after retrieval, ToolFlood attacks retrieval itself: it injects a few attacker-controlled tools whose metadata is positioned to exploit the geometry of embedding space, so that these tools semantically span many user queries, dominate the top-k results, and push all benign tools out of the agent's context. ToolFlood uses a two-phase adversarial tool generation strategy. It first samples subsets of target queries and uses an LLM to iteratively generate diverse tool names and descriptions. It then runs an iterative greedy selection that chooses tools maximizing coverage of remaining queries in embedding space under a cosine-distance threshold, stopping when all queries are covered or a budget is reached. We provide theoretical intuition of retrieval saturation and show on a large catalog (ToolBench) that ToolFlood achieves up to a 95\% attack success rate with a ~1\% injection rate. The code is available at: https://github.com/as1-prog/ToolFlood

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

↑