Giter VIP home page Giter VIP logo

zerointerestdefi's People

Contributors

ctapang avatar bryancabansay avatar y2kappa avatar patrick-fitzgerald avatar

Stargazers

Vetrichelvan Jeyapalpandy avatar

Watchers

James Cloos avatar  avatar  avatar  avatar

zerointerestdefi's Issues

Redeemer receives SOL

In the Liquity system, redeemers have to "catch" the riskiest trove in order to redeem from it. In our system, the selection can be done from the sorted list of troves, and we can design it such that the redeemer comes to our system knowing only how much stable-token she wants to exchange for SOL. Our system then selects the riskiest trove to either partially or fully redeem. Even in the case of a full redemption, the borrower does not lose all her SOL. If the contents of the first trove is not enough, the system redeems the next trove in line, and so on.

Mint stable-token (ROKS) & Transfer to (Receive) wallet 90.9%

After the system receives SOL for collateral, we consult the oracle (Pyth - see #11 (comment)) for current SOL price in USD, multiply that by the amount of SOL deposited, and mint 90.9% of the value. We then send this much stable-token to the borrower's address. This address is the "associated token account".

Can Liquidate a borrower

Borrower's collateral falls below 110% of loan value, either because the price of SOL drops or the borrower has borrowed more stable-token.

Trove loses SOL, decreases debt in ROKS

The riskiest troves are redeemed from; however, as opposed to the liquidation case, the borrower in this case does not lose all her SOL. For example, if she has 120% SOL collateral, the most she loses is 100% of the value of her debt, leaving 20% in the worst case scenario. SOL is paid to the redeemer, and the burned stable-token basically pays-off the loan (or at least part of it).

Stake reward-token (VTT), unstake VTT

Reward token holders can stake their reward token for rewards. These rewards come from the fees paid by users during trove openings and redemptions.

Staking UI

Separate page where you can stake your coins.
(Note: I may have attached this to the wrong milestone.)

Redeemer redeems stable-token (say 500 ROKS)

The redeemer in this case can be anybody, not just borrowers. She could be somebody who bought the stable-token from a DEX. She comes to the system and deposits 500 stable-tokens, with the aim of receiving SOL in return. This is only profitable when the stable-token exchange rate with USD goes below 1.0.

SOL is sent to Stability Pool depositors

All of SOL in liquidated troves are placed in "Collateral Surplus Pool". These SOL are distributed to Stability Pool depositors. (Please consult with Liquity code to determine exactly when the Collateral Surplus Pool should be distributed.)

Unstake from Stability Pool

Unstake stable-token from Stability Pool. If any reward-token is due, those would be sent to the user's reward-token address also.

Stable-token ROKS is burned

When a trove is liquidated, then depending on system conditions, some of its Stable-token debt gets offset with stable-tokens in the Stability Pool: that is, the offset debt evaporates, and an equal amount of LUSD tokens in the Stability Pool is burned.

Thus, a liquidation causes each depositor to receive a stable-token loss, in proportion to their deposit as a share of total deposits. They also receive a SOL gain, as the SOL collateral of the liquidated trove is distributed among Stability depositors, in the same proportion.

When a liquidation occurs, it depletes every deposit by the same fraction: for example, a liquidation that depletes 40% of the total stable-token in the Stability Pool, depletes 40% of each deposit. A deposit that has experienced a series of liquidations is termed a "compounded deposit": each liquidation depletes the deposit, multiplying it by some factor in range [0,1].

Deposit SOL

Deposit SOL in order to borrow stable-token ROKS.

Redeemer pays redemption fee

The redemption fee is calculated according to a decaying formula. It goes up at a certain rate for every redemption, but then decays until the next redemption.

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.