Coder Social home page Coder Social logo

ubi's Introduction

Universal Basic Income.

UBI Coin

A standard for Universal Basic Income tokens.

Built in collaboration with Kleros and the Proof of Humanity project.

Build Status Coverage Status

Features

  • ERC20 token that can mint new supply for verified humans over time at a given rate.
  • Interfaces with ProofOfHumanity to get curated list of verified humans.
  • Issuance rate —a. k. a. inflation— is subject to governance.
  • Token has burn function —a. k. a. deflation— that can be triggered by users or a DAO.
  • Snapshot event emitted to ease use of token for governance purposes.
  • ProofOfHumanity registry can be updated with governance mechanism.
  • Implements ERC20Upgradeable contracts with OpenZeppelin proxy libraries.

Built with Hardhat.

Latest release is version 0.1.9

Setup

  1. Clone Repository

    $ git clone https://github.com/DemocracyEarth/ubi.git
    $ cd ubi
  2. Install Dependencies

    $ npm install
  3. Run Tests

    $ npx hardhat test

    To compute their code coverage run npx hardhat coverage.

Deploy

  1. On hardhat.config.js configure the following constants for the kovan testnet:

    INFURA_API_KEY
    KOVAN_PRIVATE_KEY
    
  2. Deploy on Ethereum kovan testnet:

    $ npx hardhat run scripts/deploy.js --network kovan
  3. Interact with the console:

    $ npx hardhat console --network kovan

    Initalize the token with:

     const UBI = await ethers.getContractFactory("UBI")
     const ubi = await UBI.attach('0xDdAdE19B13833d1bF52c1fe1352d41A8DD9fE8C9') // Replace with your token address

Upgrade

  1. Deploy new contract in a fresh address:

    $ npx hardhat run scripts/prepare.js --network kovan
  2. Upgrade the proxy contract with the freshly deployed address:

    $ npx hardhat run scripts/upgrade.js --network kovan

Verify

  1. On hardhat.config.js configure your Etherscan API key:

    ETHERSCAN_API_KEY
    
  2. Verify the contract by running:

    $ npx hardhat verify --network kovan <ADDRESS>

Contribute

These contracts are free, open source and censorship resistant. Support us via Open Collective.

License

This software is under an MIT License. This is a free software built by Democracy Earth Foundation between 2020 and 2021. Democracy Earth Foundation is a 501 (c) 3 not for profit corporation from San Francisco, California with no political affiliations.

ubi's People

Contributors

santisiri avatar 0xferit avatar clesaege avatar fvictorio avatar unknownunknown1 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.