funded
MLabs + Clear Contracts -Agora dRep Effect Validator
Current Project Status
In Progress
Amount
Received
₳0
Amount
Requested
₳499,692
Percentage
Received
0.00%
Solution

Implementing V3 Agora dRep Effect for DAOs to vote on Governance proposals in fully permissionless way without delegating their stake to a centralized party. GAT V2 to V3 upgrade. Clarity.vote update

Problem

DAOs with a significant ADA balance in Agora treasury can’t vote on Cardano Governance proposals with their stake, nor use Agora Effects that use Plutus V3 with governance actions.

Impact Alignment
Feasibility
Value for money

MLabs

1 member

MLabs + Clear Contracts -Agora dRep Effect Validator

Please describe your proposed solution

Problem

During Chang hardfork Cardano introduced protocol level governance, however, DAOs that use open source Agora governance framework do not have a way to interact with that directly. The only solution available now is to delegate to a centralized dRep, which goes against the idea of community-managed DAO treasury. We propose expanding the Agora framework with an additional set of validators that will allow DAOs to vote for a way they want to participate in protocol-level governance.

Compatibility of previous Plutus versions (V1 and V2 at the time of writing) with V3 version and governance actions added in Chang hardfork is not straightforward. A transaction that includes a vote on Cardano proposal cannot execute a V2 validator. This imposes a problem for DAOs that use V2 versions of Agora base scripts. Specifically, GAT (Governance Authority Token) minting policy, which governs all effects (actions such as withdrawing from DAO treasury, voting on Cardano proposals, etc.) execution, is the problematic one in this case. It is not possible to use GAT tokens to authorize effects that vote to governance actions, which would involve burning GAT tokens and voting the same transaction. Our approach is to implement a proxy validator that will upgrade GATs from V2 to V3 if that is required by the effect so the upgrade remains fully onchain with no centralized parties involved.

The impact will be demonstrated by a successful integration with clarity.vote, enabling practical use in governance proposals and voting for both existing DAOs and new organizations in a seamless way without the need to upgrade the whole set of Agora validators to V3, which would effectively require bootstrapping new DAOs.

Solution

We will implement a suite of validators to enable DAOs to interact with Cardano’s protocol-level proposals and to opt-in for upgrade GAT tokens to V3 for effect that require them

Chang hardfork allows both individuals as well as scripts to become dReps that can propose Cardano proposals and vote on them. In the Agora ecosystem, this will be the validator that receives a GAT token after the Agora proposal has been successful. Here, it acts as three validators at once. It allows for dRep registration as Certifying validator, governs spending, and thus burning, of GAT as Spending and also can be executed with new Plutus V3 Voting purpose to cast votes on Cardano proposals.

To allow DAOs that use V2 versions of Agora scripts to execute V3 voting effects, we will implement a proxy spending validator and a minting policy to enable V2 to V3 GAT upgrades. It will force to burn a V2 GAT and mint a new V3 GAT and hand it over to the voting effect, or any other V3 effect as the implementation will be generic to enable other developers to write their own V3 effects without the need for everybody to roll out their own migration system.

Market

By enabling DAOs to interact directly with Cardano’s protocol-level proposals, the enhancements could drive greater adoption of the Cardano blockchain. This increased usage can lead to higher transaction volumes and greater demand for ADA, Cardano’s native cryptocurrency.

The new functionalities will empower existing DAOs to operate more efficiently and effectively, potentially leading to an increase in the number of DAOs and their activities on the Cardano network. This can create a more vibrant and active ecosystem.

By reducing reliance on centralized dReps and enabling more decentralized governance, the enhancements can strengthen the overall decentralization of the Cardano network. This can attract more users and developers who prioritize decentralization.

Please define the positive impact your project will have on the wider Cardano community

This project will improve the overall governance framework, ensuring transparency, security, and user trust. These improvements will drive growth and create new opportunities within the ecosystem.

All code and documentation will be available in a public GitHub repository, ensuring transparency and accessibility.

What is your capability to deliver your project with high levels of trust and accountability? How do you intend to validate if your approach is feasible?

MLabs has an outstanding track record of delivering on Catalyst Projects. All our accomplishments are publicly available for scrutiny, and our mlabs-haskell GitHub repo provides a wealth of information on past Project Catalyst efforts.

What are the key milestones you need to achieve in order to complete your project successfully?

Milestone 1: Requirements Specification

Outputs:

  • Research and gather requirements for spending, minting, and voting conditions.
  • Draft detailed specifications for each validator.
  • Detail the interactions between the validators and the governance framework.
  • Create a LaTeX document with detailed spending, minting, and voting conditions for each of the three validators.
  • Include diagrams and flowcharts to illustrate the processes and interactions.

Acceptance Criteria:

  • The document must clearly describe the logic and conditions for each validator in a way that is accessible to both developers and non-developers.
  • The content should cover each aspect of the spending, minting, and voting conditions thoroughly, with clear and accurate explanations.
  • Diagrams and flowcharts must be included to visually represent the validators' interactions and governance structure.

Evidence of Milestone Completion:

  • Link to final LaTeX document uploaded to the public GitHub project repository.

Milestone 2: Proxy Validator Development

Output

  • Set up a public GitHub repository for the project.
  • Develop the Proxy spending validator using Plutarch.
  • Develop the V3 minting policy to facilitate the upgrade from V2 to V3 GAT tokens.

Acceptance criteria

  • The GitHub repository must be publicly accessible.
  • The repository must include comprehensive documentation, covering the logic behind both the Proxy spending validator and V3 minting policy.
  • Code must follow best practices for structure and readability, ensuring ease of use for developers interacting with the project.

Evidence of milestone completion

  • The GitHub repository link with the implemented Proxy spending validator and V3 minting policy.
  • A version history demonstrating the development process and finalization of the Plutarch code.

Milestone 3: Proxy Validator Testing & Review

Outputs

  • Create a detailed test suite that covers all aspects of the Proxy validator and V3 minting policy, ensuring they meet the specified conditions.
  • Document the code and tests to ensure clarity and ease of understanding for future developers and auditors.
  • Conduct thorough code reviews and execute tests to validate the implementation.

Acceptance Criteria:

  • All code must pass the test cases included in the test suite, covering both normal conditions and edge cases.
  • Documentation must provide clear explanations of the code logic and test results to facilitate future auditing and development efforts.

Evidence of Milestone Completion:

  • A GitHub repository link containing the passing test suite and detailed test report.
  • Documentation in the repository outlining the results of the code review and testing.

Milestone 4: Spending Validator Implementation

Outputs:

  • Develop the Spending effect validators using Plutarch.
  • Write a comprehensive test suite to ensure the validators meet the specified conditions and can handle the transition from V2 to V3 GAT tokens seamlessly.
  • Conduct code reviews and testing to validate the implementation.
  • Add the Plutarch implementation of the Spending effect validators and the test suite to the public GitHub repository.

Acceptance Criteria:

  • The code must pass all tests in the test suite.
  • The repository must be publicly accessible and well-documented, including explanations of the validators' logic and test cases.

Evidence of Milestone Completion:

  • The GitHub repository link containing the implemented Spending effect validators, the passing test suite, and supporting documentation.

Milestone 5: Documentation of Protocol and Validators

Outputs:

  • Develop the Voting effect validators using Plutarch.
  • Write a comprehensive test suite to ensure compliance with the specified conditions.
  • Conduct code reviews and testing to validate the implementation.
  • Document the implementation to facilitate understanding and future maintenance.
  • Add the Plutarch implementation of the Voting effect validators and the test suite to the public GitHub repository.

Acceptance Criteria:

  • The code must pass all tests in the test suite.
  • The repository must be publicly accessible and well-documented, including clear explanations of the validators' logic and test cases.

Evidence of Milestone Completion:

  • The GitHub repository link containing the implemented Voting effect validators, the passing test suite, and supporting documentation.

Final Milestone: End-to-End Testing and Performance Validation

Outputs:

  • Collaborate with the clarity.vote team to integrate the validators into their platform.
  • Develop the necessary offchain components to support interaction between the validators and the clarity.vote frontend.
  • Implement the frontend interface to enable the creation of Agora proposals and voting on Cardano proposals on the testnet.
  • Conduct thorough testing on the Testnet to ensure the integration works as expected.
  • Document the overall architecture and design of the validators and their interactions.
  • Provide detailed instructions for setting up and using the validators, including examples and use cases to illustrate practical applications.
  • Ensure that the documentation is clear, concise, and accessible to both technical and non-technical users.
  • Provide a functional link to the clarity.vote website that allows for the creation of Agora proposals and voting on Cardano proposals on the testnet.
  • Include API documentation, tutorial guides, and how-tos.
  • Produce a video demonstration/closeout report showcasing the functionality.

Acceptance Criteria:

  • The integration must be fully functional and tested on the testnet.
  • The interface should be user-friendly and meet the outlined specifications.
  • Documentation must be clear, comprehensive, and technically accurate.
  • A video demonstration and report must be provided as required by the Catalyst rule book.

Evidence of Milestone Completion:

  • The link to the clarity.vote website demonstrating the integration.
  • Documentation or a demo video showcasing the functionality.
  • Direct links to the API documentation, tutorial guides, and how-tos.
  • Link to the closeout report posted on YouTube

Who is in the project team and what are their roles?

MLabs

MLabs has quickly become one of the premier development firms in the Cardano Ecosystem. We are an IOG Plutus Partner and work regularly with IOG to develop the Cardano blockchain and ecosystem. Our team is composed of talented developers who have helped build community projects such as:

  • Indigo
  • Liqwid
  • SundaeSwap
  • Minswap
  • Optim
  • Many others

Through our work with early-stage projects, we have one of the largest groups of Haskell/Plutus developers in the community.

<https://mlabs.city/>

Core team

Tomasz Maciosowski

Tomasz, a Haskell/Plutus developer, has gained experience through involvement in projects such as Clarity and Charli3. Additionally, he has made contributions to different infrastructure projects like CTL.

<u>https://github.com/t4ccer</u>

Connor Fang

Connor Fang is a haskell engineer at MLabs. With over three years of experience in the Cardano stack, he has helped develop and maintain various protocols and open-source projects. Notably, he implemented a significant portion of Liqwid’s agora governance protocol’s on-chain part. He specialises in various on-chain and off-chain toolkits, including but not limited to plutarch, ctl, and nix, and he hopes that his passion can bring power to Cardano’s growth.

<https://github.com/chfanghr>.

Please provide a cost breakdown of the proposed work and resources

Milestone 1 (Spec): 199 hours

75 h - Research spending, minting, and voting conditions

62 h - Draft specifications for each validator

62 h - Create a detailed LaTeX document for the conditions

Milestone 2 (Proxy Implementation): 182 hours

62 h - Develop the proxy spending validator using Plutarch

62 h - Implement the V3 minting policy

58 h - Set up a GitHub repository for the project

Milestone 3 (Spending/Voting Implementation): 182 hours

68 h - Create a comprehensive test suite for the proxy validator

54 h - Conduct code reviews

46 h - Validate the implementation using test cases

14 h - Document results in a test report

Milestone 4 (Off-chain &amp; Frontend Integration): 234 hours

89 h - Develop the spending effect validators in Plutarch

74 h - Write test cases for the spending validators

57 h - Review and validate the code with tests

14 h - Upload the code to GitHub

Milestone 5 (Documentation): 234 hours

90 h - Develop the voting effect validators in Plutarch

58 h - Write and execute test cases for voting validators

58 h - Conduct final code reviews and validation

28 h - Ensure documentation and upload the code to GitHub

Milestone Final (End-to-End Testing): 300 hours

101 h - Develop off-chain components for clarity.vote integration

71 h - Implement frontend interface for proposals and voting

71 h - Create API documentation and tutorial guides

57 h - Test on Testnet and prepare a closeout report with a demo video

Total: 1,331

Subtotal: 1,331 hours @110 USD/hour = 146,410 USD

Total (@ rate $0.293 USD / ADA): 499,692 ADA

**In the interest of full transparency, please note we have applied a conservative USD/ADA exchange rate in pricing this proposal. This is to ensure our operations remain stable regardless of market conditions. Although we firmly believe the future of Cardano is bright, we recognize the price of ADA and all cryptocurrencies is inherently volatile. Our financial obligations are denominated in fiat. Most importantly, this includes the salary of our engineers whose hard work makes projects like this possible.

In the unlikely scenario of severe negative price movement beyond our forecasted rate, it is possible that MLabs may need to temporarily suspend work on this proposal until the market recovers. Rest assured, this decision would be made solely to protect our business's long-term viability and never taken lightly. We appreciate your understanding and support, and we are excited to see what we can achieve together.

No dependencies.

How does the cost of the project represent value for money for the Cardano ecosystem?

The cost of the project represents value for money for the Cardano ecosystem for:

  1. Enhanced Security and Trust: By ensuring a secure upgrade process and robust voting mechanism, the project enhances the overall security and trust within the Cardano ecosystem, which is invaluable for long-term sustainabilit

  2. Increased Participation: A transparent and efficient governance system encourages more community members to participate in decision-making processes, leading to more democratic and representative outcome

close

Playlist

  • EP2: epoch_length

    Authored by: Darlington Kofa

    3m 24s
    Darlington Kofa
  • EP1: 'd' parameter

    Authored by: Darlington Kofa

    4m 3s
    Darlington Kofa
  • EP3: key_deposit

    Authored by: Darlington Kofa

    3m 48s
    Darlington Kofa
  • EP4: epoch_no

    Authored by: Darlington Kofa

    2m 16s
    Darlington Kofa
  • EP5: max_block_size

    Authored by: Darlington Kofa

    3m 14s
    Darlington Kofa
  • EP6: pool_deposit

    Authored by: Darlington Kofa

    3m 19s
    Darlington Kofa
  • EP7: max_tx_size

    Authored by: Darlington Kofa

    4m 59s
    Darlington Kofa
0:00
/
~0:00