CycleAlign: Iterative Distillation from Black-box LLM to White-box Models for Better Human Alignment

Jixiang Hong, Quan Tu, Changyu Chen, Xing Gao, Ji Zhang, Rui Yan · DOI

Abstract

Language models trained on large-scale corpus often generate content that is harmful, toxic, or contrary to human preferences, making their alignment with human values a critical concern. Reinforcement learning from human feedback (RLHF) with algorithms like PPO is a prevalent approach for alignment but is often complex, unstable, and resource-intensive. Recently, ranking-based alignment methods have emerged, offering stability and effectiveness by replacing the RL framework with supervised fine-tuning, but they are costly due to the need for annotated data. Considering that existing large language models (LLMs) like ChatGPT are already relatively well-aligned and cost-friendly, researchers have begun to align the language model with human preference from AI feedback. The common practices, which unidirectionally distill the instruction-following responses from LLMs, are constrained by their bottleneck. Thus we introduce CycleAlign to distill alignment capabilities from parameter-invisible LLMs (black-box) to a parameter-visible model (white-box) in an iterative manner. With in-context learning (ICL) as the core of the cycle, the black-box models are able to rank the model-generated responses guided by human-craft instruction and demonstrations about their preferences. During iterative interaction, the white-box models also have a judgment about responses generated by them. Consequently, the agreement ranking could be viewed as a pseudo label to dynamically update the in-context demonstrations and improve the preference ranking ability of black-box models. Through multiple interactions, the CycleAlign framework could align the white-box model with the black-box model effectively in a low-resource way. Empirical results illustrate that the model fine-tuned by CycleAlign remarkably exceeds existing methods, and achieves the state-of-the-art performance in alignment with human value.

Introduction

Aligning Large Language Models (LLMs) with human values—specifically helpfulness, harmlessness, and honesty—is a central challenge in AI safety. While Reinforcement Learning from Human Feedback (RLHF) is the standard paradigm, its implementation is often plagued by instability and the requirement for vast amounts of expensive human-labeled data.

To address these issues, researchers have turned to distillation, where smaller "white-box" models (e.g., LLaMA) learn from the outputs of larger, well-aligned "black-box" models (e.g., ChatGPT). However, traditional unidirectional distillation often hits a performance ceiling because it lacks a feedback loop. CycleAlign overcomes this by establishing a cyclical collaborative framework that iteratively refines the alignment of the white-box model through dynamic interaction with the black-box teacher.

The CycleAlign Framework

CycleAlign operates as a conversation between the white-box model being trained and a black-box teacher. The process is broken down into five distinct stages:

  1. Sampling: The white-box model generates multiple candidate responses to a given instruction.
  2. Dual Ranking: The black-box model ranks these responses using In-Context Learning (ICL), while the white-box model ranks its own responses based on internal logit probabilities.
  3. Agreement & Pseudo-labeling: The system identifies an "agreement ranking" where both models concur. This consensus serves as a high-quality pseudo-label for training.
  4. Dynamic ICL: These agreement rankings are fed back into the black-box model as dynamic demonstrations, allowing the teacher to provide more tailored feedback in subsequent rounds.
  5. Optimization: The white-box model is updated using ranking-based Supervised Fine-Tuning (SFT) objectives such as RRHF or PRO.
The iterative workflow of CycleAlign, showing the interaction between white-box and black-box models.

This iterative refinement allows the black-box model's feedback to evolve alongside the white-box model's capabilities, effectively breaking the distillation bottleneck.

Experimental Results

The effectiveness of CycleAlign was evaluated using the HH-RLHF dataset, which covers harmlessness and helpfulness across various subsets. Performance was measured using reward models and qualitative win-rate comparisons judged by GPT-4 and human annotators.

Performance comparison of CycleAlign against various alignment methods across different backbones and datasets.

As shown in the results, CycleAlign significantly outperforms standard PPO and basic ranking-based SFT methods. For instance, a LLaMA-7B model trained with CycleAlign achieved a total reward score of 68.43, nearing the performance of ChatGPT (70.43) and substantially exceeding the 58.65 score of PPO. Furthermore, qualitative evaluations showed that CycleAlign-trained models won approximately 70% of the time against state-of-the-art PRO methods in harmlessness tasks.

Discussion and Conclusion

The success of CycleAlign stems from two key innovations: the use of In-Context Learning as a dynamic "pivot" for feedback and the use of "agreement" as a filter for high-quality training signals. By iteratively sharpening the models against each other, CycleAlign achieves state-of-the-art alignment in a low-resource setting, requiring only a fraction of the full dataset to reach high performance.

While the method depends on black-box API access and involves iterative computational costs, it represents a significant step toward more efficient and stable LLM alignment. Future work will explore scaling this framework to larger model architectures and investigating the impact of teacher model biases on the distillation process.

Summary updated

BibTeX
@inproceedings{hong2024cyclealign,
  author = {Jixiang Hong and Quan Tu and Changyu Chen and Xing Gao and Ji Zhang and Rui Yan},
  title = {{CycleAlign: Iterative Distillation from Black-box LLM to White-box Models for Better Human Alignment}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2024},
  doi = {10.18653/v1/2024.findings-acl.869},
}
Figure