UPDATED: Rules for Lending, Borrowing, Insuring, and Auction within the Flash Pool

Wing Finance
Wing Finance
Published in
9 min readSep 23, 2020

Last Updated: Feb 07, 2021

Abstract: This article introduces in detail the rules of participating in Wing Flash Pool’s for borrowing, lending, guaranteeing, and auctioning. As well as the distribution rules of WING tokens to help users understand and participate in Wing Flash Pool.

Accepted assets

ONT, ONG, wBTC, renBTC, USDC, ETH, DAI, USDT, SUSD, NEO, UNI, YFI and WING.

The assets involved in borrowing, lending, and guaranteeing on the Flash Pool are all OEP-4 type assets built on the Ontology chain. Assets on the Ethereum chain or NEO chain need to be exchanged for pToken assets on the Ontology chain, and ONT needs to be exchanged for ONTd before joining. WING and ONG do not need to be exchanged and can participate directly.

Pools

Applicable Pools: Supply Pool, Borrow Pool, and Insurance Pool

Currently, only WING tokens can be used in the Insurance Pool. The same assets in the same address cannot be used in both Supply Pool and Borrow Pool at the same time.

WING Token Distribution

*The current interest calculation method is calculated by block. The actual interest is related to the rate of block production, and there may be gaps with the page display. The system calculation is based on the contract.

Current WING distribution rate per second: 0.06 WING/sec, WING burned rate per second: 0.024 WING/sec.

WING rewards will be distributed according to the pool distribution base of the Flash Pool and Inclusive Pool first. pool distribution base = Pool distribution coefficient * Borrowed Assets(in USD).

Subsequently, the WING distributed to the Flash Pool is distributed according to the WING distribution base of each asset type in the Flash Pool (see the calculation formula below). Whereas the WING earned by each asset type will be converted into the WING distribution base obtained by that asset type(in USD).

WING distribution base = Borrowed Assets (in USD)* Utilization Rate of the Asset

Utilization Rate of the Asset = the Amount of the Asset in the Borrow Pool / the amount of the Asset in the Supply Pool

WING rewards will then be distributed to the three pools in accordance to their distribution ratio.

And finally, WING rewards will be distributed to users according to the proportion of a user’s assets against the same assets in that Pool.

For instance: The total value of the borrowed assets in the Inclusive Pool is $500, and there are only the following three assets in the Flash Pool, then the proportion of each pool is as follows (in USD):

And then calculate rewards based on the pool distribution ratio:

Last but not least, calculations will be made according to the proportion of the assets in that Pool.

For example:

User A supplied pETH worth $100 and insured WING worth $100.

Based on the statistics above, User A’s WING earned per second is

(100/1,000*0.00694+100/1,000*0.00216)*86,400= 78.624.

Rules for Supplying and Borrowing

After the asset is supplied and the mortgage is opened, other assets can be borrowed. According to the Collateral Factor for the asset, users can calculate the maximum asset value that can be borrowed. Users can check the Collateral Factor corresponding to each asset type at the link below

https://docs.wing.finance/parameter#collateral-factor-in-flash-pool

For example: User A supplied 100 pETH and each pETH is worth $800, the maximum asset value that can be borrowed is 100*$800*80%=$64,000.

The same type of assets under the same address cannot participate in supplying and borrowing at the same time.

For instance: User A supplied pETH and ONTd, and User A can only borrow ONG、pwBTC、prenBTC、pUSDC、pDAI、pUSDT、psUSD、pNEO、pUNI、pYFI and WING.

When borrowing assets in the Flash Pool, 3% of the WING equivalent must be locked to earn WING incentives. If the 3% equivalent of WING is not locked when the asset is borrowed, then WING incentives for the loaned asset cannot be earned.

Borrowed assets are calculated based on the final annualized interest rate paid by the borrower. Each block is a calculation cycle and the calculated interest will be summarized as the principal when the next block is calculated.

When you have successfully borrowed, the borrowed assets will be deposited directly into the wallet and will start generating interest in real-time. You may use the borrowed assets freely at any moment.

In order to avoid liquidation caused by token price fluctuation, it is recommended that the value of the borrowed assets should not exceed 80% of the maximum asset value of the Borrow Pool. (Safe Max button)

Borrowed assets can be repaid at any time and the amount entered will be deducted from the wallet during the repayment. The interest accumulation will stop after the principal and interest are fully paid off.

Borrowed assets can also be partially repaid. Interest will no longer be accrued on the portion that has been successfully repaid.

Reserve Factor of the total interest paid by the lender (Borrow Pool) will be deposited into the Wing DAO Community Fund as a commission fee.

The borrowed amount of any kind of asset cannot exceed its total supply. In addition, users may fail to withdraw the asset if the withdrawal amount is higher than the available supply of that asset.

Rules for Rates and Interests

The compound interest is calculated by block. The Annual Percentage Rate (APR) of the borrower is calculated according to a Kink point model.

The Kink point model:
We set the capital utilization rate to “U” and the interest rate to “R” so that when the capital utilization rate is “U”, the corresponding interest rate will be “Ru”. The kink point (k) will have a capital utilization rate of “Uk” When the basic interest is R0, the kink point intersection will be R0+Rk, and the interest when the capital utilization rate is 100% is R0+Rk+R100.

Formulas:

If U<Uk: R=R0+U/Uk*Rk

If U≥Uk: R=R0+Rk+(U-Uk)/(1-Uk)*R100

The model parameters are detailed in:

https://docs.wing.finance/parameter#borrowing-interest-rate-model-in-flash-pool

Supply APY = Borrow APR*Amount of Borrowed Assets/Amount of Supplied Assets*(1–Reserve Factor)

The Reserve Factor are detailed in:

https://docs.wing.finance/parameter#reserve-factor-in-flash-pool

The interest paid and received by the user will be distributed in proportion of user’s asset in the Supply or Borrow Pool, and will be settled when user repay the loan or withdraw the supply.

The interest paid and received by the user is the same as the asset type supplied or borrowed.

Example 1:

User A supplies 100 pETH in supply, the current supply has a total of 1,000 pETH, and the borrower has loaned a total of 600 pETH.

Then,

Borrow APR=[1%+(600/1,000)/80%*7%]%=6.25%

Supply APY=6.25%*600/1,000*(1–15%)=3.19%

With the above data unchanged, the daily interest earned by user A is

100*3.19%/365=0.00874pETH

Example 2:

User A supplies 100 pETH in supply, the current supply has a total of 1,000 pETH, and the borrower has loaned a total of 900 pETH.

Then,

Borrow APR=[1%+7%+(900/1,000–80%)/(1–80%)]%=58%

Supply APY=58%*900/1,000*(1–15%)=44.37%

With the above data unchanged, the daily interest earned by user A is

100*44.37%/365=0.12156pETH

Liquidation Rules

Once the borrowing limit (value of repayable assets/maximum borrowed amount) is greater than or equal to 95%, the borrowed asset will then be displayed on the liquidation page. Once it exceeds 100%, the liquidator can liquidate the mortgage assets corresponding to the loan.

For instance: User A supplies 100 pETH, each pETH $800, and borrows 100,000 ONTd, each ONTd $0.60. After a period of time, each pETH value dropped to $750, and each ONTd value goes up to $0.65;

Therefore, the maximum borrowed amount of user A at this time is 100*$750*0.8=$60,000, and the value of the assets to be repaid at this time is (without calculating interest) 100,000*$0.65=$65,000;

Then the loan amount of user A at this time is $65,000/$60,000=108%>100%.

The liquidation conditions are met, the loan of user A will be displayed on the liquidation page and enter the liquidation process.

After entering the liquidation page, all members of the Wing DAO community can freely choose to become a liquidator, use a certain discount rate to repay the liquidated person’s assets, and obtain the liquidated person’s mortgage assets. After success, the borrower’s mortgage assets and The repayable assets will be deducted accordingly.

After the liquidator performs one or more liquidations, once the loaned asset no longer meets the liquidation conditions, it will be removed from the liquidation page.

The Liquidation Bonus is detailed in:

https://docs.wing.finance/parameter#liquidation-bonus-in-flash-pool

For example: in the above example, user B as the liquidator uses 84,000 ONTs to repay for user A and obtains the pETH mortgaged by user A. The pETH settlement price is $750*(1–8%)=$690, then the liquidator buys the number of pETH is 84,000*$0.65/$690=79.130.

At this time, user A still has 100–79.130=20.870 remaining pETH borrowed, and the maximum asset value that can be borrowed is 20.870*$750*0.8=$12,522.

User B as the liquidator has already repaid 84,000 ONTd of the loan for user A. At this time, the value of the loan repayable by user A is (without calculating interest) (100,000–84,000) *$0.65=$10,400.

Then user A’s borrowed amount at this time is $10,400/$12,522=83%<100%.

The liquidation condition is no longer met, and the loan will be removed from the liquidation page at this time.

The upper limit of assets for each liquidation does not exceed 80% of the mortgaged assets of the current lender, and the liquidator can freely choose the liquidation amount from 0% to 80%.

The liquidator can perform multiple liquidations until the borrow limit of the loan (value of repayable assets/maximum borrowed amount) is less than 100%.

Rules for Insurance and insurance compensation

Users can directly participate in the insurance pool, which only supports WING assets.

Each WING put into the insurance pool will be locked for 72 hours and can be taken out of the insurance pool after 72 hours.

When the prices of the mortgaged assets and the borrowed assets change drastically, and the loaned assets cannot be paid off after the liquidator has purchased them all, insurance compensation will be triggered.

At the time of insurance payment, the WING locked at the time of borrowed will be liquidated first, and 100% of the remaining unpaid assets will be borne by the insurer. The asset type that the insurance pays to the supplier is WING.

For example: in the above example, if the locked WING price remains unchanged, user A chooses to lock WING with 3% of the loan amount when borrowing, that is, the value of the locked WING asset is 100,000*$0.6*3%=$1,800.

If multiple liquidators have purchased all the assets borrowed by User A and still have 4,000 ONTd not repaid, the locked WING $1,800 will be paid to the supplier of ONTd first, and the remaining 4,000*$0.65-$1,800=$800 will be paid by the insurer. The insurer will repay $800 worth of WING to the supplier of ONTd.

If the value of WING deposited by user C in the insurance pool is $10,000, and the total asset value of WING in the insurance pool is $1000,000. According to the above example, user C will need to pay $10,000/$1000,000*$800=$8, which means user C loses value of $8 WING.

Auction

The part of the monthly Wing community fund income used to buy back tokens other than WING will be used for public auctions, and all WINGs obtained from the auction will be burned after the auction ends;

Burned address: AFmseVrdL9f9oyCzZefL9tG6UbvhPbdYzM

Each auction starts at 0:00 UTC on the 23rd of each month and lasts for up to 10 days;

When all assets are auctioned off, the auction for the month ends. If there are still tokens that have not been auctioned off after the 10th day, they will be automatically included in the next auction;

The auction price is taken from the Wing platform Oracle, and is subject to the price at the time of execution on the auction transaction chain;

The auction method is a reduced price bidding. The Tokens that are auctioned on the first day of auction will be reduced by 1% from the market price, and thereafter, the price will be reduced by 1% every natural day, and the price will be reduced by up to 10%;

For example: there are a total of 100 pUSDT auctions, and each pUSDT is $1 and the price remains the same. The auction starts in a certain month

The auction price of pUSDT on the 23rd was $1*(1–1%)=$0.99, 10 were auctioned on that day, and 90 were left;

The auction price of pUSDT on the 24th was $1*(1–2%)=$0.98, 20 were auctioned on that day, and 70 were left;

The auction price of pUSDT on the 25th was $1*(1–3%)=$0.97, 30 were auctioned on that day, and 40 were left;

The auction price of pUSDT on the 26th was $1*(1–4%)=$0.96, and 40 were auctioned on the same day. After the auction of the asset is completed, the auction of the asset ends.

The auction will only be operated through ONTO Wallet.

Want More?

Connect with us on Twitter or join the Telegram discussion, or read our Whitepaper to learn more.

--

--

Wing Finance
Wing Finance

Wing built a decentralized finance (DeFi) platform to support cross-chain collaborative interaction between various DeFi products.