Skip to main content
QUICK REVIEW

[Paper Review] Large Language Models can Learn Rules

Zhaocheng Zhu, Yuan Xue|arXiv (Cornell University)|Oct 10, 2023
Topic ModelingComputer Science8 citations
TL;DR

HtT learns a library of textual rules from training examples via induction and applies them deductively to improve reasoning with LLMs across relational, numerical, and concept-learning tasks, achieving 10–30% absolute accuracy gains.

ABSTRACT

When prompted with a few examples and intermediate steps, large language models (LLMs) have demonstrated impressive performance in various reasoning tasks. However, prompting methods that rely on implicit knowledge in an LLM often generate incorrect answers when the implicit knowledge is wrong or inconsistent with the task. To tackle this problem, we present Hypotheses-to-Theories (HtT), a framework that learns a rule library for reasoning with LLMs. HtT contains two stages, an induction stage and a deduction stage. In the induction stage, an LLM is first asked to generate and verify rules over a set of training examples. Rules that appear and lead to correct answers sufficiently often are collected to form a rule library. In the deduction stage, the LLM is then prompted to employ the learned rule library to perform reasoning to answer test questions. Experiments on relational reasoning, numerical reasoning and concept learning problems show that HtT improves existing prompting methods, with an absolute gain of 10-30% in accuracy. The learned rules are also transferable to different models and to different forms of the same problem.

Motivation & Objective

  • Motivate the need for explicit rule knowledge to complement implicit LLM reasoning.
  • Propose Hypotheses-to-Theories (HtT) to induce and apply a textual rule library.
  • Show that rule-based deduction improves accuracy on relational, numerical, and concept-learning tasks.
  • Demonstrate transferability of learned rules across models and problem variants.
  • Analyze what aspects of HtT contribute to improvements and conditions for success.

Proposed method

  • Induction stage: Prompt the LLM to generate rules for each training example and verify rules by checking consistency with ground-truth answers.
  • Filter rules by coverage and confidence to build a rule library (thresholds on minimal coverage k and minimal confidence p).
  • Induction from Deduction: reuse a single prompt design for rule generation and verification to reduce prompting effort.
  • Deduction stage: prepend the learned rule library to a deductive prompting method (e.g., CoT or LtM) and prompt the LLM to retrieve and apply rules during reasoning.
  • Organize the rule library hierarchically and use XML tagging to facilitate rule retrieval without external retrievers.
  • Evaluate on CLUTRR (relational reasoning), Arithmetic (numerical reasoning in non-decimal bases), and List Functions (concept learning) with GPT-3.5 and GPT-4.

Experimental results

Research questions

  • RQ1Can an LLM induce a usable library of textual rules from training examples?
  • RQ2Does incorporating a learned rule library via deduction improve reasoning accuracy over baseline prompting?
  • RQ3Are the induced rules transferable across models and problem variants?
  • RQ4What factors (e.g., rule coverage/confidence, number of examples) drive the gains from HtT?
  • RQ5How does HtT perform across relational, numerical, and concept-learning tasks?

Key findings

  • HtT yields consistent accuracy gains of 10–30 percentage points over base prompting methods across tasks and models.
  • On symbolic CLUTRR, GPT-4 with HtT improves CoT by 27.2 percentage points relative to 5-shot CoT, and CoT+HtT reaches 48.4% average vs 21.2% for baseline CoT.
  • For Arithmetic base-16/11/9, HtT with GPT-4 provides up to 21.0 percentage points improvement over base prompts.
  • On List Functions, HtT with GPT-4 raises average task accuracy to 56.2% versus 46.0% with 4-shot CoT, and GPT-3.5 benefits substantially from transferred rules (34.4% task accuracy).
  • Ablations show most gains come from reducing incorrect rules; random rules degrade performance, underscoring the value of induced rules.
  • There is a log-linear scaling of accuracy with the number of induction examples, and HtT discovers over 85% of the required rules in all datasets.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.