DELTA

Delta (Delta.sol) is an ERC4626 vault extending OpenZeppelin's standard.

Delta.sol

Rewards and Vesting

As the Delta strategy accrues profits, rewards are sent to the Delta smart contract in the form of thUSD using the sendRewards method.

This method can only be called by users with the REWARDER_ROLE, which is reserved for the strategy operator (in this case, the core Theo team).

Rewards sent to Delta are subject to a vesting period of duration REWARDS_VESTING_DURATION to prevent new depositors from "sniping" rewards. This parameter is initially set to one day.

Escrow

Delta implements an escrow (unstaking) mechanism of duration ESCROW_DURATION to allow the strategy operator to gracefully wind down positions. This parameter is initially set to 7 days.

The escrow mechanism functions as follows:

  1. First, the user unstakes with the beginEscrowAssets or beginEscrowShares method.

  2. The user's share of thUSD including any vested rewards is immediately transferred to the DeltaEscrow.sol contract for the duration of the escrow period. This is done to simplify vault accounting.

  3. Once the escrow period has elapsed, the user calls endEscrow on DELTA to claim their thUSD. Internally, this method calls unstake on DeltaEscrow transferring thUSD to the user.

DeltaEscrow.sol

Last updated