Retrieval-Augmented Language Modeling (RALM) methods, which condition a
language model (LM) on relevant documents from a grounding corpus during
generation, were shown to significantly improve language modeling performance.
In addition, they can mitigate the problem of factually inaccurate text
generation and provide natural source attribution mechanism. Existing RALM
approaches focus on modifying the LM architecture in order to facilitate the
incorporation of external information, significantly complicating deployment.
This paper considers a simple alternative, which we dub In-Context RALM:
leaving the LM architecture unchanged and prepending grounding documents to the
input, without any further training of the LM. We show that In-Context RALM
that builds on off-the-shelf general purpose retrievers provides surprisingly
large LM gains across model sizes and diverse corpora. We also demonstrate that
the document retrieval and ranking mechanism can be specialized to the RALM
setting to further boost performance. We conclude that In-Context RALM has
considerable potential to increase the prevalence of LM grounding, particularly
in settings where a pretrained LM must be used without modification or even via
API access.
cite arxiv:2302.00083Comment: Accepted for publication in Transactions of the Association for Computational Linguistics (TACL). pre-MIT Press publication version
%0 Generic
%1 ram2023incontext
%A Ram, Ori
%A Levine, Yoav
%A Dalmedigos, Itay
%A Muhlgay, Dor
%A Shashua, Amnon
%A Leyton-Brown, Kevin
%A Shoham, Yoav
%D 2023
%K llm retrieval
%T In-Context Retrieval-Augmented Language Models
%U http://arxiv.org/abs/2302.00083
%X Retrieval-Augmented Language Modeling (RALM) methods, which condition a
language model (LM) on relevant documents from a grounding corpus during
generation, were shown to significantly improve language modeling performance.
In addition, they can mitigate the problem of factually inaccurate text
generation and provide natural source attribution mechanism. Existing RALM
approaches focus on modifying the LM architecture in order to facilitate the
incorporation of external information, significantly complicating deployment.
This paper considers a simple alternative, which we dub In-Context RALM:
leaving the LM architecture unchanged and prepending grounding documents to the
input, without any further training of the LM. We show that In-Context RALM
that builds on off-the-shelf general purpose retrievers provides surprisingly
large LM gains across model sizes and diverse corpora. We also demonstrate that
the document retrieval and ranking mechanism can be specialized to the RALM
setting to further boost performance. We conclude that In-Context RALM has
considerable potential to increase the prevalence of LM grounding, particularly
in settings where a pretrained LM must be used without modification or even via
API access.
@misc{ram2023incontext,
abstract = {Retrieval-Augmented Language Modeling (RALM) methods, which condition a
language model (LM) on relevant documents from a grounding corpus during
generation, were shown to significantly improve language modeling performance.
In addition, they can mitigate the problem of factually inaccurate text
generation and provide natural source attribution mechanism. Existing RALM
approaches focus on modifying the LM architecture in order to facilitate the
incorporation of external information, significantly complicating deployment.
This paper considers a simple alternative, which we dub In-Context RALM:
leaving the LM architecture unchanged and prepending grounding documents to the
input, without any further training of the LM. We show that In-Context RALM
that builds on off-the-shelf general purpose retrievers provides surprisingly
large LM gains across model sizes and diverse corpora. We also demonstrate that
the document retrieval and ranking mechanism can be specialized to the RALM
setting to further boost performance. We conclude that In-Context RALM has
considerable potential to increase the prevalence of LM grounding, particularly
in settings where a pretrained LM must be used without modification or even via
API access.},
added-at = {2023-08-17T15:01:23.000+0200},
author = {Ram, Ori and Levine, Yoav and Dalmedigos, Itay and Muhlgay, Dor and Shashua, Amnon and Leyton-Brown, Kevin and Shoham, Yoav},
biburl = {https://www.bibsonomy.org/bibtex/20f1f693a0ec6173158698843dff3d65c/lisa-ee},
description = {In-Context Retrieval-Augmented Language Models},
interhash = {12225b75694ec58ba2ce9a05e0891298},
intrahash = {0f1f693a0ec6173158698843dff3d65c},
keywords = {llm retrieval},
note = {cite arxiv:2302.00083Comment: Accepted for publication in Transactions of the Association for Computational Linguistics (TACL). pre-MIT Press publication version},
timestamp = {2023-08-17T15:01:23.000+0200},
title = {In-Context Retrieval-Augmented Language Models},
url = {http://arxiv.org/abs/2302.00083},
year = 2023
}