Problem
Cryptocurrency markets move fast. A price swing of 5% can happen in seconds. Retail traders need real-time analysis but lack infrastructure:
- Data silos: Price feeds from Binance, sentiment from Twitter, news from crypto media—no unified view
- Indicator computation: Technical indicators (RSI, MACD, Bollinger Bands) computed manually or via expensive APIs
- No backtesting: Traders can’t validate strategies before risking capital
- Latency: Stale signals are useless; framework must operate in <100ms to be useful
The challenge: build a modular, fast, reproducible framework that traders can extend with custom indicators or strategies.
Data Preparation
Price data:
- Collected 2 years of OHLCV (open, high, low, close, volume) for 500+ pairs
- Sources: Binance, Coinbase, Kraken (normalized to 1-minute candles)
- Challenges: exchange data gaps (maintenance windows), different precisions (BTC vs shitcoins)
- Solution: forward-fill minor gaps; reject pairs with >1% missing data
- Result: 50GB dataset; compressed to 8GB in TimescaleDB
Sentiment data:
- Twitter mentions: 4M tweets/month (via Twint scraper); filtered for top 200 coins
- News feeds: CoinTelegraph API, The Block, Reddit communities
- Processing: TextBlob polarity (-1 to 1), VADER intensity; per-coin rolling sentiment (24h window)
- Validation: correlated sentiment swings with price moves (Spearman: 0.32 correlation)
Ground truth:
- 50 known trading strategies with documented historical performance (e.g., “RSI > 70 = overbought sell signal”)
- Back-tested each strategy against framework; verified accuracy within 0.1% of manual calculation
- Result: framework is accurate enough for real trading
Models Evaluated
| Component |
Model |
Result |
Note |
| Technical indicators |
Manual SMA/RSI/MACD |
Kept |
Deterministic, fast (<1ms), transparent; no black box |
| Sentiment |
TextBlob + VADER |
Kept |
78% accuracy; lightweight; no GPU needed |
| Sentiment (alt) |
Llama 7B (fine-tuned) |
Cut |
80ms per tweet; too slow; diminishing accuracy gains |
| Price prediction |
LSTM neural net |
Cut |
High variance; overfits to recent data; unpredictable |
| Price prediction (alt) |
Random Forest |
Cut |
Better generalization than LSTM, but still ~55% accuracy (near random) |
| Data source |
Binance API |
Kept |
Reliable, <500ms latency, high liquidity |
| Data source (alt) |
Kraken API |
Kept |
Cross-validation; if both agree, higher confidence |
| Backtester |
VectorBT (library) |
Cut |
Overkill; built custom engine optimized for crypto patterns |
Architecture
Data pipeline (batch):
Binance, Coinbase, Kraken APIs
v (parallel, deduplicate, normalize to 1-min candles)
TimescaleDB (2y history, compressed)
v
Compute indicators (vectorized NumPy: SMA, RSI, MACD, Bollinger)
v
Cache results (Redis, 1h TTL)
v
Ready for backtesting / analysis
Real-time signal pipeline:
WebSocket feed from Binance (price updates, every 1s)
v
Apply signal rules:
IF RSI < 30 AND sentiment > 0.5 AND volume_surge THEN
-> Emit LONG signal (confidence = 0.75)
v
Telegram/Discord webhook (notify users)
v
Log signal + outcome (did price move +5% within 24h?)
Backtesting engine:
User provides:
- Strategy rules (e.g., "RSI crossover strategy")
- Date range
- Capital allocation
v
Framework replays historical OHLCV:
v
For each candle:
- Compute indicators
- Evaluate rules
- Execute trade (simulated)
- Track P&L (with commission + slippage)
v
Output:
- Total return, Sharpe ratio, max drawdown, win rate
- Equity curve ($ over time)
- Trade log (all fills, reasons)
Safety measures:
- No real money automation (users manually execute trades; framework is advisory)
- Confidence scores on signals (users can filter low-confidence)
- Slippage + commission included in backtesting (realistic)
- Risk warnings on high-leverage strategies
Production & Scale
Deployed Jun 2024:
- Web dashboard (React): view signals, backtesting, portfolio
- Telegram bot: real-time signal delivery (100+ subscribers)
- Discord webhook: alternative notification channel
- API: programmatic access to signals + backtesting
Metrics (as of Jan 2026):
- 180+ active traders using framework
- 500+ trading pairs supported
- Real-time latency: P95 <100ms (WebSocket frame -> signal delivery)
- Signal accuracy: 62% (buy signals predict 5%+ price move within 24h; market baseline ~50%)
- Backtested strategies: 5,000+ (users upload custom rules)
- Uptime: 99.4% (exchange API outages + maintenance windows = 0.6%)
Cost structure:
- Starter: $10/month (basic signals, delayed by 1h)
- Pro: $50/month (real-time signals, backtesting API, portfolio tracking)
- Enterprise: custom (private deployment, strategy consulting)
Lessons learned:
- Sentiment lag: Sentiment data is 1–2 hours behind price (Twitter doesn’t move markets; markets move Twitter)
- Solution: Use sentiment as confirmation signal (not primary)
- Backtesting overfitting: Users love strategies that returned 100% on historical data; 60% in forward testing
- Solution: Require walk-forward validation (divide history into train/test, validate on unseen data)
- Exchange data quality: Kraken data had 2% gaps; Binance highly reliable
- Solution: Use Binance as primary; Kraken for cross-check
Result: A framework trusted by 180+ traders for analysis and backtesting. Signals are modest (62% accuracy) but better than flipping a coin, and importantly—transparent and reproducible.