YouTube transcript (p7TdPUcPoik) — Transcript
Full transcript
- 0:05So lecture three is about verification.
- 0:09In the last lecture when we talked about
- 0:13uh inference time scaling and the
- 0:16generation
- 0:17verification gap. Uh basically what we
- 0:21discussed was that language model seems
- 0:24to be able to um seems to know the
- 0:28answer to many of the hard questions um
- 0:31and especially with methods such as
- 0:33repeated sampling or other scaling test
- 0:35test time techniques. they can generate
- 0:37one but a question is how do they how
- 0:41can we automatically select which answer
- 0:44is correct or guide the model throughout
- 0:47the process of answer generation. So
- 0:49that leads us to verification where
- 0:52which we are learning about today. Um so
- 0:56in today's lecture we are going to learn
- 0:59about the following four paper papers
- 1:02and it kind of there is a progression of
- 1:04like how our uh kind of the way we
- 1:07approach verification changed or
- 1:10progressed throughout the years. Uh so
- 1:13let's first start with training
- 1:15verifiers to solve math for problems.
- 1:18This is a paper uh from OpenAI in 2021
- 1:24and the motivation for this work was
- 1:26that LLM hallucinate and um can
- 1:31confidently present wrong solutions to
- 1:34the users. Uh this still is true to this
- 1:36day. Four years later, of course, the
- 1:38model has have become significantly
- 1:40better. Um there is also at the time one
- 1:45of the contributions of this paper was
- 1:47to introduce a new reasoning benchmark
- 1:50the around math and you can see here in
- 1:52blue one of these uh problems. Um this
- 1:56is um this is a uh this is the type of
- 2:00problem that um at the time it was hard
- 2:03for LLMs to solve and uh this led to
- 2:07this new data set and and and and that
- 2:11that is has become kind of a a a a big
- 2:17part of many of the benchmarking task
- 2:19for LLMs and even to this day this data
- 2:22set is called GSM8K and even to this
- 2:24date um for smaller models and
- 2:27benchmarking it's still a very useful
- 2:30language modeling evaluation and you can
- 2:33consider it for the type of evals that
- 2:36you want to define on your projects as
- 2:38well. So um it basically consists of
- 2:418,500
- 2:43grade school math problems. uh and the
- 2:46goal with was this for this was to have
- 2:48uh the quality and diversity of the
- 2:51problems but also importantly there was
- 2:54a focus on multi-step reasoning meaning
- 2:56that to solve the problems even though
- 2:58the problems were uh simple but the the
- 3:01model required a few steps of reasoning
- 3:04to get to the answer. Um
- 3:07and and you could also collect u the
- 3:11solution in natural language uh as
- 3:14opposed to uh pure math. Um but the
- 3:18other contribution of this paper which I
- 3:21which we're going to spend more time on
- 3:23was to train a verification model where
- 3:26the verifier outputs the probability
- 3:29that a solution is correct. So let's see
- 3:33about how this can be useful. For
- 3:35example, the model jet the when as
- 3:38humans we solve problems, it would be
- 3:41very very good for us to have access to
- 3:43kind of a rubric or a way for us to tell
- 3:46whether we are correct or not. And we
- 3:48kind of want to provide the same thing
- 3:50through this verifier for the language
- 3:53model.
- 3:55So now how these verif the the the
- 3:58verifier was trained in this case is
- 4:00that assume that we have a question and
- 4:02a solution for it. Then we do have a
- 4:06label whether the it's a binary label
- 4:09whether it's correct or incorrect. And
- 4:12during the training process the
- 4:14generator the language model which is in
- 4:16charge of uh answering questions here uh
- 4:20produces SI which is the solution to
- 4:23question QI. Um and then we can generate
- 4:27do repeated sampling and generate
- 4:29multiple in this case 100 solutions per
- 4:31problem. And then we create these labels
- 4:34based on whether they were correct or
- 4:36not. Um remember that these questions
- 4:39and answers were selectively designed by
- 4:42a lot of manual human supervision. So we
- 4:45know what the answers the final answers
- 4:48to these problems are. So we can just
- 4:50based on that create these labels for
- 4:52these problems. Um and then given that
- 4:56we can train a verifier because now we
- 4:58have a we have a question we have a
- 5:01solution and then we have a label for
- 5:03it. Um
- 5:07um now the way we use it at test time is
- 5:10that at test time again we generate a
- 5:12lot of answers and then we use the
- 5:14verifier and look at the score the
- 5:16basically the log probability that is in
- 5:19this model now to see which one has a
- 5:21higher score and use that for as our f
- 5:24and show that as our final answer. Um
- 5:31so in this paper the verifier was
- 5:33trained not just based on the
- 5:35correctness prediction but there was
- 5:37also a language modeling uh objective.
- 5:40So the language modeling objective is
- 5:42also like given uh for example here
- 5:46given these tokens corresponding to the
- 5:48questions. The moment we get to the
- 5:51solution solution token we also add a
- 5:53loss that kind of urges like motivates
- 5:57the model to predict or reduce the the
- 6:00solution um kind of um
- 6:04uh distance from the true labels for
- 6:07that solution. So in this paper they
- 6:09said that it helped them to have two
- 6:11losses. One is the binary loss and the
- 6:14other one was the the normal language
- 6:17modeling uh next prediction token loss.
- 6:20Um and the verifier itself the
- 6:22architecture of the verifier is also a
- 6:24language model. Um but also this
- 6:27language model has a small scalar head
- 6:30that outputs the binary prediction
- 6:34um on a per token basis. So basically on
- 6:39a per token we are saying how close was
- 6:42the solution to the to the true labels
- 6:46uh generated by humans.
- 6:50Um and then the tokens in questions are
- 6:52masked out because we are not optimizing
- 6:55for that. So we generate the question we
- 6:58pass in fill in the model with the
- 7:00questions and we ask it to generate the
- 7:02solutions and we we work with these two
- 7:04losses. Um
- 7:07the way they trained the model was to
- 7:09fine-tune the generator language model
- 7:12for two epochs. Um and then sample a 100
- 7:15completions per question um label it
- 7:20whether they were correct or not and
- 7:22then train a verifier uh for a single
- 7:25epoch on this data set. So first they
- 7:28did fine-tune the language model on a s
- 7:31on that data set on a portion of that
- 7:33data set. Um, and this step maybe
- 7:37it's like debatable whether we we still
- 7:40need this this step or not because
- 7:42language models are already very good at
- 7:44instruction following and understanding
- 7:46math. So maybe and for a lot of newer
- 7:49verifiers we directly go to the training
- 7:51the verifier objective without any
- 7:54supervised fine-tuning first.
- 7:57Um, so they did a number of abilation
- 8:01studies. one was to create this label of
- 8:06correct or incorrect at the sentence
- 8:10level. Um so
- 8:14we have a loss that only concerns at
- 8:16each sentence level for example after
- 8:18each period looks into the previous
- 8:20sentence and looks whether this is a
- 8:22correct step given the steps of the
- 8:27correct step for the for the solution or
- 8:29not. or they could do at a token level.
- 8:32So this is like very a very noisy kind
- 8:35of label like basically we want every
- 8:37token to follow um the the the the
- 8:43pattern that leads to a final correct
- 8:45solution at the end of this generation.
- 8:49Um and then the way this is used at test
- 8:52time is the final solution score is the
- 8:55score after the last token. Because if
- 8:58you have a token label prediction per if
- 9:01you have a label prediction per token at
- 9:04the end of the day we only we want only
- 9:06one prediction for the entire generation
- 9:08whether it's correct or not. And it
- 9:10turns out in this case they looked it
- 9:12after the last token. All right. So we
- 9:14were talking about if you have a token
- 9:16per a label per token at the end of the
- 9:18day we just we want one token yes or no
- 9:22whether this answer was correct or not
- 9:24and um this is done in this case by just
- 9:28looking at the very last token and if
- 9:30that was a correct then it's the entire
- 9:33answer is assumed correct and otherwise
- 9:35uh it's assumed incorrect. So we predict
- 9:38for S1 S2 uh SM we predict these labels
- 9:42and then we only look at the very last
- 9:43label for the to generate and allocate a
- 9:48label for the entire solution.
- 9:50So um here is um looking back at these
- 9:54problems um when we get to the solution
- 9:58we are looking at the token level
- 10:00prediction by the trained verifier and
- 10:02if it's green means the verifier has a
- 10:05high score and the red ones means a low
- 10:08score in this case and in this case this
- 10:11was there were some lower scores in the
- 10:13middle but towards the end it become
- 10:15became greener and greener and this was
- 10:17a correct prediction at the end at the
- 10:20end the last the very last stage is a
- 10:23green one and we assume the actual score
- 10:25and the verifier predictions are um and
- 10:28in in this case are matching. In this
- 10:30other case uh the last verifier is red.
- 10:33Uh it starts off well but it has a there
- 10:36is something that a mistake is made um
- 10:40which I
- 10:42uh
- 10:43uh
- 10:45which is uh towards the the end of this
- 10:48generation step and the actual score is
- 10:51negative and the verifier prediction is
- 10:53also negative. So this is how basically
- 10:55this verifier is trained for GSM8K and
- 10:59then they did some abilations or uh
- 11:02comparisons with a baseline where we
- 11:04just directly just fine-tune on this
- 11:07data set. Um finetune meaning with
- 11:10supervised fine tuning. So we just take
- 11:12the base model and the next token bird
- 11:14prediction or we do this verification
- 11:18stage uh where we generate a 100 samples
- 11:22uh at each at each generation and use
- 11:24the highest score of the verifier as the
- 11:27true as the delivered output by our
- 11:30system. So the the idea to what we can
- 11:34see here is that um for both 6B and
- 11:381775B
- 11:39models the this one is a GPT3 model I
- 11:43believe um for both of these
- 11:45verification seems to work better
- 11:48especially as the training set size for
- 11:51the verifier increases. So, so this the
- 11:54verifier model eventually outperform the
- 11:57fine-tuning uh only uh approach.
- 12:03Um and vice versa if you have smaller
- 12:06data sets in this case less than a
- 12:08thousand for the 175B
- 12:11uh we um the verification is not helping
- 12:15much.
- 12:24Sorry, but what can you speak up? Um
- 12:27like the test score rate um um I mean it
- 12:31has a sol of the 6B verification um is
- 12:37still much higher than the
- 12:40on smaller bit
- 12:44like the orange still like
- 12:48>> isn't it lower? Okay, I see.
- 12:52>> Yeah.
- 12:53>> Okay. Um, let me go here. So, this is
- 12:57another result which which is very
- 13:00interesting and some this is something
- 13:02that could potentially be a research
- 13:04project that you guys can look into. So,
- 13:07what they did is that they tested two
- 13:10idea two approaches. One having a larger
- 13:12generator and smaller verifier and two
- 13:16having a smaller generator and larger
- 13:17verifier. And what they saw was that the
- 13:20larger generator helps with a smaller
- 13:24wave does better than vice versa. And to
- 13:27some extent this is intuitive, right?
- 13:29Because if we assume generation is
- 13:34naturally or on an ex like um on average
- 13:37is a harder task than verification, then
- 13:40this this might make sense. But like
- 13:42finding the parto optimal of like how
- 13:45these two can um kind of be the sizes
- 13:49with respect to each other would be a
- 13:50very interesting um pro research
- 13:54direction question especially right now
- 13:56as the base model or generators have
- 13:59improved a lot and also we have access
- 14:01to a lot of verifiers on hugging face
- 14:03there's like there's a leaderboard of
- 14:05like verification verifier models or
- 14:08reward models that can be tested against
- 14:11um So um again uh this was the main
- 14:14message from this this uh abilation
- 14:17study.
- 14:19Another result that uh about test time
- 14:24uh scaling that they they're showing is
- 14:26that as they increase the number of
- 14:29completions per problem and then they
- 14:31use the verifier it seems like around
- 14:33400 or so the verifier
- 14:37that's that's where they get a lot of
- 14:39benefit but after that they're not
- 14:41getting a lot of benefit. So if they
- 14:43sample 800 uh solutions and they use the
- 14:46verifier against that the verifier kind
- 14:49of fails to track what's best and what's
- 14:52not compared to the true true kind of
- 14:54distribution of the of the solutions. So
- 14:58um the uh one question for you is that
- 15:01do you remember last time when we talked
- 15:03about majority voting what was the range
- 15:06that we were getting out of that? Like
- 15:08we show that majority voting although is
- 15:11useful to some extent as we increase the
- 15:14number of samples per query it fails
- 15:18after some point to track and that's the
- 15:21generation verification gap. Does any
- 15:23does anyone remember that?
- 15:28Okay. Uh so that was we saw that the
- 15:32failure happens after 10 to like we
- 15:36never got to 50 samples like even though
- 15:39the coverage goes up the the pass at one
- 15:42or basically how we can generate select
- 15:45the correct response uh fails for around
- 15:4950 or less for the majority voting
- 15:52approach. But here they're showing that
- 15:54up until 400 they can increase the
- 15:57accuracy and their verifier is still
- 15:59useful.
- 16:06Yes, but these uh but the but when they
- 16:10they have so they do have the true
- 16:11labels per problem and then when they
- 16:14are testing this verifier the verifier
- 16:16ranks these uh at each point say for 400
- 16:20these 400 solutions they they take the
- 16:23highest score and they compare that
- 16:26against ground truth and that's what
- 16:28they're reporting here whether that was
- 16:29correct or not.
- 16:3283 times performance monitor completion
- 16:36>> at test time and training time as well
- 16:39for the verifier but not for the
- 16:41generator.
- 16:42>> Okay. for the training types all are
- 16:44human
- 16:46for the training like
- 16:47>> there there's only so for each problem
- 16:50the human has once generated an answer
- 16:52that's offline that's done once then you
- 16:56take the model generate a 100 solutions
- 16:59per problem and you compare each of the
- 17:02solutions against the ground truth which
- 17:05which is generated only once by humans
- 17:07and you see whether they match or not
- 17:09that's how you create the label
- 17:13Okay.
- 17:17Okay. Any questions from this paper?
- 17:20Yes.
- 17:21>> Question for it makes sense. It's the
- 17:25verifier is increasing result but after
- 17:27that why does it drop like intuitively
- 17:30like why doesn't it stay constant?
- 17:33>> Okay. So the question is why does it
- 17:35drop after a after 400? It shouldn't be
- 17:38constant because we are not showing the
- 17:40coverage. If you're showing the output
- 17:42of this entire system where the verifier
- 17:45ranks these say at this point 800
- 17:48different solutions and we are getting
- 17:50the max score of the verifier but the
- 17:53precision of the verifier drops like
- 17:55it's like if two solution are too close
- 17:58to each other but one is correct and
- 18:00incorrect at across 800 it can't like
- 18:03distinguish between the two as well as
- 18:05it could do for 400. Right? So, so
- 18:08that's where we get the drop in
- 18:10accuracy. And in reality, when they're
- 18:12outputting their they they created this
- 18:15system, they said that we stopped at uh
- 18:17they stopped at 100 samples because
- 18:20that's where they get most of the gains
- 18:22anyway and that's where they're
- 18:24consistent
- 18:35>> repeated sound. So parallel.
- 18:39>> So same question you ask the model 100
- 18:42different times to solve that.
- 18:47>> Yes.
- 18:48>> When they generate the label sentences,
- 18:52how do you distinguish like like one can
- 18:56just be a paraph?
- 19:01Because this is trained on a larger data
- 19:04set and because the the verifier and
- 19:07they consider both sentence based and
- 19:09token based it still works because the
- 19:13data that the trainer first of all the
- 19:15verifier is a language model itself. So
- 19:17it knows a lot about this space itself
- 19:20but also through this uh label training
- 19:24it has been trained to be able to
- 19:27distinguish between correct and
- 19:28incorrect.
- 19:32>> Yes.
- 19:32>> Uh does it make sense because I'm
- 19:34standing on the verification itself?
- 19:37>> So the question let me repeat the
- 19:39questions because one of you asked this
- 19:41before. So the question is does it make
- 19:45sense to scale the verifier? do test
- 19:47time scaling on the verifier. Yes. And
- 19:49we're going to see that in the in the
- 19:51future slides.
- 19:56>> Yes.
- 19:57>> Um the you showed like verification
- 19:59versus fine tuning. You showed that like
- 20:02before like around like a thousand steps
- 20:04like thousand like training size, right?
- 20:07Um the fine tuning actually does better
- 20:09than the verified. Does that happen
- 20:11again? Like if you scale like to higher
- 20:15>> um the verifi finetuning versus
- 20:18verification, do they cross each other?
- 20:21>> Yeah, I get
- 20:23>> um
- 20:28like if you were to actually if you do
- 20:30need that much data for for for example
- 20:33for one for a task.
- 20:37I mean I think they would like if you
- 20:39have a ton of data like at a a whole lot
- 20:43of data then fine-tuning and
- 20:46verification probably they're going to
- 20:48be the same going to kind of converge to
- 20:50the same thing. But the but the beauty
- 20:53of a verifier is that you are not
- 20:55fine-tuning your base language model.
- 20:58You're not making it like really custom
- 21:00to like one data set or one specific
- 21:03task. So that base model the generator
- 21:06model remains general and then now you
- 21:08have a verifier that you can um kind of
- 21:12lead the the langu the the base model.
- 21:15Okay.
- 21:18Um now let's go through the second
- 21:21paper. Uh another paper by openai. Um
- 21:25let's verify step by step.
- 21:32And
- 21:34so this was this came about a couple
- 21:37years like less than two years after
- 21:39that first paper. Again pro LLMs have
- 21:42had the same challenges. They
- 21:43hallucinated.
- 21:45um if you if they're solving a problem
- 21:48step by step and they make a step in a
- 21:50single in in an S step early on it can
- 21:53derail the entire answer right uh so the
- 21:57solution that they were proposing here
- 21:59is that um they consider these two kind
- 22:03of approaches to reward modeling one is
- 22:06outcome uh based reward model and the
- 22:10other is processbased reward model so
- 22:12the outcomebased one like we saw earlier
- 22:14earlier in the previous paper it
- 22:17generates a reward to the entire
- 22:20solution. It's about the correctness of
- 22:23the solution uh of the entire solution
- 22:25whereas the process one um assigns a
- 22:28different reward per step of the
- 22:30optimization problem.
- 22:36And so let's take a look exactly how
- 22:39this training can be done for the OM
- 22:41versus PRM. So we have a math problem.
- 22:44The generator instead of generating a
- 22:46100 solutions like it uh uh right now we
- 22:49are only looking into a one solution and
- 22:52it has a bunch of steps. Step one, two
- 22:54and all the way until we get to the
- 22:56final answer. Um and then we have the
- 23:00ground truth. So we can um know whether
- 23:04the final answer is correct or not
- 23:06because we can match the final answer
- 23:07against the ground truth. Um now with
- 23:11ORM we are done there because we we
- 23:13that's how we assigned the label for for
- 23:16the model but for PRM uh the way they
- 23:20did it in this paper was that they
- 23:23looked into they had human annotators go
- 23:27through the steps of the generations
- 23:31um by the model and assign a score to
- 23:34each step. So step one in this case was
- 23:37correct. Step two was correct and
- 23:38probably because the uh the uh maybe all
- 23:42of these steps were correct. That's why
- 23:43we we let it led to the final correct
- 23:46answer. But basically they created this
- 23:49entire data set of human annotated uh
- 23:53stepwise kind of correct or incorrect
- 23:56labels.
- 23:58Um and the final reward for this
- 24:00step-wise now can again in this case
- 24:04could be what they propose is that could
- 24:06can be calculated as the product of the
- 24:10the stepwise rewards per step of the
- 24:12model. So they basically train a model
- 24:15against this step-wise annotations and
- 24:18then they use that they create steps
- 24:20like you can even ask the model to
- 24:23generate the answers to a solution step
- 24:25by step. So the steps are clear. They
- 24:28run this PRM against each of those step.
- 24:30They get a score. They multiply them
- 24:32with each other. They they get a range
- 24:34of like um what the the quality of the
- 24:38answer and they can based on that they
- 24:40can uh decide whether they uh output the
- 24:44answer or try again. Um so this is
- 24:47called process supervision. Um obviously
- 24:51there is this credit assignment and then
- 24:53it's the more precise way of collecting
- 24:56uh data and assigning labels to
- 24:59different steps of the problem rather
- 25:01than just looking at the output answer.
- 25:04Um
- 25:06a property here that's very important
- 25:08actually this is like a really kind it
- 25:11could be a pitfall for uh test time
- 25:14scaling is that with processor
- 25:16supervision we can manage the false
- 25:19positives way better than we can do with
- 25:22just outcome supervisions supervision.
- 25:25Why? Because model might hallucinate and
- 25:28this happens surprisingly model can
- 25:30hallucinate and get to a final correct
- 25:32answer while the process for it is like
- 25:35really wrong.
- 25:37Whereas with process supervision because
- 25:39we are kind of pro like we are
- 25:41supervising we are seeing all the steps
- 25:43and we have a score for it. It's less
- 25:45likely that we get into that um mode
- 25:49where the steps are wrong but we are uh
- 25:52the final answer is correct.
- 25:55Um also it encourages interpretable
- 25:59reasoning and um human endorsed uh
- 26:02process of solutions. It's human
- 26:05endorsed again because humans have
- 26:07created the labels. Um so this paper
- 26:11produced this data set PRM 800K.
- 26:15Um it's an open-source data set uh of
- 26:19800K step level labels. So, so and and
- 26:24um
- 26:25so the way they did this was a generator
- 26:28model against a language they took a
- 26:30language model and they generated a
- 26:32large number of samples per problem in a
- 26:35step-wise matter manner and then they
- 26:38also did this trick of like because they
- 26:40wanted to collect higher quality
- 26:43stepwise labels, they took him to um
- 26:47what they call convincing wrong uh uh
- 26:51kind of answers meaning that the they
- 26:55gave higher pri priority to samples
- 26:59where the the final answers were um
- 27:02correct but the intermediate steps were
- 27:06incorrect. Um
- 27:10and this enabled them to be 2.6 times
- 27:14more data efficient just than just
- 27:16randomly selecting these samples and
- 27:19give it to humans. So they did
- 27:21iteratively. So they had like a very you
- 27:24can have a step a PRM by just asking an
- 27:27LLM to judge a step, right? You can have
- 27:30that. Uh so they iteratively upgraded
- 27:33the PRM by collecting this data and then
- 27:36training on the PRM for it and then um
- 27:40increasing the quality of the data. So
- 27:43um and at each step the label was that
- 27:46was collected was either positive or
- 27:48negative or neutral. For example, let's
- 27:50take a look at this problem. Uh the
- 27:53denominator of a fraction is 7 less than
- 27:57um uh 3 * the the numerator. If the
- 28:01fraction is equivalent to 2 over 5, what
- 28:04is the numer numerator of the fraction?
- 28:06And then there are these steps and the
- 28:08first step was labeled correct, second
- 28:11was correct and all the way to the fifth
- 28:13step was correct. U but this last step
- 28:16obviously the model failed to do the
- 28:18math. X should be 15 14 but it's seven.
- 28:21So that was labeled incorrect. So that's
- 28:23how they
- 28:24collected the labels.
- 28:29Um here is the process. So they took
- 28:32GPT4 as their base model. Um [snorts]
- 28:35they still fine-tune GPT4 for both the
- 28:38OM and PRM training on this data set
- 28:41first. So the supervised
- 28:44uh uh finetuning first
- 28:47uh
- 28:49and
- 28:51for OM of course they just have the
- 28:53pairs of generated samples and final
- 28:55correctness but for PRM they had this
- 28:58generator generate the sample and then
- 29:01the stepwise corre correctness label. Uh
- 29:04for OM the final score was the score of
- 29:07the final token in the completion. again
- 29:10they again went to the token level
- 29:12approach for ORM um but for PRM it was
- 29:16the product of uh probabilities
- 29:19uh for every stop now let's take a look
- 29:22at some of the solutions um they were
- 29:25showing that PRM outperforms OM and
- 29:28majority voting so again here n is the
- 29:31number of solutions per problem majority
- 29:34voting again fails after in this case
- 29:37100 or so samples Uh the blue line is
- 29:40the OM model and the orange one is the
- 29:43PRM approach that is doing better. Um
- 29:48and the but they notice that PRM detects
- 29:51correct solutions for some of the very
- 29:53rare kind of occurrences of correct
- 29:56answers on problems with less than 5%
- 29:59correct answers in the distribution of
- 30:01samples.
- 30:04Um
- 30:06they also showed the benefit of larger
- 30:09data and this active learning uh
- 30:11approach that they had.
- 30:14Again um the
- 30:17and and the other the other kind of
- 30:19observation that they were showing is
- 30:21that PRM seems to be more data
- 30:24efficient. So the number of labels that
- 30:27they collected for PRM if they match
- 30:29that against um uh OM u both PRM and ORM
- 30:36benefit from more and more labels but it
- 30:38turns out that the PRM is more sample
- 30:40efficient right so um so if they have
- 30:44100 solutions label labeled per problem
- 30:47for an OM model that's kind of like
- 30:50having
- 30:51like one solution per problem based on
- 30:54the PRM approach and so on.
- 30:59Um the other interesting property uh and
- 31:04that's what what we all should strive as
- 31:07we gener as we are training these kind
- 31:09of verifier and reward model is the
- 31:11gener generalizability
- 31:13to new domains and new data sets. Uh
- 31:16here what they're showing is that
- 31:18majority voting actually is better than
- 31:21OM in terms of how it generalizes. Uh
- 31:24but PRM is a better u is a better than
- 31:28majority voting overall. Um and uh it
- 31:32can tolerate a whole lot more
- 31:33distribution shift than majority voting.
- 31:36Um and so overall this seems like a much
- 31:40better approach here.
- 31:43Um any questions?
- 31:46Yes,
- 31:47>> PRM obviously like could lead to like
- 31:50false credit assignment if like a step
- 31:52looks good but doesn't actually
- 31:53contribute to the final answer. Are
- 31:55there domains that you would expect PRM
- 31:57to actually hurt?
- 32:00>> Um so the question is can PRM hurt
- 32:03sometimes because um the final answer
- 32:06might still be incorrect. Um so the
- 32:09truth is like a lot of the newer
- 32:11approaches combine the two like the
- 32:13reality is they combine both the PRM and
- 32:16OM based solutions because you want to
- 32:18get the bene benefit of of both
- 32:21approaches. Um and the other thing is
- 32:24that like the threshold that you can
- 32:26define for for a PRM then is also like a
- 32:30hyperparameter that now you have
- 32:32introduced that you have to like deal
- 32:33with and optimize for your system and
- 32:36that that's an additional complexity
- 32:38here but yes
- 32:41>> the previous one
- 32:43um does it make sense to this comparison
- 32:46because J requests much more labels than
- 32:49RN so does it show up where the access
- 32:52Texas access is like nimble.
- 32:54Um I think they were trying to Yeah,
- 32:57because they also mentioned that it's
- 32:59hard to compare and they did they did
- 33:01manage to like have because um it's true
- 33:06OM needs like K labels per problems but
- 33:11PRM needs K times some number of steps
- 33:14but then it's very hard to control that
- 33:16number of steps of like how do you
- 33:17exactly control but they did try to
- 33:20manage that and I believe some of the
- 33:22graphs they they do that but that's a
- 33:23good Right. Yes.
- 33:26>> Majority voting mean in this context.
- 33:29>> So majority voting is you have n sample
- 33:34you uh you don't have any access to any
- 33:37reward model. You just see which sample
- 33:39or solution is repeated most and you
- 33:42take that as your final answer.
- 33:46>> Are you also working on the reason
- 33:48process?
- 33:49>> No, you look into the final answer.
- 33:53Um, in this case, are they using the
- 33:55same PRM 800K for all of those tasks or
- 33:59are they using different terms for each?
- 34:03>> Um, because they're talking about
- 34:04generalization, I assume this should be
- 34:07>> the same
- 34:08>> the same one. But yeah,
- 34:14>> yes.
- 34:15>> Uh, how does this avoid when the
- 34:17reasoning is actually bad but rated
- 34:19high? Like for example um if you go back
- 34:23to slide
- 34:25>> this one
- 34:30>> yeah this one like what if like the uh
- 34:34reasoning is let's call the numerator x
- 34:36and then x = to 14 and it jumps immunity
- 34:40to the x how does that avoid like 31
- 34:44>> so you're saying the prm can give a high
- 34:46score
- 34:47>> like what if it's like skip all the
- 34:49reasoning
- 34:50um like let's call the numerator x and
- 34:53then x= to 14 like how does that avoid
- 34:55like that kind of hacking?
- 34:57>> Sorry, I don't get it. Can you speak up
- 35:00what's the alternative scenario you're
- 35:03talking about?
- 35:04uh like the the reasoning step would
- 35:07just be numerator x and then x= 4 and
- 35:11how does the like the PRM avoid the kind
- 35:12of like real typing scenario
- 35:15directly skip some steps and directly
- 35:18generate the answer
- 35:21like speed
- 35:24>> so the parents are trained like parents
- 35:27can also see the previous steps like the
- 35:29questions previous step and here is the
- 35:31current steps to score Right. You're
- 35:33right. Um, so if X is 14, then it's
- 35:36great, right?
- 35:38>> It doesn't really encourage like the
- 35:39thinking process of like going to step
- 35:41by step.
- 35:43>> It doesn't. No,
- 35:44>> no, it doesn't. But you can prompt the
- 35:46model to to do this cuz you're not
- 35:49changing the model, right? You're not
- 35:51changing your generator. You can't like
- 35:53uh the that failure mode could be when
- 35:56you were fine-tuning your generator
- 35:58model and the model kind of stops
- 36:00reasoning and just generates and final
- 36:02answer that the PRM likes, right? But
- 36:05you're not touching your generator. The
- 36:07generators can still be prompted to do
- 36:09reasoning, create these steps, and then
- 36:11the verifier just scores them.
- 36:14Um
- 36:16>> but if let's say we want to use the PRM
- 36:18to train the
- 36:20>> yeah then you have to be careful then
- 36:22you have to like make sure that the
- 36:24chain of thought makes sense right and
- 36:27your PRM again your PRM can the way you
- 36:31train your PRM can also be aware of that
- 36:33because your PRM could be as your your
- 36:36PRM these are like human generated
- 36:40labels in this case right if we had like
- 36:43skipped all of this and then we would go
- 36:45to X14. Probably the human says this is
- 36:47this doesn't make sense. This step is
- 36:50lower because this step is skipping a
- 36:52few kind of reasoning steps.
- 36:56Does that make sense? So these labels
- 36:58are created by humans here.
- 37:05>> So if the labels are not generated by
- 37:07humans and we're going to see that in
- 37:09the next paper. Yes, that is definitely
- 37:11a caveat like and something that you can
- 37:13make sure but there are ways to handle
- 37:15that as well. Okay, so for now let's
- 37:18assume these are human labels. So the
- 37:20processes are labeled in a way that they
- 37:22make sense as well. We have so many
- 37:24things to encourage these gener
- 37:26generation to make sense. First of all
- 37:29the generator
- 37:31should should generate the steps. The
- 37:33PRM is trained on human annotations that
- 37:36also they also make sure that this step
- 37:38makes sense given the prior steps.
- 37:43Any other questions?
- 37:48Okay, let's go through the next the next
- 37:51paper. Matt Shepard verify and reinforce
- 37:54LLM step by step without human
- 37:56annotation. So we're getting to what if
- 37:59we um didn't want to collect that many
- 38:03annotations
- 38:05um from humans. So again motivation is
- 38:10that um
- 38:12having stronger vifiers shows the
- 38:15potential to really improve models
- 38:17reasoning behavior especially if you do
- 38:19test time scaling. um PRM have shown
- 38:23more potential than OMS but they require
- 38:26a lot of data and it's hard to collect
- 38:28these data so can be um automate the
- 38:32process of label collection for PRMS
- 38:37um so this paper talks about two kind of
- 38:40approaches one is automatic annotation
- 38:44um and also
- 38:47u kind of brings the the the the reward
- 38:50model as a into the loop of uh generator
- 38:53optimization via a reinforcement
- 38:55learning approach uh which uh we are
- 38:58going to briefly mention that. So
- 39:03in this case u the way they tried to go
- 39:07about this um automatic kind of
- 39:10annotation of steps was that they define
- 39:13the quality of the reason step as the
- 39:17potential of the step to reach to the
- 39:19final correct answer. So let's say we
- 39:22have we are at a given step. we sample n
- 39:25kind of completions from that given step
- 39:28and see the potential for um a correct
- 39:32solution at the very end. So and they
- 39:34introduce two ways of doing this. One is
- 39:37the hard estimate uh where the the step
- 39:43is annotated u as a success if
- 39:48it any of those n generations after that
- 39:51step gets to a final correct answer. The
- 39:55soft estimate thinks of measures the
- 39:58frequency like what portion of the
- 40:00generations after a current step reached
- 40:02the final correct answer. So here is
- 40:04like how it works. um say here is the
- 40:08problem and this is our current state.
- 40:11Instead of just sampling one step, we
- 40:15sample n is three in this case. So we
- 40:17sample three steps and then we continue
- 40:21um and and we measure the frequency in
- 40:23the soft estimate. We we measure the
- 40:25frequency of correct answer at the very
- 40:27end. In hard estimate, we see whether
- 40:30any any of these um uh are correct or
- 40:34not. So hard estimate would be one for
- 40:36step one. Soft estimate would be 2/3 for
- 40:40step one.
- 40:42Um anyone can
- 40:45um kind of name it a challenge or a
- 40:51drawback of this approach. So basically
- 40:55the this soft or hard um kind of
- 40:58estimation is replacing the human
- 41:02annotations. So we're getting a score
- 41:04per step by just rolling out more
- 41:07samples from that step and and seeing
- 41:09whether we reach to the final correct
- 41:11answer or not and assume that we do have
- 41:13final labels for these problems. Um
- 41:21>> yes
- 41:23>> or um where are predictable paths on the
- 41:28lower right uh the when the
- 41:31unpredictable path could be the only way
- 41:33to solve
- 41:35>> sorry speak up again if it's
- 41:37unpredictable
- 41:38>> unpredict or like unusual approaches to
- 41:40solving a problem but it could be scored
- 41:43as low or something that might You know
- 41:46a way to be able to solve that problem.
- 41:48So it might be really hard problem
- 41:51to lose that path to that solution.
- 41:54>> That is correct. So basically say n is
- 41:58three here. Maybe we needed like 100 n
- 42:01equal 100 to see that final correct kind
- 42:05of like trajectory to score this step.
- 42:09But we won't see that if we just look
- 42:11into three, right? And then we give a
- 42:13score of zero. Um, anything else?
- 42:23>> Yes,
- 42:24>> I guess this is similar, but if you're
- 42:26dealing with like a hard question, if
- 42:27you're taking the approach of like
- 42:29generating a lot of samples, a lot of
- 42:31the samples can just not be correct or
- 42:33not the correct way to do it. So,
- 42:35>> you just
- 42:36>> you don't get any signal for hard
- 42:38problems in this case.
- 42:41>> Um, that's right.
- 42:44that service doesn't mean any
- 42:48>> exactly I think this is like probably
- 42:51like these two that you all mentioned
- 42:53here one is for hard problems you don't
- 42:55get signal the other one is what if
- 42:57there are like wrong steps in the middle
- 43:00and we got to the final correct solution
- 43:03um we still label those uh steps as
- 43:06correct
- 43:07um so the hope is that if you have more
- 43:10samples it shows the wrongness in one of
- 43:12these these kind of uh trajectories but
- 43:16it's not guaranteed.
- 43:20So um
- 43:25so here is the verification process. You
- 43:27sample and again you sample in candidate
- 43:31solutions uh score them using the PRM
- 43:34and you select the highest kind of PRM
- 43:37score across across the the generated
- 43:41samples. They also took this PRM and
- 43:44trained the model with this PRM to
- 43:47encourage the model to generate uh steps
- 43:50that are scored higher and higher by
- 43:52PRM. So PRM basically uh served as the
- 43:55reward model uh for this. Um so for they
- 43:59looked into the hard versus soft
- 44:01annotations and although the loss
- 44:03function um as they increased n would be
- 44:08um it seemed like the the the soft
- 44:11annotations were uh doing better. Uh but
- 44:17somehow um what they observed with that
- 44:20with an n equal 4 the depth of like the
- 44:23trajectory completions to collect these
- 44:26labels that's where they get like their
- 44:28best results anyway. So it really didn't
- 44:32matter whether they used the hard
- 44:33estimate or softest estimate and they
- 44:35went with the hard estimate at the very
- 44:37end because it's um because it was just
- 44:39easier to to measure that. So um
- 44:47here is another comparison with
- 44:49baseline. So here they have SC is major
- 44:52self-consistency is another name for
- 44:54majority voting which which solution was
- 44:57most consistent. Uh that's the red one.
- 45:00Um OM is the blue one and the shepherd
- 45:04is this PRM approach uh is uh the green
- 45:07one. And the interesting part here was
- 45:09that there was no human annotation. All
- 45:12the annotations were uh modeled
- 45:14generated
- 45:16um or the with the the mechanism that
- 45:19they introduced.
- 45:21Um here they also compare with PRM 800K
- 45:24which was the way fire the that we that
- 45:28in the previous paper that was trained
- 45:30and it outperformed that as well on math
- 45:32which is like a harder much harder uh
- 45:35setup. This data set is more difficult
- 45:38than GSM GSMHK and they were getting
- 45:41even higher uh delta in there.
- 45:45Uh they also compared the these results
- 45:49uh with uh different types of verifiers
- 45:52again across uh
- 45:56GSM8K and MAT 500 problems. And you can
- 46:00see that the difference between these
- 46:01models and like these approaches um and
- 46:06um there there is a notable difference
- 46:11between these models and uh the
- 46:13baselines which is self-consistency
- 46:16approaches
- 46:18and this is true across different models
- 46:2070 lama 70B LMAD 34B and deepseek 67B
- 46:29uh they also showed that they can get
- 46:31even better they can make the model even
- 46:33better if they they RL the model against
- 46:35the PRMS that they trained. So in this
- 46:38case the match sheepard on this their
- 46:41their approach basically mis taking
- 46:43mistral 7B this model and then they uh
- 46:47po it against this PRM uh they're
- 46:50getting much higher results u compared
- 46:53to um doing this RL with just an OM um
- 46:59the delta here is um slightly less I
- 47:02would say than just the test time
- 47:04scaling but um this is also
- 47:07another way for the models to
- 47:08self-improve, right? You generate the
- 47:11annotation by the model itself. You
- 47:14train the PRM and then use that PRM to
- 47:17improve the mo the generator model as
- 47:19well, both at test time and during with
- 47:21this RL fine-tuning. So, it's like
- 47:23multiple levels of using the model
- 47:25itself to generate data and like RL
- 47:28reward signal for for for itself.
- 47:34Um
- 47:38yeah and then they can do RL and PO and
- 47:41do verification up on top and they get
- 47:43even better results but it seems like
- 47:45kind of kind of their optimizations are
- 47:48plateauing at some point. Um any
- 47:51questions from this paper?
- 47:56>> Yes. Are there ways to build PRM that
- 47:58like incentivize like self error
- 48:01correction which I imagine be like a
- 48:03desirable thing but like if we're only
- 48:04you know rewarding each step be correct
- 48:07you don't necessarily end up reinforcing
- 48:10a lot of incorrect steps back
- 48:14>> so encourage parents to do more self
- 48:17correction
- 48:19>> yes absolutely like for example one of
- 48:22the methods that that can be done is
- 48:24that you have a rubric or a set of rules
- 48:27that you give the model as your scoring
- 48:31step. So the model can check the step
- 48:34against this rubric that your design for
- 48:37this data set and that can be used as
- 48:40extra signal whether this step makes
- 48:43sense or not
- 48:45right for example the very or like use a
- 48:47calculator in that case in the problem
- 48:49in the equation that we are seeing if
- 48:51the model could use could do tool use or
- 48:54use a calculator in that case it would
- 48:56not it could solve that problem easily
- 48:58right could for example use uh simp.
- 49:02So, so there are ways to bring more
- 49:05supervision and more signal and enable
- 49:07the model to use tools and test time
- 49:11scaling and agentic approaches to
- 49:13improve the verification process.
- 49:19>> Yes.
- 49:22>> Do they control the amount of test
- 49:24compute?
- 49:28Um
- 49:30I I believe so. You mean test s times
- 49:32when they're using the verifier like a
- 49:34baseline verifier versus themselves? I
- 49:37I'm actually not sure if they do they do
- 49:39that when they're doing process versus
- 49:42because again that's really hard to do
- 49:45like but
- 49:50>> you're scaling things right.
- 49:52>> Yeah. I think that could actually be a
- 49:54question that you could investigate like
- 49:56you can sample more on the generator,
- 49:59you could sample more on the verifier if
- 50:01you if you're controlling for a fixed
- 50:03compute. How do you allocate that? Um so
- 50:07one of the challenges here is that
- 50:08usually like the OM and PM should come
- 50:10from the same data for us to do like a
- 50:13good like apples to apples comparison,
- 50:16right? Um cuz if you do train a PRM and
- 50:19someone else train an RM makes things a
- 50:21bit harder. The training data also
- 50:23matters a lot.
- 50:26>> Any other questions? Yes.
- 50:28>> Um, can you go back to the 3D slide?
- 50:31>> No, I was just Oh, no. No. It was the
- 50:33basically for this one I was just
- 50:34curious as to why after using RL um they
- 50:37stuck with evaluating performances with
- 50:403D decoding. Uh I was just curious like
- 50:42whether or not you know raising the
- 50:44temperature like really made a
- 50:46difference or that's the only way they
- 50:48could have seen like the you know
- 50:50smalish delta.
- 50:53So the the the reason so the question is
- 50:55why they they stopped greedy decoding
- 50:57why they didn't do like temperature
- 50:59changes and test time scaling again
- 51:01right I think that's what this slide is
- 51:04so they they then in this case
- 51:08um the verification is done against 256
- 51:12outputs so the previous one is um no
- 51:15verification right the ver verifier is
- 51:17just using the RL training here it is at
- 51:19test time as well Yeah,
- 51:25I think it's something that they didn't
- 51:26do and it would be interesting to see
- 51:28what if they repeat the process again
- 51:31um generate another set of labels and
- 51:35train a verifier and then but starting
- 51:37from this RLPPO
- 51:40model. Yeah.
- 51:47>> Okay. Let's get to the last paper. um
- 51:51shrinking the generation verification
- 51:53gap with weak verifiers. So this is the
- 51:56paper a paper um that uh from from
- 52:01Stanford that uh came out a couple of
- 52:05months ago at this point. So um it's a
- 52:09new 2025 paper. So the motivation again
- 52:14um is
- 52:17the same. We have we still have a
- 52:19generation verification gap and but the
- 52:22approach here was a bit different. The
- 52:25here we were not training a new
- 52:27verifier. We were thinking can we reduce
- 52:29the generation verification gap by using
- 52:32inference compute and inference scaling
- 52:35and specifically by using an ensemble of
- 52:38verifiers because it's but when we say
- 52:41weak we just assume that no verifier is
- 52:44perfect. So that's the weakness. We
- 52:45didn't purposefully choose like bad
- 52:47verifiers. These are the best verifiers
- 52:49that are out there, but we are using an
- 52:51ensemble of them to create uh a single
- 52:55uh much more capable verifier. Um
- 53:02so the property of weak verifiers is
- 53:05that they do have they do correlate with
- 53:07the true label of the problem but they
- 53:09have of the solution but they have
- 53:10imperfections. Um and there are two
- 53:13types of these verifiers. We learned
- 53:15about PRM and OMS. But another one that
- 53:18we briefly discussed in the in in a few
- 53:21minutes ago is that we can use LLMs
- 53:23themselves as a judge. We can show it an
- 53:28answer and ask it whether do you think
- 53:29this is correct or not. The prompt could
- 53:31be literally that or we can have the
- 53:34model use tools and use rubrics and all
- 53:36that to uh generate a score for a model.
- 53:39So that's a whole category of verifiers
- 53:42that we can use on top of just PRMs and
- 53:44OMS. Um so here this first graph just
- 53:48shows um how ensembling and using a
- 53:52number of verifiers that are they could
- 53:55be trained by different labs on
- 53:58different data sets. We just like and
- 54:00there are all these language models that
- 54:01take a query as input and give a score
- 54:04at on the output side. Here we are
- 54:06comparing uh we are seeing these four
- 54:08data sets. So in this case we showing
- 54:12the performance of top one versus top
- 54:15five versus top 10 verifiers based on
- 54:18like how good they are in some ranking
- 54:20system. Overall, it seems like um
- 54:26like just uh un ensembling them with
- 54:29each other um and using them at test
- 54:32time
- 54:34uh does improve things u but not in a
- 54:38necessarily in a monotonically monotonic
- 54:41way. But the thing that always helped
- 54:43was that if we train a model to a a way
- 54:48for them to to add them together. to
- 54:51assign weights for different members of
- 54:53the ensemble if we have labels from
- 54:56them. Here we have we have two methods
- 54:58naive base or logistic regression. These
- 55:00are very simple methods. Basically, you
- 55:03add a simple single weight per verifier
- 55:05to score them together to and if you
- 55:08have a training set set for for your
- 55:11with a with labels, you can basically
- 55:14come up with these weights and and now
- 55:16these results are on the test set
- 55:18corresponding to those tasks. So, you
- 55:21basically say for math 500 500 I have a
- 55:25set of labels. I use that to average my
- 55:27verifiers, find the weights and then I
- 55:30use this averages on a new on test data.
- 55:33So that does give it seems like it does
- 55:35give a lot lot of improvement just this
- 55:38simple task. Um now you can do other
- 55:43things. So the the way we works is by
- 55:45this score weight and select approach.
- 55:48So in the first step, we are going to
- 55:51score outputs of the verifiers and uh
- 55:55normalize them so they're all on the
- 55:57same scale and and um and filter out the
- 56:01lowquality verifier. So in this setup
- 56:04even we are assuming we have access to a
- 56:06very limited labels that we can say okay
- 56:08these verifiers are just so bad against
- 56:10our labels we just remove them from our
- 56:13ensemble. We have noticed that this is a
- 56:16very important step like your verifiers
- 56:18should be above a certain quality to be
- 56:20even be let in the pool of verifiers. So
- 56:24then you have your verifiers, you have
- 56:26your LM judges, you have your reward
- 56:28models and then you get these scores
- 56:30from them whether it's zero or one or
- 56:32the log prop of correctness per um per
- 56:36verifier. And then um what weieber did
- 56:40was to use weak su weak supervision to
- 56:44uh estimate kind of the verifier
- 56:46accuracy with very small uh data labeled
- 56:50data and then um and then we use those
- 56:53ways to combine the verifiers output and
- 56:55assign a score. Um I go briefly through
- 56:59like how this week to strong supervision
- 57:02works. Some of you if you have t taken
- 57:04deep learning courses or even CS 229s
- 57:08last time we talked about it about weak
- 57:11to strong supervision. There's a whole
- 57:13body of work here. Uh beaver was
- 57:16specifically u kind of uh
- 57:20um motivated by the work by snorkel by
- 57:23Alex ran ratnell atal and other work
- 57:26from Stanford. So the so here is how we
- 57:29have these weak verifiers like weak
- 57:32signal from our verifiers and combine
- 57:34them together to get a stronger signal.
- 57:36The setup is the following. We have n
- 57:39queries. For each query we create k
- 57:42solutions and then let's assume we have
- 57:44m verifiers. So we have a total of n * k
- 57:48* m labels. uh and our goal here is to
- 57:54create to get this probability of um
- 57:59query I sample J uh equal to one given
- 58:03all the labels that we get from all the
- 58:05verifiers. So how do we estimate this
- 58:07probability correctly? Um the assumption
- 58:10in beaver is that each verifier captures
- 58:14independent aspect of the correctness.
- 58:17So this is a key assumption that we
- 58:19made. Um to some extent the reason we
- 58:22get so think about it this way if you
- 58:24have a pool of verifiers if all of them
- 58:27agree on the score that they give to any
- 58:30sample then we are not learning anything
- 58:32new from them right if all of them are
- 58:34like 100% or the same score the signal
- 58:37here is on kind of similarity and
- 58:40dissimilarity across these whole set of
- 58:43verifiers with each other. So under this
- 58:46assumption we can write this probability
- 58:49for the the response being correct given
- 58:52the labels that we have and then we use
- 58:55two sets of equations. Again this the
- 58:57first equation uh is uh we can write it
- 59:01this way because we assume every two
- 59:03verifier I and J are independent from
- 59:05each other. The second equation is the
- 59:08the just the base uh kind of the the the
- 59:12way probability works. There's no
- 59:13assumption in writing this. And given
- 59:15these two uh we can kind of define uh we
- 59:20can write an optimization and def come
- 59:22up with the weights that we can assign
- 59:25to each of the the verifiers.
- 59:29Um and here we are comparing the results
- 59:32with a naive ensemble approach. And it
- 59:35turns out that it does help in some
- 59:38cases that the the gains are more
- 59:40significant in GPQA diamond um and math
- 59:44and ML MMLU pro and each of these
- 59:46problems that are relatively hard uh
- 59:49problems for example the GPQA are our
- 59:52our baseline um is already low but the
- 59:56very fire this way of weak to strong
- 59:58aggregation of uh responses is helping
- 1:00:02getting a large boost over naive
- 1:00:04ensemble. ing of them. Um, now there are
- 1:00:07different ways that we can scale the
- 1:00:09verification compute. We can sample more
- 1:00:12generations. So instead of 10 samples,
- 1:00:15we can do a 100 or a thousand. We can
- 1:00:18use larger models for generation and
- 1:00:20verification. We can increase the the
- 1:00:23number of verifiers in the pool. um uh
- 1:00:27and and in general there are different
- 1:00:29ways to assign flops or inference uh
- 1:00:32scale inference compute for um for
- 1:00:35solving a problem. Um here we are
- 1:00:38comparing uh some of these methods with
- 1:00:40each other. So the dashed uh kind of
- 1:00:44dark red line is the passetk oracle
- 1:00:49meaning that if we had like an oracle
- 1:00:53uh selector that would give us the
- 1:00:56correct answer. We don't have that and
- 1:00:58that's why we are training these
- 1:00:59verifiers. Um the the purple one is we
- 1:01:03were supervised and that's assumed that
- 1:01:05we have a large body of label data and
- 1:01:07we can use them to learn these weights.
- 1:01:10The blue one is the unsupervised. In
- 1:01:12this case, we're using 1% of the
- 1:01:15training labels for each data set. Um
- 1:01:18the orange one is the naive ensemble,
- 1:01:20meaning we just average them average the
- 1:01:24on the the the verifiers without any
- 1:01:27special treatment. We still are
- 1:01:29filtering um and keeping the good
- 1:01:32verifiers in the loop. And then all of
- 1:01:34these are significantly better than
- 1:01:36methods such as majority voting or
- 1:01:39multi- aent verification. And
- 1:01:42multi-agent verification just or MAV is
- 1:01:46um it's just based on prompting LLMs and
- 1:01:50asking them to score a given response
- 1:01:52based on different kind of aspects that
- 1:01:54is produced. So kind of a rubric base
- 1:01:57which is doesn't do that that much
- 1:02:00better or actually worse in these two
- 1:02:02cases than majority voting.
- 1:02:08Um but something to notice here is the
- 1:02:12drastic gains that the model can have
- 1:02:16going from something like 40 less like
- 1:02:18slightly over 40% to over 70% on these
- 1:02:23hard uh problems. and in this case
- 1:02:26matching a model like 03 mini. Um so the
- 1:02:30thing that is interesting here is that
- 1:02:33the we can use this weak to super weak
- 1:02:36to strong supervision to reduce the gap
- 1:02:39between model classes. So what we are
- 1:02:42saying here is that if we take a
- 1:02:44generator model of llama 3.18b instruct
- 1:02:48and the verifier um model which is like
- 1:02:51the the pool of verifiers that are 8b
- 1:02:54and below uh we get an average of 70% on
- 1:02:58these data set and this is almost
- 1:03:01comparable to the accuracy that we get
- 1:03:04with majority voting but when our models
- 1:03:07and uh models are at 7B. So we are kind
- 1:03:11of like
- 1:03:13making the model making this 8B model
- 1:03:17um the same roughly the same as the 7TB
- 1:03:22class by just doing this inference
- 1:03:25scaling and using the verifier and in
- 1:03:27this case unlike the what we saw in most
- 1:03:30of the previous lecture we are talking
- 1:03:32about the end results we're not talking
- 1:03:34about the coverage we're talking about
- 1:03:36the solution accuracy of the entire
- 1:03:39system.
- 1:03:41Um and here again in this case for when
- 1:03:44we do the same apply the same generation
- 1:03:46and verification to 70B class of models
- 1:03:50we are getting an average accuracy of
- 1:03:5286.2% 2% on these data sets and this is
- 1:03:55very comparable to this to O3 mini which
- 1:03:59um which has a much uh uh which is like
- 1:04:04a proprietary model and in general is a
- 1:04:08higher like a different class of models.
- 1:04:10So this shows how much verification or
- 1:04:12this work on verification can help with
- 1:04:14the results. Um, another uh work that
- 1:04:18was done on the increasing the
- 1:04:20usefulness of something like Vaver is
- 1:04:22that a challenge with ensembling
- 1:04:24verifiers is that you have a ton of like
- 1:04:26models that now you need to run for each
- 1:04:29solution to get a score and then to
- 1:04:31average them, right? To uh and that
- 1:04:34increases the cost especially if you
- 1:04:37instead of one sample per per you have a
- 1:04:40100 samples and then you want to create
- 1:04:42all these scores. So instead what uh the
- 1:04:46proposal here is that what if we do
- 1:04:48train wever once and then distill it
- 1:04:50into a much smaller model um and that's
- 1:04:54how instead of running each of these LLM
- 1:04:58judges or reward models per sample we
- 1:05:00just take this distilled uh LM which in
- 1:05:04this case we show that it could be
- 1:05:06really really tiny like something like
- 1:05:07400 million parameters as opposed to the
- 1:05:11original model which was in the 70B
- 1:05:14range. Um, and it turns out that with
- 1:05:17this distilled model, we can kind of
- 1:05:18capture 97% of accuracy of this large
- 1:05:23pool of L uh verifiers, but be
- 1:05:27significantly in this case 99 plus% use
- 1:05:31less compute at test time. And these uh
- 1:05:34and these um distilled version and the
- 1:05:37original version, they're all open
- 1:05:39sourced and the checkpoints are
- 1:05:40available. um if any of you are
- 1:05:43interested in working with them in your
- 1:05:46um agentic or test time scaling
- 1:05:49projects.
- 1:05:52Um
- 1:05:54and here is another graph. Here is the
- 1:05:56distilled one which is the light blue
- 1:05:58one and the original beaver is the dark
- 1:06:01blue one. And we are comparing again the
- 1:06:04efficiency the success rate over the
- 1:06:07inference compute the total inference
- 1:06:10compute that we are spending on this
- 1:06:12data set. Um and u
- 1:06:16um and the distilled one obviously is
- 1:06:18like significantly more efficient. uh
- 1:06:20but even the original weaver because it
- 1:06:23reaches higher levels of accuracy um at
- 1:06:26those levels it becomes more flop
- 1:06:28efficient than models like naive
- 1:06:30ensemble and majority voting
- 1:06:35and
- 1:06:37let's do a quick recap. So um here we
- 1:06:42today we covered like four papers that
- 1:06:45also showed the trajectory of how this
- 1:06:47work on verific how research on
- 1:06:49verification has progressed over the
- 1:06:52last like four years. We talked about
- 1:06:54how verification
- 1:06:56um can improve training both during uh
- 1:07:00can improve the outcome of the and the
- 1:07:02quality of results uh both uh during
- 1:07:06training and inference. uh process
- 1:07:08rewards seems to be very useful and
- 1:07:11overall uh very effective uh and more so
- 1:07:15than the outcome rewards but perhaps we
- 1:07:18need to combine them to get the best
- 1:07:20results both PRMS and OMS um and we also
- 1:07:25in Matt Shepard learned that scaling you
- 1:07:27need a lot of data and the more data you
- 1:07:29throw in the verifier training it
- 1:07:32becomes better and you can use it during
- 1:07:34your RL uh fine-tuning to increase the
- 1:07:38quality of your generator as well. And
- 1:07:41uh the beaver work was took a whole
- 1:07:44different approach to verification was
- 1:07:46and that was just uh doing this weak
- 1:07:49supervised optimization on an ensemble
- 1:07:51of verifiers and in a way we are using
- 1:07:54test time scaling but by bringing more
- 1:07:56verifiers rather than sampling a single
- 1:07:58verifier more um to to get the results
- 1:08:02and we can turns out we can distill that
- 1:08:04and capture a whole lot of the quality
- 1:08:07uh from a much smaller model and With
- 1:08:10that I can conclude the class. Any
- 1:08:13questions?
- 1:08:15Yes.
- 1:08:16>> The papers were on math or reasoning uh
- 1:08:21benchmarks. Do you think there's
- 1:08:22anything else that [clears throat] could
- 1:08:23work for project other ways to evaluate
- 1:08:26the model?
- 1:08:28>> Um like coding other ways to evaluate
- 1:08:30the model. You mean other areas like
- 1:08:33coding would be a very interesting uh
- 1:08:36area for for reasoning. So these like
- 1:08:38there were like some coding problems in
- 1:08:40this CT like in some of the benchmarks
- 1:08:42here. So it's not not just math uh but
- 1:08:46um coding is also a very interesting
- 1:08:49kind of uh area for verification. We
- 1:08:52will uh we will talk about code monkeys.
- 1:08:55This is a paper uh that instead of
- 1:08:58directly training a verifier, you can
- 1:09:00make the model create a test time system
- 1:09:03to make the model generate unit tests
- 1:09:06and those unit tests become your
- 1:09:07verifier. So that's an entire different
- 1:09:09approach. Um but these kind of
- 1:09:13verifications should also be useful for
- 1:09:15any kind of reasoning task.
- 1:09:22>> Yes. I'm curious like how do generation
- 1:09:27verification help
- 1:09:30us model like that internalized
- 1:09:35one.
- 1:09:37>> Okay. So the question is that for
- 1:09:39reasoning model how does the generation
- 1:09:41verification or these kind of test time
- 1:09:43scalings work for them? It actually
- 1:09:45helps them as well still. uh but the
- 1:09:49reasoning model like uh we're going to
- 1:09:51talk about them in this class but
- 1:09:53basically what they're doing a big part
- 1:09:55of it is to generate these reasoning
- 1:09:57steps use the reward for it and do an RL
- 1:10:01loop and generate positive trajectories
- 1:10:04and then use that positive trajectories
- 1:10:07as part of training for the next round.
- 1:10:09Right? So the test time scaling is
- 1:10:12inherently used to generate data and
- 1:10:15generate the training process. But they
- 1:10:18still would benefit because they still
- 1:10:21uh could explore different parts of the
- 1:10:24solution space with with more sampling
- 1:10:29kind of like knowledge using training on
- 1:10:33the test. Do you think in the future
- 1:10:35like this two parish or do you think
- 1:10:39like um maybe like repeat sampling would
- 1:10:42only be used for generating training for
- 1:10:47>> Yes. So the question is like would we
- 1:10:50converge to a future where these kind of
- 1:10:52test time scaling repeated sampling and
- 1:10:54science just for training time to create
- 1:10:56the data and then at test time we uh we
- 1:10:59just use ask the model once I think
- 1:11:01that's the direction we want to go right
- 1:11:03we want the model to be really really
- 1:11:05good at pass at one like the first time
- 1:11:07we ask it to do something we want it to
- 1:11:10generate and that increases the
- 1:11:11efficiency and all that like that would
- 1:11:13be the hope one challenge though with
- 1:11:16making the model too like like to make
- 1:11:19the the log props of the model too
- 1:11:21sharpened through through one answer is
- 1:11:23that the creativity and diversity of
- 1:11:26solutions may be lost some somehow
- 1:11:28during the training. Um so
- 1:11:32surprisingly we still like them like
- 1:11:34models that are very d like create have
- 1:11:37a lot of creativity and diversity in the
- 1:11:40way that they they think and that's like
- 1:11:42a good feature that we want to have in
- 1:11:44the models.
- 1:11:46>> Yes.
- 1:11:48Does it matter if generator and
- 1:11:49verifiers have very different
- 1:11:51architectures? For example, if the
- 1:11:52verifier is like a mini version of the
- 1:11:54generator versus if they're very
- 1:11:56different architectures,
- 1:11:59>> but does it matter like like which one
- 1:12:01which one is um empirically?
- 1:12:04>> Okay, so the question is like if the
- 1:12:06generator and verifier from the same
- 1:12:08family or not. That's that's a good
- 1:12:11research question. Um I think in general
- 1:12:16it's interesting like models like their
- 1:12:18own generations and their their own way
- 1:12:20of interpreting results much better than
- 1:12:23using a different family of models. Um
- 1:12:26we are going to talk about a paper that
- 1:12:30talks about how uh certain models can
- 1:12:33benefit from like a different class of
- 1:12:35verifiers over themselves. But like a
- 1:12:37specifically uh I am unaware of a study
- 1:12:41that has looked into that specific
- 1:12:43question of uh same kind of size and
- 1:12:46family versus uh different size
- 1:12:48different family. How does how that
- 1:12:50changes the behavior of the model?
About this transcript
This page contains the full transcript of YouTube transcript (p7TdPUcPoik) , generated from the public captions YouTube serves with the video. The transcript has 10,493 words across 1,536 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.
What you can do with it
Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to choose a caption track available on the video.
Free YouTube transcript tool
YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, caption language selection, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.