Knowledgeable In-Context Tuning: Exploring and Exploiting Factual Knowledge for In-Context Learning

Jianing Wang, Chengyu Wang, Chuanqi Tan, Jun Huang, Ming Gao
9/26/2023
cs.CLcs.AI

No confident code implementation found for this paper. 1 possible match can be shown below.

Abstract

Large language models (LLMs) enable in-context learning (ICL) by conditioning on a few labeled training examples as a text-based prompt, eliminating the need for parameter updates and achieving competitive performance. In this paper, we demonstrate that factual knowledge is imperative for the performance of ICL in three core facets: the inherent knowledge learned in LLMs, the factual knowledge derived from the selected in-context examples, and the knowledge biases in LLMs for output generation. To unleash the power of LLMs in few-shot learning scenarios, we introduce a novel Knowledgeable In-Context Tuning (KICT) framework to further improve the performance of ICL: 1) injecting knowledge into LLMs during continual self-supervised pre-training, 2) judiciously selecting the examples for ICL with high knowledge relevance, and 3) calibrating the prediction results based on prior knowledge. We evaluate the proposed approaches on autoregressive models (e.g., GPT-style LLMs) over multiple text classification and question-answering tasks. Experimental results demonstrate that KICT substantially outperforms strong baselines and improves by more than 13% and 7% on text classification and question-answering tasks, respectively.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 1 weaker match is hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{wang2023knowledgeable,
  title  = {Knowledgeable In-Context Tuning: Exploring and Exploiting Factual Knowledge for In-Context Learning},
  author = {Jianing Wang and Chengyu Wang and Chuanqi Tan and Jun Huang and Ming Gao},
  year   = {2023},
  eprint = {2309.14771},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2309.14771v2}
}

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

Discussion