Skip to content
Ep. 136Tuesday, October 27, 2026

AI Engineering: Building Applications with Foundation Models

Part 1

Book Covered

AI Engineering: Building Applications with Foundation Models

AI Engineering: Building Applications with Foundation Models

by Chip Huyen

Get the book →

Book links are affiliate links. We earn from qualifying purchases.

Author

Chip Huyen

Hosts

Nathan ToupsHost
Carter MorganHost

Transcript

This transcript was auto-generated by our recording software and may contain errors.

Carter (00:00)

They drive me absolutely insane with their talk about like,

distillation attacks and like how egregious it is that someone would try to distill Claude. I'm like, Claude is a distillation of the internet. Like shut up.

Hey there, welcome to Book Overflow, the podcast for software engineers by software engineers, where every week we read one of the best technical books in the world and effort to improve our craft. I am Carter Morgan and I'm joined here as always by my co host, Nathan Toups. Are you doing Nathan?

Nathan Toups (00:58)

Doing great. Hey everybody.

Carter (01:00)

Well, make sure to like, comment, subscribe, uh, share it with your friends and coworkers. I feel like my voice is a little maybe a little raspier than usual. I think I'm a little sick. I also uh you'll hear about this first, although I did mention it. But big college football guy, and I'm a big BYU football fan. And we did just knock off the number two Notre Dame, and now we are number two in the country. And so I was shouting a lot of that game. I was in person and I lost my voice. And so um

We have a we have an interview that'll come out here soon. And I'm also like decked out in BYU gear because we recorded that like right after the game. But anyhow, if you're listening and you're like, my man, Cardi sounds a raspy, it's it's probably a combination of those two factors, but totally

Nathan Toups (01:41)

Amazing.

Carter (01:42)

worth it.

Nathan Toups (01:43)

Congratulations on being number two.

Carter (01:45)

Thank you. I did a lot of hard work to get there. So Yeah, yeah.

Nathan Toups (01:49)

You di it sounds like it. Lost your voice and you know.

Carter (01:51)

I always say that because like on third down, they like want you really loud. And then like if they if the other team like gets it on third down, I'll always like, I was so loud. Like I did my part. How come the football team didn't do their part to stop the

Nathan Toups (02:03)

Mm-hmm.

Carter (02:04)

third down? So um anyhow, if any BYU fans out there, live it up. These are the good days. And if you're a Notre Dame fan, well, better luck next time. We'll play you next year.

Uh, but we got we got a good book this week. We got a good book. this is AI Engineering, Building Applications with Foundation Models by Chip Huyen. Uh just wanna flag up front because you actually flagged me just before we started, Chip is a woman. Um, and you you could be forgiven for for not thinking that. Um, but Nathan, you discovered this book right through Pragmatic Engineering. Gergely Orosz conducted an interview here.

Nathan Toups (02:41)

Yeah, so actually I had it on. I was I was actually re- retracking the history. I think it f was on my feed or something a while back, but then it really caught my attention when Pragmatic Engineer had Chip on. And their their conversation's phenomenal. I'd highly recommend checking out. Maybe we can throw that in the show notes. and yeah, this book's pretty new. I think it came out at the beginning of twenty twenty five.

And uh yeah, it's it's it's been on our list. It was like on our backlog, it's kind of been on our reader for probably almost almost a year, and I'm glad we're finally getting around to it.

Carter (03:15)

Yeah, well, I'm a I'm glad we got around to it too. Um, let's give you the author introduction, the book introduction, so we all know what exactly we're talking about. Uh Chip Huyen is a writer and computer scientist who grew up chasing grasshoppers in a small rice farming village in Vietnam. My best friend growing up was from Vietnam. her work sits

Nathan Toups (03:32)

That's cool.

Carter (03:33)

at the intersection of AI, data, and storytelling. She built machine learning tools at NVIDIA, Snorkel AI, and Netflix, founded an AI infrastructure startup that was later acquired, and taught machine learning systems design at Stanford.

Her

previous book, Designing Machine Learning Systems, became an Amazon bestseller in AI and has been translated into more than 10 languages. Outside of tech, she writes fiction and has published four storybooks in Vietnamese. For the book Introduction, we got 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 engineering and the process of building applications with readily available foundation models. So this book, I think we're we're doing a three-parter, aren't we, on this?

Nathan Toups (04:31)

Yeah, this one's there's a lot. There's a lot to it.

Carter (04:33)

It's

it's dense. Uh we read chapters one through three. Uh I'm listening to the audiobook. but I think I gotta pick up the the Kindle copy because you you said you're doing that, right, Nathan?

Nathan Toups (04:45)

Yeah, so I'm I am listening to the audiobook, but I've had to supplement with the Kindle because it's it's just one of those where this is enough out of my depth and there's enough technical density to it that um yeah, the audiobook's a little strange in the sense that like it will it's going to read to you a table of, you know, information or explain some sort of like diagram that it has that it does a pretty good job at it, but unless you see the picture, and there is a there is a PDF associated with the book.

the audiobook, you know, if you if you have that supplemental stuff. Chip also she has uh GitHub repositories with a lot of the code examples and things like this. So it's a pretty interactive learning if you want to spend the time and energy in it. And depending on who the audience is, we'll get into that later. Uh it's a pretty it's a pretty important book for certain career paths.

Carter (05:37)

Chapter two in particular is a bunch of math equations that I'm listening to as an audiobook. And I just want to promise you, the listeners, I understood every equation. I've got them all memorized by heart. And so if you

Nathan Toups (05:49)

Yeah.

Carter (05:50)

if you need to know them, just just let me know. Um it's like Yeah. Yeah.

Nathan Toups (05:53)

You're literally Zach Alifhenakis with all those, you know, formulas c passing through your head.

Carter (05:59)

Well, so we did chapters one through three. Nathan, why don't you give me your thoughts on uh chapters one through three?

Nathan Toups (06:05)

Yeah, so um I put in my notes like this book does not hold back. And and I will say I was actually influenced by the later chapters that we read, two and three, when I was saying this. it starts the book is like sort of almost like in college, right? You'd have these courses that are deep into some specific topic, and some of them are like survey courses, right? Where kind of gives you like a lot of information about a few little things. Chapter one sort of starts out that way, and I

I I think Carter and I kind of talked about this before the episode recording started. I wasn't sure where I was gonna go on the journey with this because I was like, is this the is this the breadth of the entire book that's just gonna be like really broad? But then I realized like we already get the payoff in chapters two and three. We're already like diving in deep, right? Bunch of math equations in chapter two. A topic that's really interesting to me, like um LLM as a judge and evals. I I

I'm actually really enjoying this book, even though it's more domain-specific and focused than books that we've been reading recently. You know, mostly we've been reading these sort of like broader, you know, philosophy type books. Um, it's kind of refreshing because we haven't read something very specific like this in a while. And it's a different type of reading, I guess. that's kind of I had to switch my brain into like, oh, like I know I don't know anything about this mode, and I'm gonna have to like

Carter (07:27)

Right, right.

Nathan Toups (07:28)

go back and, you know, do more research after after I read. So anyway, that was kind of like my uh my initial thoughts and I'm I'm I don't yeah, so far so good.

Carter (07:38)

Yeah, it's like we talk about, we we call it the end-to-end test, right? Where we just we have to read these books cover to cover. It's just the structure of the podcast. And so you do find a book every now and again that suffers from that. I found that a bit with chapter one, which is called Introduction to Building AI Applications with Foundation Models. And it it's structured a little like if you maybe woke up from a seven-year coma and you're just like, my gosh, like what's going on with AI? And so I I was a little like.

might be in for a rough ride. Um, if like the if the books kind of thinks its job is to just cover anything and everything AI under the sun. We've talked about this before where I I think we appreciate books that are a little more bold with who their target audience is and a little more restrained with what exactly they're trying to cover. I actually think what is Chat GPT doing and why does it work by Stephen Wolfram? friend of the podcast by the way, we've had him on, um, is a great example of kind of saying like, I know exactly who I'm talking to and I'm just gonna

limit the breadth of what I talk about. So I was a little nervous in chapter one, but chapters two and three are uh I think much more like meaty and uh and and like again like this is not like a knock on the book. Like she says like in every chapter like, hey if you feel like you've got this, like skip ahead. Um, which is great. We don't skip ahead, right? We we listen or read the

Nathan Toups (09:01)

Yeah.

Carter (09:02)

whole thing. Um so you know just just know that if you get into this book. Um

But we can go ahead and start talking right about chapter one, the introduction to building AI applications with foundation models. Um, like I said, this starts out kind of very like, okay, what are LLMs? Um, kind of like why you might decide to build an AI application. And I guess maybe the best thing to talk about here is like the distinction between like, are you building a traditional application using LLM assisted coding, or are you building like an

actual AI application. Um have you had experien any experience with the latter, Nathan, where you're trying to like where AI is like the product or at least a very core

Nathan Toups (09:48)

Yes,

Carter (09:49)

component.

Nathan Toups (09:49)

you know, I actually interviewed uh I've interviewed a couple of companies. I've I've never worked on an LLM product myself. I have worked on a product that was um based off of ML and some language models that was sort of the previous generation of how we did ML ops. And actually this book does a really good job of capturing the fact that this is a a world in transition.

That we're actually trying to figure out how to deal with these new transformer-based LLMs, and that there's a real distinction between the consumer of these, right? Like software engineers are a big consumer and there's a lot of excitement and a lot of fear. And again, she covers this quite well. But like if you're trying to build a product around these things, you know, she brings this up even in the first chapter. Like, what is your moat, right? Is this really something that

Is very unique. Like you have the unique data set that the foundation models don't have. Do you have these other things? You start thinking through this stuff. Uh, or is it like one design and implementation spike away from a foundation model taking your entire startup away from you? These are real questions that you should be asking. I will also say, like, I I wanna bring this up is this book came out in the very beginning of 2025, and it feel but it feels like most of the book was finished.

In its writing around the end of 2023. I don't really see any LLM references that are like beyond that, at least not at this point in the book. And the world's already shifted so much, right? There's a lot of handwritten, like there is mention of anthropic, there is mention, um, but Claude Code wasn't out yet. There's not a single mention of Claude Code, right?

Carter (11:28)

Right, right.

Nathan Toups (11:29)

Or of this more like advanced sort of harness engineering type patterns or loop engineering or some of these more. We do talk about humans in the loop. we do talk about

Frameworks around how to build things with LLMs, which again, all of that stuff was going on. I think also in the first chapter, and I want to kind of bring this up because hear your thoughts on this as well. I think one of the reasons that this had to be so broad is that there's an entire category of folks building stuff with LLMs that were not in the ivory tower of it.

Carter (12:06)

Right, right. Who doesn't?

Nathan Toups (12:06)

Monte Carlo simulations and a bunch of statistics.

Right, right. Or in you know, probably even a PhD in um in in machine learning to to do anything useful. And then um a bunch of Python libraries came out, which opened this up a bit. You didn't have to know nearly as much. You started to do with the beginning of what we're calling prompt engineering, which I remember at the time was a lot of butt of the butt of a lot of jokes, right? That

Carter (12:31)

Right, right.

Nathan Toups (12:32)

e you would even be a prompt engineer. It was like almost like comical.

But yeah, this book treats it quite seriously. Like, hey, there's here's all the things that you need to do. Um, and then the other one was the introduction of JavaScript. And so we see the beginnings of this. This is completely normal now, right? If you're using um, you know, ling uh I always get it backwards. Is it Lang Chang or Chain

Ling? Thank

Carter (12:52)

Lang chain. Yeah.

Nathan Toups (12:53)

you. Um, yeah. So it Langchain was all Yeah, Chain Ling. Um, yeah.

Carter (12:56)

I I like Chainling better. Chainling. Anyhow.

Nathan Toups (13:01)

Langchain uh used to be only Python, right? And now it's probably the most popular implementation of it is the JavaScript library for it at this point. And so the fact that a full stack engineer is now being kind of thrown into doing AI uh engineering and development stuff means that I I think that this is why chapter one is the way it is. There's some concepts that a core audience of JavaScript developer maybe didn't understand, like doesn't have an this

knowledge of like the heritage or the constraints or the designs that kind of came into it. So it's it is a challenging um piece there. And yeah, so I I that's sort of like I I f I I'm trying to take and we do this increasingly with our books that we're reading. It's like I rewind my brain to

Carter (13:50)

Brian.

Nathan Toups (13:51)

what did 2023 feel like? What did 2021 feel like? What did 2019 feel like, right? These are because these are different

sort of paradigms of what it meant and our expectations were. 2023, we're still at the like bright-eyed and bushy-tailed beginnings of something that we understand is there's a there there, right? There's something different.

Carter (14:09)

Right, right.

Nathan Toups (14:10)

Um and so yeah, that's that's sort of like if I do give grace to why extra explanations are there, I think some of these things have become obvious and sort of part of the zeitgeist. But in even in 2023, where parts of this book were written obviously

I don't think it was so obvious. I don't think that a lot of people, you know, had wrapped their head around many of these concepts yet.

Carter (14:33)

I I don't think it was obvious at all. And I've said that on the podcast before, as somewhat like I I heard it said once that basically like all VC funds, like their whole job is just like trying out basically every business idea known to man and then like cycling through them. And so if you want to start a business, like

Usually the best opportunity is when a new technology comes out. Because if you have like the idea, like, like I think Tinder for cats is like the best idea ever, like odds are they someone has already pitched that, maybe even gotten funding for that. And uh and it hasn't worked. Um now sometimes there are legitimate gaps in like VC judgment, Airbnb is the classic example here, where like everyone just thought like you guys are insane. Why would anyone want to sleep in someone else's house?

That business probably could have existed 10 years before it did, but it kind of took two guys crazy enough to think that it could work. And then smartphones certainly helped accelerate it. But anyhow, uh so I I'm always very interested when new technology comes on the scene. Like, hey, well, you know, maybe this there could be an exciting business here. Um, and I've said before, but like I was kind of really burned from blockchain and crypto in the sense that, like, not that there's not utility for it, but that everyone thought like,

There's gonna be everything under the sun. Same with like the metaverse. We had kind of had like two big boom and then varying level bust attempts to have like a web three or whatever. Um, and so I was very skeptical of AI when it came out. And I wish I'd kind of recognized the potential. I think I might have made some different moves in my career and tried to work with it more when it came out. Um, but it's yeah, like

I don't know. Uh it's I like I said, I I I wish I had recognized that it could like that that it could write its own code. And and if it can write its own code, then it can invoke systems. And if I think if I had recognized like, okay, this is something that can invoke systems, then I would have recognized the potential. Um, I mean, hats off to Chip, who obviously recognized that from the very beginning. I mean, do we know like yeah, I'm trying to remember her background exactly of like

How how was she so on the ground floor of this? Is she just like kind of one of those people like Dario, who like it is just what they did?

Nathan Toups (16:58)

You know, I'm I'm I don't know the details. I d I know that she's been in the space for a while with the transition from like the more traditional ML ops and building um AI tooling into like I and it's funny, I actually've worked with a few companies. I worked with an agency that does it's funny they up to this point they've actually they're they're an ML agency. They're like a a AI agency that, you know, works with uh companies who need to, you know.

build custom tools that are sort of outside of their core experience. And again, they have this like core set of PhD researchers and PhD you know experts in the field. A lot of it was building out machine learning pipelines. A lot of it was making sure that the data integrity, testing, and quality are all there. Um I that's where her background is as well. And then transitioning into this sort of LLM ops, which is sort of the change to this, which is hey, we're not

doing all the hands-on stuff. Like we're actually taking these foundation models and you know we can't develop these models, right? They're way too big, they're way too expensive, but we can take the inference engines that come out of them and you know build a bunch of you know system prompts or the all these other pieces that are in place. And I I I think that that this was again this is like a pretty big shift and I I I ran into this with one of the agencies I I was working with back in 2022, 2023.

And they were at this spot where, like, do we even want to get into this? Right. Like they were like, we we still think there's

Carter (18:32)

Right, right.

Nathan Toups (18:32)

so much we can do with um, you know, image recognition, neural nets and all these other like sort of, you know, more traditional AI tools that there's still like a really important work to be done. And then the GPT and LLM stuff sort of exploded and they they shifted their, you know, opinions about this. They still do augmented stuff where they'll use more traditional.

more efficient AI tools in conjunction with these LLMs. And so um yeah, I if I'm and I'm guessing here because I don't know her full backstory, it feels

Carter (19:08)

Right, right.

Nathan Toups (19:09)

like someone who's incredibly knowledgeable about the field also just sort of being there and embracing, hey, there, you know, these foundation models are shifting everything and you we can't ignore them. And um actually th there was one thing that I thought that was very interesting about from her from her insights.

She does a lot of survey work. And so that's what this first chapter kind of goes in, and she'll talk about doing analysis across a bunch of repositories in GitHub, which again is hilarious because I can't imagine if she ran them again now. Um, a lot of the like, you know, what shows up and what doesn't, what's common and what is not common in like 2023 time versus now would be a fundamentally different. Um and this is before the time of, you know, now you can have AI GitHub repos.

They go to a hundred thousand stars within a few days, right? It's just unheard

Carter (19:58)

Right.

Nathan Toups (19:59)

of. Uh just a few years ago. One of the things she talks about though is this what is it? The OpenAI's GPTs or GPTs, and it was talking about task exposure, meaning like what tasks you have in your job. This is kind of gets back to what Carl Brown talked about, like that AI, these tools replace tasks, they don't replace jobs. But she

Carter (20:20)

Right.

Nathan Toups (20:21)

sort of frames this in, hey, but if a lot of your tasks

are your job and all those things get replaced.

Carter (20:27)

Right, right.

Nathan Toups (20:28)

There's like an exposure issue. And so things like people who do uh language translations, tax preparers, web designers, right? These are what were categorized as high risk of um task replacement. Where is it cooks, stonemasons, athletes, like there's a lot of like these like physical labor type jobs are like very low on the exposure standpoint. Um, which I thought again, it it seemed obvious when I

read that but I was it was also just kind of funny to frame it the way that it was framed.

Carter (21:00)

I have uh what you so on my team, we've got like 10 engineers and I really like them all. But like three of them are junior engineers. And then a couple other ones like have kind of only worked at kind of like startups. Like the most, the biggest they've ever worked is a place with like a hundred engineers. And so I was talking about just like a future where like things are more successful and we raise more money, like how strange it might be for us to have like a hundred engineers, like

Just the idea that like we might see each other in like a monthly meeting or something. Like we're we're joined at the hip now, but like maybe it'd be like, how have you been? I'm like, it seems so crazy to ask, like, how have you been? Like I I see this guy every single day. And and

Nathan Toups (21:39)

Right.

Carter (21:40)

I and I I I have a uh colleague, I I I really, really like him, but he's a bit of a pessimist and and has a bit of like a scarcity mindset. And he's just like, this company will never be bigger than like sixteen engineers. And I I I I'm like, No, no, no, like I I think we'll grow and like

You know, our boss has like big ambitions about like what a successful version of this looks like, like on par with like a LinkedIn. And and so I'm like, well, I think if we accomplish that vision, he's like, No, no, even if we were like as big as LinkedIn, we'd only have 16 engineers. And I'm just a little like, you just don't under like like I don't want to pull rank or anything, but like you've never worked somewhere very big. Like I'm telling you, like

Nathan Toups (22:20)

Right.

Carter (22:20)

LinkedIn has like a thousand engineers. And I think even in an aggressive like AI has eaten the world.

way that I I would think of that as like I can do the job of LinkedIn with like thirty percent as many engineers as LinkedIn currently has, which I think would be incredi incredibly aggressive.

Nathan Toups (22:37)

and l LinkedIn has

like sixteen to eighteen thousand uh ICs, actually. Right.

Carter (22:42)

Yeah, exactly. Right. And so, like,

I I bet it's probably more like 4,000 of those are engineers, right? I'm like, I'm telling you, like, it was it was just driving me a little nuts. I'm like, having come from like like big tech like thing, like you you underestimate the complexity as you scale and the amount of people you need to just like run you know the individual pieces of a business. But I just started thinking about that because you're talking like a replacing.

Tasks. And I I think this colleague I was talking to, he's mourning the loss of some of those tasks. But you know what I was thinking about actually uh in terms of like some of the tasks that it's replaced? I think every task that LM has replaced in our job, Will Larson would have defined as snack.

Nathan Toups (23:31)

Right.

Carter (23:32)

Right. Like j this I this idea that um I don't think there was anything that LLMs are doing that previously we were doing that was like really super high leverage. I think this was all the sort of stuff like you just got into a kind of groove, you felt good because you were producing something. But at the end of the day, like typing out those crowd endpoints really wasn't that high leverage. Like creating this, you know, like

Improvement to your CICD process, like I mean, maybe creating it was high leverage, but like it's it's it's hard because like it's the architecting and the and the having the idea and the doing that's high leverage. But if someone had just come to you and said, like, I have this plan, now you implement it, like the actual implementation would not have advanced you very far in your career. And so I don't know, like I still remain bullish on us as a field because I

There's just nothing it's really eaten where I'm like, darn. Like that used to be really fun to do. yeah.

Nathan Toups (24:37)

Yeah, and

and and I would say that, you know

For instance, it used that used to be an industry where a software agency would build your website from scratch. There

Carter (24:50)

Right.

Nathan Toups (24:51)

was no WordPress, there was no, you know, Shopify, there were no tools, uh, where building a custom shopping cart from scratch is actually not very valuable, right? That that's a that's something that's like a solved problem for most people. And if your business is really

shopping cart business, you have a product, you need to have represent it online somehow, you have these things. You know, once you have something that's sort of the commodity, and this gets back to like Wardley maps and s stuff like this, right? Once you've commoditized something that was unique and bespoke, um, the that job's gone, right? So there were people who specialized in building custom shopping cart apps because there was no pattern for this and you would listen to the customer and come up with a unique experience.

Now there's expectations, people have, you know, there's compliance, there's all these things. And so I, you know, yes, we can t catastrophize uh all kind uh all kinds of things that are going on. And yes, some of it's moving faster than we can even wrap our head around. I'm not downplaying the scariness of some of this. But what I but I I agree with you in the sense that it, you know, if you identify your job as a set of tasks that you're doing, that is a very dangerous place to be.

If if you identify your job as a set of uh your your ability to problem solve unknowns with a set of you know patterns and tools that are are available to your disposal, well then then if you think about this reframing, it's well my patterns and tools are going to evolve over time, right? Which tools I use to solve these problems, the patterns that I learned to recognize, the world as it changes around me.

If my job is to do that is to continuously learn how to to do that, I that seems like a very optimistic, you know, view of the world. I I don't see this as being an incompatibility even if the tools available to us make my job unrecognizable in five years. I

Carter (26:54)

Right.

Nathan Toups (26:54)

you know, I yeah. So I and and again, I think if we if you're if you think in the high leverage standpoint, well

We'll just take the tools and figure out how my leverage gets better. Right. I don't have to be in as involved in the same way that there was a time that everyone had to think about how was the code I wrote um represented in assembly. And you were supposed to go in and like look at the ASM that was generated

Carter (27:21)

Right, right.

Nathan Toups (27:22)

from your C code or whatever, right? And you're like, wait, why is this inefficient loop here? let me fix the C code so that, you know, the machine code that comes out of it is like super, you know, cleaned up.

And there may still be jobs that do this, right? Like if you're like a kernel kernel engineer

Carter (27:37)

Right, right.

Nathan Toups (27:38)

or something, but most people like again, if you're working in an e-commerce website or if you're building a social media platform, or if you're building some, you know, weightlifting or fitness app or something, you will never look at the ASM. Like that's never going to happen. And it doesn't mean that you're being irresponsible. It just means that that's the it's a different level of like where your areas of focus are.

Carter (28:01)

Yeah, it's uh I I think I think part of it also comes from like not just as an engineer, but like as a human being, do you have like an abundance mindset or like a scarcity mindset? Right. And and I've met I think there are too many people that are just so terrified of losing what they have now that they can't think about the exciting things that that may come later.

I've always been pretty good about having an abundance mindset, but this engineer in particular was just like, I really hope like our startup works or or the startup I was at previously works because like I don't think I'm gonna have another job after this. I'm like, this dude is wildly talented. Like this, like I would I he would be like if I had my own company, like one of the first hires I'd make, any company would

Nathan Toups (28:42)

Yeah.

Carter (28:43)

be lucky to have this guy. And he's just so I think nervous about kind of the changing world.

Nathan Toups (28:49)

So

I will say though, I so I and I and maybe this is just a cope because I I'll play this role sometimes. Like as optimistic as I am, I do have very strong opinions about sort of like our security posture or some other things that we have. And it sounds like this person's doing something very similar, which is have you ever seen the show The Terror? have you ever seen this show or heard of it?

Carter (29:09)

I don't think I have. No.

Nathan Toups (29:11)

Okay. So The Terror is great. It's a it's a sort of fictionalized account of these

Ships that were trying to find an from the UK that were trying to find a northern passage above Canada for trade routes, and they get this is the real part of the story. They get trapped and they're stuck there. They're sort of la locked into the ice. Um, and they die. I'm not this is not a spoiler, this is like the

Carter (29:33)

Right.

Nathan Toups (29:34)

historical part of it. The entire crew of both boats die. Um

Carter (29:38)

Mm.

Nathan Toups (29:39)

the show is about maybe what happened, and there's this whole thing that happens in.

Jared Harris, who's in a phenomenal actor, is one of

Carter (29:47)

Yes, yes,

Nathan Toups (29:48)

he's one of the captains, and he is just the most negative person. He's like, you know, there's all these people who are like, yeah, we're gonna get through this, and you know all these like very optimistic views. And he's just like, I don't, I'm not sure that we will. Like this, here's all the things that could go wrong, and I'm really worried about this, and we need to send a party out. And I sometimes I will fall into the Jared Harris role. And it can be very annoying to somebody who's very optimistic.

Carter (30:10)

Right.

Nathan Toups (30:13)

But I will tell you, Jared Harris was right. Like in the terror,

Carter (30:16)

Right, right.

Nathan Toups (30:17)

he was correct. Now he was also wrong about a bunch of important things and he had some character arc stuff. The Jared Harrises of the world can kind of like get to doom and gloom where the things don't work out. But sometimes it's incredibly important that you listen to a Jared Harris. That, you know, maybe our hope for the optimistic outcome needs to be tampered with a, hey, if we go on this trout r this track.

We don't have enough food to make it through winter.

Like,

Carter (30:45)

Right, right.

Nathan Toups (30:46)

you know, instead of being like, hey, I you know what, we just we'll just cut portions down by a third and everything will be f you know, like so sometimes you just have to be like listening to the Jared Harris. And so I I I really appreciate if you've cultivated an environment where Jared Harris's can exist, right? Like there's this

Carter (31:03)

Right, right.

Nathan Toups (31:04)

like at the same time you should tamper the tamper it because you're like, hey, you know, you have an imagined reality of the future that doesn't exist.

I have an imagined reality of the future that doesn't exist. They seem incompatible. Let's try to invalidate both of ours. Right. You work your hardest to invalidate mine. I'll work my hardest to invalidate yours. And um, you know, let's hope that we can get things to a place that we're all happy with. But we should listen to everyone, you know. Uh, you know, am I

Carter (31:31)

But guess I'm only

interested in pessimism in so much as it can motivate action, right? I think that's kind of when I when I get a little like, eh, like when people are like,

Nathan Toups (31:40)

Right. Well

Carter (31:41)

it's all going to crap. Like, what should we do about it? Nothing. Like, okay, well, I disagree. Right. Like, you know, may me

Nathan Toups (31:47)

Right.

Carter (31:49)

what if what if it's not all going to crap? And because it's not all going to crap, um, we can't we we should do this instead. Um

And anyhow, I I have even thoughts about that from like a

Nathan Toups (32:02)

I love this though, because I it

yeah. Uh so so one of the things that I I also and I think this again sort of ties into some pessimism that I actually really appreciate. And I will say it's critique. and we actually get into this. chapter three gets into this for a second, but I think humans do this as well. actually I'll skip to it for a second and then we'll come back. One of the things they talk about is like, can LLMs judge the efficacy of the output of an LLM?

Right. And there's like a bunch of

Carter (32:30)

Right, right.

Nathan Toups (32:31)

questions of why that would actually be hot garbage. But one of the researchers that she cites says, Hey, you know, it's actually hard to write a nice, like a good song. Right. It's like asking an LLM to say, write a good song. That would be very difficult. But asking an LLM to critique whether a song is good or not is actually not nearly as difficult. And that we can see this with ourselves. Like I maybe am not as talented as a pop artist, but I can listen to three popular

Pop songs and go, hmm, this one's better than those two, right? I I I maybe don't have like the most scientific reasons for it, but and then you ask a large enough aggregate of people and they'll judge, right? Whether a song's better or not. I think the same thing can be done for critique in uh art industry. And I think, again, I've brought this up many times, like Kelsey Hightower, Corey Doctoro, um, Carl Brown, uh, you know, folks who have dissenting voices are important to listen to, even if they don't necessarily have.

Solutions, right? Um, it's one of the ones that I I've actually been really enjoying with this, and we're I promise there's like a tie into all this. I've been playing with the idea from um Kelsey Hightower, what he calls the zero token architecture, which is this idea of can we use LLMs to put them put put an LLM out of its own job, which I think is just like the funniest thing to think about, right? It's like we we talk about

Carter (33:51)

Yeah. uh

Nathan Toups (33:52)

LLMs putting people out of jobs.

Like, can I use the LLM to automate itself out of a job where it's no longer into like loop? Like I'm not using like if I write a skill and I'm doing this thing with it, I'm like, wait, that is now a non-deterministic outcome that's coming out of this regular process that I'm doing. Can I get the LLM to write um some deterministic sort of outc out output

Carter (34:13)

Right, right.

Nathan Toups (34:14)

from it? And so I played with I I haven't and I'm announcing this to the world right now because I'm not finished with the blog post. But I'm I've been playing with this metric that very it's kind of silly, but I think it's actually kind of cool.

called mean time to determinism. So it's like, can we measure the mean time that it takes for me to take an LLM process and turn it into a deterministic process? So the mean time to determinism

is like from when I come with the idea to like when I've completely automated the LLM out of its own job.

Carter (34:38)

Right, right.

Nathan Toups (34:39)

Um, because I and then that's actually kind of a fun thing. I'm like, I I've been doing this with some compliance work where I'm using this LLM to help me explore a bunch of data and do these things. But as I'm going, I'm building out a run book and I'm building out a set of scripts.

So that it doesn't have to do this work anymore. Right. And so hopefully next month or the whatever the next cycle is, it's just a Python script that's like analyzing a bunch of data traditionally, like I would have done before LLMs. And that just gives that that like that tickles my fancy. Like that's a lot of fun. That is and it and it's and it all happened from a critique of, hey, are we getting too reliant on LLMs? Um

And it also frees up the LLM to do higher order work too, right? So I'm like, if I'm spending all of my tokens doing really silly base level things because it was just convenient, what if I

Carter (35:29)

Right, right.

Nathan Toups (35:29)

put if I put it out of not doing that and we have a new baseline of deterministic programming, can I get the LLM to do higher order work, right? And then go up the stack. So anyway, that's kind of like where I think the spirit of chapter one is all about. Um

in the like I AI engineering in the stack and like where does it sit and like what's its role?

Carter (37:15)

That's my my boss's belief is just that like engineering will eat the org chart in terms of like, let's say you do arrive in a world where like software engineering is quote unquote solved, which for what it's worth, I don't think will happen. Like my coworkers, like they'll just have product managers. I'm like, no,

Nathan Toups (37:28)

No

Carter (37:29)

no, no, no, like the product manager won't exist anymore. It'll all just be engineers. Like, I can't even imagine, like I get so antsy or like uncomfortable when I feel like I don't understand what's going on. And I don't even need to understand.

Everything like a very at a nitty gritty detail level. But like if I can't like piece it out, like as uh as Mitchell Hachimoto calls it, like the whiteboard test, like draw on a whiteboard a high level understanding of like the feature I just, you know, produced. Like I get so antsy. I'm like, I cannot even imagine a world where it's like the models are so good, we'll just hand them over to like people who have never done any software engineering in their life. I'm like, that's not gonna happen. It's it's gonna turn into software engineering's taking on more.

product ownership responsibilities. I think we're always worth this engineer I worked with doesn't like that. He doesn't want to have any product ownership. But it's another one of those things where like everything that's happening with LLMs, like it's all just continuation of trends that have always happened. Like any staff engineer worth his or her salt back in the day had strong product ownership. Like had opinions about what the business was building and why they were building it and how it should be built.

Um anyhow, uh it's a it's a lot. There's a there's a lot that's going on here, folks. But I just think like in a world where our job gets eaten, like I don't know, I think we'll all become like super duper marketers or super duper salesmen or super duper whatever. Because it and to your kind of point of like how do you automate the LM out of a job? Like I see so many people were like they have like these really complicated workflows set up with like these skills or whatever. I'm like, this is so

Token inefficient. Like this is a script. Like this whole chunk you've created in the middle is it like just run a script. Have Claude write the script for you, but it should be a script. And for some reason, folks just they don't think like that. I don't blame them for not thinking like that. Like they haven't been trained to think like that, but they don't.

Nathan Toups (39:32)

Wasn't it I I can't remember what big company it was. it's gonna drive me nuts. But I read an article not too long ago that one of these companies, you know, it's a story about honing back on the amount of tokens spend across the org, which is hilarious because like all these companies were all about token maxing and then people actually started doing it, and now they're like, Hey, don't spend so much on tokens. But if you actually analyze like what a lot of folks were doing, apparently they were using it to do OCR on PDFs.

Like a good chunk of the work was just like doing OCR and there all these tools existed already, but it was so convenient because you could just drag the PDF in there and say, Hey, tell me, give me the gist. And

Carter (40:14)

Right, right. Yeah.

Nathan Toups (40:16)

um, you know, it it it it is interesting of like what behaviors emerge and how these token spend is gonna be done because it and we've talked about this. It can't replace thinking. Like if you just

Carter (40:31)

Right,

right.

Nathan Toups (40:31)

decide

that you're gonna dial in the thinking part of your job, I do think your job's at risk, right? Because

Carter (40:36)

Right, right.

Nathan Toups (40:37)

why do we need you to enter that prompt to think for you? Right. Like that's I think the bigger the bigger question.

Carter (40:44)

We we've been that and that's always my metric for like, is it valuable to have a human in the loop here? Which is, am I learning something? Am I learning something while I'm kind of like building out this feature, interacting with Claude? We have had like we just launched this big product and kind of like towards the end, there's just like a lot of little bug fixes, kind of like, hey, like we're displaying the number of impressions here, but maybe we should be displaying the number of likes instead. And and like that really was like, I was just a I was a slop operator. I was just like, take ticket, feed to Claude.

Move on. And so we've been exploring like, okay, how could we get better at more like autonomous AI development? Like, uh, even for some of this like low risk stuff like this, where if it passes like the automated AI review, we're okay with the AI merging it in itself. Um, so I I mean I do think there are, but but again, I I I kind of view this as more like replacing tasks uh rather than jaw or you know, but but but I'll I again like

From I've read all night, there just so many people totally happy to like surrender its thinking to surrender their thinking to the LLM. I'm just like, yeah, but like I doubt you're a very good engineer before all that, right? Like you probably weren't doing a ton of thinking there either. Like

Nathan Toups (41:59)

Well and here's the thing. The over time, the folks who've reached conclusions that are useful, and by useful I mean it's useful for their career, it's useful for their employer, it's useful for customers, those ideas are going to win, regardless of my opinion about it. And that is, you know, some of that can be like, okay, cool. Well, the stupidest ideas are gonna go away. That's not necessarily true. There could be some really stupid and dangerous ideas that

perpetuate because they're useful enough to be market dominator, but are not useful enough to like analyze security risks, you know, for some period of time. And so, you know, I I do I I I think it's healthy that we're kind of pushing back on what the boundaries are. It is also to me, it's very telling who thinks that certain jobs aren't needed or kind of like excited about a job going away. Cause that itself is revealing, right? It that that's sort of like a

Carter (42:55)

Right, right.

Nathan Toups (42:56)

exposure of one's worldview.

So I I hope we live in a world in which all of us get to spend more time doing the things that get us excited and are valuable to other people. And maybe that's a little yeah. Like I

Carter (43:08)

That's how I feel. Yeah.

Nathan Toups (43:11)

it's just like, yeah, if if you get your job done and you get to spend as much of it as possible where you're like kind of excited about the type of work on your plate. Um unfortunately I've seen a lot of this where a lot of people feel like their job is to hit return and kind of crank out a bunch

Carter (43:27)

Right.

Nathan Toups (43:27)

of garbage.

And they feel kind of trapped. And um I don't want that future. Like that sounds horrible to me. And I hope that we, you know, figure out ways to get away from that.

Carter (43:39)

I

agree. Um, we we should discuss chapter two, just kind of like understanding foundation models. Look, the this

Nathan Toups (43:43)

We should. This is a great chapter, yeah.

Carter (43:47)

is a this is a book club masquerading as a podcast, not a book report masquerading as a podcast. If you want to know all the nitty little litty bitty details about the book, read the book. That's what we did. We read the book. We get to talk about whatever we want. but what we want to talk about right now is chapter two. But this is all the like understanding foundation models and like how they're built. Um

A lot of overlap here with like what is ChatGPT doing and why does it work? Uh by Stephen Wolfram. Um I think a lot of us are familiar with kind of like the the like the the base details of like an LLM model. Like LLM models are trained, they're their next token prediction machines. They're trained by consuming basically all of the text in the world, like basically all, you know.

All the text on the internet, every published book. Um, and then that's how they train them. That's how they get kind of like the even then some of these details, even I'm I'm fuzzy on, but basically like basically what they're they're training their uh what is even like the mechanism, the transformer, the transformer architecture, right? Is this idea that you know you can reorient the weights by like saying like giving it the text like the car is.

And having it guess the next word. And if it guesses correctly, that's good. You're rewarded. If it guesses incorrectly, you punish it, and then you know, have it guess again. Um, I thought it was interesting. This idea of like, so where does that training data come from? Um, I guess there's like this corpus of data called common crawl, which is like just yeah, a non-profit institution that just is had a habit of scraping the entire internet. Um and I also found out from this book that basically I think they estimate.

About 48% of common crawl data these days is no longer legal to use. Like Reddit, for example, change their terms of service to not allow you to scrape the website, in particular, because like these companies came along and slurped up all the world's knowledge and then, you know, started selling it to other people, which is I know we've talked about this on the podcast before, but I can't stand at anthropic. Like, I think I have good products as a company.

They drive me absolutely insane with their talk about like,

distillation attacks and like how egregious it is that someone would try to distill Claude. I'm like, Claude is a distillation of the internet. Like shut up. Um

Nathan Toups (46:11)

Um same boat.

Carter (46:12)

so yeah, no sympathy there.

I hope every model gets distilled. Like I hope it gets distilled until there is zero margin on these models. Um that's my other theory of like the the AI companies like I'm not like AI is a bubble. And like I think that like anthropic and open AI have a future where like they're as prominent

In our lives, or like as big a company as like Amazon or Apple. Um, they think they're making the digital machine god. That's not gonna happen. And I think that OpenAI anthropics future is a lot closer to like um like a SaaS company. They're they're gonna be like an like an AI cloud services business, um, much, much more like AWS.

in particular, like I've seen charts that basically like most of their spend does not come from their newer models. Like a a a good amount of the spend on it is from people choosing like the level of model that like is good enough. Like Opus drives far more revenue than Fable. And so I'm skeptical of kind of like how intelligent these the the models themselves need to be. And I think a lot of what more of the opportunity comes is like in the orchestration.

Around them.

Nathan Toups (47:29)

So

w one of the things that this chapter really made clear to me was what a room Rube Goldberg machine we've built. Right? Like

Carter (47:36)

Yeah, right. Right.

Nathan Toups (47:38)

it's it's amazing that any of this works because you look at this and you go, hey, we have this common data. yeah, and by the way, it's got a bunch of nasty stuff in it. And we have to have these like all these quality filters that kind of go in and uh it it doesn't do a lot of these things that we're hoping it would. So we had come up with all these like special ways to fix this or uh

to correct things at different phases. They they also talk about how what a few interesting things too, right? Challenges of training data and by language, right? The talking about the number of tokens it takes to do to to express certain words and things in English versus I think it was yeah, one of them was a it um median English test text was like seven tokens of use for this training stuff, but in Burmese

Carter (48:26)

Mm-hmm.

Nathan Toups (48:27)

It was like 72 tokens. And so

Carter (48:29)

Right, right.

Nathan Toups (48:29)

it's like 10 times more expensive to to do training for Burmese or uh I think Hindi and Bengali. It's it's talking about these challenges where I like this book because I just hadn't thought about this. I wasn't I remember I've been, you know, ignorant of of what goes into this. And then secondly, this book really doesn't hold back when it comes to like, hey, there's all these you know kind of partially solved or unsolved problems where it seems to be good enough.

Based off this way that we're measuring it. But I where again the Jared Harrison me, I look at this and go, yeah, but these to me look like compounding errors. For instance, we've kind of come up with this idea that we think that this is a good foundation and so we're gonna build a bunch of things on top of it. But if some of those foundational assumptions are wrong, we actually could have some like obvious improvements to how all of this works if we actually fixed some of the fundamentals.

And I have a feeling that what's gonna happen is there's going to be some pre PhD research, and there probably is even from the end of this book. I have a feeling that again, and I'm pretty ignorant, but even what Chip is talking about in tw 2023, 2024 terms, and what's common or corrective or the best practices now have shifted. Uh, and what which is why

Carter (49:46)

Right, right.

Nathan Toups (49:46)

the models have become more efficient. It's it's why we're able to do some things. Um

Carter (49:51)

But that's

even something I'd like to understand better because every time we talk about like the models getting better, the models getting better. I am not aware of any like major changes to this process of like getting all the data, you know, doing pre-training, then doing post-training. Like we're still using the kind of transformer architecture. And so that's another reason I've been kind of bearish on like we will invent the machine god, because like, I don't know, it all seems like kind of the

The same stuff just at a bigger scale with more complex

Nathan Toups (50:25)

Right.

Carter (50:25)

orchestration around it, but it's still at the end of the day an LLM.

Nathan Toups (50:32)

They there was a YouTube short that I watched recently. There's a there's a guy who wrote an interesting book. I kind of like this is off in left field a bit, but it's called Materialism is baloney, and it talks about how like consciousness might be this bigger, kind of more fundamental thing in the universe. But he was actually recently talking about how like why he doesn't think that uh silicon will become conscious in the same way that he's like, you know, you can make a simulation of a dog peeing.

And nobody goes, wow, like this is such a good simulation. This isn't actually a dog peeing. Like, versus, oh, here's a simulation of consciousness. It's actually consciousness, right? Like, like for whatever

Carter (51:12)

Right, right.

Nathan Toups (51:13)

reason, we've come up with a machine that kind of like it it simulates something that we it recognize, but never once have we had a simulator go, the simulator's so good that it is reality. And

the the burden of proof of like what it takes to go from here's a simulation of how things how things work the best we can understand into no we've actually created the real thing from the simulation. It's just I I think it's because we're kind of founded in belief that some people can be convinced that they've built something that we haven't because it feels kind of like a human brain.

Carter (51:52)

Right, right. Um, I I I thought like uh and and the more I learn about these things, the more I'm just like this very, very impressive technology, don't get me wrong, but it's still just technology. Um it's great to spend some more time with like post training, um, which is the idea that like, you know, it LLMs are just if you just train them like the internet data, then they would they would serve as very kind of like explanatory models. They wouldn't be able to have conversation because like

The data on the internet is not structured like a conversation. And so if you asked, you know, how to make a pizza, it would respond with for a family of six, right? Um, because that's the the data consumed. So post-training is the idea that after that you then start talking with the model, you know, having these conversations and then rewarding it based on like how it does in that more chat-based environment. That's part of what makes Cloud Code so powerful or like Codex, is that they are then post-trained.

As the model with the harness in conjunction. Um, but it's like uh I this is I think somewhere where things have probably changed in the past couple years. Is I don't know if you remember, but ChatGPT used to do like it would give you two answers and ask you which one you liked better, which I always thought was stupid because like the the it was like nine paragraphs. Like, dude, I'm not reading the nine paragraphs.

You give me already, like I'm already skimming these things, right? Now you want me to read

Nathan Toups (53:22)

Right.

Carter (53:22)

a separate nine paragraphs and tell you which one is better. Like it wouldn't surprise me if the data they were getting back on that was like total nonsense and people were just like, I will click the one on the left, because I just want to get these

Nathan Toups (53:34)

Well,

Carter (53:35)

two things out of my face.

Nathan Toups (53:36)

it chapter three talks about this a little bit, right? Which is that um it only works for questions that you're already a domain expert in, right?

Carter (53:44)

Exactly, right.

Nathan Toups (53:45)

You know, like you already have to kind of like if it says, hey, do you like this answer or that answer better? Maybe if I'm like pair programming with the LLM and I've already got some strong aesthetic ideas and then it's saying, Hey, here's the two conclusions I've had. But if you're if you're in uncharted territory and you really don't know.

It's the it's beyond useless, right? I I don't think that you

Carter (54:04)

Right.

Nathan Toups (54:05)

can actually give better than a coin flip on uh, you know, sh should I go to a psychologist? Um these are my thoughts. And it's like here's the yes conclusion, here's the no conclusion. You're like, I don't know how to choose between which is better because I'm asking I'm asking you, should I do this thing?

Carter (54:20)

Right.

Nathan Toups (54:21)

Um yeah.

Carter (54:24)

Yeah, I mean I mean like those poor suckers at Meta who got reassigned to like just Claude just generating or their their internal model and generating just tons and tons of AI code bases. And then they had to go through and just like label them. Um that was the other thing I was talking about. Like I'm I I'm like I promise you, these big companies are not keeping the engineers around out of the goodness of their hearts. Like, you know, all these companies love

They l nothing more, nothing gets them more excited waking up in the morning than the thought that they could cut headcount. Like that that's just what gets these guys jazzed. And so like then Meta tried to like aggressively cut headcount off that same assumption of like, hey, with LLMs, we don't need engineers anymore. And then they'd like a third of the people they cut, they'd offer like these big old return offers because they realized they'd cut too many, right? I'm like, if you could run AWS

Nathan Toups (55:16)

Yeah.

Carter (55:18)

with 50% of the engineers today, I guarantee you.

Amazon as a company is more motivated than anyone in the world to figure out how they can cut their own employees. Like the fact that they haven't is a huge signal as far as where this technology is. Maybe it'll change, right? Maybe they will we'll reach some threshold and um be able to cut everyone. But I don't know. Like the models are already insanely impressive. Like they're they're better at coding than I have ever been. Um yeah, we're still here.

Nathan Toups (55:49)

The

the funny thing is, and you can see two sides of this. If you could cut headcount because the models are so effective, then you're basically making the argument that we're living at a steady state place. We don't need that many engineers because we're not going to be growing that much. Because the same argument that could justify headcount cut by the LLMs being amazing, are the fact that you could 10x expansion of your business too.

Carter (56:15)

Yeah,

exactly. Right.

Nathan Toups (56:17)

Right. So like both of those are true. If you're in a growth industry and you think you could actually have a larger share of the of the market, and the LLMs were as effective as some folks are claiming, then you would have outsized returns on the value of your engineers. You wouldn't actually you wouldn't want to cut headcount because it would reduce your need to hire more engineers because you're expanding. And so like both of these things are true, right? It uh

If the LLMs were what the hype machine I think tells us, then yes, you can steady state a company on a smaller team, or you can grow and expand faster than your competition, which you would want either one of those depending on how you're building out your business. What we've experienced though is that there's a lot of interest in these tools that were trying to reduce toil, but we also have introduced a lot of problems, especially when it comes to code quality, especially when it comes to being able to reason about the system.

And that I think if anything, we've exacerbated the the creation of tech debt. And I think that our security exposure is significantly higher than folks realize. Right. That it's

Carter (57:29)

one hundred percent.

Nathan Toups (57:30)

it and so these are the thing like I and so I think all of these things can kind of be true at the same time because I I have not seen a compelling argument that says this is how we took a team of eight and beat a team of sixty-four.

Right. Or here's how we took a team of 64 and beat our closest competitor who's 10 times larger than us, um, and ship code faster and safer and more effectively. When we do start seeing those types of things outside of the hype cycle, I mean like real, real ones, there's a there there. Like there's something interesting that that'll come out of it. But from what I can tell, and even with the clients and stuff that I've worked with, there's some things that we're doing that are novel and interesting and better.

than they were before. And then there's some things that we're doing that like keep me up at night that I'm like, ugh, you know, we're we are one clever exploit supply chain attack away from all

Carter (58:22)

Right.

Nathan Toups (58:24)

of us having the hugging face problem. Right. Like where we like I'm like dealing with little critters that have like, you know, made their way through our infrastructure because agents went buck wild. And I I don't know how to solve that yet.

I and I don't think anyone does yet. Um it you know, we have we have to come up with new new patterns.

Carter (58:44)

What are you?

Well, I want to talk just a bit about chapter three, because chapter three was really interesting about this idea of like um evaluating foundation models and

Nathan Toups (58:52)

Mm.

Carter (58:53)

how do you judge them? Because you do get to a certain point where it's like the models are spitting out, like, you know, they've they've had all these like really cool advancements in math. And then it's like, but how do you even know that it's correct? Right? Like you have to be like a world class mathematician to even evaluate it.

Um I mean, was there anything that that stuck out to you here, Nathan, in chapter three that was particularly interesting?

Nathan Toups (59:16)

Yeah, because you know, we've kind of gone back and forth in the as the in the industry. Some of these things have kind of even maybe even not fallen out of fashion, but have become questionable. I think that first of all, we have benchmarks and we've seen this, the public benchmarks, right? And they're the kind of like tongue in cheek joke is that all the foundation models have gotten really good at like optimizing towards the benchmarks so that when their new model comes out, they can like brag that they're the best. Um

There's also the fact that, you know, how do you evaluate the output of something that has unpredictable outputs? And can you

Carter (59:57)

Right.

Nathan Toups (59:57)

get, do humans have to do this evaluation? Or is there a way that you can get large language models to evaluate large language models? And what are what are the trade-offs? What are the constraints? And this chapter really explores that quite well. Uh, even down to the fact that, like, could you have a

Benchmark upon which you measure yourself in sort of an objective way? Or is there this are we gonna have to get into a world where we have to compare a model to a model and then find the winner of those two models that are compared? And is that model comparison transitive? Like they kind of talk about this in the book of like, you know, if A is better than B and B is better than C, then therefore A is better than C, right? That's the sort of like transitive property.

And there's even some questions here, which is like, well, is that true? Like, is it could it be that A does better than B, B does better than C, but that when you actually pit A to C, they're actually not as comparable as you think. That that, you know, the

Carter (1:00:56)

Right, right.

Nathan Toups (1:00:56)

way that they go about tasks is different enough with depending on what you put on their plate. Um, and so again, I like about this chapter is it goes in super deep on like what exactly are evals or evaluations?

some patterns that are really common, like um AI as a judge and what

Carter (1:01:17)

Right.

Nathan Toups (1:01:18)

are there what are the trade-offs for again, AI as the judge is this idea that like, yeah, can an AI judge the efficacy of another AI? And do you have to have a more powerful AI to judge it? Or can you use a less powerful AI to judge a more powerful AI? And how how do you how do you do that? And like what controls and constraints do you need to have in place? And um what biases could be introduced and all these kind of like very interesting things.

Carter (1:01:42)

Yeah, that this is an area where like I really like where I work. I think one of our weaknesses is like not an inability to focus, but like I think we spread ourselves too thin. And you know, the CEO wants kind of like a general agent layer over the website and just been trying to tell him a bit like, do you understand like the commitment necessary there? Because this isn't just like you can build it and then leave it. Like the models will change, right? And and not even just in the sense of like maybe you could just pin it to the exact

version you want, but then the models are going to improve and then consumer expectations are going to rise. And so you need, if you're going to build something like this, to know like what does success look like and to be monitoring it pretty uh effectively, like to have a really solid set of evals for yourself internally, uh, to be paying attention to like customer behavior and like noticing like, are we dropping off conversations? Are there increased signs of frustration? Like,

Any, at any rate, like I think evals are a really, really interesting idea that I haven't been able to play with too much because I haven't worked on like a product where like the AI is the product necessarily. Um, like, you know, I use it a ton for coding, but it's like it spits out the code. I can look at the code, I can decide, okay, is this good, is it not? Right. Um, I think the idea of evals for like something more nebulous, or it's a really interesting idea and also a really like

Weird idea. And I that's part of why I wasn't as interested in AI when it started, is because it just the whole non-deterministic nature of it is very it's it's it's so weird compared to everything we have ever known about how a computer works. Um

Nathan Toups (1:03:27)

Right.

Carter (1:03:28)

but that's what makes it, you know, an exciting, challenging new opportunity.

Nathan Toups (1:03:33)

Yeah, and i even you can think of imagine internal products that we would use LLMs where we we really are kind of building something, even though it's not customer facing. Imagine you make a, you know, SOC to compliance bot internally that on every PR checks to make sure that your compliance and controls are being honored. You know,

Carter (1:03:54)

Right, right.

Nathan Toups (1:03:55)

how do you know it's actually catching what it should? Right? How how do you know

That it actually is reading your policy documents, evaluating that against what's in the PR. Um, is there a regression over time? Which model are you using? Um, you know, does it do it the correct what you would consider the correct job 80% of the time? Does it do it 60% of the time? Does it make up policies that aren't actually there? You know, these are the kind of things where now it actually is part of the product, right? You know, and and and a hallucination could reach um all kinds of like strange

in surprisingly negative behaviors, but also could do something absolutely amazing for the team. Like, hey, we caught a violation before the PR happened. We were able to mitigate it and remediate it and, you know, fix it before it actually became an issue. And I so I do think that even if it's not something that the outside world sees, as soon as we start having LLMs making decisions or telling us whether something is uh, you know, a good thing or not.

thinking about this like AI as a judge or evals or these kind of things, um, I think they're gonna slip in. I think that in the same way that like open telemetry has become like an obvious yes, right? you know, the teams just you can't make decisions about how the functioning of the system works unless you are measuring all of the things that open telemetry helps us measure. I think that we're the the standards are going to become oh, any LL autonomous agent

that help gives us some sort of output in the company that we wanna rely on is also gonna have to have an evaluator like itself. And I that's where I think things are going, uh, even though that seems to be evolving as as well.

Carter (1:05:41)

Yeah. Um, well let's let's wrap up. We well this is like I said, the first third of the book. Um let's we can wrap with the usual questions, which is what are you gonna do differently in our career as a result of having read this book? or at least this third. Nathan, what do you got here?

Nathan Toups (1:05:56)

Hey, maybe this is the the you know the m the recency bias or something, but chapter three, the chapter on evals. I think folks who listen to the podcast have known I've mentioned an interest in evals in the past. this is inspired and put in my notes a bunch of stuff that I'm gonna look into. Um actually there's folks in our Discord as well that have brought up eval frameworks that I've never heard of before. And so I I think I'm gonna do a little research spike on on the tooling that we could use.

Carter (1:06:25)

There we go. Uh for me, I mean, I I think the same. I I just I've never had to do any of this, but it's looking like I might have to start doing some of it. So I want to get a bit ahead of the curve here. As far as who we'd recommend the book to, I mean, I I think people who are really interested in like how LMs are trained and how they work, you know, that's a lot of like chapter two. I also think what is Chat GPT doing and why does it work is a great book here. Um but it helps to kind of cut through the hype. And so that's you. I I'd recommend this book. How about you, Nathan?

Nathan Toups (1:06:54)

Same, like, you know, you you find yourself increasingly getting into a world where your job is expecting you to build AI into the product. You you gotta check this book out, right? This is this is one of those

Carter (1:07:05)

Right, right.

Nathan Toups (1:07:05)

where um I I think it's it's a it's it's a no-brainer. It the author is well established in an authority in her field. Um I highly recommend also checking out her interviews. She speaks so clearly about these complex topics, and I think that that

clarity of thought comes through in this book. So if if you need to get better clarity of thought in what the expectations are, the risks, the tools available, how to think about these things, this book is just does an incr incredible job framing so far, right? We're only a third of the way through, but yeah.

Carter (1:07:40)

Great. Well, uh, thanks for tuning in, everyone. Uh, you can always find us on Twitter at BookOverflow Pod. I'm on Twitter at Carter Morgan. Nathan is working with his consulting agency at rojo roboto rohoroboto.com. And you can find us online at bookoverflow.io. And you can email us at contact at bookoverflow.io. Thanks for tuning in, everyone. We will see you later.