Keep leverage
A GMX setting that, when enabled during a partial close, withdraws collateral in proportion to the size being closed so the remaining position keeps its original leverage ratio. With it disabled, the leverage of what is left shifts.
Definition
Keep leverage is a toggle on the close dialog that decides what happens to your collateral when you close part of a position. Enabled, collateral is withdrawn alongside size in the same proportion, so the ratio between them stays as it was. Disabled, the collateral stays put and only the size shrinks.
Why the toggle exists
Leverage is size divided by collateral. Reduce only the size, and the ratio falls: the remaining position becomes more conservatively funded, its liquidation price moves further away, and more of your money stays locked in the trade than the position now needs.
Reduce both together, and you get back the collateral you no longer need, but the remaining position carries the same risk profile it had before, with the same distance to liquidation.
Which setting to use when
The two settings answer different questions. Taking profit and wanting the freed capital available elsewhere points to keeping leverage. Reducing exposure because the trade is uncomfortable points to leaving the collateral in place, since that is what actually buys the remaining position more room.
The mistake is assuming that closing half a position halves the risk on the other half. Whether it does depends entirely on this toggle.
Where you will run into it
On the GMX close dialog when entering a partial close. Other perpetual venues express the same choice differently, sometimes as a separate collateral withdrawal step after the close, sometimes automatically according to the margin mode in use.