LLM 裁判也会产生幻觉:ZoomInfo 如何验证智能体的动作
原题Your LLM Judge Is Hallucinating Too — Brian Kennedy, ZoomInfo
看前速览
ZoomInfo 审核了 LLM 裁判在生产中的判定,并用影子模式验证七个可以直接从工具回执回答的问题。
自信的报告掩盖了失败的动作
智能体声称安排了邮件,裁判照样批准。实际上 Salesforce 建记录失败,智能体只创建了待办。500 个抽样步骤中有 118 个被错误放行。
问题要能用工具结果回答
Jev 读取指令、输入、工具调用及结果和智能体报告,回答七个是非题,为通过、重做或停止提供理由。把握不够时交回 LLM。
先用影子模式测试
Jev 发现了 728 个工具失败步骤中的 623 个,原裁判发现 294 个。会虚报邮件安排成功的步骤运行了 1,081 次,Jev 识别出 876 次,LLM 只识别出一次。
按工具的作用增加后置检查
发送后可以核实消息是否送达,写入后可以查记录是否存在。团队计划在同一次调用里加上这些问题,与通用的七个问题一起作答。
完整摘要
智能体说邮件已经安排发送,实际 Salesforce 调用失败,它也没有发邮件的工具,ZoomInfo 的 LLM 裁判却批准了这一步。团队审核了 500 个生产步骤,裁判与复核标签的一致率只有 65%,其中 118 次本不该通过。他们改用 Jev 根据工具结果回答一组短问题,接受概率达到 30% 就通过,低至 5% 就重做或停止,中间区间交回 LLM。在 37,000 次影子判定中,Jev 发现了 728 个工具失败步骤中的 623 个,原裁判只发现 294 个。Brian Kennedy 还介绍了这套部署中快 10 倍、成本降至四十分之一的结果,以及团队计划增加的工具后置检查。
文字稿
简要描述Brief Description
Brian Kennedy 详细介绍了 ZoomInfo 的一个生产环境案例:某个智能体声称自己安排发送了一封电子邮件,而一位 LLM 评审器认可了这一说法。他解释了团队如何审计该评审器、测试一组规模较小且以工具结果为依据的检查项,并在影子模式下比较这两种方法。Brian Kennedy walks through a ZoomInfo production example in which an agent claimed it scheduled an email and an LLM judge approved the claim. He explains how his team audited the judge, tested a smaller set of checks grounded in tool results, and compared both approaches in shadow mode.
目录Table of Contents
- 一封从未发送的电子邮件An email that was never sent
- ZoomInfo 智能体团队Agent Teams at ZoomInfo
- 每种工作,都有一位评审。One judge for every kind of job
- 法官有 65% 的时候是正确的The judge was right 65% of the time
- 说法与证据The story vs the receipts
- 改为一些简单的是非题Small yes-or-no questions instead
- 一次调用回答七个问题Seven questions in one call
- 阈值与 LLM 回退机制Thresholds and an LLM fallback
- 影子模式:37,000 次决策Shadow mode: 37,000 decisions
- 速度提升 10 倍,成本降低 40 倍10x faster, 40x cheaper
- 后置条件检查Post-condition checks
- 你今天可以做的事What you can do today
一封从未发送的邮件An email that was never sent
大家下午好。我是 Brian Kennedy,是 ZoomInfo 智能体平台的一名工程师。现在,我想先给大家看看我们的一位智能体生成的内容。这是我们产品实际生成的结果。这个智能体的任务是为客户安排一封邮件。它给出的反馈是:邮件已安排好,已加入队列,将于周二发出。 不过,我们不会只相信智能体的说法。另一个模型会检查智能体的工作。我把这个模型称为“裁判”。裁判读了这段内容,并判定它没问题。很好。 现在,问题来了。实际发生的是这样的。这些是工具返回的结果,也就是智能体调用工具时实际执行情况的记录。我把它们称为“凭证”。智能体尝试在 Salesforce 中创建一条记录,但失败了。Good afternoon, everybody. I am Brian Kennedy. I'm an engineer on ZoomInfo's agentic platform. Now, I want to start with showing you something one of our agents wrote. This is a real output from our product. The agent's job was to schedule an email for a customer. And this is what it reported back. It said it scheduled the email, it queued it up, and that it was going to go out on Tuesday. We don't just trust the agent, though. A second model checks the agent's work. I'm going to call this one the judge. The judge read this and it accepted it. Great. Now, here's the problem. Here’s what actually happened. These are the tool results, the record of what actually ran when the agent called the tools. I'm going to call these the receipts. The agent tried to create a record in Salesforce and it failed.
返回的错误消息说记录并未创建,并告诉智能体不要报告成功,也不要捏造记录。这条消息正是我们针对这种情况专门编写的。智能体又试了一次。它创建了一个任务,也就是一项待办事项。邮件从未被安排发送过。智能体甚至没有发送邮件的工具。它却捏造了这件事,而评审模型还批准了。所以这是两次失败:智能体捏造了邮件已发送,评审模型则不假思索地盖章通过,批准了一项它根本没有核实过的说法。如果你在构建智能体,你大概也遇到过这种情况,也用过类似这样的评审模型。它可能是代码审查器、评测结果的评分器,或者工作流中的监督器。只要一个模型要判断另一个模型的工作是否合格,这种情况就可能发生。接下来我会告诉你我们是如何发现这个问题的,以及为此采取了哪些措施。The error message that came back says the record was not created and it tells the agent not to report a success or even make up a record. We wrote this message ourselves for exactly this situation. The agent tried again. It created a task, which is a to-do. No email was ever scheduled. The agent doesn't even have a tool that can send an email. The agent made it up and the judge approved it. So that's two failures. The agent fabricated a send and the judge rubber-stamped it, approving a claim it never actually checked. So if you build agents, you’ve probably run into this and have a judge like this. It might be a code reviewer or a grader of your evals or a supervisor in your loop. Anytime a model decides whether another model's work is good, this can happen. I’ll show you how we caught this and what we did about it.
ZoomInfo 的智能体团队Agent Teams at ZoomInfo
首先,简单介绍一下背景。我在 ZoomInfo 的团队叫作 Agent Teams。我们上周宣布了这一产品。它是一个多智能体编排层,运行在 ZoomInfo 的 GTM Studio 中,负责协调公司系统中的一组专业智能体来执行 GTM 工作流。例如,查找公司、调查这些公司、撰写邮件,并将邮件记录到相应的 CRM 中。每个智能体都有自己的角色、指令和工具,例如 Salesforce、HubSpot 和 Slack。这些智能体会做出真正的决策,并在客户的系统中采取实际行动。First, some quick background. My team at ZoomInfo is called Agent Teams. We announced this last week. It's a multi-agent orchestration layer that lives in ZoomInfo's GTM Studio. It coordinates a team of specialized agents across the company's systems to run GTM workflows. For example, find companies, research them, write an email, log it into their CRM. Each agent has its own roles, instructions, and tools like Salesforce, HubSpot, Slack. These agents make real decisions and take real actions in the customer's systems.
它们会写入记录并发送消息。每当一个团队或智能体完成一个步骤,另一个模型就会检查其工作。这就是评判模型,它有三种选择:继续、重做该步骤,或彻底停止任务。你可能听说过这种做法叫作“LLM-as-a-judge”(让大语言模型充当评判者)。这和代码审查员或评测评分器的概念相同。They write records and they send messages. Whenever a team or an agent finishes a step, a second model checks its work. That's the judge and it has three options to move on, to redo the step or to stop the job altogether. You probably heard this called LLM as a judge. It's the same idea as a code reviewer or an eval grader.
每种工作都配备一位评审者One judge for every kind of job
难点在于,一个模型必须评判所有经过它的各类智能体。我们的客户会用任意智能体和工具,以任意顺序构建自己的工作流。因此,可能的组合几乎是无穷无尽的,评判模型需要处理的任务清单也必须随之扩展。评判模型能判断工作看起来是否已经完成,但它无法判断工作是否正确,因为每项任务对“正确”的定义都不一样,而我们却在用同一个问题评判所有任务。 接下来我们会这样展开:首先,我会介绍我们检查评判模型时的发现,然后讲讲我们选择了什么替代方案,以及你现在可以如何将它用于自己的智能体。 首先,我们进行了离线评测。我们从生产环境中抽取了 500 个真实步骤,每个步骤都包含评判模型做出的一个判断。The hard part is that one model has to grade every kind of agent that we’re running through it. Our customers build their own workflows with any agent and any tool in any order. So the permutations are almost infinite. So the list of jobs for the judge has to grow with it. The judge can tell whether the work looks finished, but what it can't tell is whether the work was right because that depends on what right means for each job and we're asking it the same question for all of them. So here's where we're going. First, I'll talk about what we found when we checked the judge. Then what we chose instead and what you can do today with your own agents. To start, we ran offline evals. We took 500 real steps from production, each with a decision that the judge had made.
法官有 65% 的时候是正确的。The judge was right 65% of the time
然后,我们拿一个更大的前沿模型,把这些步骤逐一重新评分,让它判定是接受还是退回。接着,我们人工检查了每个样本,也核对了评分。凡是我们和模型意见不一致的地方,都以我们的判断为准。这样一来,我们就为全部 500 个步骤都标注了参考标签。结果发现,裁判模型只有 65% 的时候判断正确,差不多就像抛硬币。它接受了 118 个本该退回的步骤,这占它所接受内容的四分之一以上。情况相当糟糕。我们逐一查看这些案例后发现,最常见的问题和一开始提到的那封邮件类似:智能体声称自己做了某件事,比如发送了一条消息,但实际上从未有任何工具调用执行过这件事。Then we took a larger frontier model and regraded every one of those to come back with an accept or send back. Then we hand checked each of those samples and we checked the grades. Where we disagreed with the model, we went with our call. This gave us a reference label for all 500 steps. And it turned out the judge was right 65% of the time, so more or less a coin flip. It accepted 118 steps that it should have sent back. That's more than one in four of everything that it accepted. Pretty bad. And when we read through those, the most common problem was that similar to the email at the start, the agent reported that it did something like send a message and no tool call had ever done that.
说法 vs 实锤The story vs the receipts
所以,要弄清楚评审器为什么会接受它,我们回到邮件这个例子,看看评审器拿到的是什么。左边是代理自己的摘要。可以把它看成一个故事:语气笃定,文笔流畅,还说邮件已经安排好了。右边则是实际证据,也就是工具返回的真实结果。里面有错误,还有“创建消息失败”的记录,这些都在告诉代理不要捏造记录。评审器两边都看到了,却选择相信这个故事。表面上看,工作做得不错,所以它就接受了。但这不仅仅是我们这个评审器会遇到的问题。你可以想想代码审查代理:它先读 PR 描述,再看代码差异。这也是类似的问题。如果描述写着“我修复了这个 bug,还添加了测试”,代理读代码时就会受到这句话的影响。So to see why the judge had accepted it, let's go back to the email example and look at what the judge was given. On the left, you have the agent’s own summary. Think of it as a story. It's confident, it's well written. It says the email was scheduled. Now on the right, you have the receipts. These are the actual tool results. There are errors, failed to create messages telling the agent not to make up the record. Now the judge had both of these and it went with the story. The work looked fine on the surface, so it accepted it. Now this isn't only our judge. You can think of a code review agent that reads the PR description before it looks at the diff. It's a similar kind of problem. If the description says “I fixed the bug and added tests,” the agent is going to lean on that when it reads the code.
改为一些简短的是非题Small yes-or-no questions instead
一开始,显而易见的解决办法是调优评判器,并编写更好的提示词。对我们来说,这需要投入大量工作。我们的智能体会撰写销售邮件、更新 CRM、开展研究;要准确评判这些工作,我们就得弄清楚用户到底想要什么。我们还得为每一类工作制定合适的评判规则,并确保规则始终是最新的。这基本上等于针对每种使用场景定制一个评判器。我们最终选择了另一条路:不再问一个笼统的大问题——“这做得好吗?”而是开始问一小组简短的“是或否”问题。每一步都问同样的问题,而且每个问题都足够简单,只需查看相关凭证就能回答。前一种做法基本上是一个永无止境的提示词调优项目,而后一种做法只需少量简单的检查。The obvious fix at the start was to tune the judge and write a better prompt. For us, that was going to be a significant amount of work. Our agents write sales emails, update CRMs, do research, and to judge each of these well, we'd have to figure out what it was that the user was asking. Give the judge the right rules for every kind of work and keep it all up to date. That's basically a custom judge for every use case. What we went with, we went a different direction. We stopped asking one big general question, is this good? And we started asking a short list of small yes or no questions. They're the same questions for every step and each one is small enough to answer by looking at the receipts. The first option here is basically a prompt tuning project that never ends, whereas the second one is a small handful of small checks.
现在,为了回答这些问题,我们使用了 Jev。今天你们已经听我介绍了很多 Jev,所以我就不再赘述,简单带过。它是一种类型化决策模型,而非生成式模型。对于在家观看的妈妈来说,直接问 Claude 就行。我们会向 Jev 提供有关该步骤的结构化事实,以及一系列类型化问题。类型化问题指的是只能回答“是”或“否”的问题,或只能从固定选项列表中选择答案的问题。它会为每个答案返回一个概率,并在一次调用中回答所有问题。Now, to answer those questions, we used Jev. You've heard a lot about Jev today, so I'll skip that and keep that short. It’s a typed decision model rather than a generative model. For Mom at home watching, just ask Claude. We send Jev structured facts about the step and a list of typed questions. A typed question is a yes-or-no question or a choice from a fixed list of options. It sends back a probability for each answer and it answers all the questions in one call.
一次调用中提出七个问题Seven questions in one call
我们给它提供了四样东西:指令、输入、收据(每次工具调用,以及调用成功还是失败)和智能体的报告。然后我们让它做一个选择:接受、重做或停止。这个选择决定了最终结果。但我们还问了七个是非题。这七个问题告诉我们原因,帮助我们在重做和停止之间做出选择。当智能体确实需要重做某一步时,这些问题的答案还会作为反馈提供给它。现在回到那封邮件。LLM 评审在大约两秒半内接受了它。We gave it four things, the instructions, the input, the receipts (every tool call and whether it succeeded or failed), and the agent’s report. Then we asked for one choice, which was accept, redo, or stop. And that choice makes the decision. But we also asked seven yes-or-no questions. Those seven questions tell us the why. They decide between a redo and a stop. And they go into the feedback that the agent gets when it actually has to redo a step. Now back to the email. The LLM judge accepted it in about two and a half seconds.
阈值与 LLM 回退机制Thresholds and an LLM fallback
Jev 为每个选项都给出了一个概率。在这一步中,接受的概率为 0%,重做为 97%,停止为 3%。整个过程大约花了五分之一秒。我们根据接受的概率来做决定。概率达到 30% 或更高,就接受;低于或等于 5%,就重做或停止。介于两者之间则说明 Jev 不确定,因此我们会将其交给 LLM 评审器。我们根据一开始的 500 个标签进行测试,确定了这些阈值。 为了测试这种方法是否更有效,我们采用了两种不同的方式。第一项测试使用了离线评估中的同一批 500 个生产步骤。Jev 对其中约七成步骤有足够把握。在这些步骤中,LLM 评审器接受了 82 个本应退回的步骤。这里每个红色方块都代表其中一个。Jev 成功识别出了其中 74 个。蓝色方块表示 Jev 会退回的步骤。Jev gave us a probability for each option. For this step, the probabilities were 0% accept, 97% redo, and 3% stop. And it took about a fifth of a second. We make the decision from the probability of accept. At 30% or higher, we accept that. At 5% or lower, we redo or stop. And anything in between means Jev isn't sure, so we kick it to an LLM judge. We pick those cutoffs from testing the 500 labels that we had at the beginning. To test whether this works better, we took two different routes. The first test used the same 500 production steps from the offline eval. Jev was confident enough in about seven out of ten. Among those steps, the LLM judge had accepted 82 that should have been sent back. Each red square here is one of those. Jev successfully caught 74 of those. The blue squares are the ones that Jev would have sent back.
影子模式:37,000 次决策Shadow mode: 37,000 decisions
第二项测试是我们所说的影子模式。两位裁判都会检查每一步,但只有 LLM 裁判的判定会计入结果。我们记录了 Jev 在不影响实际运行的情况下会做出的判断。这样一来,我们就有了 37,000 条决策可供分析,寻找洞见。在这段时间里,有 728 个步骤中工具明显执行失败。LLM 发现了其中 294 次,Jev 发现了 623 次。而且,一开始提到的那封虚构邮件也不是个例。同一个步骤运行了 1,081 次,几乎每次代理都声称已经安排好了一封邮件,LLM 裁判却只发现过一次。Jev 发现了 876 次。The second test is what we called shadow mode. Both judges look at every step, but only the LLM judge’s decision counts. We saved what Jev would have done without letting it affect the actual run. That gave us 37,000 decisions to mine for insights. And in that time, there were 728 steps where a tool had clearly failed. The LLM caught 294 of them. Jev caught 623. And the fake email from the beginning, it wasn't a one-off thing either. The same step ran 1,081 times, and almost every time the agent said it had scheduled an email, the LLM judge only caught it once. Jev caught that 876 times.
速度提升 10 倍,成本降低 40 倍10x faster, 40x cheaper
有裁判时,每一步都得等。Jev 的速度快 10 倍,成本低 40 倍。达到这个规模,差异就非常巨大。接下来呢?目前,每一步都会附上同样的七个问题。这些问题和事实一起输入 Jev,Jev 会给出“接受”“重做”或“停止”的结果。When you have a judge, every step waits. Jev was 10 times faster and 40 times cheaper. At this scale, it is massive. So what's next? Right now, every step goes with the same seven questions. They go into Jev along with the facts, and Jev gives us an accept, redo, or stop.
后置条件检查Post-condition checks
但接下来,我们要添加后置条件检查,这些检查取决于该步骤中调用的工具。我们可以事先知道这一步会做什么,因为工具会告诉我们。如果某一步调用了比如说发送工具,我们也会询问消息是否已送达。如果它写入了一条记录,我们就会询问该记录是否存在。然后,这些检查会和同样的七个问题一起,在同一次调用中传给 Jev。But next, we're adding post-condition checks, which depend on the tool called in the step. We know the step upfront because the tool tells us. If a step called let's say a send tool, we also ask whether the message was delivered. If it wrote a record, we ask whether the record exists. And those go into Jev with the same seven questions in the same call.
你今天可以做什么What you can do today
今天,你可以用你的智能体做什么?首先,挑选一个判断。在你的系统中,某处有一个 LLM 正在判断某件事好不好。它可能在审查代码,也可能在给某项评测打分。挑一个这样的判断,把它改写成几个简单的是非题,并且这些问题都能根据证据作答。What can you do today with your agents? First, pick one judgment. Somewhere in your systems there is an LLM deciding whether or not something is good. It might be reviewing code, grading an eval. Pick one of those and rewrite it as a few simple yes or no questions that can be answered from the evidence.
第二步是构建它。说实话,这是简单的部分。我们用的是 Jev,我们的评判器有七个问题。第三步是在影子模式下部署它。让它和你现有的系统并行运行,但暂时不要让它做决策。只要把结果保存下来,之后再分析。然后阅读这些案例,看看两者在哪些地方意见不一致。别想得太复杂,从小处着手就好。我们原本信任自己的评判器,直到实际测量后才发现问题。也测测你的评判器。再做一次检查。在影子模式下运行它,看看它在哪些地方意见不一致。你可能会对发现的情况感到惊讶。谢谢。Second is build it. This is the easy part honestly. We used Jev and ours was seven questions. Then the third, ship it in shadow mode. Run it next to what you already have, but don't let it make the decisions yet. Just save it and then you can analyze it later. Then read the cases and see where the two disagree. And don't overthink it, just start small. We had trusted our judge until we measured it. Measure yours. Run a second check. Run it in shadow mode and see where it disagrees. You may be surprised with what you find. Thank you.