Grimoire is All You Need for Enhancing Large Language Models

Ding Chen, Shichao Song, Qingchen Yu, Zhiyu Li, Wenjin Wang +2 more
1/7/2024
cs.CL

No official code found. Best implementation: IAAR-Shanghai/Grimoire (120 stars, Apache-2.0, last commit 2024-02-29).

Abstract

In-context Learning (ICL) is one of the key methods for enhancing the performance of large language models on specific tasks by providing a set of few-shot examples. However, the ICL capability of different types of models shows significant variation due to factors such as model architecture, volume of learning data, and the size of parameters. Generally, the larger the model's parameter size and the more extensive the learning data, the stronger its ICL capability. In this paper, we propose a method SLEICL that involves learning from examples using strong language models and then summarizing and transferring these learned skills to weak language models for inference and application. This ensures the stability and effectiveness of ICL. Compared to directly enabling weak language models to learn from prompt examples, SLEICL reduces the difficulty of ICL for these models. Our experiments, conducted on up to eight datasets with five language models, demonstrate that weak language models achieve consistent improvement over their own zero-shot or few-shot capabilities using the SLEICL method. Some weak language models even surpass the performance of GPT4-1106-preview (zero-shot) with the aid of SLEICL.

View on arXivView PDF

Code Implementations(1)

Apache-2.0

Grimoire is All You Need for Enhancing Large Language Models

12013Shell, PythonJan 9, 20242 years agoApache-2.0
baichuanchatgptdatasetsgpt-4grimoire+5 more

Similar Papers

Cite this paper

@article{chen2024grimoire,
  title  = {Grimoire is All You Need for Enhancing Large Language Models},
  author = {Ding Chen and Shichao Song and Qingchen Yu and Zhiyu Li and Wenjin Wang and Feiyu Xiong and Bo Tang},
  year   = {2024},
  eprint = {2401.03385},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2401.03385v2}
}

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

Discussion