🥳Stacking the STX Tokens

An overview of the stacking strategy used in the liquid stacking protocol

The actual strategy to stack the STX tokens and maximize the yield we receive on the rewards address is somewhat complex.

To understand the logic, we need to understand the inner workings of the Proof-of-Transfer (PoX) contract in Clarity. We have stack-stx, stack-extend and stack-increase methods at our disposal. Furthermore, we know that each PoX cycle is 2100 Bitcoin blocks long (approximately 2 weeks), so we will have to model our inflows and outflows based on that.

As a default strategy, 5 stacker contracts will be used, which divide all the STX tokens between them based on a distribution that maximises the yield. In other words, each stacker gets a certain weight (between 0 and 100%) assigned that indicates the percentage of the amount of STX it should stack. The default weights are:

  • Stacker 1: 50%

  • Stacker 2: 25%

  • Stacker 3: 15%

  • Stacker 4: 5%

  • Stacker 5: 5%

Each PoX cycle, all stackers can be extended with 1 cycle, using `stack-extend` (in case of net inflows). In the case that we have net outflows, we will have to unstack some STX. If the outflows are 5% or smaller, we only have to **not** extend 1 stacker, Stacker 5 in this case. If the net outflows are between 5 and 10%, we have to stop stacking with two stackers (Stacker 4 and Stacker 5) etc.

The calculations can be handled off-chain or on-chain. Practically we haven't seen a big advantage handling this on-chain, since all or a subset of STX have to be stacked anyway for the protocol to function.

Last updated