惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

F
Fortinet All Blogs
博客园 - 三生石上(FineUI控件)
小众软件
小众软件
人人都是产品经理
人人都是产品经理
V
Visual Studio Blog
Last Week in AI
Last Week in AI
V
V2EX
博客园_首页
IT之家
IT之家
Jina AI
Jina AI
博客园 - 叶小钗
The Cloudflare Blog
T
Tailwind CSS Blog
腾讯CDC
B
Blog
D
Docker
L
LangChain Blog
博客园 - 司徒正美
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
美团技术团队
Apple Machine Learning Research
Apple Machine Learning Research
爱范儿
爱范儿
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
GbyAI
GbyAI

Snorkel AI

Building AI-Native Systems for Federal Infrastructure: A Conversation with Rezaur Rahman Code World Models and AutoHarness for LLM Agents Benchtalks #1: Alex Shaw (Terminal-Bench, Harbor) – Building the Benchmark Factory Building FinQA: An Open RL Environment for Financial Reasoning Agents How Tool Discipline Let a 4B Model Outsmart a 235B Giant on Financial Tasks Coding agents don’t need to be perfect, they need to recover Closing the Evaluation Gap in Agentic AI SlopCodeBench: Measuring Code Erosion as Agents Iterate Introducing the Snorkel Agentic Coding Benchmark 2026: The year of environments Part V: Future Direction and Emerging Trends in Rubric-Based AI Evaluation The self-critique paradox: Why AI verification fails where it’s needed most Chat With the Terminal-Bench Team | Snorkel AI Intelligence per watt: A new metric for AI’s future Terminal-Bench 2.0: Raising the bar for AI agent evaluation Snorkeling in RL environments Introducing SnorkelSpatial: A Benchmark for LLM Spatial Reasoning Scaling Trust: Rubrics in Snorkel's Quality Process Evaluating Multi-Agent Systems in Enterprise Tool Use Evaluating Coding Agents with Terminal-Bench 2.0 Parsing isn’t neutral: why evaluation choices matter The science of rubric design The right tool for the job: An A-Z of rubrics Data quality and rubrics: how to build trust in your models Building the benchmark: inside our agentic insurance underwriting dataset Evaluating AI agents for insurance underwriting LLM observability: key practices, tools, and challenges Anthropic Claude + AWS: revolutionizing pharma data analytics with Snorkel AI Data-centric development of an enterprise AI agent with Snorkel Building the data development platform for specialized AI
LLM alignment techniques: 4 post-training approaches
Matthew Casey · 2025-03-04 · via Snorkel AI

Large language models (LLMs) have revolutionized how we interact with technology, enabling everything from AI-powered customer service to advanced research tools. However, as these models grow more powerful, they also become more unpredictable. Misaligned LLMs can generate harmful, unhelpful, or downright nonsensical responses—posing risks to both users and organizations. This is where LLM alignment techniques come in.

Alignment ensures that an AI model’s outputs align with specific values, principles, or goals, such as generating polite, safe, and accurate responses or adhering to a company’s ethical guidelines.

LLM alignment techniques come in three major varieties:

  1. Prompt engineering that explicitly tells the model how to behave.
  2. Supervised fine-tuning with targeted and curated prompts and responses.
  3. Post-training preference optimization, which takes feedback from both desirable and undesirable responses and adjusts the model accordingly.

This piece will focus on four post-training techniques worth knowing.

While alignment techniques vary, their shared goal is to shape LLM behavior to better meet human needs and expectations. Below, we’ll explore several popular methods for LLM alignment, breaking down how they work, their strengths, and their challenges.

Reinforcement Learning from Human Feedback (RLHF)

Reinforcement Learning from Human Feedback (RLHF) is one of the most widely used techniques for aligning large language models.

After pretraining a model on large datasets, RLHF adds a post-training phase. In this phase, human annotators review the model’s outputs, identifying which ones are preferred. These preferences are then used to train a reward model, which predicts the quality of new outputs. The reward model is usually smaller than the target LLM, but can be any size. Finally, the reward model guides the LLM’s behavior using reinforcement learning algorithms, such as Proximal Policy Optimization (PPO).

How RLHF works (in simple terms)

  1. Humans compare different responses from the model and either pick the better ones or rank responses from best to worst.
  2. A reward model learns to predict these human preferences.
  3. The LLM is fine-tuned to produce responses that the reward model rates as “good.”

RLHF’s advantages

  • Proven success: Used by OpenAI for ChatGPT, RLHF is a tried-and-true method for improving model alignment.
  • Handles complex goals: By encoding nuanced human preferences into the reward model, RLHF can optimize for multiple criteria (e.g., helpfulness, safety, and politeness).

RLHF’s disadvantages

  • Complex and expensive: RLHF requires training a separate reward model and running reinforcement learning, which can be computationally intensive.
  • Risk of overfitting: The model may over-optimize for specific reward metrics, leading to unintended behaviors.
  • Scaling challenges: Reliance on human annotations makes RLHF difficult to scale across niche use cases.

Direct Preference Optimization (DPO)

Direct Preference Optimization (DPO) simplifies the alignment process by skipping the separate reward model altogether. Instead, DPO trains the LLM directly on human preference data. Researchers at Stanford demonstrated that LLMs inherently encode information that can approximate human preferences, which can be leveraged for alignment without explicitly training a separate reward model. By optimizing the likelihood of human-preferred responses, DPO fine-tunes the LLM without the added complexity of reinforcement learning.

How DPO works (in simple terms)

  1. Collect data showing which responses are “good” or “bad.”
  2. Fine-tune the LLM directly on this data, increasing the likelihood of good responses and decreasing the likelihood of bad ones.

DPO’s advantages

  • Simplicity: DPO requires no separate reward model or reinforcement learning algorithm, making it easier to implement.
  • Stability: DPO avoids some of the instability issues associated with reinforcement learning.
  • Efficiency: Computationally cheaper than RLHF, DPO stands as a better option for smaller teams or less resource-intensive applications.

DPO’s disadvantages

  • Limited flexibility: While simpler, DPO may not handle highly complex alignment goals as well as RLHF.
  • Data quality dependency: Success depends heavily on having high-quality preference data.

Odds Ratio Preference Optimization (ORPO)

Odds Ratio Preference Optimization (ORPO) builds on ideas from RLHF and DPO but combines multiple steps into a single process. Instead of training a reward model and fine-tuning the LLM separately, ORPO uses a unified loss function to balance task-specific objectives with human preference alignment, streamlining the training process. This approach combines supervised fine-tuning with preference optimization in a mathematically integrated manner.

Orpo—one of many LLM alignment techniques available to data scientists

How ORPO works (in simple terms)

  1. Use labeled preference data to calculate a combined loss for both task accuracy and preference alignment.
  2. Fine-tune the LLM using this single loss function.

ORPO’s advantages

  • Efficiency: By merging two steps, ORPO reduces the overall training time and computational cost.
  • Improved performance: Studies show that ORPO can outperform RLHF and DPO on some benchmarks.

ORPO’s disadvantages

  • Implementation complexity: Designing a combined loss function requires careful calibration to avoid one objective dominating the other.
  • Niche use: ORPO is relatively new and less widely adopted, so best practices are still emerging.

Kahneman-Tversky optimization (KTO)

Kahneman-Tversky optimization (KTO) is inspired by economics and focuses on how humans perceive utility. Much like the formulation for SFT, this can be done using prompt-response pairs that have been labeled as “good” or “bad,” optimizing the model to favor responses rated as good while being robust to label noise.

KTO—one of many LLM alignment techniques available to data scientists.

How KTO works (in simple terms):

  1. Label responses as either good or bad.
  2. Use these labels to train the LLM to favor good responses while ignoring occasional inconsistencies in the labels.

KTO’s advantages:

  • Robust to noisy data: KTO is less affected by imperfect or inconsistent labeling compared to other methods.
  • Simple labeling: Requires only binary labels, which are easier to collect than detailed rankings or scores.

KTO’s disadvantages:

  • Limited granularity: Binary labels lack the nuance of other methods, which may limit performance for complex alignment goals.
  • Less established: Like ORPO, KTO is relatively new and still under active research.

Key Takeaways

  • Alignment is crucial for ensuring that LLMs generate safe, helpful, and context-appropriate responses.
  • RLHF holds a vital place in alignment pipelines but can be complex and costly.
  • DPO simplifies the process and reduces computational overhead, making it ideal for resource-constrained teams.
  • ORPO and KTO are emerging methods offering promising alternatives to traditional alignment techniques, with unique strengths in efficiency and robustness.
  • Translating abstract human values, ethics, and context-specific goals into measurable metrics remains a significant challenge across all alignment methods.

When choosing an alignment method, organizations must weigh trade-offs like complexity, computational cost, and data quality requirements. Ultimately, the right approach depends on the specific use case, resources, and alignment goals.

Learn More

Follow Snorkel AI on LinkedInTwitter, and YouTube to be the first to see new posts and videos!