IterAlign: Iterative Constitutional Alignment of Large Language Models

Xiusi Chen, Hongzhi Wen, Sreyashi Nag, Chen Luo, Qingyu Yin +3 more
3/27/2024
cs.CL

No official code found. Best implementation: xiusic/IterAlign (5 stars, Apache-2.0, last commit 2024-05-03).

Abstract

With the rapid development of large language models (LLMs), aligning LLMs with human values and societal norms to ensure their reliability and safety has become crucial. Reinforcement learning with human feedback (RLHF) and Constitutional AI (CAI) have been proposed for LLM alignment. However, these methods require either heavy human annotations or explicitly pre-defined constitutions, which are labor-intensive and resource-consuming. To overcome these drawbacks, we study constitution-based LLM alignment and propose a data-driven constitution discovery and self-alignment framework called IterAlign. IterAlign leverages red teaming to unveil the weaknesses of an LLM and automatically discovers new constitutions using a stronger LLM. These constitutions are then used to guide self-correction of the base LLM. Such a constitution discovery pipeline can be run iteratively and automatically to discover new constitutions that specifically target the alignment gaps in the current LLM. Empirical results on several safety benchmark datasets and multiple base LLMs show that IterAlign successfully improves truthfulness, helpfulness, harmlessness and honesty, improving the LLM alignment by up to $13.5\%$ in harmlessness.

View on arXivView PDF

Code Implementations(1)

xiusic/IterAlignCommunity61%
Apache-2.0

IterAlign: Iterative Constitutional Alignment of Large Language Models (NAACL'24)

50PythonMay 2, 20242 years agoApache-2.0

Similar Papers

Cite this paper

@article{chen2024iteralign,
  title  = {IterAlign: Iterative Constitutional Alignment of Large Language Models},
  author = {Xiusi Chen and Hongzhi Wen and Sreyashi Nag and Chen Luo and Qingyu Yin and Ruirui Li and Zheng Li and Wei Wang},
  year   = {2024},
  eprint = {2403.18341},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2403.18341v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2403.18341.svg)](https://codeofpaper.com/paper/2403.18341)

Discussion