SparsePO: Controlling Preference Alignment of LLMs via Sparse Token Masks

要約

好みの最適化 (PO) は、言語モデルを人間の望ましい行動に合わせるための効果的なステップであることが証明されています。
現在のバリアントは、オフラインの Direct Preference Optimization 目標に従って、すべてのトークンが KL 発散のシグナルと損失関数への報酬に寄与する厳密な設定に焦点を当てています。
ただし、人間の好みは、シーケンス内の各単語に均等に影響を受けるのではなく、多くの場合、特定の単語やフレーズに依存します。
有害な用語が存在すると、好ましくない反応が生じます。
この観察に基づいて、我々は、PO 中にすべてのトークンが均等に重み付けされるべきではないと主張し、PO トレーニング中に各トークンに対応する KL ダイバージェンスと報酬の重み付けを自動的に学習することを目的とした SparsePO と呼ばれる柔軟な目標を提案します。
私たちは、参照モデル自体から導出するか、オンザフライで学習できる重みマスクの 2 つの異なるバリアントを提案します。
特に、私たちの方法は学習されたマスクにスパース性を誘発し、モデルがトークンレベルで最適な重み付け報酬とKLダイバージェンスの寄与を学習し、マスクのスパース性の最適なレベルを学習できるようにします。
感情制御、対話、テキストの要約、テキストからコードへの生成など、複数のドメインでの広範な実験により、私たちのアプローチがターゲットタスクに応じてトークンに意味のある重みを割り当て、望ましい優先順位でより多くの応答を生成し、推論タスクを向上させることが示されています。
他のトークンレベルおよびレスポンスレベルのPO方法と比較して、最大2パーセントポイントです。

要約(オリジナル)

Preference Optimization (PO) has proven an effective step for aligning language models to human-desired behaviors. Current variants, following the offline Direct Preference Optimization objective, have focused on a strict setting where all tokens are contributing signals of KL divergence and rewards to the loss function. However, human preference is not affected by each word in a sequence equally but is often dependent on specific words or phrases, e.g. existence of toxic terms leads to non-preferred responses. Based on this observation, we argue that not all tokens should be weighted equally during PO and propose a flexible objective termed SparsePO, that aims to automatically learn to weight the KL divergence and reward corresponding to each token during PO training. We propose two different variants of weight-masks that can either be derived from the reference model itself or learned on the fly. Notably, our method induces sparsity in the learned masks, allowing the model to learn how to best weight reward and KL divergence contributions at the token level, learning an optimal level of mask sparsity. Extensive experiments on multiple domains, including sentiment control, dialogue, text summarization and text-to-code generation, illustrate that our approach assigns meaningful weights to tokens according to the target task, generates more responses with the desired preference and improves reasoning tasks by up to 2 percentage points compared to other token- and response-level PO methods.

arxiv情報

著者 Fenia Christopoulou,Ronald Cardenas,Gerasimos Lampouras,Haitham Bou-Ammar,Jun Wang
発行日 2024-10-07 15:01:29+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.AI, cs.CL, cs.LG パーマリンク