# SARF: Enhancing Stock Market Prediction with Sentiment-Augmented Random Forest

**Authors:** Saber Talazadeh, Dragan Perakovic  
**arXiv:** [2410.07143](https://arxiv.org/abs/2410.07143)  
**Date:** 2024-09-22  
**Summary page:** https://www.summarizepaper.com/en/paper/2410.07143v1/

## Key points

- Stock trend forecasting in the financial domain is complex and requires extensive data analysis and consideration of various indicators.
- Traditional empirical analysis methods often lack accuracy in predicting stock trends sustainably.
- Machine learning researchers have found that the random forest algorithm can significantly improve stock trend predictions by playing a crucial auxiliary role in forecasting market movements.
- A new approach called "Sentiment-Augmented Random Forest" (SARF) integrates sentiment analysis using the FinGPT generative AI model with the traditional Random Forest model to enhance stock price forecasts' accuracy.
- FinGPT was chosen over FinBert for sentiment analysis due to its contextual understanding of financial language, providing valuable sentiment scores and information related to finance, banking, and investing.
- The SARF model combines technical indicators with sentiment features from FinGPT within the Random Forest framework to improve market sentiment understanding effectively.
- To enhance SARF's performance further, technical indicators were calculated using TA-Lib and feature selection techniques were applied to address multicollinearity issues, prevent overfitting, enhance interpretability, improve computational efficiency, and aid in dimensionality reduction.
- Experiments showed that SARF outperformed conventional Random Forest and LSTM models with an average accuracy improvement of 9.23% and lower prediction errors in predicting stock market movements.

## Summary

Stock trend forecasting is a complex task in the financial domain that requires extensive data analysis and the consideration of various indicators. Traditional empirical analysis methods often fall short in providing accurate and sustainable predictions. In recent years, machine learning researchers have shown that the random forest algorithm can significantly improve stock trend predictions by playing a crucial auxiliary role in forecasting market movements. In a recent study, a new approach to stock market prediction was introduced by integrating sentiment analysis using the FinGPT generative AI model with the traditional Random Forest model. This innovative technique aims to enhance the accuracy of stock price forecasts by leveraging the nuanced understanding of financial sentiments provided by FinGPT. The methodology, known as "Sentiment-Augmented Random Forest" (SARF), incorporates sentiment features into the Random Forest framework. The study conducted experiments with both FinGPT and FinBert models for sentiment analysis, ultimately opting for FinGPT due to its broader focus, adeptness in handling various financial queries, and proficiency in generating responses in natural language. FinGPT's contextual understanding of financial language provides valuable sentiment scores and information related to finance, banking, and investing. The SARF model combines technical indicators with sentiment features from FinGPT within the Random Forest framework. By adding sentiment-based features as extra inputs, SARF aims to improve the model's ability to grasp market sentiment effectively. This hybrid approach leverages the strengths of both models by integrating sentiment analysis and technical indicators seamlessly. To enhance the SARF model's performance further, technical indicators were calculated using TA-Lib (Technical Analysis Library) and feature selection techniques were applied to eliminate variables with high correlation. This process addresses multicollinearity issues, prevents overfitting, enhances interpretability, improves computational efficiency, and aids in dimensionality reduction. Overall, experiments conducted using SARF demonstrated superior performance compared to conventional Random Forest and LSTM models. With an average accuracy improvement of 9.23% and lower prediction errors in predicting stock market movements, SARF showcases promising potential for enhancing stock trend forecasting accuracy through integrated sentiment analysis and technical indicators within a robust machine learning framework.
