2. DISCLAIMER
§ The views and opinions expressed by the Presenter are those of the Presenter.
§ Presentation is not intended as legal or financial advice and may not be used as legal or
financial advice.
§ Every effort has been made to assure this information is up-to-date as of the date of
publication.
3. PLAN FOR TODAY
1.DAO and Decentralized Governance
2.Smart Contracts for Decentralized
Governance
4. DEFINING DAO
“A decentralized autonomous organization (DAO), sometimes called
a decentralized autonomous corporation (DAC), is
an organization represented by rules encoded as a computer program that is
transparent, controlled by the organization members and not influenced by a
central government, in other words they are member-owned communities
without centralized leadership.”
- Wikipedia
• DAOs often use blockchain technology to provide a secure digital ledger to track
digital interactions
• DAO governance is coordinated using tokens or NFTs that grant voting powers
• DAOs can be subject to coups or hostile takeovers that upend their voting
structures especially if the voting power is based upon the number of tokens one
owns
5. DECENTRALIZED GOVERNANCE
Decentralized
Governance
frameworks for managing collective
action and common resources
rules of decentralized organizations
are primarily enforced by code,
rather than the legal system
often use direct voting
Benefits:
• Gives power directly to token holders
• Eliminates some risks of censorship,
manipulation, bribery
• Reduce reliance on external legal frameworks
and systems
• Helps to align interests with group goals
• Greater autonomy
• Efficiency of decision making
• Improved transparency
6. GOVERNANCE BY VOTING
On Chain
More secure
No trusted third party is required to
count or enact votes
Passed proposals can be executed
automatically
Works well for approving protocol
changes or other high-risk votes
Reduces risk of vote tampering
Off Chain
Votes are not submitted as
blockchain transactions
No transaction fees are necessary
for off chain votes
More participation, particularly from
smaller holders and wider
community
Off chain votes can be recorded via
decentralized data storage systems,
reducing risk of vote tampering
Works well for sentiment polls or
other low risk votes
7. NOTABLE DAOS
Name Token Use cases Network Launch Status
Dash DASH
Governance, fund
allocation [24]
Dash
(cryptocurrency)
May 2015[25] Operational since
2015[26][27][28]
The DAO DAO Venture capital Ethereum April 2016
Defunct late 2016
due to hack[29]
Augur REP
Prediction
market, Sports
betting, Option
(finance), Insurance
Ethereum July 2018 Operational
Steem STEEM
Data distribution,
Social media, Name
services, Industrial
Steem March 2016 Operational
Uniswap UNI
Exchange,
Automated Market
Making
Ethereum November 2018 Operational[30]
ConstitutionDAO PEOPLE
Purchasing an
original copy of
the Constitution of
the United States
Ethereum November 2021[31] Defunct[32]
17. BALLOT CONTRACT 1/6
// SPDX-License-Identifier: GPL-3.0
pragma solidity >=0.7.0 <0.9.0;
/// @title Voting with delegation.
contract Ballot {
struct Voter {
uint weight; // weight is accumulated by delegation
bool voted; // if true, that person already voted
address delegate; // person delegated to
uint vote; // index of the voted proposal
}
// This is a type for a single proposal.
struct Proposal {
bytes32 name; // short name (up to 32 bytes)
uint voteCount; // number of accumulated votes
}
18. BALLOT CONTRACT 2/6
constructor(bytes32[] memory proposalNames) {
chairperson = msg.sender;
voters[chairperson].weight = 1;
// For each of the provided proposal names,
// create a new proposal object and add it
// to the end of the array.
for (uint i = 0; i < proposalNames.length; i++) {
// `Proposal({...})` creates a temporary
// Proposal object and `proposals.push(...)`
// appends it to the end of `proposals`.
proposals.push(Proposal({
name: proposalNames[i],
voteCount: 0
}));
}
}
19. BALLOT CONTRACT 3/6
function giveRightToVote(address voter) external {
require(
msg.sender == chairperson,
"Only chairperson can give right to vote."
);
require(
!voters[voter].voted,
"The voter already voted."
);
require(voters[voter].weight == 0);
voters[voter].weight = 1;
}
20. BALLOT CONTRACT 4/6
/// Delegate your vote to the voter `to`.
function delegate(address to) external {
// assigns reference
Voter storage sender = voters[msg.sender];
require(!sender.voted, "You already voted.");
require(to != msg.sender, "Self-delegation is disallowed.");
while (voters[to].delegate != address(0)) {
to = voters[to].delegate;
// We found a loop in the delegation, not allowed.
require(to != msg.sender, "Found loop in delegation.");
}
// Since `sender` is a reference, this
// modifies `voters[msg.sender].voted`
Voter storage delegate_ = voters[to];
// Voters cannot delegate to wallets that cannot vote.
require(delegate_.weight >= 1);
sender.voted = true;
sender.delegate = to;
if (delegate_.voted) {
// If the delegate already voted,
// directly add to the number of votes
proposals[delegate_.vote].voteCount += sender.weight;
} else {
// If the delegate did not vote yet,
// add to her weight.
delegate_.weight += sender.weight;
}
}
21. BALLOT CONTRACT 5/6
function vote(uint proposal) external {
Voter storage sender = voters[msg.sender];
require(sender.weight != 0, "Has no right to vote");
require(!sender.voted, "Already voted.");
sender.voted = true;
sender.vote = proposal;
// If `proposal` is out of the range of the array,
// this will throw automatically and revert all
// changes.
proposals[proposal].voteCount += sender.weight;
}