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:
  • longPositionUsd and shortPositionUsd for the pair
From those it computes the ratio R = shortPositionUsd / longPositionUsd and picks a tier:
TierEntry R ≥Exit R <Grid step
0 (inactive)1
10.90.82
21.00.93
31.251.14
41.51.34
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
ValueCheck
Long$800
Short$960
R = $960 / $8001.20R ≥ 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
ValueCheck
Long$700
Short$1,000
R = $1,000 / $7001.43R ≥ 1.25 → Tier 3 (step 4)
Short grid reconstructs at step 4.
Step 3: Price reverses, gradual decay
ValueCheck
Long$900
Short$990
R1.10R < 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

FeatureInteraction
Hedge GuardComplementary. 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 GuardComplementary. 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 indicatorWhile 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 GuardLong-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 earlierLower the entryRatio of tier 1 (e.g. 0.85)
Larger spacing during a pumpRaise later tiers' step (caps at short grid's orders-per-side / cache limits)
Slower re-tightening after a reversalLower exitRatio of each tier, or raise cooldownMs
Fewer but bigger tier jumpsRemove an intermediate tier. The config schema accepts any number of tiers as long as they are monotonic.

Troubleshooting

SymptomLikely cause
Throttle never activatesLong position is 0, or you are in long mode, or enabled: false at the effective scope
Throttle stuck at an old tier after price reversesCooldown or exit threshold has not yet passed. Check R and lastStateChangeTs in the dashboard
Short OPEN orders still being amplifiedVerify 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 changeTier changed but the step did not (e.g. tier 3 ↔ tier 4). Reconstruction only triggers on step change