Code Monkey home page Code Monkey logo

cellar-staking's Introduction

๐Ÿ”’๐Ÿ’ฐ Cellar LP Bonding

An extension of canonical ERC20 staking patterns for Sommelier LP bonding rewards programs. Unlike other ERC20 staking pools, Sommelier also uses a 'bonding' mechanism, inspired party by Osmosis.

When staking, users must choose an "unbonding" time - this is the cooldown period a user must wait to claim their tokens after electing to unstake. Higher unbonding periods/cooldown times receive higher reward boosts.

Features

  • ๐Ÿฆ Admins can set the length of a rewards epoch and fund a certain amount of rewards, starting an epoch.
  • โฌ‡๏ธ Users can stake coins in the bonding program, choosing 1-day, 7-day, or 14-day bonding. User's stakes receives multipliers based on bonding period. For instance, a deposit of 100 LP shares with a 2-week unbonding period will receive the equivalent of 200 LP shares deposited with no boost.
  • ๐ŸŽ Users begin to accumulate rewards as soon as their stake is deposited.
  • ๐ŸŽŠ Users can claim accumulated rewards at any time.
  • โฒ๏ธ Users can begin unbonding period at any time, starting the cooldown timer. Once unbonding, any time-based boosts are removed. Users cannot edit their unbonding period after staking.
  • โŒ After beginning to unbond, users can cancel unbonding at any time, moving the cooldown timer back to 0 and reinstating any time-based boosts.
  • โฌ†๏ธ After unbonding, users can return after the cooldown period to claim their deposited tokens, along with rewards.

Full technical documentation can be read in the code's natspec.

Project Architecture

Template copied from kkennis' Hardhat template - see template README for generalized project instrutions.

cellar-staking's People

Contributors

0xble avatar kkennis avatar sandbochs avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

cellar-staking's Issues

Start contract in paused state

The contract should be paused upon deployment. Calling initializePool should set contract to unpaused. This will allow us to remove the init check within the stake fn.

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.