Created comprehensive deployment guide with:
- DEPLOYMENT.md: Full documentation covering server requirements,
step-by-step deployment, troubleshooting, and project structure
- scripts/nginx-template.conf: Nginx configuration with SSL, reverse
proxy to backend, and frontend static file serving
- scripts/systemd-template.service: Systemd service for auto-restart
and environment variable management
- scripts/deploy.sh: Automated deployment script for rolling updates
Implemented issue #9 - Frontend Project Setup with Svelte and TypeScript.
Changes:
- Created SvelteKit project with TypeScript
- Set up routing structure:
- / (landing page)
- /login
- /register
- /dashboard
- /bot/[id]
- /bot/[id]/backtest
- /bot/[id]/simulate
- /settings
- Created Svelte stores for state management:
- userStore - Current user info
- botsStore - List of user's bots
- currentBotStore - Selected bot
- chatStore - Chat messages
- backtestStore - Backtest results
- simulationStore - Simulation signals
- authStore - Authentication state
- Created API client for backend communication
- Set up environment variables (.env.example)
- Created auth store with protected routes and login/register functionality
Implement simulate engine for real-time signal detection via REST polling.
Changes:
- SimulateEngine service with configurable check interval (default 60s for free tier)
- REST polling for current prices using AveCloudClient
- Condition matching for real-time data (price_drop, price_rise, volume_spike, price_level)
- Signal logging with user-initiated start/stop
- Simulation API endpoints:
- POST /api/bots/{id}/simulate - Start simulation
- GET /api/bots/{id}/simulate/{run_id} - Get status/signals
- GET /api/bots/{id}/simulations - List all simulations
- POST /api/bots/{id}/simulate/{run_id}/stop - Stop simulation
- Updated SimulationCreate schema with check_interval field
- Free tier limited to 60s minimum check interval
- Signals stored in database for simulation signal history
Depends on issue #7 (Backtest Engine) which was merged in PR #18
Implements issue #7 - Backtest Engine for historical strategy testing.
Changes:
- Created AveCloudClient for fetching klines from AVE Cloud Data API
- Implemented BacktestEngine with condition matching (price_drop, price_rise, volume_spike, price_level)
- Implemented signal generation and portfolio simulation
- Calculates metrics: total_return, win_rate, max_drawdown, sharpe_ratio, total_trades
- Implemented async/background backtest execution via FastAPI BackgroundTasks
- Stores results in backtests table and signals table
- All backtest API endpoints with JWT auth and ownership validation
API Endpoints:
- POST /api/bots/{id}/backtest - Start backtest
- GET /api/bots/{id}/backtest/{run_id} - Get status/results
- GET /api/bots/{id}/backtests - List all backtests
- POST /api/bots/{id}/backtest/{run_id}/stop - Stop running backtest
- Add register endpoint with bcrypt password hashing
- Add login endpoint returning JWT tokens
- Add logout endpoint with token blacklisting
- Add /me endpoint for current user info
- Add rate limiting (5/minute) for login attempts using slowapi
- Add user settings GET and PATCH endpoints
- Create auth middleware via get_current_user dependency
- Add UserSettings and UserSettingsUpdate schemas
Based on IMPLEMENTATION_PLAN.md Section 4 schema, the existing schemas.py
was missing schemas for:
- BotConversationCreate/Response (for bot_conversations table)
- SignalResponse (for signals table)
These were identified as gaps during issue #3 review.
- Added 3 runnable Python scripts for Data REST, Data WebSocket, and Trading APIs
- Expanded research with 7 new sections:
- Extended API documentation with full request/response examples
- Working code examples with CLI commands
- Security guide (API keys, HMAC signing, private key protection)
- Testing strategies (dry-run, paper trading, testnets)
- Troubleshooting guide with error codes
- Competitive analysis vs DexScreener, Moralis, CoinGecko
- Quick reference appendix
Research doc grew from 242 to 906 lines