Bullish.social

Voting Power

Voting power determines how much influence a user has when participating in Bullish DAO governance. It is calculated based on historical leaderboard performance using rank proofs.

🗳️ What Is Voting Power?

Voting power is the number of valid votes a user can cast on a proposal. It reflects the user's historical contribution to the platform, both individually and through clubs.


🧮 How Is It Calculated?

Voting power is derived from historical leaderboard ranks. Users and clubs earn voting power based on their rankings in past weeks. The voting power system is designed to incentivize active and long-term engagement in the platform.

  1. Individual Voting Power:
    • Proofs of ranking within the top votingMaximumRank over the past eligibleWeekCount weeks are required.
    • Each valid proof grants 1 voting power unit.
  2. Club Voting Power:
    • Club leaders(in the weekly leaderboard) have the right to vote on behalf of their club.
    • The club’s rank must be within the votingMaximumRank, and the leader’s member rank should be 1.
  3. Interim Governor:
    • The interim governor (initial owner) is automatically granted the maximum voting power for both individuals and clubs during the bootstrapping phase.
    • This bonus is 1 voting power for individuals and 1 voting power for clubs per eligible week.

Voting power = number of valid individual + club rank proofs

Example: Assume eligibleWeekCount is set to 2, and votingMaximumRank is 100. John was ranked 50th on the individual leaderboard last week and 30th this week. Therefore, John receives 2 voting power on proposals created during or after the current week.


🔢 Main Function of Calculating

/**
 * @notice Calculates the voting power for a range of weeks based on provided proofs.
 * @param forUser for which address
 * @param maxWeekIndex maximum allowed week index of the proposal.
 * @param minWeekIndex minimum allowed week index of the proposal.
 * @param individualProofs Array of individual rank proofs.
 * @param clubProofs Array of club rank proofs.
 * @return votingPower The total voting power (number of valid proofs).
 */
function _calculateVotingPower(
    address forUser,
    uint64 maxWeekIndex,
    uint64 minWeekIndex,
    IndividualRankProof[] memory individualProofs,
    ClubRankProof[] memory clubProofs
) internal view returns(uint64 votingPower) {
    // Interim owner has the maximum power of users can have
    if (forUser == i_interimOwner) {
        uint64 interimVotingPower = (maxWeekIndex - minWeekIndex + 1) * 2;
        return interimVotingPower;
    }

    // Individual rank proofs
    for (uint256 i = 0; i < individualProofs.length; i++) {
        IndividualRankProof memory proof = individualProofs[i];

        // Check for duplicated entries
        for (uint256 j = i + 1; j < individualProofs.length; j++) {
            require(!_isIndividualRankProofEqual(individualProofs[i], individualProofs[j]), "Rank proof has been already used in this proposal");
        }

        // Verify and apply power
        if (verifyIndividualRankProof(forUser, proof, minWeekIndex, maxWeekIndex)) {
            votingPower += 1;
        }
    }
    
    // Club rank proofs
    for (uint256 i = 0; i < clubProofs.length; i++) {
        ClubRankProof memory proof = clubProofs[i];

        // Check for duplicated entries
        for (uint256 j = i + 1; j < clubProofs.length; j++) {
            require(!_isClubRankProofEqual(clubProofs[i], clubProofs[j]), "Rank proof has been already used in this proposal");
        }

        // Verify and apply power
        if (verifyClubRankProof(forUser, proof, minWeekIndex, maxWeekIndex)) {
            votingPower += 1;
        }
    }
    
    return votingPower;
}

Users who are active on the platform can participate in decision-making, ensuring committed members have a voice in governance

On this page