Dev & Tell | DIVA Protocol
Developer DAO · 29 Apr 2022 · 29:55
Vladimir, a co-founder of DIVA Protocol with a background in financial mathematics, introduces an open and permissionless protocol for creating and settling customisable derivative assets. The talk explains derivatives with sports bets and insurance, then shows how a deposited asset splits into long and short tokens whose payoff curves are shaped by floor, inflection, gradient and cap parameters. It covers example markets, oracle-based settlement, ERC-20 positions, a preview of the app, and how builders could create prediction and insurance products on top.
Topics
From Developer DAO; community: Developer DAO.
Transcript
gm gag everybody uh welcome to what's going to be another great devontel so if you didn't know devontel is a 30 minute window for members of the dow to showcase something they're passionate about or have been working on this could be an awesome project to be working on demonstrating unit testing best practices automation goodies smart contracts how to structure a project etc basically if you've got a passion for something this is your opportunity to share with the community today i am uh going to welcome to you vladimir who and team who's going to be presenting us the diva protocol take it away vlad cool thanks a lot for the introduction and yes thanks for having us giving us the opportunity to introduce what we are
currently building um maybe some brief backgrounds uh myself um i have financial background for background in financial mathematics and worked in the financial industry for a very long time and i always had the passion for programming so i started learning solidity back in 2018 and kind of like that's how everything started yeah with a friend we actually were looking to kind of like work on a concrete project and that's how diva protocol was born and i will share uh some slides you let me know whether you see them on the screen
uh it's loading yes i can see them yeah okay so i will show a few slides and then i can also also show you like give some insights into the app that we're building that is not yet released so there might be some alpha in this call all right so so the protocol is called diva protocol and um it's an open and permissionless protocol to create and settle fully customizable derivative products so before i explain how it works i think especially for people that don't have a financial background i want to briefly explain what the derivative is and i
will make it very simple uh explain very simple terms so that's that's understandable for everyone because that's actually relevant to basically understand how it's working so what's the derivative the simplest example of or sorry one step back so a derivative like the formal definition is like it's a financial instrument that derives its payout from the outcome of an event so the simplest example is a sports bet right you have like a team so and there's an outcome team a wins or loses and there's a payout attached to each outcome so if team a wins
you you get like one dollar if they lose you get zero dollar another example is an insurance so everybody knows what the insurance is but at its core it's also a derivative it has the same concept underline so you have an event your house burns down or it doesn't and you have a payout attached to that so if the house burns down uh the insurance taker will get one dollar if it doesn't he will receive nothing so that's kind of like a very simple kind of like um introduction to derivatives now you can generalize this concept right instead of using like an event with two outcomes you can also
use a metric that has a continuous kind of like range like the bitcoin price for instance or the temperature or i don't know the gas price so that's on the event side how you can generalize that and on the payoff side um instead of having like an all or nothing pattern as you typically have in a sports bet or insurance um maybe you want to use something that goes up linearly uh the more the bitcoin price goes up so something like that for instance right and you can also use a reverse pattern that will benefit if the price goes down so it could like down is now to the left
so you could uh construct something like that and then benefit as the price of the bitcoin goes down so that's kind of like the work uh concept of a derivative and i mean as you can imagine you can kind of like build in all kinds of complexities but at its core that's what it is and maybe one thing to note about relatives when you hold the derivative say on bitcoin you don't hold the underlying asset which is bitcoin you just hold kind of like a right in the payoff that you receive that will be derived from bitcoin price so that's kind of like a brief introduction to the concept of derivatives and this brings me now to
how the web protocol works um so again like a little bit of explanation before i explain the concept to you so and the concept underlying diva protocol is referred to as asset claim decomposition so um maybe you know a long time ago people have deposited golden banks and then received kind of a claim on that gold right so whoever had that claim could go back to the bank and claim that goal so it was kind of like a one-to-one claim and like how much gold you received was completely independent of its price right
so that's basically what you see on the left hand side so your payoff was always kind of like one ounce of gold or whatever irrespective of what the underlying kind of like say the price of gold was now in geva what we do is uh it's a similar concept so you deposit an asset but instead of getting one a one to one claim you actually get two legs with directionally reversed payoffs so we will refer to them as the short and a long leg that if you combine them if you hold both of them they represent the claim on the asset say the gold that you deposited right but if you
hold them in isolation say you you sell the short one right then you are exposed either to the up or downside so that's kind of like um the basic concept that is underlying diva protocol now another feature that we have in diva protocol is here in this example i just use like a random function random linear function now maybe you want to have exotic maybe a binary one as i've shown before or maybe a combination between the linear and the binary kind of like part so what we have done is we've introduced four parameters
that govern the shape of these payoff curves so we have a parameter which is called floor which basically means okay if the price or the underlying values at or below this value the long position will get zero payout and the short position will get the maximum here one then we have the cap on the right side which is basically just to reverse so that's if the underlying price is at or above this level the long position will get the max payout and the short position will get zero and we also have like a point in between which we refer to as reflection and the gradient
which basically where you define okay at that point at that inflection point the payout of the long is equal to the gradient so in that case we chose it kind of like at 0.5 which gives you like a nice nice linear curve but you could also move it up or down and get uh like various payoff profiles we've seen the linear one but we could also just set the floor inflection cap at the same length value and have a binary one like in a sports pack or like an insurance so what this means like
these kind of like sports betting platforms or prediction mark platforms like vulgar or poly market which mainly offer these binary type of patterns it's just one uh special class of payoff patterns individual protocol and then yeah depending on how you set the parameters you see you can have like get something that looks like con convex concave or a combination between like a binary like a jump and some linear component which are the below two and two pair of profiles so that's for the long and the short is just kind of like a mirrored version of the long of the long payload
so and that's one uh feature of your protocol so we have now covered the payoff payoff part right in if you remember this this kind of like part here so we've now covered this part which is very flexible now on the event side you can basically choose everything as your underlying event so it can be the bitcoin price it can be also the eth gas price the average over the last seven days right or um also a binary event where the other was hacked or not or you can also say take the amount how much was hacked
in our protocol in 2022 and then attach a linear payout to that so you can construct really interesting products that do not exist in that form yet and so before i continue uh with the rest of the presentation i think would be interesting could be interesting for the audience to briefly have a look at the app that we are currently building and how this will eventually look like for the user um so you can define the event here so you can say okay i want to create derivative assets on the bitcoin price
and the bitcoin price end of may right that these two bills basically find your event but you could also write something else i don't know how that gets hacked right so it's pretty flexible there's kind of like like we have like a drop down list or a list of data feeds that users can choose from but it also allows you to create your very kind of like customized type of uh derivative assets right yeah that'll be done sorry was it was that the question sorry i couldn't hear it
everything good yeah i i i think the connection is pretty bad oh that doesn't mean yeah maybe they're working okay uh matt russell if you have if you don't have a question could you please mute okay so it seems to be working good now yeah yeah yeah i think i'm i'm good are you still there
yeah i'm still not really muted i muted who is music i thought you were muted because you didn't say anything but you're not muted just like i was just thinking there was a question in the background that's why you kind of like was started someone was answering their phone and um did not use themselves okay okay cool good so um then we have covered the event then the user will have to deposit an asset like in by example at the beginning it was gold but in our case it will be like an ufc 20 token so this is now a test token and then here is basically where this magic happens so you can really
kind of like customize the payoff profile to your needs so like here you see now um based on these inputs you would create a long position token that would kind of like start paying off at 60 and to reach the max at 100k bitcoin price and you have like a short position component will basically payouts you if the compressor is above 100k and the max if it stays below 60k and kind of like linear payout in between but if you don't like that you can actually change that so and that's what i've shown on the on the slide before so you can really um configure
the payoff profile according to your risk apparatus so just me personally don't like binary type of patterns because it can be slightly wrong and lose everything so what i personally prefer but that's just me right um is probably more something like that where like the payoff reduces if it drops below a certain threshold so that's kind of like covers this part that i just explained and um if i briefly go back to the presentation um are there any questions so far no
okay and so what's our vision i mean our vision is to power like uh most of the derivative protocol or most of the derivative prediction insurance type of platforms and like you could for instance as as i mentioned earlier you could rebuild ogre or poly market using diva protocol as the underlying infrastructure so you don't need to kind of like program these smart contracts yourself we will have a nice documentation where you kind of like we'll see how to execute these functions we also have some graphs where you can easily query all these data and
yeah actually build your own application on top of on top of diva protocol what you have just seen this diva app that i briefly shown that's kind of like the first app implemented using develop protocol as the underlying but it's we hope it won't be the last one and we hope people come up with great ideas and try to kind of like realize their own uh prediction market insurance platforms um maybe one word uh regarding the trading so the protocol itself it can only create
and settle themselves so settlement i can talk in a bit uh but trading is not covered so these long and short positions they're represented they're tokenized and these are erc20 tokens which means you can integrate them into any decentralized or centers infrastructure so you can either create a cool or unis on uni swap or balance or theoretically like binance or coinbase could list them and make them available to their users in our app we will be leveraging xerx protocol um which some of you may be familiar with so it's kind of like a
limit order protocol which allows to create orders off chain uh with on-chain settlement and yeah we chose the order approach because we feel uh for derivative assets there are much more dimensions you have to incorporate when you price them and that's the best way basically to achieve that and yeah the current versions of am apps which are not yet there to allow training this time so sets um yeah so here brief overview like how we are different compared to our
like or to other protocols that exist so augur for instance as i mentioned several times in the presentation so it's a prediction market they can also offer any underlying so you can also choose the weather or whatever as the event but the payoffs are limited to binary payoffs so all or nothing and there are also other protocols which are similar to opine so you basically um yeah so on the underlying side you can only choose assets that are native to ethereum so you cannot use the temperature or the gas price because you have to actually lock in one of these assets and um yeah and also the payoffs are limited to just linear structures so
and individual we kind of like have flexibility in all these areas um then one thing that is actually quite critical for your protocol is the oracle right and maybe i can briefly go back here so when we have created this asset and we are happy we can go to the next step and now someone needs to report the bitcoin price as of end of may where the temperature or the eve gas price whatever um tivo protocol was designed to be oracle agnostic so we don't force anyone to use any org so in diva protocol the auric is
actually just an address right you can just paste an address and then this will be the oracle so this address is supposed to report the final value so this can be an extern externally on the account like my account now here right so it can be a human reporter could be interesting i don't know if institutions like two banks want to create something some derivatives trade with each other and want to assign third party that they trust as the data provider and those like setup this could be interesting we and also this could be a smart contract that is equipped with some logic maybe
some dispute mechanism to basically pull the final value and report it to the smart contract so this is pretty flexible and the problem with that flexibility is that um if you're a cool creator or you want to buy these assets and you see just a random address you never know like whether this is now a random address that will never report the value right and so how we are solving that is diva token holders or the diva dao when it's uh when it goes live will maintain a white list of trusted data providers so there will be like a white list that will be maintained on the blockchain
transparent and accessible for everyone where users that users can reference when we create pools and when they when they when they want to buy these type of position tokens yeah and then so that's the last step and um basically yeah then you just have to review everything and prove it and create and then just to brief you inside how it would look like so these positions will show up you have basically the long and short position two legs right as i described before and they will show up as two separate lines on the market space so this pool creation or position uh
creation part which i just described this you only need to do one so most users will probably just come see okay i like that asset here uh if price between 2 500 and 4 000 i click here and then i want to buy it right so they they're not involved in this creation process it's more like a one-off thing that happens from time to time but most users are actually interested in kind of like training those things and this is how it will look like we are currently fine-tuning uh kind of like updating um the design and we are having a test net launch probably
in two weeks we hope if there are no unexpected issues on upcoming yeah so i think i would open up for questions i've now talked a lot so i would be curious to hear what you think guys oh this is fantastic vlad thank you so much for sharing uh i have a couple questions but i will open it to the floor we do have just about seven minutes here so does anybody in the crowd have any questions for vladimir team all right all right uh if you were still warming up uh maybe i'll get some of
mine in uh so uh you you said you were you have a financial background as well as one in mathematics like what was you and and your team's inspiration behind uh building this like what what gaps did you see out there that inspired you to create the diva protocol yeah when i started learning uh solidity uh i [Music] quickly understood that this is something you can use to build financial applications right so you don't need to ask like like regulators or like all right to build or kind of like realize your vision of a financial implication like this combination of knowing how to code
and solidity plus having the financial background or this knowledge of how to yeah basically how on the finance side i think that is what kind of like motivated me to start this project with uh with like a bunch of people and yeah it's just great it's it's just combines these two things which like i like building and find fantastic fantastic and uh i assume it's built on uh ethereum could you speak a bit on the tech stack behind behind the protocol
uh yes so the plan is um yes we will deploy a version on ethereum but we will also deploy other versions on other evm compatible chains including polygon so we expect most users to use this platform on polygon because it's much much cheaper to interact with the protocol especially if it's about like there are only small amounts involved right so the plan is actually to launch a polygon or arbitrary sidechain layer 2 solution it has not been decided yet but um yeah our goal is to kind of like make this
protocol available uh to as many users as possible so that they can realize um their visions or or their platforms insurance or prediction type of platforms feed on avalon or shipping polygon arbitrage whatever so um that's kind of like how we see it and how we strategy will be fantastic fantastic and is there any uh social media handles or anything people can follow uh you and your team's progress with or yes there is a diva protocol.i o um on twitter and
um so it's uh diva protocol dot io so that's our handle nice and also we have a discord channel so the easiest way to find it is to go on our web page and then there is a link to our discord and also to our twitter there's also an old version of the white paper attached which will be replaced by git book very soon so have a look to kind of like read the initial vision some things have changed in the meantime but uh yeah the general or the basic idea basically yeah is is the same so if you guys are
interested awesome awesome uh does anyone have a question yeah yeah exactly go for it uh can i model my own car insurance on diva your own car insurance on diva um yes i mean yeah i mean technically let me go back here something simple uh my car is broken car broken the car broken insurance brakes okay
then until end of here you can select the end of here yeah it's it's possible so your insurance company i'm sorry so your insurance company could actually create this kind of this thing here could deposit an asset and could say i don't know create something like that like a binary payout right where one will represent yes it's broken or it and zero it was not broken um and the insurance company could create this and sell you kind of like the long position so basically if it breaks you get a payout
and if it doesn't break the insurance company just can't get out the collateral that they put in plus keep the premium that they charge you or that you basically paid for buying this insurance from them so in the best case for the insurance company they can uh reclaim the capital that they put in plus keep the premium like say 50 magni tokens that you paid to purchase it so yes it's uh it's possible i mean you the only thing you have to make sure is you have an oracle that
actually reports right that your car was broken in that period so that's the only thing but if if there is like yeah i could imagine working services to uh evolve around diva protocol that will offer these kind of things will be probably some local services i could imagine but yeah technically it's possible to create these kind of things awesome great question uh we have about a minute and a bit left is there any final question questions here going once
going twice so well this was an awesome presentation vet thank you so much for for coming on devontel and and sharing sharing this project with us we'll all be uh watching and and waiting for the uh the actual release uh so we can all start uh trading away on uh diva protocol um yeah we will let you know fantastic fantastic all right uh so uh for the crowd um i will post a uh uh google sheets link um for the co-ops and uh vlad i'll also share um special speaker pro-apps for you and your team
um and with that i wish everybody a very happy friday saturday weekend and uh we will see you back here next week for another great uh installment of devontel all right and with that i will stop the recording
Related talks
- The Evolution of Onchain Derivatives
- Building Infrastructure for the Future of Finance on Top of Ethereum
- Введение в DeFi. Часть 2: деривативы, оракулы, флеш-боты 🧩 Андрей Беляков
- Demystifying Options in DeFi: A Deep Dive by Panoptic | ETHDenver 2023
- Complete Protocol Markets
- The Search for Reasonably Priced Tokens | Analyst Round Table
- Exploring the Use of Perpetual Protocols in DeFi Applications
- Rethinking Finance for a Decentralized World
- Riding the Unicorn Uniswap v3 as a Perpetual Option Primitive Guillaume Lambert
