Leveraging LLM-based sentiment analysis for portfolio allocation with proximal policy optimization
Abstract
Portfolio optimization requires adaptive strategies to maximize returns while managing risk. Reinforcement learning (RL) has gained traction in financial decision-making, and proximal policy optimization (PPO) has demonstrated strong performance in dynamic asset allocation. However, traditional PPO relies solely on historical price data, ignoring market sentiment, which plays a crucial role in asset movements. We propose a sentiment-augmented PPO (SAPPO) model that integrates daily financial news sentiment extracted from Refinitiv using LLaMA 3.3, a large language model optimized for financial text analysis. The sentiment layer refines portfolio allocation by incorporating real-time market sentiment alongside price movements. We evaluate both PPO and SAPPO on a three-stock portfolio consisting of Google, Microsoft and Meta, and we compare performance against standard market benchmarks. Results show that SAPPO improves risk-adjusted returns with a superior Sharpe ratio and reduced drawdowns. Our findings highlight the value of integrating sentiment analysis into RL-driven portfolio management.