ChatPaper.aiChatPaper

Step-Controlled DPO: Sfruttare gli Errori Graduali per un Ragionamento Matematico Migliorato

Step-Controlled DPO: Leveraging Stepwise Error for Enhanced Mathematical Reasoning

June 30, 2024
Autori: Zimu Lu, Aojun Zhou, Ke Wang, Houxing Ren, Weikang Shi, Junting Pan, Mingjie Zhan
cs.AI

Abstract

L'ottimizzazione diretta delle preferenze (Direct Preference Optimization, DPO) si è dimostrata efficace nel migliorare le prestazioni dei modelli linguistici di grandi dimensioni (Large Language Models, LLMs) su compiti downstream come il ragionamento e l'allineamento. In questo lavoro, proponiamo la DPO controllata a passi (Step-Controlled DPO, SCDPO), un metodo per fornire automaticamente una supervisione degli errori passo-passo creando campioni negativi di ragionamenti matematici che iniziano a commettere errori in un passaggio specificato. Applicando questi campioni nell'addestramento DPO, SCDPO può allineare meglio il modello per comprendere gli errori di ragionamento e produrre passaggi di ragionamento accurati. Applichiamo SCDPO sia a soluzioni integrate con codice che a soluzioni a catena di pensiero (chain-of-thought), dimostrando empiricamente che migliora costantemente le prestazioni rispetto alla DPO semplice su tre diversi modelli SFT, inclusi un modello SFT esistente e due modelli che abbiamo perfezionato. L'analisi qualitativa dell'assegnazione del credito di SCDPO e DPO dimostra l'efficacia di SCDPO nell'identificare gli errori nelle soluzioni matematiche. Successivamente, applichiamo SCDPO a un modello InternLM2-20B, ottenendo un modello da 20B che raggiunge punteggi elevati dell'88,5% su GSM8K e del 58,1% su MATH, rivaleggiando con tutti gli altri LLM open-source, mostrando il grande potenziale del nostro metodo.
English
Direct Preference Optimization (DPO) has proven effective at improving the performance of large language models (LLMs) on downstream tasks such as reasoning and alignment. In this work, we propose Step-Controlled DPO (SCDPO), a method for automatically providing stepwise error supervision by creating negative samples of mathematical reasoning rationales that start making errors at a specified step. By applying these samples in DPO training, SCDPO can better align the model to understand reasoning errors and output accurate reasoning steps. We apply SCDPO to both code-integrated and chain-of-thought solutions, empirically showing that it consistently improves the performance compared to naive DPO on three different SFT models, including one existing SFT model and two models we finetuned. Qualitative analysis of the credit assignment of SCDPO and DPO demonstrates the effectiveness of SCDPO at identifying errors in mathematical solutions. We then apply SCDPO to an InternLM2-20B model, resulting in a 20B model that achieves high scores of 88.5% on GSM8K and 58.1% on MATH, rivaling all other open-source LLMs, showing the great potential of our method.
PDF254November 28, 2024