SparsePO: Controlling Preference Alignment of LLMs via Sparse Token Masks

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Christopoulou, Fenia, Cardenas, Ronald, Lampouras, Gerasimos, Bou-Ammar, Haitham, Wang, Jun
Format: Preprint
Published: 2024
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866909878871654400
author Christopoulou, Fenia
Cardenas, Ronald
Lampouras, Gerasimos
Bou-Ammar, Haitham
Wang, Jun
author_facet Christopoulou, Fenia
Cardenas, Ronald
Lampouras, Gerasimos
Bou-Ammar, Haitham
Wang, Jun
contents Direct alignment algorithms have proven an effective step for aligning language models to human-desired behaviors. Current variants of the 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 equally by each word in a sequence 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 balance reward and KL divergence contributions at the token level, learning an optimal level of mask sparsity. Extensive experiments illustrate the effectiveness of our approach at aligning to preference proxies, including sentiment control, helpfulness and harmlessness, and summary quality. Our method obtains +10% and +3% win rate points in summarization and dialogue scenarios, respectively, without compromising model reasoning or the relevancy and faithfulness of the summary response.
format Preprint
id arxiv_https___arxiv_org_abs_2410_05102
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle SparsePO: Controlling Preference Alignment of LLMs via Sparse Token Masks
Christopoulou, Fenia
Cardenas, Ronald
Lampouras, Gerasimos
Bou-Ammar, Haitham
Wang, Jun
Computation and Language
Artificial Intelligence
Machine Learning
Direct alignment algorithms have proven an effective step for aligning language models to human-desired behaviors. Current variants of the 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 equally by each word in a sequence 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 balance reward and KL divergence contributions at the token level, learning an optimal level of mask sparsity. Extensive experiments illustrate the effectiveness of our approach at aligning to preference proxies, including sentiment control, helpfulness and harmlessness, and summary quality. Our method obtains +10% and +3% win rate points in summarization and dialogue scenarios, respectively, without compromising model reasoning or the relevancy and faithfulness of the summary response.
title SparsePO: Controlling Preference Alignment of LLMs via Sparse Token Masks
topic Computation and Language
Artificial Intelligence
Machine Learning
url https://arxiv.org/abs/2410.05102