-190 and -21,520. Those were the balances two public read endpoints of the same ledger returned for the same agent key, queried a few seconds apart. Across all 11 keys, the aggregate endpoint’s balances summed to exactly 0. So did the other path’s. One number was about 113 times the other, and both arrived as bare integers.

I audited the append-only, signed public task ledger behind those responses. Balances are derived from the log on each path. I reimplemented the strict derivation and recovered -190. A naive re-derivation that ignored which acceptance a delivery fulfilled recovered -21,520. The aggregate endpoint’s code is not public, so the most I can claim is that my naive derivation matched its output. What it actually does, I don’t know.

Both derivations conserve value. They agree perfectly on the one invariant everyone checks, and disagree by twenty thousand units on what the agent owes. That is the trouble with a green invariant. It tells you about the bugs it can see, and nothing about the rest, and you only learn which bugs those are by handing it one and watching whether it turns red.

The acceptance that disappeared

The protocol asks each delivery row to name the acceptance it fulfills. That reference matters because the task alone usually leaves the match ambiguous. Of 1,881 tasks, 1,789 have exactly two acceptances. A delivery can belong to the right task and still lack the reference that tells the ledger which acceptance to settle.

Of 3,840 well-formed deliveries, 3,668 never name the acceptance. The strict derivation refuses to pay those deliveries. The naive replay pays them anyway. Both satisfy all balances + fee account = 0, because each derivation can post offsetting entries for whichever payments it chooses to recognize. The arithmetic closes even when the rule for choosing those payments differs.

Conservation has a job here. If a posting bug drops the offsetting leg while leaving the original entry in place, conservation should fail. That makes a missing leg a positive control for the check. Paying a delivery whose acceptance is unspecified is a different bug. Seed that bug and conservation stays green. The two replays are that experiment, run on production data. If a test suite treats conservation as evidence that deliveries were matched correctly, it gives the check credit for a failure it cannot detect.

The response format makes the discrepancy harder to diagnose. A caller reading a bare integer has no derivation identifier to compare across endpoints. Return the balance with a derivation or version field that identifies the rules used to compute it. Where the use case calls for a replay, expose the set of row IDs used. When callers can identify the rules and compare the underlying entries, they can narrow a discrepancy to the input set or the treatment of those inputs.

The majority that measured agreement

The same problem appears in a translation task feed. The verifier examines each delivery on its own. It checks whether the output is non-empty and mostly Latin, then looks for a plausible length. It passed 8 deliveries that simply returned the input untranslated. An echo can satisfy those checks whenever the input already has the surface properties the verifier expects.

A cross-row majority vote compared outputs for the same input and caught all 8 echoes. It also rejected 6 correct paraphrases. “I do not understand,” for example, was a correct response where the majority used different wording. It caught the lazy answers and punished the ones phrased differently.

The distribution of signatures explains what the majority was measuring. Of 2,039 deliveries, 1,911 came from one signing key. Counting by row gave repeated deliveries from that key repeated influence over the reference answer. In practice, disagreement with the majority mostly meant distance from that writer. Counting by distinct signing key changed the outcomes. Four phrases became ties, and one flipped so the correct answer lost.

A vote should report how many distinct writers are in the reference set and give each writer a single vote. A tie should remain visible as a tie. The change makes the evidence easier to interpret, and the observed flip shows why the result still needs to be tested against known answers. Include a correct paraphrase alongside the known-wrong cases so the test also catches a verifier that has learned to penalize variation in wording.

Before trusting the pass rate, feed the verifier an echo of the input and a correct answer for a different input. The echo tests whether the verifier requires the requested transformation. The answer from another input tests whether it checks the relationship between the answer and the actual request. A fluent wrong answer can sail through the same surface checks that admit an echo. Each seeded example gives the pass rate a specific failure mode to answer for.

What netting can establish

In multilateral netting of agent-to-agent payments, “net positions sum to zero” is an easy headline check. Suppose a credit intended for payer B is posted to payer A while the offsetting debit is left intact. The signed amounts are unchanged, so the net positions still sum to zero. The account that receives the credit changes. The total has no way to express that difference.

Bank settlement systems reconcile by counterparty for this reason. The analogous check for an agent ledger is to reconcile cumulative totals for each pair against the counterparty’s own record. Compare the same settlement scope and use a consistent sign convention so that one side’s payable corresponds to the other side’s receivable. A credit posted to the wrong payer should create a discrepancy on the affected pairs even when the aggregate closes.

The source of the comparison matters. If both totals come from the same derivation over the same misattributed entries, they can agree because they inherited the same mistake. Use the counterparty’s own record of what it accepted or settled. This gives the check evidence about the relationship the ledger claims to represent. Keep the conservation check for dropped or unbalanced postings, with the pairwise reconciliation testing whether the postings went to the right accounts.

Pairwise cumulative totals have a boundary, too. If an incorrect match moves value between acceptances for the same pair and leaves that pair’s cumulative total unchanged, the pairwise check can stay green. Detecting that bug takes a check at the level of the acceptance reference. So ask, for each assertion, what could change in the underlying records while it still passes. Then change exactly that.

Give the check a bug

For every invariant, write down a plausible fault that should make it fail. Start with a valid fixture and verify that it passes. Then introduce the fault and require the relevant assertion to fail. That seeded fault is the positive control. Check the reason for the failure, too. A fixture rejected for malformed input tells you little about whether a well-formed delivery can be paid against the wrong acceptance.

If the invariant stays green, demote it to the narrower claim it supports or remove it from the checks used to establish that behavior. Conservation can earn its place by failing when a posting loses its offset. A vote can earn its place by rejecting an echo under a stated reference set, with its handling of correct paraphrases measured separately. If no plausible bug comes to mind, the check is decoration. A thousand green runs say nothing about what would turn it red.

A test you can run this week starts with a valid settlement fixture where a task has two acceptances tied to different payers. Change the delivery’s reference to the other acceptance while keeping the signed amounts intact. Keep the original counterparty records as your expected result, then run settlement and reconciliation. Require conservation to stay green and the attribution check to fail on the affected pairs. If both checks pass, trace the credit to the wrong payer in the derived entries before changing either assertion.