> For the complete documentation index, see [llms.txt](https://onchaintrade.gitbook.io/ot/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://onchaintrade.gitbook.io/ot/spot-and-borrow/borrow/interest-rate-model.md).

# Interest Rate Model

### OT Interest model is 2-slop based mechanism

* ~~Minting and borrowing OSD using select collateral comes with a 0.5% fee based on borrowing amount. Fee is paid up when CDP is partially or fully closed.~~
* Interest rate of minting and borrowing OSD using select collaterals is quoted from oracles or third party lending/borrowing market such as AAVE or Compound.
* Interest rate of borrowing non-OSD assets will be based on a 2 part slope formula as following:

> The interest rate$$R\_t$$follows the model:
>
> $$if \hspace{1mm} U < U\_{optimal}:  \hspace{1cm}  R\_t = R\_0 + \frac{U\_t}{U\_{optimal}} R\_{slope1}$$  &#x20;
>
> $$if \hspace{1mm} U \geq  U\_{optimal}:  \hspace{1cm} R\_t = R\_0 + R\_{slope1} + \frac{U\_t-U\_{optimal}}{1-U\_{optimal}}R\_{slope2}$$

```javascript
const otBorrowRate = function (r0, u, uOptimal, slop1, slop2) {
  let rate;
  if (u < uOptimal) {
    rate = r0 + (u / uOptimal) * slop1;
  } else {
    rate = r0 + slop1 + ((u - uOptimal) / (1 - uOptimal)) * slop2;
  }
  return rate;
};

const main = function () {
  const assetConfigArray = [
    [[0.8, 0, 0.04, 1], 0.02, "USDC"],
    [[0.8, 0, 0.04, 1], 0.85, "USDC"],
    [[0.65, 0, 0.08, 1], 0.02, "ETH"],
    [[0.65, 0, 0.08, 1], 0.7, "ETH"],
  ];
  for (const assetConfig of assetConfigArray) {
    const [config, u, asset] = assetConfig;
    const [uOptimal, r0, slop1, slop2] = config;
    console.log(
      asset,
      `on Utilization Rate = ${u} Interest Rate is ${otBorrowRate(r0, u, uOptimal, slop1, slop2)}`
    );
  }
};

main();
```

<figure><img src="/files/WUOibxJukKSNVYAsp0Ok" alt=""><figcaption></figcaption></figure>

### Variable Interest Rate Model Parameters

<table data-header-hidden><thead><tr><th width="150">Asset</th><th width="150" align="center"> </th><th width="150" align="center">Base</th><th width="150" align="center">Slope 1</th><th align="center">Slope 2</th></tr></thead><tbody><tr><td>Asset</td><td align="center"> <span class="math">U_{optimal} </span></td><td align="center">Base</td><td align="center">Slope 1</td><td align="center">Slope 2</td></tr><tr><td>BUSD</td><td align="center">80%</td><td align="center">0%</td><td align="center">4%</td><td align="center">100%</td></tr><tr><td>USDC</td><td align="center">90%</td><td align="center">0%</td><td align="center">4%</td><td align="center">60%</td></tr><tr><td>DAI</td><td align="center">80%</td><td align="center">0%</td><td align="center">4%</td><td align="center">75%</td></tr><tr><td>USDT</td><td align="center">90%</td><td align="center">0%</td><td align="center">4%</td><td align="center">60%</td></tr><tr><td>OSD</td><td align="center"></td><td align="center"></td><td align="center"></td><td align="center"></td></tr><tr><td>ETH</td><td align="center">65%</td><td align="center">0%</td><td align="center">8%</td><td align="center">100%</td></tr><tr><td>WBTC</td><td align="center">65%</td><td align="center">0%</td><td align="center">7%</td><td align="center">100%</td></tr><tr><td>LINK</td><td align="center">45%</td><td align="center">0%</td><td align="center">7%</td><td align="center">300%</td></tr></tbody></table>

### Stable Interest Rate Model Parameters

The stable rate provides predictability for the borrower which comes at a cost, as the interest rates are higher than the variable rate. However the rate of a stable loan is fixed until the rebalancing conditions are met:

1. Utilisation Rate: $$U\_t > 95%$$&#x20;
2. Overall Borrow Rate, the weighed average of all the borrow rates: $$R\_O < 25%$$&#x20;

The currencies the most exposed to liquidity risk do not offer stable rate borrowing.

The base rate of the stable rate model corresponds to the average market rate of the asset.

<table data-header-hidden><thead><tr><th width="150">Asset</th><th width="150" align="center"> </th><th width="150" align="center">Base</th><th width="150" align="center">Slope 1</th><th align="center">Slope 2</th></tr></thead><tbody><tr><td>Asset</td><td align="center"> <span class="math">U_{optimal} </span></td><td align="center">Base</td><td align="center">Slope 1</td><td align="center">Slope 2</td></tr><tr><td>BUSD</td><td align="center">80%</td><td align="center">4%</td><td align="center">2%</td><td align="center">60%</td></tr><tr><td>DAI</td><td align="center">80%</td><td align="center">4%</td><td align="center">2%</td><td align="center">75%</td></tr><tr><td>USDC</td><td align="center">90%</td><td align="center">4%</td><td align="center">2%</td><td align="center">60%</td></tr><tr><td>USDT</td><td align="center">90%</td><td align="center">3.5%</td><td align="center">2%</td><td align="center">60%</td></tr><tr><td>OSD</td><td align="center"></td><td align="center">4%</td><td align="center"></td><td align="center"></td></tr><tr><td>ETH</td><td align="center">65%</td><td align="center">3%</td><td align="center">10%</td><td align="center">100%</td></tr><tr><td>WBTC</td><td align="center">65%</td><td align="center">3%</td><td align="center">10%</td><td align="center">60%</td></tr><tr><td>LINK</td><td align="center">45%</td><td align="center">3%</td><td align="center">10%</td><td align="center">300%</td></tr></tbody></table>

## Interest Rate Parameters Change

When market conditions change, risks change. The utilization of reserves is continuously monitored to check liquidity is available. In case of prolonged full utilization, the interest rate parameters are adapted to mitigate any risks emerging from market conditions


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://onchaintrade.gitbook.io/ot/spot-and-borrow/borrow/interest-rate-model.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
