Reproduce “TAIA: Large Language Models are Out-of-Distribution Data Learners” on OpenResearch

Run Claude Code, Codex or any coding agent as a research agent: literature, hypotheses and experiments on your laptop, cluster or cloud GPUs.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

Shuyang Jiang, Yusheng Liao, Ya Zhang, Yanfeng Wang, Yu Wang

The paper introduces TAIA (Training All parameters but Inferring with only Attention), an inference-time intervention that allows large language models to effectively utilize out-of-distribution (OOD) data for fine-tuning. This method achieved superior performance on seven diverse downstream tasks and demonstrated improved robustness against red-teaming attacks, maintaining helpfulness while increasing safety.

Key insights

  • Self-attention modules are primarily responsible for enhancing an LLM's instruction-following capabilities, while feed-forward networks (FFNs) predominantly encode pre-trained parametric knowledge.
  • Fine-tuning with out-of-distribution (OOD) data can introduce 'noisy parametric knowledge' into FFNs, leading to catastrophic forgetting of valuable pre-trained knowledge.
  • By discarding fine-tuned FFN parameters at inference, the method prevents detrimental shifts caused by OOD data while retaining beneficial self-attention updates for adaptive instruction following.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.