Python bot to mirror wallet actions on Solana using:
- QuickNode RPC/WSS
- Solana Web3 (
solana-py+solders) - Jupiter swap API for execution
- Monitors target wallets for recent token movement
- Infers
buyorselldirection from token balance deltas - Executes mirrored swaps from your bot wallet
- Applies simple risk controls:
- max open positions
- max trade budget
- slippage bps
- Exports action + decision logs to JSONL for AI training
- This is a starter bot and not production-grade.
- DEX/CEX behaviors can be hard to infer from public transactions.
- Before real funds:
- test on small size
- add strict token allowlist/blocklist
- add PnL and stop-loss logic
- add transaction simulation and route checks
- Create and activate a virtual environment.
- Install dependencies:
pip install -r requirements.txt
- Copy env file:
copy .env.example .env
- Fill
.env:QUICKNODE_HTTP_URLQUICKNODE_WSS_URLBOT_PRIVATE_KEY(base58 keypair)TARGET_WALLETS(comma-separated)- optional risk params
TRAINING_EXPORT_ENABLED/TRAINING_EXPORT_PATH
python bot.py- When enabled, the bot appends one record per action to
TRAINING_EXPORT_PATHas JSONL. - Each row includes:
- source action (signature, mint, side, amount)
- bot decision (
mirrored,skip,failed) - mirrored transaction signature (if present)
- reason (for skipped/failed decisions)
- You can use this dataset to train ranking/classification models for:
- when to copy
- position sizing
- token/wallet filtering
- Replace polling with websocket subscriptions for low latency.
- Add exact parser for known DEX programs (Raydium, Orca, Meteora).
- Add per-wallet weighting (copy 20%, 50%, etc.).
- Add persistence (SQLite/Postgres) for seen signatures and position state.
- Add Telegram/Discord alerts and kill-switch.