Introduction
In machine learning, there are critical non-trainable settings called hyperparameters that influence the performance and effectiveness of models. Hyperparameters include choices such as the type of architecture, the degree of regularization, which optimization method to use, and others. Hyperparameter optimization (HPO) seeks the best set of these settings for a given problem. Traditional methods for HPO, like random search or Bayesian optimization, have limitations, notably in defining a search space and dealing with the initial phase of search. This paper explores the potential of leveraging LLMs for HPO.
Methodology
A novel approach is proposed where LLMs, specifically variants of GPT, are used for HPO tasks. LLMs are prompted to suggest hyperparameters and are provided with feedback on model performance, which informs subsequent suggestions. The process continues iteratively until a resource budget is reached. The paper also introduces the use of LLMs to generate complete training code, treating the code itself as an adaptable hyperparameter. This allows for more flexible exploration beyond a predefined hyperparameter space. Empirical evaluations compare LLMs to traditional HPO methods on standard benchmarks, assessing efficiency and performance over multiple iterations.
Results
The findings demonstrate that LLMs can suggest effective hyperparameters that lead to comparable or superior model performance than traditional optimization methods within a limited search budget. The paper offers analyses on both simple 2D toy problems to visualize the optimization process and realistic HPO benchmarks. When tasked to generate training code, LLMs produced results that were more successful than random search in early evaluations, indicating potential for reducing the search space effectively. Additionally, the paper observes the positive impact of 'chain-of-thought' prompting, where providing reasoning with responses slightly improved outcomes.
Conclusion and Related Work
LLMs show promise as hyperparameter tuning assistants, achieving good performance and efficiently navigating the search space. The paper acknowledges existing hyperparameter optimization techniques and their challenges, placing the LLM approach in the broader context of HPO research. While recognizing limitations such as the potential for dataset contamination and cost restrictions associated with using commercial LLMs, the authors are optimistic about LLMs becoming more versatile and cost-effective for HPO applications in the future.