CLAIApr 11, 2024

From Words to Numbers: Your Large Language Model Is Secretly A Capable Regressor When Given In-Context Examples

arXiv:2404.07544v368 citationsh-index: 43
AI Analysis

This work addresses the problem of enabling LLMs to perform regression tasks efficiently for AI practitioners, showing incremental improvements in applying in-context learning to regression.

The paper investigates how pre-trained large language models (LLMs) like GPT-4 and Claude 3 can perform linear and non-linear regression tasks using in-context examples without additional training, finding that they rival or outperform traditional supervised methods such as Random Forest and Gradient Boosting, with Claude 3 outperforming many on the Friedman #2 dataset.

We analyze how well pre-trained large language models (e.g., Llama2, GPT-4, Claude 3, etc) can do linear and non-linear regression when given in-context examples, without any additional training or gradient updates. Our findings reveal that several large language models (e.g., GPT-4, Claude 3) are able to perform regression tasks with a performance rivaling (or even outperforming) that of traditional supervised methods such as Random Forest, Bagging, or Gradient Boosting. For example, on the challenging Friedman #2 regression dataset, Claude 3 outperforms many supervised methods such as AdaBoost, SVM, Random Forest, KNN, or Gradient Boosting. We then investigate how well the performance of large language models scales with the number of in-context exemplars. We borrow from the notion of regret from online learning and empirically show that LLMs are capable of obtaining a sub-linear regret.

Code Implementations1 repo
Foundations

The foundational work for this paper's niche, ranked by how specifically the neighbourhood builds on it — not by global fame.

Your Notes