Epochs
Epochs System
The epoch system provides orderly batch processing of vault operations. Each epoch represents a discrete management period where deposits and redemptions are processed together.
Epoch Timeline
Epoch N-2: Performance realized, redemptions claimable
Epoch N-1: Deposits processed, redemptions queued
Epoch N: Current epoch, accepting deposits/redemptionsState Transitions
When roll_epoch is called:
Epoch Counter
Increments by 1
Triggers state updates
Deposit Processing
epoch_depositswithdrawn by adminAdded to
managedassetsReset to 0 for new epoch
Redemption Processing
prev_epoch_redemptionsbecome claimableepoch_redemptionsmove toprev_epoch_redemptionsNew redemptions start at 0
Performance Application
Applied to epoch N-2 positions
Updates
managedassetsAffects exchange rate
Exchange Rate Stability
The exchange rate remains constant during an epoch. This ensures:
Fair treatment of all users
Predictable deposit amounts
Known redemption values
Exchange rate only updates when:
Performance is reported
Epoch rolls over
Redemption Delay
The 2-epoch delay for redemptions provides:
Time for strategy unwinding
Batch processing efficiency
Liquidity management
Timeline for redemption:
Epoch N: User redeems
Epoch N+1: Admin processes
Epoch N+2: User claims
Admin Operations
Admins can perform operations during an epoch:
process_deposits: Withdraw accumulated depositsprocess_redemptions: Deposit underlying for claimsroll_epoch: Advance to next epoch
These operations can happen multiple times per epoch or batched at epoch end.
Last updated