YouTube2Text

YouTube transcript (yVnmHSAy3ck) — Transcript

12,791 words · 1,886 segments · language en · Watch on YouTube

Full transcript

  1. 0:05Welcome everyone to sixth lecture for
  2. 0:07CS3 to9A. Uh we'll today cover train
  3. 0:11time scaling or scaling RL. So far we
  4. 0:14have gone through several topics related
  5. 0:16to test time scaling u feedback using uh
  6. 0:20tools and code and then also robust
  7. 0:23verification. Today we will see how we
  8. 0:26can close the loop to improve the models
  9. 0:28even further.
  10. 0:30Okay. So today's lecture we will
  11. 0:31actually cover three papers. Uh the
  12. 0:34first paper will cover how can you uh
  13. 0:37boost the reasoning capabilities of the
  14. 0:39models with um putting rationals in um
  15. 0:43problems. Uh this paper was is called
  16. 0:46star. It was actually done by an author
  17. 0:48at uh Stanford. The second paper we will
  18. 0:51cover is deepseek math which talks about
  19. 0:53mathematical reasoning and how that can
  20. 0:55be uh boosted in u language models. And
  21. 0:58then the third paper is more focused on
  22. 1:00reinforcement learning and how when you
  23. 1:02have to do uh reasoning with longer
  24. 1:05reasoning chains how can you stabilize
  25. 1:07that kind of reinforcement learning
  26. 1:09algorithms.
  27. 1:11So to
  28. 1:13ground a lot of the to motivate a lot of
  29. 1:15the uh papers that we'll present today
  30. 1:18if you look at a benchmark called Amy.
  31. 1:20So AM is a benchmark which is uh on
  32. 1:24mathematical problems which uh tests for
  33. 1:27mathematical reasoning. It's very
  34. 1:28similar to say um it's it's more uh
  35. 1:32complex mathematical reasoning problems
  36. 1:34than say what was in a math benchmarks.
  37. 1:36Uh we used math benchmarks earlier this
  38. 1:39year and then that one is already
  39. 1:40saturated and and not and contaminated
  40. 1:43in most of the models. Basically most of
  41. 1:45the models have been trained on it. So
  42. 1:46we had to change the benchmark. So this
  43. 1:48is uh Amy 2024 and AME 2025. The
  44. 1:51benchmark that you use in homework one
  45. 1:54um is a recent a recent benchmark that
  46. 1:56is uh has mathematical reasoning
  47. 1:58problems. And if you were to evaluate
  48. 2:01GPD 3.5 which is 175 billion parameter
  49. 2:05model you would get or or that's what
  50. 2:07it's believed to be you get almost 5%
  51. 2:10accuracy. But if you were to take
  52. 2:12deepsek math which was uh using train
  53. 2:15time scaling with on a 7B model it gets
  54. 2:1851.7% accuracy and
  55. 2:21with additional tricks it's able to even
  56. 2:23get 60% accuracy and if you apply uh the
  57. 2:27third paper that I will talk about
  58. 2:29called Dapo uh on the quen 32B model you
  59. 2:33are able to get 50% accuracy. So in the
  60. 2:36prior work or in the first lecture we
  61. 2:39were saying that as we scale the number
  62. 2:43of parameters in the model that's when
  63. 2:45the model capabilities go up the model
  64. 2:48accuracy on benchmarks go up. But what
  65. 2:51we are seeing in this particular slide
  66. 2:52is that you can achieve a pretty high
  67. 2:54performance on reasoning benchmarks with
  68. 2:56smaller models. So how did these smaller
  69. 2:58models uh get really performant? How did
  70. 3:00they get really high accuracy? So that's
  71. 3:03something that we will kind of explore
  72. 3:04in this particular lecture. And the some
  73. 3:08of the tricks that are being used uh to
  74. 3:10achieve uh this are called train time
  75. 3:12scaling. Um so typically if you try to
  76. 3:15do reinforcement learning on reasoning
  77. 3:17it will not work well and a lot of the
  78. 3:19times the reason it doesn't work well is
  79. 3:22uh because the implementation details
  80. 3:23are hard to get right. So the the key
  81. 3:26insights that we uh that we will study
  82. 3:29today are that if you have a model
  83. 3:32earlier you were just training it on
  84. 3:34internet. So pre-training the technique
  85. 3:36of model training was training the model
  86. 3:39on internet. If you allow the model to
  87. 3:41learn from their own outputs uh by
  88. 3:43filtering cleverly you can improve the
  89. 3:45models even further. Hence the class is
  90. 3:47called self-improving AI agents algorith
  91. 3:50uh class. Um and then the the amount of
  92. 3:53compute you invest in training the model
  93. 3:55on its own outputs can substitute for
  94. 3:57the model parameters. This also
  95. 3:59parallels some of the earlier efforts
  96. 4:01where the amount of compute uh used in
  97. 4:04training smaller models u if you could
  98. 4:06increase the amount of data has been
  99. 4:08shown to like help improve certain
  100. 4:10benchmarks. And then the third point is
  101. 4:12that when you're doing reinforcement
  102. 4:14learning as opposed to supervised
  103. 4:15learning, you have to really be careful
  104. 4:17about uh details of the implementation
  105. 4:20because as you scale up those
  106. 4:22algorithms, uh the small fixes can be
  107. 4:24extremely important. So the three
  108. 4:27paradigms that I'm talking about here
  109. 4:28are pre-training which is basically
  110. 4:30you're training the model on internet um
  111. 4:33that we have talked about in the first
  112. 4:35lecture and we're not covering that much
  113. 4:37in detail. And then the next technique
  114. 4:39would be that fine-tuning which is how
  115. 4:41you get your chatbots where you're
  116. 4:43basically perhaps fine-tuning or doing
  117. 4:45reinforcement learning with human
  118. 4:46feedback or RLif on uh preference data
  119. 4:50uh from humans and then the test time
  120. 4:52scaling which was some of the techniques
  121. 4:54that were covered uh in previous
  122. 4:56lectures. Those are more techniques
  123. 4:57where you're basically doing some sort
  124. 4:59of say majority voting or inference time
  125. 5:02sampling and then combining the outputs
  126. 5:04from the uh how you sample from the
  127. 5:06model. Um for example in homework one uh
  128. 5:09you are evaluating majority voting then
  129. 5:11you are evaluating some other techniques
  130. 5:14that u combine and evaluate the errors
  131. 5:17in what the model is producing and then
  132. 5:19using that to improve the model. So test
  133. 5:21time scaling is mostly inferencebased
  134. 5:23techniques. Now if you take what the
  135. 5:25model output filter after applying this
  136. 5:29test time scaling and then use that to
  137. 5:30fine-tune further that that's roughly
  138. 5:33what train time scaling is. So if you
  139. 5:34take nothing away from this entire
  140. 5:36lecture but you just remember this loop
  141. 5:38then you kind of have learned the basics
  142. 5:40of what train time scaling does.
  143. 5:43Questions?
  144. 5:47How do you um know like when what is
  145. 5:49like the good balance to distribute your
  146. 5:51compute into train time scaling versus
  147. 5:53test time scaling like
  148. 5:54>> is there like a flat flat like ROI curve
  149. 5:58that you reach at certain point after
  150. 6:00investing in train time I mean great
  151. 6:02question um let's hold that question
  152. 6:05until the third paper
  153. 6:08>> cool [clears throat]
  154. 6:09uh but definitely ask that question
  155. 6:10again
  156. 6:13um so roughly um what happened last year
  157. 6:15was that um what uh the reasoning model
  158. 6:19this is a graph on 01 and 01's accuracy
  159. 6:22on Amy uh on the it's passet one
  160. 6:24accuracy on the y-axis and then the
  161. 6:27amount of compute on x-axis and train
  162. 6:29time is shown on the x-axis on left
  163. 6:32graph and test time compute is shown on
  164. 6:34the x-axis on the right hand plot. So
  165. 6:38what is happening here is that as we are
  166. 6:40increasing the test time compute that we
  167. 6:41have already seen the passet one
  168. 6:43aggressive should go up. So we this is a
  169. 6:45log linear plot and so more inference
  170. 6:48time compute better passet one accuracy
  171. 6:51but what they're also showing is that if
  172. 6:52you can increase the train time compute
  173. 6:54then you can also improve passet one
  174. 6:56accuracy. So what Owen showed uh for Amy
  175. 6:59benchmark was that by increasing both
  176. 7:02the train time compute and the test time
  177. 7:05compute you are able to in improve the
  178. 7:07accuracy on the benchmark and um so it
  179. 7:10allows you for basically a circular loop
  180. 7:13where like you can generate model
  181. 7:15outputs and then feed them back to
  182. 7:17improve the model on this particular
  183. 7:18benchmark. Now why does this work? So
  184. 7:20math is a domain in which there is
  185. 7:22verifiability. So we had an whole
  186. 7:24lecture on robust verification. So you
  187. 7:26have the ability to know which outputs
  188. 7:28are correct and which ones are not
  189. 7:30correct. So you have some ability to
  190. 7:31actually choose the correct outputs that
  191. 7:33that can then feed into train time
  192. 7:35scaling. So this works better in domains
  193. 7:37where there is verifiability.
  194. 7:40So uh typically why doesing um start to
  195. 7:44help? Uh so this is a repeat of some of
  196. 7:46the slides but I think it's very
  197. 7:47important to remind folks that all the
  198. 7:50reasoning models in Osiris or or Gemini
  199. 7:53Gemini flash thinking or like valance in
  200. 7:55other uh frontier labs the basically
  201. 7:58reasoning allows us to solve for
  202. 8:00difficult problems because when you're
  203. 8:01solving a difficult problem you will not
  204. 8:03just spit out the output even in chain
  205. 8:05of thought and math problems when you
  206. 8:07were asking the model to think step by
  207. 8:08step it allowed certain amount of tokens
  208. 8:10to be dedicated to um uh spelling out
  209. 8:13the reasoning and step-by-step process.
  210. 8:15So, thinking models use a chain of
  211. 8:17thought where when they're attempting to
  212. 8:19solve the problem and what these tokens
  213. 8:21might get dedicated to is you will see
  214. 8:23patterns like problem analysis where
  215. 8:25they might actually try to understand
  216. 8:26what the problem is describing. Task
  217. 8:29decomposition. I'll show you an example
  218. 8:31of this but that will where they try to
  219. 8:33decompose the task into subtasks. Um
  220. 8:36self-evaluation they might actually try
  221. 8:38to look at the answer and then be like
  222. 8:41okay this is not looking correct. Uh so
  223. 8:43they might actually choose to uh
  224. 8:46backtrack and uh recognize their own
  225. 8:48mistakes and then backtrack to a
  226. 8:49previous step where they redo the
  227. 8:51problem and um they might uh try some
  228. 8:56kind of different approaches. So it's
  229. 8:57like a somewhat parallel search where
  230. 8:59they might actually try multiple
  231. 9:01approaches at the same time instead of
  232. 9:02if the current one is not leading to a
  233. 9:05solution. So it needs to have some sense
  234. 9:06of whether it's the correct solution or
  235. 9:08not. So here are some examples from um
  236. 9:12actually um earlier version of the model
  237. 9:14uh in 01 series. Uh so here the user is
  238. 9:17requesting a bash script uh where it
  239. 9:20wants to understand uh so it's
  240. 9:22requesting a bash script that will
  241. 9:23represent a string with the for with
  242. 9:25this format and print out the transpose
  243. 9:27in the same format. So it's taking a
  244. 9:29matrix and printing the transpose and uh
  245. 9:33what you see in the output is that the
  246. 9:36model first tries to understand what the
  247. 9:38user uh is asking in terms of input and
  248. 9:41output formats before it tries to solve
  249. 9:43the problem. So that's more of a problem
  250. 9:45analysis kind of pattern. Another
  251. 9:48example for the same problem you see is
  252. 9:50that it tries to decompose the problem.
  253. 9:52So it will actually once it understood
  254. 9:54the problem it's saying that the
  255. 9:55approach should involve maybe I should
  256. 9:57parse the input string then build the
  257. 9:59matrix transpose the matrix and then
  258. 10:01output the matrix in the same format. So
  259. 10:03it's breaking it into multiple steps.
  260. 10:05While for this particular problem this
  261. 10:07might be an overkill but in more complex
  262. 10:09problems this might be a better way to
  263. 10:11solve the problem because you've
  264. 10:12decomposed the problem into smaller
  265. 10:14steps. And then selfcorrection. So this
  266. 10:18is a different problem from chemistry
  267. 10:19where it's asking pH of uh some solution
  268. 10:22on a chemical and um the model starts to
  269. 10:26compute uh the pH value but then it um
  270. 10:30suddenly has this notion of weight the
  271. 10:32correct formula is different. So it
  272. 10:34basically goes and changes the formula
  273. 10:35that it was going to use. So even though
  274. 10:37it's pulling from the knowledge that the
  275. 10:39model already has it's actually um
  276. 10:42correcting itself. So it has the
  277. 10:43capability of selfcorrection.
  278. 10:46And how does this help the model? So as
  279. 10:48I was trying to explain before in
  280. 10:50domains where you have verification like
  281. 10:52computer programming or um data analysis
  282. 10:56or mathematical calculation the win rate
  283. 10:58over GPD40 which which was not a
  284. 11:01thinking model you'll see that it's
  285. 11:02greater than 50%. So uh certain domains
  286. 11:05benefit way more from uh the strain time
  287. 11:08scaling kind of techniques as opposed to
  288. 11:10if you look at personal writing or
  289. 11:12editing editing text there's not as much
  290. 11:14improvement in terms of win rate. Win
  291. 11:16rate means like if you were to give
  292. 11:17humans output from GPD40 versus thinking
  293. 11:20models um personal writing and editing
  294. 11:22text may not see as much gains but
  295. 11:24domains which have the ability to uh
  296. 11:27verify and close the loop see more
  297. 11:29gains.
  298. 11:30um questions.
  299. 11:40>> Mhm.
  300. 11:41So the train time
  301. 11:46to zero times it seems like performance
  302. 11:51is better than the train performance
  303. 11:54like on the right
  304. 11:56but on the left side that is low. So in
  305. 11:59this case it has performance actually
  306. 12:02better than performance.
  307. 12:04>> So in this particular plot it does look
  308. 12:06like that. Um
  309. 12:08>> but
  310. 12:10>> there is no intuition around these
  311. 12:11things as to like one should be better
  312. 12:13than the other. I think I mean you have
  313. 12:14to it this is one instantiation of where
  314. 12:17things were and I just wanted to show
  315. 12:19you the curve.
  316. 12:22>> Performance is better than performance.
  317. 12:24>> Mhm.
  318. 12:25>> Just mean some suspicious
  319. 12:27>> something suspicious going on. Okay.
  320. 12:29>> I I copy the plot so some their graphs
  321. 12:32are not always right as you might know
  322. 12:33from their latest release.
  323. 12:35>> Okay.
  324. 12:37>> [laughter]
  325. 12:39>> U okay so let's go back to the
  326. 12:41fundamentals right so what is it that
  327. 12:42we're trying to answer I think the
  328. 12:44fundamental question we're trying to
  329. 12:45answer is that in test time compute you
  330. 12:47can basically if you go back to this
  331. 12:49plot test time compute is very cheap for
  332. 12:52someone to put uh because you've trained
  333. 12:54a model and then you can go and do
  334. 12:56multiple inferences and if one of the
  335. 12:58answers is correct and you have a good
  336. 12:59verifier on your end then you can
  337. 13:02basically scale compute infinitely in
  338. 13:05fact I think next Friday uh I'll go
  339. 13:07through some papers including alpha code
  340. 13:09for example and what you'll find there
  341. 13:11is that if you can basically make make
  342. 13:14your search infinite in some ways then
  343. 13:16in test time you basically have a
  344. 13:18solution that will be correct because
  345. 13:19from test time scaling we do know that
  346. 13:22there is a correct solution if you
  347. 13:24repeatedly sample right um pain time
  348. 13:27scaling the challenge will be that you
  349. 13:28have to scale it correctly which we'll
  350. 13:30cover in this lecture and then the
  351. 13:32second bit is that there's a certain
  352. 13:34amount of this closed feed feedback loop
  353. 13:36has to have enough successes for the
  354. 13:38train time scaling to work well.
  355. 13:41So you will see that in the papers that
  356. 13:43I'll present now. So that plot is
  357. 13:46actually different the traditional
  358. 13:48machine learning will compare between
  359. 13:49the performance and test performance
  360. 13:51because that clause is showing it's
  361. 13:53actually more efficient if you boost the
  362. 13:55computer to the test because when
  363. 13:58computer increases the accuracy faster
  364. 14:02like given the same computer to test
  365. 14:05essentially you have better
  366. 14:07>> so uh so there is a caveat to what
  367. 14:09you're saying uh test time compute works
  368. 14:13well in benchmark marks where the
  369. 14:15verifiability is robust.
  370. 14:18Okay.
  371. 14:18>> Um otherwise you do need to get the
  372. 14:20model to start to reason better because
  373. 14:22you and and you need some verification
  374. 14:24loops. So both serve their uh I mean
  375. 14:27this is something we'll discuss in the
  376. 14:29lecture but both serve their goals. So
  377. 14:30like if you prefetch what I'll present
  378. 14:32by the end of the lecture. uh when you
  379. 14:35look at a pre-trained model what it is
  380. 14:37good at is it has certain level of
  381. 14:39capability in say solving mathematical
  382. 14:41problems and solving reasoning problems
  383. 14:43and reasoning about um finance or legal
  384. 14:46or whatever based on whatever domains it
  385. 14:48has seen already data in but then uh in
  386. 14:52inference time you're basically getting
  387. 14:53it to reason over multiple of these
  388. 14:55traces and then picking one if you know
  389. 14:57and have a good way to verify the
  390. 14:59solutions then you can like pick one of
  391. 15:01the solutions that's like saying I'm
  392. 15:03going to throw spaghetti at the wall and
  393. 15:04I know which where it should land. Um
  394. 15:07otherwise with train time scaling you
  395. 15:09can teach the model and boost the pass
  396. 15:11at one accuracy so that uh there's more
  397. 15:13likelihood that will emit the correct
  398. 15:15output but you still need verification
  399. 15:18of the loop.
  400. 15:20More questions?
  401. 15:24>> Yes. So, so when you're um fine-tuning
  402. 15:27the model to be able to solve difficult
  403. 15:29problems better, um does it
  404. 15:31[clears throat] have any regression on
  405. 15:33solving simpler problems? And if so, how
  406. 15:35do you get that?
  407. 15:37>> That one also needs to be let's let's
  408. 15:39keep those questions. I like all the
  409. 15:41reason all the questions, but we need to
  410. 15:43get to the first paper and then we can
  411. 15:45ask that one.
  412. 15:48Typically there shouldn't be a
  413. 15:50regression on solving um uh difficult uh
  414. 15:53easy problems if you're solving
  415. 15:54difficult problems unless you basically
  416. 15:56go into like reasoning chains that are
  417. 15:58completely um broken in some ways. So
  418. 16:01repetitive reasoning chains
  419. 16:03that which is called as overthinking.
  420. 16:08So uh so let's cover the first paper
  421. 16:10first where we are basically teaching
  422. 16:12the model how to reason. Um so we are
  423. 16:15boosting the reasoning capability of the
  424. 16:17model with reasoning chains.
  425. 16:20So let's take a uh let's take a look at
  426. 16:23um how we can do that. So we already
  427. 16:25covered this earlier and uh we showed
  428. 16:28this in the first lecture. So chain of
  429. 16:30thought in uh large language models
  430. 16:32provides both interpretability and if
  431. 16:34you ask the model to show its uh work
  432. 16:36step by step then provides boosts
  433. 16:38mathematical reasoning and we saw
  434. 16:40several benchmarks common sense
  435. 16:42reasoning and so on. So we want to
  436. 16:44basically get the model to have strong
  437. 16:46step-by-step reasoning capabilities u
  438. 16:49along solving any problem. Uh what is
  439. 16:52what is challenging with existing
  440. 16:54approaches if you were to like try to
  441. 16:56get this in existing approaches. So no
  442. 16:57internet scale data has really reasoning
  443. 16:59steps. Most of the time there are very
  444. 17:01few internet sources that have the large
  445. 17:03scale reasoning steps. And then if you
  446. 17:05try to manually annotate reasoning steps
  447. 17:07that's very expensive because you
  448. 17:09literally need humans to annotate those
  449. 17:11reasoning steps. And if you try to
  450. 17:13automate this process of like generating
  451. 17:16reasoning on based on known solution
  452. 17:18patterns then that also uh works only in
  453. 17:21very very specific domains. Uh and then
  454. 17:24if you try to few short prompt, few
  455. 17:26short prompting means like if you give
  456. 17:27it a few examples of like here's a
  457. 17:29problem, here is a reasoning chain, here
  458. 17:31is an answer, then that still
  459. 17:33underperforms uh models that can be
  460. 17:36fine-tuned on just larger data sets. So
  461. 17:38basically um small amount of uh
  462. 17:41reasoning examples don't quite cut it
  463. 17:43and you can just have a larger data set
  464. 17:44without reasoning chains. So the the key
  465. 17:48insight that star has is a very is very
  466. 17:51simple. first thing. So this is a very
  467. 17:54simple example like it will start with a
  468. 17:56small number of of examples that is
  469. 17:57reasoning [snorts] steps. It will
  470. 17:59generate solutions. So say 10k problems.
  471. 18:02Uh 10k is a representative number and
  472. 18:05then it will only keep the ones that
  473. 18:06have correct answers. Uh but it will
  474. 18:08generate these uh problems with rational
  475. 18:11and it can fine-tune on those and it can
  476. 18:13repeat. So it can repeat this loop. So
  477. 18:14this what's new here compared to what we
  478. 18:17were doing in test time scaling is it's
  479. 18:18only keeping the ones that have correct
  480. 18:20answers. Now why did it not produce
  481. 18:23correct answers on the other ones and
  482. 18:24what can we do with those particular set
  483. 18:26of examples? So that's the other
  484. 18:28interesting bit. So in certain problems
  485. 18:30where it could not solve the problem the
  486. 18:32model got stuck. So what we want to do
  487. 18:34is we basically
  488. 18:36if we just fine-tune on the correct
  489. 18:38examples the model is not able to learn
  490. 18:40new how to solve new problems. Let me
  491. 18:43cover this slide and then we can come
  492. 18:44back. U so there's basically no no
  493. 18:46signal. So what we do is we give the
  494. 18:49model the answer and ask it to explain
  495. 18:51backwards. So it's almost like I have
  496. 18:53this question. I asked the model to
  497. 18:55produce the answer but now the model did
  498. 18:57not produce the correct answer. So I
  499. 18:58give the model the answer and then I ask
  500. 19:00you to produce the rational. So for
  501. 19:01example the answer is 42. The human says
  502. 19:04and then the model generates the
  503. 19:06reasoning and then you can fine-tune the
  504. 19:08model on again the problem rational and
  505. 19:12the answer but don't show it the hint um
  506. 19:14as if it was solved directly. So this
  507. 19:16helps you expand the training set to
  508. 19:18include more difficult problems now. So
  509. 19:21uh basically it allows you to bootstrap
  510. 19:23the reasoning capabilities u and not
  511. 19:26just say limit it to u easy problems
  512. 19:28that the model could solve earlier but
  513. 19:30like now you can bootstrap iteratively.
  514. 19:32So you basically generate reasoning
  515. 19:34attempts you learn from successful
  516. 19:36reasoning paths where the quality of the
  517. 19:37reasoning paths is entirely based on uh
  518. 19:40things being correct. And for failed uh
  519. 19:42attempts uh you're basically
  520. 19:44rationalizing them by saying okay here
  521. 19:46is a hint uh please generate the
  522. 19:48rationale and then you're using these
  523. 19:50generated rationals as the training
  524. 19:51data. So that's basically the algorithm
  525. 19:53that they use in star. It's a very bare
  526. 19:56bones and like you you can almost call
  527. 19:58it an off policy reinforcement learning
  528. 20:00technique. It's a very bare bones way of
  529. 20:02producing uh reasoning techniques in a
  530. 20:05model.
  531. 20:07And the assumption that is being made in
  532. 20:09this particular case is that how do you
  533. 20:12know something is a good rationale?
  534. 20:13They're assuming that if the model
  535. 20:15output is correct, which in math uh they
  536. 20:17found that that was generally true, the
  537. 20:19correctness of the final output is a
  538. 20:21proxy for the reasoning quality. And so
  539. 20:23they're filtering incorrect answers.
  540. 20:25Basically, they're assuming that um that
  541. 20:27will be filtering out lower quality
  542. 20:29reasoning chains, but there might be
  543. 20:31scenarios where they um they're not
  544. 20:34learning from incorrect reasoning chains
  545. 20:35as a result.
  546. 20:37and but they get higher quality training
  547. 20:39data. And then the second bit is that
  548. 20:41they assume that the uh language model
  549. 20:43can generate valid reasoning paths when
  550. 20:46it's given the answer as a hint. So it
  551. 20:48kind of assumes that if I show show the
  552. 20:50model the answer and then ask it to show
  553. 20:51its work, it will be able to do so. And
  554. 20:54then finally um there's some amount of
  555. 20:57assumption that the initial language
  556. 20:58model is strong enough to uh bootstrap
  557. 21:00from few short examples. So if the class
  558. 21:03of problems is way outside the
  559. 21:04capability of the initial language model
  560. 21:06then it will not make much progress on
  561. 21:09this and this is where the iterative
  562. 21:11aspect starts to become important. I was
  563. 21:13seeing a couple of hands. So let's take
  564. 21:15them one by one.
  565. 21:16>> Um yeah I was just wondering so do they
  566. 21:19start with like a math data set that has
  567. 21:22like the correct answer and just doesn't
  568. 21:24have reasoning right like that's how
  569. 21:26they know what the correct answer is.
  570. 21:28>> Yes.
  571. 21:28>> Okay. Cuz I was like how do they know
  572. 21:30the correct answer? Yeah, everyone is
  573. 21:32starting with a benchmark basically.
  574. 21:34Yes.
  575. 21:35>> Is there filtering that happens for step
  576. 21:37three? Uh like are we worried that we
  577. 21:41give like the correct solution and then
  578. 21:43there's like issues in the reasoning
  579. 21:44just to like get to the solution?
  580. 21:46>> So they actually don't filter in step
  581. 21:47three but there are follow on papers
  582. 21:49that do filter in step three. Uh I mean
  583. 21:52you can do some sort of process reward
  584. 21:54model on top of the reasoning chains and
  585. 21:55then say which of the steps make sense
  586. 21:57or which of the steps don't make sense.
  587. 21:59But this particular paper was one of the
  588. 22:01first. I mean one of the attempts of
  589. 22:03this class is to show you papers as they
  590. 22:05evolved as opposed to like what's the
  591. 22:08latest paper here. But yes, you can um
  592. 22:11that might be another project idea of
  593. 22:14like how do you evaluate the quality of
  594. 22:15the reasoning chains if you don't want
  595. 22:16to depend on just the final outcome as
  596. 22:18the proxy [snorts] for correctness.
  597. 22:23>> Yes. What if you problem
  598. 22:26if you tell it fails as a parent even if
  599. 22:30you tell the model the answer has been
  600. 22:34not because it's just too complicated to
  601. 22:39>> that's a great question. So uh
  602. 22:41>> as as I told you in step four uh the
  603. 22:44assumption is being made that the the
  604. 22:46benchmark on which this is being done is
  605. 22:50essentially uh where the problem is not
  606. 22:53too difficult. It is within range or
  607. 22:55some subset of the problems are within
  608. 22:57range of the language model. Um and
  609. 23:00typically you can uh
  610. 23:03so so that that that is an assumption
  611. 23:05that is made and then when you do
  612. 23:07iteratively the model might get better
  613. 23:08at certain point that it can start
  614. 23:10handling these other problems.
  615. 23:16So in the key like very should negative
  616. 23:19sound this means that
  617. 23:22you
  618. 23:24so I'm just wondering is there
  619. 23:26possibility that you you know from the
  620. 23:28step two you know works well and if the
  621. 23:31step three doesn't work and you just use
  622. 23:33the step two positive step three
  623. 23:38>> um so so
  624. 23:42that's a great point let's come back to
  625. 23:44that one so I think what I'll show you
  626. 23:46by the end of the lecture is that
  627. 23:47learning from negative examples has not
  628. 23:49been nailed. Learning from positive
  629. 23:51examples has been like if you have any
  630. 23:53non-zero reward then you have an ability
  631. 23:55to close the RL loop which is not happen
  632. 23:57uh close the reinforcement learning loop
  633. 23:59which is not happening yet in this
  634. 24:01particular set of examples. So you do
  635. 24:03need to be able to close the loop in
  636. 24:06some way.
  637. 24:07So if if you have negative examples
  638. 24:10there are some papers that have tried to
  639. 24:12learn from it but like that's not
  640. 24:13something we'll cover today.
  641. 24:16Yes,
  642. 24:17>> I have a similar question like um how to
  643. 24:20evaluate or verify quality of the
  644. 24:22generated red nails on fail on this
  645. 24:25fails after giving the hints like since
  646. 24:29already know the answer but um it might
  647. 24:32it might generate like a incorrect
  648. 24:35reasoning that leads to
  649. 24:38>> so that's a great problem to like uh so
  650. 24:40you're saying that in step two it might
  651. 24:42or in step three it might generate wrong
  652. 24:44rationals is what you're saying then it
  653. 24:47will learn wrong wrong wrong reasoning
  654. 24:50from correct attempts yes that will be a
  655. 24:52problem in this particular case they're
  656. 24:54not they don't have any further uh
  657. 24:57filtering on top of uh rationals
  658. 25:01so there will be no way to hill climb in
  659. 25:02that case
  660. 25:04you can have humans look at the
  661. 25:06reasoning chain
  662. 25:08>> tedious
  663. 25:08>> it could be tedious yes
  664. 25:13okay So uh going through this in a
  665. 25:16little bit more uh rigorous detail. So
  666. 25:17you start with a prompt data set where
  667. 25:19you have the questions the ration and
  668. 25:21the answers. This uh prompt data set
  669. 25:23will be small and uh compared to um the
  670. 25:27amount of data that we want to train on.
  671. 25:29For example, this is the multiple choice
  672. 25:31questions um where do you put your
  673. 25:33grapes just before checking out there's
  674. 25:34a rationale and then the correct answer
  675. 25:36is uh for example B which is grocery
  676. 25:38cart. Now you have a training data set
  677. 25:41which is quite large uh of examples that
  678. 25:44have questions and answers. This would
  679. 25:45be uh say if you have a benchmark you
  680. 25:47might have a train subset of the
  681. 25:49benchmark and test subset of the
  682. 25:51benchmark and what vanilla star will do
  683. 25:54is it will start with this rational data
  684. 25:56set and training data set. So it will
  685. 25:58first few short prompt the model with uh
  686. 26:00the rationals in the rational data set
  687. 26:02and then it will get the model to um
  688. 26:05produce the rationals and the correct
  689. 26:07output and then uh so this is on the
  690. 26:10training data set. So now it's few short
  691. 26:11prompting but it's supplying um pro
  692. 26:14problems questions uh from the training
  693. 26:16data set and it's checking if the
  694. 26:18answers are correct by the language
  695. 26:19model and it will collect these set of
  696. 26:22uh rationals that it can use if they uh
  697. 26:25and then it can fine-tune the language
  698. 26:27model on these correct solutions. If you
  699. 26:29have uh rationalization which is what
  700. 26:32star uh does if the answer is incorrect
  701. 26:36what you will do is you will add hint.
  702. 26:37So you'll be saying okay here is the
  703. 26:39correct answer and you will essentially
  704. 26:42generate the rationale by looking at
  705. 26:44this hint and then you you will use that
  706. 26:46to to add to that data set of rationals
  707. 26:49that led to the correct answer and then
  708. 26:50you can fine-tune on top of that
  709. 26:52language model and um so you basically
  710. 26:55have these two sets of rationals that
  711. 26:57then you can fine-tune on top of this
  712. 26:59language model and you can do this
  713. 27:00process iteratively. So you don't like
  714. 27:02do it just once you fine-tune it. Now
  715. 27:05the language model perhaps is able to
  716. 27:06produce better reasoning chains. So now
  717. 27:08you can again start with your training
  718. 27:10data set and uh whatever was not correct
  719. 27:12you can redo this process. So their
  720. 27:16experiments were on a small model which
  721. 27:17is an open- source uh of GPD3 a six
  722. 27:20billion parameter model called GPDJ.
  723. 27:22they had a pretty small warm-up uh and
  724. 27:24then they kept a constant learning rate
  725. 27:26and then they basically had certain
  726. 27:28number of iterations of the outer loop
  727. 27:30and then they increased uh the inner
  728. 27:32loop the number of steps in the inner
  729. 27:34loop on each step. So one of the
  730. 27:36comments the paper makes is that they
  731. 27:38want to start the they want to have a
  732. 27:41slower start in the training time and
  733. 27:42then they want to slowly increase uh the
  734. 27:45number of u things that are happening in
  735. 27:47the inner loop.
  736. 27:49The data sets that they tried this on
  737. 27:50was GSM 8K. U so GSM 8K is just uh math
  738. 27:55problems that you have seen where you're
  739. 27:57basically asking these are grade school
  740. 27:58math problems. There are about 9K
  741. 28:00samples. Then common sense QA. Common
  742. 28:02sense QA is essentially uh problems that
  743. 28:05would you would see on say related to
  744. 28:08day-to-day stuff. So you will have these
  745. 28:10multiple choice questions and then you
  746. 28:12have these answers and there's
  747. 28:13rationalization that looks like this.
  748. 28:15and then arithmetic problems which
  749. 28:17basically was some sort of an addition
  750. 28:18problem on multi-digit addition.
  751. 28:22So they generated the last one was uh
  752. 28:24synthetic data where they randomly uh
  753. 28:26like they generated some of these uh
  754. 28:28things themselves.
  755. 28:30So in terms of results uh some of the
  756. 28:33results that stood out in this paper was
  757. 28:35that just compared to say supervised
  758. 28:37fine-tuning on say math benchmark they
  759. 28:39could boost uh with this uh star
  760. 28:42approach to 51.7 but they only used like
  761. 28:4570 to 87% of the data in terms of like
  762. 28:48uh so they had to throw out a whole
  763. 28:49bunch of data that didn't did not have
  764. 28:51correct solutions and um other challenge
  765. 28:55is that it's not really true RL so if
  766. 28:57you basically do multiple iterations of
  767. 28:59this it starts to plateau after a while.
  768. 29:01So uh I mean RL has its own set of
  769. 29:05challenges but here it also starts to
  770. 29:07plateau. So you have to really pay
  771. 29:09attention to um how many iterations you
  772. 29:11can do and there's some amount of
  773. 29:13tweaking there that you have to do. Uh
  774. 29:16the other interesting set of results
  775. 29:17here were that um this was on common
  776. 29:21sense reasoning. So so they actually
  777. 29:22looked at um this was a question that
  778. 29:25several folks asked here. They actually
  779. 29:27tried to see the rationals for common
  780. 29:29sense QA. They showed it to human
  781. 29:32raiders and they asked human raiders to
  782. 29:34say how likely they are to um prefer the
  783. 29:38rationals from star versus like uh just
  784. 29:41like uh otherwise. So star generated
  785. 29:44rationals versus the few short rationals
  786. 29:46in the the the rational data set. uh
  787. 29:49they compared those and what they found
  788. 29:51was that um generally the qualitative
  789. 29:54analysis showed that their rationals
  790. 29:57were pretty reasonable. Now common sense
  791. 29:58QA as you remember is a natural language
  792. 30:01um like it's tackling daily problems
  793. 30:04here. So as a result of that um this
  794. 30:06these seemed the rational seemed pretty
  795. 30:08reasonable and then the other aspect
  796. 30:11that they noticed was that uh star in
  797. 30:13general requires like if you use direct
  798. 30:16finetuning you you basically do get a
  799. 30:18certain level of accuracy but star with
  800. 30:20rationalization gets that accuracy but
  801. 30:22it does not require that same like it
  802. 30:25requires much less data compared to what
  803. 30:26you would need for fine-tuning. So
  804. 30:28rationalization helps you uh get to an
  805. 30:31accuracy without um using like so 86% of
  806. 30:35the data is used but you can basically
  807. 30:37get to uh the deficit accuracy of 72.5%
  808. 30:40compared to like using a lot of training
  809. 30:42data. So this was a very small model. So
  810. 30:45this was first science of life that was
  811. 30:46shown for reasoning. U in terms of
  812. 30:49mathematical reasoning this was an
  813. 30:51interesting uh one on GSM8K. What they
  814. 30:53found was that the use of
  815. 30:54rationalization actually did not improve
  816. 30:56performance. So like star by itself was
  817. 30:58not helping in this particular case. Uh
  818. 31:01so what you see is that you have uh GPDJ
  819. 31:05like basically it improves of the
  820. 31:07baselines but it's basically not helping
  821. 31:09too much. Uh if you directly do
  822. 31:12fine-tuning on good data then you can
  823. 31:15actually improve it similarly. So one of
  824. 31:17the reasons that is the case is the
  825. 31:19number of calculation steps that were
  826. 31:20used uh by the model themselves. if you
  827. 31:23force the model to use chain of thought
  828. 31:25versus you provide these rationalization
  829. 31:27steps is actually pretty similar. So in
  830. 31:30in some ways uh it was not helping if
  831. 31:32the problem is too simple like the whole
  832. 31:35notion of like getting the model to
  833. 31:36reason if the model if the problem is
  834. 31:39too simple was basically not helping. So
  835. 31:40GSM8K for GPD40 was very much within
  836. 31:43capability. So um similarly for GPDJ so
  837. 31:47there was not much improvement here
  838. 31:49relative to but it did show that direct
  839. 31:51fine-tune versus star with
  840. 31:52rationalization you still had some
  841. 31:54gains.
  842. 31:56Okay, so some takeaways here are that um
  843. 32:00the whole notion of rationalization
  844. 32:02conditions on the fact that you have an
  845. 32:04answer and then you can essentially
  846. 32:05figure out what rationals would would be
  847. 32:08good and um the outputs without
  848. 32:11rationalization are examples where the
  849. 32:13model is already quite confident but
  850. 32:16then uh the model is not yet but if you
  851. 32:18can look at the answer then in certain
  852. 32:20cases it might actually do a better job
  853. 32:22producing the rationale and if you do
  854. 32:25few short prompting you can basically
  855. 32:27really help the model um in how it
  856. 32:30should produce rational but um the style
  857. 32:34of rational might actually influence the
  858. 32:36model in certain ways. So you you do
  859. 32:38have to like prompt engineering in this
  860. 32:40particular case might might bias the
  861. 32:42model in certain ways. So effectively
  862. 32:44there are certain challenges. One
  863. 32:46challenge is that um the rationalization
  864. 32:49the quality has certain amount of
  865. 32:51effects and the second bit is that if
  866. 32:53you're few short prompting then you are
  867. 32:54biased by how the rationals were
  868. 32:56formatted in your uh few short prompts
  869. 32:59and and that might affect what kind of
  870. 33:01rationals the model will produce and
  871. 33:04what you're training on. So overall I
  872. 33:07think uh this kind of gives us a sense
  873. 33:09of just that in the in the uh model
  874. 33:12space if you basically bootstrap the
  875. 33:14model to generate rationals you can get
  876. 33:16high sample efficiency while not having
  877. 33:18to get humans to generate these uh
  878. 33:20reasoning chains and you can apply it to
  879. 33:22many problems like you can apply it to
  880. 33:24symbolic problems natural language
  881. 33:26mathematical reasoning. The some of the
  882. 33:28challenges that are there in this
  883. 33:30overall techniques is that you don't
  884. 33:32have a very good evaluation for ration
  885. 33:35uh for most tasks because you basically
  886. 33:37have to have a human evaluate them or
  887. 33:39you need some sort of a process reward
  888. 33:41model to evaluate them. Uh there might
  889. 33:43be u true negatives and false positives.
  890. 33:46So you are just filtering based on
  891. 33:48correct answers. So you might have some
  892. 33:49invalid steps in between which might
  893. 33:51cause problems. Yes. So, so this
  894. 33:56uh method is is useful for models,
  895. 34:00right? Because if if you are if you are
  896. 34:03if you want to fine a small language
  897. 34:05model, you can just use a front model to
  898. 34:08generate these training, right?
  899. 34:11>> Oh, I don't know how to answer that
  900. 34:13question.
  901. 34:14>> So, so you don't have to rely on on on a
  902. 34:17small model to generate you this uh new
  903. 34:21additional data automatically. you can
  904. 34:23just use a big model and it can train
  905. 34:26stuff but I'm wondering that the the the
  906. 34:28main benefit I mean you are actually
  907. 34:31getting
  908. 34:32>> getting training out from nothing
  909. 34:34>> what is is is shows when you are
  910. 34:36training something which is basically
  911. 34:38the following
  912. 34:40>> yes so the the goal for a lot of the
  913. 34:43work that we're discussing is the
  914. 34:45ability to I mean we're showing um the
  915. 34:49solutions on small models but at the end
  916. 34:51of the day what we wanted to want to be
  917. 34:54able to do is take the model, take its
  918. 34:56outputs and then use that to improve the
  919. 34:57model. Um, you can always take a more
  920. 35:00powerful model and use it outputs and
  921. 35:01that's like distillation process. Um,
  922. 35:05>> yeah, that's that's clear. I I mean the
  923. 35:07the theory
  924. 35:09attempt is clear but I mean when it
  925. 35:11comes to practical application
  926. 35:12>> yes
  927. 35:13>> so so I will I will use this method when
  928. 35:16I'm at opening I learn topic and I'm
  929. 35:19training the next
  930. 35:21one
  931. 35:24parameter model and I need additional
  932. 35:26data view what I have
  933. 35:29>> that that's a fair point
  934. 35:32[snorts] um or or you want to basically
  935. 35:34uh improve the model on so instead
  936. 35:36capabilities that they they actually
  937. 35:38don't have they won't produce good model
  938. 35:39outcomes on.
  939. 35:42>> So so so what I mean is that so if if I
  940. 35:45want to improve their performance over 7
  941. 35:47billion
  942. 35:50>> in practice then I I wouldn't use this
  943. 35:52because I I get get high quality data
  944. 35:56from
  945. 35:57>> from this
  946. 35:59is much easier.
  947. 36:00>> We are not covering this relation but
  948. 36:02that's fair point. Okay, thank you. Just
  949. 36:04>> uh No, that's a fair point that you can
  950. 36:06use one of the frontier models in distal
  951. 36:08things, but this is more an attempt to
  952. 36:11uh build it from scratch and for you
  953. 36:13folks to understand what might that
  954. 36:15take.
  955. 36:16>> Yes,
  956. 36:18>> question. I'm curious why this isn't
  957. 36:21like full-fledged RL and also um whether
  958. 36:24>> you're leading me to my next slide.
  959. 36:26>> Okay, great. Oh, and also um I I'm also
  960. 36:29curious uh so like when you would decide
  961. 36:32to make the choice of to post train with
  962. 36:35SFT versus RL and if there's any
  963. 36:37different implications of how much data
  964. 36:39or compute is needed.
  965. 36:42>> Um hold that question until the end
  966. 36:45[laughter]
  967. 36:46but I'm covering that that's that's part
  968. 36:48of the lecture.
  969. 36:50Uh so just uh just to cover so in star
  970. 36:54you basically were just using the
  971. 36:56correct uh output which is like a proxy
  972. 36:58for a verifier where like you already
  973. 37:00know the answer. If you basically also
  974. 37:03add a verifier in that whole loop then
  975. 37:06that would be called var. So there was a
  976. 37:07paper that basically had a generator and
  977. 37:10a verifier training in a loop. And then
  978. 37:12quietar was essentially adding an
  979. 37:14internal thinking. So what it was doing
  980. 37:16was essentially instead of having uh
  981. 37:19reasoning steps be in the language
  982. 37:21space, it was actually uh putting
  983. 37:23reasoning steps in the latent space uh
  984. 37:24with um MLPS. So why have them in
  985. 37:28English when you can have them have the
  986. 37:30model thinking internally?
  987. 37:34So before I move further actually there
  988. 37:36have been a lot of questions. I'll only
  989. 37:38pick one of these questions but um
  990. 37:41let's look at question two. What what is
  991. 37:44uh what what bounds the performance of
  992. 37:46star as an approach?
  993. 37:53You can talk to someone for a minute and
  994. 37:55then let's chat as a class.
  995. 38:02>> Let's come on back as a class.
  996. 38:04>> So what performance like what bounds the
  997. 38:06performance of star as a technique that
  998. 38:10multiplication of choice helps
  999. 38:18I'm seeing no hands. You guys are
  1000. 38:20talking. All answers are welcome.
  1001. 38:27>> Yes.
  1002. 38:27>> I think this is kind of like a silly
  1003. 38:29like answer right here. We were thinking
  1004. 38:30like um there are some logical steps
  1005. 38:33that are kind of more complex than
  1006. 38:35others and you wouldn't expect star to
  1007. 38:36be able to make any logical leaps that
  1008. 38:38are not in its training data set, right?
  1009. 38:41like the rationalization
  1010. 38:43should all kind of be of the same level
  1011. 38:45as what it was dreamed of just this
  1012. 38:47allows it to get like you know more
  1013. 38:50rational rationalization data
  1014. 38:52>> okay okay so it will not make I I mean
  1015. 38:56it will basically not have a logical
  1016. 38:58leap into say new domain that will have
  1017. 39:00figured out new things is what you're
  1018. 39:01saying okay
  1019. 39:04any other takers
  1020. 39:10>> um absolutely
  1021. 39:11You care about new things. So you can't
  1022. 39:13really model to to do likeation
  1023. 39:17because like if the model is really bad
  1024. 39:20at like creating new
  1025. 39:22reasoning introduce wrong samples into
  1026. 39:25the training and like
  1027. 39:30>> say that loudly what you're saying.
  1028. 39:33>> Yeah. So we testing like this
  1029. 39:35performance is improved by the um by
  1030. 39:39model's capability to do reasoning
  1031. 39:41because
  1032. 39:41>> I see
  1033. 39:42>> yeah because
  1034. 39:43>> if the model can't reason even given the
  1035. 39:45hints that's also not going to work out
  1036. 39:48because the rationalization won't show
  1037. 39:49up at all. [snorts]
  1038. 39:50>> Yeah wrong samples
  1039. 39:54>> that that opens the question what leads
  1040. 39:56to reasoning
  1041. 39:59>> in the base model. I I think some some
  1042. 40:02answers make it inherently easier to um
  1043. 40:04rationalize than others. For example, if
  1044. 40:06the final answer is like 225, you
  1045. 40:08probably know that at some point.
  1046. 40:10There's like the multiplication of 15
  1047. 40:11and 15 or something similar to that. But
  1048. 40:13maybe some other numbers are not as
  1049. 40:15straightforward. And I also think that
  1050. 40:17um if there's a lot of a lot of problems
  1051. 40:20that you don't know the answer to and
  1052. 40:21that forces you to rationalize, then it
  1053. 40:23probably um you probably need more data
  1054. 40:25so that you can form more generalized
  1055. 40:26reasoning to backtrack.
  1056. 40:28>> Okay.
  1057. 40:30and that that is in the right direction.
  1058. 40:32Yes.
  1059. 40:35Okay. I think all of these answers are
  1060. 40:38fairly valid, but I think this is worth
  1061. 40:39keeping in the back of your mind as we
  1062. 40:41move into RL because a lot of the magic
  1063. 40:43in this particular domain is like what
  1064. 40:45can the base model do as we're building
  1065. 40:48on top of that.
  1066. 40:50Um so we'll we'll come back to that.
  1067. 40:53Okay. So the second paper that we'll
  1068. 40:55cover is deepseek math uh that will
  1069. 40:57focus on mathematical reasoning uh and
  1070. 41:00it will actually use a form of RL that
  1071. 41:02it proposed that has become quite
  1072. 41:04popular. So we already looked at this
  1073. 41:06graph earlier where we were basically
  1074. 41:08showing that in math domain if you do
  1075. 41:09train time scaling you can do much
  1076. 41:11better and okay um so what this slide is
  1077. 41:16showing is that if you look at the
  1078. 41:18performance so this is a earlier
  1079. 41:20benchmark than Amy it's actually a
  1080. 41:21simpler benchmark than Amy it's called
  1081. 41:23math uh benchmark and you're basically
  1082. 41:25looking at top at one accuracy so if you
  1083. 41:28look at the date of the benchmark you'll
  1084. 41:30see that as the model sizes increased
  1085. 41:31typically the accuracy on this benchmark
  1086. 41:34has gone up. But then suddenly when
  1087. 41:35Deepse seek math came out, a 7B model
  1088. 41:38was doing really well. Um and the main
  1089. 41:40leap that they made was that they were
  1090. 41:42able to do the reinforcement learning
  1091. 41:44part with this in the train time scaling
  1092. 41:46loop correctly. So we will see what led
  1093. 41:49to that uh innovation. So the first
  1094. 41:52thing that they got right was that
  1095. 41:53typically when you try to improve on
  1096. 41:56math and this was something that was
  1097. 41:57done on top of palm as a paper palm
  1098. 42:00model. Uh there was this paper paper
  1099. 42:02called minurva which improved palm model
  1100. 42:05on stem and what what they did was they
  1101. 42:07trained on a lot of science and math
  1102. 42:08data typically like archive data. What
  1103. 42:11deepseek did was it was like okay
  1104. 42:13actually training on archive papers is
  1105. 42:16not the trick. they actually trained on
  1106. 42:18common crawl web pages but they started
  1107. 42:20uh with a deep sea coder model. So they
  1108. 42:22said that if you start with a model that
  1109. 42:24has already been uh improved on code
  1110. 42:27reasoning that it will actually do
  1111. 42:29better and then they did a really good
  1112. 42:30job at
  1113. 42:32um curating from content from common
  1114. 42:35crawl pages on math and they found that
  1115. 42:38often archive papers in some ways don't
  1116. 42:41have adequate amount of uh math content
  1117. 42:43that would cover give us coverage. So,
  1118. 42:46open web math uh by curating that and
  1119. 42:48and mining it, they were able to
  1120. 42:50actually and and getting better coverage
  1121. 42:53across math domains, they were actually
  1122. 42:54able to get much larger yield in number
  1123. 42:57of tokens. And that was their first um
  1124. 43:00first exercise in like priming the model
  1125. 43:03before they take it to RL. So, this was
  1126. 43:05related to one of the comments that were
  1127. 43:07made that if the model is not strong in
  1128. 43:09a certain domain, you do have to improve
  1129. 43:11its capability in that domain. So, this
  1130. 43:12is that step. Um so they basically got
  1131. 43:15coverage across a lot of math domains
  1132. 43:17showed it a lot of high quality data in
  1133. 43:18math and they started from a code uh
  1134. 43:21code pre-trained model and so they
  1135. 43:24actually showed that archive training
  1136. 43:26was actually not really helping but code
  1137. 43:28to math significantly helped uh because
  1138. 43:31it allowed the model to reason better do
  1139. 43:33tool use better. This was actually the
  1140. 43:35first time that um uh this was shown
  1141. 43:37that like a model if you start from a
  1142. 43:39coding based model you could do better.
  1143. 43:41And then the other thing that they
  1144. 43:42showed was that um the curation of data
  1145. 43:45really helped in this particular case.
  1146. 43:48Now the second step that they did was
  1147. 43:50okay now that you have um this um like
  1148. 43:54you've trained the model on math using
  1149. 43:56supervised fine tuning what do you do
  1150. 43:58next? So they actually scale up their
  1151. 44:00RL. Now the typical RL algorithm that
  1152. 44:03has been used in RL for human feedback
  1153. 44:05even with verifiers is called PO. So you
  1154. 44:08have to keep your policy and your new
  1155. 44:10policy. So you basically this ends up
  1156. 44:12being a memory problem if you try to do
  1157. 44:14it on larger models. A 7B model is fine
  1158. 44:16but if you try to scale up uh RL you
  1159. 44:19have to keep multiple policy models and
  1160. 44:21then you also have to learn a critic
  1161. 44:22model and a reward model. So typically
  1162. 44:25in the RL loop you have an old policy a
  1163. 44:27new policy that you're learning. uh you
  1164. 44:30have a critic that's basically giving
  1165. 44:32feedback and then you have a reward
  1166. 44:33model that's assigning the rewards. So
  1167. 44:35keeping all four of the copies of models
  1168. 44:37starts to become challenging. So what
  1169. 44:39they did was they proposed a new
  1170. 44:40technique called GRPO where instead of
  1171. 44:43uh having a critic or a value function
  1172. 44:45estimate uh things they basically used
  1173. 44:49some sort of a generalized um advantage
  1174. 44:51estimation that I'll show you in the
  1175. 44:52next slide and then you only have three
  1176. 44:55copies of the model. So now the PO which
  1177. 44:58needed a lot more memory instead of that
  1178. 45:00GRPO essentially could use just a group
  1179. 45:02for the baseline and and the way that
  1180. 45:05works is that for each question you
  1181. 45:07sample a lot of the answers and then you
  1182. 45:11score them and you normalize the reward
  1183. 45:14of so this is the score that you gave
  1184. 45:16for each of the answers using the reward
  1185. 45:17model and then you normalize the reward
  1186. 45:19as reward minus mean of rewards divided
  1187. 45:21by standard deviation and then this
  1188. 45:23becomes your advantage basically. So
  1189. 45:25typically if you look at u the way DPO
  1190. 45:28works or all of those techniques works
  1191. 45:30you're basically going to compare the
  1192. 45:32rewards. So by doing a reward minus mean
  1193. 45:35of rewards divided by standard deviation
  1194. 45:37you're effectively providing a
  1195. 45:38comparative technique across rewards
  1196. 45:43and uh the why so the reason this made
  1197. 45:46sense was because reward models are
  1198. 45:48going to essentially be trained on
  1199. 45:49comparison anyway. So by providing the
  1200. 45:51grip context you can save memory and now
  1201. 45:53you can start scaling up RL and your
  1202. 45:55advantage function in this particular
  1203. 45:57case essentially. So I I didn't add the
  1204. 46:00full formula because I just wanted you
  1205. 46:01guys to have intuition. You could just
  1206. 46:03like take the reward subtract the
  1207. 46:05average reward and then divide that by
  1208. 46:06the spread of rewards and you can get an
  1209. 46:08estimate of the advantage. And on math
  1210. 46:11they were able to go from 46.8 to 51.7.
  1211. 46:14And this was actually the first open
  1212. 46:15source model at 7B scale that crossed
  1213. 46:17like 50% without having a critic. Um
  1214. 46:20this is a much earlier paper but then
  1215. 46:22this gives you a sense of the technique
  1216. 46:24that they used and further what they
  1217. 46:27showed was that if you look at different
  1218. 46:28variants of RL effectively what you are
  1219. 46:31changing is either the data source. So I
  1220. 46:33showed you how they curated their data
  1221. 46:35and then you're deciding how to compute
  1222. 46:38the gradients. The gradient depends on
  1223. 46:40gradient coefficient and uh the
  1224. 46:42probability
  1225. 46:43of the output given the question. So the
  1226. 46:45gradient coefficient computation changes
  1227. 46:47in different algorithms. So their
  1228. 46:48estimate of gradient coefficient was
  1229. 46:51coming from this um group estimator
  1230. 46:54group baseline uh which worked well for
  1231. 46:56a single singlestep problem where you're
  1232. 46:58just trying to get the answer. So if you
  1233. 47:00compare uh approaches like star where
  1234. 47:03you basically are just generating uh
  1235. 47:06things once and if you uh you get
  1236. 47:08correct one you basically get a reward
  1237. 47:10of one if it's correct and zero if it's
  1238. 47:12wrong or if you do online rejection
  1239. 47:15fine-tuning you are still uh generating
  1240. 47:18things online but you only get a reward
  1241. 47:20of one if it's correct and zero if it's
  1242. 47:22wrong. So you basically reject anything
  1243. 47:23that is incorrect. GRPO is generating uh
  1244. 47:27rewards online with the reward model,
  1245. 47:29but it's basically getting an advantage
  1246. 47:31function because you're doing multiple
  1247. 47:33samples and then you're giving them a
  1248. 47:35score and then the the advantage for
  1249. 47:37that score comes from this uh group
  1250. 47:39baseline by computing the mean and then
  1251. 47:42dividing it by the spread of rewards. So
  1252. 47:44um now you can ask me the question that
  1253. 47:46you were asking me earlier about the
  1254. 47:48difficulty of the problems.
  1255. 47:50>> Oh the difficulty of the problem that I
  1256. 47:54make regression on sensor questions.
  1257. 47:56>> Yes. Yes. So I'm curious um um if you
  1258. 48:00are updating the updating the model with
  1259. 48:04with fine tuning for difficult questions
  1260. 48:07you are essentially um updating all the
  1261. 48:09weights. So isn't that going to
  1262. 48:10potentially theoretically have any um
  1263. 48:13regression on similar questions or other
  1264. 48:14metrics?
  1265. 48:16>> So this is this is a table I wanted to
  1266. 48:18show you. So effectively um if you're
  1267. 48:21basically trying to close the loop, what
  1268. 48:22you're trying to figure out is how much
  1269. 48:24reward you're giving. So simple problems
  1270. 48:26effectively might uh equate to you're
  1271. 48:29going to get a reward of one anyways and
  1272. 48:30you're like never getting a reward of
  1273. 48:32zero. um and in with GRPO you're getting
  1274. 48:35some form of a distribution of rewards
  1275. 48:38um that I was showing here. So if you
  1276. 48:40don't have any distribution in rewards
  1277. 48:42then so effectively what you want is
  1278. 48:45some form of a distribution of rewards
  1279. 48:46across the set of problems you are
  1280. 48:48showing. If there is not a distribution
  1281. 48:50of rewards there's nothing for the model
  1282. 48:51to learn like if all the rewards are
  1283. 48:53zero or all the rewards are one then
  1284. 48:56basically the normalization doesn't
  1285. 48:57work. Does that make sense? Uh yeah yes
  1286. 49:01yes but
  1287. 49:01>> which we will solve in the next like the
  1288. 49:04like the the shortcoming of this
  1289. 49:07particular method we will solve in the
  1290. 49:08next paper
  1291. 49:09>> but but this reward is specific to um
  1292. 49:12like this one particular
  1293. 49:15feature that we're trying to train and
  1294. 49:17not like the basic overall holistic
  1295. 49:19benchmark that we trained for the
  1296. 49:21previous model before.
  1297. 49:24>> So I mean it is basically taking
  1298. 49:26problems and then computing answers
  1299. 49:28right. uh if across the model you
  1300. 49:31basically are showing problems that are
  1301. 49:33all very hard then the model has no
  1302. 49:35capacity to learn because it will
  1303. 49:37basically have no reward at any point
  1304. 49:42>> it needs some hill climbing signal right
  1305. 49:45>> like I'm not showing you a formula I'm
  1306. 49:46intuitively explaining it to you
  1307. 49:50>> yes
  1308. 49:50>> um yeah actually I just want to comment
  1309. 49:52on that piece quickly
  1310. 49:54>> I think my interpretation of actually
  1311. 49:56the solution to that is in the original
  1312. 49:58papers like bo that's why there's a kale
  1313. 50:01divergence term. So essentially it's
  1314. 50:03like it is a valid concern I think
  1315. 50:05because it's like if we're updating the
  1316. 50:06weights we could probably train really
  1317. 50:07far like model and maybe we can get
  1318. 50:10really good answer these benchmarks but
  1319. 50:12if we got the model to be really
  1320. 50:13optimized on all these like simple
  1321. 50:14benchmarks earlier straight away so I
  1322. 50:17think in addition to the normalized
  1323. 50:19rewards we also have some like
  1324. 50:21divergence and all
  1325. 50:24>> okay that's a fair interpretation uh
  1326. 50:26that you add divergence and then you
  1327. 50:28don't deviate from what it could already
  1328. 50:30solve. Okay.
  1329. 50:32>> Yeah, I was interpreting it more along
  1330. 50:34the lines of like how do you have good
  1331. 50:36distribution of problems so that the
  1332. 50:38model has the right hill climbing signal
  1333. 50:40but I think what you're saying is that
  1334. 50:41if the model could already solve
  1335. 50:43something then kill diversion solves
  1336. 50:44that part of the problem.
  1337. 50:46>> Okay. Thank you.
  1338. 50:49>> Question is like so if you were trying
  1339. 50:50to post post train so that it has like a
  1340. 50:54new feature do you really have to update
  1341. 50:56all the weights or
  1342. 50:57>> No, I don't think so. Right. And there
  1343. 50:59are some more recent works that have
  1344. 51:00shown there are some blog posts that
  1345. 51:02have been recently shown that um like
  1346. 51:05you can do with like lower updates and
  1347. 51:07so on.
  1348. 51:09So I I do think that either kale
  1349. 51:11divergence or some like subset of
  1350. 51:13features could solve that problem. I
  1351. 51:15think the
  1352. 51:17uh the reason this is interesting is
  1353. 51:18that you uh want um you want perhaps
  1354. 51:22that these kind of techniques allow you
  1355. 51:24to improve the model overall.
  1356. 51:27>> Yeah.
  1357. 51:30more questions.
  1358. 51:31>> I hope
  1359. 51:33you just have a
  1360. 51:36zero but at this point you have a score.
  1361. 51:39How do you come up with a score?
  1362. 51:42>> How do you come up with a clean score?
  1363. 51:45>> Oh, because you train a reward model,
  1364. 51:47right?
  1365. 51:49I mean, you can also have zeros and ones
  1366. 51:50there and then you can average things.
  1367. 51:52But uh
  1368. 51:53>> so zero line that they have thresh
  1369. 51:59>> no you so what I was showing you are
  1370. 52:01training a reward model that is
  1371. 52:02basically going to give you a score for
  1372. 52:04that feedback.
  1373. 52:06>> Yeah if you only use zero and one that
  1374. 52:09can be a proxy but then you can do some
  1375. 52:12averaging.
  1376. 52:17Okay.
  1377. 52:19So what this roughly tells you is that
  1378. 52:22if you do basically the online
  1379. 52:23reinforcement learning loop uh and your
  1380. 52:25sample from the current model that beats
  1381. 52:28um what we were doing earlier where
  1382. 52:29we're in star approach. Uh so overall
  1383. 52:32what they showed was that you can
  1384. 52:34improve the majority of the like if if
  1385. 52:36they had 32 tries it was improving the
  1386. 52:38majority at K but it was actually not
  1387. 52:41improving pass at K. So if if you were
  1388. 52:43basically looking and plotting pass at K
  1389. 52:47um say one is correct if you sample 32
  1390. 52:49times then that was not what was
  1391. 52:51improving in their paper. What was
  1392. 52:52improving was that majority of the
  1393. 52:54solutions become correct. Um that that's
  1394. 52:56what was improving in this particular
  1395. 52:58paper. So the model actually became more
  1396. 53:01consistent not fundamentally smarter was
  1397. 53:03what they showed.
  1398. 53:06Now we'll cover the last paper uh called
  1399. 53:09Dappo um which is basically going to fix
  1400. 53:12some of the problems uh with respect to
  1401. 53:14reasoning on harder problems. So if you
  1402. 53:17naively scale up uh gRPO and want to do
  1403. 53:21this on even a quen 32B model which is
  1404. 53:23very easily accessible and you would get
  1405. 53:2630% on amy benchmark and here I will
  1406. 53:28show you a lot of technical terms uh but
  1407. 53:31I will try to explain to you intuitively
  1408. 53:33some of the challenges in just doing
  1409. 53:35this on quen 32B ends up being like the
  1410. 53:37entropy of the model collapses the model
  1411. 53:39can become too confident the training
  1412. 53:41can become unstable and the response
  1413. 53:43length the model output length can
  1414. 53:45become uncontrollable like it can
  1415. 53:47explode uncontrollably but deepseek did
  1416. 53:49get 47% on Amy like the deepseek urban
  1417. 53:53paper did get 47% so DAPo as a published
  1418. 53:56piece of work tries to um make explicit
  1419. 54:00what what were the techniques in RL that
  1420. 54:02were not covered in say GRPO so some of
  1421. 54:06the techniques that uh they talk about
  1422. 54:07is the that in PO you have to do um so
  1423. 54:10you're basically trying to do some sort
  1424. 54:12of exploration in your standard PO
  1425. 54:14algorithm And um the standard PO
  1426. 54:18clipping uh treats the increasing and
  1427. 54:20the decreasing u on on on that very
  1428. 54:23similar. So basically if you have a low
  1429. 54:25probability token um it can only hill
  1430. 54:28climb so much and then the high
  1431. 54:30probability token has can also get
  1432. 54:32clipped. So the exploration can
  1433. 54:34collapse. Uh so basically the clipping
  1434. 54:36function in the the PO algorithm needs
  1435. 54:38to be asymmetric and that will allow
  1436. 54:41bigger increases. So that was the first
  1437. 54:42thing that Dappo found.
  1438. 54:44U in terms of graphs what that roughly
  1439. 54:47meant was that if you did clipping then
  1440. 54:50your accuracy was much better and if you
  1441. 54:53didn't uh do if you could allow clipping
  1442. 54:55higher if you could allow asymmetric
  1443. 54:56clipping the purple plot shows you that
  1444. 54:58you could achieve much higher accuracy
  1445. 55:00and your entropy on the right side
  1446. 55:02stayed more stable and did not collapse
  1447. 55:04while if you uh did have uh did I invert
  1448. 55:08that? So, so this is higher accuracy and
  1449. 55:10then the entropy is looking nicer and
  1450. 55:12then if you did not do asymmetric
  1451. 55:14clipping then your entropy has
  1452. 55:15collapsed. So you entropy is a proxy for
  1453. 55:18how much exploration is possible in the
  1454. 55:20model.
  1455. 55:21A second uh very interesting technique
  1456. 55:24which actually relates to what we were
  1457. 55:26talking about earlier was something
  1458. 55:28called as dynamic sampling. So what I
  1459. 55:31showed you for uh GRPO was that okay you
  1460. 55:34go and sample 64 solutions and then you
  1461. 55:36come up with a distribution on them and
  1462. 55:38then then you take a group baseline.
  1463. 55:40What uh Dapo said was okay well um how
  1464. 55:43about we oversample how about we don't
  1465. 55:45just use 64 samples how about we
  1466. 55:47oversample and then what we want is that
  1467. 55:49we will filter out things that have
  1468. 55:51zeros and zero reward and one reward so
  1469. 55:53that what we want is basically a nice
  1470. 55:56distribution so that uh most of the
  1471. 55:58solutions uh have some sort of a signal.
  1472. 56:01So they filter out all correct and all
  1473. 56:04wrong groups and they keep only some
  1474. 56:07subset uh between 0 and 64. So they
  1475. 56:10they're basically doing dynamic sampling
  1476. 56:12because they don't want to waste their
  1477. 56:13gradient. Your advantage should not be
  1478. 56:16zero. Like if you're if you're basically
  1479. 56:18your rewards are all correct or all
  1480. 56:20wrong then those groups are filtered out
  1481. 56:21and you essentially want to keep only
  1482. 56:24those groups that have um some signal.
  1483. 56:27So this maintains an effective batch
  1484. 56:29size because in RL if you have effective
  1485. 56:32batch size for propagating the gradients
  1486. 56:34because you're not computing gradients
  1487. 56:36from all correct and all wrong. Anyways
  1488. 56:38questions
  1489. 56:44>> group
  1490. 56:47question. Yes. So you have a batch of uh
  1491. 56:50questions when you are training and then
  1492. 56:52you're uh filtering out questions.
  1493. 56:56Yeah. Um, it seems 64 samples is quite
  1494. 57:01small. I I'm wondering if it's because
  1495. 57:02like there's very limited amount of Amy
  1496. 57:05questions out there and like whether
  1497. 57:08that was enough.
  1498. 57:10>> So this was a this is more an exemplar
  1499. 57:12here. You can choose how many samples
  1500. 57:15you pick but at the end of the day uh
  1501. 57:18this this is mostly to showcase what was
  1502. 57:20possible from their paper. So Amy yeah
  1503. 57:22yeah yeah this will be benchmark
  1504. 57:24specific and the difficulty of the
  1505. 57:25benchmark and the [snorts] capability of
  1506. 57:27the base model
  1507. 57:32and I think the the third bit that is
  1508. 57:34worth noting is that the reasoning
  1509. 57:35chains um have certain amount of um
  1510. 57:38length that matters. So if you are
  1511. 57:41basically doing a sample level loss uh
  1512. 57:44sample level means that for each
  1513. 57:46question answer pair that that sequence
  1514. 57:48you're computing a loss then each answer
  1515. 57:50is basically counted globally. So um in
  1516. 57:54certain cases if you have a very long
  1517. 57:55garbage answer in the model output then
  1518. 57:57that basically gets same weight as a
  1519. 57:59short good answer. So they effectively
  1520. 58:02suggest that you should have some sort
  1521. 58:03of a effectively length penalty but
  1522. 58:06which should put uh better like they
  1523. 58:09want a shape uh based on the length. So
  1524. 58:11they put a token based low loss as
  1525. 58:13opposed to putting a sample level loss
  1526. 58:15and that they gave them some gain. And
  1527. 58:18in particular what they were controlling
  1528. 58:20for is both the entropy and the mean
  1529. 58:22response length. So effectively if they
  1530. 58:24didn't have a token level loss they were
  1531. 58:25noticing that the entropy was growing
  1532. 58:27and the response length was also uh not
  1533. 58:29looking like it was control um it was
  1534. 58:31growing uncontrollably. So they wanted
  1535. 58:33to shape that better by putting some
  1536. 58:35form of a penalty there.
  1537. 58:38So they put um token level loss for
  1538. 58:40that. And then finally um there are
  1539. 58:44certain cases in which um the model
  1540. 58:48encounters a hard problem. So it
  1541. 58:50basically gets truncated at the end
  1542. 58:52because um it was thinking it was
  1543. 58:56basically producing model outputs and
  1544. 58:57and these truncated uh reasoning chains
  1545. 59:00can generate a lot of noise. So they
  1546. 59:02basically put a gradual penalty in and
  1547. 59:05in in the tokens to to deal with that
  1548. 59:06and that allowed the training to become
  1549. 59:08stable instead of adding noise. So
  1550. 59:11effectively uh the generation entropy
  1551. 59:13instead of uh becoming unstable uh once
  1552. 59:16the model was learning to generate like
  1553. 59:18really like the model as it progresses
  1554. 59:21starts to um generate longer and longer
  1555. 59:23reasoning chains and that can that can
  1556. 59:26get truncated and that can cause
  1557. 59:27problems. So there are a couple of
  1558. 59:28different ways in which different papers
  1559. 59:30have tried to tackle this. one is that
  1560. 59:32either they increase the context length
  1561. 59:34over RL loop um to handle that in this
  1562. 59:36particular case they are basically
  1563. 59:38putting this uh penalty function so that
  1564. 59:40they can handle this this part.
  1565. 59:43So overall what this showed was that
  1566. 59:45when you started with GRPO on this AMA
  1567. 59:48benchmark if you put overong filtering
  1568. 59:51you went from 30 to 36 on the quen 32B
  1569. 59:54model. If you did asymmetric clipping,
  1570. 59:57you could go to 38. With soft overong
  1571. 59:59punishment, you could go to 41. And then
  1572. 1:00:01with token level loss, you go to 42. And
  1573. 1:00:03then if you do dynamic sampling, where
  1574. 1:00:05you're basically doing a better
  1575. 1:00:07distribution of rewards um across the
  1576. 1:00:10batch, you have a better signal
  1577. 1:00:11propagation. You basically got to 50,
  1578. 1:00:13which was even better than what DeepS R1
  1579. 1:00:16uh distilled down to Quen 32B had done.
  1580. 1:00:18So they could actually hill climb on the
  1581. 1:00:21quen 32B themselves and and get to a
  1582. 1:00:23pretty strong score here.
  1583. 1:00:25So some of the learnings from this paper
  1584. 1:00:28was that the loss function by itself was
  1585. 1:00:31not a reasonable enough proxy when
  1586. 1:00:32you're learning in RL. You have to look
  1587. 1:00:34at the response length. You have to look
  1588. 1:00:35at the entropy and keep it so that it's
  1589. 1:00:38not too low but it's not too high
  1590. 1:00:39either. And then uh the percentage of
  1591. 1:00:42samples that have uh a full accuracy of
  1592. 1:00:44one tells you how much you need to
  1593. 1:00:46sample. So that's all of all three are
  1594. 1:00:49important principles in uh learning in
  1595. 1:00:51RL and some of the challenges that you
  1596. 1:00:54might have to look out for is that if
  1597. 1:00:56your response length in the model
  1598. 1:00:58outputs is exploding then you have to
  1599. 1:01:00control the loss there. You have to
  1600. 1:01:01control the entropy and then if you're
  1601. 1:01:03not seeing improvement after um certain
  1602. 1:01:06number of steps then your reward model
  1603. 1:01:08actually might be saturated.
  1604. 1:01:10Uh so effectively what this is saying is
  1605. 1:01:13that the
  1606. 1:01:15the optimization in the RL loop is
  1607. 1:01:17harder. So if I were to answer the
  1608. 1:01:18question that was brought up earlier of
  1609. 1:01:19like SFT versus RL, RL does provide you
  1610. 1:01:23uh in the domains where there you do
  1611. 1:01:25have a strong reward signal. It does
  1612. 1:01:27provide you the ability to hill climb
  1613. 1:01:28with fewer number of examples but it
  1614. 1:01:31does take a lot of work to like get it
  1615. 1:01:33right. Well, supervised fine-tuning
  1616. 1:01:34oftentimes if you do have access to a
  1617. 1:01:36lot of high quality data is faster way
  1618. 1:01:38to just improve the model performance in
  1619. 1:01:40certain cases, but it doesn't bring
  1620. 1:01:42reasoning trace reasoning capabilities
  1621. 1:01:44or boost them in in certain ways.
  1622. 1:01:48So if you want to compare the the three
  1623. 1:01:51different techniques uh that we uh
  1624. 1:01:53talked about today. Um so if you
  1625. 1:01:56basically only had a few different
  1626. 1:01:58examples like 100 examples with
  1627. 1:01:59reasoning and you are effectively just
  1628. 1:02:02like playing around uh with a model star
  1629. 1:02:05is a pretty good and you don't have RL
  1630. 1:02:07infrastructure. Star is a pretty good
  1631. 1:02:08way for you to like start getting the
  1632. 1:02:10model to reason. um and and simple
  1633. 1:02:13reasoning tasks like GSM8K actually will
  1634. 1:02:16see reasonable amount of improvement
  1635. 1:02:18there. Maybe not phenomenal, but like
  1636. 1:02:19you're still staying within what the
  1637. 1:02:21model was capable of. If you go to
  1638. 1:02:23Deepseek Math um and you use GRPO, you
  1639. 1:02:26do need a good enough base model plus
  1640. 1:02:28like uh you do need to u prime the model
  1641. 1:02:32with with good instruction data. But now
  1642. 1:02:35um you have a reasonably strong
  1643. 1:02:36algorithm that that can work even if you
  1644. 1:02:39don't have enough memory. if you have a
  1645. 1:02:41limited number of GPUs and then for
  1646. 1:02:42standard math reasoning tasks this was
  1647. 1:02:44well proven
  1648. 1:02:47and then if you uh and you need do kind
  1649. 1:02:50of uh techniques when your reasoning
  1650. 1:02:52chains will end up being longer which
  1651. 1:02:53typically correlates with harder
  1652. 1:02:55problems so if your reasoning chains are
  1653. 1:02:57going to be uh much longer you need
  1654. 1:02:59state-of-the-art performance then you do
  1655. 1:03:00need to control all of these variables
  1656. 1:03:02in your RL algorithm and infrastructure
  1657. 1:03:04but for compet competition level
  1658. 1:03:06problems like Amy and IMO this is very
  1659. 1:03:09useful
  1660. 1:03:12So what is it that we expect to improve?
  1661. 1:03:15All three techniques will improve in
  1662. 1:03:16general the majority at K performance on
  1663. 1:03:19the y-axis as you put more compute. Um
  1664. 1:03:22the answer formatting and generally will
  1665. 1:03:24improve as you apply these techniques
  1666. 1:03:27and uh in general the model will be more
  1667. 1:03:29coherent over multiple steps but none of
  1668. 1:03:31these will yet improve the fundamental
  1669. 1:03:33capability or just teach the model to
  1670. 1:03:35solve no new problems or generalize a
  1671. 1:03:38lot out of domain. So there is some set
  1672. 1:03:40of questions that are being asked at
  1673. 1:03:42this point in time. What would it take
  1674. 1:03:44for the the last part to start
  1675. 1:03:46improving?
  1676. 1:03:48>> Yes.
  1677. 1:03:50part is because I wonder whe
  1678. 1:03:54the part like all brand or all because
  1679. 1:03:58that's if you
  1680. 1:04:01>> Mhm. That's like uh the only way you
  1681. 1:04:06like on the page and you improve on so
  1682. 1:04:13because we all
  1683. 1:04:16>> I see
  1684. 1:04:17>> I'm just a
  1685. 1:04:21>> uh that's not the reason I think the
  1686. 1:04:23more fundamental question is that to
  1687. 1:04:24improve pass at K you're basically
  1688. 1:04:27improving the fundamental capability of
  1689. 1:04:28the model to solve new problems right So
  1690. 1:04:31you want to see the model uh show
  1691. 1:04:34capabilities in certain ways. So
  1692. 1:04:36typically the fundamental capability
  1693. 1:04:38scaling comes from uh the fundamental
  1694. 1:04:40capability step jumps have typically
  1695. 1:04:43been seen by either some sort of a
  1696. 1:04:45breakthrough or by scaling in some
  1697. 1:04:47dimension.
  1698. 1:04:48>> Okay. So if you actually see that this
  1699. 1:04:51thing for a set of the problems always
  1700. 1:04:53give the answer then it's possible that
  1701. 1:04:57I'm not sure whe is good to do so but
  1702. 1:05:00you can answer the question to some
  1703. 1:05:02other models you're going to get the
  1704. 1:05:04answer and you can go back to
  1705. 1:05:07>> let's take that one offline
  1706. 1:05:10>> um okay so one of the thing that I keep
  1707. 1:05:14highlighting um is something to keep in
  1708. 1:05:17mind is that a lot the RL loop or even
  1709. 1:05:19the star method like the quality of
  1710. 1:05:21rational all of that depends on the
  1711. 1:05:23ability of the model to reason or there
  1712. 1:05:26there needing to be some sort of a
  1713. 1:05:27verifier or a reward model and the
  1714. 1:05:30reward models if the model is too
  1715. 1:05:32capable then the reward rewards will get
  1716. 1:05:34hacked or and if the reward model
  1717. 1:05:36doesn't have enough signal then you're
  1718. 1:05:37basically not able to hill climb the
  1719. 1:05:39loop. So it is a harder optimization
  1720. 1:05:42problem in that respective. Um we looked
  1721. 1:05:46at last um last lecture uh or last
  1722. 1:05:50Friday we looked at the autonomous
  1723. 1:05:52coding applications where you do have
  1724. 1:05:54access to verifiable rewards because you
  1725. 1:05:56have like in math and code you have the
  1726. 1:05:58final correct answer then you can also
  1727. 1:06:00give execution feedback which was the
  1728. 1:06:02RLEF paper we looked at and then you
  1729. 1:06:04also have unit test execution. Um
  1730. 1:06:06similarly in other there are some
  1731. 1:06:08domains in which you have this kind of
  1732. 1:06:10verification available. So it's easy for
  1733. 1:06:12you to uh hill climb but then how many
  1734. 1:06:14such places do you have this signal
  1735. 1:06:16available? These questions will continue
  1736. 1:06:18to come up. So um like what verification
  1737. 1:06:20signals are good enough and then there's
  1738. 1:06:23can you use a ensemble of verifiers
  1739. 1:06:25instead of like one single verifier to
  1740. 1:06:28make up for the gaps of what a single
  1741. 1:06:30verifier will provide signal on. So all
  1742. 1:06:32of these questions are extremely
  1743. 1:06:34important.
  1744. 1:06:36So in terms of if you were to look at
  1745. 1:06:37open problems uh in this domain so I
  1746. 1:06:40think this is still an active train time
  1747. 1:06:41scaling is an active area of research uh
  1748. 1:06:45I already highlighted this there's a
  1749. 1:06:47fundamental question of like why only
  1750. 1:06:49majority at K increases why why does
  1751. 1:06:51pass at K doesn't increase a second
  1752. 1:06:53question is that um we do see in the
  1753. 1:06:56reasoning chains um things like
  1754. 1:06:58backtracking or the model is able to
  1755. 1:07:00like self-evaluate self-correct we did
  1756. 1:07:03show those examples early on, but are
  1757. 1:07:05those behaviors real? Like these
  1758. 1:07:07reasoning behaviors, are they emerging
  1759. 1:07:08or were they already like present and
  1760. 1:07:11they're basically statistically becoming
  1761. 1:07:12more prevalent? And then a third bit
  1762. 1:07:15right now is that we don't really have
  1763. 1:07:17very good techniques to learn from
  1764. 1:07:18failures. There have been a few papers
  1765. 1:07:19that have tried to uh learn from
  1766. 1:07:21failures in useful ways, but currently a
  1767. 1:07:23lot of the techniques just filter them
  1768. 1:07:25out. Some uh some promising directions
  1769. 1:07:28that people continue to explore in this
  1770. 1:07:29is uh along the data dimension of like
  1771. 1:07:32how do you generate better data to train
  1772. 1:07:34the model along the algorithm dimensions
  1773. 1:07:36of like how do you get the reinforcement
  1774. 1:07:39learning to be robust to noise in the
  1775. 1:07:40reward models what kind of rewards
  1776. 1:07:42should we use and then can you combine
  1777. 1:07:45some of the rationalization techniques
  1778. 1:07:46that we did with um in star with say the
  1779. 1:07:49techniques that we did in DAPo. So all
  1780. 1:07:52of those are u very interesting
  1781. 1:07:53directions that that you could look into
  1782. 1:07:55for your projects.
  1783. 1:07:58And with that we have a few minutes
  1784. 1:08:00left. Um but let's have questions.
  1785. 1:08:03>> Um for like the new like being like out
  1786. 1:08:07of the box like models it
  1787. 1:08:12are training. How much do you think
  1788. 1:08:14they're still relying on just like just
  1789. 1:08:17common call like next to prediction like
  1790. 1:08:19just just like blank like like raw text
  1791. 1:08:21data right like that they take from like
  1792. 1:08:24the internet right or anywhere
  1793. 1:08:28rather than like instruction tuning data
  1794. 1:08:30that like they generate like using
  1795. 1:08:32reasoning techniques and techniques that
  1796. 1:08:34we learn today like what do you think is
  1797. 1:08:36that fraction
  1798. 1:08:37>> I think so I think the like I don't
  1799. 1:08:40think that's published for entropic but
  1800. 1:08:41I think rock was more public. So
  1801. 1:08:44typically the percentage of um
  1802. 1:08:46reinforcement learning uh versus uh
  1803. 1:08:48pre-training has been closer to I think
  1804. 1:08:51last year it was closer to say 99% 1%
  1805. 1:08:54and then it's grown to perhaps like 5%
  1806. 1:08:56or something like that but Grock claimed
  1807. 1:08:58that Grock 4 claimed that it did 50% RL
  1808. 1:09:02but it actually did not quite improve 50
  1809. 1:09:04like 50% RL should give a big jump but
  1810. 1:09:08you're [snorts] bottlenecked by a lot of
  1811. 1:09:09the things that I'm showing you here of
  1812. 1:09:12like your your rewards are not strong
  1813. 1:09:14enough or there's noise in rewards. All
  1814. 1:09:16of those things are going to be
  1815. 1:09:17bottlenecks. So there's still a lot of
  1816. 1:09:18open problems in this domain. Yeah.
  1817. 1:09:23Uh let's see if there are more questions
  1818. 1:09:24across the board or is this lecture too
  1819. 1:09:27complex for people to ask questions
  1820. 1:09:31too complex? Okay.
  1821. 1:09:35Happy to answer questions after
  1822. 1:09:43>> more questions across the class. No,
  1823. 1:09:46>> I will like for example.
  1824. 1:09:58>> Mhm. Is this something like if you
  1825. 1:10:03if the model perform okay in this
  1826. 1:10:06calculus and you help it to perform
  1827. 1:10:09better by RL
  1828. 1:10:12the model never see always fail in
  1829. 1:10:16regardless how well they can never
  1830. 1:10:21fundamental reason like K is like
  1831. 1:10:24fundamentally you think you need
  1832. 1:10:27>> Mhm. But like you better
  1833. 1:10:31>> exactly.
  1834. 1:10:32>> Yes.
  1835. 1:10:34>> Okay. So
  1836. 1:10:36maybe that's something like there's more
  1837. 1:10:39to learn because [clears throat] it's
  1838. 1:10:43getting better at something you already
  1839. 1:10:46can do.
  1840. 1:10:48>> Yeah. You mean it's basically able to
  1841. 1:10:49explore better in the design space of
  1842. 1:10:51what it knows and by exploration and
  1843. 1:10:54search it's able to arrive at the
  1844. 1:10:55solution.
  1845. 1:10:59There was a question here which I didn't
  1846. 1:11:01let you ask.
  1847. 1:11:02>> All right. Yeah. I I was curious for um
  1848. 1:11:05especially on the directions of data. Um
  1849. 1:11:08so uh for very unique data set like Amy
  1850. 1:11:11or USML where the number of data sets is
  1851. 1:11:13very limited. Um how can we uh ensure
  1852. 1:11:17that we have enough signals for
  1853. 1:11:19verifiable rewards? Um I mean like
  1854. 1:11:23there's not enough data but we need a
  1855. 1:11:24lot of signals. So how can you kind of
  1856. 1:11:27like make sure that you have enough
  1857. 1:11:28training and verification without
  1858. 1:11:30accidentally leaking data?
  1859. 1:11:33>> So uh I mean RL is more data efficient.
  1860. 1:11:36So you do not need that much data to
  1861. 1:11:38begin with. So I mean like that's why I
  1862. 1:11:40was presenting these papers you do see
  1863. 1:11:42that u certain number of like enough
  1864. 1:11:45examples is going to enough to help
  1865. 1:11:47climb. Uh the verification signals are
  1866. 1:11:50more a function of like having good set
  1867. 1:11:52of verifiers. So I think I thought you
  1868. 1:11:54already covered the ensemble verifier
  1869. 1:11:56paper, right? Like we were you already
  1870. 1:11:58covered that. So it's it's not just a
  1871. 1:11:59matter of having a single verifier, you
  1872. 1:12:01can have multiple verifiers.
  1873. 1:12:03>> I see. So when there's not enough data,
  1874. 1:12:05we can just make up for that with many
  1875. 1:12:08more verifiers.
  1876. 1:12:10>> So I think you solve the data problem
  1877. 1:12:12separately, but like I don't think the
  1878. 1:12:14not enough data is the right
  1879. 1:12:15abstraction. I think it's do you have
  1880. 1:12:17enough data to hill climb on is the
  1881. 1:12:20right abstraction, right?
  1882. 1:12:22like where you don't end up filtering
  1883. 1:12:24out if you were doing dynamic sampling
  1884. 1:12:26for example.
  1885. 1:12:28>> Okay, with that we'll close the class
  1886. 1:12:30and I'm still around. Thanks everyone.

About this transcript

This page contains the full transcript of YouTube transcript (yVnmHSAy3ck) , generated from the public captions YouTube serves with the video. The transcript has 12,791 words across 1,886 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.