Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fip0081 gradual activation #967

Merged
merged 24 commits into from
Aug 15, 2024
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
97145dd
adding gradual activation version
kkarrancsu Feb 8, 2024
e60d3a5
adding additional description
kkarrancsu Feb 8, 2024
6143ac0
changed default time
kkarrancsu Feb 8, 2024
cb3c106
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu Mar 18, 2024
19e554b
Updated ramp len to 1Y
kkarrancsu Mar 18, 2024
1f86315
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu Mar 19, 2024
3351511
remove hard activation date and replace with variable noting intended…
kkarrancsu Mar 20, 2024
1122938
added qualitative description of activation period
kkarrancsu Mar 21, 2024
2f3cd55
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu Apr 16, 2024
d6c0537
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu May 7, 2024
3f1633c
updated description of ramped activation
kkarrancsu May 7, 2024
a46bb73
updated diagram to be clearer
kkarrancsu May 7, 2024
89008d8
added motivation for ramped activation and PDF of economic considerat…
kkarrancsu May 7, 2024
89330e2
fixed link to resources
kkarrancsu May 7, 2024
855600b
updating broken pdf
kkarrancsu May 8, 2024
1847de3
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu Jul 2, 2024
8cd672e
adding link to draft implementation
kkarrancsu Jul 2, 2024
59b42dc
added description of changes updates to builtin-actors in FIP document
kkarrancsu Jul 23, 2024
1a6c5e3
updated doc per additional feedback
kkarrancsu Jul 26, 2024
d535cff
adding state migration information
kkarrancsu Aug 6, 2024
582df4b
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu Aug 6, 2024
35cd354
Merge branch 'filecoin-project:master' into fip0081_gradual_activation
kkarrancsu Aug 13, 2024
af81dbe
Update fip-0081.md
kkarrancsu Aug 13, 2024
23c2568
Update fip-0081.md
kkarrancsu Aug 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 50 additions & 9 deletions FIPS/fip-0081.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,27 +77,72 @@ but an undesirable property of tending network collateral to zero as the baselin
This proposal aims to maintain the desirable property of exponential pledge decrease but introduces
a reasonable lower bound on network collateral.


## Specification
Factor the per-sector initial consensus pledge into two parts: a 70% share which divides by the baseline function like today,
and a smaller 30% "simple" share which does not divide by the baseline function.
Factor the `SectorInitialConsensusPledge` pledge into two parts, the `SimpleConsensusPledge` and the `BaselineConsensusPledge`, defined as follows:

```
BaselineConsensusPledge = PledgeLockTarget * SectorQAP / max(NetworkBaseline, NetworkQAP)
SimpleConsensusPledge = PledgeLockTarget * SectorQAP / max(NetworkBaseline)
jsoares marked this conversation as resolved.
Show resolved Hide resolved

PledgeLockTarget = 0.3 * CirculatingSupply
```

A convex combination of `SimpleConsensusPledge` and `BaselineConsensusPledge` is now the `SectorInitialConsensusPledge`, with a parameter `gamma` which controls the contribution of each component of pledge to the overall `SectorInitialConsensusPledge`. The new definition is:

```
SectorInitialConsensusPledge = PledgeLockTarget * (0.3 * SectorSimpleShare + 0.7 * SectorBaselineShare)
SectorInitialConsensusPledge = (1-gamma)*SimpleConsensusPledge + gamma*BaselineConsensusPledge
```

To achieve a ramped activation, vary the gamma parameter linearly from 1.0 at the date of activation to 0.7, on the date when the ramped activation will be completed.

![ramped_activation_gamma.png](../resources/fip-0081/ramped_activation_gamma.png)

<!-- Factor the per-sector initial consensus pledge into two parts: a 70% share which divides by the baseline function like today,
and a smaller 30% "simple" share which does not divide by the baseline function. Gradually activate the change from the current
to the target over the activation period - the time window over which the gamma value is varied, by adding a new parameter, gamma, which varies from the initial value of 1.0 at the start of the activation decreases linearly to a value of 0.7 at the end of the ramped activation period.

```
FIP_activation_date = # TBD
activation_len_days = int(365)
current_day = 0
update_day = (FIP_activation_date - datetime.today()).days
state = "before_activation"
while True:
if state == "before_activation":
gamma_day = 1
if current_day >= update_day:
state = "ramping"
elif state == "ramping":
gamma_day -= 0.3/(activation_len_days-1)
if current_day >= (update_day + activation_len_days - 1):
state = "after_ramping"
elif state == "after_ramping":
gamma_day = 0.7
SectorInitialConsensusPledge_day = PledgeLockTarget * ( ((1-gamma_day)*SectorSimpleShare) + (gamma_day*SectorBaselineShare) )
current_day += 1

SectorSimpleShare = SectorQAP / NetworkQAP
SectorBaselineShare = SectorQAP / max(NetworkBaseline, NetworkQAP)
PledgeLockTarget = 0.3 * CirculatingSupply
```
``` -->

Note that the implemented calculation should be re-arranged to defer division until the final operations,
to avoid loss of precision in rounding.

The practical effect of this is that the sector initial pledge calculation will not tend to zero
as the network baseline grows,
but toward the SectorSimpleShare (30% of the pre-baseline-crossing total).
but toward the `SectorInitialConsensusPledge` (30% of the pre-baseline-crossing total).
When/if the baseline function exceeds network QAP, the per-sector initial pledge value will still decrease exponentially,
but to this floor rather than toward zero.

### Motivation for Ramped Activation
The proposed update for `SectorInitialConsensusPledge` requires setting the gamma parameter to 0.7, which results in 70% of the `SectorInitialConsensusPledge` coming from `BaselineConsensusPledge`, and 30% coming from `SimpleConsensusPledge`.

Under the updated formula for `SectorInitialConsensusPledge`, the network's current setting is `gamma=1.0`, which results in all of the `SectorInitialConsensusPledge` coming from `BaselineConsensusPledge`.

We recommend updating gamma from its current value of 1.0 to the target value of 0.7 over an period of 1Y. The technical reason for this recommendation is that gamma has a direct effect on pledge - changing this gradually will prevent pledge from sharply increasing, which will negatively affect SPs. There are additional economic considerations which support this recommendation and are discussed [here](../resources/fip-0081/gradual_activation_rationale.pdf).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No "we recommend" in a FIP. Just clearly define what the specification is. The fact that the FIP authors recommend it is implied.


## Design Rationale

The baseline function primarily exists to mediate the minting of rewards.
Expand Down Expand Up @@ -236,9 +281,5 @@ so the supply of storage is more than adequate to demand.

To be provided.

## TODO

- Implementation
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is still TODO. The description of intent is clear enough, but this currently lacks specification of how to achieve it.


## Copyright
Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).
Binary file not shown.
Binary file added resources/fip-0081/ramped_activation_gamma.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.