Ratio Fee
Last updated
Was this helpful?
Last updated
Was this helpful?
The Ratio Swap Fee Module is one of many dynamic fee mechanisms that can be used to price LST-> Native Token swaps in STEX AMM. The Ratio Fee follows similar logic to the Utilization Rate formula commonly used in Lending and Borrowing Protocols, the goal being to incentive LPs based on the amount of LST reserves they are exposed to and incentivize productive capital (Native Token deposits) when they are needed.
The Swap Fee Module applies a fee based on swap direction:
Native Token -> LST
swaps always receive a zero fee
LST -> Native Token
swaps receive a dynamic fee between feeMin and feeMax corresponding to how the swap affects LPs current exposure to LST reserves.
The Swap Fee Module uses four parameters to determine the swap fee
feeMinBips
- fee applied when the current ratio is below the threshold
feeMaxBips
- fee applied when the current threshold is above the maximum threshold
minThresholdBips
- the critical ratio where a linear fee is applied
maxThresholdBips
- the critical ratio where fee reaches a maximum
The LST: Native Token Ratio
is measured as the current LST reserves (in the pool and queued for withdrawal) divided by the Native Token reserves (In the pool and lending module).
The resulting dynamic fee acts to incentivize liquidity providers when they take on large LST-denominated positions. This swap fee ensures APY is high to incentivize new LP deposits when the ratio is imbalanced while properly pricing the risk associated with holding a position denominated in the LST.