arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2610.24048cs.CLcs.AIcs.CR
收藏

推理过程中的窗口:当大语言模型智能体决定遵循提示注入时

The Window Is in the Reasoning: When LLM Agents Decide to Follow Prompt Injections

Fullive-AI;Nanyang Technological University(南洋理工大学);Peking University(北京大学);University of Chinese Academy of Sciences(中国科学院大学);Soochow University(苏州大学);Beijing University of Posts and Telecommunications(北京邮电大学);University of Leeds(利兹大学);Beihang University(北京航空航天大学)
Haoxuan Jia, Yang Liu, Bin Chong, Yingguang Yang, Yancheng Chen, Jiayu Liang, Qian Li, Hanning Lu, Kefu Xu, Hao Zheng, Chongyang Zhang, Yulin Huang, Jianshen Zh… 展开作者

Haoxuan Jia, Yang Liu, Bin Chong, Yingguang Yang, Yancheng Chen, Jiayu Liang, Qian Li, Hanning Lu, Kefu Xu, Hao Zheng, Chongyang Zhang, Yulin Huang, Jianshen Zhang, Yongzhi Qi, Yunuo Lin, Hao Peng

AI总结:

该研究针对LLM智能体被提示注入劫持的问题,通过分支回滚测试假设,发现开启思考会改变结果方差的读取时占比,且单次运行基准存在较高不一致性,需多次运行。

摘要:

读取不可信内容的大语言模型(LLM)智能体可能会被提示注入劫持。运行时监控器试图在智能体行动前检测劫持,以及用单次运行对每个任务评分的基准测试,都基于一个假设:智能体是否遵循注入指令在读取注入时就已确定。我们通过分支回滚测试该假设,该方法会精确重放某一情节直至智能体读取注入的步骤,随后多次重新采样该情节的剩余部分,将结果方差拆分为读取时固定的部分和之后决定的部分。在四个AgentDojo套件中,未开启思考的Qwen3智能体的结果方差有0.91处于读取时确定的状态;开启思考后,该比例降至0.62(下降的95%置信区间为[-0.38, -0.22]),且在三种攻击模板和两个成功标签中方向一致。读取时固定的程度是模型的属性,该测量可揭示这一点,且思考会降低Qwen3的攻击成功率,但会提高另外两种模型的攻击成功率。从推理前缀重新采样显示,决策会随着智能体的推理逐渐形成。基于更廉价模型构建的零样本思维链监控器会错过许多已确定的内容,而更强的监控器以及判断模拟下一个行动的前瞻监控器,会接近前缀确定的内容。最后,开启思考的智能体的单次运行标签与重新运行的标签有高达35%的不一致,因此基准测试需要对每个任务进行多次运行。

英文摘要:

LLM agents that read untrusted content can be hijacked by prompt injections. Runtime monitors that try to catch a hijack before the agent acts, and benchmarks that score each task with a single run, share an assumption: whether an agent follows an injection is settled when the injection is read. We test this assumption with branching rollouts that replay an episode exactly up to the step at which the agent reads an injection and then resample the rest of the episode many times, splitting the outcome variance into a part fixed at read time and a part decided afterwards. Across four AgentDojo suites, a Qwen3 agent without thinking is largely decided at read time (0.91 of the outcome variance lies between states); with thinking on, this share drops to 0.62 (95% CI of the drop [-0.38, -0.22]), in the same direction for three attack templates and two success labels. How much is fixed at read time is a property of the model that the same measurement reveals, and thinking lowers the attack success rate of Qwen3 but raises it for two other models. Resampling from reasoning prefixes shows that the decision forms gradually as the agent reasons. Zero-shot chain-of-thought monitors built on cheaper models miss much of what is already decided, whereas stronger monitors, and a lookahead monitor that judges simulated next actions, come close to what the prefix determines. Finally, single-run labels of thinking agents disagree with a rerun up to 35% of the time, so benchmarks need repeated runs per task.

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

↑