Vaults

At the heart of Olive Finance lies the concept of vaults. Each vault is intricately linked with a specific strategy contract, designed to auto-compound returns, and a dedicated lending pool for borrowing purposes.

Users have the flexibility to undertake the following actions within the vaults:

  • Deposit: Add assets to the vault.

  • Withdraw: Retrieve assets from the vault.

  • Manage Position: Adjust and optimise their leverage within the vault.

Users have the flexibility to deposit assets into a vault either with or without leverage.

Without Leverage: When depositing without leverage, the user's collateral is directly placed into the associated strategy contract for optimising and auto-compounding returns. In return, the vault issues 'oTokens' (representative of vault shares) to the user.

With Leverage: On choosing to deposit with leverage, the vault sources the necessary assets from its linked lending pool to mint new LP tokens. The vault then amalgamates the user's deposited collateral with these borrowed LP tokens, directing them into the strategy contract for auto-compounding. In this scenario, the user receives both 'oTokens' from the vault and 'dTokens' (indicative of debt) from the lending pool.

While 'oTokens' can be freely transferred provided the position's health factor remains above 1, 'dTokens' are inherently non-transferable.

'oTokens' accumulate yield based on the underlying vault tokens, whereas 'dTokens' gather interest based on the borrowing rate.

Users can set a permissible slippage tolerance when opting for leverage. If the actual slippage surpasses this set tolerance during the leverage process, the transaction will be halted. By default, the slippage tolerance for any transaction is capped at 0.5%.

Health Factor

The health factor (HF) of a user's position is computed as:

HF = Position Value x liquidation threshold / Debt Value

where

Position Value = Collateral + Debt

If the health factor dips below 1, any individual can initiate the liquidation of the user's position. Therefore, it's prudent to maintain a health factor well above this threshold. A health factor of 2 is generally recommended for safety.

Withdrawal Process

Without Debt: If a user holds no outstanding debt, they can simply redeem all of their 'oTokens' to retrieve their entire position value.

With Leverage: For users who have opted for leverage, partial withdrawals are possible by redeeming a portion of their 'oTokens'. The maximum number of 'oTokens' that can be redeemed is determined based on two conditions:

  1. After the withdrawal, the user's health factor must remain above 1.

  2. The position's leverage post-withdrawal should not exceed the vault's maximum allowable leverage.

Managing your Position

User can either increase or decrease the leverage. Increasing Leverage: When a user opts to increase their leverage, it's akin to taking on additional borrowing. This results in an expansion of the user's position size, increasing leveraged yield farming APY and a corresponding amount of 'dTokens' are minted for the user. This action leads to a decrease in the user's health factor.

Decreasing Leverage: Conversely, when a user chooses to decrease their leverage, it's equivalent to repaying a portion of their debt. This action reduces the user's position size, reducing leveraged yield farming APY and the necessary 'dTokens' are burned to reflect the debt repayment. This action leads to a increase in the the user's health factor.

Last updated