ccf-core/ccf-agent v1.0.1: hard min-gate coupling, QAC trust updates, and runtime certificates. Gate C exercised the computed runtime on Seed-class ARM hardware with driver-fed input. Unless a post cites a specific run, do not read it as proof of live sensors, mBot2 behaviour, Cognitum store validation, or production deployment.Where did the robot's familiarity come from? One answer, not three
A real moment
Niamh Kearney is the risk manager at St Kevin's General. The hospital is invented for this post, and so is Niamh, but the job is real. A delivery robot brings linen and supplies round eight wards. Four are adult wards in the old block. Four are children's wards in the new wing. The last of the children's wards, a day unit, opened three weeks after the robot arrived.
In its first week on the day unit the robot seemed at home. It was more forward than a newcomer should be. A parent mentioned it to the ward manager. The ward manager asked Niamh a fair question: had someone set the robot up wrong?
Niamh asked the supplier for an account. Their engineer ran the robot's log through a tool that explains how the robot shares familiarity between wards. The tool gave its answer as a list of reshuffles. Its biggest one said that, for nearly a quarter of the blend, the day unit and the ward beside it had been swapping records while the four adult wards passed theirs round in a ring.
That is a strange sentence to put in a risk report. It got stranger. A second engineer used a different tool, just as correct, and got a different biggest reshuffle for the same robot on the same day. A third tool gave a third. All three lists were mathematically right. They agreed on almost nothing.
Then someone asked a plainer question. Of the number the robot used on the day unit, how much came from each ward? That has one answer. In the simulated version of this week, about 81% came from the other three children's wards, about 10% from the adult wards, and about 9% from the day unit's own short history. On about 40% of visits, that borrowed number, rather than how calm the room was at that moment, was what set the limit on the robot.
Niamh could write that down. It answered the parent. It would read the same if anyone ran it again with any of the three tools.
Why this matters
Robots and software agents that learn from experience will be asked to explain themselves. Hospital risk managers will ask. So will insurers, families, and regulators. The EU AI Act asks providers to make high-risk systems transparent to the people who deploy them, and gives affected people a right to an explanation of individual decisions.
Explanations have a known weakness. For many systems there are several equally correct ways to describe why something happened. Statisticians call this the Rashomon effect, after the film where four witnesses give four different accounts of the same event. If an explanation is one of many, two auditors can be given two answers, and neither is lying. Explanations can also jump around when the system underneath barely changes. Researchers who test explanation methods for machine learning have shown both problems.
A robot that borrows familiarity between places adds a twist. The borrowing is the point. A robot that treated every new ward as a total stranger would be stiff and slow to settle. A robot that treated every ward as home would be rude. CCF lets a new place borrow a little from places that resemble it, under a hard limit, and earns the rest. That is useful. It also means that, when someone asks "why was it like that in there", part of the answer is somewhere else.
So the question for this run was simple. When the robot borrows, can we say where from, in a way that does not depend on which tool you happen to use?
What CCF does about it
CCF keeps one earned record of familiarity per context. A context can be a ward, a room, or a person. Before the robot acts in a context, two things are compared: how calm and readable the moment is right now, and how well the robot knows this context. The robot is held to the lower of the two. A robot that knows a place well still holds back in a tense moment. A calm moment in a strange place still gets caution. That hard limit is the core of the first CCF patent filing.
The borrowing step sits in front of that limit. A table, called the mixing matrix, says how much of each context's record every other context may use. Each row of the table adds up to one, and so does each column, so the robot cannot create familiarity out of nothing by moving it around. The filing builds that table in a specific way and gives two readings of it.
The first reading, in Claim 23 of the filing, uses a theorem from 1946 by Garrett Birkhoff. Any table of this kind can be written as a weighted list of reshuffles. Each reshuffle hands every context somebody's record. The filing presents this as a way to see what the borrowing is doing.
The second reading is in the paragraph that describes what the table means. For two contexts A and B, it asks how much of A's record is being treated as if it were B's. That is a plain split. For a new ward, it is the share of its number that came from each other ward.
This run built both readings for the first time, on tables made exactly the way the filing describes, and tested them in three ways.
How long is the list of reshuffles? For a robot with 8 contexts, the shortest of the three methods we tried needed about 50 reshuffles. For 64 contexts, the filing's upper limit, it needed about 600. Each reshuffle moved almost every context at once: on average 63 of 64 for random tables. The single biggest reshuffle carried about 4% to 10% of the blend. A reader shown "the main reshuffle" is seeing a small corner of the story.
Is the list unique? No. This is a known property of Birkhoff's theorem. What we measured is how far apart two correct lists for the same table can be. For 16 or more contexts, two methods produced lists with nothing in common, to three decimal places.
Does the plain split depend on the list? No. We rebuilt the split from each of the three lists and compared it with the split read straight off the table. They matched to better than one part in a million billion, which is the limit of the computer's arithmetic. You do not need the list to get the split. You can read it off the table directly.
The numbers
The hospital in the scenario is a simulation of 64 hospitals with eight wards each, two wings of four, and a new children's ward opening on day 20. In the new ward's first week, its own record averaged 0.32 on a scale of 0 to 1. Its blended record averaged 0.79. Of that blend, 81% came from the same wing, 10% from the other wing, 9% from the ward itself. The blended record was what set the limit on 40% of visits. The robot's average allowance, on the scale CCF uses, was 0.29 with borrowing and 0.14 on the ward's own record alone. So the borrowing roughly doubled what the robot was allowed to do in that first week, and the plain split says exactly where it came from.
The three lists of reshuffles for each hospital's table were almost completely different from each other. The split was identical in every case.
Cost: on one core of an ordinary desktop processor, the shortest list took 0.17 milliseconds for 8 contexts and about a quarter of a second for 64. The plain split is a handful of multiplications per context.
What this doesn't solve
The split says where a number came from. It does not say why the table weights the wards that way. In a real robot that table is learned over months. Explaining the table itself needs a record of how it was learned. In this run the table was fixed, so that question was out of scope.
The hospital is a simulation. Visits per day, how tense each visit was, and how fast the robot learns are stated settings, not measurements from a ward.
The table built the filed way is very slightly off balance after its 20 rounds of adjustment. A small amount of the blend then sits outside every reshuffle. On random tables it was about seven parts in a hundred billion. A tool that draws the list should report that leftover rather than drop it.
This run also found a limit in one filed setting. The fix is in the filing queue and will be written up once it is filed.
For the curious: the math
The filed construction takes a matrix of mixing scores M, clamps each entry to [-1.5, 1.5], exponentiates, and runs 20 rounds of Sinkhorn-Knopp scaling (alternate row and column normalisation). The result H is doubly stochastic up to rounding. The blended record for context i is m_i = sum_j H_ij c_j, and the gate is alpha = rho(min(C_inst, m_i)), using the hard min-gate from the ccf-core crate.
Birkhoff-von Neumann: H = sum_k w_k P_k, with weights w_k >= 0 summing to one and each P_k a permutation matrix. The classic bound on the number of terms is (n-1)^2+1, which is 3,970 at n = 64. Because the clamp keeps every entry positive, Birkhoff's original constructive proof (peel any permutation in the support, at the smallest entry along it) used exactly that many in every case we ran. The max-bottleneck greedy method (peel the permutation whose smallest entry is largest) is the standard heuristic; finding the fewest terms is NP-hard (Dufosse and Ucar, 2016). Greedy needed 50, 165, 333 and 628 terms at n = 8, 16, 32 and 64 before the weights fell below 1e-12.
We compared lists by total-variation distance over permutations: half the sum of absolute weight differences. Zero means the same list. One means no permutation in common. Between greedy and Birkhoff's original method, on exactly balanced matrices, the distance was 0.988 at n = 8 and 1.000 at n = 16 and 32.
The pairwise reading is the entry H_ij times c_j. Any decomposition reproduces it because summing the weights of the permutations that send i to j gives back H_ij. Measured rebuild error: at most 6.7e-16.
The Birkhoff reading here is a way of presenting the matrix. It is not the trust dynamic and says nothing about CCF's runtime certificate.
Where this fits
CCF is filed in a series of US provisional applications, starting with 63/988,438 in February 2026, which covers the per-context records, the hard limit, and the mixing table read here. Earlier nightly runs measured how many rounds of adjustment the table needs and how it behaves at scale. This one is the first to build the filing's swap reading and to check it against the plain split.
The research note with full tables is the public gist for this run, and the code is in the CCF repository on GitHub (github.com/Hulupeep/ccf) under crates/research/context-swap-explanation. The published ccf-core crate is on crates.io. The spec and contract tooling used to build CCF is Specflow (github.com/Hulupeep/Specflow).
License & contact
Research code is under BSL 1.1, converting to Apache 2.0 in 2032. For licensing, contact Flout Labs at floutlabs.com.