-
Notifications
You must be signed in to change notification settings - Fork 208
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
7400 governance docs #7402
Merged
Merged
7400 governance docs #7402
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
5a12bc0
docs: rename governance.md
turadg 6651d84
docs: update governance info
turadg 3f3c7c6
chore(auction): remove unused export
turadg c36e03d
fixup! docs: update governance info
turadg 7ff0cf2
Merge branch 'master' into 7400-governance-docs
mergify[bot] File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
# Inter Protocol Governance | ||
|
||
Inter Protocol is subject to two forms of governance. Like the entire chain, it's subject to BLDer DAO governance. This is sometimes called the "big hammer" because the DAO can approve running any code in the core ("core eval"). | ||
|
||
There is also governance by an configurable electorate using a contract governor (see `@agoric/governance`). The _governor_ contract allows the electorate to execute governed API methods or set governed parameters of the _governed_ contract. In the conventional configuration of the Inter Protocol contracts there is electorate, which is called the "Economic Committee". | ||
|
||
The *Economic Committee* (EC) can enact proposals through contracts governed by their charter. A contract is put under EC governance by adding its governance facet to the EC charter creatorFacet. At the time of writing, governed contracts include: | ||
|
||
- [auctioneer](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/proposals/committee-proposal.js#L100-L102) | ||
- [price feed](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/proposals/price-feed-proposal.js#L219-L224) | ||
- [psm](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/proposals/startPSM.js#L189-L193) | ||
- [reserve](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/proposals/committee-proposal.js#L89-L94) | ||
- [smartWallet provisionPool](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/vats/src/core/startWalletFactory.js#L248-L253) | ||
- [vault factory](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/proposals/committee-proposal.js#L95-L97) | ||
|
||
|
||
## API Methods | ||
|
||
The Zoe contract framework allows contracts to set filters on what offers they accept, by matching a string in the offer description. The governed contracts above grant to EC the ability to pause the creation of offers by calling `setOfferFilter` to set a list of strings. (Offers are blocked when their 'descriptions are an exact match or a prefix match to one of the strings in the list. Other criteria are not yet supported](https://github.com/Agoric/agoric-sdk/issues/7317).) | ||
|
||
Specific contracts also grant to the EC permission to invoke other API methods: | ||
- Oracle / Price feed / fluxAggregator | ||
-- [addOracles](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/price/fluxAggregatorContract.js#L113-L121) | ||
-- [removeOracles]https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/price/fluxAggregatorContract.js#L123-L131 | ||
- reserve | ||
-- [burnFeesToReduceShortfall](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/reserve/assetReserve.js#L281) | ||
|
||
## Parameters | ||
|
||
This sections documents the Governance-controlled parameters of the major Inter Protocol contracts. | ||
|
||
Below, for each contract you will find the governance keys for the various parameters, | ||
the type of each parameter, and an indicator of whether that parameter is described in | ||
the Inter Protocol Whitepaper, v0.8. | ||
|
||
### Vault Factory - Director | ||
([source](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/vaultFactory/params.js#L35-L39)) | ||
|
||
| Governance Key | Type | WP? | | ||
| ------------------ | :---------------- | --- | | ||
| MinInitialDebt | Amount | | | ||
| EndorsedUi | String | No | | ||
| ChargingPeriod | RelativeTime | | | ||
| RecordingPeriod | RelativeTime | | | ||
|
||
|
||
### Vault Manager | ||
|
||
([source](https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/vaultFactory/params.js#L96-L101)) | ||
|
||
| Governance Key | Type | WP? | | ||
| ------------------ | :---------------- | --- | | ||
| DebtLimit | Amount | Yes | | ||
| InterestRate | Ratio | Yes | | ||
| LiquidationPadding | Ratio | | | ||
| LiquidationMargin | Ratio | Yes | | ||
| LiquidationPenalty | Ratio | Yes | | ||
| LoanFee | Ratio | Yes | | ||
|
||
From Inter Protocol Whitepaper, v0.8: | ||
>Governance determines the approved collateral types: the crypto assets that can be used as collateral in vaults. In addition, it sets and manages the parameters associated with each collateral type based on the risk of the asset. These include the total debt limit, the collateralization ratio, the stability fee, and the liquidation penalty. | ||
|
||
Note that the "stability fee" described in the Whitepaper comprises both InterestRate and LoanFee. | ||
|
||
### stakeFactory (unreleased) | ||
|
||
In `packages/inter-protocol/src/stakeFactory/stakeFactory.js`: | ||
|
||
| Governance Key | Type | WP? | | ||
| ------------------ | :------------------ | --- | | ||
| DebtLimit | Amount | Yes | | ||
| InterestRate | Ratio | Yes | | ||
| LoanFee | Ratio | Yes | | ||
| MintingRatio | Ratio | Yes | | ||
|
||
From Inter Protocol Whitepaper, v0.8: | ||
>Governance through the BLDer DAO determines the parameters for stakeFactory. These include the total debt limit, the minting limit per account, and minting fees and interest rates. | ||
|
||
### Parity Stability Mechanism (PSM) | ||
|
||
In `packages/inter-protocol/src/psm/psm.js`: | ||
|
||
| Governance Key | Type | WP? | | ||
| ------------------ | :------------------ | --- | | ||
| WantMintedFee | Ratio | N/A | | ||
| GiveMintedFee | Ratio | N/A | | ||
| MintLimit | Amount | N/A | | ||
|
||
The Inter Protocol Whitepaper v0.8 does not describe the governance parameters | ||
for this contract. | ||
|
||
### Provision Pool | ||
|
||
In `packages/vats/src/provisionPool.js`: | ||
|
||
| Governance Key | Type | WP? | | ||
| ----------------------- | :------ | --- | | ||
| PerAccountInitialAmount | Amount | N/A | | ||
|
||
### Auctioneer | ||
|
||
([source]( | ||
https://github.com/Agoric/agoric-sdk/blob/5cbc847618dfb22f80e4641e5221b80e6daa109a/packages/inter-protocol/src/auction/params.js#L58-L68))) | ||
|
||
| Governance Key | Type | WP? | | ||
| ------------------------- | :------------ | --- | | ||
| StartFrequency | RelativeTime | N/A | | ||
| ClockStep | RelativeTime | N/A | | ||
| StartingRate | BasisPoints | N/A | | ||
| LowestRate | BasisPoints | N/A | | ||
| DiscountStep | BasisPoints | N/A | | ||
| AuctionStartDelay | RelativeTime | N/A | | ||
| PriceLockPeriod | RelativeTime | N/A | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we're laying an interpretation NatValue here, should we do likewise for ChargingPeriod, RecordingPeriod above? Those are relative times in seconds, yes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch, thanks