Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash
41 tokens/sec
GPT-4o
60 tokens/sec
Gemini 2.5 Pro Pro
44 tokens/sec
o3 Pro
8 tokens/sec
GPT-4.1 Pro
50 tokens/sec
DeepSeek R1 via Azure Pro
28 tokens/sec
2000 character limit reached

Aligning Large Language Models with Representation Editing: A Control Perspective (2406.05954v3)

Published 10 Jun 2024 in cs.AI, cs.LG, cs.SY, and eess.SY

Abstract: Aligning LLMs with human objectives is crucial for real-world applications. However, fine-tuning LLMs for alignment often suffers from unstable training and requires substantial computing resources. Test-time alignment techniques, such as prompting and guided decoding, do not modify the underlying model, and their performance remains dependent on the original model's capabilities. To address these challenges, we propose aligning LLMs through representation editing. The core of our method is to view a pre-trained autoregressive LLM as a discrete-time stochastic dynamical system. To achieve alignment for specific objectives, we introduce external control signals into the state space of this language dynamical system. We train a value function directly on the hidden states according to the BeLLMan equation, enabling gradient-based optimization to obtain the optimal control signals at test time. Our experiments demonstrate that our method outperforms existing test-time alignment techniques while requiring significantly fewer resources compared to fine-tuning methods. Our code is available at https://github.com/Lingkai-Kong/RE-Control.

User Edit Pencil Streamline Icon: https://streamlinehq.com
Authors (10)
  1. Lingkai Kong (34 papers)
  2. Haorui Wang (13 papers)
  3. Wenhao Mu (4 papers)
  4. Yuanqi Du (52 papers)
  5. Yuchen Zhuang (37 papers)
  6. Yifei Zhou (24 papers)
  7. Yue Song (56 papers)
  8. Rongzhi Zhang (18 papers)
  9. Kai Wang (624 papers)
  10. Chao Zhang (907 papers)
Citations (8)