深層言語ネットワーク:変分推論を用いたスタック型LLMの結合プロンプト学習
Deep Language Networks: Joint Prompt Training of Stacked LLMs using Variational Inference
June 21, 2023
著者: Alessandro Sordoni, Xingdi Yuan, Marc-Alexandre Côté, Matheus Pereira, Adam Trischler, Ziang Xiao, Arian Hosseini, Friederike Niedtner, Nicolas Le Roux
cs.AI
要旨
大規模言語モデル(LLM)をネットワーク内の確率的言語層として捉え、各層における学習可能なパラメータを自然言語プロンプトと見なします。我々はこのような層を2つ積み重ね、1つの層の出力を次の層に入力します。この積層アーキテクチャをDeep Language Network(DLN)と呼びます。まず、1層の言語ネットワーク(DLN-1)におけるプロンプト最適化を効果的に行う方法を示します。次に、2つのプロンプトを学習する必要がある2層DLN(DLN-2)の訓練方法を示します。第1層の出力を周辺化する潜在変数と見なし、共同プロンプト訓練のための変分推論アルゴリズムを考案します。DLN-2は単層よりも高い性能を達成し、ネットワーク内の各LLMがより小さく能力が低い場合でも、few-shot GPT-4に匹敵する場合があります。DLNのコードはオープンソースです:https://github.com/microsoft/deep-language-networks。
English
We view large language models (LLMs) as stochastic language layers in
a network, where the learnable parameters are the natural language
prompts at each layer. We stack two such layers, feeding the output of
one layer to the next. We call the stacked architecture a Deep Language
Network (DLN). We first show how to effectively perform prompt optimization
for a 1-Layer language network (DLN-1). We then show how to train 2-layer DLNs
(DLN-2), where two prompts must be learnt. We consider the output of the first
layer as a latent variable to marginalize, and devise a variational inference
algorithm for joint prompt training. A DLN-2 reaches higher performance than a
single layer, sometimes comparable to few-shot GPT-4 even when each LLM in the
network is smaller and less powerful. The DLN code is open source:
https://github.com/microsoft/deep-language-networks .