Large Language Model Cascades with Mixture of Thoughts Representations for Cost-efficient Reasoning

Murong Yue, Jie Zhao, Min Zhang, Liang Du, Ziyu Yao
10/1/2023

No official code found. Best implementation: MurongYue/LLM_MoT_cascade (32 stars, last commit 2024-06-01).

Abstract

Large language models (LLMs) such as GPT-4 have exhibited remarkable performance in a variety of tasks, but this strong performance often comes with the high expense of using paid API services. In this paper, we are motivated to study building an LLM cascade to save the cost of using LLMs, particularly for performing reasoning (e.g., mathematical, causal) tasks. Our cascade pipeline follows the intuition that simpler questions can be addressed by a weaker but more affordable LLM, whereas only the challenging questions necessitate the stronger and more expensive LLM. To realize this decision-making, we consider the"answer consistency"of the weaker LLM as a signal of the question difficulty and propose several methods for the answer sampling and consistency checking, including one leveraging a mixture of two thought representations (i.e., Chain-of-Thought and Program-of-Thought). Through experiments on six reasoning benchmark datasets, with GPT-3.5-turbo and GPT-4 being the weaker and stronger LLMs, respectively, we demonstrate that our proposed LLM cascades can achieve performance comparable to using solely the stronger LLM but require only 40% of its cost.

View on arXivView PDF

Code Implementations(1)

This is the implementation for the paper "LARGE LANGUAGE MODEL CASCADES WITH MIX- TURE OF THOUGHT REPRESENTATIONS FOR COST- EFFICIENT REASONING".

324PythonOct 3, 20232 years ago

Similar Papers

Cite this paper

@article{yue2023large,
  title  = {Large Language Model Cascades with Mixture of Thoughts Representations for Cost-efficient Reasoning},
  author = {Murong Yue and Jie Zhao and Min Zhang and Liang Du and Ziyu Yao},
  year   = {2023},
  eprint = {2310.03094},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/pdf/2310.03094},
  journal = {ICLR 2023 2023}
}

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/2310.03094.svg)](https://codeofpaper.com/paper/2310.03094)

Discussion