> ## Documentation Index
> Fetch the complete documentation index at: https://artemis.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Morpho

> Morpho Schema Description and Methodology

This schema contains comprehensive datasets for tracking Morpho fundamental data across multiple metrics categories, including lending activity, deposits, loans, fees, token economics, and market data.

## Available Tables

Morpho data is available in two main tables:

* **ez\_metrics**: Main aggregated metrics for the entire Morpho protocol
* **ez\_metrics\_by\_chain**: Metrics broken down by blockchain

## Table Schema

### Lending Activity Metrics

| Table Name  | Column Name         | Description                                |
| ----------- | ------------------- | ------------------------------------------ |
| ez\_metrics | lending\_dau        | The number of daily active users on Morpho |
| ez\_metrics | lending\_txns       | The number of daily transactions on Morpho |
| ez\_metrics | daily\_borrows\_usd | The USD value of daily borrows             |
| ez\_metrics | daily\_supply\_usd  | The USD value of daily supply              |
| ez\_metrics | dau                 | Legacy naming for lending\_dau             |
| ez\_metrics | txns                | Legacy naming for lending\_txns            |

### Deposits and Loans Metrics

| Table Name  | Column Name              | Description                                         |
| ----------- | ------------------------ | --------------------------------------------------- |
| ez\_metrics | lending\_deposits        | The total amount of tokens deposited (in USD)       |
| ez\_metrics | lending\_loans           | The total outstanding loans (in USD)                |
| ez\_metrics | lending\_loan\_capacity  | The total amount of loans available (in USD)        |
| ez\_metrics | tvl                      | The total value locked in Morpho (deposits - loans) |
| ez\_metrics | deposits                 | Legacy naming for lending\_deposits                 |
| ez\_metrics | borrows                  | Legacy naming for lending\_loans                    |
| ez\_metrics | supplies                 | Legacy naming for lending\_loan\_capacity           |
| ez\_metrics | total\_available\_supply | Legacy naming for lending\_loan\_capacity           |

### Fee and Revenue Metrics

| Table Name  | Column Name             | Description                                             |
| ----------- | ----------------------- | ------------------------------------------------------- |
| ez\_metrics | lending\_interest\_fees | The total amount of interest fees generated on Morpho   |
| ez\_metrics | fees                    | The total value generated by the protocol from all fees |
| ez\_metrics | fees                    | Legacy naming for lending\_interest\_fees               |
| ez\_metrics | fees\_cumulative        | The cumulative sum of fees over time                    |

### Token Supply Metrics

| Table Name  | Column Name                 | Description                                        |
| ----------- | --------------------------- | -------------------------------------------------- |
| ez\_metrics | circulating\_supply\_native | The circulating supply of MORPHO in native tokens  |
| ez\_metrics | net\_supply\_change\_native | The net change in the circulating supply of MORPHO |
| ez\_metrics | premine\_unlocks\_native    | The amount of native tokens unlocked from premine  |

### Market and Token Metrics

| Table Name  | Column Name                  | Description                                             |
| ----------- | ---------------------------- | ------------------------------------------------------- |
| ez\_metrics | price                        | The price of MORPHO token in USD                        |
| ez\_metrics | market\_cap                  | The market cap of MORPHO token in USD                   |
| ez\_metrics | fdmc                         | The fully diluted market cap of MORPHO token in USD     |
| ez\_metrics | token\_volume                | The trading volume of MORPHO token in USD               |
| ez\_metrics | token\_turnover\_circulating | The turnover of MORPHO based on circulating supply      |
| ez\_metrics | token\_turnover\_fdv         | The turnover of MORPHO based on fully diluted valuation |

### Metrics by Chain

The `ez_metrics_by_chain` table provides a breakdown of Morpho's performance across different blockchains. It includes the following columns:

| Table Name             | Column Name              | Description                                  |
| ---------------------- | ------------------------ | -------------------------------------------- |
| ez\_metrics\_by\_chain | date                     | The date of the recorded metrics             |
| ez\_metrics\_by\_chain | chain                    | The specific blockchain (Ethereum, etc.)     |
| ez\_metrics\_by\_chain | dau                      | Daily active users on this chain             |
| ez\_metrics\_by\_chain | txns                     | Number of transactions on this chain         |
| ez\_metrics\_by\_chain | daily\_borrows\_usd      | The USD value of daily borrows on this chain |
| ez\_metrics\_by\_chain | daily\_supply\_usd       | The USD value of daily supply on this chain  |
| ez\_metrics\_by\_chain | total\_available\_supply | Available loan capacity on this chain        |
| ez\_metrics\_by\_chain | fees                     | Interest fees generated on this chain        |
| ez\_metrics\_by\_chain | lending\_loans           | Outstanding loans on this chain              |
| ez\_metrics\_by\_chain | lending\_loan\_capacity  | Loan capacity on this chain                  |
| ez\_metrics\_by\_chain | lending\_deposits        | Total deposits on this chain                 |
| ez\_metrics\_by\_chain | tvl                      | Total value locked on this chain             |
| ez\_metrics\_by\_chain | lending\_interest\_fees  | Interest fees on this chain                  |
| ez\_metrics\_by\_chain | fees                     | Protocol revenue on this chain               |

## Sample Queries

### Basic Protocol Activity Query

```sql theme={null}
-- Pull fundamental activity data for the Morpho protocol
SELECT
    date,
    lending_dau,
    lending_txns,
    lending_deposits,
    lending_loans,
    tvl,
    price
FROM
    art_share.morpho.ez_metrics
WHERE
    date >= DATEADD(month, -3, CURRENT_DATE())
ORDER BY
    date ASC
```

### Lending Metrics Analysis

```sql theme={null}
-- Analyze Morpho lending metrics
SELECT
    date,
    lending_deposits,
    lending_loans,
    lending_loan_capacity,
    lending_loans / lending_loan_capacity * 100 as utilization_rate,
    tvl
FROM
    art_share.morpho.ez_metrics
WHERE
    date >= DATEADD(month, -3, CURRENT_DATE())
ORDER BY
    date ASC
```

### Revenue Analysis

```sql theme={null}
-- Analyze Morpho revenue and interest fees
SELECT
    date,
    lending_interest_fees as daily_fees,
    SUM(lending_interest_fees) OVER (ORDER BY date ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) as cumulative_fees,
    fees,
    lending_deposits,
    lending_interest_fees / lending_deposits * 365 * 100 as annualized_yield_percentage
FROM
    art_share.morpho.ez_metrics
WHERE
    date >= DATEADD(month, -3, CURRENT_DATE())
ORDER BY
    date ASC
```

### Token Economics Analysis

```sql theme={null}
-- Track MORPHO token metrics
SELECT
    date,
    price,
    market_cap,
    fdmc,
    circulating_supply_native,
    net_supply_change_native,
    premine_unlocks_native
FROM
    art_share.morpho.ez_metrics
WHERE
    date >= DATEADD(month, -3, CURRENT_DATE())
ORDER BY
    date ASC
```

### Cross-Chain Comparison

```sql theme={null}
-- Compare Morpho metrics across different blockchains
SELECT
    date,
    chain,
    lending_deposits,
    lending_loans,
    tvl,
    fees
FROM
    art_share.morpho.ez_metrics_by_chain
WHERE
    date >= DATEADD(month, -1, CURRENT_DATE())
ORDER BY
    chain, date ASC
```

### User Activity and Growth Analysis

```sql theme={null}
-- Track Morpho user growth and activity
SELECT
    date,
    lending_dau,
    lending_txns,
    lending_txns / lending_dau as avg_txns_per_user,
    daily_borrows_usd,
    daily_supply_usd
FROM
    art_share.morpho.ez_metrics
WHERE
    date >= DATEADD(month, -6, CURRENT_DATE())
ORDER BY
    date ASC
```

### Protocol Economics Analysis

```sql theme={null}
-- Analyze Morpho protocol economics
SELECT
    date,
    lending_deposits,
    lending_loans,
    tvl,
    lending_interest_fees,
    lending_interest_fees / lending_loans * 365 * 100 as annualized_borrowing_rate,
    price,
    token_volume
FROM
    art_share.morpho.ez_metrics
WHERE
    date >= DATEADD(month, -3, CURRENT_DATE())
ORDER BY
    date ASC
```
