A personal cryptocurrency trading and analysis platform focused on cost optimization by replacing expensive APIs with free alternatives.
CryptoWildfire is a data-driven crypto trading and analysis platform that integrates market data, social sentiment, and on-chain metrics to generate trading signals. The platform follows a cost-efficient approach by leveraging free APIs and web scraping techniques instead of expensive commercial services.
The system consists of several core components:
-
Data Collection Layer
- Market data from CoinGecko
- External sentiment indicators (Fear & Greed Index, CryptoCompare Social Stats, TradingView)
- Social mentions from Reddit
- On-chain data (roadmap)
-
Signal Processing Layer
- Signal aggregation with configurable weights
- Composite score calculation
- Consensus determination
-
Storage Layer
- Supabase PostgreSQL database
-
Frontend Layer
- React (Vite + TypeScript + Tailwind CSS) dashboard
- Data visualization (TradingView, custom charts)
- Frontend ML Engine (Prediction, Validity)
- Backend: Python (FastAPI)
- Database: Supabase (PostgreSQL)
- AI Services: Gemini/OpenRouter (Backend), Frontend ML Models (TypeScript)
- Frontend: React (Vite, TypeScript, Tailwind CSS)
- Cloud Infrastructure: Google Cloud (potential for backend ML), Supabase
- Real-time Market Data: Track prices, market caps, and volumes for various cryptocurrencies
- Hybrid Sentiment Analysis:
- External sentiment indicators (Fear & Greed Index, CryptoCompare)
- Reddit community sentiment (analyzed with AI)
- Signal Generation: Combines multiple indicators to generate trading signals
- Responsive Dashboard: Interactive visualization of all data and signals
- Enhanced Technical Analysis:
- Dynamic support/resistance levels from API data
- Moving averages (7-day and 21-day SMA)
- Volume overlay with separate y-axis
- Indicator toggles for technical features
- Advanced Risk Management:
- ATR-based volatility stop loss calculation
- Trailing stop logic and position sizing
- Correlation risk analysis
The platform is being enhanced with ML-based prediction capabilities through a 6-phase implementation plan:
- ML Training Infrastructure - Building data collection and feature engineering pipelines
- Model Training & Evaluation - Implementing quantile regression models for price predictions
- Prediction API Integration - Creating prediction services with confidence scoring
- Frontend Integration - Building UI components for prediction visualization
- Testing & Deployment - Comprehensive testing and monitoring
- Post-Launch Optimization - Continuous learning and enhancement
See TODO.md for the detailed implementation plan.
- TechnicalChart Component - Now integrates ML predictions with technical indicators
- DynamicStopLoss System - Uses ML models to optimize ATR-based stop levels
- Progressive ML Influence - Initial 25% influence with performance-based growth
CryptoWildfire/
├── src/
│ ├── ai/
│ │ └── sentiment.py # AI sentiment analysis module
│ ├── collectors/
│ │ ├── coingecko.py # Market data collection from CoinGecko
│ │ ├── reddit_client.py # Social data collection from Reddit
│ │ └── market_sentiment.py # External sentiment indicators collection
│ ├── database/
│ │ ├── client.py # Supabase database client
│ │ └── schema.sql # Database schema definition
│ ├── engine/
│ │ └── aggregator.py # Signal aggregation and processing
│ └── main_collector.py # Main data collection orchestration
├── frontend/ # React frontend application
│ ├── src/
│ │ ├── components/ # UI Components
│ │ ├── pages/ # Page views (Dashboard)
│ │ ├── ml/ # Frontend ML logic (engines, ensemble)
│ │ ├── services/ # API communication
│ │ └── main.tsx # Frontend entry point
│ ├── package.json # Frontend dependencies
│ └── vite.config.ts # Vite configuration
├── .env # Environment variables (API keys, etc.)
└── README.md # This file
-
Clone the repository
git clone https://github.com/yourusername/CryptoWildfire.git cd CryptoWildfire -
Set up Backend environment
# Create and activate a virtual environment (recommended) python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate` pip install -r requirements.txt
-
Set up Frontend environment
cd frontend npm install cd ..
-
Configure environment variables Create a
.envfile with the following variables:# Core Infrastructure SUPABASE_URL=your_supabase_url SUPABASE_SERVICE_ROLE_KEY=your_supabase_service_role_key # Market Data Sources COINGECKO_API_KEY=your_coingecko_api_key (optional) CRYPTOCOMPARE_API_KEY=your_cryptocompare_api_key # Social Data Sources REDDIT_CLIENT_ID=your_reddit_client_id REDDIT_CLIENT_SECRET=your_reddit_client_secret REDDIT_USER_AGENT=your_reddit_user_agent -
Initialize database
# Ensure Supabase is running and accessible python -c "from src.database.client import DatabaseClient; client = DatabaseClient(); client.execute_schema('src/database/schema.sql')"
# Start the main data collector (runs continuously)
python -m src.main_collector
# Start the backend API server (in a separate terminal)
# Ensure you are in the root directory with the venv activated
uvicorn src.api.main:app --reload --port 8000 # In a separate terminal
cd frontend
npm run devAccess the dashboard at http://localhost:5173 (or the port specified by Vite).
CryptoWildfire uses a hybrid approach to sentiment analysis:
-
External Sentiment Analysis (NEW)
- Fear & Greed Index: Market-wide sentiment indicator (0-100 scale)
- CryptoCompare Social Stats: Pre-analyzed social metrics
- TradingView Technical Analysis: Buy/Sell signals from technical indicators
-
In-house Sentiment Analysis
- Reddit Analysis: Uses AI models via OpenRouter/VertexAI to analyze sentiment
This hybrid approach allows us to leverage existing sentiment analysis where available, reducing computation costs and improving reliability.
Signals are generated using a weighted system:
- Price momentum (30%)
- Reddit sentiment (15%)
- Volume spikes (10%)
- On-chain metrics placeholder (10%) # Placeholder, needs implementation
- Fear & Greed Index (10%)
- TradingView technicals (10%)
- CryptoCompare social (10%)
These weights can be adjusted in src/engine/aggregator.py.
This phase focuses on strengthening the core system using existing data sources and infrastructure.
- Enhance Data Quality & Monitoring: Implement robust checks (outliers, missing values, staleness) in data collectors (
src/collectors/*), add corresponding automated tests (tests/integration/*), potentially structure checks insrc/analysis/data_quality.py, and add basic performance monitoring. (Source: Existing APIs) - Add Fibonacci & Refactor Technical Analysis: Implement Fibonacci retracement (
src/analysis/technical_analysis_methods.py), ensure correct calculation/use of indicators like Ichimoku insrc/analysis/technical_analysis.py, and add basic indicator toggles. (Source: Existing Market Data) - Add Enhanced Volatility Measures: Implement historical volatility calculations in
src/risk/risk_assessment.py. (Source: Existing Market Data) - Create ML Benchmarking Suite: Develop baseline model training and evaluation scripts (
src/ml/), potentially using MLflow. (Source: Existing Data) - Implement Basic Feature Flag System: Create a simple mechanism (
src/config/feature_flags.py) to toggle features for safer rollouts. (Source: New Code) - Improve Backtesting/Validation: Enhance the existing backtester (
src/backtesting/) and add basic forward testing logic. (Source: Existing Data)
- Migrate to a Time-Series Database (e.g., TimescaleDB).
- Implement a Data Backfill Pipeline.
- Expand Exchange Coverage via CCXT configuration.
- Add basic News Sentiment (e.g., GDELT).
- Integrate Paid On-Chain Data (e.g., Glassnode).
- Integrate Paid Social Sentiment (e.g., Twitter/X API).
- Integrate Whale Tracking data.
- Develop Advanced ML Models (LSTM, Transformers).
- Implement Advanced Risk Models (VAR, Liquidity).
- Implement Advanced UI Features (WebGL, Explainable AI).
A detailed blueprint outlining the design principles, architecture, and key components for the next-generation CryptoWildfire frontend can be found in docs/FRONTEND_VISION.md.
This project is for personal use only and not licensed for redistribution.