Leveraging enhanced egret swarm optimization algorithm and artificial intelligence-driven prompt strategies for portfolio selection

Zhendai Huang, Zhen Zhang, Cheng Hua, Bolin Liao*, Shuai Li*

*Corresponding author for this work

Research output: Contribution to journalArticleScientificpeer-review

Abstract

In the financial field, constructing efficient investment portfolios is a focal point of research, encompassing asset selection and optimization of asset allocation. With the advancements in Large Language Models (LLMs), generative Artificial Intelligence (AI) tools have showcased capabilities never seen before. However, the black-box nature of these tools renders their outputs difficult to interpret directly, often necessitating iterative fine-tuning to align with users’ expected outcomes. This study presents a structured prompt framework specifically designed for stock selection, aiming to provide direct and interpretable stock-selecting tools for investors of various levels. By creating representative scenarios and combining them into different cases for experimentation, we can explore how the construction of prompts influences the responses generated by generative AI tools. Additionally, this paper proposes a novel algorithm that combines the Nonlinear-Activated Beetle Antennae Search strategy with the Egret Swarm Optimization Algorithm (NBESOA) to address the Mean-Variance Portfolio Selection problem with Transaction Costs and Cardinality Constraints (MVPS-TCCC), utilizing real stock market data to construct portfolios based on generative AI tools recommendations. Simulation results indicate that, compared to other algorithms, NBESOA prefers optimizing portfolio configurations to achieve the highest Sharpe Ratio with the strictest constraints, bringing the outcomes closer to the portfolio’s efficient frontier.

Original languageEnglish
Article number26681
JournalScientific Reports
Volume14
DOIs
Publication statusPublished - Dec 2024
MoE publication typeA1 Journal article-refereed

Keywords

  • Bio-inspired algorithm
  • Egret swarm optimal algorithm
  • Large language models
  • Portfolio selection
  • Prompt engineering

Fingerprint

Dive into the research topics of 'Leveraging enhanced egret swarm optimization algorithm and artificial intelligence-driven prompt strategies for portfolio selection'. Together they form a unique fingerprint.

Cite this