**UI Updates (settings page):** Added new '📈 Position Scaling' section with: - Enable/disable toggle (defaults to OFF) - Min quality score slider (60-90, default 75) - Min profit to scale (0-2%, default 0.4%) - Scale size percent (10-100%, default 50%) - Max position multiplier (1-3x, default 2.0x) - Min ADX increase (0-15, default 5) - Max price position for scale (50-90%, default 70%) **Visual Feedback:** - Purple-themed section with warning banner - Real-time risk calculator showing: * Original position size (SOL example) * Scale addition amount * Total after 1 scale * Maximum possible position size - Dynamic descriptions explain each parameter - Warning: 'DISABLED by default' with red indicator **API Updates:** Extended /api/settings GET/POST to handle 7 new fields: - ENABLE_POSITION_SCALING - MIN_SCALE_QUALITY_SCORE - MIN_PROFIT_FOR_SCALE - MAX_SCALE_MULTIPLIER - SCALE_SIZE_PERCENT - MIN_ADX_INCREASE - MAX_PRICE_POSITION_FOR_SCALE **User Flow:** 1. Navigate to http://localhost:3001/settings 2. Scroll to '📈 Position Scaling' section 3. Toggle 'Enable Position Scaling' to 1 4. Adjust thresholds (defaults are conservative) 5. See live calculation of scaling impact 6. Click 'Save Settings' 7. Click 'Restart Bot' to apply **Safety:** - Feature OFF by default (requires explicit opt-in) - Warning banner explains scaling behavior - Risk calculator shows maximum exposure - Conservative defaults prevent aggressive scaling - All parameters adjustable via sliders **Example:** With defaults (SOL $210×10x = $2100): - Scale adds: $1050 (50% of $2100) - Total after 1 scale: $3150 - Max position (2x): $4200 User can now enable and configure position scaling without touching .env file!
36 KiB
36 KiB