The AAH protocol enables users to earn rewards through staking in either a flexible (sAAH) or fixed-term (veAAH) manner.
- sAAH: Flexible staking with no lock-in period, allowing for free transferability and staking rewards, but excludes voting rights.
- veAAH: Achieved through staking sAAH with varying lock-in durations, where the length of the term determines both voting weight and interest rate, but these tokens are non-transferable.
Due to the inability of smart contracts to execute timed operations, a settling period is required when fixed-term stakes expire to cease distributing rewards to users. However, in Solidity, executing loops consumes significant gas and excessive iterations can exceed limits. Hence, performing this in the Aspect not only speeds up the process but also reduces costs. Therefore, a part of the Curve boost function contract rewritten in Solidity has been re-implemented in Aspect for efficiency.