When do we interact with Yield Farms?

Certain vault actions will trigger the vault to either deposit or withdraw to/from the yield farms.


Calling the rebalance function will result in the protocol either depositing in or withdrawing from the Yield Farm. If we are actively farming, then the loan-to-value ratio with the lender will be close to the vault target threshold after the rebalance has completed.

Out-of-buffer user actions

Whenever a user either borrows, withdraws or claims rewards, the vault checks (in addition to user position checks) if the vault will be borrowing more than the vault target active asset amount after the user action. At this point the vault will aim to get back to its target borrow amount by withdrawing from the Yield Farms and repaying part of its outstanding debt.

As interactions with the Yield Farms tend to be associated with high gas costs we have a buffer to shield users from these gas costs. Therefore, only actions that can’t be supported from this buffer will interact directly with the external Yield Farm(s)


In addition to the above, there are a few areas such as migrations from one Yield Farm to another, withdrawing from the reserve and managing potential losses where we will also interact with the Yield Farms.

Last updated