Abstract
Market makers play an important role in providing liquidity to markets by continuously quoting prices at which they are willing to buy and sell, and managing inventory risk. In this paper, we build a multi-agent simulation of a dealer market and demonstrate that it can be used to understand the behavior of a reinforcement learning (RL) based market maker agent. We use the simulator to train an RL-based market maker agent with different competitive scenarios, reward formulations and market price trends (drifts). We show that the reinforcement learning agent is able to learn about its competitor's pricing policy; it also learns to manage inventory by smartly selecting asymmetric prices on the buy and sell sides (skewing), and maintaining a positive (or negative) inventory depending on whether the market price drift is positive (or negative). Finally, we propose and test reward formulations for creating risk averse RL-based market maker agents.
Introduction
In financial markets, market makers provide liquidity by quoting bid (buy) and ask (sell) prices. While reinforcement learning (RL) has achieved significant success in domains like gaming and robotics, its application in finance is hindered by the lack of high-fidelity simulators. Most existing research focuses on Limit Order Books (LOB), where order visibility is high. This paper addresses the more opaque "Dealer Market" (Over-the-Counter/OTC), where agents interact directly and only observe their own trades. This partial observability presents a challenge: how can an agent price its services without knowing competitor actions or the true market price?
Methodology
The researchers developed a multi-agent simulator featuring two primary agent types: Investors and Market Makers.
- Simulator Environment: The reference price follows a geometric Brownian motion, with spread curves calibrated using real-world LOB data from Microsoft (MSFT).
- Adaptive Agent (Competitor): A baseline agent using classical mean-variance optimization and an empirical response table to adjust prices based on market share and inventory.
- RL Agent: A deep RL agent utilizing Proximal Policy Optimization (PPO). Observations include past trades, current inventory, and reference prices. Actions involve setting buy/sell spreads and hedging inventory on an exchange.
- Risk Aversion Modeling: To simulate realistic risk preferences, the authors tested various penalty functions, including Standard Deviation and Squared Inventory PnL, within the RL reward structure.
Key Insights: Learning and Strategy Discovery
The RL agent demonstrated an ability to discover sophisticated financial heuristics without explicit programming.
Learning Competitor Distributions
The RL agent effectively "learned" the hidden pricing distributions of its competitors. As shown in the density plot below, the RL agent's pricing parameter ($\epsilon$) distribution aligns with the range and peaks of the Adaptive Agent's policy, suggesting it converged toward a sophisticated understanding of the competitive landscape.
Emergent Behaviors: Skewing and Drift Exploitation
- Skewing: The agent learned to manage inventory risk through asymmetric pricing. With excess inventory, it lowers sell prices to attract buyers while raising buy prices to deter sellers.
- Drift Exploitation: In trending markets, the agent learned to build inventory to benefit from price movements, effectively combining market-making with momentum trading.
Key Results
The RL agent consistently outperformed baseline "Random" and "Persistent" agents. In direct competition with the sophisticated Adaptive Agent, the RL agent demonstrated superior performance, particularly as it optimized its strategy over time.
As illustrated above, the RL agent (green) achieves significantly higher total rewards compared to the Adaptive Agent (blue) over the course of the simulation, indicating stable convergence to a highly profitable policy.
Conclusion and Future Work
This research demonstrates the potential of RL in complex, partially observable dealer markets. Future work will focus on modeling "informed traders" to account for adverse selection, expanding to multi-security portfolios, and incorporating execution latency to better reflect real-world high-frequency trading environments.
Summary updated