This repository contains the starter kit and tutorials for the ACM ICAIF 2024 FinRL Contest.
Task | Model | Environment | Dataset | Link |
---|---|---|---|---|
Stock Price Prediction | Linear Regression | -- | OHLCV | Demo |
Stock Trading | PPO | Stock Trading Environment | OHLCV | Demo |
Stock Trading @ FinRL Contest 2023 | PPO | Stock Trading Environment | OHLCV | Baseline solution |
Stock Trading | Ensemble | Stock Trading Environment | OHLCV | Demo for paper |
Task 1 Crypto Trading Ensemble (requires the files in the starter kit to run) | Ensemble | Crypto Trading Environment | BTC LOB 1sec | Code |
Sentiment Analysis with Market Feedback | ChatGLM2-6B | -- | Eastmoney News | Code |
This task aims to develop robust and effective trading agents for cryptocurrencies using ensemble methods. Participants are expected to explore innovative ensemble methods for single cryptocurrency trading. They are also encouraged to take advantage of the power of massively parallel simulations by utilizing the provided vectorized environments.
A dataset containing second-level Limit Order Book (LOB) data for Bitcoin is provided. Contestants are free to apply various techniques to the data, design component models, and use innovative methods to increase the diversity of component models in the ensemble.
The initial cash should be $1 million.
The contestants are required to:
- Specify the state space, action space, and reward functions in the environment.
- Ensure that the final ensemble model should be able to interact with the provided trading environment.
The performance of the model will be assessed by the following metrics:
- Cumulative return. It is the total return generated by the trading strategy over a trading period.
- Sharpe ratio. It takes into account both the returns of the portfolio and the level of risk.
- Max drawdown. It is the portfolio’s largest percentage drop from a peak to a trough in a certain time period, which provides a measure of downside risk.
Please see Task_1_starter_kit folder.
New notes for clarifications
The basic requirement is that your model should be able to interact with the environment. The code for training agent and ensemble is just an example solution for your reference.
- You are free to apply any method for ensemble learning. (For example, You can add new agents, use different ensemble algorithms, adjust hyperparameters, etc) The code provided is just to help get started and we encourage innovation.
- You are not required to stick to the 8 features we provide. But for evaluation purpose, please make sure that your new technical factors, if any, can be calculated based on the unseen data. Please include this code and state clearly in readme.
- We will use the provided environment to evaluate. So it is not encouraged to change the existing parameters in the environment. However, you can fully utilize the environment settings and the massively parallel simulation.
- To encourage innovation, if you want to add new mechanisms or use the unused settings (e.g. short sell) in the environment, please also submit your environment, ensure it works with your agent for evaluation, and describe the new changes in the readme.
This task aims to develop LLMs that can generate and engineer effictive signals from news by using Reinforcement Learning from Market Feedback (RLMF). By incorporating market feedback in the fine-tuning process, LLMs can learn from and adapt to financial market behaviors.
In this task, the LLM will be used to generate one type of signal (e.g., a sentiment score) based on the content of news. Contestants will develop models that leverage RLMF to adjust the signals based on the market feedback. Contestants are expected to explore useful market feedback from market data and innovative reward models to fine-tune their LLMs.
An OHLCV dataset and a corresponding news dataset for a list of stocks are provided. Contestants are free to use external datasets to deveop RLMF methods and fine-tune the LLMs.
- Contestants should use the LLM that can be loaded with huggingface and can do inference on 20GB GPU.
- Contestants can determine what signal to generate and engineer.
- Contestants should provide the prompt for their LLM. For example, "What is the sentiment score of {stock ticker} after the release of this news: {news}. Give and only return the score in the range of [-1, 1]. Answer: "
To assess the effectiveness of the signal engineered by the LLMs, we will apply the signal to a simple and practical trading strategy:
- Buy the top 3 stocks with the highest signals on the day of the news release and sell them 3 days later.
- Short-sell the 3 stocks with the lowest signals on the day of the news release and cover the short position 3 days later.
The initial cash is $1 million, which will be allocated equally to each trading day and each stock.
The performance will be assessed by the following metrics:
- Cumulative return. It is the total return generated by the trading strategy over a trading period.
- Win/loss ratio. It is calculated by dividing the number of winning trades by the number of losing trades over a trading period.
Please see Task_2_starter_kit folder.
Each team should also submit a 1-2 page report for the corresponding task they choose with the ACM sigconf template through Open Review. The title should start with “FinRL Contest 2024 Task I” or “FinRL Contest 2024 Task II.”
Useful materials and resources for contestants to learn about FinRL, including APIs and more tutorials: