A Python-based Polymarket bot and Polymarket trading bot for simulated copy-trading. Backtest and paper trade by copying a "leader" trader's positions on BTC price predictions with a powerful, professional workflow.
- Market: BTC price UP/DOWN predictions
- Timeframe: 15-minute resolution candles
- Modes:
- Backtest: Test strategy on historical simulated data
- Paper Trading: Practice with simulated real-time data
- Strategy: Copy a leader trader's positions with confidence-based position sizing
- Performance Metrics:
- Total PnL (Profit and Loss)
- Win rate
- Maximum drawdown
- Sharpe ratio
- Confusion matrix (UP/DOWN prediction accuracy)
- Precision and recall metrics
- Clone the repository:
git clone https://github.com/apemoonspin/polymarket-trading-bot-python.git
cd polymarket-trading-bot-python- Install dependencies:
pip install -r requirements.txtRun a backtest with default settings:
python main.py --mode backtestRun paper trading simulation:
python main.py --mode paperGenerate sample market data and leader trades:
python main.py --generate-data --periods 1000Edit src/config.py to customize settings:
# Market settings
MARKET_NAME = "BTC_15MIN_UP_DOWN"
RESOLUTION_MINUTES = 15
# Trading settings
STARTING_BALANCE = 10000.0
MAX_POSITION_SIZE = 0.1 # 10% of balance maximum
TRADING_FEE = 0.02 # 2% per trade
# Leader trader settings
LEADER_SKILL_LEVEL = 0.65 # 65% win ratepolymarket-trading-bot-python/
├── src/ # Source code
├── notebooks/ # Analysis notebooks
├── tests/ # Test suite
├── requirements.txt # Python dependencies
├── README.md # This file
└── main.py # Main entry point
- GitHub: https://github.com/apemoonspin
- Telegram: https://t.me/apemoonspin
- Twitter/X: https://x.com/apemoonspin For a more effective, updated bot that aims to be more reliable, or if you need help running this bot, please contact me using the links above.
Polymarket bot, Polymarket trading bot, powerful Polymarket bot, powerful Polymarket trading bot, top powerful Polymarket trading bot.
Suggested repository description: Polymarket bot and Polymarket trading bot in Python for backtesting and paper trading with a copy-trading strategy.
Suggested topics: polymarket, polymarket-bot, polymarket-trading, polymarket-trading-bot, trading-bot, crypto, prediction-markets, backtesting, paper-trading, python
Run the test suite:
python -m unittest tests/test_simulator.pyThis is a simulation tool for educational purposes only. Not financial advice.