An automated cryptocurrency trading system that combines LSTM-based price prediction with natural language processing of market events. The system leverages asynchronous processing to handle market API latency and provides remote monitoring through Telegram integration.
- Hybrid Prediction Model: Combines LSTM networks for technical analysis with NLP-based sentiment analysis of market events
- Asynchronous Architecture: Built with Python's asyncio for efficient handling of multiple exchange APIs
- Telegram Integration: Remote monitoring and control capabilities through a custom Telegram bot interface
- Multi-Exchange Support: Compatible with major cryptocurrency exchanges (Binance, Bittrex, Huobi)
- Real-time Event Processing: Monitors and analyzes market-moving events like new listings and partnerships
- Automated Trading: Executes trades based on combined signals from technical and sentiment analysis
- LSTM Model: Processes historical price and volume data to predict short-term price movements
- Sentiment Analyzer: Evaluates market news and events using natural language processing
- Async Market Interface: Handles exchange API communications with non-blocking operations
- Telegram Manager: Provides real-time monitoring and remote command execution
├── main.py # Main entry point and async orchestrator
├── Trader.py # Trading logic and order execution
├── Market.py # Exchange API interface layer
├── Predictor.py # LSTM model implementation
├── learn.py # Model training functionality
├── preprocessing.py # Data preprocessing pipeline
└── visualization.py # Trading performance visualization
The system utilizes Python's asyncio for efficient handling of market operations:
- Parallel processing of multiple exchange APIs
- Non-blocking order execution and monitoring
- Real-time data streaming and analysis
- Concurrent event processing and trade execution
Remote management features include:
- Real-time performance monitoring
- Trade execution notifications
- Remote command execution
- Portfolio status updates
- Market event alerts
- 4.1% net profit over 15-month testing period
- Outperformed traditional single-input LSTM models
- Successfully processed multiple market events simultaneously
- Maintained stable operation during high-volatility periods
- Python 3.6+
- TensorFlow 2.0+
- python-telegram-bot
- ccxt (cryptocurrency exchange trading library)
- pandas, numpy, scikit-learn
- Clone the repository
- Install dependencies:
pip install -r requirements.txt
- Configure exchange API keys in
settings.py
- Set up Telegram bot token and chat ID
- Run the system:
python main.py
Create a settings.py
file with your API credentials:
# Exchange API credentials
binance_APIKEY = "your_binance_api_key"
binance_SECRET = "your_binance_secret"
# Telegram configuration
telegram_token = "your_telegram_bot_token"
telegram_chat_id = "your_chat_id"
python main.py
/status
- Get current portfolio status/profit
- View profit/loss metrics/trade <symbol> <side> <amount>
- Execute manual trade/stop
- Safely stop the trading system
MIT License - see LICENSE file for details