Democratising DeFi liquidations by pooling together funds for liquidations.
Liquidations on DeFi platforms as a means of making money used to be quite inaccessible to a majority of DeFi enthusiasts, while the yields they can offer are very attractive. We aim to combat this by allowing anyone to participate in DeFi liquidations. LiquiDefi is a profit-sharing platform for liquidations. Users deposit Dai into our pool and are minted sharkTokens. These tokens represent a percentage of the total pool holdings and increase in value as liquidations are carried out. The pooled funds are utilised by our liquidation bots on Aave. By using the pooled assets vs flash loans we save in gas cost and are more efficient. This also will give everyday users the chance to profit from liquidation yields.
We build a Solidity smart contract that allows anyone to deposit DAI. This DAI is then converted to aDAI for additional yield for our users. In return the users receive sharkDAI, which represents a share of the pool. The exchange rate is calculated by dividing the supply of aDAI in the contract by the total supply of sharkDAI. Next, our liquidation bots call the liquidate function on our contract. This unwraps the contract's aDAI, and uses the resulting DAI to liquidate Aave positions. In return the contract receives some collateral from Aave (such as ETH or WBTC). This gets swapped back to DAI using Uniswap (support for v1 and v2), and finally is converted back to aDAI with Aave again. At any point in time, the investors may withdraw their funds by burning sharkDAI and receiving the equivalent back in DAI. The exchange rate calculations stay the same. For the frontend we used Next.js together with Onboard.js for easy Metamask and Portis integration. We opted for a pie chart to represent ownership of a part of the pool, so these sharkTokens feel more like shares.