EIP-1234: Decentralized Autonomous Organizations (revision Feb. 4, 2022)
Remaining tasks:
UUID specification for proposals
Not sure we can guarantee all proposals will fit into this.
Writing
Structure / rewrite optional extensions
Use-cases - highlight discoverability/legibility, sensemaking, execution simulation
rationale / discussion for why and why not proposal object that exposes current discussion to core devs in EthMagicians.
In asking for an off-chain JSON schema, we did so because (1) it is still unclear what the use-cases are for standardizing an on-chain proposal object, (2) there was a sense in the community that , but that frameworks would be unlikely to adopt Because ( comes down to the lack of use-cases for a standard on-chain proposal object; “the frameworks are not going to adopt the standard if we force them to represent proposal on-chain”. By the time we submit, it’s basically just the call since all the proposal-specific actions might have been taken care of through off-chain signatures.
DAOs occupy a spectrum from on-chain to off-chain.
After today’s call, I think I don’t understand enough about the typical control flow of proposals in these DAOs, when things transition from off- to on-chain, to fully articulate the need & the use-cases for on-chain formalization of “proposals” as opposed to the base execution data.
We are fundamentally answering simple questions about what, who, how does it make decisions, what is it doing / what is its history.
Lucia: create + pop-in table for all the proposals states of the contracts collected
Lucia: create + pop-in a table for voting options
Add MUST, SHOULD, MAY language to clarify different fields of proposalsURI.
Zargham: The fact that the status field is free text may be a bit concerning, but the fact that the status types are coming from code is a bit easier.
Zargham: as a data scientist, I would want an index of types of status.
Possible status
Write up rationale for why no back link in daoURI.
Write Ethereum Magicians post: recommendation, DON’T BE SHY, BE BOLD, we want this NOW and exactly as it is, we don’t want to equivocate much. On proposal objects: this is out-of-scope.
Something to include in the EthMag rationale: learn from this standard before we project on-chain rigidity.
However, there is one use-case that we might want to focus on, e.g. on-chain signature/authorization of proposals, typically by other contracts.
Add “reporting standard” language.
Address in daoURI, choose one of:
Instead of “address”, should it be “@value”?
Include: more visible, very standard + intuitive, less dangerous than include as array
Include as array: explicitly support and name multiple contract addresses affiliated with the URI, makes sense given current contract architectures
Not include: parsimony, can be inferred from context, allow multiple contract addresses mapping to the same daoURI
Name decisions
constitutionURI vs. governanceURI
interactionsURI vs. activityLogURI
Isaac: moloch implementation
Members
Proposals (there are distinct proposal types)
Activity log
Implement JSON-LD context files and host them on daostar.org
Choice: daostar.org
Re-organize all these decisiosn so we can hit them more efficiently for next time.
Optional metadata stuff.
BY FEB. 4, PUBLISH TO ETHEREUM MAGICIANS
BY FEB. 15, SUBMIT EIP DRAFT
[Save for later, please.] Define userflows for how people will be able to publish extensions of the schema, e.g. via GitHub PRs.
Â
Simple Summary
Abstract
Motivation
Specification
Members
Proposals
Activity Log
Rationale
Membership
Proposals
Activity Log
Governance
Why JSON-LD
Community Consensus
Implementations
History [Planned]
References
Copyright
Cutting board & rationales
Simple Summary
Standardized interfaces and behaviors for decentralized autonomous organizations (DAOs).
Abstract
Standardized interfaces and behaviors for decentralized autonomous organizations (DAOs) and related contracts, focusing on relating on-chain and off-chain representations of membership and proposals.
Motivation
DAOs, since being invoked in [1, 2], have been vaguely defined. This has led to a wide range of patterns but little standardization or interoperability between the frameworks and tools that have emerged. Standardization and interoperability are necessary to support a range of emerging use-cases, including
- DAO discovery, e.g. via aggregators like Etherscan, DeepDAO, or Messari
- multi-DAO joint or conditional proposals,
- DAOs of DAOs,
- and other DAO-to-DAO interactions, e.g. Moloch DAOs using “minions” to operate a Gnosis Safe, or other forms of whole- or partial ownership.
Further, some level of standardization in the interfaces is useful for tooling developers that want to develop tools and modular extensions for the entire DAO ecosystem rather than for a single framework or DAO.
Specification
The key words “MUST”, “MUST NOT”, “REQUIRED”, “SHALL”, “SHALL NOT”, “SHOULD”, “SHOULD NOT”, “RECOMMENDED”, “MAY”, and “OPTIONAL” in this document are to be interpreted as described in RFC 2119.
Every ERC-1234 compliant contract MUST implement the ERC1234 interface below:
pragma solidity ^0.4.20;
/// @title ERC-1234 DAOs
/// @dev See https://eips.ethereum.org/EIPS/eip-1234
interface ERC1234 {
/// @notice A distinct Uniform Resource Identifier (URI) pointing to a JSON object following the "EIP-1234 DAO JSON-LD Schema". This JSON file splits into four separate URIs: membersURI, proposalsURI, interactionsURI, constitutionURI. The membersURI should point to a JSON file that conforms to the "ERC-1234 Members JSON-LD Schema". The proposalsURI should point to a JSON file that conforms to the "ERC-1234 Proposals JSON-LD Schema". The interactionsURI should point to a JSON file that conforms to the "ERC-1234 Interactions JSON-LD Schema". The constitutionURI should point to a flatfile, normatively a .md file. Each of the JSON files named above can be statically-hosted or dynamically-generated.
function daoURI() external view returns (string _daoURI);
}
The ERC-1234 DAO JSON-LD Schema mentioned above.
{
"@context": "https://www.daostar.org"
"@type": "DAO"
"membersURI": "<URI>",
"proposalsURI": "<URI>",
"interactionsURI": "<URI>",
"properties": {
"description": "<description>",
"governanceURI": "<URI>"
}
}
Members
Members JSON-LD Schema.
{
"@context": {
"@vocab": "http://daostar.org/"
},
"members": [{
"memberId": {
"@type": "EthereumAddress"
"@value": "<address>",
}
},
{
"memberId": {
"@type": "EthereumAddress"
"@value": "<address>",
}
}
]
}
Proposals
Proposals JSON-LD Schema. Every ERC-1234 contract MUST implement a proposalsURI pointing to a JSON object satisfying this schema.
{
"@context": {
"@vocab": "http://daostar.org"
},
"@type": "Proposal",
"metadata": {
"@type": "proposalMetadata",
"proposalId": "[CHAIN_ID][CONTRACT_ADDRESS][PROPOSAL_ID]",
"title": "<title>",
"contentURI": "<contentURI>"
},
"status": {
"@type": "proposalStatus",
"description": "<description>"
},
"executionData": {
"calls": [
{
"@type": "callDataEVM",
"from": "<address_1>",
"to": "<address_1>",
"data": "<call_data_1>",
"call_type": "<call or delegate call>",
"value": "<call_value_1>"
} ,
{
"@type": "callDataEVM",
"from": "<address_2>",
"to": "<address_2>",
"data": "<call_data_2>",
"call_type": "<call or delegate call>",
"value": "<call_value_2>"
}]
},
}
An example of an ERC-1234 Proposals URI JSON file follows. The properties array proposes some SUGGESTED formatting for proposal-specific display properties and metadata.
An example of an ERC-1155 Metadata JSON file follows. The properties array proposes some SUGGESTED formatting for token-specific display properties and metadata.
Activity Log
Activity Log JSON-LD Schema.
{
"@context": "https://www.daostar.org"
"@type": "ActivityLog",
"proposalId": "<proposal_id>",
"member": {
"@type": "Member",
"address": "<address>"
},
"interactionData": {
"@type": "interactionDataBase",
"description": "<description_text>"
}
}
Rationale
In this standard, we assume that all DAOs possess at least two primitives: membership and behavior. Membership is defined by a set of addresses. Behavior is the contract-level behavior defined by a set of actions. Proposals relate membership and behavior; they are objects that members can interact with and which, if and when executed, become actions of the DAO.
Membership
Approaches to membership vary widely in DAOs. Some DAOs and DAO frameworks (e.g. Gnosis Safe, Tribute), maintain an explicit, on-chain set of members, sometimes called owners or stewards. But many DAOs, especially DAOs where membership status is based on the ownership of a transferable/non transferable token or tokens (e.g. Moloch, Compound, DAOstack, 1Hive Gardens), require some form of off-chain indexing of events to compute the current list of members.
In choosing to ask only for an (off-chain) JSON schema of members, we are trading off some on-chain functionality for more flexibility and efficiency. We expect different DAOs to use membersURI in different ways: to serve a static copy of on-chain membership data, to contextualize the on-chain data (e.g. many Gnosis Safe stewards would not say that they are the only members of the DAO), to serve consistent membership for a DAO composed of multiple contracts, or to point at an external service that computes the list, among many other possibilities. We expect many DAO frameworks to offer a standard endpoint that computes this JSON file, and provide a few such examples of such endpoints in the implementation section.
We encourage extensions of the Membership JSON-LD Schema, e.g. for DAOs that wish to create a state variable that captures active/inactive or different membership levels.
Proposals
Proposals have become a standard way for the members of a DAO to trigger the DAO’s possible actions, or as a signaling mechanism.
We split the proposal’s properties to the following categories:
- Metadata: In many cases, a proposal will have some off-chain context (e.g. a forum post) which predates the actual proposal object. The meta-data includes description properties (e.g. the proposal title, URI of the proposal content and context), timing properties (e.g. start time, end time) and the submitter of the proposal.
- Status/state: A proposal will have a set of possible states and the current state indicates the status of the proposal (e.g. passed, executed).
- Governance: A proposal has some governance method attached to it. The governance defines the rules which control the transitions between the possible states of the proposal.
- Execution: A proposal may include some implied execution or may serve as a signal generator. In case the proposal implies execution (we refer to it as binding execution), the execution can be either an on-chain or an off-chain action.
The proposed standard is designed to be flexible enough to be compatible with the diverse DAO space, while still providing useful applications. As the main diversity is in the governance space, the standard focuses on the proposal’s metadata and execution properties. Though the state of the proposal depends on the governance method, some basic state indicators are included.
Activity Log
The activity log object’s purpose is to capture the interplay between the members of a DAO and a given proposal. Examples of activities are the creation/submission of a proposal, voting on a proposal, disputing a proposal, and so on.
Alternatives we considered: history, interactions
Governance
Membership, to be meaningful, usually implies rights and affordances of some sort (right to vote on proposals, right to ragequit, right to execute proposals, etc.). But many rights and affordances of membership are realized off-chain (e.g. right to vote on a Snapshot, gated access to a Discord). Instead of trying to standardize these wide-ranging practices, we believe that a flatfile (normatively a .md file) represents the easiest and most widely-acceptable mechanism for communicating what membership means. These flatfiles can then be consumed by services like Etherscan, supporting DAO discoverability.
We chose the word “constitution” as an appropriate word that reflects (1) the document’s role in characterizing the meaning of membership in a DAO, and (2) the already-extant pattern of DAOs emitting constitutions that perform this role.
Alternative names considered: description, readme, governance, constitution.
Why JSON-LD
We chose to use JSON-LD [3] rather than the more widespread and slightly simpler JSON standard because we want to support use-cases where a DAO wants to include members using some other form of identification than their Ethereum address. We also want this standard to be compatible with future multi-chain standards. Either use-case would require us to implement a context for the address, which is already implemented in JSON-LD.
Community Consensus
The initial draft standard was developed as part of the DAOstar One roundtable series, which included representatives from all major EVM-based DAO frameworks (Aragon, Compound, DAOstack, Gnosis, Moloch, OpenZeppelin, and Tribute), a wide selection of DAO tooling developers, as well as several major DAOs. Thank you to all the participants of the roundtable, the full list of which can be found here.
In-person events will be held at Schelling Point 2022 and at ETHDenver 2022, where we hope to receive more comments from the community. We invite anyone with questions or contributions into our discussion.
Implementations
Moloch
DAOstack
Compound
DAO*1: a Snapshot based on membership in the roundtable
History [Planned]
References
- Dilger, W. (1997). Decentralized autonomous organization of the intelligent home according to the principle of the immune system’. 1997 IEEE International Conference on Systems, Man, and Cybernetics. Computational Cybernetics and Simulation, 351–356. https://doi.org/10.1109/ICSMC.1997.625775
- Buterin, V. (2013a). Ethereum whitepaper: A next-generation smart contract and decentralized application platform [White Paper]. https://blockchainlab.com/pdf/Ethereum_white_paper-a_next_generation_smart_contract_and_decentralized_application_platform-vitalik-buterin.pdf
- JSON-LD Schema. https://json-ld.org/
- ...
Copyright
Cutting board & rationales
Older notes from Lucidchart, incl. ER diagram
ă…¤ | - | - |
- | Membership has no relationship to behavior | Behavior defines membership |
- | Membership defines behavior | Membership and behavior define each other |
- Use JSON-LD instead of JSON. Rationale: JSON-LD seems like it may be unnecessary overhead for the Ethereum/EVM use-case, since there is a centralized EIP process + standard for documenting the meaning of JSON objects. However, it may be useful for multi-chain use-cases. what will be the standards environment be there, will having context files be really useful / necessary if we imagine the ecosystem gets much more complicated. Further, if in 3 months when we are making a multichain standard and decide this would be really useful to have, then we can change the draft standard (since it will very likely still be in the EIP comment period at that time). If we end up going the JSON-LD route, we can host the schema file at daostar.org.
- We will use addresses instead of DIDs; we MAY include DID as an optional field in the JSON. Rationale: DIDs are not yet a widely-adopted standard, and will not always be relevant or preferred for certain DAO use-cases. In the members JSON schema, DAOs can optionally include a DID reference. However, we believe that DID could benefit a substantial number of use-cases and MAY include it as an optional field in the members JSON.
- Do we want to include a chainID property as mandatory in proposals or in the metadata extension?
- The members URI should point to an off-chain JSON file or endpoint that returns a JSON schema, full-stop. But we will still provide 1-3 demo methods (incl. endpoints for Moloch, DAOstack, Aragon) that produce this JSON schema. Rationale: compared to alternatives below, this is more straightforward and substantially less risky than pointing to a piece of unsecured code and asking users to run it to obtain a members JSON. compared to a URI that points to a JSON file or a piece of code that returns a JSON, we expect many DAOs will subscribe to endpoints maintained by aggregators or framework providers.
- What about on-chain membership data that is not queryable?
- Alternative 1: membersURI should point to a JSON file or an arbitrary method that returns a JSON file (no guarantees)
- Alternative 2: membersURI should point to a JSON file or an arbitrary method that returns a JSON file (no guarantees), and here are 1-3 demo methods as archetypes
- Alternative 3: membersURI should point to a JSON file or an arbitrary method that returns a JSON file, and use this “universal resolver” that guarantees some of the computation.
- A resolver or a driver is a piece of code that, in this case, takes as input the DAO address and outputs the members JSON. In between, it can run arbitrary code, including reaching out to external services and data sources. It guarantees that what you run will return a JSON-LD object.
- NOTE: if you make it too easy to create resolvers / drivers, that might create bloat. Ref. explosion of DID methods.
- If so, which examples of resolvers do we want to implement as examples?
- Parse graph index, return JSON
- Run arbitrary Rust code, return JSON
- Are we focusing too much on data science use-cases and not enough on on-chain use-cases like DAO-to-DAO interaction? ...
- Do NOT include a choices or options property in the JSON-LD schema, as below, since ...
"choices": {
"@type": "proposalChoicesList",
"possibleChices": "<options_array>",
"selectedChoice": "<selected_choice>"
}
Â