/>

When spend feels out of control: auditing agents by session, process, and tool

By The Lucidrail Team · 2026-07-06

A developer using Claude Code — a paid coding tool, not an experimental swarm of autonomous agents — opened an issue on the project’s GitHub tracker with a simple complaint. Their spend kept climbing even when they had stopped working.

the usage appears to continue increasing even when I am no longer actively working … completely out of my control as a paying user. — hayefmajid, on a Claude Code GitHub issue

The request that followed was not for a refund or a discount. It was for visibility — a way to see where the money actually went.

a way for users to audit token consumption by session/process/tool. — hayefmajid, on a Claude Code GitHub issue

This is one person, paying for one tool, on their own machine. The gap they are naming — no way to attribute spend to the thing that caused it — does not shrink as you add agents. It grows.

“Out of control” usually means “out of view”

It is worth noticing what this complaint is not. It is not a report of a large, dramatic bill. It is a report of a feeling — that spend is happening somewhere the user cannot see, for reasons they cannot check. That feeling has a precise cause. When you cannot attribute a number, every rise in it reads as runaway.

Control over spend is really control over attribution. If you can answer which session, which process, and which tool spent the money, a climbing bill is just information. If you cannot, the same bill is an alarm with no source.

The unit of the question is session, process, and tool

Look closely at what the developer asked for. Not a monthly total. Not an average. Per session, per process, per tool. That is an audit question, not a billing question.

A billing dashboard gives you one number, usually late. An audit gives you the story behind it: which agent, running which task, called which tool, and what that call cost. One tells you that you spent; the other tells you where and why. Only the second lets you do anything about it.

A team at Artificial Lab described the far end of this gap. They ran seventeen agents and had no per-agent view at all:

One day we realized we had no idea what they were spending… The UI for all of that spending was our credit card statement. Once a month. After the fact. — peiyaooo, on building an agent spend-approval tool (Show HN)

A credit-card statement is the exact opposite of a session-level audit. It is one figure, delivered after the fact, with no way to trace it back to the agent or the step that ran up the cost.

One tool is the easy case

The developer with the climbing Claude Code bill is running a single tool on a single machine and still cannot see spend by session. That is the simple version of the problem.

Now scale it. A fleet of agents running around the clock, each one spawning sub-tasks, each sub-task calling tools that cost money. The number of sessions, processes, and tools you would need to attribute grows quickly, and the credit-card statement stays exactly one number.

The stop button is missing too. One operator left an agent running, stepped away for twenty minutes, and came back to a bill they did not expect. When they went looking for a way to cap it, there was nothing:

I searched for a tool that could just stop the agent when it hit a dollar limit. Nothing existed. — sahiljagtapyc, after a surprise bill from an agent left running (Hacker News)

Two different people, one shape: spend they could neither see per unit nor stop at a line.

What being in control would actually look like

Being in control of agent spend is not the same as spending less. It is being able to answer a few plain questions at any moment, and to act on the answers:

The developer on that GitHub issue was asking for the first of these. Most people running agents today have none of the three.

This is the visibility we build at Lucidrail: per-company budgets with live metering and hard caps that stop a runaway before it bills, and an audit trail where every action traces back to the goal that prompted it — down to the agent and the tool it called. The aim isn’t to run more agents. It’s to answer “where did that go?” without waiting for a statement.

Lucidrail home · Security