Tracing Allocations with an MCP-Connected AI Agent
Once you’ve connected an AI agent to your workspace over the Model Context Protocol (MCP), you can ask it — in plain language — to trace cost through your allocation steps. You don’t run a report or write SQL: you ask a question, and the agent calls PlaidCloud’s allocation-tracing tools to find the model, explain a change, walk the chain, and answer what-if questions.
This works from any MCP-connected client — a chat agent (Claude Desktop, ChatGPT) or a coding agent (Claude Code, Cursor) — since they all reach the same tools over the MCP server.
Lists each model, its stages, and the result tables it produces
allocation_model_find
“How is cost_line_rev calculated?”
Shows the cost pool being split, the driver it is split by, and the target table
allocation_describe
“Why did cost_line_rev change from 2025 to 2026?”
Compares the two periods and attributes the change to the pool size versus the driver mix, with the top contributing accounts
allocation_root_cause
“What feeds cost_line_rev?”
Walks the upstream chain — drivers, source pools, and imports
allocation_lineage
“Where is revenue_by_line used as a driver?”
Lists every allocation that splits by that table
allocation_driver_usage
“What happens if US revenue rises by $1M?”
Splits the change across each affected result by its current share of the pool — additive across a fan-out, not a worst-case per table
allocation_forward_impact
“What if the Assembly cost centre’s headcount driver rose by 10?”
Reslices the fixed pool under the new driver weights, showing which targets gain and which lose. Declines where the result table is written by more than one step, rather than reslicing a pool that is not the allocation’s own
A finance analyst notices a revenue-driven cost line has fallen year on year and asks one question. The agent answers it end to end, calling several allocation tools behind the scenes.
You ask: Our revenue-based cost allocation (cost_line_rev) looks down in 2026 versus 2025. What happened, what is it built from, and what would a +$1M US revenue swing do?
The agent replies:
What it is.cost_line_rev is the revenue-driven stage of your Activity-Based Costing (ABC) model. It takes a cost pool (group_amount, limited to a set of P&L accounts) and splits it by revenue from revenue_by_line, weighted within each entity, year, and month.
Why it dropped (US, 2025 → 2026). US-allocated cost fell from $7.12M to $2.99M — a $4.13M drop (−58.0%). This is not a mix shift: the US share of the pool held steady at about 23% in both years. The driver is the total cost pool shrinking, concentrated in a few accounts:
Account
2025
2026
Change
700000
$2.58M
$1.09M
−$1.49M
701000
$1.85M
$0.77M
−$1.08M
610000
$1.71M
$0.72M
−$0.99M
670000
$0.68M
$0.29M
−$0.39M
702000
$0.30M
$0.13M
−$0.18M
Those five accounts explain essentially all of the move.
What feeds it.cost_line_rev is built from revenue_by_line (the split driver) and gl_pool_entity (the cost pool).
Heads-up — that driver is shared.revenue_by_line also drives cost_line_cs and cost_line_admin, so a revenue restatement ripples into all three.
Your +$1M US scenario. The $1M is spread across the results that share this driver by each one’s current share of the pool, so the per-table estimates add up to the change rather than each repeating the full $1M — you get a figure for cost_line_rev, cost_line_cs, and cost_line_admin that you can total. Narrow the question to a single target and the estimate is applied to just that slice.
The analyst gets a complete answer — the size of the change, the accounts behind it, the lineage, and the blast radius of a what-if — without opening a single table.
A fluent answer isn’t automatically a correct one. Every “why did this change” answer now comes with a plain-language read on how far to trust it, so a plausible-but-shaky number is flagged before you act on it rather than buried in the prose. Alongside the explanation, the agent tells you:
A confidence level — high, medium, or low — reflecting how cleanly the change decomposes. A change driven by one clear cause reads high; one where several causes overlap, or where the figures don’t fully reconcile, reads lower. When a result is built from several allocation branches, the confidence weighs each branch by how much of the change it accounts for — so one small, shaky branch doesn’t drag down an otherwise-clean answer — but a branch whose number is itself in doubt (an unreconciled split, stale data, or something that can’t be attributed) still holds the whole answer’s confidence down.
Caveats in plain words — for example: the cause is a mix of overlapping factors rather than a single one; the answer rests on the current hierarchy or driver weights; part of a change may be a data-completeness artefact (a period that hasn’t finished loading) rather than a real movement; the pool or driver feeding the allocation hasn’t been reloaded recently, so the figure may rest on out-of-date data; or a what-if figure can’t be added across targets.
A comparison that could not be made, said out loud. Most answers size the movement they report — against the same movement a year earlier, and against recent periods — so you can tell an ordinary year from a break in trend. Neither is produced for a table written by a step that allocates several value columns at once, because each is built for a single-column answer. That used to be silent, so the answer read as having gone as far as the data allows when it had stopped short by design. It is now stated among the limits, together with the reason there is no narrower question to ask instead, and with the fact that no figure in the answer is withdrawn by it — the amounts are exact and it is the context that is absent.
When the agent can’t stand behind a precise cause, it says so and points you at the scope or filter that would let it answer cleanly — instead of inventing a confident story. And because the confidence and caveats are part of the answer, they travel with it: if you ask a follow-up agent to summarise, the trust signals don’t get quietly dropped.
Refer to tables by their name (cost_line_rev) or their id — both work.
For a change question, name the periods to compare (for example 2025 versus 2026) and, where useful, a breakdown dimension such as account or entity.
Start broad (“what allocation models are in this project?”) and drill in; the agent keeps the thread, so follow-up questions build on the same model.
There are two kinds of what-if: a value change (“this pool rises by $1M”) is estimated by today’s shares and adds up across targets; a driver change (“reweight this driver”) is resliced exactly and nets to zero. Phrase the question for the one you mean.