Black Friday Deals For Authors Are On Now!

Leanpub Header

Skip to main content

One Door to AI

A beginner’s guide to running an LLM gateway with LiteLLM on Google Cloud

One Door to AI

Every team in your company wants AI, and every team is buying it on its own. This book shows you, in plain words, how to give them all one safe, governed door to every model: one address, a key per team, budgets, guardrails and a bill you can explain.

Minimum price

$9.99

$15.99

You pay

Author earns

$

Also available for 1 book credit with a Reader Membership

PDF
About

About

About the Book

Every team wants AI. Left alone, each one picks its own model, its own vendor and its own key, and nobody can say what is being sent where, or what it costs.

One Door to AI shows you how to fix that with one LLM gateway: a single address in front of every model, built on the open-source LiteLLM proxy and run on Google Cloud. You start from zero (what a language model is, in plain words) and finish with a gateway a regulator could inspect.

You will learn:

  • how LiteLLM works, as a library and as a proxy
  • keys, teams and models, and who may call what
  • budgets, limits and a bill you can explain team by team
  • checking every question and answer with a guardrail, including streamed answers
  • what to do when a model or the database is down
  • rules as files: models, teams and residency, reviewed like code
  • real use: answers from your own documents, reading invoices, developers' AI tools, and agents with their own identity and limits
  • running it day to day, changing it safely, and what it really costs

Every step was built and tested live; the appendix says how. The open-source code is on GitHub.

Author

About the Author

Rakesh Gupta

Rakesh Gupta is the founder of Fluxor Software, the company behind Pipewright, the open-source MLOps platform for Google Cloud, and OneDoorAI, the governed gateway for every AI model. He has spent more than two decades building software for airlines, banks, automotive companies and governments. More at getpipewright.dev.

Contents

Table of Contents

  • Part 1. Why a door?
    • 1. What a language model is, in plain words
    • 2. The day every team bought its own AI
    • 3. One door
  • Part 2. Meet LiteLLM
    • 4. The library: many models, one way to ask
    • 5. The proxy: one address for everyone
    • 6. A walk through the office
  • Part 3. The rules at the door
    • 7. Keys, teams and models
    • 8. Money: budgets, limits and who pays
    • 9. Is it safe? Checking questions and answers
    • 10. The hole in the fence
    • 11. When something is down
  • Part 4. Building it
    • 12. The building blocks
    • 13. Same address, different projects
    • 14. Rules as files
    • 15. Your app's first call
  • Part 5. The door at work
    • 16. Answers from your own documents
    • 17. Reading invoices
    • 18. When developers use AI
    • 19. Every team has one
  • Part 6. Running it
    • 20. Watching it
    • 21. Changing it safely
  • Part 7. The door grows up
    • 22. A home for the rules
    • 23. When the database is down
    • 24. The developers' own door
    • 25. Agents: when a program decides
    • 26. Tools, and the lock that stays with the tool
    • 27. The rules a regulator will ask about
  • Part 8. The bill, and your first month
    • 28. What it costs, what it is not, and what next
  • Appendices: A. Words you met, B. How this was tested, C. Sources

The Leanpub 60 Day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

See full terms...

Earn $8 on a $10 Purchase, and $16 on a $20 Purchase

We pay 80% royalties on purchases of $7.99 or more, and 80% royalties minus a 50 cent flat fee on purchases between $0.99 and $7.98. You earn $8 on a $10 sale, and $16 on a $20 sale. So, if we sell 5000 non-refunded copies of your book for $20, you'll earn $80,000.

(Yes, some authors have already earned much more than that on Leanpub.)

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub