description |
---|
An implementation of an Optimistic Approval mechanism |
Through an additional mechanism, end users of the protocol - GYD stablecoin holders - have power over governance regarding how upgradeable the protocol should be. This takes the form of an alternative 'wrapped' form of GYD, boundedGYD.
As implemented in WrappedERC20WithEMA
, at any time, a user can choose between holding GYD or the wrapped bGYD and can freely convert between them. Choosing to hold bGYD means voting for limited protocol upgradeability.
When a user converts between GYD and bGYD, a moving average is updated in the bGYD contract. When the moving average exceeds a threshold in addition to the total bGYD supply exceeding another threshold, upgradeability of core Gyroscope contracts through governance becomes more difficult. This takes the form of increased difficulty in action tiering.
The main idea is to let the end-user decide when the system should be more upgradeable and when core infrastructure should be considered more settled based on the market choice of whether to adopt GYD or bGYD. This change of adoption is intentionally difficult (e.g., integrations would have to shift to using bGYD) because early on the DeFi space itself is not settled and any stablecoin will likely need to adapt parameters and structure over time as DeFi itself changes.
Tracking the Moving Average
We track the moving average of the share of bGYD to GYD in terms of an irregularly-spaced exponential moving average (EMA) as follows. Index the points in time where the EMA is updated by
Here,
Note that we only track the EMA at the previously updated block, not the current block. This is to prevent manipulation of the EMA by, e.g., using a flash loan. The values
The variables in _updateEMA()
match the variables from the formulas above as follows:
Math | Code |
---|---|
y_{i-1} | expMovingAverage.value |
x_i | previousWrappedPctOfSupply.value |
t_{i-1} | expMovingAverage.blockNb |
t_i | previousWrappedPctOfSupply.blockNb |
\tau | windowWidth |
Limiting upgradeability in this way is an application of the idea of Optimistic Approval, a new governance primitive that allows governance changes to be conditional on a timelock and veto process. It is a very flexible mechanism that can be used both to streamline governance processes and to better align incentives among protocol participants, not just in Gyroscope but also in DeFi governance more broadly.
Read our research piece introducing Optimistic Approval here.
Optimistic Approval can help to align incentives among different types of parties: one who possesses governance powers (governors), and another (guardians) who has the power to optionally veto during a timelock period. Ordinarily, guardians do not need to be involved in day-to-day governance, but the veto gives them the ability to block malicious proposals that would deviate from the vision of the protocol.
The Optimistic Approval framework generalizes who has governing powers and who has veto rights during a time delay. Additionally, the mechanism is parameterized by (1) initial timelock duration, (2) guardian voting threshold for increasing timelock duration, and (3) guardian voting threshold for achieving veto.
In this first application to Gyroscope in the form of limiting upgradeability, Optimistic Approval is designed to give protocol users a veto power to stop governance changes that they disagree with. In this case, protocol users fulfil the guardian role of stewarding the protocol vision (e.g., of maintaining stability). The mechanism introduces checks and balances on governors' power. Should governors try to deviate from the shared vision of the protocol, Gyro Dollar holders will be able to exercise optional veto powers during the time delay to stop it. Ordinarily, Gyro Dollar holders will not need to do anything if governance actions are sound. However, if governance actions are contentious, Gyro Dollar holders can exercise the veto to block the action.
{% hint style="info" %} Optimistic Approval was initially devised this application as a means to circumvent an impossibility conjecture around secure decentralized governance arising from the models in our Stablecoins 2.0 paper (Conjecture 1). {% endhint %}