Abstract
Direct Multi-Turn Preference Optimization (DMPO) is a novel framework designed to fine-tune Large Language Models (LLMs) into robust multi-turn agents. Standard Direct Preference Optimization (DPO) often fails in multi-step environments because its normalization term becomes state-dependent. DMPO addresses this by introducing a State-Action Occupancy Measure (SAOM) constraint and theoretical length normalization. Our experiments across benchmarks like WebShop and ScienceWorld show that DMPO significantly mitigates compounding errors and outperforms existing methods, particularly in noisy and out-of-distribution scenarios.
Introduction: The Challenge of Multi-Turn Agents
Building effective language agents—LLMs capable of tool use, web browsing, or scientific reasoning—requires navigating complex, multi-step environments. Traditional training methods like Behavioral Cloning (BC) or Supervised Fine-Tuning (SFT) are prone to compounding errors: a single mistake early in a trajectory can lead the agent into unfamiliar states, causing task failure.
While Reinforcement Learning (RL) can address these issues, it is often unstable. Direct Preference Optimization (DPO) has simplified alignment for single-turn chat, but its mathematical assumptions break down in multi-turn scenarios. Specifically, the normalization term (partition function) in DPO becomes state-dependent, preventing it from canceling out during optimization.
Methods: From Policy to Occupancy Measures
DMPO introduces two primary innovations to adapt preference optimization for agents:
- State-Action Occupancy Measure (SAOM) Constraint: Instead of constraining only the policy (the probability of an action given a state), DMPO constrains the distribution of state-action pairs the agent visits. This shift ensures the partition function becomes a global constant, allowing for a clean derivation of the loss function.
- Length Normalization: Trajectories in agent tasks vary significantly in length. DMPO incorporates theoretical length normalization into the Bradley-Terry preference model, eliminating biases toward shorter or longer paths that are not based on quality.
- Early-Step Reweighting: The DMPO loss function naturally prioritizes early actions through a discount function $\phi(t, T)$. This aligns with the intuition that successful task completion often hinges on correct initial steps.
Experimental Evaluation
The researchers evaluated DMPO on three major benchmarks:
- WebShop: Simulated e-commerce navigation.
- ScienceWorld: Text-based elementary science experiments.
- ALFWorld: Embodied household task simulation.
The study utilized Mistral-7B and Llama-2-7B models, testing on both "Seen" (in-distribution) and "Unseen" (out-of-distribution) scenarios.
Key Results and Insights
DMPO consistently outperformed standard DPO, particularly in "noisy" data regimes where negative examples are low-quality failures. On ScienceWorld (Unseen), DMPO achieved a reward of 0.651, compared to 0.629 for DPO using a Mistral-7B base.
In "clean" settings, DMPO surpassed state-of-the-art methods like Exploration-based Trajectory Optimization (ETO) and PPO. Notably, on WebShop, DMPO reached a reward of 0.701, exceeding GPT-4's performance of 0.632 on the same benchmark. The model's improved performance on "Unseen" tasks suggests that the SAOM constraint encourages learning the underlying task logic rather than simple trajectory memorization.
Conclusion and Future Work
DMPO provides a robust, mathematically grounded framework for fine-tuning multi-turn language agents. By addressing the state-dependency of the partition function and incorporating length normalization, it overcomes the hurdles that limited DPO's utility for agents. Future research will explore token-wise optimization and scaling these benefits to larger model architectures.
Summary updated