A New Day for DeFi

Crypto Valley Conference 2022 · June 2022 · 29:43

Mark Richardson argues that AMMs cannot credibly challenge private market makers if liquidity providers are forced into prescribed portfolios and risk losing more than they earn through impermanent loss. He presents Bancor 3's first, still-soft-launch phase as offering impermanent-loss protection from deposit subject to seven days' withdrawal notice, plus a one-hop vault design intended to reduce gas use. He says rewards can compound without extra transactions and liquidity caps can be removed, while stressing that the broader rollout and later contract uses were unfinished.

Speakers

Topics

From Crypto Valley Conference 2022, hosted by Crypto Valley Association.

Transcript

hello hello welcome back from lunch i hope that you're caffeinated enough [Laughter] now i would like to welcome mark richardson head of research at bancore for an amazing keynote mark the floor is yours good afternoon crypto valley uh so for those who haven't met me yet my name is mark richardson i am the product architect and the head of research at bancorp and um so one of the things that i you know that i'm trying to achieve with this presentation is to sort of give you a the most general sort of overview of

what it is that our new product release actually is the kind of value proposition that it gives to users but also to the industry and so for those who are at my master class yesterday that was very sort of down in the weeds understanding very specific sort of mathematical components of amms and how they operate and that kind of thing but this is more sort of you know for the the generalist audience but if there's anything that i uh mentioned this presentation that sort of arouses your curiosity and that you would like to explore in more depth with me we have a booth outside and i'm very happy to go into as much detail as you like so the title of this presentation is that it's a new day for d fire and this is because we really think that you know

the uh the last 12 months uh really everything since d5 summer right which is even further back than that we've seen a very large number of different of different d5 protocols being invented and tested i think that we've been through this amazing sort of epoch in sort of economic experimentation if i can put it that way i think that uh of the of the economic models that have been tried and tested the majority of them have happened in d5 over my recent history but i want to come back to sort of fundamentals a little bit because a lot of people have been asking me like what was the you know where did bangkok come from why does bancor exist people seem to know that we were the first d5

protocol or at least the first um amm not just on ethereum but anywhere and i think that this quote from from aesop which is that those who voluntarily put power into the hands of a tyrant must not wonder if but at last be turned against themselves this is really the uh i think the most concise way that i can communicate the inspiration behind what bancor is just over lunch i had a really lovely uh meeting with the team members from kiln and we were speaking about what is it even going to look like in the future right do i expect that amms are going to annex the um you know the entirety of finance right do i think that every single market in the world can be made

using an amm and i do but i don't necessarily think or want that to happen i consider these things to be in equilibrium with each other i don't trust private market makers and i don't think anyone should because they are motivated of course by their own self-interest they are profit motivated and for you know i i think it's controversial to to point out that um some of the private market makers in cryptocurrency have made more money than any other private market maker in any other market anywhere in the world over that period of time and that value has to come from somewhere right and if it's not exploitative it can at least be predatory if they are extracting that value it has to be from markets and therefore for market participants

that opportunity is fine and i don't mind it being there and i don't mind them using it but the problem is the lack of an alternative right as long as they are continually being able to siphon that kind of value off of market participants without anything standing in the way of it then of course if you let that run to its logical conclusion we end up with an essentially exploitative system and bangkok was invented to take some of that power away so we have a history of inventing the future i would say or at least reimagining um the the future of finance we had our ico in 2017 uh we established the bangkok foundation

in switzerland in zuk uh with those ico funds and the bangkok foundation continues to support the development of the protocol but also support for the whole industry many people may not know this but bankroll actually predates ethereum and smart contracts in d5 by quite a way we were the first to experiment on a large scale i think with community currency projects so in places like um like africa and even some places in the united states we were looking at whether or not it's even a good idea to have the government issued fiat as the sole way to communicate value between different market participants and so that system works quite well by the way but when it has to interface with outside economies the problem becomes

exchange right if you have a community currency that you're using to buy for example labor maybe someone rowing your lawn or painting your house how does that translate into a u.s dollar evaluation to buy things like gasoline or other commodities within that contained economy and it doesn't and so we invented amms because you want a way to establish that valuation process for a currency any currency to know its value in a reliable and a decentralized way without having to have that valuation at the whims of an emotional market maker someone who is prone to panic or someone who is incentivized by their own profit motive to value something a certain way and then force the market to just accept

that valuation so amms in our case were invented exclusively to address this problem that we saw with with community currencies and then realizing that it's actually a general problem that doesn't just affect all of cryptocurrency but maybe every asset in the world so in 2017 we actually launched the first amm and back then it was an entirely regulated operation right d5 didn't really have a name for itself yet ideas like permissionless uh use of things and you know anonymous use of these products was still to come right that narrative hadn't really began and so uh you know unlike many of the d5 projects around today bancor is intimately familiar with

regulation we have a very strong relationship with both mme and finma and we are collaborating with with regulators and lawmakers to make sure that d5 progresses in the most reasonable way when um after we launched the amm we had an opportunity to observe one of the you know some how some of those design principles affected the people that are interacting with it so in uh in contrast to um to centralized market makers that understand precisely what they're doing you can't actually make that assumption about d5 users necessarily people that are providing liquidity out of their own volition may not understand that what they're participating in is something

like a you know self-financing um trading strategy and the uh the experience back then as we established it was that if you have a token such as you know a chain link token which is link and you could then pair that with any asset for our protocol it was bnt but the status quo and ethereum right now is to pair it with the ethereum itself when you provide both of these tokens together it's the amm itself the protocol that you're using that is prescribing your portfolio for you so you're actually forced if you're an amm participant to combine these assets in a known ratio to that curve okay and i think that that is problematic one

because you know and i i know i am intimately familiar with the chain link community in general they don't like holding any other token except for chain link okay and there are other d5 communities where they want the maximum possible exposure to a particular token because either they you know they believe that it's going to outperform the rest of the market or they have a you know a very deep seated um you know uh loyalty to that particular token and they refuse to sell it this can also be a bootstrapping problem if you are a new cryptocurrency in the space and you want to create uh you know a decentralized liquid market because you don't have the resources or the relationships to establish a relation to establish an operation with a market maker then you have to do this stuff

yourself and if you are selling a very large amount of your token before it's liquid in order to make markets with it then you're actually driving its price into the ground at the first you know before you even get legs under it so this forced token exposure and defy is a problem but not just through bootstrapping but also because of this kind of leakiness of value that we call in permanent loss now i introduced this into my my master class yesterday and so if you'd like to know more about how to do this calculation i suggest that you look back over that recording but essentially when you are providing liquidity to an amm you are sort of short the uh price valuation and long the fees that it generates and because of the profound volatility of some tokens this

assumption might last for a long period of time you can be net positive but then eventually if you're if one of those tokens you know halves in price or if one of them you know goes 10x in price or something you actually might be better off not providing liquidity at all and just huddling the tokens in your wallet the problem with that is that once users start realizing that they're always better off holding the tokens and not participating in these kinds of d5 products then it's actually eroding away that kind of decentralization security that we're looking at where we are trying to take back some of that stability right and trying to establish a um an organic uh price discovery mechanism for cryptocurrencies and community currencies

this impermanent loss issue cannot be understated we created a website called il.wtf where you can put in your ethereum wallet and it will measure how much money you've lost by providing liquidity on our competing protocols and you can see some of these numbers are not insignificant there is someone here that's lost uh two thousand one hundred and three dollars there's fifty one thousand four hundred and sixty seven dollars um fourteen thousand dollars and these are regular defile users one of the uh one of the tiles there was for in excess of a million dollars lost due to liquidity provision and that's a problem right we cannot if my accusation against the private market makers of the world is that they are

siphoning value from you know naive market participants then how is this system any better right if we are asking users to provide decentralized liquidity because it's good for the market because it's better for the ecosystem but that they're losing value in the process then i am a hypocrite and i think that that's a problem so bank or version two sought to address both of these problems right prescribing a portfolio for a user cannot be something that we force and forcing users to take on this impermanent loss risk is also a problem so with bancor version 2 we discovered a way that you can still use the underlying amm design but split tokens up so that you can take

as much exposure to one token as you want even if it's a hundred percent one token so if you're a link marine and you only want to trade if you only want to hold link and you want all of your portfolio exposure in link you're welcome to do that and if you want your portfolio to be distributed in any way that you want to compose it bancor can support you and you can provide liquidity with it at the same time we're the only dex that still allows you to do that we also invented the concept of impermanent loss protection this is a condom we have some of the booth by the way if anyone wants to come pick up some of our marketing materials one of one of my favorite charts right now is how suspicious how many condoms you can take through customs versus how

suspicious that is something like 50 to 100 condoms is like really suspicious but like 2 000 condoms and they don't even bat an eye but we think that this is important one because decks and sex rhyme and so practicing safe decks is just something that rolls off of the tongue but i think that it also it helps to instill this idea that there is a risk right like d5 can be fun but it's also dangerous um and so you know inventing products that protect people from sort of these you know these problematic consequences is something that i think is not controversial and this is kind of just the light-hearted way of addressing it so those two things single token exposure should you want it or any

amount of portfolio composition possibilities and protection from a permanent loss is something that we've already done right our new product is building on these concepts but they were already achieved long before bancor version 3. so we just recently a few weeks ago launched our new uh version and there are some really really significant changes in the system not all of them of which i'm going to be able to describe today in terms of things like the way that smart contracts are organized and the type of new possibilities that it gives you and i'm not even going to be able to talk about everything that bangkok 3 is intended to be because of how

ambitious our our goals are with this release we've actually been forced to split it up into three different small releases and so i'm only going to talk today about phase one which is what we're currently in if anyone goes to the app and sees that there's only a few tokens for example just be reminded that we are still deploying the contracts and so we're sort of in this uh slow release mode the uh the protocol isn't 100 ready but you can definitely see it sort of starting to roll out of the gate the first feature i want to talk about is instant and permanent loss protection i said in bangkok version 2 we had already developed this insurance mechanism for those that are more financially privy in our audience one of the ways

that you can understand the cost of impermanent loss on an amm is by considering it to be essentially an american perpetual option and you can use things like volatility metrics to compute what the value of that option is over time and so using data prior to the launch of bank or version 2.1 we sort of established that during the first 30 days of liquidity provision based on data from 2017 to 2018 we can't ensure you so during that first 30 days you can withdraw whenever you want but whatever the impermanent loss is you have to wear it after that 30 day period you kind of jump up a cliff to a 30 vesting rate and then you kind of accumulate one extra percent per day of

insurance coverage up to 100 days and so this is a point of friction right from a product perspective it's problematic but from a financial perspective it made a lot of sense right this really agreed with um you know our risk assessment at the time but the data from 2017 to 2018 is horrifically out of date right cryptocurrency is maturing things aren't as volatile as they were i know that past couple of weeks that doesn't seem to be true but i promise you it is right the whole market is kind of finding this this stable equilibrium it will always be volatile but nothing like what it was back when we were first developing this mechanism and so on revision using um more uh rica more recent market history

we've actually learned that it's possible to create a system where you don't need this vesting period at all so in bangkok version three you are protected from employment loss from the first instant that you provided with the one caveat that you have to give seven days notice when you withdraw that's it so moving back from a 100 day vesting period to a seven day effective vesting period um i think is a pretty significant improvement that's a 93 reduction in the time that it takes for your your insurance to vest um and i'm really proud that that we've managed to build that out into our new release so this um you know we're calling this safe staking you'll see that a lot in our marketing materials and it's not just that vesting period that's improved

the withdrawal algorithm that actually handles the the liability of the protocol during um you know during that withdrawal um it massively improves the cost efficiency and we've also added support for other token projects to offer to cover the il themselves remember i spoke about this bootstrapping problem where you have to sell a large amount of your token in order to establish initial liquidity this is only true if you're providing both sides on bank or version 2.1 and this continues into bank or version 3 the protocol offers to bootstrap 50 of the pool for you so there is no initial cell pressure that sacrifices your token valuation as you're establishing liquidity and this has made us extremely attractive to

the the high quality token projects and the rest of ethereum we've currently accepted i think uh 35 different dow treasuries into the bankroll ecosystem and this is continuing to improve and these are established dows if you're a new dow the insurance uh risk of of um you know the impermanent loss of your token is relatively unknown and so one of the ways that you can help to offset that risk and encourage the bank or dow to support your token is to offer to recover the il yourself because this insurance you know this insurance fund is not a part of the circulating supply it's akin to being in a nurse's safe with a type of slow release schedule um in terms of optics this also helps the team because they can say that you know

some of those tokens are still locked and aren't um aren't available for um for to contribute to selling pressure so in terms of everything in permanent loss related bank or version 3 is a lot more sophisticated a lot more stable a lot more risk off we've also developed a product that we're calling the omnipool and this is kind of uh relating to the way that the smart contracts are organized but one of the consequences i'm going to explore with you right now in bangkok version 2.1 we still had discrete liquidity pools so essentially baskets of different assets that are kind of combined with b bnt tokens and because bnt is in both of those baskets you know that the ratio between those

two assets are whatever it is in b t and that means you know what the ratio is between either asset that isn't paired with b t i'll show you what this means if someone's performing a swap between 8th and chain link you can first perform a trade to bnt on one pool and then perform a trade to the other pool and because every asset on bancor is paired with b t it is the universal numerator and this means that any token is exchangeable for any other token the problem is that you have these two hops for any smart contract engineers in the audience you'll know that this will mean that there's you know two different token send requests are part of that transaction and so there's kind of an unnecessary gas consumption to the way that the

network is is arranged so with bancor version 3 rather than picture everything as being separate buckets we've kind of visualized this as more like a bnt central component a nucleus with the tokens orbiting around it and the uh you know this isn't just a like a heuristic the actual bank or version three contracts are in a single vault with bnt and that means that everything has a relationship to vnt where it currently is so you no longer have to send tokens between different liquidity pools the trader can just send a token into the vault and have the vault send that token back so rearranging this animation if someone was to uh want to swap eath for link as they did before

from the trader's perspective the ether is just sent into the vault and the link is sent back out so we actually managed to eliminate a whole token uh send transaction in the middle and that means that you get a lot more gas efficiency out of the out of the system so we call this a one hop trade whereas the other one is a two hop trade now the that gas efficiency means that we can start to use um some of uh we can start to build in other features into the protocol that would have been gas prohibitive before so with that gas budget that you now have you can now start to build in other features such as security features right things that people make people worried in d5 things like price manipulation attacks right things like flash loan

attacks and the the system that we've built and i'm going to come back to this later in the slide is generic enough that it's actually appropriate for deployment anywhere it's not specific to evm and that kind of generalization actually hasn't been achieved by any project except us the other thing that we've developed is the infinity pool now infinity pool again is a marketing term but i can describe exactly what it means on bancor version 2.1 because it's an insurance protocol we can't accept arbitrary amounts of capital right can you imagine if someone tried to provide a trillion dollars worth of ethereum that we would then be on the hook for a trillion dollars worth of il potentially maybe more so bangkok version 2.1 had a specific

cap you cannot provide more than x liquidity and the dow pre-approves that liquidity and that meant that one as a d5 protocol you're kind of nailing your foot to the floor in terms of tvl this is obviously a kpi that the rest of the industry cares about but we couldn't take on that risk right it's not enough that marketing is better because you've got more tdl the actual functioning of the protocol has to be put forth or it has to be put first in bangkok 3 though with the infinity pool design we've actually found a way that we can accept an arbitrary amount of capital an infinite amount of capital without affecting necessarily the insurance liability of the protocol and so this means that we can accept a very very large amount of liquidity and the overall risk to the protocol remains

constant this is pretty profound uh for our bank or version three release which is still in a soft launch we only have like three tokens i think the tvl at one point was already over 500 million whereas with 150 tokens on bancor version 2.1 i think the maximum that we got to was 2 billion and so if you scale that right or if we're expecting that to scale the tvl of bangkok version 3 could be absolutely breathtaking something akin to something like rv the other advantage that you get here is you further decentralize the number of people that are providing liquidity right one of the problems with capping pools is that you have fewer liquidity providers and that again goes against some of the the advantages of amms that i espoused at the beginning

of this presentation so it's not just a bigger tvl of the protocol but also a more decentralized community of liquidity providers and i think both of these things are equally important the order compounding rewards is something that i have spoken about at permissionless if anyone saw me there and that's a recording that i have online i'm going to show you just briefly one of the user-facing features for this and if anyone is interested in how this is beneficial to the industry please find me after the presentation but essentially one of the one of the ways that defy use has been incentivized is through liquidity mining rewards and how this works is you would contribute your capital to a liquidity pool and then the

token contract would issue additional tokens essentially for providing that service now on any other protocol except bank or that would mean that someone would have to sell off like a proportion of those tokens in order to buy another token to provide more liquidity with it but on banquo you can just provide the tokens as is but it's still a new transaction right that's still gas costs and on ethereum gas costs can be a controversial topic in bangkok version 3 the auto compounding rewards just require you to provide liquidity once and without any other transactions those incentives just accumulate on your position over time this also by the way has a significant tax relief benefit because every time that people were claiming those external

rewards from a contract and it was getting added to their wallet it generally triggers a taxable event but with the order compounding rewards of bank or version 3 and this is again is an institutional facing feature because that value is accumulating just on the pool token itself it's akin to capital gains which is only triggered at the time that you actually dispose of the token so from a tax perspective it's a lot more efficient and from a user perspective it's a lot less friction because there's less it's less clicky right it's less contract interactions this is generalizable so we're doing this both for the bnt community but we're also allowing external token teams to do it themselves so you can be a liquidity provider both in bnt and tkn so let's pretend i don't know chain link

providing their own rewards and both of those positions could auto compound and so again uh this is happening in in a way that you only have a single token in your wallet and that token valuation is simply appreciating over time because it's pro rider share of the liquidity of the protocol is increasing and so there's no claim there's no you know you know trying to bid up the gas price or anything like that this is all happening behind the scenes so it's much more cost efficient for for users bancor has only ever been on ethereum okay and i still think that ethereum is is the only blockchain that i that i really trust um to last forever um maybe bitcoin as well um but you know this needs to change we need to be more

pragmatic and there are a lot of really great options and our community is always investigating which one of those is likely to be the thing that best serves bangkok's mission what i want to point out here is that it's usually the case that when projects are moving from ethereum to another chain and i consider all l2's to be in other chains that it has to be something that is uh evm compatible for bank core that's absolutely not necessary the way that the contracts are designed the security modules being for example time independent means that we can deal with essentially any blockchain architecture if we want to use cairo for example on stock net or if we want to use rust on solana

anything if we substrate on polka dot any of these blockchains are appropriate and they won't affect the way that the contracts work of course we'll need to change the actual programming language but the actual internal logic that allows the protocol to do what it what it does is completely unaffected and again this is something that very very few uh protocols have ever done and i think that we're the first amm to realize that generalization and genericness um is actually a huge competitive advantage when you're dealing with a multi-chain ecosystem so bank version 3 has these features right the auto compounding rewards and again there's an industry-facing utility to this that i'm happy to describe if you want to come and talk to me after the presentation the instant and

permanent loss protection with the only caveat there's a seven day cooldown the omnipool architecture which has massive gas efficiency that allows us to better spend the gas economy in order to improve the security of the system the dual sided rewards which means that you can do this on both bnt and any token as so long as that token team supports it the genericness of the contracts and the the design which means we can go to any chain and have the same confidence that we do on ethereum and the fact that we can accept unlimited liquidity meaning that we can grow our community and grow the tvl of the protocol there is one other feature which is that to migrate from version 2.1 to version 3 after all the pools are supported will only require a single click there's no withdrawal restake or anything like that we've got a contract

that does it for you and that contract has the added benefit that you can actually migrate from any protocol to bank or version three so right out of the gates we support migration from unisort v2 sushi swap so that if you are experiencing il on those platforms and you're kind of sick right of of taking that risk there will be an option on the vanco website just say migrate my uni swap position migrate my sushi swap position and so i think that this is kind of uh you know the friendliest type of vampire attack that i think the industry has seen but i i actually think that it is it's in the the greater interest of the community right i don't feel like we are you know attacking these other protocols but supporting the users of those protocols

it's a slightly different sentiment and i want to remind you that you know i've spoken about some stuff that i hope you agree is actually pretty exciting and it's just the first phase in a way this is the stuff that we get for free with the new contract architecture the real ambition is what you can do with those contracts once they're established and this is going to take me some time right there not all of the stuff is specced out but the roadmap at least internally and where we know that bancor has to go and where we know defy has to go where we know cryptocurrency and blockchain has to go is kind of well understood and i think that we have a unique claim to air addition to that because we were also the first here no one pays attention like we do

and so i hope that you've enjoyed that presentation this is you know a really exciting time for us again if you go to the app please be reminded that the rest of the system is is coming in the next few days um but i really hope that um that you see what it is that we're trying to do and why why it's valuable and if there's anything that i can do to address any questions that you have i'm happy to take them after the talk thank you so much for your attention thank you mark this was amazing and thank you so much for giving us so much insight into this new dawn we're excited about it