$npx -y skills add agiprolabs/claude-trading-skills --skill exit-strategiesSystematic exit rules, stop-loss methods, take-profit strategies, and trailing stop implementations for crypto trading
| 1 | # Exit Strategies |
| 2 | |
| 3 | Entries are easy, exits are everything. A mediocre entry with a disciplined exit will |
| 4 | outperform a perfect entry with no exit plan. This skill covers systematic, rule-based |
| 5 | exit methods for crypto and Solana token trading. |
| 6 | |
| 7 | ## Why Exits Matter |
| 8 | |
| 9 | - **Entries** determine _if_ you participate. **Exits** determine _how much_ you keep. |
| 10 | - Most traders spend 90% of effort on entries and 10% on exits — invert this. |
| 11 | - Without defined exits you rely on emotion, which guarantees inconsistency. |
| 12 | - Every trade should have **three exits defined before entry**: stop loss, take profit, |
| 13 | and trailing stop. |
| 14 | |
| 15 | ## Exit Categories |
| 16 | |
| 17 | ### 1. Stop Loss — Risk Management Exits |
| 18 | |
| 19 | Predefined price level where you close the position to cap downside. |
| 20 | |
| 21 | | Method | Description | Best For | |
| 22 | |--------|-------------|----------| |
| 23 | | Fixed percentage | Exit at entry − X% | Simple setups, beginners | |
| 24 | | ATR-based | Entry − ATR(14) × multiplier | Volatility-adaptive | |
| 25 | | Support level | Below nearest swing low | Technically defined risk | |
| 26 | | Maximum loss | Absolute SOL/USD cap | Account protection | |
| 27 | |
| 28 | **ATR-based stop (recommended default):** |
| 29 | |
| 30 | ```python |
| 31 | import pandas_ta as ta |
| 32 | |
| 33 | atr = df.ta.atr(length=14) |
| 34 | stop_loss = entry_price - (atr.iloc[-1] * 2.0) # 2x ATR below entry |
| 35 | ``` |
| 36 | |
| 37 | Multiplier guide: |
| 38 | - **1.5×** — Tight. High win rate needed. Good for scalps. |
| 39 | - **2.0×** — Standard. Balances noise filtering with risk. |
| 40 | - **3.0×** — Wide. For swing trades in volatile conditions. |
| 41 | |
| 42 | See `references/stop_loss_methods.md` for complete methodology. |
| 43 | |
| 44 | ### 2. Take Profit — Target Exits |
| 45 | |
| 46 | Predefined levels where you lock in gains. |
| 47 | |
| 48 | **Fixed risk/reward targets:** |
| 49 | |
| 50 | ```python |
| 51 | risk = entry_price - stop_loss_price |
| 52 | tp_2r = entry_price + (risk * 2) # 2:1 R:R |
| 53 | tp_3r = entry_price + (risk * 3) # 3:1 R:R |
| 54 | tp_5r = entry_price + (risk * 5) # 5:1 R:R |
| 55 | ``` |
| 56 | |
| 57 | **Scaled exit framework (recommended for meme/PumpFun tokens):** |
| 58 | |
| 59 | | Tranche | Size | Target | Action After | |
| 60 | |---------|------|--------|--------------| |
| 61 | | 1 | 25% | 2× risk | Move stop to breakeven | |
| 62 | | 2 | 25% | 3–5× risk | Trail remainder | |
| 63 | | 3 | 25% | 5–10× risk | Tighten trail | |
| 64 | | 4 | 25% | Trailing stop | Moonbag — let it ride | |
| 65 | |
| 66 | **Market cap milestone exits:** |
| 67 | |
| 68 | For PumpFun and meme tokens where R:R ratios are less meaningful: |
| 69 | |
| 70 | ```python |
| 71 | milestones = [ |
| 72 | {"mcap": 50_000, "sell_pct": 0.25, "label": "Cover cost"}, |
| 73 | {"mcap": 100_000, "sell_pct": 0.25, "label": "Lock profit"}, |
| 74 | {"mcap": 500_000, "sell_pct": 0.25, "label": "Major profit"}, |
| 75 | # Hold 25% as moonbag with trailing stop |
| 76 | ] |
| 77 | ``` |
| 78 | |
| 79 | See `references/take_profit_strategies.md` for full methodology including Fibonacci |
| 80 | extension targets and volume-based exits. |
| 81 | |
| 82 | ### 3. Trailing Stop — Trend-Following Exits |
| 83 | |
| 84 | Dynamic stops that follow price upward but never move down. |
| 85 | |
| 86 | **Percentage trailing:** |
| 87 | |
| 88 | ```python |
| 89 | def percentage_trailing_stop( |
| 90 | current_price: float, |
| 91 | highest_since_entry: float, |
| 92 | trail_pct: float = 0.10, |
| 93 | ) -> tuple[float, bool]: |
| 94 | """Return (stop_level, triggered).""" |
| 95 | highest = max(highest_since_entry, current_price) |
| 96 | stop = highest * (1 - trail_pct) |
| 97 | return stop, current_price <= stop |
| 98 | ``` |
| 99 | |
| 100 | **ATR trailing (Chandelier Exit):** |
| 101 | |
| 102 | ```python |
| 103 | def chandelier_exit( |
| 104 | highs: list[float], |
| 105 | atr_value: float, |
| 106 | multiplier: float = 2.5, |
| 107 | lookback: int = 22, |
| 108 | ) -> float: |
| 109 | """Highest high over lookback minus ATR * multiplier.""" |
| 110 | highest_high = max(highs[-lookback:]) |
| 111 | return highest_high - (atr_value * multiplier) |
| 112 | ``` |
| 113 | |
| 114 | **EMA trailing:** |
| 115 | |
| 116 | ```python |
| 117 | # Exit when close < EMA for M consecutive bars |
| 118 | ema = df.ta.ema(length=20) |
| 119 | below_ema = df["close"] < ema |
| 120 | consecutive_below = below_ema.rolling(3).sum() == 3 # 3 bars below |
| 121 | ``` |
| 122 | |
| 123 | Typical EMA periods: 10 (scalp), 20 (day trade), 50 (swing). |
| 124 | |
| 125 | See `references/trailing_stops.md` for Parabolic SAR, SuperTrend, and step trailing. |
| 126 | |
| 127 | ### 4. Time-Based Exits |
| 128 | |
| 129 | Exit if the trade hasn't moved in your favor within a defined window. |
| 130 | |
| 131 | ```python |
| 132 | bars_since_entry = current_bar - entry_bar |
| 133 | if bars_since_entry > max_hold_bars and current_pnl <= 0: |
| 134 | exit_reason = "time_stop" |
| 135 | ``` |
| 136 | |
| 137 | Guidelines: |
| 138 | - **Scalp**: 5–15 minutes |
| 139 | - **Day trade**: 4–8 hours |
| 140 | - **Swing**: 3–5 days |
| 141 | - **PumpFun snipe**: 2–10 minutes (token-specific) |
| 142 | |
| 143 | Time stops prevent capital from sitting in dead trades. |
| 144 | |
| 145 | ### 5. Signal-Based Exits |
| 146 | |
| 147 | Exit when the indicator that generated the entry signal reverses. |
| 148 | |
| 149 | ```python |
| 150 | # RSI reversal exit |
| 151 | rsi = df.ta.rsi(length=14) |
| 152 | if position == "long" and rsi.iloc[-1] > 70: |
| 153 | exit_reason = "rsi_overbought" |
| 154 | |
| 155 | # MACD crossover exit |
| 156 | macd = df.ta.macd() |
| 157 | if macd["MACDs_12_26_9"].iloc[-1] < macd["MACDh_12_26_9"].iloc[-1]: |
| 158 | exit_reason = "macd_bearish_cross" |
| 159 | ``` |
| 160 | |
| 161 | Signal exits work well when combined with trailing stops — the signal triggers |
| 162 | tightening the trail rather than an immediate full exit. |
| 163 | |
| 164 | ### 6. Liquidity-Based Exits |
| 165 | |
| 166 | Exit when volume or liquidity dete |