saanjaypatil78/trading-platform
AI BASED Customized trading Platform
0 stars0 forksUpdated Jan 23, 2026
npx skills add saanjaypatil78/trading-platformREADME
Trading Platform
A complete algorithmic trading platform combining Chartink (stock screeners) and OpenAlgo (order execution) features.
๐ Quick Start
Option 1: One-Click Cloud Launch
- GitHub Codespaces: Click the badge above or press
.on GitHub - Gitpod: Click the Gitpod badge above
- Google Colab: Upload
colab_setup.pyand run all cells
Option 2: Local Launch
python launcher.py
Option 3: Manual Start
# Start services individually
python backend/services/brain/main.py # Port 8007
python backend/services/scanner/main.py # Port 8008
python backend/services/broker/main.py # Port 8009
# Start frontend
cd frontend/static && python -m http.server 8000
๐ Features
Scanner Engine (Chartink-style)
- 16+ Technical Indicators: RSI, MACD, SMA, EMA, Bollinger, ATR, VWAP
- Custom Conditions:
rsi(14) > 70,sma(50) > sma(200) - Pre-built Templates: RSI Overbought, Golden Cross, Death Cross
- Real-time Scanning: Scan entire stock universes
Order Execution (OpenAlgo-style)
- Paper Trading: Simulated broker with slippage & commissions
- Order Types: Market, Limit, Stop Loss, SL-Market
- Position Tracking: Real-time P&L calculation
- Webhook Support: TradingView, Amibroker integration
AI Brain (Chain-of-Thought)
- Sequential Thinking: Explainable multi-step reasoning
- 5 Trading Strategies: Entry, Risk, Regime, Portfolio, Earnings
- Knowledge Graph Memory: Persistent context and learning
Workflow Tools
- Action Center: Auto/Semi-Auto execution modes
- Smart Router: Latency-based order routing
- Monitoring: Latency P50/P95/P99, Traffic analytics, P&L tracking
- Telegram Bot: Real-time notifications
๐๏ธ Architecture
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Frontend (Static HTML) โ
โ No npm required - Uses Tailwind CDN + Vanilla JS โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโ
โผ โผ โผ
โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโโ
โ Brain โ โ Scanner โ โ Orders โ
โ :8007 โ โ :8008 โ โ :8009 โ
โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโโ
โ โ โ
โโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโ
โ
โโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโ
โผ โผ
โโโโโโโโโโโโ โโโโโโโโโโโโ
โ Shared โ โ Broker โ
โ Brain โ โ Adapter โ
โ Memory โ โ Paper โ
โโโโโโโโโโโโ โโโโโโโโโโโโ
๐ Project Structure
trading-platform/
โโโ backend/
โ โโโ services/
โ โ โโโ brain/ # AI reasoning API
โ โ โโโ scanner/ # Stock screener API
โ โ โโโ broker/ # Order execution API
โ โโโ shared/
โ โโโ brain/ # SequentialThinker, KnowledgeGraph
โ โโโ workflow/ # ActionCenter, Monitoring
โโโ frontend/
โ โโโ static/ # No-build HTML frontend
โโโ launcher.py # Universal launcher
โโโ colab_setup.py # Google Colab script
โโโ codespaces_setup.sh # Bash setup script
โโโ .devcontainer/ # GitHub Codespaces config
โโโ .gitpod.yml # Gitpod config
๐ API Endpoints
Brain Service (Port 8007)
| Endpoint | Method | Description |
|---|---|---|
/api/v1/brain/entry-analysis | POST | Buy/Sell decision |
/api/v1/brain/risk-assessment | POST | Position sizing |
/api/v1/brain/regime-detection | POST | Market regime |
/api/v1/brain/earnings-play | POST | Options strategy |
/api/v1/brain/memory | GET | Knowledge graph |
Scanner Service (Port 8008)
| Endpoint | Method | Description |
|---|---|---|
/api/v1/scanner/scan | POST | Run custom scan |
/api/v1/scanner/templates | GET | List templates |
/api/v1/scanner/template/{name} | POST | Run template |
/api/v1/scanner/indicators/{symbol} | GET | Get indicators |
Order Service (Port 8009)
| Endpoint | Method | Description |
|---|---|---|
/api/v1/orders/place | POST | Place order |
/api/v1/orders | GET | List orders |
/api/v1/positions | GET | Current positions |
/api/v1/funds | GET | Available capital |
/api/v1/webhook | POST | TradingView signal |
๐งช Testing
# Run all tests
python test_openalgo.py
python test_workflow.py
python verify_modules.py
# Debug agent
python debug_agent.py --fix
๐ฅ Demo Videos
The following videos demonstrating key features have
...
Publisher
Statistics
Stars0
Forks0
Open Issues3
CreatedJan 22, 2026