Skip to content

Ape108/IMC-Prosperity-4

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

146 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

IMC Prosperity 4

Algorithmic trading competition by IMC Trading — 5 rounds, ~18,000 teams globally. Each round adds new products; you implement a Trader class that the platform calls once per tick to return orders.

Round-by-round writeup (in progress): Substack

Final Results

  • Global Ranking: #42
  • National Ranking (United States): #14

Overall and State Ranking

Contributors: Cameron Akhtar · Heagen Bell

Results by Round

Round Products Strategy PnL
R1 ASH_COATED_OSMIUM, INTARIAN_PEPPER_ROOT Avellaneda-Stoikov MM with data-driven drift estimation 160,290
R2 Same as R1 Refined drift estimation; MAF blind auction bid 475,034
R3 HYDROGEL_PACK, VELVETFRUIT_EXTRACT, VEV options (10 strikes) Microprice + Avellaneda inventory skew MM; Black-Scholes IV smile scalper 87,276
R4 Same as R3 Carried R3 MM; inside-spread passive MM on VEV_4000 (21-tick spread); Mark bot EDA 207,815
R5 50 products across 10 groups PEBBLES M↔XL pair trade; OXYGEN_SHAKE autocorrelation overlays; base MM everywhere else 796,401

Directory Structure

├── datamodel.py          # Official IMC platform data model — do not modify
├── requirements.txt      # Python dependencies
├── datasets/             # prices_*.csv + trades_*.csv pairs for each round
│   ├── round_0/
│   ├── round1/
│   ├── round2/
│   ├── round3/
│   ├── round4/
│   └── round5/
├── logs/                 # Backtest and live submission logs
│   └── r1/ … r5/
├── manual/               # Manual trading analysis notebooks
│   └── r2/ … r5/
├── reference/            # Backtester docs; jmerle and timodiehm reference strategies
└── submissions/          # Shipped code per round
    ├── tutorial/         
    ├── r1/               
    ├── r2/               
    ├── r3/               
    ├── r4/               
    │   ├── piors/        # Archived development iterations
    │   ├── tests/        # EDA scripts
    │   └── strategy.py
    └── r5/               
        ├── piors/        # Archived development iterations
        ├── groups/       # Per-group analysis scripts (cointegration, lead-lag)
        └── strategy.py

Architecture

Credit

Author Resource Role in this repo
jmerle 25th place Prosp3 strategies Class hierarchy (Strategy, StatefulStrategy, MarketMakingStrategy) & code reference
timodiehm 2nd place Prosp3 strategies Advanced theory/technique reference
GeyzsoN Rust backtester Faster & configurable backtesting
Equirag Online visualizer Upload submission.log artifacts for order-level detail

Class Hierarchy

Base classes are copied from reference/jmerle_hybrid.py into each submission.

Strategy[T]
├── StatefulStrategy[T]
│   └── SignalStrategy
└── MarketMakingStrategy

Workflow

Windows Setup

.venv/Scripts/activate
pip install -r requirements.txt

Backtesting

The backtester runs in WSL2. $PROSP4 in the WSL2 ~/.bashrc points to this directory.

cd ~/prosperity_rust_backtester

# 1. Quick default run
rust_backtester --trader "$PROSP4/submissions/rN/strategy.py" --dataset roundN

# 2. Conservative PnL check
rust_backtester --trader "$PROSP4/submissions/rN/strategy.py" --dataset roundN \
  --queue-penetration 0 --price-slippage-bps 5

Upload runs/<backtest-id>/submission.log to prosperity.equirag.com for order-level detail.

About

Official repository for IMC Prosperity 4. Features modular Python strategies including market making, statistical arbitrage, and signal-based trading. Final placement: #42 Global, #14 US.

Topics

Resources

Stars

Watchers

Forks

Contributors