Reap the Harvest of Yield Farming on Blockchain I.

Yimikz
UCL CBT
Published in
8 min readDec 21, 2022

This article is the first part of a concise summary of the paper ‘Reap the Harvest on Blockchain: A Survey of Yield Farming Protocols’ by Dr Jiahua Xu and Yebo Feng. Dr Xu is a researcher at UCL Centre for Blockchain Technology and the programme manager of M.Sc. Emerging Digital Technologies at UCL. Yebo Feng is a Ph.D. candidate of the Computer and Information Science Department at University of Oregon, USA.

A Brief Introduction

Reaping the harvest is symbolic of receiving rewards of assets invested in. As a farmers’ seeds are major requirements for harvesting crops in agriculture, so are crypto assets requirements to undergo yield farming on the blockchain.

Yield farming enables interest generation through decentralised asset managers. The process occurs automatically with the use of self-executing computer algorithms which deploy the cryptocurrencies gained from users into income generating services such as market makers and lending. As these protocols charge a management fee, while users earn interests on digital assets, a mutually beneficial relationship exists.

The top yield aggregators — market share information.

Background in DeFi

Yield farming protocols are a sub-components of the wider decentralised finance (DeFi) ecosystem, which is built on top of the blockchain. As a sharp contrast to the traditional financial system, which are highly centralised, DeFi relies on a the decentralised network of the blockchain to democratise finance, cutting out the middle-man or central authority, therefore, enhancing accessibility, inclusion and transparency. The three layers of the DeFi ecosystem are explained below:

A. DeFi Chain Layer

The DeFi chain layer lies at the foundation and requires smart contract compatibility for DeFi protocols and other decentralised applications (dApps) to exist. Ethereum, host of the highest number of DeFi protocols recently transitioned from the proof of work (PoW) consensus mechanisms to proof of stake (PoS) due enormous energy consumption and scalability issues. Beyond forming an infrastructural base layer, PoS chains function as a yield mechanisms for user to incentivise participation in consensus.

The architecture of the DeFi ecosystem on blockchain

B. DeFi Primitive Layer

The DeFi primitive layer is built on top of the chain layer, and serves as the application layer, enabling financial products and services to be available to everyone. DeFi primitives include Automated Market Maker (AMM) based DEXes, Protocol for Loanable Funds (PLF) and stablecoins.

  1. AMM-based DEX: As an alternative to book-based exchanges, these DEXes utilise an algorithm known as “conservative function” to compute the exchange rate between two assets based on the demand and supply. AMM-based DEX include Uniswap, Curve and Balancer.
  2. PLF: This protocol utilises an interest rate model to automatically change the borrow and supply rates based on the ratio of the total borrowed to the total supplied (utilisation ratio) for each asset. Only with the provision of sufficient collateral is a loan provided to borrowers as lenders receive interest bearing tokens in accordance to the amount supplied. PLFs include Aave and Compound.
  3. Stablecoins: These are blockchain-deployed token contracts pegged to an asset, which could be another cryptocurrency, a legal tender, a commodity or a combination of these. Stablecoins are either asset-backed or algorithmically programmed. USDT, USDC and DAI include the most popular dollar-pegged stablecoins.
The interactions between the environment of an Automated market maker (AMM).
The interactions between the environment of a Protocol for Loanable Funds (PLF).

The figures above are state diagrams which describe the interactions between the environment of a DeFi protocol and the associated actions. The sign “+” means positive effect, while the sign “−” means negative effect.

C. DeFi Aggregation Layer

Protocols on the aggregation layer interact with the chain or primitive DeFi layers for end users. These protocols can be grouped into two depending on if end users are providing or requesting the service.

The interactions between the environment of yield-aggregator protocols.
  1. Demand-side Aggregators: These aggregators algorithmically select the most ideal rate among multiple DeFi primitives. These include Paraswap and 1inch
  2. Supply-side Aggregators: These protocols perform yield farming directly with the chain layer (Lido and Ankr) by enabling users gain staking rewards on PoS chains or with the primitive layer (Yearn Finance, Beefy and Badger DAO) by allocating customers’ funds and generating returns.

Yield Farming Preliminaries

A. Types of Yield Farming Protocols

  1. Yield Aggregators: In these protocols, following the deposting of funds into a yield farming pool, tokens of the pool are issued, representing a part of the total pool funds. The value of the pool token changes with an increase or decrease of the total pool wealth. Examples of yield aggregators include Yearn, Beefy and Badger.
  2. Yield-bearing Stablecoins: These protocols work similarly to traditional banks, as interest is gained on dollar-pegged stablecoins over a period of time. As opposed to minting pool tokens, stablecoins are issued to users by the protocol, as a proof of deposit. The wallet of the holders sees an increase in the quantity of the stablecoin, as opposed to an increase in the value of the token. Bank of Chain a yield-bearing stablecoin protocol, issues USDi, for example.
  3. Lottery Protocols: These protocols automatically pool uses individual funds and issues each user a lottery ticket token. However, rather than disturbuting interest in proportion to funds deposited, the protcol randomly selects one or more users, who receive the yield of all the participants. PoolTogether is an example of this type of protocol.
  4. NFT Farming: These protocols give utility by creating liquidity for NFTs and providing token owners with yield. Platforms which provide these services include Axie Infinity, ZooKeeper, Pulsar Farm and MOBOX.

B. Yield Farming Operations

1] User Actions:

a. Deposit: Users can perform deposit funds into their preffered yield farming pools by authorising the transfer of tokens to the pool’s smart contract.

b. Redeem: Except in protocols which have token time locks, users may choose to redeem funds deposited in addition to any yield generated.

2] Protocol Actions

a. Mint: When a user deposits funds, the protocol mints pool token in the accordance with the amount deposited

b. Burn: Following the user’s withdrawal request of funds by the user, pool tokens need to be released by users and burned by the protocol.

c. Invest: The protocol can pool funds aggregated by all users and invest in either AMMs acting as the liquidity provider to collect fees, or in a PLF to earn interests as a lender. In other cases, a yield farming protocol can invest in another yield farming protocol.

d. Withdraw: Following the user’s request to redeem their funds from the yield farming protocol, the pool contract triggers the withdrawal of the corresponding amount from the protocol.

e. Swap: The protocol generally performs swap on AMMs, which enable the conversion of yield tokens into initlaly deposited tokens.

f. Borrow: Fund deposited by users can be utilised as collateral to borrow from PLF by protocols. A higher amount of fund locked in as collateral equates to higher participation rewards for the protocol and higher yield tokens can be retrieved to generate more interest for users.

g. Repay: Following the borrowing of tokens by protocols, a partical or full repay can begin over a period of time. Once the full repayment is made, the collateral is relased to the protocol. However, if payment is not received, the collateral will be liquidated.

h. Rebase: In addition to the asset deposited by users, yield farming protocols may contain other assets, due to investment diversification in multiple protocols. These assets prices are retrieved via an oracle and the total value locked is calculated. The rebase action can be defined as the update of the exchange rate through the division of the updated pool value by the assets deposited by users.

C. Forms of Yield Farming Pools

1] Pool Structure

a. Single-asset Pool Structure: These are yield farming pools which only accept the deposit of one asset.

b. Multiple-asset Pool Structure: This involves the deposit of more than one asset, which are typically pegged to each other.

2] Accepted Token Types

a. Stablecoins: As an alternative to the recent traditional finance low-interest rates, stablecoins offer higher yield to yield farming users.

b. Liquidity Pool Tokens: Various protocols accept LP tokens, which provide tokenholders with swap fee.

c. Others: Yield farming protocols accept other assets beyond stablecoins and LP tokens. These include the native blockchain currency and tokens of other DeFi protocols.

D. Sources of Yield

  1. Supply Interest: This is a type of yield that comes from lending crypto assets. When demand for loans in crypto assets is high, the interest rates on those loans increases, which means lenders can earn higher yields. This is a typical occurrence in a bullish market, where speculators are willing to pay high interest rates to borrow assets in the hope that the value of those assets will potentially increase.
  2. Swap Fee Income: In this case, yield is generated following the provision of liquidity, as tokens give users a share of the revenue generated by a protocol. For example, in an Automated Market Maker (AMM)-based decentralized exchange (DEX), users who provide liquidity to an AMM pool can earn fees from traders using that pool, which can be governance tokens or other types of tokens.
  3. Participation Rewards: These are a type of yield that are earned by early participants in liquidity mining programs. Users are incentivised to contribute funds to a protocol and by giving them native tokens that represent ownership in the protocol, decentralisation is enabled. These tokens often have governance functions that allow token holders to influence the direction of the project, and they may also give holders a share of the protocol’s revenue. The value of these tokens can also increase if they are in high demand, which can be an additional benefit for token holders.
The Total value locked (TVL) (b USD) of yield aggregators on Ethereum, BNB Chain and Polygon. Data collected on 12 September 2022
The top yield aggregators — protocol mechanisms.

To Conclude

Despite the exhilarating popularity of yield farming, it remains unclear whether current yields will be sustinable long term. In addition to this, Its important to note that higher yields are associated with greater risks and the smart contract vunerability of DeFi protocols, show the susceptible of even the most secure protocols to attack.

Despite these few concerns, yield farming protocols provide a significant opportunity of decentralised finance to everyone. As smart contract functionality evolves, a higher number DeFi and yield farming protocols mechanisms will emerge. Replicating, automating and disrupting the finance world of today.

--

--

Yimikz
UCL CBT
Writer for

Interested in web3 products which bring significant value to users and businesses. I write about FinTech, DeFi. AI, NFTs, DAOs and start-ups.