Slides for this post-training talk and slides for the full tutorial on language modeling (with a bit less post-training content and no recording yet). Here are some timestamps for the video: 00:00 Introduction 10:00 Prompts & Skill Selection 14:19 Instruction Finetuning 21:45 Preference Finetuning 36:17 Reinforcement Finetuning 45:28 Open Questions 52:02 Wrap Up Psssst… we just recently released our technical report for OLMo 2 - 2 OLMo 2 Furious, check it out for tons of training details and tips! This post has some good content, but if you just want to watch the tutorial on YouTube, it’s here. I’m far more optimistic about the state of open recipes for and knowledge of post-training starting 2025 than I was starting 2024. Last year one of my first posts was how open post-training won’t match the likes of GPT-4. This is still the case, but now we at least understand the scope of things we will be working with better. It’s a good time to record an overview of what post-training looks like today. I gave a version of this tutorial talk for the first time in 2023 (at ICML), which felt like a review of the InstructGPT paper not based on reproduced literature knowledge. In 2024, the scientific community made substantial progress in actually training these models and expanding the frontier of knowledge. Doing one of these talks every year feels like a good way to keep tabs on the state of play (whereas last year, I just had a bunch of links to add to the conversation on where to start). With the talk, I wanted to add more context on where I see post-training generally. The most important one people need to know, given the excitement around OpenAI’s o1 series of models, is that post-training alone is nowhere near a complete enough lens or taxonomy to study training reasoning language models. It’s a step. Back to processes for all modern AI models. There are a lot of post-training methods to improve models and, more importantly, they can be segmented so the scientific community can make progress on each of them individually. The new state of finetuning stages is satisfying, with three groups of training methods: * Instruction finetuning (a.k.a. supervised finetuning), * Preference finetuning (the generalization of reinforcement learning from human feedback), and * Reinforcement finetuning is the new abstraction for improving performance on specific tasks. Some of the long-tail methods like rejection sampling, knowledge distillation, and extensive filtering aren’t studied well, but you can still do excellent post-training without them. We have options for studying post-training in 2025. Where last year we were settling debates such as “DPO vs. PPO” or “does AI feedback for RLHF work,” now we are focused on just making the best practices better. Similarly, the stress around doing research on outputs from foundation model providers, i.e. if research violates the OpenAI terms of service on training competitor models, has dropped further and is common practice - in fact, distilling from strong models is a fundamental part of successful post-training. Interconnects is a reader-supported publication. Consider becoming a subscriber. To summarize the state of post-training, there are a few things to keep in mind: 1. Post-training techniques are more impactful on the final performance of models Some caveats before I toot the horn of post-training as all you need today. Given that “scaling as we know it is ending” this is not entirely a controversial take. Finally, it is obviously self-serving to myself as someone who is going to benefit from post-training being more important. All of this aside, it’s very logical that post-training will be the next domain for scaling model compute and performance. Predicting the next token accurately is not something that a user cares about - correct answers and how the answer is presented are. All through 2024, there were way more discussions on how post-training is more important. If we look at the Elo ratings of models on ChatBotArena, we can see progress has accelerated even though the models haven’t been getting noticeably bigger. Pretraining on these architectures is improving, yes, but the biggest and best models are used as tools and supervision for better post-training. Post-training got more popular because there was more low-hanging fruit on model performance. A lot of that potential has been realized and, in doing so, entirely new types of models are being made akin to o1. To interpret these numbers: * 100 Elo margin over another means ~2/3 win probability over the lower, * 200 Elo gives ~76% win probability, * 300 Elo gives ~85% win probability, and so on. You can play with these numbers here. 2. Post-training can be very expensive While still far cheaper than pretraining due to the price of GPUs, post-training costs have been growing rapidly. If we estimate the costs of post-training the Llama models, we could guess that the all-in costs for the models were about the following: Note - numbers are based primarily on a combination of headcount and data costs with compute driving them even higher. * LLaMA (Q1 2023) <<$1M: instruction tuning only. * Llama 2 (Q3 2023) ~$10-20M: 1.4M preference pairs, RLHF, IFT, Safety, etc. and other costs not in the paper. * Llama 3.1 (Q3 2024) >$50M: similar preference data to Llama 2, a ~200-person post-training team, larger models, etc. The number could be much higher. Post-training costs from large data bills and extensive inference to generate, clean, and verify multiple types of synthetic training data. More complex loss functions, e.g. RL optimizers, use a lot of memory to train, but far fewer FLOPs than pretraining for general Instruct models. This is all growing rapidly and is expected to change. This culminates in the o1 style models where the compute with post-training loss functions can account for 40% or more of the overall compute of the model. Even Tülu 3, our major post-training project at Ai2 that didn’t buy any human data, I estimate costs >$1M for a large academic project. 3. Post-training is less reliant on human data While all the frontier laboratories still rely on human data for parts of their post-training pipeline (including both training and evaluation), AI can be substituted at most stages and get a “good enough” outcome. For example, given the costs above, they can be slashed from moving from human preference data that is ~$5-20 per preference point to AI feedback that is <0.01$ per sample. The optionality of synthetic data driven by having models that are good enough for supervision makes the pace of post-training progress far higher. In my experience, AI feedback for RLHF only became possible with GPT-4 tier models and the academic community reaps extreme benefits from the plummeting cost of inference. 4. Post-training ability is the door to advanced reasoning models Doing post-training well and having mastery of the techniques seems crucial to making progress on reasoning models like o1 due to the infrastructure for RL finetuning of an instruct model is the same as what is used for large-scale RL training, at least you want it to be. Given the above trends - we know more, it is easier to study, we have cheaper alternatives, etc. - there is cause for optimism in open replications of o1. It should still be expected that the first “replications” of o1 are more relative models - scaled up post-training on reasoning rather than the special pretraining + scaled RL that OpenAI does. We will learn a lot soon. The talk on YouTube Slides for this post-training talk and slides for the full tutorial on language modeling (with a bit less post-training content and no recording yet). Here are some timestamps for the video: * 00:00 Introduction * 10:00 Prompts & Skill Selection * 14:19 Instruction Finetuning * 21:45 Preference Finetuning * 36:17 Reinforcement Finetuning * 45:28 Open Questions * 52:02 Wrap Up This is a public episode. If you'd like to discuss this with other subscribers or get access to bonus episodes, visit www.interconnects.ai/subscribe
Audio and video play straight from the show's own hosting. PodSubs stores and serves no media.
Transcript
From the show. Tap a time to play from there.
So I gave this presentation as part of a language modeling tutorial at NeurIPS. I said that I was going to rerecord this and I've added some things in to kind of
SPEAKER_00flesh out how you should think of pose training, more results, and I'm excited to get into this. This will be kind of long. There should be chapters in the show notes so you can see kind of which section you might want to do it in parts. But this is the state of pose training going into 2025. Post-training has kind of grown out of this reinforced learning from human feedback area I was in and is now a whole bigger thing. This doesn't really cover 01 and reasoning models, but I'll get to that soon.
SPEAKER_00So what is post-training? At AI2 we call it language model adaptation and really it's the process of taking a raw base model and making it useful for things you care about. I think the word alignment really makes sense in this where you're aligning the model to be useful on specific tasks that you care about. you really should check out base models to understand what post training is doing to them. So post training is making these next token predictors a very
different thing with specific structure and getting into just much better performance on tasks we care about.
SPEAKER_00So we care about following language instructions, probably safety of certain types of queries and all of that. So going into 2025, I would say for 2024, we actually knew a lot more about pose training than we did in 2023, but also the pose training that we're trying to imitate is just far more complicated. I think we'll see how early models mostly just use instruction tuning. And now there's a whole suite of techniques that are needed to do quote unquote state-of-the-art frontier model pose training.
SPEAKER_00At the same time, we have a lot better documentation and understanding for what the tools we can use are to do post-training, but the details that OpenAI, Anthropic, Google are using to make these models really good on tasks they care about, we don't have. Most of this comes down to data, internal evals, and just a lot of small things that add up to the final product. So the same thing when I made this tutorial for NeurIPS. This might change soon in 2025.
There was no open data recipes for post training in the top 60 of the LMSYS chatbot arena.
SPEAKER_00An interesting fact is that there's also like, I think there's like 70 models that have beaten GPT-4 on chatbot arena. So it's about that there are no models better than GPT-4, which we got in 2023, that have open post-training data. So post-training has become incredibly important, but we don't have a lot of resources for doing so. And we're really excited to hopefully change this with Ulmo and Tulu models in their arena right now. They're there and the ranking should hopefully be far better than the top 60.
Post-training, as we know it, really started with this kind of three-phase approach.
SPEAKER_00These works, this is a photo from InstructGPT, came out before ChatGPT and then post-training through RLHF really became popular with this kind of quote from the OpenAI ChatGPT blog post. They've said explicitly, we train this model using reinforced learning from human feedback, using the same methods as InstructGPT, but with slight differences in the data collection setup. This is something we see time and time again. And this was the basis for learning about post-training, was trying to understand RLHF.
SPEAKER_00If we go back, these ideas that they were using on trying to learn the reward of an environment through feedback signals, whether scalars or binary, goes back to decision-making research and deep RL. The kind of popular paper was Cristiano et al., which was deep reinforcement learning from human preferences, where they took different trajectories of agent behavior to learn a preference model and then optimize for control. These techniques quickly were brought into the language modeling space. There's some important papers there. I have more talks on my YouTube that talk about the history of RLHF.
But the first example was really like learning to summarize with human feedback in 2020,
SPEAKER_00the same three-stage approach, which is collect human feedback, train a reward model, train a policy with PPO. This is a very RLHF-centric view of what post-training is. An example would be like, you have some question, it could be a Reddit question, which is like, you have to summarize this long post asking a question on whether or not I should do a PhD in computer science. A vanilla language model will kind of just garble out an answer. It will be very informative and direct. And we can get a human to actually annotate what it should look like and collect
SPEAKER_00preferences on this. And the language model, this work at the time was an actual example from... 2020 in this paper and the answer is much more coherent it kind of has a style of writing that we like and this is some of the foundations for post training today if we take that three-stage approach and make it into a flow chart what we'll see is something like this where you have a base model we have to do a certain amount of human instructions to make an sft model and then you make a reward model and you do rl on top of this
SPEAKER_00This is fairly standard and we kind of, we go from here. And this three-stage approach kind of has instruction to in base model, color preferences, I've said this. And the focus of this was really on to make general chat capabilities rather than what we're doing now where we have a lot of different capabilities that we care about. And if we look at current PROS training techniques, which really got us towards O1, O1 and reasoning models are a totally different thing, and I'll say this multiple times.
We're trying to address many different capabilities at once from evaluations, and we're leveraging synthetic data on a much bigger level than we were before. That first diagram I had showed about 10,000 examples for instructions and 100,000
SPEAKER_00for preferences. And I'll talk about data budgets for post-training now, and it's way bigger. So we're talking about millions of data points at each stage of training, and we're targeting a lot of different goals. What this looks like, here's an example from the Lama 3 paper where they have prompts that they care about and they collect a lot of generations for each prompt. And then they use those generations to do training, that's rejection sampling. They also train reward models with this off of human preferences with these prompts and they use DPO and they use this multiple times.
SPEAKER_00Since this Lama 3 paper, they've released Lama 3.3, which is actually a different post-training technique to this with more online RL rather than DPO. But you get the point, it's a complicated system for doing this training. The NVIDIA paper for Nemetron 4 340B was actually quite similar. They show this iterative loop where you're using synthetic data multiple times, you're collecting new data, you're collecting new preference data, and you just keep kind of incrementally making the post-training model better through a much more iterative process than the original recipes.
SPEAKER_00We attempted this for the TULU3 paper. I'll talk about TULU a lot in this talk. Essentially with TULU, we did bring in more loss functions. So we'll talk about three different types of methods you can use for post training in this tutorial. And we tried to do this, but we didn't have the data budget and the kind of just keep iterating out performance over time that these big labs have by really scaling up the amount of people on their project. So if we compare this to the system diagram that we showed before,
SPEAKER_00we kind of have this three-stage approach at the top. And at the bottom, there's this multi-stage approach with far more data, far more pieces that are interconnected while you use previous iterations of your model in order to generate data that can push the next generation of your model to be even better. It's a very complicated picture and it has a lot of moving parts compared to what used to be just like instruction tuning. This kind of leads us to a really nice abstraction for how we can think about this. I think previously post-training was equivalent to our LHF.
SPEAKER_00People said these were the same things, but really reinforced learning from human feedback is about point number two, preference fine tuning. And there's three types of methods that we can use to train our models. The base of all of this is supervised fine tuning. We still get most of our performance there. On normal chat models, it teaches the template of question answering. But then we go into this preference tuning. It's where chattiness is really boosted through this kind of comparison of two responses. And then finally, we're starting a new area, which does synergize with O1 and reasoning models,
SPEAKER_00which is reinforcement fine tuning, which is a final stage where you can boost performance on evaluations that you really care about. You don't need to use all of these different methods, but the standard workflow will use all of these to kind of push out the Pareto frontier on a lot of different things you care about. This talk, I'll include a lot of examples from Tulu3. Tulu3 is a recent open post-training recipe where we trained models on LLAMA and then we trained them on our ULMO models a few weeks later, which is really to encompass what performance you can get out
of these techniques
SPEAKER_00that we're talking about. This is a substantial project where we do all these things, instruction tuning, preference tuning, blah, blah, blah. But it's good to have a grounded example where we can show you numbers of performance with really updated tools in post-training relative some techniques from a year or longer ago. So generally, I'm going to talk about all these things, kind of the background and setup. Good post training always starts with kind of selecting skills and prompts. You have to kind of take the lay of the land before you actually do anything.
And then we'll kind of go through each of the training stages for instruction tuning,
SPEAKER_00preference tuning, RL tuning, and then kind of open questions in post training. This is probably one of the most important slides, which is to do post training well, you really need to know what your goals are and you need to have ways to measure performance. You measure performance with evaluations for targeted skills. And normally you're only going to be able to improve performance on skills that you care about if you have prompts that are representative to what users will ask you on said skills. Prompts are not easy to get for open projects, I think.
SPEAKER_00ChatGPT has the most prompts out of anyone. They have the most user data informing their post training. But for academics, data is scarce and extremely valuable. If you want to do important work, you have to make sure you have data to actually hill climb on with it. And also for evaluation, I kind of think of it in two ways, where you're going to either have specialized models like math or code models that are popular. There's LamaCode, there's QuenCoder and things like this, where you just have a few capabilities that you care about. It might just be code, it might be math, it might be math and code.
SPEAKER_00Whereas you have these very general instruct models, which are good at chat, they're good at instruction following, information processing, code, blah, blah, blah. And you can see our evaluation suite for Tulu3, which is very much one of these general instruct models. And I'll talk more about this later on, but being really clear about the goals and how many evaluations that you have kind of determines the difficulty for the process you're going to get into. If you're really trying to make sure you're not overfitting, you can hold some evals from the skills you care about to be unseen until the end
SPEAKER_00of your training process to test generalization. As an example of a prompt budget that you can have, you really end up wanting to balance the prompts, which is a proxy for how much training you're doing across the different stages of training. This makes a lot of sense. If you start with supervised fine tuning and do things after that, you're going to need to have similar, sometimes even the same prompts in preference tuning or overlapping ones to kind of control the loss function and make sure training goes well. Well, we'll talk about the end with this reinforcement fine tuning
and OpenAI announced the RFT API is that you need way fewer prompts because the model would be trained
SPEAKER_00on multiple times for each prompt. Still, you'll see a lot of variation in these numbers. I think for open instruction data sets, you can easily see a 5 million, 10 million, or I think like OpenMap from NVIDIA is like 15 million instructions for one domain. And then there's also... like historically was watch smaller preference datasets in open research where ultra feedback was state-of-the-art and it was like about 60,000 prompts. So scaling preferences is an important topic, but kind of like most things in deep learning, if you have more quality data,
SPEAKER_00you can keep going from here, but it's good to have a ballpark for how many prompts you might need. An interesting thing is actually doing research on how to generate more prompts. For Tulu3, we didn't have a lot of math prompts that were improving performance. So we use this technique called Persona Hub, which you prompt a language model to come up with a question to be similar to what a certain person would ask for. So a moving driver will probably ask math questions about box
counts or an
SPEAKER_00astronaut about space dynamics. and this type of prompt can actually really work you you really just need ways to get prompts that are interesting but in this domain that you want what this looks like an example is like as simple as asking ChatGPT to create, it says, create a verifiable instruction that the following persona might ask you to do, and then you would input firefighter. And then there's, in this example, is an example of a verification would be start every sentence
with the letter A. And what you do is you ask a strongish language model to create a prompt. And this kind of thing can work and is often a technique that people don't turn to
SPEAKER_00as much when they're really searching for user data. There are other ways to kind of expand the distribution of a few high quality prompt ideas that you have. Kind of with these prompts, we're gonna go through the three different training techniques. First is supervised fine tuning. Instruction tuning is the core of post-training. When ChatGPT first came out, that's all that people were doing was instruction tuning on various synthetic data. And what instruction tuning is doing is adapting the base model
to be able to input
SPEAKER_00the style that you care about. Most of this is done through the combination of chat templates and then some question examples. you'll see that most of the performance in post-training on our vowels come from the stage because the raw base model just hasn't been formatted to do instructions yet. So you can really extract a lot of performance by just doing this initial formatting and kind of controlling of generation. A system prompt is these kind of special tokens like the bracket system, bracket end,
SPEAKER_00where it just kind of controls how information is passed into the model. And you can kind of separate the question from the answer when you are training so that the model knows that it's generating an answer after an explicit end of question token. The kind of classic example for instruction tuning is things like Stack Exchange and Reddit, where the post is a question and then the answer is the completion that you would want the waddle to be able to generate on its own. Here's an example of what makes a transformer. Transformer asking about AI architectures.
This is the type of thing that very likely may have been used to train some of the
SPEAKER_00early language models. You can see this was posted two years ago when I took the screenshot, so this is probably the type of thing that makes important training data. And what early models did is they kind of, as I mentioned with the synthetic prompts, is that you create new synthetic data, both on prompts and completions. So what is done now is that the strongest language models for LLAMA is LLAMA405B. For OpenAI, it might be their secret Orion model that we haven't gotten to use, which could be GPT-5.
And you make completions to this prompt that are very high quality responses to an answer.
SPEAKER_00And you can generate these way faster than if you were using humans. Generally, humans are only used for areas that the language models don't yet solve. But as academics, we have access to very strong models like OpenAI and Cloud that can solve basic math problems very robustly, especially if you give them a few tries. So it's just much easier to iterate with generating completions for instruction data from language models. And all of the first kind of open post-training recipes did use
this kind of
SPEAKER_00synthetic instruction and synthetic completion pipeline, where it's like Alpaca, Vicuna, DALI, et cetera. Like this was the first major establishment of open post-training recipes was using synthetic instruction data. DALI used human data, but kind of at the time, it's this idea of just expanding your instructions and fine-tuning existing model weights to be chattier. The actual design process with supervised fine tuning is interesting because as you get new data, you kind of need to retest your hypotheses over time on what
makes a good data set. So you have some people that are working on sourcing high quality data or making instructions from synthetic data sources and other people that are just down
SPEAKER_00sampling them, filtering and combining these together in order to make a final data set that performs well across your suite of benchmarks. And it takes a lot of effort to remove data that is probably limiting performance, as with anything. And generally, While it sounds like this is a very complicated process, you often can take some datasets off hugging face, do some sort of careful mixing and minimal filtering,
and get state-of-the-art performance in many kind of academic evaluations that you
SPEAKER_00care about. This is just because base models are getting better so fast and their kind of underlying capability is so high. Still, most people at this point aren't interested in only doing SFT. I think SFT research is important and will continue. It's just kind of repetitive. You find prompts, you generate really high-quality completions, and you see how these different subsets of the dataset interact with each other. There can definitely be surprises where two subsets that you thought would work really well together, because they work individually, don't mix well because they use slightly different formats for
how they communicate,
SPEAKER_00and that signals hard to train the model on. This is kind of like a reiteration of how important synthetic data is, but when you're building SFT data, the quality of the completion is the most useful part. It's not surprising. This is what the model is learning to imitate when you use this next token prediction loss function. And human data is not as needed as it used to be. And even filtering where it's going to help you if you do it well, If you have some noise in the system because there are multiple
training processes downstream,
SPEAKER_00you could actually get more. You don't necessarily have to remove all the bad instances. It's okay to have some noise and supervise fine-tuning. When you're actually doing the instruction tuning training, be careful with implementation. Just a few months ago at the end of 2024, there was a lot of discussion on how there was a bug with gradient accumulation in Hugging Face, which essentially messed with how the samples in a batch for instruction tuning were getting passed through the gradients.
SPEAKER_00Here's a blog post on Onslaught you can read about this, but we had found the same thing at AI2 that you just have to be careful with a lot of things like this that can still be broken in the open ecosystem. Here's an example of how much performance you can gain by getting a better SFT stat. Here you can see Tulu2 and Tulu3 trained at both 8B and 70B, where these are our two iterations on the SFT mix. Tulu2 as a mix was made in the fall of 2023,
SPEAKER_00and then Tulu3 was our recent work in the fall of 2024, where we're kind of remixing and creating new synthetic data based on these open... open resources and the gap between TULU2 mix and TULU3 mix on the same base model is extraordinary. So it's like nine to 10 points across our evaluation suite just from improving SFT. That type of performance is way bigger than anything else we'll see after with preference tuning or RL. And also we can compare it to some other open data sets such as RLHF flow and
SPEAKER_00Mammoth2 where we do see that our TULU2 mix, TULU3 mix does outperform these and there's a large variance. It goes to show this variance means there are still a ton of performance gains to be had. I know there's other community projects working on improving fine-tuning data, and I think this is a great place to look, which is supervised fine-tuning as a loss function is so simple, but there's just so much more for us to hill climb on it while there are fancier things that we'll get into. So this is the kind of next thing is like, while there are definitely
lot of like there's a lot of exciting things after instruction tuning but if you're focused on performance you should still be spending a large proportion of your time on instruction tuning and then we move into these other stages which i think are seen as flashier in the community because they're just so much newer and the best practices are even less established this will kind of be a trend as we go through
SPEAKER_00which is as I discuss these things, there's more and more uncertainty over how you should do these and therefore also probably more potential to find performance. What is preference fine tuning? So preference fine tuning is a word that I use to encompass RLHF and its related methods. And it's really known for training a large influence on style and chat. A lot of people became down on preference tuning and RLHF because they thought that
this chattiness was making the models dumber through things like Chatbot Arena. Chatbot Arena has now added controls for style where it actually tries to get just the informativeness and the kind of correctness out of the evaluation because
SPEAKER_00people have pushed the limits of style so much with preference tuning. But in reality, how information is presented is really important to how it is absorbed by a user. So preference tuning is crucial to doing post-training really well. And for things like math or coding where it's a quote unquote like specific ability, preference tuning does continue to improve performance. I would kind of say as we learn to do this, I kind of conclude the whole talk with some areas we don't know what to do is we're just going to, there's so much to improve here.
And these kind of basic things of community kind of having a reaction to this whole
SPEAKER_00area is just early growing pains of learning how to do this. All of this is based on the idea that we're collecting preference data either from a human or from an AI. So here's this example from the early anthropic RLHF work where a kind of human is discussing with an assistant and then the annotator's job is to label between A and B, which is these two responses to the same question of which one they like better. The chosen one is then for use as the positive training signal
in contrast to the rejected. And with this data, we go to this Reinforced Learning from Human Feedback objective. If you're from a Reinforced Learning background, this will look very familiar to you.
SPEAKER_00If not, please pause, stare at it. You can go get a book of Sutton and Bartow, which is the classic RL textbook. And what you're doing is you're trying to maximize the reward in expectation for a specific policy pie. And in our LHF, because we are fine-tuning, we don't want the model weights to drift too far from their initial values. So we add this KL distance constraint on the probabilities of the model. What does it see? You can see this first half on the left of my screen is this
kind of reward
SPEAKER_00inspired by human preferences. We'll get on what r phi is, which is a learned model of reward, but we want to constrain the model so that it doesn't overexploit the reward. Lots of these kind of single words like over-optimizing the reward are whole areas of study in post-training now, but I'm not going into all of them today. Two questions, how do we implement this reward, R, and then how do we actually optimize it to make the model better? So preference modeling is
SPEAKER_00It was very core to early RLHF progress and everyone knew that. I think it went through a phase in the end of 2022 and 2023 with the methods we'll talk about where it was much less studied. Generally, a preference model is giving a reward, which is a scalar value where we want a higher scalar value proportional to how good a response is. And how we do this with the pairwise preferences that I started this RLHF preference tuning section on is we train a model to predict the
likelihood that a
SPEAKER_00chosen completion, the one that they liked between the two, is better than a rejected. And this is built on a Bradley Terry model, which kind of estimates the probability that a pairwise preference is the true preference. And what we can do at inference time is pass in any piece of text to the reward model, and it'll return a number where that number is the probability that that piece of text is quote unquote good. It's a bit of a weird setup, but the important part is that we can get a scalar notion of how good the text is
SPEAKER_00from this model we trained. And with this, we could then do the whole RL magic and RL number goes up on this preference model is what the basis of RLHF is. You maximize the reward. I mean, you have the same thing here. You maximize this and the downstream language model is better. There's a lot swept into this that I don't go into here with how to implement RL, what these functions look like, what these learning curves look like, etc. But the magic of it is that if you have a good preference model
and you make the RL
SPEAKER_00number go up, you get a better model out. This is not always that easy, which is why people ask the question of what if we just use gradient ascent, we make the reward go up with taking gradient steps on this loss function. This is what direct preference optimization is, is kind of a more direct way to solve this preference fine tuning optimization. This was released in May. It's a wonderful paper. Definitely recommend you watch it or some of my other talks on the matter. But this is kind of an answer to make RLHF more accessible.
SPEAKER_00DPO is extremely simple to implement. Here on the right, you can kind of see the few lines of code that are needed to actually implement the loss function. If you have a chosen and rejected sample, you compute the log probabilities of those from the model, i.e. how likely the model thinks those certain tokens are. And then you do a basic combination of them with the sigmoid, and you get the loss to update the model. Because it is so simple, it scales nicely with existing distributed training libraries.
It actually trains an implicit reward function to solve the RLHF loss function.
SPEAKER_00And this makes it much easier to iterate on. You could see the Lama 3 paper talks about DPO. This Tulu 3 paper, we also talked about DPO extensively because it's easier to iterate on and kind of scale a multi-person team to use a simpler training library to run a lot of data ablations across your model. This gave us a proliferation of models that I'll talk about for a little bit because it was faster to implement. It gave everyone out there the ability to do preference fine tuning on their own,
SPEAKER_00which was very new. I think there was six months or more where people are trying to do PPO and there was almost no preference tuning, which was when we had those instruction models that we're talking about. And this still continues today. DPO is popular as I was saying with LLAMA, but kind of, As people look to more performance, these online RL methods are coming back as a way to get more performance out of it. Some of the first DPO models you should know about were like Zephyr Beta. And the fun story I like to tell about this was that we've been
trying DPO for a while,
SPEAKER_00but we just didn't really know the right loss function. So we learned that you generally need to use really low loss functions for DPO after instruction tuning in order to get the kind of state-of-the-art performance people are now used to. Another example was a Tulu 2 rather than Tulu 3, which was in 2023, which is that DPO scales. And these early DPO results were all built on one dataset, Ultra Feedback, in the open community, which I'll go on to talk about soon, which is just like,
SPEAKER_00There's a very narrow path to things taking off in post-training, especially in academic circles, that requires the useful code that actually runs, so DPO is easy to implement, the right dataset for the method, and then just enough people throwing computer at the problem to find the right hyperparameters for that combination of data and base model and code. kind of leads into the next question which is after this dpo takeoff came the phase of debates on whether or not dpo is the thing that we should be
spending our time
SPEAKER_00on because dpo kind of dpo direct performance optimization is so simple to implement but this really popular rl algorithm ppo proximal policy optimization is much more complicated but ppo is the rl kind of de facto implementation for rlhf so the question is if you do all the work to implement the rl side how much can you gain relative to the simple dpo approach which is a clever way of solving the same problem
SPEAKER_00And the RL stuff ends up winning out just by a little bit. You can look at this table where we do DPO versus PPO, both with their own hyperparameter tuning on a variety of common datasets. And it really seems like PPO and RL can really outperform the direct preference optimization if you have the time to spend on the engineering and finding the right way to steer your data at it with the right SFT config. This is how it is.
It's not necessarily worth the time for everyone to do this training, but so be it.
SPEAKER_00Also, there's the kind of question of, Do we need to use human preferences for labeling these kind of pairs of chosen and rejected, or can we use language models as a judge? AI feedback, so LLM as a judge, really became popularized or kind of mainstream with Anthropic's constitutional AI paper. The thing that people kind of don't realize with constitutional AI, which is that Constitutional AI and AI feedback is used to kind of further fine-tune a language
model that also has human feedback built into it or based on data that started with
SPEAKER_00human feedback. So this kind of human preferences and human data is very important because it is the foundation of a lot of post-training. LAMA 3 still used it extensively. Scales business is doing fine, so obviously more people are still using human feedback data. But LM as a judge is also extremely useful. So human data is super expensive. I think LM as a judge costs less than a cent to do a preference comparison on an instruction, whereas one human preference data point can cost $5 to $20.
SPEAKER_00So we kind of see these, they're on very different sides of the spectrum, but both are very useful. I think what we're trying to do as academics is approximate the human preference data with AI, but we don't really know the nuance of human preferences because there's a lot of instructions that go into guiding humans and data filtering that places like scale AI do. So ultimately you can get this reduced to a talking point where human preference data is high noise but low bias and synthetic preference data
from AI is low noise
SPEAKER_00and high bias. We don't really know what these biases are but I suspect especially in 2025 and as this field goes on we will start to learn these more. I mentioned this ultra feedback method as the data set that kind of unlocked performance of dpo for the zephyr and tulu2 models and the key aspects of it really are diversity so excuse me so ultra feedback takes a bunch of models to generate completions from and it takes a bunch of prompts from
other popular data sets to label data on so it's really general where there's a lot of different chosen and rejected models there's a lot of different instructions and then it also
SPEAKER_00generates fine gained feedback to kind of make sure the feedback is on something that the user will care about when doing this AI feedback. This works extremely well for a lot of different base models. Generally I think because there's some learning signal for every SFT dataset that you put in because they're very likely to be in the model pool that you started with. What we've kind of found by building on Ultrafeedback is that you can continue to get more performance in preference tuning just by including more prompts.
SPEAKER_00So I think in 2Loot3, we took a lot of our prompts from the project called WildChat, which is trying to get permissive queries to something like ChatGPT. Essentially, WildChat paid users or gave users free ChatGPT Plus in exchange for their data, which is just a much fairer way to do it than some of the other sources that were scraped to get human data in the first place. By using things like WildChat and the Ultrafeedback pipeline, for two to three we made much bigger preference datasets, which were a really easy way to improve average performance. You can kind of see the average performance inching up as
datasets get bigger, for our DPO stage and even GSMAK and some of these evaluations we really care about
SPEAKER_00just keep climbing as we scale the preference data. One of the ways that we did this is through on policy preferences. So a lot of the debates between RL and DPO is this idea of online data. On policy data is data where the completion comes from the model checkpoint that you're trying to learn on. If I'm training my own SFT model on LAMA and I want some on policy preferences to do this, I generate from my own SFT model rather than taking completions
from something like
SPEAKER_00GPT-40 and then creating preference data from that. The tokens used by GPT-40 will be really different than the tokens of my SFT model so that having tokens that are just close creates a nice learning signal which makes the final performance higher. It's very logical. If you're going to throw training data at something, you don't want the model to be too surprised about the tokens that it's seeing. It really just wants to be in distribution. And the best way to have in distribution data is to generate it from the model you're training on itself.
SPEAKER_00OK, we're getting to the fun stuff here. Now we're going to talk about RL and advanced tuning. I think a lot of people want to know about 01. Again, I don't talk about 01 specifically, but this type of RL tuning is confirmed as being something that OpenAI uses. I would say that There was a tweet where somebody on the fine tuning team said that the infrastructure for the reinforcement fine tuning API is the same infrastructure they used internally to train 01. This is awesome. And we need to explore this as a frontier in 2025,
but it kind of gets into a border between post training and reasoning that I think
SPEAKER_00is up for debate. So what is RL tuning? Reinforceable tuning is just kind of another objective other than human preferences, where we're kind of training on some reward that's not necessarily from a reward model, but another signal from the environment or from the question that we asked. I think there's a few examples. There's a lot of research on verifiable domains for code, etc. In two to three, we'd use this kind of RL fine-tuning as the final stage for our
general instruct model to improve a bunch of key evaluations where the outcomes are verifiable. And this is why I'm going to talk about reinforcement learning with verifiable rewards, kind of as an idea for one type of reinforcement fine-tuning that you can do. We wrote RLVR as an idea trying to match those kind of four letter frameworks and
SPEAKER_00transition from RLHF to RLVR. And then just a few weeks later, OpenAI released the reinforcement fine tuning RFT API. And RLVR is really a subset of things you can do with reinforcement fine tuning. And I expect this kind of idea to continue where there's a lot of ways to do RL fine tuning depending on your domain. The key of the RL fine tuning that we're going to talk about is the data. So the data format here is that you have two things.
SPEAKER_00You have a prompt and an answer that is verifiable. OpenAI use this example in their RFT post or live stream, which was about biology and sequencing genes. We have an example on hugging phase, which is just for instruction following, which is like, you have to write your entire response should be in English and in all lowercase letters, no capital letters are allowed. Checking that all the letters used as lowercase can be done in a Python code. And generally what you do is you check the answer with a
specific constraint for the prompt and you give a reward if that answer is correct relative to the constraint rather than the kind of chat preference nature that we talked about
SPEAKER_00earlier in preference tuning. So how do we actually implement this? I think if we start with the standard contorted RLHF world, what RLHF looks like, if you've looked at a lot of RL diagrams, this will look familiar, is you have training data, which is prompts, the language model, which is the agent generates a completion for the prompt, and then the reward model gives a scalar reward for that. With the reward from reward model, you do some RL math. In your policy, your agent pi theta gets updated and can do new completions.
SPEAKER_00We kind of feed prompts into the RLHF process, and that's kind of why everything always started with prompts and evals. We need prompts as the fuel to build post training. If we look at the RL details, the agent actually has a few different language models within it. It has a generating policy, which is the weights that are getting updated. It has a reference policy, which is how we do that distance constraint that I talked about. And also has a value model, which is learning the per token attribution to the rewards it
gets in a sequence.
SPEAKER_00So if we wanna add verifiable rewards to this, our first idea for RLVR was let's add it in addition to a reward model and just give the model a bonus if the answer to a problem is correct. We actually found out in building RLVR that the value model that's intrinsic to the agent in this orange bubble is enough to kind of constrain the behavior where we don't need another reward model. And then the ground truth just kind of fine tunes the model very gently to improve performance.
So we kind of can clarify this which is we don't have a reward model and it looks very similar to that first diagram that I showed you but it's only learning from
SPEAKER_00the if the answer is correct in this RL fine-tuning phase. A really crucial part of this and OpenAI emphasize this a lot is answer extraction and what they call greater models. You can see this example on the right for this RL fine tuning where if you do a math problem, there are a lot of ways to represent numbers the same way. And you need to do some answer extraction to make sure that all different representations of the model are rewarded if the answer is actually correct.
SPEAKER_00So as a language model, I might prefer a certain format, but I really care about the answer being right far more. So we start with Python code extractions. OpenAI's RFT API does a nested kind of schema of functions or related things, but the core of it is extracting the answer. This is reward shaping from the classical reinforcement learning literature applied to language model fine-tuning. When we do this kind of RLBR at AI2,
SPEAKER_00like this is what training looks like, which is you look at the KL of the model, which is kind of the distance that the model changed from the reference policy. You look at the kind of RLHF reward, which is the reward from the this kind of process which is checking the batch and then you look at the verifiable rate. In this example these two are the same where the verifiable rate is the RLHF reward but if you have a reward model the cumulative reward can be different and you can
kind of see these learning curves with a classic RL learning curve is time on the x-axis performance on the y-axis and performance should be going up over time.
SPEAKER_00It's very, very low KL distance relative to this kind of preference tuning literature where this RLVR is only moving the model a little bit for the most successful runs. What you can do is, we don't wanna train on test obviously if we're doing this, but if we have our training data for a specific RL domain, we probably have a downstream evaluation that we care about kind of generalizing to. So we did these things on math and GSM 8K. Example like GSM 8K has a training set.
What we can do is we can look at the performance on the training set where here we
SPEAKER_00have the similar things on the right, which is the reward rate, the KL divergence and response length, where the reward rate on our training set is going up and we want to make sure that this translates to the test set. So we can see for here the green and pink are two different initializations for the value model. Or, actually, never mind. There are two different starting points for RLVR, and we can see kind of how these learning curves for GSMAK, math, IFEVAL, all on the training site gain performance, while it's really on GSMAK and math do the generalizations
translate the clearest,
SPEAKER_00and kind of some IFEVAL. You can see our code that we use to do this at OpenInstruct, and As you can see, I kind of get stuck on some of this and describing it is a lot of this is just like, it just works. We haven't done the most rigorous analysis of RLVR. I think in 2025, this kind of RL fine tuning as a research area is going to be extremely fruitful and prominent. There's just a lot of areas for things that we haven't tried. It gets all sorts of followup questions like, why didn't you try this? Why didn't you try that? And it's like, look, we didn't need to yet.
SPEAKER_00And people are gonna make a lot of progress on this in a research domain. One of the fun things that we tried for ULMO 2, by the time I posted this, the paper should be out, and we just did RLVR on different training sets in order to kind of keep improving our final performance. Because this RL fine tuning doesn't really change that much about the model outside of the scope of your training, it kind of worked. We applied it in three different stages. where we can do something like GSM 8K and then IFVAL and then math.
There's a lot of things to play with in RL fine tuning and we don't know what is best.
SPEAKER_00There's also a lot of questions from people who have RL backgrounds, which is like, why is this new relative to classical RL? All of reinforcement learning as a field is having agents learn from feedback on whether or not their behavior is correct. So what we introduced as reinforcement fine-tuning, which is rewarding your language model when the answer is correct, is pretty much identical to that. But the main innovation is that we are applying reinforcement learning in a fine-tuning domain where it has a lot of stability and doesn't
cause degradation to
SPEAKER_00things that are out of distribution. still this rl as fine-tuning paradigm which started with preference tuning in rlhf and is continuing into rft is there a really important aspect of what rl is for now where rl in the kind of alpha go sense was learning from scratch for an agent's behavior but now it's just a really powerful fine-tuning capability that we have to use in post training generally OK, I'm going to kind of get to the end here where I talk about
open questions in post training.
SPEAKER_00Specifically, this is around an academic lens of post training. The first thing that you should always think about is like, what the heck base models should I use? I think among academics, there's actually too much hesitance to use the instruct models that other people have trained. So a lot of academic research starts on like Lama 3 base or Olmo base. And the reason is we're trying to reproduce the entire post-training recipe.
SPEAKER_00Meanwhile, what most people are doing to apply these techniques is that they are taking the Instruct model from LAMA3 Instruct or ULMO Instruct, and they're fine tuning in on one to two tasks to make the performance much better. I think for most people, we should be understanding the limits of taking Instruct models and making them extremely good at one specific task. I think... Full post-training research is still crucial for transparency, but it's really strange that there's something that academics can be doing, which is smaller scale fine-tuning,
SPEAKER_00and a lot of industry and startup people are using, which is fine-tuning from Instruct, but academics don't tend to use this in their benchmarks or comparisons. It's an extension of post-training and it's something we should be doing. And this kind of is like one of the ways we can train our base model. I think what we've seen is that if we apply the same two to three post-training recipe to different base models, we, yes, obviously need to change the hyperparameters, but also like the relative gains per base model will be different,
which is kind of a balance of the underlying performance of the base model and how
SPEAKER_00it is extracted with our data. think we have a lot to learn if you're working the open there's also implementation differences between base models like if you need to use vllm a lot at the time phi3 which is like three billion parameters was slower than quen7b in vllm this bug may have been fixed but it's good to try multiple base models for your use case because there's a lot of variance in terms of implementations and gains when the field is moving so quickly Something else we need to discuss,
SPEAKER_00and I've kind of just blown through this in the whole talk, is whether or not we should be distilling from GPT-4 and LAMA-405b as academics doing post-training research. And if we should be doing everything in a fully open source and reproducible way, The reality is that distilling from these closed models like GPT-40 and Claude is just a powerful shortcut in post-training, and there's almost no progress on creating powerful models without doing this.
Llama internally uses their 405b models to train their 1b, their 3b, and their 8b models. So it's kind of a trade-off of we're losing transparency over time as these big artifacts that are hard to work with or these closed artifacts are really important
SPEAKER_00to post-training. But this is what they're doing in labs to make a lot of progress in post-training is use the absolutely best models for AI feedback and for synthetic construction data. At the same time, there's definitely value for pushing the limits of fully open source models where they're not using any API models. And I think there should be more focus there on the community, which is comparing only among models that use no API models, because that's kind of our basis of knowledge when we're doing this kind of open research.
SPEAKER_00At the same time, this is a good lead into how industrial post training is different than academic progress. I think industrial post trading has things in it that academics will never care about and never really make progress on. Well, never is an extreme stance, but there's just far fewer incentives. I think industry post trading is a lot about user interfaces and kind of blending the model performance with the domain it's working in. They have far more evaluations than academics where they can have almost unit tests on types
of behavior that they
SPEAKER_00care about across a wide variety of queries from past users. And they use this data and kind of really quickly iterate all the time on their models. I think we've seen in the past few months, it seems like OpenAI and Gemini are releasing new models just every couple of weeks and continuing to climb on Chatbot Arena. These chatbot arena climbs of industry are also surely accompanied by internal benchmarks for evaluations they care about internally for further kind of preference testing and things like this. And they're just hill climbing on a different thing where,
SPEAKER_00for example, something that Claude cares a lot about is character. And we have no real open research on how to tune a character, the character of a language model a specific way or how to kind of evaluate that. This kind of leads into more open questions. I think I covered a lot of post-training, but there are still a lot of methods that we just don't have good understanding of. I mentioned rejection sampling in the LAMA section, which is the idea of ranking completions of the reward model before doing SFT. We don't have a clear replication of how to do this with open research.
We tried it in 2 to 3 and just couldn't get good signals, so we tabled it to future work.
SPEAKER_00how to train a good reward model. There's very few good open reward models where people actually can do this kind of preference tuning, RLHF and data filtering and get a lot out of them. I think in 2024, the reward model ecosystem was seeded. I worked on RewardBench. It was the first project on evaluating reward models. And there's since been a lot of discussion where people extend RewardBench to other applications of multilinguality or rag and then there's also a lot of understanding that reward
model evaluation should not only be on accuracy and trying to correlate reward models with kind of final chatbot arena performance but there's still not enough papers on just how do we train a reward model that is useful for our own instruction pipeline which is just like what should you do with the data to create a good reward model is not known enough relative to its importance especially when you ask the peers in
SPEAKER_00industry I mentioned this in the preference tuning section, which is just like, how should you consider human preference data versus LLM as a judge? We are going to continue to pile AI feedback data in open resources on Hugging Face, but we don't know if we really need humans to get a specific thing. It might be that character training that I mentioned or something else like this, but we need to know the answer of what we're missing out on. I mentioned these, they're kind of intertwined.
SPEAKER_00And some conclusions. This is really broad to all of language models, but We need a lot of research. I mentioned a ton of things in post-training, but this post-training is all integrated with the whole language modeling ecosystem. Test time inference, inference scaling are really coming on fast. Post-training is the set of techniques that you need to master in order to scale up these loss functions and make reasoning language models like O1. So we're going... It's good that we have this knowledge of post-training,
but we need to learn how to exploit it to an even greater extent in the near future. There's a lot of details in training language models and doing post-training well.
SPEAKER_002Loot3 was a 20-plus person project for many months. It's a very deep investment to move the frontier on open recipes that people have. There's a GitHub repo with more open source language models recipes that you can look at that I made for the tutorial. This knowledge I'm working on builds on a lot of people at AI2 working on these ULMO work streams. And if you're interested in the types of models you get following these post-training recommendations,
SPEAKER_00you can go to this playground and try them out. Maybe I'll make videos just... talking about what our language models are doing and kind of showcasing them if that interests you. But please let me know if you have more questions on post training. I can make follow up videos as needed. And thanks a lot for your attention. Peace.
The resignation of Nvidia CEO Jensen Huang is a major setback for the US development of an open model ecosystem. Nvidia still has the financial interests in supporting open models, which are to avoid concentration in...
Last week coined the term “Black October“ after an onslaught of critical vulnerability disclosures, including PHP2Shell and a long-standing GitLab bug, signified the moment when the cyber risks of AI models started to...
Hill-climbing is easy, knowing what to hill-climb is hard. Making scores go up is expensive, but we have a much clearer playbook for it than we do for creating meaningful benchmarks at the true frontier of AI today....
We - Nathan and Florian - wanted to discuss all the messy trade-offs of a busy week in AI and ask all the pressing questions like: * Why did Kimi K3.1 Pro have a mixed reaction with such incredible benchmarks? Will it...
This has been a week where the balance of American open-weight models took a step change back toward the frontier. Meta took the lead of this charge with Muse Spark Open, which is now the strongest American-made open...