Summarize-Explain-Predict (SEP)
May 16, 2024 ยท View on GitHub
This repository contains the code for "Learning to Generate Explainable Stock Predictions using Self-Reflective Large Language Models" [Paper].
Setup
To get started:
- Install the module dependencies into your environment:
pip install -r requirements.txt
- Set
OPENAI_API_KEYenvironment variable to your OpenAI API key:
export OPENAI_API_KEY=<your key>
- Run a sample experiment:
python main.py --price_dir "data/sample_price/preprocessed/" --tweet_dir "data/sample_tweet/raw/"
Note
The full dataset used in the work can be found here.
Due to the nature of these experiments, it may not be feasible for individual developers to rerun the full results as OpenAI has significant API charges.
Citation
If you find this repository useful, please cite our paper.
@inproceedings{koa2024learning,
title={Learning to Generate Explainable Stock Predictions using Self-Reflective Large Language Models},
author={Koa, Kelvin J.L. and Ma, Yunshan and Ng, Ritchie and Chua, Tat-Seng},
booktitle={Proceedings of the ACM on Web Conference 2024},
pages={4304โ4315},
year={2024}
}
Acknowledgement
We appreciate the following GitHub repositories a lot for their valuable code base: