MCPHallu:针对MCP智能体中推理、执行与记忆幻觉的基准测试
MCPHallu: Benchmarking Reasoning, Execution, and Memory Hallucinations in MCP Agents
AI总结:
本研究推出MCPHallu基准测试,涵盖推理、执行、记忆三个维度,含358个任务,评估14款LLM智能体,发现其在不可达目标任务表现差,子类型排名差异大,为MCP智能体幻觉研究提供工具。
摘要:
大型语言模型智能体正越来越多地通过模型上下文协议(Model Context Protocol,MCP)部署,该协议允许智能体在运行时发现并调用跨多个服务器的工具。现有的MCP基准测试主要衡量任务完成情况;在诊断失败时,它们是在执行之后进行的,而非在任务构建中纳入特定的推理、执行与记忆失败风险。我们推出MCPHallu,这是一个用于诊断MCP环境中易出现幻觉的智能体失败的基准测试,涵盖三个维度:推理、执行与记忆。MCPHallu包含五个能力领域的358个任务,在隔离容器中运行于36个生产级MCP服务器上。每个任务都设计有一个结构触发器,使四种子类型之一成为主要失败风险:分支崩溃(Branch Collapse)、不可达目标(Unreachable Goal)、工具误用(Tool Misuse)或上下文遗忘(Context Forgetting)。这种设计支持子类型层面的分析,而非仅依赖总体任务成功率。我们评估了来自八个厂商的14个前沿LLM智能体,共进行5012条轨迹测试。当前的MCP智能体仍易受幻觉诱导的工具环境影响,在[0,1]量表上的平均得分为0.642(分数越高越好)。失败集中在不可达目标任务上,该类任务的平均得分降至0.458,仅23.2%的运行通过,表明智能体往往会继续发出工具调用或声称成功完成,而非识别出不可行的目标。子类型排名差异显著:模型的排名在各子类型间平均变化13个位置中的6.9位,且分支崩溃与不可达目标在模型间无相关性(r=-0.12)。MCPHallu已在此URL发布。
英文摘要:
Large language model agents are increasingly deployed through the Model Context Protocol (MCP), which allows them to discover and invoke tools across multiple servers at runtime. Existing MCP benchmarks primarily measure task completion; where they diagnose failures, they do so after execution rather than building specific reasoning, execution, and memory failure risks into task construction. We introduce MCPHallu, a benchmark for diagnosing hallucination-prone agent failures in MCP environments along three axes: reasoning, execution, and memory. MCPHallu contains 358 tasks across five capability domains and runs on 36 production MCP servers in isolated containers. Each task is designed with a structural trigger that makes one of four subtypes the dominant failure risk: Branch Collapse, Unreachable Goal, Tool Misuse, or Context Forgetting. This design enables subtype-level analysis rather than aggregate task success alone. We evaluate fourteen frontier LLM agents from eight vendors on 5{,}012 trajectories. Current MCP agents remain vulnerable to hallucination-inducing tool environments, achieving an average score of 0.642 on a $[0,1]$ scale (higher is better). Failures concentrate on Unreachable Goal tasks, where the average score drops to 0.458 and 23.2\% of runs pass, indicating that agents often continue issuing tool calls or claim successful completion rather than recognizing infeasible goals. Subtype rankings diverge sharply: a model's rank shifts by 6.9 of 13 positions on average across subtypes, and Branch Collapse is uncorrelated with Unreachable Goal across models ($r = -0.12$). MCPHallu is released at https://github.com/J1zz/mcp_hallu.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。