-
Notifications
You must be signed in to change notification settings - Fork 1k
Description
The MASP reward design computes rate changes using absolute units instead of relative units, making consistency in calibration difficult. All things being equal, assets with larger unit targets have disproportionately higher rate change behaviours than small unit assets. This introduces a complexity that is difficult to account for using PD controller parameters Kp and Kd alone. We would like the computation to use percentage-based ratios instead.
https://github.com/namada-net/namada/blob/main/crates/controller/src/lib.rs#L122C1-L133C6
fn compute_control(
&self,
coeff: Dec,
current_metric: Dec,
) -> Result<Dec, arith::Error> {
let val: Dec = checked!(
current_metric * (self.d_gain_nom - self.p_gain_nom)
+ (self.target_metric * self.p_gain_nom)
- (self.last_metric * self.d_gain_nom)
)?;
checked!(coeff * val)
}https://github.com/namada-net/namada/blob/main/crates/shielded_token/src/conversion.rs#L216C1-L357C2 also appears to be using absolute values.
Percentage-based ratios would make stewarding MASP reward rates less complicated and more predictable.