Large language models improve portfolio optimization by guiding evolution strategies
LLMDE: A Large Language Model-Driven Differential Evolution Algorithm for Portfolio Optimization
Neural and Evolutionary Computing
Summary
Optimizing portfolios to minimize risk and meet return goals can be tricky because it relies on setting many parameters manually. The authors created an approach where a large language model helps choose strategies and settings dynamically during the optimization process. They tested this method on benchmark problems and on selecting stocks for a portfolio optimization task, finding it performs well and adapts to constraints. This shows how language models can assist traditional optimization algorithms to make them more flexible and effective.
What this means in practice
- •For financial data teams: Optimize stock portfolios under risk and return constraints using adaptive algorithm settings guided by large language models.
- •For machine learning engineers: Enhance evolutionary algorithms by integrating large language models to dynamically adjust parameters for complex optimization tasks.
Authors
Rong Chai, Vaclav Snasel, Xiaopeng Wang, Seyedali Mirjalili, Crina Grosan
Abstract
This study proposes a Large Language Model-Driven Differential Evolution (LLMDE) algorithm to reduce the reliance on handcrafted hyperparameter design. The proposed algorithm leverages a prompt engineering strategy, allowing large language models (LLMs) to dynamically select mutation strategies and configure control parameters guided by optimization feedback, thus enhancing the performance of the DE algorithm. We evaluate the performance of LLMDE on the CEC2022 benchmark suite, comparing it with standard DE and representative metaheuristics. Furthermore, we employ factor analysis and K-means clustering for stock selection, and then apply LLMDE to solve the Conditional Value at Risk (CVaR) portfolio optimization problem using the selected stocks, subject to budget and minimum expected return constraints. Experimental results demonstrate that LLMDE achieves competitive performance on the benchmark suite while continuously generating high-quality solutions for complex constrained optimization tasks. These outcomes successfully demonstrate the viability of embedding LLMs within metaheuristics, paving a promising path toward the design of advanced LLM-assisted optimization techniques.