Cascade Reward Sampling for Efficient Decoding-Time Alignment

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Li, Bolian, Wang, Yifan, Lochab, Anamika, Grama, Ananth, Zhang, Ruqi
Format: Preprint
Published: 2024
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866915424103301120
author Li, Bolian
Wang, Yifan
Lochab, Anamika
Grama, Ananth
Zhang, Ruqi
author_facet Li, Bolian
Wang, Yifan
Lochab, Anamika
Grama, Ananth
Zhang, Ruqi
contents Aligning large language models (LLMs) with human preferences is essential for their applications. Recently, decoding-time alignment has emerged as an effective plug-and-play technique that avoids fine-tuning model parameters. This approach retains the general utility of pretrained LLMs but often suffers from significant inefficiencies during decoding, primarily due to wasted token generation and excessive reward evaluations. To address these challenges, we introduce Cascade Reward Sampling (CARDS) to resolve both efficiency bottlenecks in decoding-time alignment. Specifically, we develop a segment-level rejection sampling algorithm that minimizes redundant computations of both LLMs and reward models (RMs). Central to CARDS is an uncertainty-based segmentation mechanism, which ensures the accuracy of RMs evaluations on incomplete segments. Furthermore, we provide a detailed analysis of reward scores on segments to elucidate the improved alignment performance. Experimental results demonstrate that CARDS significantly improves decoding efficiency, alignment quality, and general utility compared to existing decoding-time alignment methods, achieving approximately a 70% reduction in decoding time and over 90% win-ties in utility and safety benchmarks.
format Preprint
id arxiv_https___arxiv_org_abs_2406_16306
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Cascade Reward Sampling for Efficient Decoding-Time Alignment
Li, Bolian
Wang, Yifan
Lochab, Anamika
Grama, Ananth
Zhang, Ruqi
Computation and Language
Machine Learning
Aligning large language models (LLMs) with human preferences is essential for their applications. Recently, decoding-time alignment has emerged as an effective plug-and-play technique that avoids fine-tuning model parameters. This approach retains the general utility of pretrained LLMs but often suffers from significant inefficiencies during decoding, primarily due to wasted token generation and excessive reward evaluations. To address these challenges, we introduce Cascade Reward Sampling (CARDS) to resolve both efficiency bottlenecks in decoding-time alignment. Specifically, we develop a segment-level rejection sampling algorithm that minimizes redundant computations of both LLMs and reward models (RMs). Central to CARDS is an uncertainty-based segmentation mechanism, which ensures the accuracy of RMs evaluations on incomplete segments. Furthermore, we provide a detailed analysis of reward scores on segments to elucidate the improved alignment performance. Experimental results demonstrate that CARDS significantly improves decoding efficiency, alignment quality, and general utility compared to existing decoding-time alignment methods, achieving approximately a 70% reduction in decoding time and over 90% win-ties in utility and safety benchmarks.
title Cascade Reward Sampling for Efficient Decoding-Time Alignment
topic Computation and Language
Machine Learning
url https://arxiv.org/abs/2406.16306