[Project] single-token staking contract (FEI or TRIBE) đź’š

Hi guys,

I’d like to see if there would be some interest in the community for a single-token staking contract.

The pitch goes like this :

The protocol distributes rewards for staking Uniswap FEI-TRIBE LP tokens, but what if you have only FEI, only TRIBE, or both of them but not in a 50/50 proportion ? Now, you can stake your tokens and benefit from the >50% APY offered by the protocol’s staking rewards, regardless of how much of each token you own.

Sounds good ?

I propose to implement such a contract, and I’ll try to describe the advantages & inconvenients of it.

Implementation:
Without changes to the protocol, there is no way around it : liquidity has to be provided in the FEI-TRIBE Uniswap pool, and the LP tokens have to be staked in the FeiStakingRewards contract.

The new SingleTokenStaking contract will act like a “zapper” : when you provide a token, half of it will be converted to the other token, it will provide liquidity to Uniswap, and it will stake the LP tokens to collect rewards.

When you want to cash out, the “zapper” will work in reverse : some LP tokens are unstaked, liquidity will be withdrawn from the Uniswap pool, and all the tokens will be swapped to give you only the token you want.

At any moment, anybody can ask the SingleTokenStaking contract to claim the staking TRIBE rewards, have half of it swapped to FEI, and have it provided as liquidity on Uniswap & then staked to collect moar TRIBE staking rewards.

Good:

  • Big APY staking for FEI
  • Big APY staking for TRIBE
  • More liquidity in the FEI-TRIBE pool
  • The compounding acts like a Yearn vault or Pickle jar, but whithout the PICKLE token rewards, and without getting shaved off 20% of your TRIBE staking rewards.
    • The compounding probably don’t need to be called more than once a week : for a base APY of 50%, compounding daily will make it 64.82% APY, while compounding weekly will make it 64.48%…
    • I’d keep a small part of the TRIBE rewards to get ETH to pay for the gas fees, but it would be dwarfed by the added benefits.
    • Alternatively, the core team could be interested in making this contract part of the protocol, and we could have FEI rewards for making the compounding call (like for reweights). In that case, there would be no need for a small fee.

Bad:

  • You are exposed to impermanent loss
    • should be largely compensated by staking rewards
  • You could have some up/downside by staking FEI
  • You could miss some upside on the TRIBE token (but will be less impacted by downside)

I initially considered a TRIBE-only staking contract & have the protocol mint an equal amount of FEI to provide liquidity, but then it raises so many questions, like : what do we do of the TRIBE tokens earned by the protocol’s FEI ? And should the protocol experience some downside if the value of TRIBE decrease ? I also like the proposed solution better, because it has less interactions with the core protocol.

  • I like it
  • meh
  • I like it, but… (comment)
0 voters
4 Likes

Not sure I 100% follow… Wouldn’t the volatility of tribe make this idea not able to work since the exchange rate for the inbound token will be different than the one when it’s unstaked? If i have 100k fei and 50k is converted to tribe but when i unstaked tribe has crashed who pays for the extra tribe to result a net of 100k fei?

I think creating something like a FSA (Fei Savings Account) or FSR (Fei Savings Rate) would be a better stake mechanism. Everyone likes yield farming via stable coins because of no impermanent loss nor volatility and the interest provided could come from yields generated from PCV instead of PCV buying circulating FEI back. I think the earlier interest rate has a more better “net stablization effect” than just buying fei back!

I like the idea of a “FEI savings account” where the tribe would share part of the benefits generated by the PCV with FEI holders to drive adoption of the FEI stablecoin, but it sounds more like a long term proposal :wink: I’m trying to do something short term to try to onboard everyone on staking, even those that don’t own a 50/50 share of tokens.

That would be the risk when staking pure FEI (you would be matched with people who stake TRIBE). I don’t think there is a way around it, because of how Uniswap works.

But if the APY is >50% and a FEI holder believes TRIBE value will drop >50% (which will result in some loss), I don’t see why they would want to farm a doomed token in the first place :stuck_out_tongue: there will be integrations with other protocols that provide a better use of their FEI tokens. On the other side, if TRIBE appreciates, TRIBE stakers share the upside with the FEI stakers they have been matched with.

Ah I see you are suggesting matching tribe stakers with fei stakers like tinder :slight_smile: makes sense and plausible. Thanks for the explanation.

Tecnically FSA would aim to solve the stablization problem short term by contracting liquidity (all the while preserving PCV size which is the key) and thereby rewarding tribe holders longer term yes. This obviously requires value generation from somewhere to pay off the interest rate which could come from the yield from pcv (in the future once FEI stablizes the value could be provided by simply minting new fei).

Interesting idea!

But would this be constrained by the protocol’s original staking of 50/50? Would there be any possibility to tweak the ratio of the underlying LP? Would there be a difference in the economics if the staking is not 50/50?

Yes, the protocol’s original staking is based on Uniswap, so we have no choice but providing tokens in a 50/50 dollar value mix.

The other way to do it would be a TRIBE-only staking contract, where the protocol would mint matching FEI to the TRIBE staked. In that case there would be no way to stake only FEI tokens, but that use case can be taken care of by a separate proposal, like @redball’s FEI savings account, or the upcoming DeFi protocol integrations.

To go further on this topic, here is how that would work for an initial price of FEI = 1$ and TRIBE = 1.5$:

  • Someone provides 1000 TRIBE tokens, for a value of 1500$
    • Let’s say that is 1% of the staking shares
  • The protocol mints 1500$ matching FEI (1500 FEI)
  • Liquidity is provided on Uniswap
  • LP tokens are staked to collect rewards

If the value of TRIBE increase two-fold:

  • FEI = 1$ and TRIBE = 3$
  • The original (1000 TRIBE, 1500 FEI) LP tokens are now redeeming for (707 TRIBE, 2121 FEI)
  • On withdraw, 1% of the share of LP are taken out of Uniswap, which is now worth ~4242$
  • 2121-1500 = 621 FEI are swapped to 207 TRIBE
  • The user gets back 707 + 207 = 914 TRIBE = 2732$
    • The user would have 1000 TRIBE worth 3000$ if they didn’t stake
  • The protocol burns the remaining 1500 FEI

If the value of TRIBE drops by half:

  • FEI = 1$ and TRIBE = 0.75$
  • The original (1000 TRIBE, 1500 FEI) LP tokens are now redeeming for (1414 TRIBE, 1060 FEI)
  • On withdraw, 1% of the share of LP are taken out of Uniswap, which is now worth ~2120$
  • 586 TRIBE are swapped back to FEI, to pay back the protocol 1500 FEI (that burn them)
  • The user gets back 1414 - 586 = 828 TRIBE = 621$
    • The user would have 1000 TRIBE worth 750$ if they didn’t stake

As we can see, in both cases, the TRIBE staker is losing tokens & dollar-value, because they are carrying alone the impermanent loss (on a 2x leverage since protocol provides half the liquidity & is made whole in every situation). But they are also receiving the staking rewards on a 2x leverage (the protocol provide half liquidity, but does not take a share of the profits from staking besides what is required to make it exit without loss).

But those are the worst-case situations, where TRIBE value changes overnight & the staker withdraws directly after it. In practice, with the staking rewards, stakers should win in all situations. For instance, assuming a 50% APY and 3 months of staking (no compounding), the 1000 TRIBE staker will exit with…

  • 1090 TRIBE if value doubles (36% APY in TRIBE, 72% APY in USD)
  • 1181 TRIBE if value halves (72% APY in TRIBE, 36% APY in USD)
  • 1250 TRIBE if value stays the same (100% APY in TRIBE & USD)

Problem: if TRIBE price drop by more than 75%, the protocol could be at risk :

  • At 1$ FEI, 0.375$ TRIBE (75% drop)
  • LP tokens are redeemable for (2000 TRIBE, 750 FEI)
  • LP tokens are worth 1500$ (what the protocol matched, so it should sell all TRIBE to get back its 1500 FEI)

In that situation, I see 2 options : the position could be liquidated (but the TRIBE staker lose their tokens), or the staking position could be “locked” (impossible to unstake) while we wait for more TRIBE rewards to cover the missing value, or wait for impermanent loss to go in the other direction, but in these cases, the protocol emits more FEI in circulation than what is covered by the locked TRIBE, so that is not a good situation. Some TRIBE tokens could be locked forever, too, if the price never recovers and staking rewards end.

1 Like

An interesting idea!

As you mentioned on discord, the threshold for net inflation is a 75% drop in TRIBE. To put it differently, this is the threshold at which the protocol cannot collect its FEI loan. So we might want to set a condition to automatically liquidate the leveraged position before it becomes undercollateralized. It seems to me that the liquidation condition should be a function of not just the relative price, but also the TRIBE-FEI liquidity. The 75% threshold is assuming that the borrower’s TRIBE can be swapped for FEI without slippage, which may not be true in a crisis where TRIBE crashes and the liquidity disappears.

I also have a question. How would providing a 2x leverage for liquidity provision satisfy the demand for TRIBE-only staking? TRIBE holders already have the option to swap 50% of their TRIBE for FEI and stake that. If some of them are choosing not to do this, that would be because for them, the rewards (Uniswap fees and staking rewards) are not enough to compensate for the impermanent loss. But compared to swapping 50% and staking, taking the leveraged position doubles both impermanent loss and rewards. Are there parameters for which someone holding TRIBE doesn’t want to stake without the leverage, but wants to with the leverage? I don’t have a good intuition for this right now.

Hmm… it comes down to TRIBE holders not being willing to sell half of their TRIBE ? Offering leverage to TRIBE stakers is also a way to “catch up” for those that preswapped 100%. But of course it’s more risky.

I’m not satisfied with the liquidation thing, it’s going to be a pain to operate… maybe a “zapper” contract as described in the first post (without leverage) is better ? Apart from compounding, it does not really bring new features vs swapping half of your tokens & staking yourself, but it brings improvement in the user experience & gas use.

I was thinking that being exposed to IL could have similar effects whether you bought your FEI with your TRIBE or borrowed it… but I might be wrong. Anyway, “catch up” makes sense. A lot of people who are already staking could be induced to stake a larger amount through leverage, and this would support the price of TRIBE.

If we don’t want to liquidate (or accept the risk of inflation), maybe the zapper contract is better. A lower gas cost alone could be a big factor for many retail investors. How much do you think will be the reduction in gas cost?

1 Like

Love this idea and I’d participate. I’m staking on Pickle now but if there was an alternative to avoid the 20% cut, I’d be game. Would also like to see you take more of a cut than just covering gas fees if you built this for the community.

I like the idea of zapping as gas costs can stop me entering or compounding at times.

We should avoid calling it single token staking though - that terminology has ties to farming in single token pools. People may think they are avoiding impermanent loss by putting into this pool.

A compounding button would be great for fei/tribe.

1 Like