Manuscript Offprint

arXiv:2610.02036

Global Coherence: When Every Agent Is Right and the Team Is Still Wrong - A Local-to-Global Semantic Foundation for Multi-Agent Collaboration

Xin Heng

Abstract

AI agents now work together on shared code, documents, tools, and scientific analyses, often alongside people. No participant sees the whole state. Every step can look right on its own while the combined result is wrong. We call this the global coherence problem, and we argue that it is a problem of state, not only of intelligence: a stronger model makes better local decisions, but it cannot see what is not in its context, and it cannot make locally valid pieces fit together when they do not. Intelligence alone cannot guarantee a solution. To our knowledge, this paper is the first to formulate this as a failure class of AI agent systems in its own right and to synthesize the relevant limits into specifications for two practices builders already use for reliability, context engineering and the agent harness: what each agent's context must contain, and what the harness around the agents must own and check.

Our first result, the Observation-Aliasing Impossibility Theorem, makes the missing-information case precise. A policy can guarantee a valid action from its context exactly when every world consistent with that context allows a common action. When two worlds look identical but require different actions, no amount of reasoning, deliberation, role decomposition, messaging, or randomization can guarantee the right choice. The best randomized policy succeeds with probability exactly 1/k1/k when kk indistinguishable worlds have disjoint valid actions, and a bb-bit hint raises this to at most 1/⌈k/2b⌉1/\lceil k/2^b \rceil. This is a theorem about context engineering: it says exactly what a context must contain. Choosing the smallest such context is NP-hard: putting everything in every window is rarely feasible, and finding the least that suffices is hard.

The second failure survives full information. Three agents can each use a locally valid, inverse-consistent translation between neighboring units while the loop through all three does not close; three roles can each make a legal spend while the total breaks the budget. No local check identifies the global error, because it lives in how the pieces fit, not in any one piece. Checking harder locally does not solve this in general: pairwise checks suffice when overlaps are tree-like, cycles can defeat them, and no fixed locality bound works universally across unrestricted constraint semantics. The two failures are linked, and the link is the paper's central construction. The impossibility theorem says which distinctions a harness must keep; the second failure is what happens when those distinctions are lost on the way, as state is split into local views, re-encoded between participants, or changed by actions. We give a principled synthesis for guarding all three steps: a topology of where things meet, sheaves for whether local states glue into one world, groupoids for which encodings mean the same thing, and categories for how actions compose over time. These structures are not uniquely forced machinery. Under explicit assumptions on local views, lossless translations, and state updates, each realizes a property that exact validation requires, and each becomes unnecessary when its corresponding map is absent. Version checks, dependency engines, ledgers, and escrow quotas are domain-specific realizations of the same requirements. The same language also prices the problem. Agreement across representations can be certified in linear time, yet finding the smallest repair can be NP-hard, and a shared budget cannot be protected by independent local checks at all: it must be enforced at commit or split into quotas. The design these two failures lead to goes further than a manager agent, which is one more participant with one more view and is bound by the same theorem: models propose, and a harness built on this framework decides what is allowed. The framework tells that harness its job: which distinctions it must own, where overlaps can hide global inconsistency, which loops of translation must close, and which changes must wait for commit.

We test the theory in nine studies. A frontier LLM solves all 40 tasks of a revision benchmark when it can see the deciding event. With that event hidden, observed accuracy across tested reasoning, role, voting, and tool conditions is statistically compatible with guessing among three options (1/3); one sentence restoring the missing fact brings it to 40/40. On a preregistered 60-run TeamBench panel, ordinary agent teams overspend a shared 20-call budget in 5/5 runs, showing them the live count still leaves 4/5, and enforcing the budget at commit leaves 0/5; observed mean task progress does not fall in this five-seed comparison. A follow-up on the same task shows that fixed per-role escrow quotas also reach 0/5 violations, while an information-only counter still overspends in 4/5; progress comparisons between escrow and the ledger are descriptive because their attestation gates differ. Under an explicit unique-name diagnostic, public ontology-alignment networks contain pairwise-invisible same-ontology identity collisions in 23 of 45 networks from 2018–2024. Agents given split views reproduce such collisions in 9 of 40 merges, and a network-level check detects and removes all nine, although the send-to-all repair lowers mean F1 from 0.796 to 0.774. In a preregistered 222-episode τ2\tau^{2}-bench Telecom panel, ordinary policy checks tie our coherence harness where the injected change breaks a policy rule, as predicted; where a committed change is silently undone, agents with those checks score 0.07 on the benchmark's own grader and agents with the harness score 1.00. Where a conventional tool already holds the relevant state—a dependency engine, a coupled solver—it matches our harness exactly, as the theory predicts. Across all nine studies the pattern is the one the theory draws: the harness wins where the deciding state is missing or unowned, and ties where a conventional tool already owns it. The proofs are complete and given in the appendices; the agent evidence uses one model family and modest panels, and scale is the next step.

1 Introduction: every step looks right, and the result is still wrong

Consider a three-agent team on a TeamBench task [51]: a Planner writes the plan, an Executor runs commands, and a Verifier checks the result, with 20 command runs allowed for the whole team. Each agent spends runs for good reasons, and no single run is a mistake. But the limit belongs to the team, no agent owns it, and the team spends about three times the budget. This is the failure this paper is about: every step is locally justified, and together they break a rule that belongs to no one. Showing the team the running total did not fix it. When the harness itself held the count and refused the 21st run, the violations disappeared; observed mean task progress did not fall in that five-run panel (Study IV).

The pattern is general. In τ2\tau^{2}-bench Telecom, a user and an assistant change different parts of one environment under different permissions [12]; in BixBench3, several scientific artifacts must stay derived from one evolving analysis [25]. The participants act on local views, each step can be locally correct, and the combined result need not be:

local validity ≠\neq global coherence.

Two ways to fail. Figure 1 sketches both. The first is observation aliasing: two situations look the same to every participant but need different actions, as when two revision histories produce the same log once one event is hidden. Our first result, the Observation-Aliasing Impossibility Theorem (Theorem 2.1), says exactly when this is fatal: a policy can guarantee a valid action from what it observes—for an LLM agent, its context—if and only if every world consistent with that observation allows a common action. When that fails, no amount of reasoning, deliberation, role decomposition, messaging, or sampling recovers the difference; with k look-alike worlds whose admissible-action sets are pairwise disjoint, the best randomized worst-case success is exactly 1/k (Theorem 2.3). A stronger model searches better within its context; it cannot see past it. Context engineering helps exactly when it puts the missing distinction into the window, and longer reasoning over the same window does not. This separates intelligence from identifiability, for human, AI, and mixed teams alike. In Study I, a frontier LLM solves all 40 tasks when it can see the deciding event; when that event is hidden, observed accuracy across the tested inference strategies is compatible with chance (1/3), and one sentence of added context stating the missing fact brings it back to 40/40.

The second failure concerns information the participants do have. Everyone can pass the checks available in their local scope while the whole is not coherent, because locally consistent pieces need not fit together into any single global state. Three pairwise translations can each be well formed, inverse-consistent, and locally plausible while the loop through all three does not return to where it started; three roles can each make a legal spend while the total breaks the budget, as in the TeamBench team above.

Four questions. The paper asks what can be said about these failures before choosing any particular agent design. We separate four questions:

• Observation. Do the local views contain enough information for globally valid behavior?

• Realization. Do locally compatible pieces correspond to any global state?

• Transition. Do local actions combine into a valid global change?

• Semantic state. What is the least information that must be kept to decide which futures remain valid?

Cost cuts across all four: how much state must be observed, how hard global checking is, how hard it is to design the smallest sufficient set of observables, and whether repairing an inconsistency is harder than detecting it.

The framework. The first question has a sharp answer, the impossibility theorem, and it says what the harness must keep and every decision's context must reach: every distinction that changes which actions are valid (Proposition 2.4). The rest of the paper answers how. In a team the state is never in one place and never still. It is split into local views, re-encoded between participants, and changed by actions, and each of these steps can silently lose a distinction the theorem says must be kept. Mathematics already has a precise structure for each step. Together they form the paper's central construction,

X=(H,C,G,F;D).\mathfrak{X}=(H,\mathcal{C},\mathcal{G},\mathcal{F};D).

Figure 2 shows all five on one example: a Design agent, a Fabrication agent, and a Cost agent share one beam, and each records its length in its own unit.

• A topology H: where things meet. H records which participants' scopes overlap, and on which shared state. Here all three agents hold the beam length, so H is a triangle. In general it is a hypergraph, because one field can be shared by many participants at once. Its shape helps decide when local checks are enough: on join trees pairwise agreement suffices, while cycles can hide inconsistency from pairwise checks.

• A groupoid G: what only looks changed. The objects are the encodings of one thing (1 m, 1000 mm, 39.37 in) and the arrows are the translations between them ( ×1000\times 1000, ÷25.4\div 25.4, ×0.0254\times 0.0254). Every translation can be undone; that is what makes this a groupoid, which is like a group except that two arrows compose only when one ends where the other starts. The check that matters is that translations composed around any loop return the identity. A single wrong factor, ÷25\div 25 instead of ÷25.4\div 25.4, looks plausible on its own edge and brings 1 m back as 1.016 m around the loop.

• A sheaf condition F: whether one world glues. Each agent holds a local piece of data: 1 m, 1000 mm, 39.37 in. The sheaf condition asks whether pieces that agree on every overlap come from exactly one world, here exactly one beam. When it holds, local agreement is enough; when it fails, the pieces agree everywhere and come from no world at all. This is where “every agent is right and the team is wrong” becomes a condition a harness can check.

• A category C: what can change. The objects are versions of the shared state and the arrows are actions that really change it: revise the beam to 1.2 m, then order $720 of steel. Arrows compose into histories, most cannot be undone, and order matters, so this is a category rather than a groupoid. The line between the two is the line between 1 m → 1000 mm, which only re-expresses the beam, and 1 m → 1.2 m, which changes it. Only changes are checked at commit.

• A history state D: what still matters. This is the theory of agent memory. Of the whole past, the harness keeps only what changes which future actions are legal: here the budget left and the version each agent last read. That is enough to refuse an order priced from the v3 quote once the beam is revised in v4. The rest of the log can be dropped.

This is a principled synthesis, not the only possible implementation. Corollary 4.2 shows that exact validation requires particular properties under explicit assumptions: realizable gluing for distributed views, reversible loop-consistent

(a) Missing information

Figure

(b) Pieces that do not glue

Figure

Figure 1: The two failure modes. (a) Two worlds that need different actions produce the same view, so no policy that acts on the view can be right in both (Theorem 2.1). (b) Three views agree pairwise, yet no single world agrees with all three; the inconsistency lives on the loop, not on any edge (Sections 3.1 and 3.3).

(a) One beam, three agents, three units

(b) Changes, commits, and memory

Figure

Figure 2: The framework X=(H,C,G,F;D)\mathfrak{X} = (H, \mathcal{C}, \mathcal{G}, \mathcal{F}; D) on one example. (a) Three agents share one beam. HH is the triangle of who shares what, and because it is a cycle, pairwise checks are not enough. G\mathcal{G} is the unit translations on its edges, which must return the identity around the loop. F\mathcal{F} asks whether the three local values come from one beam. (b) C\mathcal{C} is the real changes, which compose into a history and are checked at commit. DD is the little the harness must remember to check them; here it refuses an order priced for the old beam.

translations for lossless formats, and self-updating semantic state for actions and history. The named structures are standard, compositional realizations of those properties, and each drops out when its corresponding map is absent. The framework also absorbs what practitioners already use: version checks, dependency engines, ledgers, escrow quotas, and residual solvers are domain-specific realizations, and in our experiments each one matches the general harness exactly where it already owns the relevant state. Other routes exist—weakening the goal, restructuring state, accepting probabilistic success—and we price each one (Appendix F.4). Sections 3–4 develop the synthesis in the language of agent systems, and Section 4.3 derives the required properties and shows how these structures realize them; no category theory is needed to follow the argument.

What the theory says. Beyond the impossibility theorem itself, we give the exact success rate of the best randomized policy in general (Theorem B.2) and the number of bits of new information needed to raise it (Corollary B.3). Choosing the smallest set of fields or sensors that makes validation exact is NP-hard (Theorem 2.5). For the second failure, classical database results say local agreement is enough on tree-like overlap structures (Theorem 3.1), while cycles can make pairwise agreement insufficient. More generally, no fixed locality order works universally across unrestricted constraint semantics (Proposition 3.2), although structured cyclic classes can admit bounded tests. Agreement across different representations reduces to a cycle check that a spanning forest certifies in linear time (Theorem 3.4, Corollary 3.5), but repairing a disagreement at minimum cost is NP-hard (Proposition 3.6). Actions that change state are different from actions that only re-express it: re-expressions preserve global consistency automatically, while individually valid spends against a shared budget can jointly break it (Propositions F.4 and 3.3). So consistency must be checked when changes are committed, and version checks with atomic commit give the usual serializability guarantee, provided every value a change depends on is recorded (Proposition 4.1).

Why “just give everyone all the information” is not the answer. A natural reply is that the impossibility theorem is correct but easy to escape: share all the context, and every agent will be right about the whole. We claim more than the theorem. Its corollaries are correct, and global coherence stays hard even in principle, for five separate reasons.

• Sharing everything is rarely an option, and sharing the least is hard. Context windows, bandwidth, privacy, and authority limit what each participant can see. So the real question is what to share, and removing aliasing requires exposing every distinction that changes which actions are valid. Finding the smallest context—the fewest fields, sensors, or log entries—that does this is NP-hard, and greedy selection is essentially the best polynomial-time approximation (Theorem 2.5). Also, in a team each decision is made on the acting participant's own information set, not on the union of everyone's views (Corollary 2.2).

  • Local agreement does not always add up. Pairwise checks are enough when the overlaps form a join tree. Cycles can defeat pairwise checks, and no fixed locality bound is universal across unrestricted constraint semantics; structured cyclic classes can nevertheless admit bounded tests (Theorem 3.1, Proposition 3.2). Exact global checking costs time exponential in the width of the interaction structure in the general finite-domain case (Section 3.4).

• Finding an error is easier than fixing it. A spanning forest certifies that representations agree in linear time, but finding the fewest labels to change is Max-Cut-hard (Proposition 3.6).

  • Shared constraints need coordination. Spends that are each legal on their own can merge into an illegal total (Proposition 3.3). The ways out are coordination at commit or a redesign such as escrow quotas, and each has a price (Appendix F.4).

  • Change and time add their own conditions. Re-expressing state preserves gluing, but changing state does not (Proposition F.4). A long-running process must carry exactly the history that still matters (Theorem F.3), and a commit is safe only if everything it read is still current (Proposition 4.1).

The theory also says when coherence is easy: when one participant can hold and act on the whole exact state, the extra structure should add little (Section 5.11, Prediction 1). The hard case is ordinary multi-party work, where authority, views, and shared resources are split. Sections 3 and 4 prove these points. Section 5 shows them in agent runs. Showing the live budget to every agent still leaves overspending in 4 of 5 runs, and only ownership at commit or escrow stops it (Study IV). A single agent with the full view keeps an alignment network coherent, but agents with split views leave conflicts that only a network-level check finds (Study IX). And checks on the current state miss what changed since the agent read it: in τ2\tau^{2}-bench Telecom they commit on a stale quote in 10 of 10 episodes, and they never notice when a committed change is silently undone (Study V).

Hardness results for decentralized decisions are known in pieces, from team decision theory to decentralized POMDPs (Section 6), and software and systems research has long supplied related compositional structures. This paper's contribution is to synthesize those conditions for AI agent harnesses: one framework organizes missing distinctions, cycles, shared invariants, repair, and time, helps diagnose which conditions a system faces, and names standard structures that realize the required properties. The nine studies test these pieces, the central ones on agent benchmarks under a fixed model.

What this means for building agent systems. The theory separates two jobs, and they map directly onto how agents are built today. The model supplies proposal intelligence: interpreting intent, planning, choosing tools, and drafting changes. The harness supplies state, admissibility, and commit: it decides what enters each agent's context, holds the distinctions that matter, checks each proposed tool call against them, and accepts, repairs, or rejects it. Context engineering and harness design are usually practiced as craft; the theory turns them into specifications. The impossibility theorem says what a context must contain, and the framework says what the harness must own and check. The model can stay as flexible and stochastic as it likes; what must be fixed is the shared record of facts that decide what is allowed. Stronger models improve the first job. They cannot replace the second when the needed distinction is missing from what they see. The limits bind every layer. No matter how capable the model or how well engineered its context, a constraint that several agents act on needs an owner (Proposition 3.3, Study IV). And no matter how carefully the harness is built, it guarantees only what its own state can tell apart (Proposition 2.4), catches a contradiction around a loop only if some check spans the loop (Proposition 3.2), and catches a stale read only if it remembers what each proposal read, since against the current state alone a stale proposal and a fresh one look the same (Theorem 2.1 applied to the harness itself, Study V). The harness is also a different thing from a manager or orchestrator agent. A manager is a model too: it proposes from its own view, so Corollary 2.2 binds it like any other role, and in Study IV a team with a dedicated Planner and Verifier still overspent its budget when shown the live count. Where an orchestrator does work, the framework says why: a hub that holds the shared fields makes the overlaps a tree, and on trees local checks are enough (Section 3.1). The harness is not a smarter participant. It owns the state, and the framework tells it which state to own, what to put in context, and which checks to run. The same results answer the team-design questions practitioners usually settle by intuition: who should own a decision, which roles can work in parallel, and who must wait for whom (Section 4.5).

What the evidence shows. The studies follow the two failure modes; 1^{1} Figure 3 shows four causal results. A frontier LLM solves all 40 aliasing-probe tasks when it can see the deciding event; with that event hidden, all tested arms are statistically compatible with chance (1/3), and one sentence stating the missing fact restores 40/40 (Study I, Section 5.2). The finite panel supports the predicted contrast but does not establish empirical equivalence to chance. When actions change shared state, ordinary TeamBench teams overspend a shared budget in 5/5 runs, exposure leaves 4/5, and commit enforcement leaves 0/5; observed mean progress does not fall in the five-run enforced comparison (Study IV, Section 5.5). On the same budgeted task, per-role escrow quotas also reach 0/5 violations while an information-only counter still overspends in 4/5; progress differences between escrow and the ledger are descriptive because their

1^{1}The code and run records for all nine studies will be released.

(a) Study I: hidden deciding event

Figure

(c) Study IX: split views

(b) Study IV: shared budget

Figure

Figure

(d) Study V: silent reverts in τ2\tau^{2}

Figure

Figure 3: Headline results, all with the same LLM (models and settings in Section 5). (a) The LLM solves all 40 tasks when the deciding event is visible. With it hidden, the tested arms score 12–17 of 40 and none is significantly above chance (1/3); adding the missing fact (blue) gives 40/40 again. One majority-vote cell failed on an API error, so that arm has 39 tasks. (b) Each dot is one of five runs of TeamBench's budgeted-workflow task (LH2). Ordinary teams overspend the 20-call budget in 5/5 runs; showing the live count still leaves 4/5; enforcing the budget at commit stops every run at exactly 20. (c) Ontology-alignment tasks under the stated unique-name rule: agents with split views leave hidden collisions in 9 of 40 tasks; a pairwise check never fires; a network-level check removes all nine, with the repair-quality cost reported in Study IX. (d) τ2\tau^{2}-bench Telecom tasks in which a change the agent already committed is quietly undone, scored by τ2\tau^{2}'s own grader: the stock agent and call-time policy checks believe the job is done; the coherence harness sends one notice and the agent redoes the change in 15 of 15 episodes. Bars and dots are plotted directly from the recorded run results.

attestation gates differ. Under an explicit unique-name diagnostic, public OAEI ontology-alignment networks [66] carry pairwise-invisible same-ontology identity collisions in 23 of 45 networks across seven years (Study VIII, Section 5.9). Agents given split views reproduce them in 9 of 40 merges, a single full-view agent leaves none, and a network-level check removes them all; the current send-to-all repair lowers mean F1 from 0.796 to 0.774, so detection succeeds while repair routing remains open (Study IX, Section 5.10). When state changes under a user and an assistant in τ2\tau^{2}-bench Telecom, ordinary policy checks tie the coherence harness where the change breaks a policy rule, as predicted; but they commit on a stale quote in 10 of 10 episodes, and when a committed change is silently undone they score 0.07 on the benchmark's own grader while the harness scores 1.00 (Study V, Section 5.6). Where a conventional mechanism already owns the relevant state—dependency closure for stale derivations, a residual solver for coupled design—it matches the general harness exactly (Studies III and VI). The theory predicts that equality; the studies above test the boundaries where no such mechanism exists.

What is new. This paper’s novelty is the agent-facing synthesis and operationalization. To our knowledge, it is the first work to formulate global coherence as a failure class of agent systems in its own right, separate identifiability and commit semantics from model capability, and assemble the relevant information-theoretic and local-to-global conditions into a framework that says what each agent’s context must contain and what the harness must enforce. The mathematical ingredients have important precedents, credited below; the contribution is connecting their guarantees and limits to agent harness design and testing the resulting boundary. The experiments probe its counterintuitive parts:

  • A stronger model is not the fix for missing information. A model that solves every task when it can see the deciding fact produces accuracy statistically compatible with chance when that fact is hidden across the tested reasoning, deliberation, and voting conditions; one added sentence stating the fact solves every task again (Study I). The theorem supplies the general impossibility statement; the finite panel is consistent with it.

• More context is not the fix for shared state. Context fixes missing information, as Study I shows, but agents who have the live budget in their context still overspend it. A shared invariant needs an owner: enforcement at commit, or quotas that split it (Study IV).

• Checking every handoff is not the fix. Every pairwise review can pass while the integrated result is impossible, in public benchmark data and in agent runs alike (Studies VIII and IX).

• Checking the current state is not the fix. A commit can rest on a stale read, and a committed change can be silently undone, while every check on the current state passes (Study V).

The mathematics is deliberately borrowed, and that is a strength. Acyclic database schemes, group synchronization, sheaves, treewidth, Myhill–Nerode minimization, and optimistic concurrency control are each battle-tested in their own field, and we credit each where it appears. What was missing is the bridge to AI agents: identifying the validation properties distributed agent systems require, showing how these classical structures realize them under explicit assumptions, and telling builders when each property matters and when it does not. The new formal results serve that bridge: the admissibility form of the aliasing theorem with its exact randomized value and bit bounds, and the hardness of choosing the smallest state to expose, a close relative of minimal reducts in rough-set theory (Appendix A sorts every result by origin). The contribution is the bridge, not new mathematics. The empirical claims are deliberately narrower than the theory. They use one model family, a synthetic aliasing probe, five seeds per arm on three TeamBench tasks, and failures that we inject into τ2\tau^{2}-bench tasks. Within that scope the result is that the predicted failures occur, the tested inference variations do not remove them, and owning the missing state does. How often these failures dominate on broad agent benchmarks is the next question, and the theory says where to look.

References (79)