Language Models are Hidden Reasoners: Unlocking Latent Reasoning Capabilities via Self-Rewarding

Haolin Chen, Yihao Feng, Zuxin Liu, Weiran Yao, Akshara Prabhakar +6 more
11/6/2024
cs.AIcs.CLcs.LG

Official code: SalesforceAIResearch/LaTRO (127 stars, Apache-2.0, last commit 2025-02-21).

Abstract

Large language models (LLMs) have shown impressive capabilities, but still struggle with complex reasoning tasks requiring multiple steps. While prompt-based methods like Chain-of-Thought (CoT) can improve LLM reasoning at inference time, optimizing reasoning capabilities during training remains challenging. We introduce LaTent Reasoning Optimization (LaTRO), a principled framework that formulates reasoning as sampling from a latent distribution and optimizes it via variational approaches. LaTRO enables LLMs to concurrently improve both their reasoning process and ability to evaluate reasoning quality, without requiring external feedback or reward models. We validate LaTRO through experiments on GSM8K and ARC-Challenge datasets using multiple model architectures. On GSM8K, LaTRO improves zero-shot accuracy by an average of 12.5% over base models and 9.6% over supervised fine-tuning across Phi-3.5-mini, Mistral-7B, and Llama-3.1-8B. Our findings suggest that pre-trained LLMs possess latent reasoning capabilities that can be unlocked and enhanced through our proposed optimization approach in a self-improvement manner. The code of LaTRO is available at \url{https://github.com/SalesforceAIResearch/LaTRO}.

View on arXivView PDF

Code Implementations(1)

Apache-2.0
12710Shell, PythonOct 8, 20241 years agoApache-2.0

Similar Papers

Cite this paper

@article{chen2024language,
  title  = {Language Models are Hidden Reasoners: Unlocking Latent Reasoning Capabilities via Self-Rewarding},
  author = {Haolin Chen and Yihao Feng and Zuxin Liu and Weiran Yao and Akshara Prabhakar and Shelby Heinecke and Ricky Ho and Phil Mui and Silvio Savarese and Caiming Xiong and Huan Wang},
  year   = {2024},
  eprint = {2411.04282},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2411.04282v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2411.04282.svg)](https://codeofpaper.com/paper/2411.04282)

Discussion