LALatent SpaceJun 25, 2024· 1:32:05

State of the Art: Training 70B LLMs on 10,000 H100 clusters

Josh Albrecht, CTO of Imbue, and Jon Frankle, Chief AI Scientist of Databricks, detail the challenges of training 70B models on 10,000 H100 clusters, from stolen Infiniband cables to GPUs silently returning wrong math. Imbue open-sources infrastructure scripts, health checks, the CARBS hyperparameter optimizer, and cleaned versions of 11 benchmarks plus 450,000 human judgments on ambiguity. Databricks released DBRX, a 132B-parameter mixture-of-experts model with 36B active per token, and a text-to-image model trained exclusively on Shutterstock's curated dataset. They discuss typical 3% weekly hardware failure rates, the difficulty of MoE training pushing network bandwidth, and why eval datasets need human scrutiny—most benchmarks are saturated once ambiguous examples are removed. Both emphasize that success requires deep understanding from firmware to final loss, not just fancy libraries.

  1. 0:00Intro & News
  2. 6:17The Release
  3. 13:15Hardware Setup
  4. 30:07Performance & Scale
  5. 46:22CARBS
  6. 57:56Evals
  7. 1:15:16Hot Topics
  8. 1:26:11Next Steps

Powered by PodHood

Transcript

Intro & News0:00

Host0:00

Welcome to the Late In The Space podcast, another super special edition. Today we have, uh, sort of like a two-header, uh, Jon Frankle from Mosaic Databricks or Databricks Mosaic, and Josh Albrecht from Imbue. Welcome.

Josh Albrecht0:13

Hey. Glad to be here.

Jon Frankle0:14

Yeah. Thank you for having us.

Host0:16

Hey, um, so both of you are kind of past guests. Uh, Jonathan, you were, you were actually one of the most popular episodes from last year, um, talking about MPT-7B. Remember the, remember the days when, um, we, we trained large models under a 7B?

Jon Frankle0:32

Yeah. Back, back when reproducing Llama 17B was considered a huge accomplishment for the field. Those were the good old days. I miss that.

Host0:41

Um, so things have accelerated a lot. Um, uh, actually, let, let's, let's do a little, let's do a quick catch-up, and Josh, you can, you can chime on, chime on in as well. Um, so Databricks got acquired. I, I talked to you at Neurowitz then.

Jon Frankle0:51

Mosaic got acquired, although-

Host0:53

Sorry. Mosaic

Jon Frankle0:53

... although sometimes it feels like Mosaic acquired Databricks 'cause, you know, we're having a lot of fun being here. But, you know, yeah.

Host0:59

Yeah. I mean, you are chief, chief scientist now of Databricks.

Jon Frankle1:01

Chief AI scientist. Careful-

Host1:03

Chief AI scientist

Jon Frankle1:04

... careful with the title. I- as much as I would love to understand how Spark works, um, I'm gonna, I'm gonna have to defer that to much smarter people than me.

Host1:12

Got it. Um, and you're, uh... I, I don't know about, like, you know, how, like, what you would highlight so far as, uh, post-acquisition. Uh, but the most recent news is that you guys released DBRX. Is that the, the thing that most people should be aware of?

Jon Frankle1:26

Actually, that's no longer the most recent news. Um, honestly, the most recent news, we, we announced this but it was at our Data and AI Summit last week, so it was announced among, like, 100,000 other things, um, is that we finally released our text-to-image model, um, which has been a year in the making through a collaboration directly with Shutterstock.

Um, there was a lot of work put into finding a dataset that we were comfortable with working on, um, and trying to build a model that, honestly, I felt like I could trust and that others might be able to trust to put out in the world.

So that model was released last week. Um, it's unfortunately just available via API, um, due to the fact that, you know, the data is, you know, quite sensitive and quite valuable. It's Shutterstock's entire business in a lot of ways.

But I'm still really excited that there's now a model that is trained on a dataset where the provenance of every single image is known, and it's a damn good model, so I'm really proud of the team on that.

Host2:16

Yeah. Amazing. Um, Josh, you have any thoughts on image model, uh, questions?

Josh Albrecht2:21

That is not my area of expertise-

Host2:23

Image questions

Josh Albrecht2:23

... but I'm very, uh... I was excited- ... to see the, the release of it last week as well and, and very happy that you guys did, uh, a nice job on the data side of everything there. So that was cool to see.

Host2:32

I think what's unusual is, like, Sh- I think Shutterstock's doing multiple deals with multiple labs. So what is the Shutterstock model? Like, I guess, is this the house model for Shutterstock? Is this Databricks' version of the Shutterstock model?

Like, what is this?

Jon Frankle2:47

The way that I would think about it is that, like, Shutterstock is doing an amazing business in AI across the board. Their, their dataset is kind of widely known to be, you know, the best stock photos dataset in the world, the most comprehensive, the biggest.

Like, it's... You know, when you, when you think about, like, what dataset am I gonna train a multimodal model on, you call Shutterstock. Um, and, you know, I... at least I've heard in the news, like OpenAI, Google, Meta, um, Apple have all called Shutterstock and made those deals.

Host3:12

Yeah.

Jon Frankle3:14

Um, so a lot of models have had Shutterstock data incorporated into them, but this is the only model I know of so far where it was, you know, exclusively and specifically trained just on the vanilla Shutterstock data. There was nothing else mixed in.

You know, we didn't, we didn't go and scrape the web and find other data or combine datasets or anything like that. And so this is, in some sense, the house blend. Um, but the other piece is that it's just a dataset where the provenance of every image is known in public.

Like, where did the data come from? It is the Shutterstock collection. That's it. Um, you know, nothing less, nothing more. And certainly being at Databricks, if I've learned one thing, it's I've learned about enterprise customers and what they want out of AI, and one of the things they ask for most is just, "What can you tell me about the data the model was trained on?"

And here, especially for text-to-image models where images are just tricky subject matter, there's been a lot of kind of legal conversation about images especially. It's nice to just have something where I can point to it and say, you know, "If you wanna know where the images came from, these are what they are, and this is how they got there."

Host4:16

I will talk a little bit about Databricks because it's relevant to the rest of today's, uh, episode. Um, so Databricks, uh... So- sorry, uh, I keep mis- I keep misspeaking. It's DBRX.

Jon Frankle4:27

D- DBRX actually, um, there's been a pronunciation update. It is now DB Rex. Um, so we have decided to add a dinosaur mascot because-

Host4:37

Oh

Jon Frankle4:37

... what model doesn't like a, a mascot? So literally, I wish I could pull it up. There's a little plush dinosaur, um, that we had made. It's like the world's cutest dinosaur, um, but it is the official mascot of DB Rex.

Um, and there's a little dinosaur logo that, you know, you'll probably see around a little bit more 'cause, I mean, DBRX is a mouthful, but DB Rex, like, you know, it's just kinda...

Host5:00

Rolls off the tongue. Uh, I, I l- I love mascots. I think every, every company should have a mac- mascot, and I think Hugging Face got it right. You need an emoji mascot because that's the minimal viable image.

Jon Frankle5:09

I probably shouldn't talk at all about, you know, Velociraptor, but, you know, that's, uh- Maybe, maybe that's something we can talk about later in the summer. I'll just leave it at that.

Host5:17

Okay. That's a hint to, to names. Uh, I feel like your, your names leak a lot of alpha. Um, so, so just to, just to quickly cover the, the headline details, um, D Rex, DB Rex, uh, is Make Sure experts model, uh, that's fairly big, 132 billion total parameters with 36 billion, uh, active on any input, pre-trained on 12 trillion tokens of text and code, uh, and did really well on evals, uh, to the point where you had to dye your hair blue.

That's, that's my high-level conclusion, uh, about, uh-

Jon Frankle5:47

Never, never make a bet with your team two weeks out from model launch, even when, you know, human eval is looking quite bad, um, because if you set some bar, even if it's arbitrary and you think there's no way in hell they're gonna hit it, apparently money doesn't motivate people anymore Um, humiliating their boss motivates people, so Josh, you should really take a hint from this.

Um, you know, you cannot pay someone enough money to make up for you dyeing your hair blue.

Josh Albrecht6:12

I'll keep that in mind for our next model.

Host6:13

Totally.

Jon Frankle6:14

It works.

Host6:17

Uh, so speaking of Imbue's next model, um, may- perhaps Josh, you wanna, you wanna, uh, actually just say hi to the, the general sort of Latent Space audience and talk about what we're releasing today.

The Release6:17

Josh Albrecht6:27

Yeah. Uh, I'm Josh, uh, CTO of Imbue, and, uh, we're not releasing the model, uh, we're not releasing the weights, but we are releasing a bunch of different things- ... that should make it easier for other people to make their own models.

So I think right now, training foundation models from scratch is, like, a very difficult, time-consuming, uh, expensive, kind of risky endeavor, especially for smaller companies. Uh, and the things that we're releasing hopefully make that at least a little bit easier.

So the things that we're releasing fall into kind of three different buckets. Uh, one is infrastructure and, like, scripts for dealing with the kind of hardware and, like, you know, hardware failures and, like, understanding how well is the actually lowest level of things actually working so that you can actually do your training at all and at a reasonable speed without having to constantly restart and et cetera.

So infrastructure and training scripts. Uh, a second set of things, uh, is around the evaluation. So after you've trained it, like, how well is this actually working and how do you know how well it's working? We're releasing a whole bunch of, uh, different data there, uh, a new benchmark about code reasoning understanding, as well as our own private versions of 11 different open source, uh, benchmarks, so things like BoolQ or ANLI, where we've gone through and kind of cleaned up the data as much as possible by looking at all the ones that models get wrong or that are flagged for ambiguity.

Uh, and also our own kind of private reproductions of those, where we've done, like, a kind of clean room black box, like, okay, this is what the data set is supposed to be. Here are some examples. Let's make our own version of this to make sure that there is no data contamination, et cetera, to make sure that we're actually, you know, not, um, testing on train.

Uh, and then I think a final thing that we're releasing there is around four hundred and fifty thousand human judgments about ambiguity and question quality, which we used in the process of cleaning these evaluations, and we also hope will be helpful for other people training kind of similar models.

And then the third thing is Carbs, our hyperparameter, uh, our cost-aware hyperparameter optimizer, which was especially helpful for being able to experiment at much smaller scales and then scale those experiments up to the much larger scale kind of on the first try without having to retry.

You don't want to be training, you know, ten, 20 different 70B models. You really want to get these larger models right on the first try. And so the ability to kind of tune things very precisely and learn scaling laws, not just for, you know, the, like, data and, uh, and, and FLOPs, but also for learning rate and all the other hyperparameters and see, like, how should you scale these things up, uh, was extremely valuable to us as, as we were training the larger models.

Host8:59

Yeah, that's a lot of stuff.

Josh Albrecht9:00

Yeah, exactly. So it's a bunch of stuff. We'll have to go through all of it.

Jon Frankle9:04

Yeah, I, I just want to throw in how excited I am about this. Um, this is the stuff that nobody ever talks about that is the difference between success and failure in this stuff. Like, can you get your cluster to run?

Can you get software on your cluster? Can you figure out what broke? Because fault tolerance is still not really built into any of the fundamental primitives of training models. And so if something breaks, you have to go figure out what broke.

Your job stops. You have to restart your job. It is a nightmare just to get to the point where anything can train on the cluster. A basic MPI "Hello, World" that has the GPUs talk to each other is hard enough, let alone actually training a model, let alone getting good performance out of the GPUs, let alone actually getting a model that converges to anything interesting.

Like, there are so many levels of things you have to accomplish. Um, like, this is the kind of stuff that matters. Um, you know, I think to a point that Josh made earlier, you know, before we got on here, there are plenty of weights out there.

Nobody's released this.

Josh Albrecht10:05

Yeah. That, that was part of the motivation actually-

Jon Frankle10:06

It was

Josh Albrecht10:07

... is that, like, there are, are lots of other things that are complementary, but I have not seen nearly as much discussion about some of these other things that we think are pretty important.

Host10:14

I mean, in, in some sense, I, I'm very excited to have Jon, Jonathan on, uh, because this is a, a, a little bit, uh, your, your bread and butter, uh, with Mosaic. And, uh, you know, I think you've released some, some part of with, with Compose or Composer, and, uh, I think it's just, you know, really, really interesting to see, like, and, and, and a different take, uh, like a basically a full stack, um, take that's kind of open sourced, uh, today.

Jon Frankle10:37

Yeah, it's, it's really kind of... It, it's been an ordeal to figure this out, and every time something changes, whether it's a new GPU or even a new driver update, um, you get new creative errors and new things go wrong.

And, you know, we've dealt with the weirdest things from, you know, our Infiniband cables getting stolen from the data center twice, like, in boxes before they arrived at the data center. Like, you know, porch pirate basically had stolen our Infiniband cables back when those were hard to come by, um, to, like, you know, weird recalls of switches, to, like...

The, the strangest stuff has happened. I have my favorite GPU failures I've seen, like ones where the GPU doesn't fail. It has a correctable memory issue, um, and the memory correction causes the GPU to become a straggler and hold up the whole job.

Um, like weird stuff happens, and figuring out how to not just identify all of that but then eventually productize it is in some sense the entire story of Mosaic and now Databricks in terms of our ML offering. Really, the thing, you know, the thing we offer is we have, we have gone through this suffering and figured out how to even productize that.

It has been a pain in the butt.

Josh Albrecht11:48

Yeah. It's a lot of work. I think my favorite failure was, uh, GPUs just giving wrong math. Like, if they give errors, great, 'cause you can see the errors.

Jon Frankle11:57

What?

Josh Albrecht11:57

But if they just give you the wrong math back, not so fun.

Jon Frankle12:00

When did it give you wrong math?

Josh Albrecht12:02

Like, literally you could just, you know, add two things, for example. The numbers come back. They're not the numbers that they're supposed to be.

Jon Frankle12:11

I, I think it's important to say at this stage just 'cause, like, it... I think it goes without saying for Josh and I, but it's worth saying here. This isn't to say that, like, anything is wrong with this.

It's not like Nvidia did a bad job or, you know, Mellanox did a bad job or the, like, the server builder or the data center operator or the cloud provider, like, the million other parties that are involved in building this.

We are running these insane chips that are huge and complicated and built on tiny transistors at insane frequencies with insane heat in data centers that, for the most part, were not built remotely for this kind of power or heat and have been retrofitted for this.

Josh Albrecht12:47

Mm-hmm.

Jon Frankle12:47

Like, failures happen on a good day with normal CPUs, and this is not a good day and not a normal CPU for the most part. So it's, you know, it's fun to joke about all the weird things we see.

This is not to say anybody's done anything wrong. This is just kind of part and parcel of working on a massive cluster running at multiple megawatts of power at a time.

Josh Albrecht13:08

Yeah.

Jon Frankle13:08

It's crazy.

Josh Albrecht13:09

Yeah.

Jon Frankle13:11

So, but optical cables, like, all sort of, like, everything.

Host13:15

I'll take the opportunity to start in going to the sort of infra piece. Um, so there's, there's just, like, a description of the infra just to give people a si- a sense of what we talk about when we talk about massive clusters.

Hardware Setup13:15

Host13:25

Uh, so I'm just gonna read off the blog post here. Um, it's... This post is about one cluster that has 4,092 H100 GPUs spread across 511 computers. Um, they use Unified Fabric Manager nodes, um, which manage the Infiniband, Infiniband network.

And you talk a little bit about your networking. Um, is there anything unusual about this setup that you would call, call out to people?

Josh Albrecht13:46

Yeah. Actually, this particular cluster is a little bit non-standard. The normal, the, like, vanilla setup for, you know, these large clusters, as, as vanilla as it can be, is what's n-normally, like, a 127-node, uh, cluster, so closer to, like, 1024 GPUs instead of 4,000.

Here we have a larger cluster. As you start to get into the larger clusters, the networking becomes a little bit more custom. It's a little bit more... It's a little bit trickier. It's a little bit, uh, more difficult to get these things to, to all be able to talk to each other at the same speed.

Uh, and so this has, uh... In this particular case, this is a three-tier network architecture instead of two-tier is kind of the normal one, so most of the clusters are a little bit smaller. As you get to even larger scales, then it becomes...

this becomes even much more complicated and much more expensive. So we chose this particular scale kind of knowing our own workflows and kind of what we wanted to do. Uh, this was kind of the right size for us.

But, uh, yeah, I think it's, it's, you know, it's not exactly vanilla already. It's already getting into kind of the custom territory.

Host14:44

Yeah. Is this... Uh, is there any... So my, my understanding is that there, uh, and, uh, for the re- for what it's worth, I don't know if this is on the record or whatever, but you can just tell me to strike it.

Um, w- uh, is there any, is, is there any part of this that comes with the Voltage Park deal that you guys had? Um, is, like, is that, is that part of, uh, the, the hardware that you got from the deal with them?

Josh Albrecht15:04

Yeah. So we worked really closely with Voltage Park to set up their, all their clusters and infrastructure and everything and kind of decide even, like, what to order, how sh- like, how should the networking work. Like, we were very involved in kind of the construction and bring up of this, and that's what this post is about, is about that process of, like, bringing up all these...

There's, like, different clusters in different places of different scales. So in this particular post, we're talking about this one 4,096 GPU, but there are other clusters that they have as well. Uh, and we were very, uh, closely involved with figuring out the exact architecture and kind of the trade-offs that go along with picking, you know, those exact components.

You really don't wanna, like, place the wrong order 'cause it takes months to get it and it's very expensive. So, uh, yeah, we were happy to help out with that.

Jon Frankle15:47

And then your Infiniband cables get stolen.

Josh Albrecht15:49

Yeah, yeah. Exactly. We wanted to make sure that we ended up with compute that would work for us, uh, and that would also work for their other customers, and so we kind of helped design something so that we would get exactly what we were looking for.

We knew that these kind of details would be super important, and that getting down to the level of the hardware and, like, having these good scripts and everything was going to be a core part of, like, actually getting this to work.

I'm very glad that we did that. Uh, I don't think that most companies kind of take that, like, you know, full stack approach. But for us, it certainly paid off.

Host16:18

Uh, yeah. It's, it's basically sort of built to spec. Uh, it's, it's interesting that relationship because you usually, uh, for the rest of us, uh, who don't operate at your scale, we, we take whatever we can get from cloud providers, but you, you are basically co-designing from the single machine up.

Josh Albrecht16:32

Mm-hmm.

Host16:32

Um, and you described that a little bit. Um, th- You wanna take us through the process that you described here?

Josh Albrecht16:37

Yeah. So for the actual, like, the blog post and kind of bringing, bringing these machines online?

Host16:42

Yeah.

Josh Albrecht16:44

Yeah. Um, so yeah. I think the process, uh, as we have it broken down in the blog post, there's kind of a, a few different layers. First is, like, getting the individual machines to work at all, and then getting the machines to actually be able to talk to each other, so getting the Infiniband networking to work.

And then getting to a point where, you know, not just the machines are working and they can talk to each other, but everything is actually working correctly. There's a big gap between, like, it's working at all to it's working perfectly correctly.

And then after you have all this stuff working perfectly correctly, uh, nice and healthy, then n-now you get into kind of the software data, like, training issues. And then after that, you're still not done. Like, now even once you're training at full speed, things are going to fail over time.

Things are going to change. There's going to be new, you know, firmware updates. Like, how do you kind of deal with this change and flux over time without going crazy and pulling your hair out trying to, like, reproduce things or understand why there are regressions?

And so there's a lot of work to kind of automate the infrastructure tooling as well. Um, and kind of the first step, like, bringing these things online in the first place, uh, you know, you have hundreds of machines at this point, so you don't necessarily wanna be, like, walking around with, like, a CD-ROM or a USB drive, like, plugging it in with your, you know, keyboard, like, hitting next, next, next on the LS install.

That's not, that's not how this works. You do that for one machine, uh, and then you use, uh, we use this thing called Metal as a Service, uh, to bring up all the other machines. So it's a kind of server that can kind of install the operating system on these other machines.

So most, like, when you're talking about these machines And like each machine is, you know, on the order of hundreds of thousands of dollars. So they usually come with a kind of out-of-band management, uh, interface as well. So they don't...

They have their Infiniband networking, they have their normal 100 gigabit per second Ethernet networking. They have like dual redundant, et cetera. And then you also have this extra out-of-band management network, so you can log in and you can see, like the boot screen, or you can see the blue screen of death.

You can like get in there and actually see what was wrong, which is pretty fun, and it makes it like possible to automate a lot of this work. So the beginning of that, and the blog post goes into much more detail about like exactly how we set these up and kind of the other, uh, errors that we ran into.

When you're bringing these online, you'll definitely have failures. Even if they all worked in the factory, they get shipped, some parts come loose, something fails, something goes wrong. So when you're bringing them online, there'll be some that don't quite work for all sorts of reasons.

As you start to be working at, with machines at this scale, like, you know, if something happens one in 1,000 times, you're like pretty likely to see it. Uh, and so you can get pretty rare, weird things, especially since we had fairly early builds and fairly early versions of this hardware.

Like these-- some of these are some of the like first machines that were ever produced, some of the first GPUs, so you got some extra special, uh, things there. We definitely worked with Dell, for example, on making fixes in the firmware level to be like, "Okay, like this thing is wrong, like we need to update this with the firmware to like actually fix this particular thing."

Uh, so we worked pretty closely with Dell-

Host19:37

Oh my God

Josh Albrecht19:38

... and Nvidia on the... Yeah, that's what I'm saying, like this stuff gets complicated. And the thing is like, you know, taking a step back, the whole reason we're doing this, right, is that we knew that this was going to be complicated.

There would be these kind of failures. And if we're just using, you know, AWS or some other cloud provider, these errors are still gonna be there, and you're gonna have no way to know and no way to debug this and no way to diagnose what's going wrong.

And so we would much rather be able to like call up Dell and say, "Hey, this isn't working." And they're like, "Yep, okay, cool. Let's debug it together. Oh, I see. Yeah, cool. We'll ship a firmware update and actually fix this for you."

That was a much better experience than like, great, it just magically fails. I guess we restart and hope that that machine goes away. Like that's not a very good place to be. Um, so yeah, that, that's kind of the first place, is getting to a place where like GPU training is working on your single node machines.

You can observe stuff. We have tons of tooling around like, you know, Prometheus and, and all sorts of other, uh, tools for understanding what's going on in these machines because you don't wanna be like logging into each one and looking at the temperature of something.

You really need to have tooling to collect all these metrics, et cetera. Uh, unfortunately, all of the scripts that we have for this are, like for this entire cluster and for all the simple structure, are a little bit like special purpose for our particular thing.

So it's not that every script that we have, it's not you can just like take this and plug this in. Even if we did open source all the tooling that we have, you'd still have to do like a lot of work to open source it.

What we are releasing is as many of the things that we can that are gonna be useful for other people. Uh, you're still gonna have to have some way of kind of managing these things, making your own like logging aggregators, et cetera, et cetera.

So that's kind of bringing them up to the like, you know, the single nodes are working. From there, it goes into... I'm happy to keep going if you want.

Host21:17

Well, I, I just wanna leave the opportunity for Jon to-

Josh Albrecht21:19

Yeah, yeah

Host21:20

... uh, to comment if, if there's anything that's different from, uh, how he runs things.

Jon Frankle21:24

Oh, I mean, all I'll say is I'll endorse this and say this shit is hard. Um, like this is really, really hard. And you know, I have a special props to, you know, the folks at Imbue because they were building this from the ground up.

Um, you know, at Databricks and at Mosaic, we typically work with cloud providers, um, because some of this stuff is just... there's too much to handle. It's complicated. There's a lot to deal with, and this doesn't even get into things like physical security, um, you know, securing power if you're the data center operator.

Like this gets infinitely complicated, um, and you have to abstract somewhere, like, you know. And then you get to the folks who are literally building their own custom chips and like, good God. Like-

Host22:06

Oh my God.

Jon Frankle22:07

That's, you know... If you're one of those folks, you're having, you know... Pour one out for the, the infra people at some of the AI chip startups who are having a really, really interesting time right now. Um, but this stuff is really hard, and I don't think we talk about it much because there are so many other things that are hard.

Um, but the other hard things I think everybody's becoming pretty familiar with at this point. This is something that I don't think there's ever really been a comprehensive discussion of, at least not that I've seen.

Host22:34

Yeah. So my impression is that you guys, uh, uh, Mosaic have, uh, your own software for, for sort of spinning up and down machines just like, uh, Imbue had to build. But, uh, Imbue probably... It, it sounds like Imbue, you guys went, um, a fuller stack.

I, I don't know how, I don't know how to describe it. Um, like, like Mosaic is not working with Dell on like their firmware.

Jon Frankle22:56

No, no. We're, we're typically working with like, you know, pick your cloud provider on their Dell firmware or what have you. Like it's kind of... I think, I think one of the things, I don't know, Josh, you can correct me on this.

It, it's kind of impossible if you're doing training to not go all the way through the entire stack, regardless of what happens. Like somehow I'm still chatting with cloud providers about power contracts even though-

Host23:17

Yeah

Jon Frankle23:17

... the whole point of dealing with the cloud provider is not to have to think about power contracts. Somehow I'm still asking them about which Infiniband provider they used this time, um, to see if this is part of the bad batch of cables I encountered on that cloud provider-

Host23:29

Mm-hmm

Jon Frankle23:29

... or what have you. Or like we're still talking about a firmware update from pick your provider. Like you can't not do this. It's convenient that they have data center staff who are worrying about what to send back to which provider when, and they have people who can go and wait for the Infiniband cable so they don't get stolen outside.

But you know, it's kind of... it's impossible not to really go full stack if you're thinking about the infrastructure at all. I don't know, Josh, correct me.

Josh Albrecht23:54

No, I think that's right. That's what we expected from the beginning as well, is that we would have to get in- inevitably have to get into the details here, and I'm glad that we kind of just planned for it.

I think it made it a lot easier from our perspective to have direct control over this. Instead of having to go to the cloud provider that goes to the data center that goes to the supplier, we could just go direct to Nvidia or Dell or the data center, whoever was responsible, and be like, "Hey- This thing needs to change."

And they're like, "Oh, okay, yeah, that is our responsibility. Great, we can fix that." So it was just a lot easier for us to fix these bugs

than if we had to go through an extra layer of, of email.

Host24:29

Uh, something we discussed in the pre-show was that you had a rule of thumb for, uh, your, your cluster of reliability. Uh, you say here in the post, by and large, you expect around 3% of your machines to break every week.

Um, so you're basically gonna churn through all your machines in a year. Um-

Josh Albrecht24:45

So as it says in the post. So that would be true if, uh, it was a uniform, uh, failure like that. But, uh, as it says in the post, like it's usually these kind of problematic nodes, and to be clear, that-

Host24:57

Right

Josh Albrecht24:57

... is the number that we've heard from other people, is like they're having about 3%. I don't think we're experiencing failure rates that are that high. I think ours is actually quite a bit lower than that, probably because we've taken the time to like dig into, um, a, a large, maybe larger number than we should have, of these failures and get to the root cause of it and be like, "Oh, okay," like, "that's exactly what's going wrong.

How do we fix this? How do we prevent this from happening? How do we make automated checks for this so that if it does happen, it just goes back to the, whoever, uh, owns that particular part of the process, and they can fix it immediately?"

Host25:26

Uh, and that's part of what you're also, uh, open sourcing, which is the health checks, right?

Josh Albrecht25:29

Yeah.

Host25:29

You got, uh, the NIC health check, GPU health check, disk space health check, Docker, D message. Uh, I don't know what that is.

Josh Albrecht25:36

That one, that one is-

Host25:37

There's just a, just a lot of stuff.

Josh Albrecht25:39

Yeah. That one is one where we realized that actually, like when these machines boot, sometimes they wouldn't actually boot cleanly all the way, or when they rebooted, they had problems that they didn't have when they w- were working before, which was kind of frustrating.

Like usually if you restart your computer, it gets better. Here, you restart, it did not get better, it got worse. Uh, that was very frustrating. So this health check looks at every particular line we've ever seen from the boot, uh, like in D message, like every single log line that your computer emits and says like, "Have we ever seen this before?

Is this expected? Is this in the right order, or is there something out of place?" If there's anything out of place, then we say, "Okay, great," like now it goes into this like longer, more triage list of like, all right, great, like, is this acceptable?

Should we flag this? Like, should someone take a look at this? So we're looking down at a very, very granular detail level what's happening on these computers to make sure that nothing is out of place. And that's critical because without that, if you're running your training, as Jonathan said, and you're, this thing is slow, like what are you supposed to do, right?

Like you really, you really wanna be very certain that like all 4,000 of these GPUs are working like they're supposed to. We know that, and so if it's slow, it's 'cause like we messed up the config or something else, and not because of this earlier thing that's like really hard to detect in software later.

Jon Frankle26:48

Yeah. I think the... I, I'm just curious to ask like, you know, suppose you were to set up another, let's say another H100 cluster, and it were at a different data center, and instead of the vendor being Dell, it was Supermicro or what have you.

Josh Albrecht27:00

Mm-hmm.

Jon Frankle27:01

How much of this would be repeatable, and how much of this would you have to redo? I, you know, I genuinely don't know.

Josh Albrecht27:06

A decent amount. I think it would go a lot faster the second time. I think there's lots of learnings that we had, and also the blog post, you know, yes, we are releasing the health checks, releasing some scripts, but a lot of the valuable stuff is also in the blog post itself, in the details, in kind of the, you know, the learnings that we've had and the sort of errors that we've run into.

We tried to, as much as possible, surface those so other people could learn from those and, uh, avoid the same mistakes or failures as well. So I think it would go a lot faster. Although, yes, there would certainly be some things that'd be a little bit different.

Um, I mean, there'd probably be different CPUs or whatever, but I think a lot of that stuff is less, um, it's less... That's the, like, that's less variable. Uh, I think most of it would apply the second time around.

Although, I'm sure next time we're building one, it'll probably be, you know, at a scale that's 10X as big with a different chip or something like this, and then who knows?

Jon Frankle27:54

Yeah. With ConnectX-8, that will have its own fun behavior and all that good stuff.

Josh Albrecht27:57

Yep.

Host27:58

Um, perhaps, uh, s- something that people don't discuss about, and you don't even talk about this in the blog, but I always wonder, is what is the timeline that's like kind of reasonable for this amount of work, um, at least, at least the initial stages?

And also, what, what does the team composition look like, uh, for setting up a cluster, right? Like what are the mix of skills that you typically would require, um, to, to, to get all this going?

Josh Albrecht28:21

I'm, I can't really speak to typical. One thing I am very proud of is how much we accomplished with such a ridiculously small team. Like our infrastructure team is like, you know, it fluctuates from week to week depending on like how many things are on fire and how much we need to build, but it's like between like three and six people.

Like it's small. It's not like some huge team of like tons and tons of engineers. Um, but those people are very, very good at what they do. Uh, and so that has allowed us to get a lot of mileage, uh, out of, out of these things.

I think it's not that we're building everything, right? It's not that three to six people built this whole thing. I definitely wanna like, you know, say thanks very much to Dell and H5 and, and Nvidia and the other people that have done a lot of the work.

Like to bring up this cluster, uh, you know, with 4,000 GPUs and a three-tier network- networking architecture, you have 12,000 cables, so that's 24,000 things that need to be plugged in. Like that's just a lot of stuff to plug in, right?

And you don't wanna mess it up. Like each one needs to be done correctly. Like if it's a little bit loose, like it doesn't really work. If you break it, you need to replace it. Like there's a lot of work that goes into this.

Uh, yeah. And then, you know, that's just like, that's it. That's if you were to do everything right the first time and if you didn't have to fix anything. But inevitably, you know, you will have to replace something, which means like taking all the wires out, pulling the thing out, taking all the GPUs out, going and fixing some cable, putting it all back correctly, putting it back in, doing this every time, like there's a lot of work that goes into it.

So there were a lot of people at Dell, Nvidia, and at H5 that all helped a ton with this stuff. Yeah, I don't know the exact size of the, the Dell team. It also fluctuated over time.

Host29:54

Yeah. Excellent. Um, and then, you know, you, you, you, um, so you have all the hardware set up, and now you're firing it up for a single node. Um, there's a long description that you, that you guys have about just like, um, monitoring the MFU, right?

Performance & Scale30:07

Host30:07

And-

Josh Albrecht30:08

Mm-hmm

Host30:08

... and, um, what each situation might look, might be, uh, indicative of.

Josh Albrecht30:13

Mm-hmm.

Host30:13

Um, one of the most interesting things t-to me that I, that I saw from, from here is like, you know, if training immediately starts off at 60% to 80% MFU, something's wrong

Josh Albrecht30:21

Mm-hmm

Host30:22

And it's, um, but like, you know, like what, what, what, um, are like, you know, some anecdotes or, uh, you know, notable scenarios here that you might, you might call out as maybe counterintuitive or super interesting?

Josh Albrecht30:35

I mean, there's, there's just so many of them. I mean, one of them, which I think is probably pretty common, uh, like common knowledge by this point, but like we did have a sort of like, uh... Which one was this exactly?

I think for the MFU, like gradually getting worse over time. I think that one, when we saw that the first time, we were like, "What the heck is going on? Like, why does it get just like a little bit worse?

This is so strange. Like, what, is it getting lazy or tired or something? Like, is it heat? Like, what, what's going on?" Uh, and then that, in this particular case, it was memory, uh, fragmentation, because you have hundreds of machines, they're doing garbage collection at slightly different times, and then they get slightly further apart and slightly more and more jittered until eventually they're all happening kind of at random times and just like really messing up each one of your steps.

Uh, so you just turn off garbage collection and call it a day, basically, to be honest. There's other things you can do if you want to be a little bit more sophisticated about it, but

Jon Frankle31:28

You, you can also just manually have it all garbage collect on some interval. Like, that, that's what we've done. We just have a garbage collection callback that just runs. But I've seen the exact same thing.

Josh Albrecht31:37

Yeah, yeah, exactly. So I thought that one was kind of fun. And we did trace that one down and look, and we did find the actual call. Like again, this goes to like having good tools. So we had really good tools where we could look at a bunch of like actual traces in C and be like, "Okay, cool, this is the thing that's taking a lot of time."

Or like, you know, "This is the thing that doesn't quite line up here." Like, "Oh, I guess it's garbage collection. Okay, cool. Interesting. Yeah, let's just try taking that off. Okay, great. That's what it was. Now we can fix it."

Uh, so for each of them, like basically bugs are not hard if you have good tools, but if you don't have good tools, bugs are ve- can be very, very hard. So similarly for like heat, another thing that we saw was like, oh, you know, the CPU is getting throttled.

Okay, well it's easy to see if you're monitoring the CPU throttling or monitoring the heat. If you're not monitoring that, it's really hard to know why it's just suddenly one of them is going slower.

Host32:23

I, I noticed also in, in the piece that you mentioned FSDP with Zero three. Um, actually, when we met, um, I, I went to ICLR and, uh, Guan Hua from the Deep Speed team was, was there presenting Zero+.

I was wondering if, um, you wanna make any call-outs to, uh, you know, particular open source or open library or open whatever implementation, uh, teams that were super helpful in your process.

Josh Albrecht32:46

Um, I think we ended up actually pulling from a whole bunch of different ones, uh, to pull things in, into our own-

Host32:52

Yeah

Josh Albrecht32:53

... particular pipeline. So we use things from NVIDIA's, you know, Megatron stuff. We use stuff from probably Deep Speed. I think we, we pulled in a bunch of different pieces from a bunch of different places, so it was really nice to see all these working open source, um, like examples.

I think I really appreciate all the effort that has gone into actually tuning these things. 'Cause you can tune them, but it's a lot of work to, to like tune this stuff and do all this stuff from, from scratch.

It's really nice to have like a working example. I think those are probably the two biggest ones, Deep Speed and Megatron LM, but there are probably other ones as well.

Host33:24

Is there, is there a particular thing in the ecosystem where you would call out as like, you know, there should be something here that is open source, but like, it's not really, uh, it's, like, like everyone kind of builds it on their own?

Josh Albrecht33:35

Hmm.

Host33:36

I'm gonna say something with the file system because everyone talks about the file system eventually.

Josh Albrecht33:41

The file system actually was... I, I mean, we did something kind of dumb there. Uh, like we have our own sort of local mirror so that we can, you know, like a crappy version of S3 that's local, but it's just a pretty simple script, right?

Like I think we run like a little web server that just like serves files and then, you know, can upload them and download them. Okay, great. And part of the reason we did that is that our internet connection in the beginning was not the like full speed one that we would eventually have, and so we are a little bit more kind of bottlenecked in terms of internet bandwidth.

Uh, and so we had this. I think we looked at a bunch of, uh, services out there like MinIO and some other ones. But a lot of these like, uh, come with a lot of extra overhead and maintenance, and since we already have so much infrastructure to deal with, we kind of didn't wanna, you know, bring in a whole other like cloud provider virtualized something something.

We just wanted something simple, so we went with that, um, which is, which has been quite helpful. Like the, our tools are usually quite simple. It's like Bash and Python and SSH and Docker. Like we like to keep things simple so that it's easier to debug, like less layers of infras- less layers of abstraction make it a lot easier to work with.

Like we don't use Kubernetes, for example. I would just directly launch these things, and it's just been much easier to debug this way. One, one tool actually that does come into mind that I will call out is, um, uh, Kraken, uh, from Uber.

That was great. We love that tool. Uh, we were a little bit skeptical at first-

Host35:02

What is it? I'm sorry.

Josh Albrecht35:03

Yeah. So Kraken is this-

Host35:04

Could you repeat it?

Josh Albrecht35:05

Yeah. It's a distributed, uh, like Docker registry basically that uses BitTorrent to like transfer things between the machines in a sort of nice optimal way. Like in the very beginning, the naive way is like you have this one Docker registry, which was outside of the cluster.

So every time we change an image, you know, there's many gigabytes that each of the 500 machines needs to download, so that just takes a really long time. So what this thing does is like just one of them downloads it, and then like they all sort of broadcast all the pieces to each other.

Uh, and it was just like a really nice fast way of getting these, uh, images down, and it was very robust. Like there's a lot going on under the hood, but I think it's a pretty cool tool that we haven't really had any bugs with it at all.

Host35:44

Amazing. Um, yeah, I mean, that, that's all my questions, I guess, for the infra piece. Uh, I don't know if Jon, you, you had, uh, something that you're sort of burning to ask or-

Jon Frankle35:54

No. All, all I can say is just same, um- ... in a lot of senses. Like, you know-

Host35:58

Plus one

Jon Frankle35:58

... been there, done that, seen this, plus one. Um, I think the one big difference, you know, perhaps in philosophies is we've tried to basically standardize on as much commodity stuff as possible just because, you know, I think the reason I asked about trying to do this on multiple different pieces of infrastructure is like, I think we're running on like six or seven different clouds right now, and everybody has done something slightly different And my gosh, the little differences add up as, you know, you've seen.

Host36:26

Mm-hmm.

Jon Frankle36:27

And so, you know, our philosophy has been like, "Okay, whatever the hell we can standardize, please let's standardize it," and like vanilla off-the-shelf FSDP and like, you know, we wrote our own data loader, but we've tried to make that as much of a standard as we can across our infrastructure and in Databricks 'cause things just start getting really complicated.

Or like we use Kubernetes extensively because it at least gives us a uniform set of APIs. Like, that's our hardware abstraction layer to a certain extent for everything else.

Host36:50

Mm-hmm.

Jon Frankle36:51

Um, so it's just, you know, a difference in philosophy there, but otherwise, like, yeah, this stuff is really, really hard. Um, and I feel like we take for granted how much of this, you know, is done for us when you go and you just query ChatGPT, for example.

Like, oh my God, everything going on underneath that, you know, it's kind of a miracle that the, the machines boot up, let alone that you can, like, query a giant language model that's probably doing inference across multiple machines and was trained across thousands of machines.

Like, you know, minor miracle.

Host37:22

Yeah, it is an awesome amount of power that we invoke with a single API call that we take for granted these days.

Jon Frankle37:27

Mm-hmm.

Host37:27

It's absurd.

Um, yeah, I mean, like Kubernetes, like, uh, that, that point about Kubernetes, I, I will say as a former AWS employee, like, uh, it, it, it seems like it would be, uh, ideal for Imbue to at some point make it more, uh, abstracted or agnostic, uh, because you're, you're, you're gonna wanna, you know, replicate your setup.

Josh Albrecht37:50

We do have our own sort of replacement, but it's just a much simpler version of Kubernetes. Kubernetes is really designed for running services, not for running experiments. Like, that's not its, like, main architecture. Uh, and so for us, like we have a thing that's like, cool, you're gonna run an experiment, so you want it to run to completion, right?

Okay, great. Like, the primitives are sort of built around a slightly different style, and that makes it a lot easier, like just a lot simpler to, to fit the, the nature of like these machines are gonna disappear. They will need to be rebooted for infrastructure upgrades.

They will... Like, something will happen to the GPUs. Failure is like baked into this as like a core part of our infrastructure. So it's not that we don't have an abstraction, it's that it's a sort of simpler, more tailored abstraction for the particular work that we're doing.

Jon Frankle38:30

Yeah, I think it all depends on what your goals are. And like, I think the challenge in a lot of the deep learning stuff right now is that people are trying to... Like, people often build things that are more complicated than necessary to get the job done, and complication is the enemy of everything.

Host38:45

Mm-hmm.

Jon Frankle38:45

Um, you know, don't use a fancier parallelism strategy than you have to. Don't use a fancier set of libraries than you have to. Don't do anything that you don't have to do, um, because it's hard enough as it is.

Like, don't overcomplicate your own life.

Host38:57

Yep.

Jon Frankle38:57

Don't try to bring in more tools or more fancy architecture tweaks if you absolutely don't have to. Like, getting to the minimum, um, necessary to get the job done. Um, and it's really tempting to wanna try to use everything.

Um, so like I totally understand that one.

Host39:13

I think the, the last piece I'll, I'll maybe call out is that, um, I'm just gonna weave this in just because I, I see the opportunity to do it. Are there any infrastructure shifts that need to be, uh, that, that, that need to rise because of changing arch- architecture?

Um, so I think, for example, um, Imbue, you, like, uh, you're announcing a, a, a dense model.

Jon Frankle39:36

Mm-hmm.

Host39:36

A 70B dense model, uh, whereas, uh, Jon just worked on DBRX and, and the sort of image-to-text, uh, the text-to-image model, uh, which pres- presumably has different bottlenecks.

Jon Frankle39:48

That's correct for us. Um, you know, we, we train both dense and, and mixture of expert models. The one we happen to, you know, kind of get permission to open source was a mixture of expert model, and those models are very demanding when it comes to network bandwidth, at least if you're training them in kind of FSDP 03 style, where there's just a lot of parameters getting shuffled back and forth, and your ratio of kind of compute to amount of data that you have to shuffle back and forth becomes a lot worse because you're now...

You know, you're only using a fraction of the parameters for every token instead of all the parameters. And so we had to really push the envelope on getting all the stuff to the right places on time. And so actually the networking part of DBRX was the single hardest thing, I think, of the entire process.

Just get MoE training working at scale across a big cluster. Um, we still managed to, I think, do it all with commodity parts, which was very exciting. Um, you know, the... Like, we were using FSDP and we eventually used HSTP so that we could have...

HSTP is a version of FSDP where you have multiple smaller replicas, um, and you're doing data parallel within those replicas, and that helped a lot with network latency issues that we were running into just because we were transmitting so much data, um, you know, for every single part of the process.

I think it actually, like... It was instructive for how Google designs their hardware and software together personally.

Host41:10

Mm-hmm.

Jon Frankle41:11

Their training, as far as I understand, using kind of a 03 style of training and have been for a while. They also train mixture of expert models. TPUs have a very different network bandwidth to compute ratio. They have a lot more bandwidth, um, just objectively, and TPUs per chip tend to be a little bit less compute intensive and have a little bit less memory.

Um, you know, it's just a different design choice. So the ratio of flops to m- to bandwidth is very different, and that means that it's much easier for Google to be able to pull off some of this stuff.

They also have interesting, you know, torus style network architect- or torus style like literal network architecture. It's not like the model, but the network, um, that-

Host41:49

Is this the, uh, sort of block attention? I, I forget what you call, what you call it.

Jon Frankle41:52

So this is-

Host41:53

Ring attention

Jon Frankle41:53

... this is just more or the... Yeah, this is more, not the ring attention, but these are the ring all reduces. Like you have three different dimensions of rings because they, they kind of put you in these three-dimensional toruses from what I understand.

And so like, you know, Google's infrastructure in some sense is kind of, I wouldn't say built for this, but maybe the way that Google trains models is built for a slightly different bit of infrastructure they have, and it's kind of neat to think about that.

You know, as, as one thing that I think Nvidia announced for, you know, for, for both the GH200 and the GB200 is this hybrid networking where you'll have blocks of NVLink networked chips. I think for the GB200, I think it's like groups of 72 GPUs will all have NVLink to each other, so higher bandwidth.

Then you'll have normal networking of some kind, Infiniband or RoCE or what have you, between these blocks. And that's kind of a, you know... It's a change due to the fact that, you know, it's hard to build really high bandwidth networks over very large groups, but it is now a blocked networking.

And you have to think about how you architect your model and your parallelism differently. You also have to think about fault tolerance differently because it now matters where you lose a GPU, whereas it didn't before. So, you know, it's, it, it's just all really interesting and really fun, speaking personally.

But it's gonna be new nightmares when we all move to that generation and have to think about, you know, new versions of these problems.

Josh Albrecht43:15

As you go up to larger scales, it gets quite different. Like right now, you know, if you're experiencing, let's say for example, you experience a GPU failure every day. That's fine, just restart. If you make your thing 24 times as big, now it's once an hour.

Uh, now it stops being quite as easy to just restart, right? So now you have to just kind of break, like bake in this sort of redundancy that you didn't have before. So I think as you go up in scale, you end up running into like a lot of, uh, really interesting problems that also inform the, uh, the actual like design.

Host43:50

Um, yeah, I mean, as an orchestration guy, this is why I, I always emphasize like very cheap storage or very fast storage so you can checkpoint more.

Josh Albrecht43:58

Mm-hmm.

Host43:58

But I don't think that's probably not the best solution, um, to, to, to... for, for fast, uh, you know, training.

Jon Frankle44:04

Which works fine when you're doing language and then you move to vision or video, and then, you know, you have multi-petabyte datasets.

Host44:12

Mm-hmm.

Jon Frankle44:12

And getting, you know, cheap, fast, multi-petabyte storage starts to bite. Like I've certainly encountered issues where the literal data center where my GPUs were did not have enough, you know, object store to fit the datasets that people wanted to bring into that data center from whichever users were, were trying to bring them in.

And then you get to a whole different world of hurt where you have to keep your data in a different region because the region is just out of storage. Um, so things get fun really fast.

Host44:41

Uh, speaking of vision, um, Josh, actually, uh, you know, Imbue is an agents company, um, but you're only-- you're announcing a text only model. Um, what, where does, where does the vision side come in?

Josh Albrecht44:51

Uh, I think we've actually done a lot of work in the past, and people can see kind of our blog posts about sort of self-supervised learning and, and some other kind of vision related stuff, uh, in the past as well.

So we're very familiar with, with that stuff. But I think our main focus right now is on kind of, as we say, coding and reasoning. And there, there's certainly a visual component to some problems. Uh, but you know, it's not necessarily required for all problems.

And actually we found that for most of the kind of like code writing and, and reasoning problems that we care about, the visual part isn't really a huge important part of it. Sometimes if you really need to, you can maybe describe, uh, the thing.

There are other like, you know, uh, multimodal models that you can use off the shelf to sort of plug in for those particular pieces that you need, right? Like if something is driving a browser or whatever, like y-you can sometimes get away with not having to have that baked into the original model.

So our foc-- we're, you know, in a sense we kind of do a lot across the stack. We're working on our own infrastructure and pre-training and RL and fine-tuning and products and everything, but in another sense, we're very narrowly focused on the application side.

So all of the stuff across the stack is kind of going toward like a very particular purpose. And so that particular purpose right now doesn't really need vision. So we think that people are going to make all sorts of really cool image models like Jonathan, right?

And all sorts of interesting multimodal models into the future. We'll let them go do that. That's great. We'll take advantage of that, partner with the, with, with those, uh, people in the future. And right now we're really focused on kind of the like core reasoning and coding capabilities and aspects of the model.

Host46:22

Um, I wanted to go into CARBS, um, since like that's like kind of the next layer of the stack. Um, we talked about CARBS in the first episode with Kan Jin because you've actually had a blog post about it like a couple years ago.

CARBS46:22

Host46:34

Um, maybe let's introduce it-

Jon Frankle46:36

That's been a couple years now?

Josh Albrecht46:37

No. It must've been at least one year. Uh, hopefully it was not multiple years.

Host46:41

Sorry. I, I'm counting in AI time.

Josh Albrecht46:43

Yeah, yeah. Um.

Jon Frankle46:44

Yeah, I was gonna say, you're making me feel really old right now.

Host46:50

I, I, I count everything before the generally intelligent rename as like, you know, prehistory.

Josh Albrecht46:55

Yeah.

Host46:55

And now, now sort of mod-modernity, right? Um, so, so I actually thought CARBS was more about hyperparameter optimization in a sense of like sort of parameter hyperparameter search.

Josh Albrecht47:06

Mm-hmm.

Host47:06

Uh, whereas, you know, you, when you introduced it, uh, especially in this blog post, it's more about scaling laws and predictability of, um, like are, are we, are we sort of in the right, uh, ballpark before we scale, scale things up?

Josh Albrecht47:19

Mm-hmm.

Host47:19

Um, just maybe, maybe sort of recount the history of CARBS.

Josh Albrecht47:22

Yeah. So it really is a little bit of both. So CARBS is, it's, uh, maybe a backronym, but it's for cost-aware Pareto region Bayesian search. Uh, so this is about technically how it works. But CARBS because like, you know, we like pastries and stuff, so great, why not?

Uh, but the point is that it's a cost-aware hyperparameter tuner. So most hyperparameter tuners, uh, you kind of say, "Okay, here's this objective function. I want you to make this number as big as possible or as small as possible, whichever direction you want to go.

Uh, so yeah, just go make this number, you know, as small as possible." Okay. So it'll try a bunch of different hyperparameters, a bunch of different configurations to figure out like, how do I tweak your network and architecture, et cetera, to get the kind of best, uh, performance I possibly can.

That's usually saying like, you know, almost all of these hyperparameter configurations are... let's say they're all gonna use the same number of GPUs or the same number of nodes, or they're gonna run for the same amount of time.

So you can do that, you can get a number out, and that's great. But what CARBS does is it says, "Okay, actually, what if we relax that constraint? What if we say each of these different points, we're going to model how expensive it will be to sample this configuration.

So if, what if we train with just one one-hundredth of the data?" Like how well can we do? What if we train with one-tenth of the data? What if we train with all of the data? That way you can understand, like as we get more and more data, as we spend more and more compute, as we make a bigger and bigger network, how does performance change?

But these things have changed, like how expensive it is to even explore this data point. So by doing that, we can see the scaling laws for not just, you know, the scaling laws from like the, you know, Chinchilla paper, the scaling laws for all parameters.

We can see how does, how does the number of layers change with this? How does the, you know, the learning rate change? How do the like, you know, various types of regularization change? So you can see these nice scaling laws and as you're going across costs, like how should this be changing as you're scaling up your model.

So that coupled with the kind of metric that we chose, which was a very precise way of measuring performance, allowed us to really like hone in on parameters that worked really well and understand, like how do we want to scale those up, especially as we're changing things about the network.

Like one of the things that we did is we used a custom tokenizer. Uh, as we change this tokenizer, it changes a bunch of other things about the model. So how should we scale up this entirely new tokenizer?

Like no one has ever made a model this large with this tokenizer before, and so how do we want to change all these things? Carbs kind of shows you like, look, as you change these parameters, like these other ones are kind of dependent on this.

Like this is the, these are the relationships between them, so you can better understand, like, okay, if I'm going to scale this up ten X or 100 X, like where do I want to be? Now you can only go so far.

Uh, and so, you know, we did run like a, I think maybe it was like a 14B one or something like that to check. Uh, but and so we had a bunch at like 1B or 14B, and then at 70B.

I don't think we had a b-- I think we just did like one at 14B. Um, so you can... And we get to check to like, oh, is this on the curve? Like is this where we expect it?

It was like right there. So then great, go on to the next one.

Host50:17

Yeah, I mean, that, that makes a lot of sense. Um, I wonder if, um, so one of the key questions, and, and correct me if I'm wrong, but like usually people, um, do search or do their evals just based on loss.

Josh Albrecht50:30

Mm-hmm.

Host50:31

Um, but you actually, uh, evaluate based on, you know, the, the sort of end state evals that, that pe-people might, might expect, like HellaSwag-

Josh Albrecht50:38

Mm-hmm

Host50:38

... uh, and Lum- Lambada, whatever. Um, is, what is the norm here?

Jon Frankle50:44

Is there a norm?

Josh Albrecht50:45

Yeah, I don't know if there's 100% a norm.

Host50:46

I don't know.

Josh Albrecht50:47

But, uh-

Host50:47

I only see loss on most, most people's reports.

Josh Albrecht50:50

I think it's easy to, like lo-loss is very nice 'cause it's very precise. It will tell you like it, very fine-grained differences between like really small changes in your hyperparameters or network architecture. Whereas especially at the smaller scales, if you're looking at like accuracy, it's very noisy.

Like it might be zero or 100 or like, you know, fluctuating by like 10 or 20 percentage points, which makes it really hard to tell, like did that change actually mean anything? So our loss is sort of a combination of these two.

Instead of saying like, "Let's just look at perplexity," uh, we say, "Let's look at perplexity on the tasks that we care about," or multiple choice questions effectively. So we're saying like, yes, this is formulated as a multiple choice question and we're going to look at the like, you know, the, the loss, the perplexity for this particular answer token.

And that ends up being something that's like both targeted to what you actually care about and also very precise. The nice thing about this though is that it's independent of the data that you train on. One thing that's annoying about perplexity or about loss is that as you change your dataset, this is really obnoxious because now it fundamentally changes your loss.

Right? And so you can't tell, like how do I tweak my dataset? But because we have this held-out evaluation dataset where we're looking at perplexity, we can actually change the data mix. And so Carbs actually controlled what is the mix of data that we want to see, like how much code, you know, how much internet text, et cetera, uh, in order to figure out what is the best optimal mix of data, and we could do that because we have this other metric.

So that was one of the things that was really, really helpful.

Host52:16

I think there is a trend overall about changing data mix as training goes on. Um, I don't know how, uh, you know, we're, we're, we're de- deciding not to talk about datasets- ... uh, in this podcast, but, um, what have you observed about the changing data mix, um, question?

Josh Albrecht52:36

We did, we did some experiments, uh, and we've actually talked to a bunch of researchers who were doing work here as well and looking at kind of, uh, their experiments on this. And we were originally pretty hopeful 'cause it sounds like something that should work and makes sense, right?

Like, oh, cool, like maybe you would have your model like learn the basic features and then over time it could get really good at these complicated math problems or coding or something, right? But it just turns out that like-

Host52:58

Yep

Josh Albrecht52:59

... it's just not the way it works. Like we've done so many experiments and you can get like a tiny, tiny little boost from this, but it just is not, like it's just not the important thing, at least in the experiments that we've seen.

Um, so yeah, we've kind of, we're letting other people explore that more if they want, but that just doesn't seem like the most promising direction for us.

Jon Frankle53:17

We've had, we've had some surprisingly good luck with this. Um, we, we just released a paper on it. The, the details matter a lot, and it, it really matters what you're trying to do with the model.

Josh Albrecht53:26

Yeah.

Jon Frankle53:27

But it's been, it's been quite effective for us, depending on the setting. Um, and certainly when we're thinking about domain-specific models, this helps a ton.

Josh Albrecht53:35

Mm-hmm.

Jon Frankle53:35

You know, to a certain extent, you can almost think of this as like early fine-tuning. Um, but yeah, I like there have been little glimmers of this in the literature for years, like especially I think the Gemini 1.5 paper mentions this, and I don't remember whether the Llama 3 paper mentions this, but it's kind of, it, it's one of those like people have different ways to get to these endpoints.

I think, you know, there are the architectural tricks that each lab has to mitigate loss spikes or what have you, and everybody's got, you know, their own bag of tricks, and it leads to kind of sometimes this contradictory information.

It's not contradictory, people are just kind of exploring different parts of the space in some sense, and there are lots of ways to get a great model. But certainly for us within our config, and it seems like, I guess for the folks at Google within kind of the part of the world they live in, changing the dataset has helped, but the details matter a lot, and it's really hard to get those details right for the reasons Josh, you know, just mentioned.

Like there's a lot of search involved, and you essentially have to make hard choices about what parts of the space you're going to search and which ones you're going to leave be. Um, and so, you know, some people have done an amazing job, like I think the, who is it?

The DeepSeek folks have done an awesome job looking at like batch size warm-up. And that's been really, really fruitful for them. Um, you know, other people are looking really hard at things like data mix, um, but it just gets tricky to look at everything.

Josh Albrecht54:51

Yeah. I think we found that, like, we could get some things that looked like gains from datasets, but, uh, one of the things that I like about Carbs is that when we applied Carbs to, like, properly tune things, then a lot of those kind of evaporated, whereas, like, hmm, like, if we just tune these other parameters, actually we can get almost the same gains without having to do this more complicated thing.

So at least in the experiment, in, in the settings that we've, like, in the particular metrics that we care about, we haven't seen these kind of, like, pan out or scale up in quite the same way, but not to rule it out.

And I think you're right, Jonathan, that there probably are a lot of, like, details that go into, like, exactly what is the metric, exactly what is the dataset, exactly which-- like, what schedule are we using for this, and I certainly wouldn't rule it out working.

Host55:36

Um, quick question about emergence. Um, doesn't emergence throw a spanner into theory of Carbs?

Josh Albrecht55:44

Ah. It, it-

Host55:45

So-

Josh Albrecht55:45

Just that there is a paper, uh, of which I really, uh, liked and I think informed a little bit of how we thought about this, which is our emergent properties of language models and Mirage. And I think if you look at that paper, uh, it actually makes a relatively compelling case that in fact, you know, this emergent, uh, behavior that you're seeing is not really emergent behavior, but is really a function of the evaluation metrics that we're using.

So if you look at accuracy as a metric, what's happening is that accuracy's actually going up continually over training, but it's in log scale. So it starts out at point oh oh one percent, point one, point or one, ten.

Only when you're going between ten and 90 do you see this happen, right? When you go from one in, you know, a thousand getting right to one in a thousand getting wrong, like, there's many orders of magnitude happening here.

So when you're looking at this in perplexity, then you just see this nice straight line. And so that's actually what Carbs is exploiting. Like, since we're, since our metric is in this kind of like perplexity log space, like, you can see, like, oh, it's just, like, getting better as you make it bigger in this nice, very predictable way.

Uh, so that-

Host56:47

Yeah

Josh Albrecht56:47

... and that is exactly what we saw. Like, these things were really, really bad at, you know, predicting the multiple choice answer. It just always guessed A, okay. It was so terrible at it. But it was like learning to be less confident about that.

Host56:59

Yeah, uh, one, one trick I, I saw from one of the papers recently was just like, just randomize the order of the multiple choice questions, um, and if you, um, i- if, if, if they, if they over, over...

If that hits the performance a lot, then they're, they're just basically memorizing the, the test set.

Josh Albrecht57:16

Mm.

Host57:17

Um, which makes a lot of sense.

Jon Frankle57:19

Yeah. This is, I, I mean, you know, I, I completely agree with what Josh said. I think the, you know, my bigger lesson is that anything can look however you want it to look if you put it on a log scale to a certain extent.

Host57:32

Mm.

Jon Frankle57:32

And log, we love our log scales in deep learning for various reasons. Everything looks very clean on a log scale until everything looks very flat on a log scale. Um, I don't know, I like, log scales always mix me up.

That's, that's all I can say.

Host57:46

Great. Uh, I think the, the, the last thing I was, I was gonna mention on, uh, Carbs... Oh, well, I mean, let's, let's just kinda go right into evals because I think that's gonna be, uh, the, the sort of crowd favorite.

Um, so Carbs, we already mentioned, um, you know, leans heavily on, uh, the sort of end evals that we would typically eval L- LLMs on, except that you had to make your own. Um, there are a lot of documented problems with, uh, many of the common evals out there, and you fixed all of them, it sounds like.

Evals57:56

Josh Albrecht58:13

I don't know about fixed all of them, but, uh, I think- ... in the same way that we like to dig into the infrastructure and hardware and understand, like, what actually is going wrong, like, what is the actual error on this machine with this GPU, and why did that happen and how do we fix it, we take the same approach to the evaluations.

So when we looked at the evaluations and actually looked at the datasets, you know, what we did is like, okay, if we're gonna be, you know, evaluating natural language understanding and reasoning, like, let's look at all the datasets that are out there.

Let's actually look at a bunch of the examples and say, like, "Is this a good dataset that we should use for evaluation?" That's kind of how we selected the evaluation dataset that we had. Uh, and then when we looked at the actual examples in there, we noticed, like, a lot of these are very messy.

Like, some of them messy to the point of, like, incoherence in some of the ones that we didn't choose. Uh, but even the ones that we chose, like, people tried pretty hard on these datasets. They did try and clean them, but there's just a lot of data points in there, and it's just easy to make mistakes, right?

And so, you know, it's not that they have 100 people looking at every question, like, that's just way too expensive, so you end up with questions that just don't make sense. Somebody didn't really see this. Somebody just clicked the wrong box for the answer.

Uh, or the question makes sense in your head when you write it. We've often seen this. It's not even, like, malice or incompetence. It's really just like, you know, you write this, you write it, you're like, "This makes sense to me."

You show it to another person, they're like, "That makes sense." You show it to a third person, they're like, "This makes no sense at all." It's because you're kind of, you know, using a different meaning of the word, and then when they r- say that, you're like, "Oh, wow.

You're right. That is actually really confusing." So it's easy for things to kind of make sense in our own head. So what we did for the evaluations is really dug into the details of each of these datasets and tried to ask, like, what makes a good question?

What makes a good answer? Like, what does it mean for it to be ambiguous? We had a whole, like... We looked at lots of data, broke this down, asked lots of people about all these different questions to build a model of this and help us kind of clean these datasets.

That was sort of one big piece of it. A second big piece was, uh, making sure that our data that we're training on is not data that we're testing on. So there we kind of took a step back and said, like, "Okay.

Well, let's just reproduce, you know, 500 to 1,000 examples for every single one of these datasets ourselves and just make sure that this data is definitely not in the, you know, the training set." So we did that, and then we're able to, like, now be confident that about, like, our performance, uh, of our model and also performance of other open source, uh, and other closed source models.

Host1:00:34

Yeah, there's a lot there. Um, you had, uh, 11 h- how, I don't know how many datasets you had.

Josh Albrecht1:00:40

I think so, yeah.

Host1:00:40

One, two. Yeah. Um, any one you wanna call out in particular to, to dive deeper on? Uh, some of these I, I've... are very famous, like HellaSwag, Winograd. Uh, some are less famous Uh, like RACE? Uh, I don't know if you've ever seen that one

Josh Albrecht1:00:53

RACE is a great dataset. Yeah. Um...

Host1:00:57

Yeah, w- just, you know, any- anything that's interesting you want to call out on, on specific datasets.

Josh Albrecht1:01:02

I think there are a few asterisks in there. Uh, you know, definitely read the whole paper as you're looking at some of these, like the GSM8K one is a little bit weird. Uh, I think one that was kind of funny was like low performance on ethics from some of the more recent models.

I think that was a little bit funny because the models, you know, I think there was a reaction to like, "Oh, no," like, you know, "The models are saying bad things." And so they went way, way in the other direction.

And now, like on the ethics dataset, it's always like, "This is totally unethical," even though it's really fine. Uh, so they've just been tuned to, you know, make sure they don't make any PR disasters, so I thought that was a little bit funny.

Not to say that it's necessarily like a flaw of the model, but just a kind of like-

Host1:01:39

Mm-hmm

Josh Albrecht1:01:39

... you know, political or tuning opinion. I think the main takeaway-

Host1:01:43

Um, to fix-

Josh Albrecht1:01:44

Oh, I was just gonna say the main takeaway from any of the, like perf- actual performance is like once you fix these ambiguous examples, a lot of these benchmarks are really saturated. Like, I think it's important to look at like, you know...

Like when you're talking about performance on ANLI or RACE or PoolQ or something, like what you're really talking about is like performance on questions that make no sense. Like, it's just like, did it guess the answer in this like really weird scenario?

Like, those are the ones that are left. Like when you look at the performance on the ones that actually make sense to everyone, all the models agree, we agree, like everyone's on the same page, which I think is kind of a really interesting, uh, result.

Host1:02:21

The question then becomes, you know, w- what, um, are the new like set of evals that, uh, would be like the next frontier, um, that often embeds with it your idea of what reasoning is.

Josh Albrecht1:02:33

Mm-hmm.

Host1:02:33

Uh, because I, I... Obviously you're super interested in reasoning. Um, and yeah, I mean, like where does this, where does, where does the state of evals go from here?

Josh Albrecht1:02:41

This work and this blog post is talking mostly about the public evaluations and the things that we can release. Uh, we do have our own internal evaluations. For example, one of them that we are releasing is the code understanding evaluation, which is about predicting, you know, what will this variable be, or asking questions about code, et cetera.

Uh, and that is one of, of the early benchmarks that we made that we can release. Um, we can partly release it because we can generate an almost infinite amount of this data, uh, because these, these are programmatically generated.

Uh, so, you know, we're not really worried about there being like, uh, corruption in the kind of the training or test set, so that makes it a little bit easier for us. Um, but I think it's... You know, we have built other datasets as well that we can't release.

Some of them, you know, for example, because they maybe use other open source code and so we can't redistribute it necessarily. Uh, other ones because, you know, that's... I think evaluations and data are like a core important part of, you know, the business.

Uh, and I think we take evaluations very seriously and are spending a lot of effort in terms of like what exactly do we make as part of the evaluation set? How do you evaluate these things? We've done a lot of other stuff, you know, since these evaluations.

Um, but I think a lot around like code understanding, uh, for us since that's our, that's our main focus. And, and it's a nice, like place to explore reasoning as well.

Host1:03:55

It sounds like you talk a little bit about like code understanding as like sort of variable level, like sort of very micro-

Josh Albrecht1:04:00

Mm-hmm

Host1:04:00

... context. Um, is there a sense of like larger code context as well? I don't know what I mean by that, by the way. It's, it's mostly just like if I told the senior engineer to go look at a code base-

Josh Albrecht1:04:11

Mm

Host1:04:11

... they would understand at a broad level the architecture, but also the design decisions and be able to tell me that. I don't know if that's useful or not, but I mean, that's useful to me as a-

Josh Albrecht1:04:20

Mm-hmm

Host1:04:20

... as, as someone who might be working with them.

Josh Albrecht1:04:22

Yeah. This particular dataset is like the more low-level code understanding, like just literally what happens in this code.

Host1:04:28

Yeah.

Josh Albrecht1:04:28

And this is mostly because, you know, this is part of the CARBS tuning metric, et cetera. Like we care about the low scale version of this as well. We want smaller scale models to be able to do something on this.

Uh, and so that's kind of the focus for this, and hopefully this is more useful for other people. Uh, but yes, those other questions are also quite interesting. Uh, they get a lot harder to evaluate, like is this a good architecture or not?

Like you and I could probably debate for a while on, you know, different architectures. And so it becomes a lot trickier to do these evaluations as they become more realistic. So I think that's one of the things that we've, um, been playing around with a lot, especially around like code generation.

So if you're saying, you know, implement this function, okay, it can be kind of objective. But, you know, even MBPP, we've made our own internal version of this dataset, right? Where we've taken like every single example and looked at it and been like, "Does this actually make sense?"

Like what is the type signature? Like can we-

Host1:05:16

Oh my God

Josh Albrecht1:05:16

... you know, remove all ambiguity, et cetera.

Host1:05:19

So you basically like reviewed every single question on, on... I mean, that's impossible for like HellaSwag, right? Like-

Josh Albrecht1:05:24

Yeah, yeah, we didn't do that for HellaSwag. But this is for MBPP, which is- ... only like a few hundred, so w- we just sat down and did it.

Host1:05:31

Yeah, yeah.

Jon Frankle1:05:31

I'm so excited to get to look at this dataset. Like- ... this is such a resource for the community. I, I absolutely can't wait.

Josh Albrecht1:05:38

We should probably do the... I don't know.

Host1:05:40

Yeah. It's-

Josh Albrecht1:05:40

I don't know if we were planning on doing the, um, HEAL MBPP one, but hopefully we can do that one in the future.

Host1:05:45

Did you look at SWE-bench? It's the sort of hot new dataset out this summer.

Josh Albrecht1:05:49

Yeah, I've taken a quick look at SWE-bench. It's, it's really interesting. I like that it's a much more difficult, um, kind of coding, code-related task for bug fixing. I think it gets into some of these problems where it is a lot harder to evaluate these things once they get more realistic.

Like we were looking at the AgentBench paper, I think, uh, just last week for our paper club, and one of the things that we noticed is that actually, like both of the examples in the appendix that are given as like traces where it got it right, this is actually not the right solution.

Uh, and it's okay, you know. It's, it's, it's fine. Like it did make it past the test. That's what the metric is, that's what the benchmark is about, right? But like it just said, you know, like, you know, dot encode ASCII.

Like, well, that's not the right way to do this. Like, it just dropped all the other edge cases that you actually would have cared about in production for this thing. And there is like a better way of doing it.

Host1:06:39

Yeah.

Josh Albrecht1:06:39

And, you know, that's what the real golden patch was but, you know, that's okay. But then how do you test all of that? Like, as you start to do more realistic things, the test coverage, like getting test coverage over all possible ways of solving these bugs is really hard.

Jon Frankle1:06:51

Evaluation is the single hardest part of the whole thing. Like- I spend a shocking amount of time just telling our customers we need to find a way to measure what you actually want out of the model before you should ever touch a TPU.

Josh Albrecht1:07:03

Mm-hmm.

Jon Frankle1:07:04

And, you know, trying to convince my team and me to follow our own advice a lot of the time on that. And I think everybody, like, on the one hand, it's easy to laugh at the state of the evaluations that we have.

None of them are good. Like, if you go read these eval benchmarks, you'll always come away disappointed. Um, and yet they've given us useful hills to climb.

Josh Albrecht1:07:22

Mm-hmm.

Jon Frankle1:07:23

And we do seem to be making progress and measuring progress in the field, and I think anecdotally, models are getting better year to year. So I feel like people tend to go and get into one situation or the other, like, "Evals don't matter, I'm just gonna look at loss," or like, you know, "The evals matter a lot and they're all broken, so what do I do?"

And I think, like a lot of things in deep learning, we have to make peace with just complete imperfection. Like the, the most successful scientists I see are the ones who are okay operating in a world where everything's going to be broken, and yet we can still cobble things together and make something interesting happen.

I mean, we were just discussing that with literal infrastructure. Now we're all the way up to, like, how do we measure whether a model performed a complex coding task correctly? And everything is broken.

Josh Albrecht1:08:04

Hmm.

Jon Frankle1:08:04

And yet we're still able to make huge amounts of forward progress.

Josh Albrecht1:08:07

I think that's right, Jonathan, uh, and that the challenge isn't necessarily making perfect evaluations. I think our blog post here is about going really into the weeds on these to figure out, like, what does that look like? And I think one thing is, like, you know, as you said, we have been able to make a lot of progress without making these perfect.

That's great. You don't have to have perfect evaluations, and, you know, the more interesting work is the stuff that we can't necessarily publish about, which is the imperfect evaluations that we have for, you know, actual coding tasks, for example.

Like, what does this really mean as a person? And there, as you said, it's much messier, so it's a lot harder to put it out and say like, "Hey, everybody, use this," because there's so many rough edges. It's so hard to, like, even say, "Oh, is this even the right task?

Like, is this even the right way to, to do it?" And there's a lot of judgment, there's a lot of intuition that it comes down to. Uh, but yeah, I think that's where it's critical to do if you actually wanna make these systems work.

Jon Frankle1:08:59

Yeah, you, you have to make peace with, with living in that in between.

Josh Albrecht1:09:03

Yeah.

Jon Frankle1:09:04

And I think that in some sense, when I hire researchers, that's the number one quality I look for, like, can they be at peace living in a house that is neither clean nor messy, but is just kind of somewhere in between, and are they okay with that?

Josh Albrecht1:09:15

Mm-hmm.

Jon Frankle1:09:15

Um, are they okay with a few dishes being out on the table and a few clothes being on the floor? Um, or will that drive them insane, or will they just end up with all the clothes on the floor and, like, all the dishes out all the time?

Like, it's kind of... I, I'm looking for that perfect balance 'cause it, you know, we have to operate in this imperfect world. Like, yeah, go ahead and give me the perfect evaluation for programmers or for an LLM that is a program assistant tool.

Josh Albrecht1:09:38

Mm-hmm.

Jon Frankle1:09:38

Like, there is no perfect evaluation.

Josh Albrecht1:09:40

Yeah.

Jon Frankle1:09:40

Um, but clearly we've made progress, and so the most important part is just are we climbing the right hills? And so this is why I'm so excited to see the ambiguity aspect of this.

Josh Albrecht1:09:48

Mm-hmm.

Jon Frankle1:09:49

We often think we have more room to climb on these benchmarks, and it turns out we don't, or it turns out that actually we're climbing getting good at the benchmark and not actually getting good at the task we care about underlying the benchmark anymore.

Maybe the model, like this is the famous example where if you get 100% on MNIST, your model must be broken in some way because there are four examples mislabeled. Um, you know, it's, it's that all over again. Um, welcome to this new world.

Josh Albrecht1:10:13

Yeah. It's the accidental canary, uh, canary in, in this-

Jon Frankle1:10:17

I think one thing-

Josh Albrecht1:10:17

Yeah, go ahead

Jon Frankle1:10:18

... that's actually really interesting about this also is that, yes, like the ambiguous examples are sort of, you know, not that great from the perspective of these particular tasks that we're evaluating, but actually one thing that we're very interested in is ambiguity itself.

Like, can we detect whether a task from a user is ambiguous or whether you've, you know, completed a task successfully? Like, these are actually hard, messy problems, but are really important from like the user experience of using these models.

I would much rather have a coding agent that will give me back a thing and, you know, it's, it's actually the code doesn't work like 10% less of the time than some other model, but it will tell me 100% of the time when it got, like when it's not sure.

Like, that's so much more useful if it can communicate, like, "I'm not really sure about this," or, "Maybe there's some errors here," than just like, "Here's some code. I have no idea if it works." And so these kind of like, you know, detecting ambiguity and detecting correctness or uncertainty, I think are really interesting problems that we're really, like, digging into quite deeply.

Josh Albrecht1:11:12

I'm gonna touch on, uh, maybe a couple of, uh, hot topics in evals, uh, maybe tangentially related, but we're on the evals train right now, so I'm just gonna, uh, get, get on that. So, um, Arc AGI, uh, Francois Chollet's, um, uh, hot new thing.

It's, it's sort of, uh, my, my take on it is basically it's, it's trying to measure reasoning through an abstract IQ test effectively. Uh, I no- I notice that you don't use it. Um, there's a lot of community debate, pro and con about it.

Uh, what are your thoughts on just more abstract reasoning and maybe Arc AGI specifically?

Jon Frankle1:11:45

I think we purposely stayed away from the very abs- like there's BigBench, for example, that has a lot of, uh, I think kind of to me feels sort of similar types of tasks that are, like, very, uh, unrealistic.

Uh, like, oh, you know, we have books of different colors, and then you're gonna shuffle them and then like, which book is furthest to the left or something. Like, okay, cool. I guess it's neat. It's neat, I think, for us to explore in terms of, like, an agent reasoning in a, like, larger loop, and we do care about these types of evaluations there.

The types of evaluations we're talking about in the blog post here are for getting at, like, does this model, like in a base model sense, is this working at all? Like, there's no chain of thought in these evaluations.

These are just like, go straight to the answer. Does this make sense? Like, is this a thing that you can answer very quickly? That's what we are selecting for with these evaluations. This is not to say that these are the only evaluations we have.

I think the Arc ones are like a little bit too probably visual, uh, for us to really be able to integrate with, but I think some of the BigBench ones are-

Josh Albrecht1:12:43

You can tokenize it.

Jon Frankle1:12:45

Yeah. But, you know, I think it's, it's not really... I think you can spend a lot of time getting really good at these kinds of benchmarks without making like kind of more general purpose progress. And so I think we're a little bit leery of going too far in that direction.

Josh Albrecht1:12:58

Similarly, like coding competitions, like we do a lot of code generation, but we don't really do a lot on like code competition problems for the very, very hard ones. So I think you can go very far down that route and make something that's like really good at those problems, but not actually that useful as like a programmer day-to-day.

Yep.

Jon Frankle1:13:14

Take a different tactic, which is like at the end of the day at Databricks, I have 12,000 customers or I think that's the latest number, um, all of whom are trying to do something with, you know, LLMs or AI or machine learning, and those things don't look like these tasks.

Josh Albrecht1:13:34

Mm-hmm.

Jon Frankle1:13:34

I don't think I have a single customer that's asking to, you know, have AI solve abstract reasoning problems. Um, things are pretty-- like they can be ambiguous, they can be challenging, they can be really interesting, but none of them look quite like this.

And so, you know, I think to Josh's point, like it's really about asking, why are we doing this? If-- Even if you're trying to build AGI, um, and that's not personally my purpose and I, you know, Josh has much more interesting things to say about that than I do.

I don't even know if this is the kind of intelligence I would get excited about or care about personally, or if I would consider, you know, to Josh's point, this to be the indicia of intelligence. Um, it's neat, but you know, for me, it's like more down-to-earth things like having a model that can have a conversation with you about data that on the back end is running SQL queries on your literal data.

That's a much more interesting task to me. That's something that really matters day-to-day for my customers and, you know, different perspectives. But, you know, I think Josh and I would probably say the same thing, even though I would-- I'm guessing, I don't want to put words in your mouth.

You would say that you're pursuing more general intelligence in your own way. Um, and I would say that I'm very happy with narrow intelligence. Like I'm very happy with my little SQL bot and building 12,000 of those because they're, they're moving the needle for a lot of folks every day.

Josh Albrecht1:14:48

Yeah. I think we're, you know, we're not as far away, uh, in our positions, uh, as it might seem. I think we're also excited about like, how do you actually make these things useful? And that does end up being pretty narrow.

I think these other tasks can be interesting as like ways to explore these more abstract reasoning questions or like, okay, how could an agent actually work through this? But it's important to keep in mind that it's like a toy, not a real problem.

It's like it, it's a scientific tool to tell us something about the models. It's not something we should be optimizing for necessarily.

Hot Topics1:15:16

Host1:15:16

The one thing I'll point out is, you know, as a kid, I was graded into a gifted program based on my ability to solve these exact type of problems.

Josh Albrecht1:15:23

Yes.

Host1:15:23

It's like a test. And then I entered college based on my ability to solve SATs, which again, have nothing to do with my college experience, but whatever. Um, so, you know, we have a history and a humanity of doing correlated IQ tests to general capability.

Um, uh, okay. So the two more, two more viral evals and then, you know, I just want to be mindful of, of your time. Um, needle in a haystack, long context utilization.

Jon Frankle1:15:48

Oh, for the love of God.

Host1:15:50

Something, uh, well, okay. Like let's just assume that, you know, on our podcast, we've discussed the, you know, baseline problems with needle in a haystack, but just generally long context, right? It's a useful thing for agents. Um, I, I assume, um, a-and it's something that, you know, it, it, it's out there.

Like we don't know how-- don't, don't really know what the best way to, to utilize memory is, but like, I assume it's important, right?

Jon Frankle1:16:13

What I'll say is like, you know, I, I spend a lot of time thinking about RAG these days. And RAG, you know, in one sense, you know, uh, the way that I think about RAG is it's the world's simplest agent.

It is an agent that basically, you know, there's at least more than one thing happening in the process of building a model. It's at least a system. If you give the model the ability to decide when it wants to retrieve data from a context or retrieve data from a database, then we're talking about an agent.

Um, so RAG kind of, I think, like toes that boundary really nicely. There are a lot of reasons why you do genuinely need a long context. Like I don't think long contexts are problematic in and of themselves. I know there's some controversy even about that.

Um, I love the idea of doing like 1,000-shot tasks as an alternative to fine-tuning. I love the idea of pulling in lots of data into the context. I love the idea of once you get into multimodal land, you're just gonna end up with giant context.

It's kind of unavoidable. Um, the flip side is, I don't know of anyone who like is hiding a secret passphrase in a book and needs the model to find it. Um, needle in a haystack is-- it's interesting. The, the challenge with long context to my mind, and Josh, I'm curious what you think, is simply that annotating long context evals is really hard and really expensive, you know, intrinsically, because you need someone to read 10,000 tokens or 100,000 tokens, or like you need someone to read a 1,000-page book or the equivalent thereof in order to measure these long context benchmarks.

I don't know if a human could solve these tasks, um, let alone that a human could do this in any amount of time where you're willing to pay the money to get the data annotated. And so any long context eval has to, in some sense, be correct by construction.

And you have to, you know, the, you have to know the answer before you've created the example, and needle in a haystack is kind of the simplest way of doing that. I, I think the problems with needle in a haystack are well known.

You know, it doesn't measure anything real. You're not even testing the model's ability to holistically use the context just to identify one part of the context. Um, so you can do some wacky things to your model, like quantize the hell out of the KV cache and still get needle in a haystack to work quite well because it's not trying to holistically take advantage of things.

Um, you know, I have some thoughts on things that I like more that are also still correct by construction. Um, like I really like the idea of doing 1,000-shot tasks where you can look at the scaling as you go from 10-shot to 100-shot to 1,000-shot to fine-tuning on that data instead.

And I like that as a way to, you know, have something that's correct by construction, or at least where you have a nice baseline that you can compare to automatically. So I'm typically looking for like contexts that or situations where long context is one way to solve the task, but not the only way to solve the task.

And we have some other strong baseline floating around personally. Um, but yeah, needle in a haystack, not my favorite thing in the world, to say the least.

Josh Albrecht1:18:49

Yeah. I, I mean, I agree with most of what Jonathan said, I think. I think one other thing that I will call out is that, you know, from like a coding application perspective, it's useful to have long context because the lazy thing of just like throw the whole repo in the context is like, oh, okay, cool.

Like, you know, you can just get started with that. But then in, you know, in real scenarios, you don't necessarily want to put the whole thing in there. You can have code bases that are bigger. You probably want to filter it down to the stuff that's relevant anyway to not be confusing.

Like, you probably-- even if you did have a lot of context, you might want to sort it in some way to say this is more important than this other stuff. So, and, you know, you don't want to wait for...

You don't want to be wasting all this time and compute on inference and, like, doesn't really matter. So yeah, I don't know that, uh, it's the most important thing.

Host1:19:31

Uh, I, I think people will find creative use cases and, like Jon said, I think the multimodality-

Josh Albrecht1:19:35

Mm-hmm

Host1:19:36

... examples will naturally lend themselves to long context.

Josh Albrecht1:19:39

Mm-hmm.

Host1:19:40

Um, cool. And then, uh, one last one on just general sort of agent-related capabilities that we didn't really talk about in eval section is function calling and tool use. Um, there's a recent trend, I think basically led again by OpenAI on parallel function calling.

Um, there's, there's a, there's always, there's been a limit on how many tools you can call, um, from four to now, I, I think 128, and, uh, I think theoretically, Claude and Gemini support a lot more. Um, so, so just generally, like, how do you think about evaling tool use?

Uh, is, is that super important for you guys? Um, anything of that sort.

Josh Albrecht1:20:14

I think we're thinking about it in a slightly different way, which is, yes, you can have this, like, hard-coded list of tools, but if only you could have, like, this really large open set of, like, tools, maybe they would be, like, functions that you could call.

If only there was, like, a language or, like, a programming s- thing, like being able to write code. I think for us it's like, well, look, if we can write code, like now you have all of these tools accessible.

At the end of the day, like function calling is just a function invocation, like literally in code. So I think our approach to this is like-

Host1:20:41

Yep

Josh Albrecht1:20:42

... instead of worrying about, like, weird hard-coded agents using tools, like let's just make them able to actually write code robustly and make that code work and be able to debug that code and know if that code is safe to run.

Like, get really good at the, like, code writing and execution part of things, because that will open up the action space, like far more than, you know, 128 tools. Like, just everything is at your fingertips, especially I think over the next few years.

Like, we already have so many really good APIs. As we get better and better at writing code, we'll be able to make APIs of things that don't even have APIs today. So I think that's, that's kind of how we think about it, is less as like a special purpose thing and more as like this is one of the reasons to focus on code.

Jon Frankle1:21:17

On my end, the way that I think about this is, you know, I think a lot about how models interact with data. And so for me, tool use is really a question of how do you take models that are really built for unstructured data and have them interact with structured data?

So, you know, I, I... and I get the question a lot from my customers, like, "What do I do with tabular data?" Or, "What do I do with like, you know, JSON?" Or, "What do I do..." I mean, you name it.

Like even, "What do I do with a PDF?" Um, 'cause PDF parsing is still an unsolved problem even in 2024. And the answer, or even just the basic question of like, should I bother to structure my data anymore?

Shouldn't I just toss the table? Shouldn't I flatten it and just throw it into the LLM context and like let the model figure it out? Answer is no. Like, we've built all these fun APIs and fun languages and paradigms for dealing with structured data over the years.

Just use them. Have your model use them. Train a model that can interact with these things in a meaningful way. Um, like it's, you know, text to SQL is still-- or like having a model be able to make SQL calls in the back end is actually like one of the single most useful things for my customers.

It sounds really boring. Models are really good at it, and it moves the needle day to day.

Josh Albrecht1:22:30

Mm-hmm.

Jon Frankle1:22:30

So tool use for me really is that. Like, how do you just interact with structured data sources and take advantage of the fact that you have some prior knowledge about the structure of your data that an LLM would completely flatten away?

You know, in, in many ways, this is kind of one of the, one of my biggest frustrations with the fact that LLMs work well with code. We have decades and decades and decades of understanding about the structure and interpretation of programs.

Like, I think that's literally the name of a book on programming, if I remember right. Um, and like we've, you know, we have all this theory. We know everything there is to know about programming languages if they're well-formed languages and have the right properties.

And yet when we have an LLM work with them, we literally just turn it into a token stream. Despite the fact that we know how to parse it, we know, you know, how to do all sorts of, you know, reference, you know, disambiguation and things like that, we're still just flattening it into a model and making the model relearn all of these things from scratch.

And it frustrates the hell out of me. I don't have a better answer when it comes to code, but I really appreciate that with a lot of data sources that have structure to them, tool uses and function calling are just, in my mind, the right way to deal with this.

Host1:23:39

Uh, so I think basically what you're saying is like code is the God tool for, uh, Jonathan. Like, you know, SQL is, um, so much, uh, the right abstraction for accessing all these, all this data. Um, one thing I do th- spend a lot of time thinking about is, um, you know, for the stuff that doesn't fit in a SQL table, um, you know, is knowledge graphs the answer?

I think a lot of people are exploring that. Um, and I think every now and then people get a bout of knowledge graph religion, and then it, it kind of doesn't work out. Um, so I wonder, uh, what that, uh, you know, I, I, I wonder what the end state is.

Like, you know, is, is this an idea where like it's, it, it's a, it's a, it's a mirage or is this the idea where sometime it is gonna work?

Josh Albrecht1:24:20

It's about, like having the right tools for the problems, right? Like as Jonathan was saying, SQL is sometimes definitely the right tool. Like you've got your, you know, order table or something and you want to know, you know, number of sales last month, like you should be using SQL, sum that column.

Okay, great, you're all set. Knowledge graphs also, you know, are sometimes the right tool for a particular problem. You have some like weird question about relationships between entities that are modeled on some particular ontology that you actually understand and i- is, is like maps to the real world.

Great, you know, use, use a knowledge base. Uh, like use a knowledge graph. This, this is fine. But I think in the real world it gets a lot messier than like knowledge graph, uh, style of things where it's like, well, is there a relationship between these two nodes?

Like, ah, I don't know. Like is... are these two separate nodes? Like those kind of messy borders I think prevent it from being a tool that can like solve everything forever. And so I think it'll always be good for certain problems, just like SQL is good for certain problems.

Like different abstractions are good for different problems and You know, yeah, I think this is why I'm excited about code. Like code lets you kind of pick the right, like, "Let's use this library for this problem, let's use this library for this other problem."

Jon Frankle1:25:21

You know, it... Like code is-- I think, you know, Josh said it and you said it well, like code is kind of the God tool. Um, it unlocks literally everything. Um, the, the challenge for me is always like, you know, sometimes unlocking too much power can...

Sometimes inconvenient things can happen, and so it's all about balancing that. In some sense, language is the God tool. If only, you know, we knew how to, you know, we knew how to interpret it all the time. So code is, has the really nice property that at least you can always execute it, um, you know, and sometimes you just literally want your model to be able to do SQL calls and nothing else.

Josh Albrecht1:25:54

Mm-hmm.

Jon Frankle1:25:54

And setting those boundaries properly for the problem, I think is gonna be... I, I think at least a lot of my customers are gonna be thinking very hard about that. Like, should I give the model access to the web?

Is that actually helpful for this problem? It sounds great to just like flip yes on all the tools. Um, is it actually gonna mean I'm gonna get better solutions to my problem?

Host1:26:11

Um, so I, I wanna be mindful of time. I think that's, uh, you know, basically our sort of recap of our discussion based on, uh, Imbue's releases today. I wanted to leave some time for what's next for both of you guys.

Next Steps1:26:11

Host1:26:23

Um, may-maybe, uh, you know, Josh, you wa-you want... You're-- as a guest of honor, you wanna go first as to like what happens next?

Josh Albrecht1:26:30

You know, we have these releases. We're happy to put these things out. I think there's a lot of stuff that we haven't released. Like, this is not the only thing we've been working on. Most of our actual focus has been on kind of coding and reasoning.

In particular, like the things that we're excited about are, can we make these things useful? Like Jonathan is saying, right? Like it's not about toy problems. It's like, can we use these today in our day-to-day workflow and actually have them accelerate us?

And I think we have some kind of internal product prototypes and things that we're excited about, and so we're excited to share more about this in the coming, you know, uh, months to quarters as we get it to a place where like other people could maybe get value out of this as well.

Uh, but that's kind of our, our real focus right now is like how do you take these really cool capabilities that are out there that our models have, et cetera, and like make sure that they're actually useful today for us, like when we're doing real work and then for other people as well.

In particular, focused on kind of generating code, understanding code, testing code, verifying it, like starting with the like robust, you know, creation of software.

Host1:27:27

Excellent. Uh, Jonathan?

Jon Frankle1:27:29

I mean, you know, I, I never like to talk too much about the future 'cause, you know, I don't know, I think you've heard this from me before. I, I like-

Host1:27:36

Yes

Jon Frankle1:27:36

... for us to speak through our work, and so I don't-

Host1:27:38

Yep

Jon Frankle1:27:38

... you know, I don't like to tease too much. But, you know, I think we're, you know... What's the right way of putting it? I mean, you know, our mission is, I think to Josh's point, to make this stuff useful to 12,000 customers.

And, you know, not a lot of that ends up making it into the public eye, and not a lot of that ends up getting released open source. So for this kind of forum where really I, you know... where we're talking to the community, you know, I'm asking myself right now like, you know, what exciting things are we gonna have to offer the community in the next little while?

I think the most exciting part is just we're writing a lot of blog posts right now. We're trying to share more and more of our science, 'cause I feel like we've been doing these big pushes to create these really giant models.

I think, Josh, I'm sure you had the same experience. It's exhausting and all-consuming, and you get to the end and you're like, "Oh, I have all this stuff I want to talk about. Now I need to find the time to talk about it-

Josh Albrecht1:28:28

Mm-hmm

Jon Frankle1:28:28

... now that I've survived this huge push." And we're definitely in that mode right now. Um, so there's gonna be a lot of that coming in in the next little while. Um, and you know, we're always cooking up fun new models.

I think the real question is, you know, releasing models open source is not our day-to-day bread and butter. It's kind of a fun reward that we get to do sometimes when we have something really cool to share and a little bit of time and spare GPUs in our hands.

But for the most part, everything is going toward customers. You know, Databricks is... You know, I, I think the joke is Databricks has been 18 months away from IPO for five years, but, you know. So I guess Databricks is 18 months away from IPO still.

But 18 months away from IPO means there's a lot of pressure to deliver for customers, and we're gonna keep working on that. But I think you'll see hopefully some cool interesting things get dropped over the course of the summer and into the fall.

Um, you know, we'll, we'll, we'll find out when we get there. I think that's the right way to put it. I know we were talking earlier about kind of Abra, Kadabra, and Alakazam and, you know. All I'll say is that, you know, the DBRX small model that we, we still haven't released yet was called Abra.

Um, DBRX was called Kadabra and, you know, there's a third Pokémon in that evolution, and that's all I'll say for now. Um, cool stuff kind of popping up sometimes on chatbot arena and, you know, keep your eyes out.

Host1:29:42

Yep, yep. Uh, I'll, I'll leave the, uh, the lints, the links and the hints in the show notes. Uh, but it was, that was a very, uh, way, fun way to leave some breadcrumbs for people to, to follow.

Um, cool. Uh, you know, I, I'll, I'll leave, uh, everything to sort of some calls to action. Um, we're gonna be releasing this next week, um, so that will be deep in, uh, my conference, the AI Engineer World's Fair.

So, uh, people can just go to ai.engineer and li- and, uh, live stream it. Uh, do you guys have any other calls to action before we wrap?

Josh Albrecht1:30:11

The only one is, you know, we're definitely hiring, so if you're interested in working on coding, reasoning, interested in working on all of this stuff, you know, from the ground up and really deeply understanding not just how does the hardware work, but how do the models work, uh, and, and also designing these, you know, systems to actually be useful for yourself day to day, like come say hi.

Jon Frankle1:30:29

I think the only thing I'll say is, you know, and I like saying it these days, it feels like the field is so crowded and, you know, it requires so many resources to do impactful work and, you know, almost...

On some days it feels like everything's been done or somebody else is doing everything before you can. At least I remember that feeling every single day of my PhD, um, and even more so now. But I hope, like what you heard from Josh today tells you there is so much enormously impactful work to do in the field if only you take a step back and take a fresh look at some of these things and just talk about what you're doing.

Um, there's a huge amount left to do here and a huge amount of exciting work happening every day and, you know. For those who are certainly feeling that exhaustion right now, and I count myself among those folks many days, um, it's refreshing to see these kinds of drops and, you know, see that there is so much more even in things that people feel like they understand.

How to set up a cluster, my God. Um, you know, even in these evals that we think we understand, there is still more to understand and still more work to do. And so, you know, just I hope everybody's keeping at it.

Host1:31:35

All right. Keep on keeping on. Well, thanks so much for your time, you guys. Uh, that was great discussion and, um, we'll put the links in the show notes for people to read more. Um, thanks.

Josh Albrecht1:31:44

Thanks much. This was great.

Jon Frankle1:31:45

Awesome. Thank you so much.

Josh Albrecht1:31:45

Thanks, Jonathan.