GhostRider Strategy Documentation
Version: 2.0.0
Developer: TradeStaq Technologies
Market: Futures
Table of Contents
- Overview
- Key Features
- Configuration Parameters
- Strategy Logic Summary
- Trading Scenarios
- Strategic Mastery & Success Guide
Overview
GhostRider is a precision-based Gunbot strategy designed primarily for futures markets (though configurable). It aims to "predict and ride the market wave" by utilizing a multi-timeframe analysis to identify dynamic support ("Launchpad") and resistance ("Firewall") zones. The strategy employs a combination of advanced trend, momentum, and volume analysis to determine market sentiment (Bullish, Bearish, or Moderate) and executes trades using a sophisticated DCA (Dollar Cost Averaging) and Scalping engine.
Key Features
- Dynamic Support & Resistance (TradeStaq Zones): The strategy calculates "Launchpad" (Buy) and "Firewall" (Sell) levels across 13 different timeframes (from 15m to 1y). It visualizes these zones to determine optimal entry and exit points.
- Market Sentiment Analysis: Uses comprehensive long-term market data to categorize the market into Bullish, Bearish, Moderate Bullish, or Moderate Bearish.
- Smart DCA (Dollar Cost Averaging): Unlike static DCA, GhostRider adjusts its DCA frequency and distance based on market volatility, "Magic Cooldown" timers, and proximity to support zones.
- Wick Trading: Can optionally target wick entries/exits, attempting to catch price reversals at the extremes of candle shadows.
- Partial Scalping: Allows for selling portions of a position ("scalping") when profitable while holding the remainder ("bag") for higher targets.
- Hedge Capabilities: Built-in logic to open hedge positions on a secondary pair to offset risk during adverse market moves.
- Custom Trailing: Implements internal trailing stop mechanisms for both buying and selling to maximize entries and exits.
- Dashboard Persistence & Reliability: Dashboard data is now persisted across cycles via an internal background cache, ensuring a stable, flicker-free interface even during license checks or fast execution spins.
Configuration Parameters
The following settings can be configured in the customStratEditor or strategy config.
1. Trade Configuration
Core settings defining how the strategy manages capital and direction.
| Parameter | Default | Description & Examples |
|---|---|---|
| TRADE_MODE | auto | Directional Logic Control. auto: Scans market structure. If price hits a "Launchpad" and sentiment is Bullish, it initiates a Long. If price hits a "Firewall" and sentiment is Bearish, it initiates a Short. long: Forces the strategy to only look for Long entries (buys at Launchpad). short: Forces the strategy to only look for Short entries (sells at Firewall). |
| TRADING_LIMIT_TYPE | value | Sizing Model. Select value for fixed quote amount or percentage to scale automatically based on a % of your Wallet Balance. |
| MF_TRADING_LIMIT | 50 | Base Trade Size. The quote currency amount (if value) or % of balance (if percentage) used for the initial entry. |
| OPEN_ORDER_TYPE | base | Entry Currency. Determines if the MF_TRADING_LIMIT is calculated in the base currency (e.g., BTC) or quote currency (e.g., USDT). Example: quote uses USDT amount; base uses BTC amount. |
| CLOSE_ORDER_TYPE | quote | Exit Currency. Determines quantity type for closing trades. Example: Usually set to quote to ensure precise USDT value exits. |
| MF_CAPITAL | 500 | Margin Allocation. The total margin assigned to this pair. Used for calculating risk and DCA logic. Example: Set to 1000 if you have a $1000 balance allocated for this pair. Recommended: 100x your Trade Limit. |
| MIN_VOLUME_TO_SELL | 0.1 | Dust Filter. The minimum position size required to execute a close order. Example: If your position is 0.0001 BTC (worth $5) and this is set to 0.001, the bot won't sell. |
| PERIOD | 5 | Reaction Speed. The primary short-term timeframe (in minutes) used for fast decision making. Example: 5 minutes allows quick entries; 15 filters out more noise. |
| PERIOD_MEDIUM | 240 | Trend Confirmation. The medium timeframe (in minutes) used to confirm the trend. Example: 240 (4 Hours) provides a stable trend baseline. |
| PERIOD_LONG | 1440 | Macro Trend. The long timeframe (in minutes) used for overall market direction. Example: 1440 (1 Day) ensures trades align with the daily trend. |
[!IMPORTANT] Margin Allocation (MF_CAPITAL): GhostRider is a margin-intensive strategy. It is highly recommended to allocate at least 50x to 100x your
MF_TRADING_LIMITas capital to ensure the bot has enough room for DCA operations during volatile moves.
2. PNL Management
Settings for profit taking, stop losses, and risk management.
| Parameter | Default | Description & Examples |
|---|---|---|
| AUTO_GAIN | true | Dynamic Targets. If true, profit targets are calculated based on market volatility rather than a fixed percentage. Example: In a volatile market, target might be 3%; in a flat market, 0.5%. |
| MIN_AUTO_PROFIT | 0.3 | Profit Floor. The minimum % profit accepted when AUTO_GAIN is active. Example: 0.3 ensures the bot never sells for less than 0.3% profit, even in low volatility. |
| MIN_AUTO_PARTIAL_PROFIT | 0.3 | Scalp Floor. The minimum % profit required to execute a partial sell (scalp). Example: Prevents selling small portions for negligible gains. |
| PROFIT_QUOTIENT | 2 | Target Multiplier. Increases the calculated Auto Gain target. Example: If volatility suggests 1%, a quotient of 2 makes the target 2%. Higher = Greedier. |
| PARTIAL_PROFIT_QUOTIENT | 2 | Scalp Multiplier. Increases the calculated target for partial sells. Example: 1 allows taking partial profits earlier than the full close target. |
| GAIN | 2 | Manual Target. Fixed profit target % used only if AUTO_GAIN is false. Example: 2 means sell at 2% profit every time. |
| ENABLE_TRAILING | true | Profit Maximizer. When target is reached, wait for price to peak before selling. Example: Price hits 2% target but keeps rising to 5%. Bot waits. |
| TRAILING_SPREAD | 1 | Trail Distance. The % drop from the peak required to trigger the sell. Example: Price hits 5% peak and drops to 4% (1% drop) -> Sell Triggered. |
| RIDE_PROFIT_WAVE | true | Trend Holding. If true, the bot attempts to hold the position longer during strong momentum, ignoring early exit signals until a reversal is confirmed. |
| ENABLE_STOP_LOSS | false | Hard Stop Switch. Enables the stop-loss logic. |
| STOP_LOSS_SELL_TYPE | partial | Stop Logic. partial: Sells a portion of the bag to reduce risk. full: Closes the entire position (takes full loss). |
| STOP_LOSS_PERCENTAGE | 2 | Stop Trigger. The % loss at which the Stop Loss logic activates. Example: 2 means check for stop loss if position is -2% ROE. |
| STOP_LOSS_THRESHOLD | 50 | Risk Filter. Only triggers Stop Loss if capital usage (margin ratio) exceeds this %. Example: If you only used $10 of your $1000 capital, a -2% drop is ignored. Stop loss activates only when heavily invested. |
3. Execution & Automation
Controls for DCA behavior, buying/selling toggles, and multipliers.
| Parameter | Default | Description & Examples |
|---|---|---|
| BUY_ENABLED | true | Entry Switch. Set to false to stop opening new trades or adding to existing ones. |
| SELL_ENABLED | true | Exit Switch. Set to false to hold positions indefinitely (never sell). |
| ENABLE_DCA | true | DCA Toggle. If false, the bot will strictly avoid placing any additional buys (DCA) after the initial entry. |
| STOP_AFTER_SELL | false | One-Off Mode Mode. If true, the bot stops trading completely after successfully closing a position. |
| ENABLE_DCA_MULTIPLIER | false | Martingale Logic. If true, DCA orders increase in size based on how deep the price falls. |
| DCA_MULTIPLIER | 1 | Base Multiplier. The minimum multiplier applied to DCA orders. Example: 1.5 makes each subsequent buy 50% larger. |
| DCA_MULTIPLIER_LEVEL | 7 | Depth Trigger. The support level index required to activate the multiplier. Example: 7 means don't increase buy size on small dips (Levels 1-6). Only multiply buys at deep support (Level 7+). |
| BULLISH_DCA_MULTIPLIER_LEVEL | 5 | Bullish Depth Trigger. Same as above, but applied when the market sentiment is Bullish. Example: In a Bull market, multiply buys earlier (at Level 5). |
| MAX_DCA_MULTIPLIER | 5 | Safety Cap. The maximum multiplier allowed for any single order. Example: Limits a single DCA buy to 5x the trading limit, preventing liquidation. |
| DCA_QUOTIENT | 1 | Frequency Limit. Controls how many consecutive buys are allowed in a standard zone. Example: 1 allows only one buy per zone to prevent over-trading. |
| BATTLEGROUND_DCA_QUOTIENT | 1 | Pivot Frequency Limit. Controls buy frequency specifically in the "Battleground" (Pivot) zone. Example: 1 restricts buying near the pivot point. |
| ENFORCE_DCA_MIN_STEP | true | Step Control. If true, enforces a minimum price distance between DCA orders. Example: Prevents buying twice at $100 and $99.9. |
| ENABLE_PARTIAL_SELL | false | Scalping Switch. Enables selling portions of the position at resistance levels. |
| STRICT_DCA | false | Aggressive DCA. If true, enforces strict indicator checks for DCAs. If false, allows freer buying to save positions. |
| ENABLE_WICK_TRADE | false | Sniper Mode. If true, detects long wicks piercing support and buys immediately. |
| WICK_TRADE_LEVEL | 11 | Wick Sensitivity. Which support level a wick must hit to trigger. Example: 11 requires a wick to hit very deep support (Weekly). 5 would trigger on shallower wicks. |
| IN_POSITION_MARGIN | 0 | State Threshold. Defines the margin usage threshold to consider the bot "in position" for specific trade stages. |
4. Technical Indicators & Momentum
Fine-tuning the strategy's reaction to market movements.
| Parameter | Default | Description & Examples |
|---|---|---|
| BASE_DCA_PERCENT | 0.5 | Minimum Drop. The minimum price drop % required to trigger a DCA buy. Example: 0.5 means price must drop 0.5% below last buy to consider adding. |
| LAUNCHPAD_TRADE_INDEX | 4 | Long Aggressiveness. Controls which timeframe's support is trusted for entry. Example: 1 (15m) buys shallow dips aggressively. 6 (Daily) waits for major corrections before buying. |
| FIREWALL_TRADE_INDEX | 4 | Short Aggressiveness. Same logic as above but for Short entries. Example: 1 shorts minor pumps. 6 waits for major resistance. |
| LAUNCHPAD_CLOSE_RANGE | 2 | Short Exit Point. Defines the support level used to close Shorts. Example: 2 closes shorts at 1-hour support levels. |
| FIREWALL_CLOSE_RANGE | 2 | Long Exit Point. Defines the resistance level used to close Longs. Example: 2 closes longs at 1-hour resistance levels. |
| MODERATE_BEAR_TRADE_INDEX | 6 | Trend Adaptation. If sentiment is Moderate Bearish, ignore buy zones below this index. Example: Forces minimum entry at Daily Support (Index 6) during choppy downturns. |
| EXTREME_BEAR_TRADE_INDEX | 7 | Crash Protection. If sentiment is Extreme Bearish, ignore buy zones below this index. Example: Forces entry only at 3-Day Support (Index 7) during crashes. |
| DYNAMIC_TRADE_X | false | Auto-Adjustment. If true, automatically increases trade indices based on volatility. Example: If price crashes fast, the bot auto-shifts from looking at 4hr support to Weekly support. |
| MS | 100 | Momentum Sell. Margin ratio % at which the bot force-sells during a pump. Example: If 100% of capital is used and price pumps, sell immediately to secure the bag. |
| SR | 30 | Soft Reduction. Margin ratio % at which the bot begins aggressively selling parts of the bag. Example: If 30% of capital is used, start selling small chunks at break-even or small profit to free up margin. |
| SCALPING_RATIO | 10 | Scalp Cap. Max % of capital allowed for buying in "Upper" (profit) regions. Example: 10 means only use 10% of capital for high-risk scalps above the pivot. |
| AUTO_SCALPING_QTY | false | Smart Scalping. If true, the bot automatically calculates the optimal amount to sell during a scalp based on market conditions, overriding manual settings. Example: In a strong trend, it might sell less to hold for higher profit; in a weak trend, it sells more to lock in gains. |
| SCALPING_SELL_AMOUNT | 0.5 | Scalp Size. Ratio of position to sell during a standard scalp. Example: 0.5 sells 50% of the bag at resistance. |
| SCALPING_UPPER_SELL_AMOUNT | 0.75 | Aggressive Scalp Size. Ratio to sell during a scalp in upper regions. Example: 0.75 sells 75% of the bag to lock in maximum profit. |
| IGNORE_TRADES_BEFORE | 0 | History Reset. Epoch timestamp. Ignore trades before this date. Example: Use this if you manually sold a bag and want the bot to "forget" the old position history. |
5. Hedge Set Up and Parameters
Settings for hedging positions using a secondary pair.
| Parameter | Default | Description & Examples |
|---|---|---|
| HEDGE_PAIR | USDT-BTC | Protection Pair. The secondary pair used to open hedge positions. Example: If trading ETH, you might hedge with BTC to offset market-wide crashes. |
| BULL_HEDGE_RATIO | 0.3 | Bull Hedge Size. Ratio of hedge size vs main position during Bullish conditions. Example: 0.3 means if main position is $1000, hedge is $300. |
| BEAR_HEDGE_RATIO | 0.7 | Bear Hedge Size. Ratio of hedge size vs main position during Bearish conditions. Example: 0.7 means if main position is $1000, hedge is $700 (stronger protection). |
| HEDGE_CLOSE | false | Auto Close. If true, the bot will automatically close the hedge position when it reaches profit targets. |
Strategy Logic Summary
- Zone Calculation: The bot calculates "Launchpad" (Support) and "Firewall" (Resistance) zones by analyzing market highs and lows over various timeframes, ranging from 15 minutes to 1 year.
- Entry Logic:
- Long: The strategy executes a buy order when the price dips into a "Launchpad" zone, provided that momentum analysis shows oversold divergence and the overall market trend is favorable.
- Short: The strategy executes a sell (short) order when the price rises into a "Firewall" zone and momentum analysis shows overbought divergence.
- Smart DCA: If the market moves against an open position, the bot averages down (DCA). The distance between these buy orders is not fixed; it is dynamically calculated based on risk settings, current margin usage, and the distance to the next major support level.
- Exit Logic:
- Full Close: The entire position is closed when the profit target is reached or a trailing stop is triggered.
- Scalp (Partial): If enabled, the bot sells portions of the position at intermediate resistance levels to lock in small profits while holding the core position ("bag") for the final target.
Trading Scenarios
This section explains how GhostRider reacts to specific market conditions, helping you understand the "why" behind its actions.
Scenario A: The "Launchpad" Reversal (Ideal Long)
- Market Condition: The market is in a general uptrend but experiences a sudden pullback or dip.
- Logic: The strategy identifies the market sentiment as Bullish. As the price drops, it hits a calculated support level (e.g., 4-hour support).
- Bot Action:
- The bot detects the price is within a valid Buy Zone.
- It waits for momentum analysis to show oversold divergence (indicating downward momentum is fading).
- It executes a Buy order.
- As the price bounces back up, the Trailing Stop activates once the profit target is met.
- The bot rides the wave upward. If the price dips by the configured spread, it closes the full position to secure profit.
Scenario B: The "Firewall" Defense (Bearish Short)
- Market Condition: The market is in a downtrend, but price rallies briefly (a "dead cat bounce").
- Logic: The strategy identifies the market sentiment as Bearish. The price pumps up into a calculated resistance level (e.g., 12-hour resistance).
- Bot Action:
- The bot detects the price is within a valid Sell Zone.
- It waits for momentum analysis to show overbought divergence (indicating the rally is running out of steam).
- It executes a Short order.
- If the price continues to pump unexpectedly, the Magic Cooldown feature activates, slowing down subsequent DCA orders to prevent using up margin too quickly.
- As the price rejects the resistance and drops, the bot takes profit at the next support level.
Scenario C: The "Wick" Snipe (High Volatility)
- Market Condition: A sudden flash crash or a liquidity wick where price moves violently and quickly retracts.
- Configuration: ENABLE_WICK_TRADE is active with high sensitivity.
- Logic:
- The bot detects a candle with a significantly long lower shadow (wick).
- This wick penetrates a deep support zone (e.g., 3-day support).
- Bot Action: Because the move is extreme, the bot bypasses some standard momentum checks and executes an immediate Snipe Buy to catch the V-shape reversal.
- This often results in a quick scalping exit as the candle closes or the price stabilizes.
Scenario D: The "Sideways" Accumulator (Scalping)
- Market Condition: The market is ranging (moving sideways) between a specific support and resistance level with no clear trend.
- Configuration: ENABLE_PARTIAL_SELL is active.
- Logic:
- The bot buys at the bottom of the range (Support).
- The price rises but struggles to break out of the top of the range (Resistance).
- Bot Action: Instead of holding and hoping for a breakout, the bot sells a percentage of the position (e.g., 50%) at the resistance mid-point.
- This locks in realized profit ("scalping").
- If the price drops back to the entry point, the bot buys again, re-filling the bag. This process repeats, lowering the break-even price with every successful scalp.
Scenario E: The "Hedge" Protector (Crisis Management)
- Market Condition: You are holding a Long position, but the market crashes hard, shifting the trend to Bearish.
- Configuration: A HEDGE_PAIR (e.g., ETH-USDT) is configured.
- Logic:
- The main position (e.g., BTC Long) goes into deep drawdown.
- The strategy detects a sentiment shift to Bearish on the higher timeframes.
- Bot Action: To protect the account, the bot opens a Short position on the hedge pair.
- The size of this hedge is determined by the BEAR_HEDGE_RATIO (e.g., 70% of the main position size).
- The profits from the ETH Short help offset the unrealized losses of the BTC Long, stabilizing the margin ratio until the market recovers.
Strategic Mastery & Success Guide
Disclaimer: This software is an automated tool. You are the pilot. The developer guarantees no specific financial outcome. Trade at your own risk.
1. The "Golden" Checklist Before Going Live
Don't turn the bot on and walk away. Follow this pre-flight check:
- [ ] Trend Check: Is the market trending or ranging? Set TRADE_MODE to auto for most cases, but force long or short if you have strong conviction about the direction.
- [ ] Capital Safety: Ensure MF_CAPITAL is set correctly. A safe rule of thumb is 50x to 100x your MF_TRADING_LIMIT. (e.g., $10 trade limit requires $500-$1000 allocated margin).
- [ ] Stop Loss Config: If you sleep, you must defend. Set ENABLE_STOP_LOSS to true with a STOP_LOSS_THRESHOLD of 50% (triggers SL only when 50% of allocated capital is deployed).
- [ ] Volatility check: In extremely volatile periods (e.g., CPI data release), consider increasing PERIOD_MEDIUM to 360 or 720 to avoid market noise.
2. Risk Management Protocols
GhostRider is aggressive. Tame it with these settings:
- Conservative:
- TRADE_MODE: auto
- ENABLE_WICK_TRADE: false
- SCALPING_RATIO: 0 (Focus on full closes)
- DCA_QUOTIENT: 1 (Fewer DCAs)
- Aggressive (The "Cowboy"):
- ENABLE_WICK_TRADE: true
- ENABLE_PARTIAL_SELL: true
- SCALPING_SELL_AMOUNT: 0.25 (Sell small chunks frequently)
- DYNAMIC_TRADE_X: true (Let the bot shift zones dynamically)
3. Troubleshooting "Bag Holding"
If the bot enters a trade and price moves against you for days:
- Don't Panic Sell: Check the logs to see where the support zones are. Is the price approaching a "Weekly" or "Monthly" support?
- Enable "Magic Cooldown": Set MAGIC_COOLDOWN to true. This slows down buying frequency during adverse trends to prevent exhausting your margin too early.
- Soft Reduction: Lower your SR (Soft Reduction) parameter. This forces the bot to sell a portion of the bag at break-even or slight loss to free up margin for better entries lower down.
4. Community & Support
Markets evolve, and so does GhostRider.
- Telegram: Join the Community for real-time config sharing.
- Website: TradeStaq.com for updates and backtesting results.
Ride the wave, but always wear your helmet (Stop-Loss).
Deploy GhostRider
Backtest and deploy this strategy on any of these exchanges.