# Exploring AAVE vs Compound

## Scenario

As an investment analyst at a venture capital firm specializing in a liquid fund, your current task is to conduct a comparative analysis of AAVE and Compound, focusing on user behavior, UA/UR, operational metrics, and token metrics. Your goal is to guide potential investment decisions based on on-chain data insights into user behaviour, operational efficiency, and token dynamics. This in-depth analysis aims to inform the firm's strategic investments in the dynamic decentralised finance landscape.

## Problem Statement

Construct a structured framework for assessing user behaviour, UA/UR, operational metrics, and token dynamics to allow the firm to make informed choices.

### <mark style="color:blue;">User Acquisition/Retention</mark>

Investigate protocol growth metrics and how well the protocols are attracting and retaining new users.

### <mark style="color:purple;">User Behaviour</mark>

Analyse user preferences by assessing the popularity of features on both AAVE and Compound (e.g. How often are flash loans utilised?). Observe user engagement metrics, including the frequency and diversity of transactions. Examine key money market activities like borrows, repays, liquidations, deposits, and withdrawals. Evaluate how prone users are to liquidation between the two platforms.

### <mark style="color:orange;">Operational</mark>

Investigate the special case of USDC lending/borrowing, value locked, borrowing rates, and spread (if available) between both platforms. Compare markets in AAVE vs Compound and how their interest rate models interact.

### <mark style="color:red;">Token Metrics</mark>

Assess whether fluctuations in token prices correlate with the overall performance of the platforms.

## Method

You create 4 dashboards on Orus, each with purposes as described below.

### <mark style="color:blue;">User Acquisition/Retention</mark>

* User retention ‘funnel’:
  * User retention (proxy): Active users (90D) / Active users (180D)) → `[ETH]C [AAVEV2]APP ACTIV_90D / [ETH]C [AAVEV2]APP ACTIV_180D G 180D`, `[ETH]C [COMPOUNDV2]APP ACTIV_90D / [ETH]C [COMPOUNDV2]APP ACTIV_180D G 180D`, `[ETH]C [AAVEV3]APP ACTIV_90D / [ETH]C [AAVEV3]APP ACTIV_180D G 180D`, `[ETH]C [COMPOUNDV3]APP ACTIV_90D / [ETH]C [COMPOUNDV3]APP ACTIV_180D G 180D`
  * User retention (proxy): Active users (30D) / Active users (90D) → `[ETH]C [AAVE*]APP ACTIV_30D / [ETH]C [AAVE*]APP ACTIV_90D G 180D`, `[ETH]C [COMPOUND*]APP ACTIV_30D / [ETH]C [COMPOUND*]APP ACTIV_90D G 180D`
  * User retention (proxy): Active users (7D) / Active users (30D) → `[ETH]C [AAVE*]APP ACTIV_7D / [ETH]C [AAVE*]APP ACTIV_30D G 180D`, `[ETH]C [COMPOUND*]APP ACTIV_7D / [ETH]C [COMPOUND*]APP ACTIV_30D G 180D`
* New users: New user count by day → `[ETH]C [AAVE*]APP NEW G 180D`, `[ETH]C [COMPOUND*]APP NEW G 180D`

### <mark style="color:purple;">User Behaviour</mark>

* TX count: TX count → `[ETH]C [AAVE*]APP TXC G 180D`, `[ETH]C [COMPOUND*]APP TXC G 180D`
* Deposit/withdrawal/borrow/repay/liquidation count & volume
  * `[ETH]C [AAVE*]APP DC G 180D`, `[ETH]C [COMPOUND*]APP DC G 180D`
  * `[ETH]C [AAVE*]APP WC G 180D`, `[ETH]C [COMPOUND*]APP WC G 180D`
  * `[ETH]C [AAVE*]APP BC G 180D`, `[ETH]C [COMPOUND*]APP BC G 180D`
  * `[ETH]C [AAVE*]APP REPC G 180D`, `[ETH]C [COMPOUND*]APP REPC G 180D`
  * `[ETH]C [AAVE*]APP LIQC G 180D`, `[ETH]C [COMPOUND*]APP LIQC G 180D` (not in metadata API yet)
  * `[ETH]C [AAVE*]APP DV G 180D`, `[ETH]C [COMPOUND*]APP DV G 180D`
  * `[ETH]C [AAVE*]APP WV G 180D`, `[ETH]C [COMPOUND*]APP WV G 180D`
  * `[ETH]C [AAVE*]APP BV G 180D`, `[ETH]C [COMPOUND*]APP BV G 180D`
  * `[ETH]C [AAVE*]APP REPV G 180D`, `[ETH]C [COMPOUND*]APP REPV G 180D`
  * `[ETH]C [AAVE*]APP LIQV G 180D`, `[ETH]C [COMPOUND*]APP LIQV G 180D` (not in metadata API yet)
* Liquidation risk: Liquidation count / Active users (30D) → `[ETH]C [AAVE*]APP LC / [ETH]C [AAVE*]APP ACTIV_30D G 180D` , `[ETH]C [COMPOUND*]APP LC / [ETH]C [COMPOUND*]APP ACTIV_30D G 180D`
* Flash loan count vs TX count → `[ETH]C [AAVE*]APP FLC AGG[C] / [ETH]C [AAVE*]APP TXC AGG[C] G 180D` (not in metadata API yet)

### <mark style="color:orange;">Operational</mark>

* Special case: USDC lending/borrowing → `[ETH]C [AAVE*]APP [USDC]A DV G 180D`, `[ETH]C [AAVE*]APP [USDC]A BV G 180D`, `[ETH]C [COMPOUND*]APP [USDC]A DV G 180D`, `[ETH]C [COMPOUND*]APP [USDC]A BV G 180D`
* Liquidity: TVL → `[ETH]C [AAVE*]APP L AGG[APP] G 180D`, `[ETH]C [COMPOUND*]APP L AGG[APP] G 180D`
* Interest rates, lending-borrowing spread → `[ETH]C [AAVE*]APP [USDC]A BR G 180D`, `[ETH]C [AAVE*]APP [USDC]A SR G 180D`, `[ETH]C [AAVE*]APP [USDC]A BRS G 180D`

### <mark style="color:red;">Token</mark>

* Token price → `[ETH]C [AAVE]A P G 180D`, `[ETH]C [COMP]A P G 180D`

{% hint style="success" %}
You can now answer these questions by looking at the charts described above:

* How does the trend of AAVE and Compound active users compare?
* Does any of the protocols stop drawing users? To which version?
* Are there any anomalies in the key activity metrics?
* What is the general risk exposure/risk profile of users in both platforms?
* How popular are flashloans?
* Any difference in USDC pools across the two platforms?
* Is there any difference/trend in AAVE vs Compound value locked?
* Are the borrowing rates comparable?
* Any relation between price movements and any of the operational metrics?
  {% endhint %}

***

## Resources

Decentralised finance (DeFi) has revolutionised the traditional lending landscape, establishing AAVE and Compound as frontrunners in this transformative space. The lending and borrowing of tokens have become pivotal in the realm of finance, providing users with opportunities to earn yields, effectively open short positions, arbitrage, and more. In this exploration, we delve into the distinctions between these two decentralised lending protocols.

### AAVE

AAVE, originally known as ETHLend, was launched in 2017. Ever since, it has been a mainstay in decentralised lending, introducing innovative features like ‘flash loans’ to allow users greater flexibility in managing their assets. The protocol enables users to deposit assets and borrow against them within a user-friendly and permissionless environment.

### Compound

Compound operates as an algorithmic interest-rate protocol, allowing users to earn interest on deposited assets and borrow based on the collateral provided. Compound v3, also known as Compound III, removes the concept of lending liquidity pools completely.

### Key Differences

#### AAVE

* Allows users to choose between fixed and variable interest rates
* Unique feature in flash loans, enabling users to borrow without collateral, provided the borrowed amount is returned within the same transaction
* Liquidation works like a bounty, with liquidation bonus to users willing to repay the underwater debt

#### Compound

* Simple interest rate model, transparent governance
* Compound III has a single contract that acts as an universal pool: the Vault, letting pool management to be done via individual ‘logic’ contracts
* Liquidation moves collateral to protocol account and pays the liquidated debt using protocol’s reserves
