AI Cost Tracking per Customer
AI cost tracking per customer ties every model and infrastructure cost to the specific customer that generated it, so you can see cost to serve, margin, and profitability for each account. Bear Lumen attributes token usage from provider responses to your own user or account IDs, then compares it against revenue to surface which customers are profitable and which are not.
What per-customer cost attribution shows you
When every model call is tagged with the customer that triggered it, cost stops being a single company-wide number and becomes a property of each account. You can rank customers by cost to serve, put that next to what they pay, and read the margin for each one directly.
That view answers the questions an aggregate bill cannot: who is expensive, who is profitable, and which accounts to reprice, upgrade, or investigate.
Finding unprofitable customers
The most common surprise in AI products is the power user: an account whose usage is high enough that the model cost to serve them exceeds what they pay. On a flat plan they look like any other customer until you attribute cost per account. Once you do, they stand out immediately.
Customer margin = Revenue − (attributed model cost + compute + overhead)A customer on a $99 plan runs a retrieval agent that makes dozens of model calls per session. Attributed model cost comes to $130 a month. Their margin is negative $31, and per-customer tracking is what makes that visible before it scales.
How to attribute AI cost to a customer
Send your own user or account ID with each usage event. Bear Lumen computes the cost of each call from its token usage and rate, groups those costs by your ID, and updates cost and margin in near real time. You can add further dimensions, such as feature, agent, or workflow, to see not just which customer is expensive but why.
- Attribute by your user ID, account ID, or tenant.
- Break down a customer further by model, feature, agent, or workflow.
- Near real time, with no proxy in your request path and no prompt storage.
Frequently asked questions
How do you track OpenAI or Anthropic cost by user?
Send a user or account ID with each usage event. Bear Lumen calculates the cost of every model call from its token usage and rate, then groups that cost by the ID you sent, so you get spend and margin for each user across every provider.
Can you track cost per AI agent run?
Yes. Tag events with an agent or workflow identifier and Bear Lumen rolls up the cost of every model call in that run, so you can see the cost of a single agent execution as well as the customer it belonged to.
How do I find unprofitable customers?
Attribute model cost per customer and compare it to their revenue. Any account whose cost to serve is close to or above what they pay has thin or negative margin. Bear Lumen surfaces these accounts and ranks them by margin health.