200+ models on 4+ GPU clusters: How Together AI solved ultra-complex billing with Lago

How Lago powers billing for the next-gen AI cloud.
SaaS
Stories
Mistral

“To support our growth, we decided to move beyond our home-grown billing system while keeping the control and flexibility we valued. Lago’s open-source approach, which we discovered on HackerNews, immediately resonated with us.”

Vipul Ved Prakash
CEO, Together AI

Introduction

Together AI believes the future of AI is open-source—a belief we share at Lago.

They’ve built a comprehensive cloud platform empowering developers worldwide to create with open and custom AI models, letting companies pursue generative AI strategies without being locked into a single vendor.

Startups and enterprises alike are looking to build a generative AI strategy for their business that is free from lock-in to a single vendor,” says co-founder and CEO Vipul Ved Prakash.

Together AI originally developed a home-grown billing system but soon found it was consuming resources they couldn’t spare.

With four products launching and an ambitious research agenda, Charles, their founding VP of Engineering, was ready for a scalable solution that would let his team focus on pushing AI forward—not maintaining billing software.

Anyone who believes that AI will transform how we all live and work, then anyone should be able to access the models that enable us to do this.

But while Mistral builds for science, they’re still a company that needs to bill its customers—which is why they started working with us.

Challenges

As Together AI scaled, they faced billing challenges that are familiar to technical leaders:

Accurate billing – Ensuring correct invoices for a fast-growing, usage-based product is no small feat. Any engineer who’s worked on billing systems knows that getting it right at scale requires constant attention.

Detailed usage breakdowns – Together AI’s customers needed detailed reports on their usage, broken down by dimensions like GPU type and model. Transparency was non-negotiable.

Cost structure-friendly – Together AI's cost structure includes computing capabilities with fluctuating pricing based on GPU type and model. Real-time adjustment is key to controlling margins.

Flexible configuration – Together AI needed to adjust pricing without pulling developers off core projects.

Credit system – Together AI wanted to grant and manage credits seamlessly, allowing customers to purchase credits or receive promotional ones.

Integration and revenue operations – CRM and payment processor integration were a must, as was support for smooth cash collection.

Data control – They required total control over billing data, with full transparency and access to every granular detail—one of the main reasons they initially built in-house.

Solutions and impact

Lago provided Together AI with the best of both worlds: the control and flexibility of a home-grown system, and the scalability and stability of a trusted platform.

Together AI opted to deploy Lago on-premise, retaining full control over their data while leveraging Lago’s open-source flexibility and transparency, with complete access to their billing workflows.

Iterating and scaling with Lago

Lago empowered Together AI ’s team to iterate on their pricing and billing system quickly, scaling seamlessly without the need to staff a fully-fledged engineering team dedicated solely to billing. Thanks to Lago’s open-source flexibility, Together AI avoided the “billing nightmares” that many scaling startups face, as highlighted in our HackerNews billing article.

Achieving 70% efficiency in cash collection & fraud reduction

By implementing Lago’s progressive billing and custom dunning workflows, Together AI saved 70% of the time typically spent on cash collection. Additionally, they reduced instances of billing-related fraud—a critical benefit as they scaled rapidly. With Lago’s progressive billing feature, Together AI was able to issue invoices proactively, preventing sticker shock for customers and ensuring steady cash flow.

Full data ownership & infrastructure control

With Lago’s on-premise deployment, Together AI retained complete ownership of their data and billing infrastructure, accessing it at the highest level of granularity. This setup was key for Together AI’s data-driven approach, giving them transparency and flexibility without sacrificing control.

The best of both worlds: customization, control, and out-of-the-box features

Lago offered Together AI a unique blend of “build versus buy” benefits:

Dynamic pricing: Lago’s flexible charging model includes a custom price per event to account for computing costs and maintain margin levels.

Control and data privacy: As the Together AI team deployed Lago on-premise, they maintained full control over their data, accessing it directly with the highest level of granularity.

Customizability: Lago’s open-source nature enabled Together AI’s engineers to build custom workflows, adding or modifying features to fit their evolving needs.

Out-of-the-box features: Lago’s usage ingestion system, credit system (with options for real-time balance updates, automatic top-ups, and grace periods), and progressive billing workflows have been thoughtfully designed and maintained by Lago’s engineering team. Every edge case we’ve anticipated is one less loophole Together AI’s engineers have to worry about.

Partnership-driven growth

More than just a vendor, Lago has been a partner, evolving Together AI’s revenue operations to support their growth.

By prioritizing developments such as “progressive billing” (to prevent surprise invoices) and flexible dunning, Lago customized its platform to Together AI’s needs. These improvements helped Together AI avoid the “$65M bill effect” and gave them a robust framework to manage billing even as they scale and adjust their pricing.

With Lago, Together AI’s engineering team was freed from the heavy lift of maintaining and scaling a billing system. They could instead focus on Together AI’s core mission—driving the future of open-source AI.

Takeaways for AI companies

Lago’s open-source billing platform enabled Together AI to focus on scaling AI innovation rather than spending resources on billing maintenance. Here’s what technical leaders should know:

Flexible billing models: Easily configure usage-based, tiered, or flat-rate billing with YAML-based configurations.

Real-time usage tracking: Log customer activity through a simple API to ensure accurate, transparent billing.

Progressive billing: Lago’s progressive billing feature issues invoices before balances become overwhelming, helping prevent sticker shock for customers and improving cash flow predictability. With progressive billing, Together AI could set a custom threshold to automatically trigger invoices, giving customers predictable costs while reducing Together AI’s risk of unpaid high balances.

Customizable dunning workflows: Leveraging Lago’s manual dunning options, Together AI implemented custom billing reminders to encourage timely payments. This flexibility in dunning ensured a steady revenue flow and helped maintain a positive customer experience.

On-premise deployment: Retain full control of customer data with an easy-to-deploy on-premise setup.

Open-source customization: Build and modify features on top of Lago to meet unique business needs.

Focus on building, not billing

Whether you choose premium or host the open-source version, you'll never worry about billing again.

Lago Premium

The optimal solution for teams with control and flexibility.

lago-cloud-version

Lago Open Source

The optimal solution for small projects.

lago-open-source-version