Launching today

AgentCOGS
Per-customer AI margin tracking for LLM SaaS
1 follower
Per-customer AI margin tracking for LLM SaaS
1 follower
AgentCOGS is an open-source Python SDK that shows the AI margin of each of your customers, not just the blended total. Inside agentcogs.run(), it reads token usage from the OpenAI and Anthropic calls you already make and attributes that cost to the customer you set. AI margin = (monthly fee - attributed AI cost) / monthly fee. Type the fee or pull it from the customer's Stripe subscription. Self-hosted dashboard included; a hosted API is not serving. Fictional demo: agentcogs.vercel.app. MIT.





Free
Launch Team

AWS Startup AdvisorPersonalized AWS guidance that meets you where you’re already building
Promoted
Hi Product Hunt - Vaibhav here, maker of AgentCOGS.
AgentCOGS answers one question for SaaS built on LLMs: which customer stops making money this month? A blended AI bill can look fine while one customer's usage quietly outgrows their fee.
What it does:
Runs inside agentcogs.run() and reads token usage from the OpenAI and Anthropic calls you already make
- Attributes that cost to the customer you set
- Computes AI margin = (monthly fee - attributed AI cost) / monthly fee; type the fee or pull it from Stripe
- Checks a per-customer budget before the next SDK call, with straight-line pace to month-end
What's real today: the SDK (pip install agentcogs), a self-hosted dashboard, and a fictional sample at agentcogs.vercel.app you can explore without typing anything. The hosted API is not serving yet - everything runs on your machine. MIT licensed.
I'd love feedback on the margin definition (docs/cost-methodology.md in the repo) and on which providers you'd want instrumented next. GitHub: github.com/vaibhav11123/agentcogs