arXiv:2502.20795cs.CL2025-02中稿 · ICLR被引 2

用预测控制思想让大模型生成时自动对齐人类偏好,无需微调。

Test-Time Alignment for Large Language Models via Textual Model Predictive Control

  • 基于模型预测控制设计文本规划框架,分步优化输出质量。
  • 在翻译、长文本生成和代码合成任务中均提升表现,效果稳定。
  • 适合需要高质量生成但无法微调的场景,如实时对话系统。

通过微调对齐大语言模型与人类偏好成本高昂,促使人们探索推理时的轻量级替代方案。本文从序列决策视角出发,揭示两个根本挑战:若以词元为动作单位(如引导解码),会面临‘视野诅咒’;若以完整响应为动作单位(如传统迭代优化),则出现‘维度诅咒’。为此,我们借鉴控制理论中的模型预测控制(MPC)思想,提出文本模型预测控制(TMPC),一种适用于推理时对齐大模型的新颖预测规划框架。标准MPC依赖预定义的硬分割边界,而文本生成通常无明确分段。为此,TMPC引入两个受层次强化学习启发的原则:(1) 事后子目标识别,即分析生成过程中的中间产出,回溯识别高回报的子目标(如机器翻译中的句子或代码生成中的修复段);(2) 子目标条件重生成,利用已识别的高质量子目标指导后续规划迭代。通过基于已验证成果进行改进,确保稳定提升。TMPC在三种具有不同分段特性的任务上评估:话语级翻译、长文本生成和程序合成。结果表明其性能持续提升,展现出良好通用性。

原文摘要 · Abstract (English)

Aligning Large Language Models (LLMs) with human preferences through finetuning is resource-intensive, motivating lightweight alternatives at test time. We address test-time alignment through the lens of sequential decision making, a perspective that reveals two fundamental challenges. When actions are defined at the token level, as in guided decoding, alignment suffers from the curse of horizon. Conversely, when actions are at the response level, as in traditional iterative refinement, the curse of dimensionality emerges. To resolve this trade-off, we draw inspiration from Model Predictive Control (MPC) in control theory to propose Textual Model Predictive Control (TMPC), a novel predictive planning framework adapted for aligning LLMs at inference time. A key limitation of standard MPC is its reliance on predefined, hard segment boundaries, which are often absent in text generation. TMPC overcomes this by introducing two principles inspired by hierarchical reinforcement learning: (1) Hindsight Subgoal Identification, where TMPC analyzes generation subgoals to retrospectively identify high-reward intermediate outputs as subgoals. This allows the framework to discover meaningful, task-specific planning steps (e.g., a sentence in machine translation or a bug fix in code generation.). (2) Subgoal-Conditioned Re-Generation, where these identified subgoals are used to guide subsequent planning iterations. By conditioning on these proven, high-quality subgoals, TMPC ensures stable improvement by building upon previously validated successes. TMPC is evaluated on three tasks with distinct segmentation properties: discourse-level translation, long-form response generation, and program synthesis. The results demonstrate that TMPC consistently improves performance, highlighting the generality.

大模型对齐推理优化文本生成控制理论

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。