Preprint
Large Language Models

Aligning LLMs with Demonstrated Feedback

Omar Shaikh, Michelle Lam, Joey Hejna, Y. Shao, Hyundong Justin Cho, Michael S. Bernstein, Diyi Yang
June 2, 2024International Conference on Learning Representations44 citations

44

Citations

2

Influential Citations

International Conference on Learning Representations

Venue

2024

Year

Abstract

Language models are aligned to emulate the collective voice of many, resulting in outputs that align with no one in particular. Steering LLMs away from generic output is possible through supervised finetuning or RLHF, but requires prohibitively large datasets for new ad-hoc tasks. We argue that it is instead possible to align an LLM to a specific setting by leveraging a very small number (<10) of demonstrations as feedback. Our method, Demonstration ITerated Task Optimization (DITTO), directly aligns language model outputs to a user's demonstrated behaviors. Derived using ideas from online imitation learning, DITTO cheaply generates online comparison data by treating users' demonstrations as preferred over output from the LLM and its intermediate checkpoints. Concretely, DITTO operates by having an LLM generate examples that are presumed to be inferior to expert demonstrations. The method iteratively constructs pairwise preference relationships between these LLM-generated samples and expert demonstrations, potentially including comparisons between different training checkpoints. These constructed preference pairs are then used to train the model using a preference optimization algorithm (e.g. DPO). We evaluate DITTO's ability to learn fine-grained style and task alignment across domains such as news articles, emails, and blog posts. Additionally, we conduct a user study soliciting a range of demonstrations from participants (N = 16). Across our benchmarks and user study, we find that win-rates for DITTO outperform few-shot prompting, supervised fine-tuning, and other self-play methods by an avg. of 19% points. By using demonstrations as feedback directly, DITTO offers a novel method for effective customization of LLMs.

Analysis

Why This Paper Matters

This paper addresses a critical gap in LLM alignment: the inability to efficiently customize models to individual user preferences without massive datasets. Current alignment methods like RLHF produce generic outputs that reflect the average of many voices, failing to capture the nuanced style and task requirements of specific users. DITTO's key insight is that a handful of demonstrations—as few as 10—can serve as effective feedback for steering an LLM toward a user's desired behavior. This is particularly important for ad-hoc tasks where collecting large preference datasets is impractical, such as personalizing email tone, blog writing style, or news article formatting.

The significance extends beyond mere efficiency. By framing alignment as an online imitation learning problem, DITTO introduces a principled way to generate preference data on the fly, avoiding the need for human annotators or pre-collected comparisons. This could democratize LLM customization, allowing individual users to tailor models to their unique communication styles without requiring machine learning expertise. The paper's validation through both benchmark evaluations and a user study (N=16) strengthens its practical relevance, showing that the method works in real-world scenarios with diverse user demonstrations.

Technical Contributions

  • Online Imitation Learning Framework: DITTO reformulates LLM alignment as an online imitation learning problem, where the model iteratively generates samples that are compared against expert demonstrations to construct preference pairs.
  • Iterative Preference Construction: The method builds pairwise comparisons not only between demonstrations and current LLM outputs but also across different training checkpoints, creating a richer training signal.
  • Integration with DPO: DITTO leverages Direct Preference Optimization (DPO) as the underlying preference optimization algorithm, enabling stable and efficient training without needing a separate reward model.
  • Minimal Data Requirement: The approach requires fewer than 10 demonstrations per task, drastically reducing the data collection burden compared to supervised fine-tuning or RLHF.
  • Cross-Domain Validation: The method is evaluated on diverse domains including news articles, emails, and blog posts, demonstrating broad applicability.

Results

DITTO achieves an average win-rate improvement of 19 percentage points over baselines including few-shot prompting, supervised fine-tuning, and other self-play methods. This improvement is consistent across both automated benchmarks and a user study with 16 participants who provided demonstrations for various tasks. The method's ability to learn fine-grained style and task alignment is particularly notable, as it captures subtle user preferences that generic models miss.

Significance

DITTO represents a practical step toward personalized AI systems that adapt to individual users with minimal effort. By reducing the data requirement to a handful of demonstrations, it lowers the barrier for non-expert users to customize LLMs for their specific needs. This could have broad implications for applications in writing assistance, customer service, and content creation, where one-size-fits-all outputs are often inadequate. The method's grounding in online imitation learning also provides a theoretical foundation for future work on efficient, user-driven alignment.