Hedge Throttle
What it does
Slows down short-side accumulation during sustained pumps by widening the spacing between short grid orders. Activates earlier and in smaller steps than Hedge Guard, so it kicks in while the imbalance is still mild and keeps Hedge Guard as a last resort.
Why this exists
On a strong uptrend, price keeps pushing into your short grid's sell levels. The short grid fills and fills, so your short grows fast while your long shrinks (long CLOSE sells fill as price rises). Left alone, this ends with a short that is much larger than your long, at which point Hedge Guard on the long side has to do a lot of work to catch up.
Hedge Throttle intervenes earlier. When
short / long starts drifting above parity, it widens the spacing of the short grid so new short OPEN orders land further from price. The short still accumulates, just more slowly, which buys time for price to roll over before Hedge Guard is needed.This feature is short-mode only. Long mode is unchanged.
For all config fields, see Config Reference.
How it works
Hedge Throttle evaluates on the short-mode grid service every time the grid is rebuilt, a counter order is computed, or a new candle closes. It reads two numbers:
longPositionUsdandshortPositionUsdfor the pair
From those it computes the ratio
R = shortPositionUsd / longPositionUsd and picks a tier:| Tier | Entry R ≥ | Exit R < | Grid step |
|---|---|---|---|
| 0 (inactive) | — | — | 1 |
| 1 | 0.9 | 0.8 | 2 |
| 2 | 1.0 | 0.9 | 3 |
| 3 | 1.25 | 1.1 | 4 |
| 4 | 1.5 | 1.3 | 4 |
Step is a multiplier on the short grid's price spacing. Step 2 means short orders are placed at every second level instead of every level, so the grid is half as dense. Step 3 is every third level, step 4 is every fourth.
Tier 4 is a hedge-guard-overlap marker. It uses the same step as tier 3 and only changes reporting and logging. At tier 4, Hedge Guard on the long side is usually active as well.
If
longPositionUsd ≤ 0, Hedge Throttle stays inactive (there is nothing to compare against).Activation and deactivation
Upward tier changes apply immediately. If
R jumps from 0.85 to 1.05 in one evaluation, the throttle moves straight from tier 0 to tier 2.Downward tier changes use the exit threshold of the current tier plus a cooldown (
cooldownMs, default 60 seconds). Both must pass before the throttle drops back. This prevents flapping when R hovers near a tier boundary.When the step changes, the short grid is reconstructed using the standard debounced path so outstanding short OPEN orders get re-placed at the new spacing. Tier changes that do not change the step (tier 3 ↔ tier 4) update state and logs but do not reconstruct.
Worked example
Settings: defaults (
cooldownMs = 60000, default tier table).You run $10 long orders and $5.50 short orders on HYPEUSDT. Price pumps.
Step 1: Drift past parity
| Value | Check | |
|---|---|---|
| Long | $800 | |
| Short | $960 | |
| R = $960 / $800 | 1.20 | R ≥ 1.0 → Tier 2 (step 3) |
Short grid reconstructs at step 3. New short OPEN orders go out at every third price level.
Step 2: Pump continues
| Value | Check | |
|---|---|---|
| Long | $700 | |
| Short | $1,000 | |
| R = $1,000 / $700 | 1.43 | R ≥ 1.25 → Tier 3 (step 4) |
Short grid reconstructs at step 4.
Step 3: Price reverses, gradual decay
| Value | Check | |
|---|---|---|
| Long | $900 | |
| Short | $990 | |
| R | 1.10 | R < 1.1 (tier 3 exit) → drops toward tier 2 after cooldown |
After 60 seconds of
R staying below 1.1, the throttle drops to tier 2 and the short grid reconstructs at step 3.Interaction with other features
| Feature | Interaction |
|---|---|
| Hedge Guard | Complementary. Hedge Throttle runs on short mode, Hedge Guard runs on long mode. Hedge Throttle activates first (tier 1 at R = 0.9); Hedge Guard catches the extreme case (long below 0.667 of short). At tier 4 both can be active at once. |
| Short Size Guard | Complementary. Hedge Throttle widens spacing while Short Size Guard reduces per-order short base size. When both are active, short OPEN orders are smaller and farther apart. |
| EXO indicator | While the throttle is active, short OPEN orders use base size only. EXO's multiplier is not applied to short OPEN. Long-side EXO is unaffected. |
| Rebalancer (deficit amplification) | While the throttle is active, short OPEN orders use base size only. amplificationPerFill is not stacked on short OPEN. Deficit tracker state updates normally. |
| Position Balancer (decumulation) | CLOSE-side only. No interaction. |
| Long Bias Guard | Long-mode only. No interaction. |
Short CLOSE orders are not throttled. They keep placing against inventory with normal
minQty constraints so short position reduction continues as before.Tuning tips
| If you want... | Adjust this |
|---|---|
| The throttle to act earlier | Lower the entryRatio of tier 1 (e.g. 0.85) |
| Larger spacing during a pump | Raise later tiers' step (caps at short grid's orders-per-side / cache limits) |
| Slower re-tightening after a reversal | Lower exitRatio of each tier, or raise cooldownMs |
| Fewer but bigger tier jumps | Remove an intermediate tier. The config schema accepts any number of tiers as long as they are monotonic. |
Troubleshooting
| Symptom | Likely cause |
|---|---|
| Throttle never activates | Long position is 0, or you are in long mode, or enabled: false at the effective scope |
| Throttle stuck at an old tier after price reverses | Cooldown or exit threshold has not yet passed. Check R and lastStateChangeTs in the dashboard |
| Short OPEN orders still being amplified | Verify the throttle is active on the pair. When active, short OPEN orders must use base size with multiplier 1.0 |
| Grid did not reconstruct on tier change | Tier changed but the step did not (e.g. tier 3 ↔ tier 4). Reconstruction only triggers on step change |