Jump to ratings and reviews
Rate this book

AI Engineering: Building Applications with Foundation Models

Rate this book
Recent breakthroughs in AI have not only increased demand for AI products, they've also lowered the barriers to entry for those who want to build AI products. The model-as-a-service approach has transformed AI from an esoteric discipline into a powerful development tool that anyone can use. Everyone, including those with minimal or no prior AI experience, can now leverage AI models to build applications. In this book, author Chip Huyen discusses AI the process of building applications with readily available foundation models.

The book starts with an overview of AI engineering, explaining how it differs from traditional ML engineering and discussing the new AI stack. The more AI is used, the more opportunities there are for catastrophic failures, and therefore, the more important evaluation becomes. This book discusses different approaches to evaluating open-ended models, including the rapidly growing AI-as-a-judge approach.

AI application developers will discover how to navigate the AI landscape, including models, datasets, evaluation benchmarks, and the seemingly infinite number of use cases and application patterns. You'll learn a framework for developing an AI application, starting with simple techniques and progressing toward more sophisticated methods, and discover how to efficiently deploy these applications.

Understand what AI engineering is and how it differs from traditional machine learning engineeringLearn the process for developing an AI application, the challenges at each step, and approaches to address themExplore various model adaptation techniques, including prompt engineering, RAG, fine-tuning, agents, and dataset engineering, and understand how and why they workExamine the bottlenecks for latency and cost when serving foundation models and learn how to overcome themChoose the right model, dataset, evaluation benchmarks, and metrics for your needsChip Huyen works to accelerate data analytics on GPUs at Voltron Data. Previously, she was with Snorkel AI and NVIDIA, founded an AI infrastructure startup, and taught Machine Learning Systems Design at Stanford. She's the author of the book Designing Machine Learning Systems, an Amazon bestseller in AI.

AI Engineering builds upon and is complementary to Designing Machine Learning Systems (O'Reilly).

532 pages, Paperback

Published January 7, 2025

1181 people are currently reading
2245 people want to read

About the author

Chip Huyen

7 books4,069 followers
Update: My debut novel, Entanglements That Never End, is scheduled for release later in 2025, with an early edition currently available on Kindle. I had a lot of fun writing this story, and I hope you’ll have fun reading it too!
***

I’m Chip Huyen, a writer and computer scientist. I grew up chasing grasshoppers in a small rice-farming village in Vietnam.

I'm interested in AI for storytelling and roleplaying. Previously, I built machine learning tools at NVIDIA and Netflix. I've also founded and sold a company.

I graduated from Stanford, where I taught ML Systems. The lectures became the foundation for the book Designing Machine Learning Systems, which is an Amazon #1 bestseller in AI and has been translated into 10+ languages (very proud)!

My new book AI Engineering (2025) is currently the most read book on the O’Reilly platform. It’s also available on Amazon and Kindle.

In my free time, I travel and write. After high school, I went to Brunei for a 3-day vacation which turned into a 3-year trip through Asia, Africa, and South America. During my trip, I worked as a Bollywood extra, a casino hostess, and a street performer.

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
276 (59%)
4 stars
148 (31%)
3 stars
34 (7%)
2 stars
3 (<1%)
1 star
2 (<1%)
Displaying 1 - 30 of 62 reviews
Profile Image for Sebastian Gebski.
1,188 reviews1,340 followers
April 8, 2025
Uff, I've finally managed to get this one through - and this was quite a journey.

Why did I reach for it? Based on recommendations of some knowledgeable people who called it a best book to upgrade your practical skills on building modern AI systems.

What did I expect? I call it a "Karpathy" level experience ;D Andrej is able to explain complex concepts in a way that still requires a lot of effort, but it reduces significantly the "steepness" of the learning curve.

Did I get it? Not really, but it doesn't mean it's a bad book:
- it doesn't assume much when it comes to your starting level (with Gen AI, LLMs), so you're taught concepts like finetuning, RAG or recall
- it indeed does not focus on a single aspect of using LLMs (e.g., prompting) - there are decent chapters on finetuning (even - very decent), quality assurance, inference optimisation, etc.
- sometimes very unevenly it jumps between pretty high and very deep level - I don't think the author is bragging, it's just that she was no sure who the book is for: the folks who just start with building simple things with AI, or the ones who know all the basics bits and pieces and now need to dive really deep
- it's clear that the author is very knowledgeable, I won't question that - but I missed a bit of "practical decision-making" when it comes to going beyond the basic arch (which is covered); that may be feel I'm not getting much beyond what is already freely available online in abundance

Good book, or even a very good one (4.3-4.5), but it didn't rock my world. Yes, there were some sub-chapters definitely beyond my level of knowledge (which I didn't follow straight to the very end), but still - I think I've expected (after the enthusiastic reviews) slightly "more". Maybe this more is more "focus" or more "practicability". And no, unfortunately it wasn't "Karpathy level" of explaining ;) But I'll definitely check out what that author releases next - this one was a good start.
Profile Image for Jacob.
223 reviews16 followers
May 22, 2025
Light, breezy read. Perfect for a beach trip or unwinding before bed.

Honestly there was more information packed into this book than almost anything I’ve read in recent years, and I could rarely get through more than 10 or 20 pages at a time. But it really was fantastic. She covers so many topics related to LLMs — architecture, evaluation, dataset curation, RAG, hallucinations, capturing preferences via explicit and implicit signals etc. — and goes into the perfect amount of depth. Her explanations are also crystal clear with great analogies. One fun thing I would do was ask ChatGPT or Claude about topics I wanted more detail on, which felt very meta lol.

It’s not easy to write a book about a field evolving so rapidly but Chip focuses on fundamentals more so than current news. I’m sure a new topic will come around soon and Chip will write a book on that too, and you better believe I’ll be reading it. Hopefully not too soon though because my brain is tired.

If you only read one book about how LLMs actually work, this is the one you want!
Profile Image for dantelk.
208 reviews20 followers
March 1, 2025
My profession is computer programming, and I wanted to read more on AI, both for my own pleasure, and since I didn't want to lag behind the competitors (other programmers).
Before starting this book, i tried two others, and DNF them.
- https://www.goodreads.com/book/show/2... this one made a too quick deep dive, and i felt that what I was reading didn't leave any foundation information in my memory.
- https://www.goodreads.com/book/show/1... I am not THAT nerd.

Although I am new to the field, and the book spreads into a wide range of topics, Chip's book was easy to follow, and was a good introduction for my level. I believe I should better re-read it after a year or so, when my overall AI knowledge is more advanced. If I was interviewed about the topics discusses in the book today, probably I wouldn't be able to utter more than a few words, but still, I felt that the book laid good foundation information, and gave me insight about what to focus on the following levels of my AI education.

There are at least two other goodreads friends of mine who read this book simultaneously, and I am very curious about their own impressions too! :) I guess people with more advanced AI knowledge my find the book a bit high level.
Profile Image for Thư.
9 reviews4 followers
January 18, 2025
great overview of AI engineering. will write a detailed review later but in general my favorite chapters are the ones about sampling and inference optimization.
Profile Image for Evan Oman.
31 reviews2 followers
April 23, 2025
A timely, mostly broad but sometimes deep, overview of AI engineering as of late 2024

The author mixes some of the latest ideas—many from just months before release—with timeless patterns that will stay relevant for years (like emphasizing evaluation and gathering user feedback). It highlights all the creative ways people are leveraging, evaluating, and training models—I walked away excited by the possibilities!

Some assorted takeaways:
• AI engineering is emerging as its own niche somewhere in between product, software engineering, and ML roles.
• The “R” in RAG can be any retrieval method—it’s just ranking documents. Semantic search over a vector DB is just one option; TD-IDF and BM25 work too.
• AI-as-judge performs well in many scenarios and is widely adopted.
• Use RAG to address knowledge gaps; fine-tune to fix behavioral gaps.
• Non-integer quantization rates (e.g. 1.58 bits) are just weighted average quantization rates across different parts of the model.
• Foundation-model teams use all sorts of clever tricks to boost training data:
• Perturb code samples and verify they still run.
• Generate instruction-solution pairs by generating a reasonable instruction for a known high-quality solution.
• nvidia-smi only shows that your GPU is active—it doesn’t show how hard it’s working:
• MFU (Model FLOPS Utilization): percent of peak FLOPS in use (∼50% is good for training; inference is lower).
• MBU (Model Bandwidth Utilization): percent of memory bandwidth in use.
• Even if users don't leave explicit feedback, there are lots of ways to infer implicit feedback
• e.g did they take a suggested action, did the sentiment of inputs trend up or down, did they regenerate the response, did they correct the model
• A single H100 GPU running for one year uses about 7,000 kWh—roughly 70% of a typical American household’s annual power.
Profile Image for Daniel De Los Santos.
32 reviews
May 26, 2025
Chip Huyen’s AI Engineering is a concise, hands-on guide that bridges the gap between AI research and production systems. It emphasizes building scalable, maintainable, and continuously improving AI applications. Key strengths include its focus on real-world MLOps practices, deployment strategies, data-centric AI, and reproducibility. The book is tool-agnostic but provides practical design patterns, making it ideal for engineers moving from model development to operationalization.
Profile Image for Chí.
8 reviews1 follower
January 19, 2025
This book serves as a handbook for those looking to build applications with available foundation models. Chip Huyen, with her extensive experience in the field, guides readers through the process of building AI systems—from model selection and evaluation to prompt engineering, as well as advanced techniques like Retrieval-Augmented Generation (RAG), Agents, and fine-tuning.

Rather than being a typical tutorial, this book is more like a collection of insights and experiences from Chip Huyen’s personal and professional journey in AI application development. It provides practical advice on handling various scenarios, focusing more on engineering rather than research. There’s no code or mathematical formulas, making it accessible even to general readers, though AI professionals will find it particularly enlightening.

Despite being in English, the book is easy to read, with no overly complex vocabulary. The writing style is clear, coherent, and easy to understand.

Highly recommended for those looking to grasp the practical aspects of building AI applications with foundation models.
204 reviews6 followers
January 5, 2025
Yet another comprehensively researched book by Chip and this time on the emerging field of AI engineering - i.e. building applications on top of foundation models. Many chapters in the book are hard to write because of the sheer amount of progress in just the last few years. Kudos to the author for organizing the content, including ton of references and explaining the origin stories of the key ideas. The references to Sherlock Holmes, Shannon make the reading more interesting. A must read (continuous read) if you are a practitioner in this field.
Profile Image for Iván Peralta.
5 reviews3 followers
January 15, 2025
A great overview of the AI Engineering state of the art by the end of 2024, "sadly" because of the evolution speed of AI, it might get partially obsolete in a few months. But I'm confident the structure will keep relevant.
1 review
September 2, 2025
Coming from an ML background I picked up this book thinking I would skim it quickly as I was only interested in learning more about fine-tuning, evaluation and inference optimization. I thought the book was mainly about calling inference APIs and building apps. Boy was I wrong! The book is wonderfully written by a seasoned professional in the ML world, and is full of substance! More than people that are only now touching the world of AI, I reccommend it to any ML practicioner.
Profile Image for Julien Delange.
22 reviews1 follower
May 24, 2025
This book is made for engineers who know how to code, build frontend or backend applications but are still figuring out how to build AI application or rather, applications that integrate AI. If you have 10+ years of experience and are starting to build AI applications: this is the perfect book to read.

The author does not try to be too general through the text, it's clear they have a strong experience in designing and building AI systems. From recommendations about how to approach building AI application to prompt engineering or overall system architecture, this book is an excellent start that should be enough for most application builders.
102 reviews6 followers
February 8, 2025
I really liked this book! It systematically gives you information about this hot new topic in a measured way at just the right level of abstraction.

And it is nice to read a book about _engineering_ side instead of yet another "How to change your life with ChatGPT" or "Prompts for Dummies"!

I would also recommend this book for those who oppose AI and want to fight it, as it outlines all the juicy parts and vectors for attack.
1 review
February 24, 2025
This is one of the best books you can read to make sense of AI engineering without the hype. Each chapter is written with great care and excellent flow; all chapters are referenced with papers to back up.
19 reviews
March 14, 2025
Excellent book. Highly recommend for anyone interested in understanding what current day AI is all about.
Profile Image for bimri.
Author 2 books9 followers
April 4, 2025
Chip must have gone through tremendous effort to compile this tome. (For that, this book deserves full merit on the rating score.) It had its lingering difficulties in explanations of research concepts underpinning current AI breakthroughs; but as the disclaimer to this book went, it was an expectation at the end of the day.

What this book is great at is the ultimate compression of so many moving parts in AI sea of content. My favorite bits is when Chip fervently talked about AI accelerators & especially on the hardware side of things, I bet Chip owns NVIDIA stocks & wrote this section as though Jensen himself would read it!!!

Kudos to the author for this aggregated knowledge and structure instilled in defining this AIE discipline. For those who are wondering, bruh - be ready for so much evaluations, monitoring & feedback of AI systems! Amor Fati!
Profile Image for Patrick (Kunle).
79 reviews21 followers
September 4, 2025
A tight (just ~500 pages) yet comprehensive dive into developing practical applications by adapting foundation models.

The book covers pretty much every major topic to a solid degree: how LLMs are pre-trained (transformer architecture and the attention mechanism), evaluating models and AI systems, prompt engineering, RAG, finetuning techniques, dataset engineering, and inference optimization. The final chapter was a real treat, sketching the architecture of an application that brings together all the concepts from the earlier sections.

I was looking for both a strong foundation and a reliable reference on AI engineering, and this book delivers on both counts. Highly recommended.



Profile Image for Bartłomiej Falkowski.
246 reviews27 followers
August 25, 2025
I think the book fits perfectly into the current trend regarding AI. It is not overly technical and difficult (although at times the content is really complicated) and provides a wide spectrum of knowledge.

On the other hand, paradoxically, it can be too technical for novices and too trivial for pros :)

Anyway, I got what I wanted to get. I understand Foundational Models more, I know what is transformer architecture, how models can be secured, compromised or refined. Of course, there were sections that didn't interest me, but I encountered them relatively rarely. Most of the time, even the strong Machine Learning knowledge was presented in a nice way.

Most interesting takeways? Understanding the architecture and the "pipeline of AI" (training, evaluation, finetuning etc) and understanding the constraints of models and prompting.

From my point of view, the biggest advantage of "AI Engineering" is lack of bullsh*t and lack of no unnecessary complications. It's not "build your first AI app in 10 minutes" type of a book. This is a professional and condensed source of knowledge. What is important, the author managed to combine all the fashionable AI things into one complete product without any exaggeration AND in a way that is understandable for programmers who don't deal with AI on a daily basis.

4+
Profile Image for Thang.
101 reviews13 followers
April 12, 2025
Good book and informative if you want to understand the current state of LLM development process. The book provides a broad view, but I feel a lack of depth and practical examples. Also, it focuses on trending techniques, so I wonder if it would become obsolete after short time.
2 reviews
May 23, 2025
Turns out I had already learnt most concepts in the book from YouTube videos. It was a decent refresher, hopefully will be a good reference book.
Profile Image for Christian Martin.
9 reviews
May 4, 2025
I just finished this book Honestly, it wasn't as scary as it sounds! Basically, it's about how to actually use all those fancy new AI things you hear about, like those big language models.
The book does a good job of explaining that building AI apps now is a bit different than how it used to be. Instead of training everything from scratch, we're using these huge, already trained "foundation models" think of them like really smart building blocks.
Huyen walks you through how to figure out if these AI models are actually any good for what you want to do, and what kind of tools and stuff you need to build real applications with them. It’s not super technical in a confusing way, but it gives you a good idea of what goes into making AI work in the real world.
If you're curious about how all this new AI buzz word and stuff is actually being built into apps and tools, this book gives you a pretty clear picture. It’s not a light read, but it’s definitely understandable and makes a lot of sense if you're trying to wrap your head around how AI is being engineered today.

Profile Image for Yaroslav Kuntsevych.
4 reviews
July 29, 2025
One of paper books about AI I would recommend.

AI Engineering: Building Applications with Foundation Models (paperback) offers a concise, practical guide for developers working with foundation models like transformers. It simplifies complex concepts and covers deployment strategies effectively, though it could use more detailed case studies. Code examples are useful but sometimes lack beginner-friendly explanations. The book balances technical depth with readability, making it a valuable resource for AI engineers, though it could benefit from updates on emerging tools.

I would not mind covering basics of Federated AI, Zero-Trust metadata, and Dataspace concepts.

When it comes to AI, and AI engineers I would also recommend to take a closer look at Upstaff, a platform that connects clients with trusted, pre-vetted AI, Web3, software, and data engineers. As a technology partner, Upstaff delivers end-to-end projects or boost teams with pinpoint expertise.
Profile Image for Sarah Kathryn.
364 reviews2 followers
July 20, 2025
This is the first book from an academic press that I've actually enjoyed reading. A coworker & I hosted a book club for our company using this book, & many agreed that it was extremely approachable while simultaneously highly useful.
(I did not use AI to generate this book review 😉)
19 reviews
July 5, 2025
Wow, this is a loooong one.
if 6 stars would have been available - this book would take them all.
I was able to learn about "AI" systems almost without any prior knowledge - complex terms are written in easy language.
But the book is not only about theory - practical examples in it can be quite useful to the people who don't want to move into AI engineering, but just want to be able to use AI applications more efficiently.
Profile Image for Suhel.
187 reviews
March 15, 2025
banger book, lots of alpha, some really useful practical that I haven't heard anywhere else.
Profile Image for Nathan Summers.
27 reviews
April 24, 2025
Chip Huyen's AI Engineering: Building Applications with Foundation Models is an essential text for anyone developing AI applications in today's rapidly evolving landscape. This book is particularly valuable because it emphasizes evaluation pipelines as the cornerstone of reliable AI systems.
Unlike traditional machine learning approaches that focus on model development first, Huyen advocates for a product-first orientation. Development begins with user needs and iteratively refines applications using pre-trained models. This shift democratizes AI development but introduces new complexities in evaluating open-ended outputs.

The book introduces the concept of Evaluation-Driven Development (EDD), where evaluation criteria dictate system design from inception. This approach addresses domain-specific capability, output quality, alignment with human values, and system robustness. Huyen provides practical frameworks for implementing AI judges while acknowledging their limitations, including non-determinism, hidden biases, and cost considerations.

The five-stage evaluation workflow is particularly useful because it helps engineers navigate the tradeoffs between latency, cost, and quality. The case studies on Retrieval-Augmented Generation optimization and multimodal model evaluation offer concrete examples of these principles in action.
While some sections may become outdated quickly given the pace of AI advancement, the book's enduring contribution lies in reframing AI engineering as a discipline where evaluation is inseparable from innovation. As Huyen eloquently states:

"Self-supervised pre-training gives us a monster; evaluation pipelines domesticate it into something we can use."

This book offers a practical roadmap for practitioners looking to build reliable AI systems—whether chatbots or genomic AI—that balance technical rigor with product-centric thinking.
Profile Image for Simon Gianoutsos.
427 reviews4 followers
June 27, 2025
As noted at the beginning this book "focuses on the fundamentals of AI engineering instead of any specific tool or API. Tools become outdated quickly, but fundamentals should last longer."

AI engineering refers to the process of building applications on top of foundation models.

After explaining key concepts related to AI and foundation models, potential use cases and Product Management (albeit isn't explicit called out as this) is then covered, including the setting of measurable goals and a plan to achieve them.

The book then delved into a level of detail I wasn't interested in (which I then skimmed over) but I appreciated that there had been a huge amount of research to pull out together; it just wasn't sufficiently practical for me.

Near the end though I found the AI Engineering Architecture and User Feedback section a good read. On the architecture side this covered topics such as enhancing context by giving access to external sources, input and output guardrails, using different models for different use cases, using a gateway to integrate and control access to different models, reducing latency with caches and adding agent patterns. Obtaining user feedback from explicit and implicit means to help improve the solution was also useful.

Not surprisingly given how fast this space is evolving, new topics such as MCP and A2A weren't covered.

2.5/5
2 reviews
September 2, 2025
Just finished reading this book as part of my summer learning activities. Overall I thought it was a really good overview of the emerging field of AI Engineering as applied to foundation models. As opposed to ML Engineering, which focuses on designing and building the ML models themselves, AI Engineering encompasses the broader work to build systems and products where ML models are but one of the components. The book began with an overview of foundation models, then went on to cover the steps involved in building systems using foundation models. Chapters covered model evaluation, prompt engineering, using RAG and agents, finetuning, data engineering, optimizing inference, AI system architecture and user feedback. Each section provided a good overview of the concepts while being generally technology agnostic and not too detailed. There were lots of links and references to specific tech and details for those interested.

I would recommend this book to anyone working with generative/foundation models who wants to understand the broader engineering work to deploy those models into production products.
Profile Image for Alexandru Todea.
16 reviews1 follower
April 22, 2025
Very informative material. Here are my pros and cons:

Cons:
- Lack of code examples; had the author present an A-Z example of an AI system that showcases all the theory, the book would have been a 5 stars piece of material;
- Lack of exercises in order to do self-assessment of material ingestion; Wish there where some exercises or mini projects through which one can assess their understanding of book material

Pros:
- Really informative and in-depth material on how to build ai systems and what to take into consideration when doing so;
- Explains prerequisite material such as what is a transformer;
- Easy to understand material (or it creates that impression)


Overall i think that this is a really good book especially for engineers who want to build an application around foundational models, but also for those who are curious about the current state (and paradigm shift) of smart software.
I'd recommend people to build an application alongside this book and use the material in question as a check-mark list in order learn best practices for building ai systems.
Profile Image for Ferhat Elmas.
850 reviews13 followers
May 29, 2025
Pragmatic, beginner friendly, tool agnostic intro into engineering side of AI; putting model into products and bringing it into the real world. It's broad, might even feel overwhelming but mostly shallow in the details and practical examples, that's understandable considering its length and rapid innovations in the field (already slightly outdated and also missing the new hotness such as A2A or MCP). It stays high-level and skims through nearly all interesting parts of the problem space. Its emphasis on the first principles; keeping model evaluation and user feedback in mind, and adding new components only if necessary installs a good mindset for starters. A seasoned engineer should skip the whole thing at this point.
Displaying 1 - 30 of 62 reviews

Can't find what you're looking for?

Get help and learn more about the design.