High-performance cryptocurrency trading bot with technical analysis and multi-coin trading strategies
TRAID is a high-performance cryptocurrency trading bot that leverages technical analysis to identify trading opportunities across multiple exchanges. It supports both single-coin focused trading and dynamic multi-coin trading strategies, automatically switching between assets based on market conditions and opportunities.
- Real-time Market Analysis: WebSocket connections to Kraken for live price and volume data
- Technical Indicators: RSI, Moving Averages, and Volume analysis
- Trading Modes:
- Single-coin mode: Focus on a specific trading pair (e.g. BTC/USDT)
- Multi-coin mode: Dynamically switch between coins based on opportunity scoring
- Opportunity Scoring: Proprietary 0-100 scoring system to rank trading opportunities
- Risk Management: Position sizing, stop-loss, and balance allocation safeguards
- Comprehensive Reporting: Detailed trading session statistics and performance tracking
- Python 3.9 or higher
- pip package manager
-
Clone the repository:
git clone https://github.com/codistry-software/traid.git cd traid
-
Install dependencies:
pip install -r requirements.txt
-
Run the bot:
python traid/main.py
When you start the bot, you'll be prompted to:
- Enter your initial portfolio value in USDT
- Select a trading mode:
- Single-coin mode (focused on BTC/USDT)
- Multi-coin mode (analyzes all available trading pairs)
The bot will then:
- Connect to Kraken's WebSocket API
- Fetch historical market data
- Calculate initial opportunity scores
- Begin trading based on technical signals
- Provide real-time portfolio updates
Example output:
🚀 Trading Bot initialized in MULTI-coin mode
👀 Monitoring 25 trading pairs (stablecoins excluded)
💰 Initial balance: 1000.00 USDT
🔥 Initial Top Trading Opportunities:
SOL/USDT: Score 78/100
ETH/USDT: Score 65/100
BTC/USDT: Score 62/100
🎯 Selected SOL/USDT as initial trading target
💰 Allocated 800.00 USDT to SOL/USDT
✅ Trading bot is now active
traid/
├── __init__.py
├── trading_bot.py # Core trading logic
├── kraken_client.py # Kraken API client
└── main.py # Entry point and CLI
tests/
├── __init__.py
├── test_trading_bot.py
└── test_kraken_client.py
requirements.txt
README.md
LICENSE
The default strategy uses a combination of technical indicators:
-
Buy Signals:
- RSI < 35 (oversold condition)
- Short MA > Long MA and RSI < 65 (uptrend confirmation)
-
Sell Signals:
- RSI > 65 (overbought condition)
- Short MA < Long MA and RSI > 35 (downtrend confirmation)
-
Coin Selection (multi-coin mode):
- Opportunity scores (0-100) based on price action, RSI, MAs, and volume
- Switches to a different coin when its score is at least 10 points higher
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the project
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
TRAID uses pytest for unit and integration testing:
# Run all tests
pytest
# Run specific test file
pytest tests/test_trading_bot.py
# Run with coverage report
pytest --cov=traid
All core functionality is covered by comprehensive tests, following TDD principles.
This project is licensed under the MIT License - see the LICENSE file for details.
Trading cryptocurrencies involves significant risk and may not be suitable for everyone. This software is for educational purposes only and is not financial advice. Always do your own research before making investment decisions. Past performance is not indicative of future results.
Made with ❤️ from codistry