JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading
Financial exchanges across the world use limit order books (LOBs) to process orders and match trades. For research purposes it is important to have large scale efficient simulators of LOB dynamics. LOB simulators have previously been implemented in the context of agent-based models (ABMs), reinforce...
Main Authors: | , , , , , , , |
---|---|
Format: | Journal article |
Language: | English |
Published: |
Association for Computing Machinery
2023
|
_version_ | 1811139568435462144 |
---|---|
author | Frey, SY Li, K Nagy, P Sapora, S Lu, C Zohren, S Foerster, J Calinescu, A |
author_facet | Frey, SY Li, K Nagy, P Sapora, S Lu, C Zohren, S Foerster, J Calinescu, A |
author_sort | Frey, SY |
collection | OXFORD |
description | Financial exchanges across the world use limit order books (LOBs) to process orders and match trades. For research purposes it is important to have large scale efficient simulators of LOB dynamics. LOB simulators have previously been implemented in the context of agent-based models (ABMs), reinforcement learning (RL) environments, and generative models, processing order flows from historical data sets and hand-crafted agents alike. For many applications, there is a requirement for processing multiple books, either for the calibration of ABMs or for the training of RL agents. We showcase the first GPU-enabled LOB simulator designed to process thousands of books in parallel, whether for identical or different securities, with an up to 75x faster per-message processing time. The implementation of our simulator - JAX-LOB - is based on design choices that aim to best exploit the powers of JAX without compromising on the realism of LOB-related mechanisms. We integrate JAX-LOB with other JAX packages, to provide an example of how one may address an optimal execution problem with reinforcement learning, and to share some preliminary results from end-to-end RL training on GPUs. The project code is available on GitHub 1 |
first_indexed | 2024-03-07T08:19:23Z |
format | Journal article |
id | oxford-uuid:eafe039c-38eb-4845-8252-05def202b71a |
institution | University of Oxford |
language | English |
last_indexed | 2024-09-25T04:08:09Z |
publishDate | 2023 |
publisher | Association for Computing Machinery |
record_format | dspace |
spelling | oxford-uuid:eafe039c-38eb-4845-8252-05def202b71a2024-06-05T10:49:33ZJAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for tradingJournal articlehttp://purl.org/coar/resource_type/c_dcae04bcuuid:eafe039c-38eb-4845-8252-05def202b71aEnglishSymplectic ElementsAssociation for Computing Machinery2023Frey, SYLi, KNagy, PSapora, SLu, CZohren, SFoerster, JCalinescu, AFinancial exchanges across the world use limit order books (LOBs) to process orders and match trades. For research purposes it is important to have large scale efficient simulators of LOB dynamics. LOB simulators have previously been implemented in the context of agent-based models (ABMs), reinforcement learning (RL) environments, and generative models, processing order flows from historical data sets and hand-crafted agents alike. For many applications, there is a requirement for processing multiple books, either for the calibration of ABMs or for the training of RL agents. We showcase the first GPU-enabled LOB simulator designed to process thousands of books in parallel, whether for identical or different securities, with an up to 75x faster per-message processing time. The implementation of our simulator - JAX-LOB - is based on design choices that aim to best exploit the powers of JAX without compromising on the realism of LOB-related mechanisms. We integrate JAX-LOB with other JAX packages, to provide an example of how one may address an optimal execution problem with reinforcement learning, and to share some preliminary results from end-to-end RL training on GPUs. The project code is available on GitHub 1 |
spellingShingle | Frey, SY Li, K Nagy, P Sapora, S Lu, C Zohren, S Foerster, J Calinescu, A JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
title | JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
title_full | JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
title_fullStr | JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
title_full_unstemmed | JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
title_short | JAX-LOB: a GPU-Accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
title_sort | jax lob a gpu accelerated limit order book simulator to unlock large scale reinforcement learning for trading |
work_keys_str_mv | AT freysy jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT lik jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT nagyp jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT saporas jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT luc jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT zohrens jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT foersterj jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading AT calinescua jaxlobagpuacceleratedlimitorderbooksimulatortounlocklargescalereinforcementlearningfortrading |