The Surprising Effectiveness of Test-Time Training for Few-Shot Learning

Ekin Akyürek, Mehul Damani, Adam Zweiger, Linlu Qiu, Han Guo +3 more
11/11/2024
cs.AIcs.CLcs.LG

No official code found. Best implementation: ekinakyurek/marc (356 stars, MIT, last commit 2025-11-10).

Abstract

Language models (LMs) have shown impressive performance on tasks within their training distribution, but often struggle with structurally novel tasks even when given a small number of in-context task examples. We investigate the effectiveness of test-time training (TTT) -- temporarily updating model parameters during inference using a loss derived from input data -- as a mechanism for improving LMs' reasoning and few-shot learning capabilities. On the Abstraction and Reasoning Corpus (ARC), performing TTT with in-context examples yields up to $6\times$ higher accuracy compared to fine-tuned baselines -- reaching $53.0\%$ on the public validation set with an 8B-parameter LM and $61.9\%$ when ensembled with program-synthesis methods, matching average human performance. On BIG-Bench Hard (BBH), TTT on in-context examples surpasses standard few-shot prompting in the $10$-shot setting by $7.3$ percentage points ($50.5\%$ to $57.8\%$). Our findings highlight the limitations of in-context learning for novel tasks and demonstrate the potential of test-time training to enhance language model adaptability.

View on arXivView PDF

Code Implementations(1)

ekinakyurek/marcCommunity100%
MIT

Public repository for "The Surprising Effectiveness of Test-Time Training for Abstract Reasoning"

35635PythonNov 10, 202411 months agoMIT

Cite this paper

@article{akyrek2024surprising,
  title  = {The Surprising Effectiveness of Test-Time Training for Few-Shot Learning},
  author = {Ekin Akyürek and Mehul Damani and Adam Zweiger and Linlu Qiu and Han Guo and Jyothish Pari and Yoon Kim and Jacob Andreas},
  year   = {2024},
  eprint = {2411.07279},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2411.07279v2},
  journal = {ICML 2024 2024}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2411.07279.svg)](https://codeofpaper.com/paper/2411.07279)

Discussion