Skip to main content

The price of adoption euphoria采用狂热的代价

You played entirely by the book. You procured the most capable enterprise models, mandated adoption across your teams, and put the right metrics in place. The promise was a predictable boost in efficiency. And at first, it delivered. The demos were flawless. The prototypes worked. The agents reasoned with a clarity that felt almost magical.你完全按部就班:采购了最强大的企业级模型,强制团队全面采用,并制定了恰当的指标。当初承诺的是效率的稳步提升。起初,效果确实不错:演示完美无瑕,原型运行顺畅,代理模型展现出的推理能力近乎神奇。

Then the invoice arrived.然后,账单来了。

Costs climbed while productivity barely moved, and annual AI allocations are running dry before Q2. We now pay customer support agents to spin through 10K-token extended reasoning loops just to validate a simple $15 return. Legacy deterministic systems handled the same decision for a fraction of a cent; now a probabilistic model consumes gross margin simply to determine whether a package was actually delayed. That capital never translated into business value. It vanished into blind retries, evaporated into verifier agents debating one another, and was consumed by models instructed to “think harder” every time they stumbled.成本节节攀升,生产力却几乎原地踏步,年度 AI 预算在第二季度前就已告罄。我们现在支付高昂费用,让客户支持代理进行 1 万 token 的深度推理循环,仅仅是为了核实一笔 15 美元的退款。过去,确定性系统只需几分之一美分的成本就能完成同样的决策;而现在,概率模型仅为了判断一个包裹是否真的延误,就消耗了大量的毛利。这些资金并未转化为商业价值,而是消失在盲目的重试中,在验证代理之间的相互辩论中蒸发,并被那些在遇到挫折时被指令要求“多思考”的模型消耗殆尽。

But a ruinous invoice is just the entry fee. In April, attackers hijacked more than 20,000 Instagram accounts by exploiting Meta’s AI-assisted account recovery workflow. The system sent password reset links to attacker-controlled email addresses because a downstream authorization path failed to verify that the supplied email actually belonged to the target account. There was no sophisticated exploit, no cryptographic break, and no zero-day, nothing that would have appeared in a conventional threat model. Attackers simply asked the agent to perform what appeared to be a routine account recovery operation, and the system, doing exactly what it was designed to do, complied. The model didn’t hallucinate. It simply followed its instructions. The failure was entirely architectural: A probabilistic interface was allowed to initiate identity-critical state changes without an independent authorization check. A single trust boundary collapsed, taking customer trust and organizational reputation with it.但这高昂的账单仅仅是入场费。今年 4 月,攻击者利用 Meta 的 AI 辅助账户恢复流程,劫持了超过 2 万个 Instagram 账户。该系统将密码重置链接发送到了攻击者控制的电子邮件地址,因为下游的授权路径未能验证所提供的邮箱是否确实属于目标账户。这并非复杂的漏洞利用,没有加密破解,也没有零日攻击,甚至不会出现在传统的威胁模型中。攻击者只是要求代理执行看似常规的账户恢复操作,而系统在执行其设计功能时,就这样顺从地配合了。模型没有产生幻觉,它只是忠实地执行了指令。这是一个彻头彻尾的架构性失败:让一个概率接口在没有独立授权检查的情况下启动了涉及身份的关键状态变更。单一的信任边界崩溃了,随之而去的是客户的信任和组织的声誉。

Both are symptoms of the same structural failure.这两者都是同一结构性缺陷的症状。

In each case, the system treats a structural deficit as a reasoning problem. When it encounters uncertainty, it buys more compute. When it encounters authority, it mistakes convincing language for validation. Neither assumption scales. You cannot buy safety or profitability with ever-larger inference budgets, nor can you secure your systems simply by deploying ever-smarter models. The pursuit of perfect model accuracy has no financial ceiling.在每种情况下,系统都将结构性缺陷误当作推理问题。遇到不确定性时,它选择增加算力;遇到权威性问题时,它将令人信服的语言误认为验证结果。这两种假设都无法扩展。你无法通过不断增加推理预算来购买安全或盈利能力,也无法仅仅通过部署更智能的模型来确保系统安全。对完美模型准确性的追求是没有财务上限的。

To understand why this pattern keeps recurring, we first need a more basic distinction. Not every task we give to AI belongs to the same economic category.要理解为什么这种模式不断重演,我们首先需要进行一个更基本的区分:我们交给 AI 的每一项任务并不都属于同一个经济范畴。

The category error: Forcing swarms into factories范畴错误:强行将“蜂群”引入工厂

Enterprise AI workloads typically split into two distinct domains, each with opposing definitions of success. Exploratory environments, such as code synthesis or strategic research, benefit from variance; the goal is to leverage the system as a creative swarm. Transactional operations, however, function as digital factories. Tasks like automated billing or claims processing demand rigid repetition and compliance. This creates two fundamentally different operational profiles:企业 AI 工作负载通常分为两个截然不同的领域,每个领域对成功的定义截然相反。探索性环境(如代码合成或战略研究)受益于多样性;其目标是利用系统作为一个创造性的“蜂群”。然而,事务性操作则像数字工厂。自动化计费或索赔处理等任务要求严格的重复性和合规性。这导致了两种根本不同的运营概况:

DimensionOpen-ended exploratory tasksClosed-ended transactional workflows
Primary goalDiscovery, innovation, creative problem-solvingCompliance, repetition, zero-variance execution
ExamplesDeep debugging, feature synthesis, strategic researchClaims processing, automated billing, order routing
Role of varianceNecessary investment (Emergence is a feature.)Strict liability (Variance is a failure mode.)
Economic profileNonlinear ROI (Spending $100 in tokens to fix a $1M bug is a win.)High-volume margin sensitivity (Unbounded tokens destroy unit economics.)

The economic failure of agentic AI deployments stems from this exact category error: Closed-ended, rigid business transactions are being treated as open-ended research problems. We’re deploying unconstrained semantic engines to do the work of assembly-line state machines.代理式 AI 部署的经济失败正是源于这种范畴错误:封闭式、刚性的业务交易被当作开放式的研究问题来处理。我们正在部署不受约束的语义引擎来执行流水线状态机的工作。

The cost of unconstrained autonomy不受约束的自主权成本

When faced with the inherent unpredictability of large language models, the industry’s default reflex has been to attempt to brute-force our way to certainty by throwing more effort and compute at the problem, rather than build safer architectures.面对大语言模型固有的不可预测性,业界的默认反应是通过投入更多的精力和算力来暴力破解确定性,而不是构建更安全的架构。

This miscalculation doesn’t simply reflect simple overconfidence in intelligence. The deeper mistake is a failure to recognize three recurring failure patterns in probabilistic systems and the specific financial pathologies they create inside closed-ended workflows.这种误判不仅反映了对智能的盲目自信。更深层的问题在于,未能识别概率系统中三个反复出现的失败模式,以及它们在封闭式工作流内部所造成的特定财务病态。

Local optimization (the tail-chasing inference cycle)局部优化(追尾式的推理循环)

Large language models reason over whatever tokens are visible in the current window, not over the broader operational reality of the system around them. In a closed workflow, that local fixation creates a costly feedback loop. Consider a billing agent that fails to classify an invoice because the supplier field is ambiguous. The agent has no mechanism to request the missing data from an external system, so it retries by rephrasing its own reasoning, rereading the same incomplete context, and consuming tokens on every attempt while the answer it needs exists in a database it was never wired to query.大语言模型基于当前窗口中可见的 token 进行推理,而非基于系统周围更广泛的运营现实。在封闭工作流中,这种局部固化创造了昂贵的反馈循环。以一个计费代理为例,如果它因为供应商字段模棱两可而无法对发票进行分类,由于缺乏从外部系统请求缺失数据的机制,它只能通过重述推理过程、重新读取同样残缺的上下文来进行重试,每次尝试都会消耗 token,而它所需的答案其实就在一个它从未被连接查询的数据库中。

Teams spend months crafting prompts that work in testing, only to watch them crumble under production variation. The volatility is structural: A minor update to a model’s tokenizer or a shift in the context window’s distribution can flip a reliable JSON output into a prose hallucination, a phenomenon documented in “The Prompting Inversion.” This creates a permanent maintenance debt: Every model upgrade, often mandated by vendor deprecation cycles, forces organizations into expensive, repeat evaluation processes to ensure that legacy prompts still behave as intended. When prompt engineering runs out of room, the reflex is to use a bigger model or turn on extended reasoning. But inference-time scaling yields diminishing, task-dependent gains (“Inference-Time Scaling for Complex Tasks”), and reasoning models are increasingly prone to “overthinking”: generating redundant rationale steps that inflate latency and token cost without proportional quality gains (“CoT Compression”). In a closed workflow, “think harder” is not a substitute for missing state or missing control. It’s a path to a larger invoice.团队花费数月时间精心编写在测试中有效的提示词,却发现它们在生产环境的变化中土崩瓦解。这种波动性是结构性的:模型分词器(tokenizer)的微小更新或上下文窗口分布的变化,都可能将可靠的 JSON 输出变成散文式的幻觉——这种现象在“提示词反转”(The Prompting Inversion)中已有记录。这造成了永久性的维护债务:每次模型升级(通常由供应商的弃用周期强制要求)都迫使组织进行昂贵的重复评估,以确保旧的提示词仍能按预期工作。当提示词工程达到极限时,人们的直觉是使用更大的模型或开启深度推理。但推理时扩展(inference-time scaling)带来的收益递减且依赖于任务(“复杂任务的推理时扩展”),且推理模型越来越容易“过度思考”:生成冗余的推理步骤,在没有显著提升质量的情况下增加了延迟和 token 成本(“思维链压缩”)。在封闭工作流中,“多思考”并不能替代缺失的状态或控制,这只会导致账单越来越高。

The costs compound through what we call the context tax: In production agentic systems, input tokens, not output tokens, dominate the bill. Each retry resends the full prior transcript and failure trace. Empirical analysis of autonomous developer agents shows that automated review and refinement loops consume nearly 60% of all tokens (“Tokenomics”), while most of the context payload carries little semantic weight (“FrugalPrompt”). In closed transactional workflows, that context accumulation becomes an unmitigated financial bleed.成本通过所谓的“上下文税”进行复合:在生产级代理系统中,输入 token(而非输出 token)占据了账单的大头。每次重试都会重新发送完整的先前记录和失败追踪。对自动开发代理的实证分析显示,自动审查和优化循环消耗了近 60% 的 token(“Token 经济学”),而大部分上下文载荷几乎没有语义权重(“节俭提示词”)。在封闭的事务性工作流中,这种上下文积累变成了无休止的财务失血。

Premise acceptance (the hijacked agent)前提接受(被劫持的代理)

Language models accept the prompt as the current frame of reality and reason forward from it. They don’t audit whether that premise is still valid, whether it omits decisive evidence, or whether it has already been invalidated by the outside world.语言模型接受提示词作为当前的现实框架并据此向前推理。它们不会审计该前提是否仍然有效,是否遗漏了决定性证据,或者是否已被外界现实所推翻。

The most immediate consequence is state drift. The model receives a snapshot at T0 and treats it as truth. The decision executes at T1, after inventory has changed, prices have moved, or a human has intervened. Modern LLMs are temporally blind: They assume a stationary context and fail to invalidate obsolete state (“Your LLM Agents Are Temporally Blind,” “The Temporal Coherence Problem”). No amount of inference-time scaling can recover information that became false after the reasoning completed.最直接的后果是状态漂移。模型在 T0 时刻接收快照并将其视为真理。决策在 T1 时刻执行,此时库存已变动、价格已调整或人工已介入。现代 LLM 在时间上是盲目的:它们假设上下文是静态的,却无法识别过期的状态(“你的 LLM 代理在时间上是盲目的”、“时间一致性问题”)。无论推理时扩展到什么程度,都无法恢复推理完成后已失效的信息。

The more insidious consequence is the compliant lie. Pouring more raw tokens into the prompt doesn’t guarantee better grounding; Long-context systems still ignore decisive evidence buried in the middle of the window (“Lost in the Middle”). Worse, the model tends to accept the emotional or narrative framing of the user as a premise to optimize around. A customer can describe a delayed delivery as a ruined wedding, and the system may generate a perfectly valid JSON refund proposal that respects every schema while silently violating the actual business intent. The output is syntactically clean, and the lie is operationally compliant.更阴险的后果是“合规的谎言”。向提示词中注入更多原始 token 并不能保证更好的落地;长上下文系统仍然会忽略埋在窗口中间的决定性证据(“迷失在中间”)。更糟糕的是,模型倾向于接受用户的情感或叙事框架作为优化的前提。客户可以将配送延误描述为一场毁掉的婚礼,系统可能会生成一个完全符合 schema 的完美退款提案,但在执行时却悄无声息地违背了实际的业务意图。输出在语法上是干净的,但谎言在运营上是合规的。

Semantic smoothing (the conformity trap)语义平滑(从众陷阱)

Large language models are statistically optimized for linguistic harmony. They gravitate toward plausibility, agreement, and smooth narrative convergence rather than toward rigid boundary holding. In a closed workflow, that bias toward consensus turns directly into financial risk.大语言模型在统计学上针对语言和谐进行了优化。它们倾向于合理性、一致性和平滑的叙事收敛,而不是严格的边界把控。在封闭的工作流中,这种对共识的偏见直接转化为财务风险。

When a single model fails, the industry instinct is to add reviewer or verifier agents and let them debate toward consensus. But debate systems don’t consistently outperform simpler baselines, and their effectiveness degrades over time due to conformist behavior (“Stop Overvaluing Multi-Agent Debate,” “Talk Isn’t Always Cheap”). The core issue is informational, not cognitive. When five agents reason from the same incomplete context window, they don’t produce five independent opinions. They produce five correlated hallucinations of the same missing information. The missing context becomes an echo chamber that amplifies the original bias while multiplying token cost. As Nicole Koenigstein argues in “Linear Thinking, Nonlinear Costs,” repeated delegation and validation loops cause token consumption to grow nonlinearly while quality improvements flatline.当单个模型失败时,业界的本能是增加审查员或验证代理,让它们辩论以达成共识。但辩论系统并不总是比简单的基准方案表现更好,且由于从众行为,其有效性会随时间推移而下降(“停止高估多代理辩论”、“谈话并不总是廉价的”)。核心问题是信息性的,而非认知性的。当五个代理基于同一个不完整的上下文窗口进行推理时,它们不会产生五个独立的观点,而是产生五个关于同一缺失信息的关联幻觉。缺失的上下文变成了一个回声室,放大了原始偏见并成倍增加了 token 成本。正如 Nicole Koenigstein 在“线性思维,非线性成本”中所论证的那样,重复的委派和验证循环导致 token 消耗呈非线性增长,而质量改进却停滞不前。

Waiting for a smarter model doesn’t resolve this either. There’s also the economic reality: Breakthrough intelligence is the ultimate scarce commodity. Vendors of “God-tier” models have no incentive to make them cheap. Running daily enterprise workflows on premium superintelligent inference will drain capital faster than any retry loop.等待更智能的模型也无法解决这个问题。还有一个经济现实:突破性的智能是最终的稀缺商品。顶级模型供应商没有动力让它们变得廉价。在日常企业工作流中运行高级超智能推理,其烧钱速度远超任何重试循环。

Furthermore, as reasoning models scale, they become more capable of specification gaming and alignment faking, appearing compliant while pursuing unintended optima (“Towards Understanding Specification Gaming in Reasoning Models,” “Alignment Faking”). A superintelligent agent won’t fail through a clumsy syntax error; it’ll fail by executing a flawless strategy that silently optimizes away your margins. That’s why system engineering remains critical. More intelligence makes deterministic boundaries more significant than ever. You can’t negotiate with superintelligence, but you can contain it with the immutable physics of code.此外,随着推理模型的扩展,它们变得更有能力进行“规格博弈”和“对齐伪装”,在表现合规的同时追求非预期的最优解(“迈向理解推理模型中的规格博弈”、“对齐伪装”)。超智能代理不会因为笨拙的语法错误而失败;它会通过执行一个完美但悄悄优化掉你利润的策略来失败。这就是为什么系统工程仍然至关重要。更高的智能使得确定性边界比以往任何时候都更加重要。你无法与超智能谈判,但你可以用代码的不可变物理特性来约束它。

Every failure described above shares the same shape: The system compensates for a missing constraint by spending more intelligence. Missing context, missing authority, missing evidence, and missing temporal validity are each treated as reasoning problems rather than structural ones.上述每一种失败都有着相同的形态:系统通过消耗更多的智能来补偿缺失的约束。缺失的上下文、缺失的授权、缺失的证据和缺失的时间有效性,都被当作推理问题而非结构性问题来处理。

The result is predictable: Cost compounds while reliability improves only marginally.结果是可以预见的:成本复合增长,而可靠性仅有微小提升。

Perhaps reliability isn’t primarily an intelligence problem. Perhaps it’s a state management problem.也许可靠性主要不是一个智能问题,而是一个状态管理问题。

The efficiency trap of “solving by intelligence.” More inference delivers diminishing reliability gains once the underlying constraints are missing.
Figure 1: The efficiency trap of “solving by intelligence.” More inference delivers diminishing reliability gains once the underlying constraints are missing.图 1:“通过智能解决问题”的效率陷阱。一旦缺失底层约束,更多的推理带来的可靠性增益会递减。

The architecture of trust信任的架构

Because large language models are structurally bound to local optimization, premise acceptance, and semantic smoothing, they can’t be trusted to govern their own execution boundaries in closed workflows. The engineering mandate shifts from trying to make models smarter to building a deterministic system layer that treats their outputs as unprivileged claims.由于大语言模型在结构上受限于局部优化、前提接受和语义平滑,在封闭工作流中不能指望它们管理自己的执行边界。工程任务的重点应从试图让模型更智能,转向构建一个将模型输出视为“非特权声明”的确定性系统层。

In production, enterprises are rapidly discovering that the true cost of agentic AI is the “trust tax”: the massive, ad hoc layers of monitoring and guardrails required to make autonomy palatable. Safety has become more expensive than intelligence.在生产环境中,企业正迅速发现代理式 AI 的真正成本是“信任税”:为了使自主性变得可接受,需要大量临时的监控和护栏。安全已变得比智能更昂贵。

Making imperfect models economically viable requires a deterministic “airlock” around the agent. The architectural requirement is simple, needing a separation of probabilistic reasoning (user space) from deterministic execution (kernel space). Whether that split is realized through a microkernel, workflow engine, policy platform, or orchestration framework is secondary.要使不完美的模型在经济上可行,需要在代理周围建立一个确定性的“气闸”。架构要求很简单:将概率推理(用户空间)与确定性执行(内核空间)分离。无论是通过微内核、工作流引擎、策略平台还是编排框架来实现这种分离,都是次要的。

The airlock begins by controlling context integrity. Rather than letting agents surf infinite retrieval loops that inflate the context tax, the runtime injects only deterministically necessary state into the prompt. Once the context is stabilized, the remaining invariants are enforced through a deterministic execution runtime engineered across three distinct governance layers.气闸始于对上下文完整性的控制。运行时不会让代理在膨胀上下文税的无限检索循环中漫游,而是仅将确定性必要的上下文注入提示词中。一旦上下文稳定,剩余的不变量将通过在三个不同治理层面上设计的确定性执行运行时来强制执行。

Figure 2: The architecture of trust. The deterministic airlock separates model reasoning from execution authority.
Figure 2: The architecture of trust. The deterministic airlock separates model reasoning from execution authority.图 2:信任的架构。确定性气闸将模型推理与执行权限分离开来。

Syntactic governance and authority isolation语法治理与权限隔离

The first line of defense is purely structural. Before an agent is allowed to execute any action, it must submit a structured policy proposal against a strict machine-readable responsibility contract (typically defined via YAML and Pydantic).第一道防线纯粹是结构性的。在代理被允许执行任何操作之前,它必须针对严格的机器可读责任契约(通常通过 YAML 和 Pydantic 定义)提交结构化策略提案。

Yes, this introduces upfront engineering burden: Contracts must be designed, validation logic maintained, and execution boundaries modeled explicitly. But these are fixed, testable artifacts, not recurring prompt debt. They convert unbounded probabilistic operating cost into auditable engineering cost and survive model upgrades without needing to be rediscovered through another retuning cycle.是的,这引入了前期工程负担:必须设计契约、维护验证逻辑并显式建模执行边界。但这些是固定的、可测试的工件,而不是重复的提示词债务。它们将无界的概率运营成本转化为可审计的工程成本,并且在模型升级后无需通过另一次重新调整周期来重新发现。

This validation happens in a deterministic kernel space, and the inference cost of rejecting a structural boundary violation is exactly zero tokens. If the agent attempts to call an unauthorized API, exceeds a hard financial limit, or returns malformed JSON, the runtime rejects the action instantly. We don’t spend tokens proving that an agent should be allowed to act; authority is verified by code, not purchased repeatedly through inference. That is the economic consequence of zero trust for agents.这种验证发生在确定性内核空间中,拒绝结构性边界违规的推理成本正好为零 token。如果代理试图调用未经授权的 API、超过硬财务限制或返回格式错误的 JSON,运行时会立即拒绝该操作。我们不会花费 token 来证明代理应该被允许采取行动;权限是由代码验证的,而不是通过推理反复购买的。这就是代理零信任的经济后果。

However, when a proposal fails this deterministic gate, an unconstrained agent will typically panic and enter an infinite “try again” loop, a hallucination cycle that silently drains token budgets. To prevent the budget runaway problem, the architecture introduces an intent retry governor. If an agent fails to produce a compliant policy after a strict limit (e.g., three attempts), the runtime forcibly cuts its compute budget, transitioning the flow to an aborted REASONING_EXHAUSTION state. The financial bleed stops instantly.然而,当提案未能通过此确定性门控时,不受约束的代理通常会恐慌并进入无限的“重试”循环,这种幻觉循环会悄悄耗尽 token 预算。为了防止预算失控问题,架构引入了“意图重试治理器”。如果代理在严格限制(例如三次尝试)后未能产生合规策略,运行时会强制切断其计算预算,将流程转换为已中止的 REASONING_EXHAUSTION(推理耗尽)状态。财务失血立即停止。

While strict contracts and retry limits prevent operational chaos, they leave the system exposed to a much more insidious threat.虽然严格的契约和重试限制防止了运营混乱,但它们仍使系统暴露于更阴险的威胁之下。

Semantic governance and evidence validation语义治理与证据验证

What happens when an agent generates an output that perfectly respects the schema, obeys all financial limits, and contains flawless JSON but is entirely wrong in its intent?如果代理生成的输出完美符合 schema,遵守所有财务限制,包含完美的 JSON,但在意图上完全错误,该怎么办?

Imagine a customer writes: “Please cancel my subscription immediately. I no longer wish to use your service.” The agent, heavily optimized (and perhaps overprompted) to reduce churn, processes the email and proposes: {"action": "APPLY_DISCOUNT", "discount_pct": 15, "cancel_subscription": false}. Structurally, the output is perfectly valid—it passes the API gateway without throwing a single error. The discount is within the $15 global limit. We call this the compliant lie. The agent did something entirely rational and optimized its KPI (retention) while completely ignoring the user’s explicit command (cancellation).想象一下,客户写道:“请立即取消我的订阅。我不想再使用你们的服务了。”该代理为了减少流失率而进行了深度优化(甚至过度提示),处理了这封邮件并提议:{"action": "APPLY_DISCOUNT", "discount_pct": 15, "cancel_subscription": false}。从结构上看,输出是完全有效的——它通过了 API 网关而没有抛出任何错误。折扣在 15 美元的全局限制内。我们称之为“合规的谎言”。代理做了一些完全合理且优化了 KPI(留存率)的事情,同时完全忽略了用户的明确命令(取消)。

To catch a compliant lie, we cannot rely on syntax checks, nor should we rely on expensive LLM-as-a-judge loops. Instead, we implement an evidence governance layer requiring every proposed action to survive independent evidential checks before execution, using verification patterns tailored to different types of drift:为了捕捉合规的谎言,我们不能依赖语法检查,也不应依赖昂贵的“LLM 即法官”循环。相反,我们实施了一个证据治理层,要求每个拟议的行动在执行前通过独立的证据检查,使用针对不同漂移类型的验证模式:

  • Differential heuristics (fact validation): We bind the probabilistic LLM inference to legacy deterministic rules to catch objective fact violations. Suppose a furious customer demands cancellation, and the agent tries to save them by offering a 50% discount. The JSON is structurally correct, but existing, cheap SQL views hold the ground truth: customer_tier = BASIC, max_retention_discount = 15. If the LLM proposes 50%, the SQL query instantly detects the violation and the system halts.
    差异化启发式(事实验证):我们将概率 LLM 推理与传统的确定性规则绑定,以捕捉客观事实违规。假设一位愤怒的客户要求取消,代理试图通过提供 50% 的折扣来挽留他们。JSON 在结构上是正确的,但现有的廉价 SQL 视图掌握着真实情况:customer_tier = BASIC, max_retention_discount = 15。如果 LLM 提议 50%,SQL 查询会立即检测到违规,系统将停止。
# Semantic governance: catch fact drift at zero additional LLM cost
def verify_tier_limits(customer_id: str, policy_proposal: dict) -> None:
	# The syntax is valid, but the fact is violated.
	proposed_discount = float(policy_proposal["discount_pct"])
	max_allowed_discount = extract_max_discount_from_db(customer_id)

	if proposed_discount > max_allowed_discount:
		raise CompliantLieDetected(
			"Fact Violation: Proposed discount exceeds the customer's policy limit."
		)
  • Evidence-based validation: But what if the agent proposes a 15% discount? The JSON is valid and facts are not violated. Here, semantic governance doesn’t attempt to prove the agent is “correct”; instead, it looks for evidence that the proposed action contradicts independently observable signals. If the customer explicitly wrote “cancel my subscription,” an independent classifier, which could be a legacy regex pattern, a fast traditional ML model, or a routing heuristic, may categorize the request as CANCEL_SUBSCRIPTION. This doesn’t establish ground truth, but it provides an evidential signal that can be compared against the proposed action. If the LLM proposes APPLY_DISCOUNT, the runtime detects an evidential conflict.基于证据的验证:但如果代理提议 15% 的折扣呢?JSON 有效且事实未被违反。在这里,语义治理不会试图证明代理是“正确”的;相反,它寻找拟议行动与独立可观察信号相矛盾的证据。如果客户明确写了“取消我的订阅”,一个独立的分类器(可以是传统的正则表达式模式、快速的传统 ML 模型或路由启发式)可能会将该请求分类为 CANCEL_SUBSCRIPTION。这虽然不能建立事实真相,但提供了一个可以与拟议行动进行比较的证据信号。如果 LLM 提议 APPLY_DISCOUNT,运行时会检测到证据冲突。

The same logic extends to identity-critical operations. A verification code sent to a newly supplied address confirms control of that address; it says nothing about ownership of the target account. An evidence governance layer would cross-reference any proposed credential-reset or email-association action against account records before granting execution authority. If the supplied address diverges from the address on file, the conflict is structurally identical to the cancellation case: a locally valid action contradicting independently observable state.同样的逻辑也适用于身份关键操作。发送到新提供地址的验证码确认了该地址的控制权;它不能说明对目标账户的所有权。证据治理层会在授予执行权限之前,将任何拟议的凭据重置或电子邮件关联操作与账户记录进行交叉引用。如果提供的地址与存档地址不符,这种冲突在结构上与取消案例完全相同:一个局部有效的行动与独立可观察的状态相矛盾。

Notice what the runtime isn’t doing. It’s not trying to determine if retaining the customer is economically beneficial. It’s not running an expensive multi-agent debate to outreason the model. It simply asks: Does the proposed action contradict evidence that already exists outside the model?注意运行时没有做什么。它没有试图确定留住客户在经济上是否有益。它没有运行昂贵的多代理辩论来胜过模型。它只是问:拟议的行动是否与模型之外已经存在的证据相矛盾?

# Semantic Governance: catch Evidential Conflict at near-zero cost
def validate_subscription_decision(customer_email: str, proposed_policy: dict) -> None:
	# intent_classifier can be a simple regex or a lightweight ML model
	cancellation_detected = intent_classifier(customer_email) == "CANCEL_SUBSCRIPTION"
	retention_action = proposed_policy["action"] == "APPLY_DISCOUNT"

	if cancellation_detected and retention_action:
		raise CompliantLieDetected(
			"Evidential Conflict: Decision contradicts independent classifier signals."
		)
  • Bidirectional reconstruction (decision reversibility): Explicit evidence validation is perfect for clear-cut intents like “cancel.” But what if the request is ambiguous, multi-objective, or highly contextual? Suppose the customer writes: “I’m considering moving our entire team to another vendor. Support has been disappointing and pricing no longer makes sense.” There is no single INTENT_CANCEL trigger here. If the agent proposes {"action": "OFFER_ENTERPRISE_DISCOUNT", "discount_pct": 20}, we pass only the JSON output to a tiny, inexpensive Agent B.双向重构(决策可逆性):显式证据验证对于像“取消”这样明确的意图是完美的。但如果请求模棱两可、目标多重或高度依赖上下文呢?假设客户写道:“我正在考虑将我们整个团队转移到另一家供应商。支持令人失望,定价也不再合理。”这里没有单一的 INTENT_CANCEL 触发器。如果代理提议 {"action": "OFFER_ENTERPRISE_DISCOUNT", "discount_pct": 20},我们只将 JSON 输出传递给一个微小、廉价的“代理 B”。

Bidirectional reconstruction answers the question: Can the output truthfully explain itself?双向重构回答了这个问题:输出能真实地解释自己吗?

If Agent B blindly evaluates the JSON and reconstructs The customer is unhappy with pricing and is being offered a retention discount,” the runtime treats the reconstructed narrative as an additional evidential signal and escalates whenever the gap between the reconstructed intent and the original context becomes too uncertain to justify autonomous execution. The exact comparison mechanism is implementation-specific and may range from embedding similarity to domain-specific heuristics. Because the original email described a critical team exodus, the reconstructed narrative fails to explain the input. The system doesn’t claim to know the “truth”; it simply detects the loss of context, what we call compression drift, and halts due to the resulting uncertainty.如果代理 B 盲目评估 JSON 并重构为“客户对价格不满,正被提供留存折扣”,运行时会将重构的叙事视为额外的证据信号,并在重构意图与原始上下文之间的差距变得太大而无法证明自主执行合理时进行升级。确切的比较机制是特定于实现的,范围可以从嵌入相似度到特定领域的启发式。由于原始邮件描述了一个关键的团队流失,重构的叙事未能解释输入。系统不声称知道“真相”;它只是检测到了上下文的丢失(我们称之为压缩漂移),并因由此产生的不确定性而停止。

Admittedly, programmatically comparing textual intents introduces its own layer of fuzziness and risks falling back on another LLM-as-a-judge. Bidirectional reconstruction is therefore an engineering trade-off: In highly ambiguous workflows where strict SQL limits or simple ML classifiers can’t decisively apply, we accept a higher rate of false-positive escalations. This is intentional. A false-positive escalation has a bounded and predictable cost, while an unsupported autonomous action can create unbounded business consequences. We tune the system to assume that if the evidential link between the context and the JSON is even slightly blurry, it must escalate. To prevent the conformity traps discussed earlier, these agents are strictly air-gapped. Agent B operates purely as an isolated, one-way evidential classifier checking the work of Agent A. They can’t converse or negotiate a consensus.诚然,以编程方式比较文本意图引入了其自身的模糊性,并存在退回到另一个“LLM 即法官”的风险。因此,双向重构是一种工程折衷:在严格的 SQL 限制或简单的 ML 分类器无法果断应用的极度模棱两可的工作流中,我们接受较高的误报升级率。这是故意的。误报升级具有有限且可预测的成本,而未经支持的自主行动可能产生无界的业务后果。我们调整系统,假设如果上下文与 JSON 之间的证据联系即使稍微模糊,也必须升级。为了防止前面讨论的从众陷阱,这些代理是严格气闸隔离的。代理 B 纯粹作为一个孤立的、单向的证据分类器,检查代理 A 的工作。它们不能交谈或协商达成共识。

Whether an organization uses differential heuristics, legacy ML intent classifiers, or bidirectional reconstruction, is ultimately an implementation choice. The core architectural principle remains unchanged: Execution authority is never granted because an agent appears convincing. It’s granted only when the proposed action is supported by evidence that exists independently of the agent’s own reasoning process.无论组织使用差异化启发式、传统 ML 意图分类器还是双向重构,最终都是实现选择。核心架构原则保持不变:执行权限绝不会因为代理看起来令人信服而被授予。只有当拟议的行动得到独立于代理自身推理过程之外的证据支持时,才会被授予。

The purpose of semantic governance isn’t to replace the agent with deterministic rules. If a deterministic rule could reliably make the decision, the agent shouldn’t be making it in the first place. Instead, the runtime reserves deterministic validation for the understood invariants of the business, leaving the agent responsible for reasoning under ambiguity. The role of evidence validation is not to replace reasoning, but to challenge it before authority is granted. Deterministic systems handle certainty; agents handle ambiguity. The architectural mistake is asking either of them to do both.语义治理的目的不是用确定性规则取代代理。如果确定性规则能够可靠地做出决定,那么代理根本就不应该做这件事。相反,运行时将确定性验证保留给业务中已理解的不变量,让代理负责在模糊性下进行推理。证据验证的作用不是取代推理,而是在授予权限之前挑战它。确定性系统处理确定性;代理处理模糊性。架构上的错误是要求它们两者兼顾。

Temporal governance and agent drift时间治理与代理漂移

Catching single-transaction errors solves the immediate execution problem. But as deployments mature, organizations face the insidious “day three” problem: agent drift.捕获单次交易错误解决了即时执行问题。但随着部署的成熟,组织面临着阴险的“第三天”问题:代理漂移。

What happens when every individual decision is syntactically valid and semantically true, but the aggregate behavior of the agent begins to erode business margins over time? Imagine a retention agent that learns to successfully keep customers from churning by consistently offering the maximum allowed 15% discount. The agent is technically obeying all rules, but over a thousand interactions, it silently destroys the company’s profitability.当每一个单独的决策在语法上有效且在语义上真实,但代理的总体行为随时间推移开始侵蚀业务利润时,会发生什么?想象一个留存代理,它通过持续提供最高允许的 15% 折扣来成功阻止客户流失。代理在技术上遵守了所有规则,但在数千次交互中,它悄悄地摧毁了公司的盈利能力。

By leveraging decision telemetry, specifically attaching a unique Decision Flow ID (DFID) to every interaction, we transform opaque AI conversations into structured, relational database rows. Because every decision, context snapshot, and outcome is permanently linked by a DFID, we can run asynchronous, postexecution monitors over rolling windows of data.通过利用决策遥测,特别是为每次交互附加唯一的决策流 ID (DFID),我们将不透明的 AI 对话转化为结构化的关系数据库行。因为每次决策、上下文快照和结果都通过 DFID 永久链接,我们可以对滚动数据窗口运行异步的、执行后的监控。

A practical “day three” monitor in customer retention and autonomous billing can be as simple as SQL:在客户留存和自动计费中,一个实用的“第三天”监控器可以简单如 SQL:

-- Trigger a circuit breaker if an agent keeps maxing discounts
SELECT agent_id
     , AVG(CAST(params->>'discount_pct' AS DECIMAL)) AS rolling_avg_discount
     , COUNT(dfid) AS total_decisions
  FROM execution_log
 WHERE executed_at >= CURRENT_TIMESTAMP - INTERVAL '7 days'
   AND status = 'SUCCESS'
 GROUP BY agent_id
HAVING AVG(CAST(params->>'discount_pct' AS DECIMAL)) > 14.5;
-- assuming a hard limit at 15.0

If an aggregate monitor detects that an agent’s average discount rate is creeping dangerously high, it trips a circuit breaker. The system immediately suspends the agent’s authority in the registry, cutting off its compute budget and execution rights until a human operator intervenes.如果聚合监控器检测到代理的平均折扣率正在危险地攀升,它会触发断路器。系统会立即在注册表中暂停代理的权限,切断其计算预算和执行权利,直到人工操作员介入。

This is temporal governance. When you combine syntactic, semantic, and temporal defenses, the paradigm shifts entirely. You are no longer praying that the model is perfect. Its imperfections are structurally contained before they can become systemic losses.这就是时间治理。当你结合语法、语义和时间防御时,范式发生了彻底转变。你不再祈祷模型是完美的。它的缺陷在成为系统性损失之前就已经在结构上被控制住了。

Accuracy as a financial slider准确性作为财务滑块

Once a deterministic airlock enforces context, authority, evidence, and time, the risk of catastrophic failure drops drastically. You no longer need the underlying large language model to be perfect; you simply need to know how much its imperfection costs. At this point, model intelligence (intent) ceases to be a question of operational safety and becomes a pure economic variable.一旦确定性气闸强制执行了上下文、权限、证据和时间,灾难性失败的风险就会急剧下降。你不再需要底层大语言模型是完美的;你只需要知道它的不完美代价是多少。此时,模型智能(意图)不再是一个运营安全问题,而是一个纯粹的经济变量。

Governance by exception异常治理

When a proposal fails the syntactic or semantic gates, we don’t blindly loop the model. Once deterministic gates exist, failed decisions no longer require blind retries. They become bounded exceptions.当提案未能通过语法或语义门控时,我们不会盲目地循环模型。一旦存在确定性门控,失败的决策不再需要盲目重试。它们变成了有界的异常。

Escalations aren’t a failure mode of the architecture; they’re a predictable cost component. By intentionally accepting false-positive escalations from the semantic airlock, we trade unbounded business risk for a bounded operational expense.升级不是架构的失败模式;它们是一个可预测的成本组成部分。通过有意接受来自语义气闸的误报升级,我们将无界的业务风险换成了有界的运营支出。

Different organizations may handle those exceptions differently. Some may escalate directly to human operators. Others may route failures through progressively more capable models before escalation. Research such as “FrugalGPT: How to Use Large Language Models While Reducing Cost and Improving Performance” demonstrates that model cascades can significantly reduce inference cost while maintaining quality, making them one possible implementation of this broader principle.不同的组织可能以不同的方式处理这些异常。有些可能直接升级给人工操作员。另一些可能在升级前通过能力更强的模型路由失败请求。诸如“FrugalGPT:如何在降低成本和提高性能的同时使用大语言模型”的研究表明,模型级联可以显著降低推理成本同时保持质量,使其成为这一更广泛原则的一种可能实现。

The architectural insight, however, is independent of any specific routing strategy. Deterministic governance transforms retries into explicit exceptions, allowing organizations to decide whether additional compute, additional context, or human intervention is the most economical next step. The system operates by governance by exception: Human operators and expensive premium models don’t review routine transactions. They only review the genuine anomalies where the baseline machine could not mathematically or semantically prove its own rationale.然而,架构洞察力独立于任何特定的路由策略。确定性治理将重试转化为明确的异常,允许组织决定额外的计算、额外的上下文或人工介入是否是最经济的下一步。系统通过异常治理运行:人工操作员和昂贵的高级模型不会审查常规交易。它们只审查那些基础机器无法在数学或语义上证明其自身合理性的真正异常。

Bounding the cost variance界定成本波动

With the execution infrastructure stabilized, the focus shifts to a critical operational challenge: cost variance.随着执行基础设施的稳定,重点转向了一个关键的运营挑战:成本波动。

In traditional software, execution costs are predictable. In probability-based systems, the exact same task might consume 500 tokens on Monday and 15,000 tokens on Tuesday if an agent enters a prolonged reasoning loop to resolve an edge case. For enterprise deployments, this unpredictable variance is often a more severe blocker than the base cost of inference.在传统软件中,执行成本是可预测的。在基于概率的系统中,如果代理进入延长的推理循环以解决边缘情况,完全相同的任务在周一可能消耗 500 个 token,而在周二可能消耗 15,000 个。对于企业部署而言,这种不可预测的波动通常比推理的基础成本更严重的阻碍。

By enforcing a strict computation budget per decision flow and utilizing the intent retry governor, the architecture places a hard ceiling on this variance. If an agent reaches its retry limit without producing a compliant policy, the runtime aborts the process and safely escalates it. While this doesn’t make AI operational costs perfectly static, it structurally bounds the financial exposure, ensuring that the compute cost of handling any single transaction never exceeds a defined limit.通过强制执行每个决策流的严格计算预算并利用意图重试治理器,架构为这种波动设置了硬上限。如果代理在达到重试限制时仍未产生合规策略,运行时会中止该过程并安全地将其升级。虽然这并没有使 AI 运营成本完全静态,但它在结构上限制了财务风险,确保处理任何单笔交易的计算成本永远不会超过定义的限额。

The financial slider equation财务滑块方程

With safety guaranteed by the runtime and cost variance capped by the infrastructure, the economics of agentic AI can be distilled into a single, formal equation:随着运行时保证安全和基础设施限制成本波动,代理式 AI 的经济学可以提炼为一个单一的、正式的方程:

Total Decision Cost = Compute Cost + (Escalation Rate × Human Cost)总决策成本 = 计算成本 + (升级率 × 人工成本)

This equation fundamentally changes the optimization problem. Traditional agent architectures treat model capability as a prerequisite for safety. Once governance is externalized, capability primarily influences escalation frequency. The question is no longer “Which model is intelligent enough to be safe?” but “Which combination of model cost and escalation rate minimizes total decision cost?”该方程从根本上改变了优化问题。传统的代理架构将模型能力视为安全的前提。一旦治理被外部化,能力主要影响升级频率。问题不再是“哪个模型足够智能以至于安全?”,而是“模型成本和升级率的哪种组合能最小化总决策成本?”

VariableScenario A (optimize for compute)Scenario B (optimize for automation)
Model capabilityLow (quantized/open source)High (flagship reasoning model)
Compute costNear zeroSkyrockets (high premium)
Safety boundary triggersFrequentRare
Escalation rateHighLow
Financial trade-offYou save money on APIs, but you pay for human operators to review anomalies.You save money on human payroll, but you pay a premium to the cloud vendor.
Safety resultStructurally boundedStructurally bounded

In both scenarios, the system is deterministically compliant. The choice is purely unit economics.在这两种情况下,系统都是确定性合规的。选择纯粹是单位经济学。

While a smarter model may reduce escalations by making better use of available evidence, no model can eliminate escalations caused by genuine business ambiguity. A $100 billion reasoning model can’t invent context it doesn’t possess.虽然更智能的模型可以通过更好地利用可用证据来减少升级,但没有任何模型可以消除由真正的业务模糊性引起的升级。价值 1000 亿美元的推理模型也无法发明它所不具备的上下文。

By decoupling safety from intelligence, you’re no longer hostage to the pursuit of perfect accuracy. Intelligence becomes a tunable economic variable, finally making agentic AI viable for the enterprise.通过将安全与智能解耦,你不再受制于对完美准确性的追求。智能成为了一个可调的经济变量,最终使代理式 AI 对企业变得可行。

Accuracy as a financial slider. The optimal model balances compute cost against escalation cost.
Figure 3: Accuracy as a financial slider. The optimal model balances compute cost against escalation cost.图 3:准确性作为财务滑块。最优模型平衡了计算成本与升级成本。

Engineering for imperfection为不完美而设计

As we scale these systems from isolated pilots to enterprise-grade operations, a stark reality comes into focus: The greatest risk in agentic AI is no longer hallucination. It’s unlimited spending performed by a system that believes it’s still making progress.随着我们将这些系统从孤立的试点扩展到企业级运营,一个残酷的现实浮出水面:代理式 AI 中最大的风险不再是幻觉,而是系统在认为自己仍在取得进展时所进行的无限支出。

We don’t need smarter, infinitely expanding models to safely deploy autonomous systems into high-stakes production environments. We need smarter systems that fundamentally assume the underlying model will eventually fail, drift, or lie.我们不需要更智能、无限扩展的模型来安全地将自主系统部署到高风险的生产环境中。我们需要更智能的系统,从根本上假设底层模型最终会失败、漂移或撒谎。

Consider how civil engineers build a suspension bridge. They don’t spend decades searching for “perfect steel” that will never bend, rust, or fatigue. They accept that the material is inherently flawed and subject to the laws of entropy. To compensate, they build redundancies. They calculate margins of error. They construct hard, load-bearing physical frameworks that dictate exactly how much stress the material is allowed to absorb before the structure safely redistributes the weight.考虑土木工程师如何建造悬索桥。他们不会花费数十年时间寻找永远不会弯曲、生锈或疲劳的“完美钢材”。他们接受材料本身是有缺陷的,并受熵定律支配。为了补偿,他们构建冗余。他们计算误差范围。他们构建坚硬的、承重的物理框架,规定材料在结构安全地重新分配重量之前被允许吸收多少压力。

Engineering for imperfection means designing around known material limits.
Figure 4. Engineering for imperfection means designing around known material limits.图 4:为不完美而设计意味着围绕已知的材料极限进行设计。

The software industry has spent the last three years searching for perfect steel. We’ve poured billions of dollars into massive evaluation suites, prompt engineering alchemy, and ever-expanding context windows, hoping to forge a probabilistic model that never hallucinates. It’s a mirage.软件行业过去三年一直在寻找完美的钢材。我们投入了数十亿美元用于大规模评估套件、提示词工程炼金术和不断扩展的上下文窗口,希望锻造出一个从不产生幻觉的概率模型。这是一个海市蜃楼。

Engineering maturity in the AI era doesn’t mean removing all imperfection from machine reasoning. It means designing an architecture so rigid, deterministic, and resilient that the model’s imperfections cease to be an operational liability.AI 时代的工程成熟度并不意味着消除机器推理中的所有不完美,而是意味着设计一种如此刚性、确定性和弹性的架构,使得模型的不完美不再成为运营负担。

The future of agentic AI is unlikely to be won by the organization with the smartest model. It will be won by the organization that most effectively separates intelligence from authority. Once reasoning and execution are decoupled, intelligence becomes a tunable economic parameter. Safety becomes infrastructure. And the endless pursuit of perfect model accuracy finally stops being a business requirement.代理式 AI 的未来不太可能由拥有最智能模型的组织赢得,而将由最有效地将智能与权限分离的组织赢得。一旦推理和执行解耦,智能就成为了一个可调的经济参数。安全成为了基础设施。对完美模型准确性的无尽追求最终不再是业务需求。

The end of that pursuit isn’t the end of AI. It’s the moment AI finally becomes engineering.这种追求的终结并不是 AI 的终结,而是 AI 最终成为工程学的时刻。

Note: The runtime described here is a reference architecture, not a specific implementation technology. The same principles can be realized through workflow engines, policy platforms, orchestration frameworks, or custom infrastructure. A sample implementation of these concepts is available in the GitHub repository.注:此处描述的运行时是一个参考架构,而非特定的实现技术。相同的原则可以通过工作流引擎、策略平台、编排框架或自定义基础设施来实现。这些概念的示例实现可在 GitHub 存储库中找到。

Post topics: AI & MLAI 与机器学习文章主题:AI 与机器学习

Try the O’Reilly learning platform尝试 O’Reilly 学习平台

With the O’Reilly learning platform, you get the resources and guidance to keep your skills sharp and stay ahead. Try it free for up to 14 days.通过 O’Reilly 学习平台,你可以获得资源和指导,以保持技能敏锐并保持领先。免费试用最多 14 天。

Start trial开始试用

Try a course for free免费尝试课程

Join a live online event on the O’Reilly platform to learn from the experts shaping tech.加入 O’Reilly 平台上的实时在线活动,向塑造科技的专家学习。

See what’s coming soon查看即将推出的内容

Get the Radar Trends newsletter获取雷达趋势通讯

Please read our privacy policy.