LLM-FE: Automated Feature Engineering for Tabular Data with LLMs as Evolutionary Optimizers
Nikhil Abhyankar, Parshin Shojaee, Chandan K. Reddy
TL;DR
This work addresses automating feature engineering for tabular data by introducing LLM-FE, a framework that uses LLMs as knowledge-guided evolutionary optimizers to generate feature transformation programs. It formulates feature generation as a bilevel optimization where $T = \pi_\theta(\mathcal{X}_{train})$ and $f^* = \arg\min_f \mathcal{L}_f(f(\mathcal{T}(\mathcal{X}_{tr})), \mathcal{Y}_{tr})$, aiming to maximize $\mathcal{E}$ on $\mathcal{T}(\mathcal{X}_{val})$. The method integrates structured prompts, memory-based in-context learning, data-driven evaluation, and a multi-population evolutionary strategy to explore the feature space efficiently. Empirical results across 19 classification and 10 regression datasets show that LLM-FE consistently improves predictive performance for models like XGBoost, MLP, and TabPFN, often with favorable computation. The findings underscore the value of combining domain knowledge, evolutionary refinement, and data-driven feedback to produce impactful, interpretable features for tabular learning tasks.
Abstract
Automated feature engineering plays a critical role in improving predictive model performance for tabular learning tasks. Traditional automated feature engineering methods are limited by their reliance on pre-defined transformations within fixed, manually designed search spaces, often neglecting domain knowledge. Recent advances using Large Language Models (LLMs) have enabled the integration of domain knowledge into the feature engineering process. However, existing LLM-based approaches use direct prompting or rely solely on validation scores for feature selection, failing to leverage insights from prior feature discovery experiments or establish meaningful reasoning between feature generation and data-driven performance. To address these challenges, we propose LLM-FE, a novel framework that combines evolutionary search with the domain knowledge and reasoning capabilities of LLMs to automatically discover effective features for tabular learning tasks. LLM-FE formulates feature engineering as a program search problem, where LLMs propose new feature transformation programs iteratively, and data-driven feedback guides the search process. Our results demonstrate that LLM-FE consistently outperforms state-of-the-art baselines, significantly enhancing the performance of tabular prediction models across diverse classification and regression benchmarks.
