AI-Powered Automated Trading Platform for Borsa Istanbul (BIST)
Features • Architecture • Quick Start • Documentation • Contributing
An open-source, modular, AI-driven trading infrastructure for Borsa Istanbul (BIST) — featuring real-time market data, automated order execution, technical & AI-based strategies, backtesting, and a professional dashboard.
⚠️ Disclaimer: This platform does not provide investment advice. Trading involves risk of loss. Use responsibly.
| Feature | Description |
|---|---|
| Real-Time Market Data | Live prices, volume, and order book via WebSocket |
| Automated Order Execution | Risk-controlled buy/sell with broker adapters |
| Trend & Bottom Detection | Technical indicators (RSI, MACD, Bollinger) + AI models |
| Risk Management | Daily loss limits, position sizing, volatility controls |
| Backtesting Engine | Historical strategy simulation with detailed metrics |
| Professional Dashboard | Real-time P&L, positions, risk gauges, performance charts |
| Index Filtering | BIST30, BIST100, Participation Index support |
| AI Strategy Engine | ML-powered predictions using XGBoost, scikit-learn, PyTorch |
| Paper Trading | Safe simulation mode before going live |
| Notifications | Telegram bot & email alerts for signals and risk events |
Frontend (Next.js 15)
│
API Gateway (Nginx)
│
Backend (FastAPI)
┌──────┼──────┐
│ │ │
Market Trading Strategy
Data Engine Engine
│ │ │
┌─────┼──────┼──────┼─────┐
│ │ │ │ │
PostgreSQL TimescaleDB Redis Kafka MinIO
| Layer | Technology |
|---|---|
| Backend | Python 3.12+, FastAPI, Celery, SQLAlchemy 2.0 |
| Frontend | Next.js 15, React 19, TypeScript 5.7, TailwindCSS |
| Database | PostgreSQL 16 + TimescaleDB |
| Cache / Queue | Redis 7+, Kafka / Redpanda |
| AI/ML | scikit-learn, XGBoost, PyTorch, TA-Lib |
| Monitoring | Prometheus, Grafana, Sentry, structlog |
| DevOps | Docker, Docker Compose, GitHub Actions |
| Testing | pytest, Vitest, Playwright |
bist-robogo/
├── backend/ # Python Backend (FastAPI)
│ ├── app/
│ │ ├── api/ # REST API routes (v1)
│ │ ├── brokers/ # Broker adapters (paper, live)
│ │ ├── core/ # Config, security, Redis, WebSocket
│ │ ├── indicators/ # Technical indicators (RSI, MACD, etc.)
│ │ ├── models/ # SQLAlchemy ORM models
│ │ ├── schemas/ # Pydantic request/response schemas
│ │ ├── services/ # Business logic layer
│ │ ├── strategies/ # Trading strategies (MA crossover, AI trend)
│ │ ├── tasks/ # Celery async tasks
│ │ └── websocket/ # Real-time WebSocket streams
│ ├── alembic/ # Database migrations
│ ├── tests/ # Backend test suite (pytest)
│ └── pyproject.toml
├── frontend/ # Next.js 15 Frontend
│ ├── src/
│ │ ├── app/ # App Router pages
│ │ ├── components/ # React components (auth, charts, layout)
│ │ ├── hooks/ # Custom React hooks
│ │ ├── lib/ # API client, utilities
│ │ ├── stores/ # Zustand state management
│ │ └── types/ # TypeScript type definitions
│ └── package.json
├── docs/ # Design & implementation docs (12 files)
├── docker-compose.yml # Full dev environment (6 services)
├── Makefile # Common dev commands
└── .github/workflows/ # CI pipeline
The docs/ directory contains 12 detailed design & implementation documents:
| # | Document | Topics |
|---|---|---|
| 01 | R&D & Requirements Analysis | Tech research, functional/non-functional requirements |
| 02 | System Architecture | Modules, data flows, deployment |
| 03 | Data Models & API | DB schemas, API contracts, event flows |
| 04 | Frontend Design & UX | UI/UX, wireframes, component hierarchy |
| 05 | Development Plan & MVP | Sprint planning, roadmap |
| 06 | Gap Analysis Report | Coverage gaps in existing docs |
| 07 | Backend Implementation Guide | File structure, code patterns |
| 08 | Frontend Implementation Guide | Components, hooks, stores |
| 09 | Design System | Color tokens, typography, component catalog |
| 10 | Step-by-Step Dev Guide | Docker, CI/CD, phased tasks |
| 11 | AI Agent Dev Prompt | End-to-end AI agent master prompt |
| 12 | Project Status | Current progress & completed phases |
- Docker & Docker Compose
- Python 3.12+ & Poetry (for local backend dev)
- Node.js 20+ & pnpm (for local frontend dev)
# Clone the repository
git clone https://github.com/omerada/bist-robogo.git
cd bist-robogo
# Copy environment template
cp .env.example .env
# Edit .env with your own secrets (see .env.example for details)
# Start all services
docker compose up -d --build
# Verify
docker compose ps
# http://localhost:8000/health → 200 OK (Backend)
# http://localhost:3000 → Dashboard (Frontend)# Backend
cd backend
poetry install
poetry run alembic upgrade head
poetry run uvicorn app.main:app --reload --host 0.0.0.0 --port 8000
# Frontend (in a separate terminal)
cd frontend
pnpm install
pnpm devmake dev # Start all services (Docker)
make test # Run all tests (backend + frontend)
make backend-test # Backend tests with coverage
make frontend-test # Frontend unit tests
make migrate # Run database migrations
make seed # Seed BIST30 symbols & indexes# Backend (272+ tests)
cd backend && poetry run pytest -v --cov=app
# Frontend (Vitest)
cd frontend && pnpm test
# E2E (Playwright)
cd frontend && pnpm test:e2eContributions are welcome! Please see CONTRIBUTING.md for guidelines.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
For security concerns, please see SECURITY.md. Do not open public issues for security vulnerabilities.
This project is licensed under the MIT License — see the LICENSE file for details.
If you find this project useful, please consider giving it a star!
⚠️ Disclaimer: This platform does not provide investment advice. Trading involves risk of loss. Use responsibly. The developers are not liable for any financial losses incurred through the use of this software.