Yield Boost

Yield boost + MELD Banker support

Yield boost is a novel mechanism to allow for external yield generated from other parts of the MELD protocol/ecosystem to be passed into the users of the lending and borrowing protocol.

Yield boost integration in the protocol has two main areas of development:

  • Bridging

  • Lending and borrowing protocol integration

This page covers the integration in the lending and borrowing protocol, along with the key flows definition.

The Yield boost protocol is a new set of contracts that derive from the original MELD staking system, closely integrating with the Lending and borrowing and having significant modifications to the original codebase.

  • No concept of pools. a full protocol will be deployed linked to each reserve

    • No change delegation flow

  • No lock tiers, therefore no weights or lock times apply

  • No operator, without any fee

  • Positions are unique to each user. One user can only have one position and will be tracked by address, not NFT ID. Positions can’t be transferred

However, a couple of new elements need to be accounted for:

  • Rewards can be distributed in multiple tokens each epoch (reserve asset + MELD)

  • Interactions with the protocol to stake/withdraw need to be limited to only be done by L&B protocol, not user directly

  • Users can claim rewards independently, or the rewards will be claimed on full withdraw or repay of debt

  • User’s staked amount will be dynamic, and rebased every time there is an action of the user on the reserve. This allows for automatic tracking of all flows without having to do specific code changes on each one of them.

    • Specific info on the section below Integration with MELD Banker NFTs

  • Genius loan integration must follow the already existing toolset to allow for yield boost rewards to be used for genius loans (claim rewards by admin, with previous approval from the user)

Protocol still needs to keep track of:

  • Epoch system, that will be in sync with Staking epochs

  • min/last staked amounts for each user on each epoch

  • Rewards are only distributed among those that were active during a full epoch

    • If balance changes happened during the epoch, the smallest balance will be used for calculations

General architecture of the smart contracts:

  • MeldYieldBoost (logic)

  • MeldYieldBoostStorage

All contracts to be deployed on L&B reserve configuration.

Deployment and upgradeability

Yield boost systems will be deployed automatically for all reserves configured to have yieldboost when reserve is configured. We will use a clone system to optimize for gas costs of creation of new reserves. Initial version of the code of the yield boost system to be deployed along with the rest of the protocol.

Reserves can be configured with yieldboost afterwards and the deployment will happen on activation.

Integration with MELD Banker NFTs

Amounts to take into consideration on the yield boost will be modified based on the usage of the MELD bankers NFTs. On this table we show some WIP reference numbers for the multipliers of the users’ supplied/borrowed amounts that will be used in the yield boost

No BankerBanker usedGolden Banker used

Supply multiplier (mToken)

100%

105%

120%

Borrow multiplier (stable and variable debt)

0%

10%

30%

Some properties of the Banker NFTs:

  • If the bank manager is being used in the protocol, it cannot be transferred

  • MELD Banker is a Normal ERC721 token

  • Dynamic metadata, with external module (same as staking). Currently only a link to ipfs.

  • Direct flag for isGolden with a getter.

  • Transfer hook to prevent transferring when the BM is locked into a position

    • check function isBankManagerBlocked(uint256 _id) in the protocol

  • NFT is not burnable at any point by their owner. Only admin with role can

  • There is a Minter contract that mints the NFT and sets the metadata (ipfs hash) to the nft id

And they connect to the protocol by:

  • Can only use it for borrow or supply, not both at the same time

  • Action to start using a Banker NFT can only be done on initial supplying of the asset, can’t be activated later

  • Action to stop using a Banker NFT can only be done on initial borrow of the asset, can’t be activated later

  • Each user can only do this boost for 1 Banker at a time (if you have 1 regular and 1 gold, you can only use 1)

Last updated