DeFi By Design EP#43: Building DeFi from Scratch w Agoric’s Dean Tribble
29 Jul 2021 · 51:06
Andy and Robbie Klages talk with Dean Tribble of the Agoric network for DeFi by Design, exploring how Agoric departs from typical blockchain design by building around a programming language familiar to traditional developers. The conversation covers what that approach means for building DeFi applications from scratch and the tools it opens up for traders, developers, and newcomers alike.
Speakers
Topics
Transcript
[Music] d5 slate team [Music] what's up y'all real quick if you like the d5 state content on twitter and youtube and sub stack please please give us a like and a subscribe on this video on youtube and join our channel join the community we'd really appreciate it we're pumping this stuff out for you all as much as we can and we really enjoy the support and the community that we've built thank you very much enjoy guys welcome to episode 43 of the d5 by design show it's july 1st today happy canada today you know i'll have you guys know both my parents were born in canada so i feel you know we're very grounded today right so great day
um yeah d5 has gone nuts crypto's got nuts it's a it's a choppy market builders are going everywhere people are going nuts i mean not really but it's been exciting and uh we're here to talk about some recent developments in the in the blockchain development space in terms of actually building and creating applications on the blockchain what that process looks like and we have the pleasure today of speaking with dean tribble dean is a blockchain specialist i don't i'm not sure i'm gonna call an expert because he might cringe but i'm sure he's he's a self-labeled expert and yeah we're here today to learn a bit about what's going on over at agorik and how they aim to impact the d5 space what up robbie welcome to episode 43.
all right buddy yeah uh i'm doing well uh super psyched to be talking to dean and the agora team yeah um it's been a great day very productive very busy like you said july 1st happy canada day we're celebrating you today annie i'm just kidding yep let's get to it dean how's it going uh tell us a little bit about yourself and a little bit about agwork well it is going really well thank you guys for having me here this will be a lot of fun um i got into large scale secure distributed systems entirely too long ago um i worked on the first production smart contract back in 1989 um so if you count that's five years before vitalik was born um and you know it's important that that
you know blockchains predate uh sorry uh smart contracts predate blockchain by quite a bit now i've been working with our chief scientist mark miller for um a similar time period he and i met at xerox park research center where we worked on these secure distributed systems and technology that was sort of the precursor to a lot of these distributed systems that you see today including blockchain so so been working on this stuff a lot really love the stuff and for all of us it's been about you know the thing it's been about supporting computer-mediated cooperation right a smart contract is a thing that enforces a contract-like arrangement between third parties you know so paypal venmo ebay airbnb uber lyft those are all
software running on a trusted third party you know there's that word um but it's enforcing the terms of a contract like arrangement between other people and we were always very excited about that because we wanted to have computers help strangers cooperate right if you can create more cooperation if you can make cooperation cheaper and easier you get a more cooperative world and that's always been kind of the driving dream in whatever it is right you know and and if the result is you make you enable people to cooperate financially easier get more strangers involved in their business and successfully cooperating you know you get more economy you get more efficiency you get lower costs you get happier people you get people that you know
well they might not like each other but they're in business so you know what are they going to do right yeah and i'm sure you've seen a strong development and progression of that exact concept over the last 20 or so years huh oh yeah yep absolutely yes however many flame wars are inspired by people arguing on the internet the amount of cooperation that that it enables far exceeds that right i mean you know much of the trillions of dollars of our of our of our world economy is all electronic cooperation by people who may never have met yeah yeah it's amazing how much value is created and i think that's a very optimistic view which is important to have and and just really keep you driving you know
keeps you going forward can you tell us you know how you got the xerox park maybe what what happened from there and then ultimately what led you to uh agorik [Laughter] well okay it's a long journey because that was 1980s right so you um so highlights then yeah xerox park is where object-oriented programming was really promulgated so small talk was the the o programming language from which java descends from which you know uh ruby on ruby was inspired you know javascript was inspired all these things come from from from from the object-oriented model from small talk um the ui user interface of the mac
that was inspired by by the small talk user interface so a lot of stuff started from there and so you know as a as a um early you know young punk developer i really wanted to work in that stuff because it was just the coolest thing on the planet right and imagine a world with no windows and graphics and now here's a place where you can go to work on that to both you know play with it build it learn how it works um and and get something out in the world that was that was meaningful right it if you can buy and build a bunch of land currently in in the metaverse then you've got like that's it that's an analogy for what do you say that just sounds that's like like there's no there's no windows like wow right right
right you know it's a crazy time right so so um i went to i went to stanford you know great great university but mostly so i could work at xerox park which was nearby so i was an intern there um anyway um somewhere along the line uh i met mark miller we were both in a project to do large-scale distributed systems you know secure object programming and and network communications with highly pipelined high performance messaging and all that kind of stuff and so that work led into a bunch of the ideas that grew into well lots of things you see today so for example promises in javascript um you know the thing that that that people and node people in in react people in all in all these javascript applications used for asynchronous coordination you
know has a very direct lineage to that work that we did at xerox park for doing asynchronous messaging and asynchronous programming um so so a lot of interesting stuff came out of that one of those is the igork open systems paper so mark miller and eric drexler came up with a lot of these ideas out of the work out of the work we were all doing at park for that really articulated software agents creating and participating in markets and that led to a lot of the ideas that evolved into or inspired you know the the overall ideas of um of smart contracts you know nick zabo came along from a different tradition and really had that idea in his head and when he came in and saw what we had built in 89 and go what you're doing there is this smart contract that is that is the first
production one let me tell you why that's important right you know and that that kind of crystallized a bunch of those ideas of the realization that yeah having software that's in that coordinating and enforcing role is really powerful and you know and it's a different kind of business than things that had predated it where it was i'm a service i'm providing you a service you will buy the service for me and that's that's fine and useful you know compuserve but you know i'm going to sell you email and you're going to be able to do email right um or or a a enterprise rent-a-car that i can go and rent a car from enterprise and so they're running a service lets me do that that's great but it's a different set of businesses that are enabled by empowering other people to cooperate with each other
rather than just with you and then sorry go ahead you're going to say i'm on me so yeah this uh this distributed system like you're saying is a you know a way to coordinate between people um great so i didn't mean to interrupt maybe maybe you could just you know i'll add two more two or three more wrinkles here and then we'll get you know so so um we did a project for sun labs where java was was was born or near you know part of sun um to do smart contracts it was back in 1994 96 something like that where it was software contracts that were managing the selling of computational resources
inside of computers so self-processor time memory that you know things that are now you know controlled by gas if you will and learned a lot about how to be able to do that stuff and so mark then carried a lot of those i you know i i was doing parallel systems research and then large-scale production systems i went off and built broke architected brokerage information systems for schwab and and electronic checks for ibm and several of us did various disruptive technologies out into the rest of the world and markham was following the track of really driving that set of ideas forward both our security model and how to be able to do smart contracts how to be able to do interesting economic cooperation um inside of normal programming languages you know there's lots of ways you could do special dsls or or funky weird languages
um you know to be able to do this stuff but to reach millions of developers you need to be able to do this in in languages that millions of developers programming so we both drove things into um uh into programming languages you know java c sharp you know c plus plus tickle everything else um and um uh and looked at what were the tools needed to do it what would you like in a programming language for it and so forth so markham came up with the e-programming language you know i was going off in building systems using the architecture for for for enterprise he then jumped to google where um they they started the kaha project which was take those ideas that had been
evolved in the e-programming language where financial cryptography there are several papers that he has about here's how to do you know a um essentially an atomic swap in a pro in a normal programming language here's how to do uh secure auction and normal normal programming like and they took those ideas of how to be able to do all that sort of stuff securely with components and started driving those solutions into javascript so javascript was a you know security disaster you know you know long ago where many of the elements like strict mode and proxies and promises and all those things were driven into that with you know
cooperation of brendan the guy who created this thing and many others but markham was one of the key forces driving those features into javascript so that the javascript you use in web 2 the javascript you use in web3 all of those have mechanisms so you can actually build secure systems um and so you know and then and then i went and took a bunch of these ideas over into um a research operating system at microsoft called midori where we made sure we can do this stuff for very high performance very high scale systems okay so that would you know went off and did a payment instrument and got back into cryptocurrencies but um somewhere along the way i'll skip the steps where we were cypherpunks and doing crypto stuff you know back in the the early 90s with with with all of the
all of the all of the gang of other ogs but um uh so we'll skip a few steps here come 2018 2018 2017 right um there had been all this crypto d5 and i was doing you know payments for traditional banks which now turned into a multi-billion dollar payment instrument that was lovely so i wasn't deep inside of the blockchain space at that time and there were all these security breaches and we had worked with zuko of zcash zuko uh wilcox and others in the crypto space because you know we've been doing crypto stuff for a long time and so uh they saw all these security breaches whether it was the dow
uh hack or the the the the reentrancy lockup of all the parity dollars or what have you for the the parody ethereum you know all these things and we're looking at that and going and zuko sort of asked the question these guys know a different way of doing security they've been doing this stuff for a long time do they have answers to some of these problems and so there was a panel in 2017 that had um uh zuko markham uh arthur breitman from from tezos uh brian warner who had just been working on the security review for ethereum um uh uh uh jorge whose last name i will never pronounce correctly um from from from what was called the
gravity project at the time and it was about applying our techno our security technology called object oriented security so object capability systems to blockchain and was there a marriage right and we got you know a lot of people who have been doing this this this um high security architecture because it's used in insecure os's we got a lot of them together and we got some blockchain people together and we did this panel and it happened to fall just as tezos was doing their sale and so sort of from the beginning of the panel or the beginning of the point where where arthur was speaking to the end of the point where arthur was speaking they raised another 20 million dollars in their public sales so sort of a funny timing to have this all happen but um but the outcome of that was oh my god this
is a real solution to some of these problems we should really do something about that and so you know zuko helped pull together the company and thus agorax was born or gork was born um and so it then took a while to get it all together but we had brian as our lead crypto engineer just you know fresh off of doing he had done uh ocap stuff so our model inside of large-scale you know storage systems he'd worked with zuko on zero knowledge stuff he was an advisor to z cash and he had just participated in the security view for ethereum where he had identified the reentrancy bug that several people have were have been bit by since that they didn't fix but it was identified in that security review by bryant right so so we had a we had we had we had um bill
tullow who was one of the economists that we had worked with on other on other uh endeavors and smart contract stuff prior to that to help with the the economic stuff and so that was sort of the the technical crew that got this started that had the spectrum from you know software management you know oh system security crypto and and economics and that was the nucleus that we formed formed to gork around 2018 so it wasn't until 2017 that you had really merged the object-oriented systems that you had you know worked on for 30 years not until 2017 did you did you bring that over to crypto and start to merge with some of the smart contract technology that zuko
brian and some of these other guys were working on right yeah yeah interesting i mean the smart contract technology that i care a lot about is the stuff that was in the of things the thing that blockchain brings and the way it interfaces to smart contracts really is it brings high integrity execution right you've got hundreds or thousands of machines voting on what happened they're all in different administrative domains they're all in different jurisdictions so no one can compromise enough of them to matter and what that means is you can really rely on them to execute correctly and execute the code that you intended and what that does it lets you get rid of that trusted middleman right you know that trusted third party that is ebay that's going to do your auction well now i don't need them right i can have the software do that
and that takes a big cost out of the middle and it takes a big opportunity for someone to cheat out of the middle is that unique unique of oos or smart contracts or or does one of them have it and one of them don't um no that's that's really that that that edition of you know there's what does a smart contract do for you that's true of any smart contract that's the whole point and then what blockchain adds to it is being able to execute that directly without a third party that is you know that's independent of our security model that's just fundamentally what that what that synergistic marriage of those two does is it lets you now run smart contracts to enable cooperation you know how good that is depends on the architecture your smart contracts but run whatever you chose to do on a
platform that no one can compromise and those that's really the that's really the magic that makes smart contracts on blockchain power now you know it's important to realize bitcoin is a smart contract right it's software running on a platform that orchestrates a contract-like relationship between parties where that contract-like relationship is primarily you know i'll send you this money right or you know i will make this money available to anyone who can satisfy these conditions and that's now enforced by the software it's no longer up to me i told the software it's going to enforce those terms that's a smart contract it's just a very specific one ethereum added hey we're going to write it so third parties can submit these contracts and run them and that's an awesome step forward because now multiple people could add multiple smart contracts on the same
platform and run with the high integrity that you didn't have um uh uh prior to prior to ethereum and prior to blockchain and so those are those are huge step forwards steps forward now the question is that model of smart contracts you're running does it have the power you need does it have security hazards that are that are that are too easy to step into and you know the whole power of agorak is it's a platform that that you know has the power you need is programmable in a language people understand and avoid the security hazards uh that that are endemic to to to ethereum and as a result we we end up with a model that is a lot more programmable to a lot more programmers and you know if you're going to take
over the economy with all this stuff you it takes more than you know the people in this room or takes more than the 10 000 developers that can maybe write a decent contract on solidity it takes the millions of programmers that do financial stuff right now pretty much they all know javascript right so you know 10 million programmers know javascript i can write we can have smart contracts that are readable to pretty much all of them and readable to new programmers with you know three three or four months of training and that's the way that's what you need in order for this to get bigger legs and that just that just pushes the coordination to just a whole other level right you got the one-two punch of the smart contracts and the blockchain and then now if you if if we can create the thing that
i think the entire space is missing which is basically just like ease of use like earlier today we were speaking about the ui experience right you know as these prices are down everyone's like all right what can we nitpick to fix right but that's how building happens right and so now it's like okay if we can get the one of the biggest programming languages in the world known to mankind onto what we're trying to accomplish in terms of decentralized systems then we've got you know a bigger a bigger bowl to like choose from effectively in terms of innovation that speeds it up so i'm curious how you see the impact of bringing javascript to the blockchain if you will or to like the d5 scene absolutely impact the overall coordination of the space and
of of of the industry how do you see it affecting me right yeah so let me i'll make a javascript analogy for for for user interfaces in javascript so 15 years ago developers could struggle to build kind of cool uis in javascript now the language has certainly changed since then but not sort of in some fundamental way you know it's got dom compatibility back to the to the dawn of time right um uh and now a beginner with relatively little training can make an application that is responsive internationalized flashy graphics works on multiple devices including including mobile phones and looks better and feels better than what an expert could do 15 years ago
and the reason is not because the language is different it's not here's javascript knock yourself out the reason is because there are frameworks in which there are a definition of components so let's take react.js in particular but vue and angular and several others still you know recent frameworks have the same properties where i can define where there's a defined way that components are built and plugged together in a framework that will use them and that provides affordances for doing um uh user interface interaction so it knows how it knows that help rendering it's got support for styles it's got interactivity it's got you know all of the the the gesture stuff
formalizes events so it's easy to program those events and then there's patterns to follow to be able to build these things and that's what we call a real compositional model people in crypto have been talking about composition that's what real composition is it's where i can take a component built by someone else parameterize it a little bit plug it in and use it as is right and that means a beginner can take a slideshow and take a library from stripe and add a little bit of code and now they've got something that's selling their images and you know that's that's accessible to a programmer you know someone who's got a little bit of programming and is otherwise an artist and now they've got a site that's selling their images right and they couldn't build a slideshow or build a stripe thing yes
is this level of composability out of scope for solidity and ethereum or is it just simply that the the skill learning curve is not there yet so it is so so in general composition on solidity is so hard that all of the cases where it happens are really notable right you know a lot people we like to talk about you know uh uh compounds governance contract being used by uniswap to produce the uni thing which was a huge success we don't like to talk about the fact that dforce did the same thing and lost 25 million dollars right code copying is not a good way to do composition and the security model of ethereum fundamentally obstructs this ability to easily plug together components i don't i don't when i'm building my ui
and plugging in a slideshow it doesn't ask so which user is doing this are they allowed to see this image i don't know right you know instead i go here's the slideshow here's the image do it right and there's no questions it you know it can only show the slides i gave it and it can show exactly the slides i gave it and it can show them in the screen area i gave it and that's it right that's that's that's the model right and that model of components that can plug together is really really powerful and the security model of ethereum gets in the way of that whole you know the details kind of don't matter but but people have tried lots and lots of things and they keep adding epicycles and it keeps getting more complicated and you know it adds performance it adds
gas and it doesn't solve the problem and a fair answer for why one would choose to basically use a different set of code and parameters than on the salinity blockchain however and then we have to understand here please oh i'll just say and so people do composition right you know no question ethereum is hugely valuable it's just really painful and expensive and it's and it's in the currency it's very current right so it's like what is d5 it is ethereum that's right that's right well i don't know so cosmos is getting a lot of deficits on this show we're kind of like all right let's be real it's ethereum but that's right we're not absolutely you know a multi-chain world is is gonna be inevitable all right and all
these things are gonna come into this uh all these all these factors which you spoke of are gonna come into the picture um you know and there's different little rules and parameters and and sets and things and and everything really for each chain um so in particular for how how the javascript blockchain will work how will um i guess in the in the most technically sound way which you can describe um but also easy uh how will the javascript ask blockchains uh create and validate transactions and and how will the node infrastructure look okay um so um so fundamentally you know whereas on ethereum you're running an evm and it's running a particular
instruction set we're running a javascript machine on every node now our technology we have we have a a a security technology called cess that lets us lock down javascript so you know people sort of have this this this racial memory of javascript as being insecure and that's because it's malleable right it turns out it's really valuable to have a system that can evolve where i can change what array iteration does what array four each does it's not so great if i can change array for each to iterate all of your information go open a file that has your secrets and send them off to another country right that's not so great right so you know so in some sense building systems on on on javascript right now is like building on quicksand and what our lockdown does is it really turns that
into concrete so it locks what all those primordial objects are and so as an accident of history javascript is actually more securable than most other programming languages we locked down the world and now we can run confined programs in arbitrary javascript arbitrarily malicious javascript inside of a compartment where it cannot get out right and this is all based on secure os technology architecture from secure s technology we understand that very deeply we've done it in multiple systems and it's a really awesome awesome technology right and so so and it's used in salesforce app exchange it's used in brokerage terminals the next generation of metamask uh wallet will be using it for its extension module right it is this is a technology lots of people have looked at parts of it are in uh the node security
architecture it's changing how modules would be done in javascript and so forth and so that that lets us run a safe programs in javascript okay so then every validator node right and this is a proof of stake uh network we're building a proof of state network on top using cosmos sdk so it's tendermint underneath for consensus and then we run our stack on top of that so every validator node is running a javascript engine that for every smart contract that's running it's running that contract in one of these confined boxes and conceptually it just stays up and keeps running and just runs in memory right now there's a lot of magic so that that's what happens conceptually but in fact if it crashes it'll come back up in a few seconds and
keep going you know it's storing it out to disc because you know okay and so at the same time we can lock down that execution so you can't escape the box we can make it so that it's deterministic so we're really running is deterministic javascript so that once tendermint has accepted a transaction now um uh all of the all of the validators will execute that transaction the the message that comes in like bid a thousand quad lose in this auction and it will execute them the same come up with the same answer to take a thousand quad lose out of my account and put it in the auctioneers account and decide the same thing at the end of the block and so what that means is a machine crashes i mean conceptually
you can just you know get back to exactly the same state and anyone anyone can look at a block and go what happened there and they can just start the block at beginning run the messages debug them in a normal debugger inspect what all the variables are in javascript and get the same answer as the as the chain got in order to see what happened right and so that's sort of the the computational model and so what that means is every block is is these messages were delivered we have an initial state we compute a new state you know and a set of messages to be delivered the next block and we're off to the races and that's your blockchain and so you call this a deterministic blockchain yes absolutely absolutely yeah so in order to have you know independent computers running uh the you know run
running running the same smart computation and being able to check each other's work it's got to be deterministic so they come to the same answer and so you know ethereum's model is deterministic cosmos is deterministic that's deterministic you know but we managed to be able to bring exactly the required determinism without having to write a special programming language that has that characteristic we were able to bring it to one that people already understand and so being able to bring that to the javascript was part of the the coup of what we managed to do here yeah yeah and you know you called it coup i i was gonna call it secret sauce like what what is the special you know twist that you put on a blockchain that makes it different and just better than you know the unique advantages over over uh
other blockchains that are out here what you know what is your secret sauce okay so well there are so there are two levels of this right there's the execution model and then there's the economy we're building at the execution at the execution model level it is that security model of object capability security where where you know there's a lot of theory about it secure operating systems were built on this design scl4 you know the most secure os's on the planet were built this way but and there's lots of detail to getting it right in an operating system and you know like our you know underneath we have the gorick vm is essentially an operating system there's a lot of tricks to getting it right in a network protocol but fundamentally at a programming level it just shows up as object-oriented programming so i've got a concert ticket
object i've got a reference um to andy i can say andy.enjoy concert ticket you know that's a javascript one-line sentence there you go and now my concert ticket is handed to the object that andy gave me to deliver the concert to get into his inbox and that's it right i have the object i handed to him it's just like i give him my car by handing him my car keys he gives it back by handing them back very simple to understand actions that i trend you know transitions that i take are automatically changing who's authorized to do what without it having to be okay i need to add him to the list that's authorized to drive my car and when he gets to the hotel he can't he's not in a position to add the valet so oops he's got to park his own car
right so that model i mean we've got lots of presentations that go into it that model is what enables the kind of composition that developers are used to when they're building node.js applications when they're building uh react.js applications and so forth it's the thing that really has the leverage where i mean literally you get to build on you know what is it not literally you get to build on the shoulders of other developers so literally it leads to the exponential growth of components in the exponential ability to rapidly build new new d5 applications or new new new depths and and that exponential growth is is is what we believe will overtake the development speed on other platforms simply because they're not in a position
to be able to reuse components in the same way and that's a huge lever point it's the reason why you know reactant frameworks like that took over the world of doing user interface into javascript it's the reason why node.js was across a billion downloads a couple of years ago right because people use it for doing large-scale network systems and so forth and so it's a huge lever point so that's a big comparative advantage now we give away a lot of that technology but it's integrated into our chain and we understand that model in a way that others don't and so we help people use that model for other things but our focus is our public chain and that's the execution layer yeah and you know now that that's part one it and is there a whole other layer to like this economy layer
you know that brings up more value yep absolutely so the the other so so there are two more layers that are that are important one is is our smart contract layer and then the second is what we do with it which is our economy um we refer to it as zoe um uh if anyone's seen firefly no it doesn't refer to that zoe at all no no um but um but it is a framework for doing smart contracts where you mention the the the horrors of of um user interfaces in in in current crypto ecosystem i characterize that as send money to a random number and hope something good happens right you know you you go through all this lovely ui and then you push a button to swap and it says you know transfer you know 4 eth to 0x
99532 and i have no idea um so for us instead the intrinsic model of smart contracts is i make offers to them right there's a quid pro quo i give an offer of uh you know i will offer you um god i don't know the prices right you know i will offer you um 300 usdc how's that for for that particular concert ticket and now i've contributed my 300 usdc to the contract but it's not available to the contract unless the contract provides the concert ticket and so the contract infrastructure is enforcing that what i give you you only get if i get what i want and it's like a permission
thing it's like it's like giving granting the permission um that when both objects are present that's when the switches have the switch is made right it's it's um what the financial industry calls delivery versus payment um where where i'm saying i'll give you this but it's going to be escrowed by the contract system until you provide the other thing and then you know the seller on the other side is doing the same thing i'll give you this concert ticket if i can get 250 bucks right and and now we both presented that to a smart contract in the middle that's running an order book and it goes you two let me reallocate your money to him and his ticket to you and now bam the sale the sale consummates and everyone everyone goes away
happy but an important thing about this is it's what we call offer safety no bug in that intermediate contract can cause me to lose my money unless i get my concert ticket and vice versa right and no bug in that intermediate contract whether it's malicious or accidental no bug can lock up my money indefinitely i have exit uh uh assurance so that so that i would call exit exit liveness where or payout license that's what it is i will get my payout so if i say give me my money back nothing the contract can do can stop it from rescinding my offer and getting my money back right so so the level of economic safety this provides and also as a as a contract developer the safety it provides me where i can't
accidentally have a bug that steals everybody's money that's just a huge huge value right it's just a vast reduction in the overall risk of uninteresting bugs i'm perfectly happy for people to deal in economic risk where they're playing interesting games in finance but having been subject to computational risk that's that's terrible right yeah yeah so you can still you can still be rug pulled right you know there's still economical risk someone pulls their liquidity and and you can't swap out and cash out but like you're saying there's no computational risk of a of a bug malicious or otherwise that just happens to be an error in the code and and you can't have a rug that just leaves my money stuck you know if you have an escape with my money i can get a
back guarantee you know if i see that happening and now it's now you know a race to it's a race to the line to get my money back but nothing the program can do can stop me from getting my money back if it's still there have you called good old the owner of the mavs mark cuban about that one i think he's interested i think he got rugged on iron that's right that's right yep parody right the reentrancy bug of parody you know that that that's an example of a bug that simply should never have happened that should you know we like safety properties where it's stuff that never should be possible programmers shouldn't be expressed able to express certain kinds of issues reentrancy is one of those so there was no hacker and that in that um parody loss it was just a drain of funds that kind of ended up in
the in the ecosphere it was that it was that a someone actually broke it whether it was a hacker or accidental who knows right but the result is there's a bunch of money locked up by the contract that no one's in a position to pull out which means they don't have payout liveness they aren't able to get their payouts it's clearly their money well except by virtue of the code no clearly it's not because they can't do anything with it so you know what does it mean to possess it right um so okay so that's at the smart contract layer at the economy layer so so our mantra is build fast earn fast right being able to build in javascript being able to build with other people's components being able to build with with you know some of the best development tools on
the planet vs code webstorm etc and use standard ci and development practices and all the javascript static analysis tools and you know get types from typescript and all those kinds of things and all the literally millions of libraries out there inside of your smart contracts that gets you the build fast part but the urn fast requires a place to deploy this stuff obviously you know the main place for deploying d5 right now is ethereum it's you know six months ago i would have said it was the only place right but now with with with the advent of ibc the inter blockchain communication protocol we've already seen multiple networks starting in the cosmos ecosystem where they start connected to each other so you know osmosis launched and people brought adams over and invested it immediately right
and so it was you know was garnering 10 million dollars a day in additional capital now i realize that's small potatoes compared to the the defy central of of of ethereum but all new you know all new oak trees start from an acorn right and and and this really is a very important shift that that agorak will will will take advantage of which is when we deploy our chain when we go public when the when the public chain launches it will launch not in a vacuum right it will launch connected to tens of billions of dollars on and cosmos terra cetera right you know all these all these these um uh ibc connected chains okay so it's kind of being a place but it's not quite there yet because because you know you you can launch a
chain but you can't just deploy a smart contract so we are producing that smart contract layer where it's the market right it's it's an economy and it has the ingredients so that you aren't just saying you know here's a programming language knock yourself out or even here's a framework knock yourself out it's here's a place where once you build it you can go and deploy it and have there be money have there be uh you know stable currency so that you know everything's priced in the same terms so a customer coming can go do i want to buy that hedge you know and versus that insurance product right and i don't want to be going and that one's for quality and that one's 23 simoleons is which one's higher i don't know i've got to do currency exchange in my head that's crazy you can clearly make an
economy work that way but it's expensive it's sand in the gears it means it means evolution it means innovation is harder and so we have is a stable local currency called run so it uses a a cdp style model of alt-style model but it's intrinsic to the economy right it it's it's it's backed at the end of the day by the underlying staking token the the cryptocurrency stable local currency is what contracts will use to pay gas so gas is now charged in in you know you you can compare its cost from day to day because it's charged in a stable coin right and it's the glue that or it's the grease that makes trading and pricing across these different contracts easy then we have a native amm that when you know it's an asynchronous
system it can wake up in in response to pricing events instead of waiting for someone outside to go oh the price changed right um and so when the when the vault notices that some some vault is underwater it can wake up and turn around and proactively sell it on the local amm or rate limit and have it sell incrementally over time so there's time for arbitrage out to to gravity decks or osmosis or thor chain or whatever to be able to dip into those other liquidity pools in order to make sure that the current that the price stays you know reasonably constant not just on the chain but over the overall uh interchange ecosystem right and so that's what we're building is a place where you get all those services and where it's easy to be able to integrate and compare multiple
businesses and that means that you can add new little businesses right you can add something that all it does is stop loss on an amm and it's you know 20 30 40 lines of javascript that anyone could understand and now it's a business and i can deploy it i can deploy it on top of an existing economic model right i can build a business where you know new defy thing where it needs liquidation but i'm not a liquidation specialist i'm going to grab the same liquidation the underlying engine uses i'm going to grab the governance implementation you know exactly component right npm install chain governance right but instead of using the the underlying build token bld is our staking token instead of using that i'm going to use my liquidity token and i don't have to do that by changing the software i just do it by instantiating
it with a parameter that says you know vote based on my token rather than his token and that means i'm using a battle-tested hardened reviewed insurable component plugged into my thing and i get to focus on just my business and and deploy something fast um and in order to start making money based on my comparative value in that economy too that's already created as you you as a developer entrepreneur or just person in general trying to go and create too now i know this strikes a thing with rob and i because we've had thoughts about okay i want to learn this language and and build this you know one big thing that you actually hit on was like a liquidation bot like that just sounds sounds awesome in in terms of profitability morality and such you know
we can get into in the into the philosophical later right but the point is that ability to get up go build in a short amount of time is key now i kind of want to turn the convo over to the intricacies of the d5 economy right so we've got all these fungible tokens and all these pools of liquidity as you're saying so right you can go and trade on an amm you you can deposit into this protocol you can trade options on this so a lot of the financial characteristics that you're explaining in this economy are created now where do the concept of non-fungible tokens fit into this d5 world that that you explain right so obviously there's we understand what those are for those who are new to nfts what what a non-fungible token is is
effectively it's a token that cannot be easily replicated if you will now i'm going to let dean give give a more you know tech technical explanation but effectively one bitcoin is one bitcoin but my house is not your house right and so that's kind of like the idea so uh i'll let dean explain nfts and perhaps a little bit of insight into why it is early but how they could fit into this idea of your economy okay so a big part of this is you know i talked about zoe the contract layer there's a there's a thing we call electronic resource electronic rights transfer protocol which is an api for generally being able to talk about digital assets that includes fungible assets and non-fungible assets so
so fungible non-fungible assets are intrinsic to our system all of these abstractions whether it's escrow whether it's the zoe contracts whether it's the auction contract it can be auctioning off you know fungible you know uh uh eath from a liquidation um that's pegged across ibc and over the gravity bridge to ethereum or it could be auctioning off a cryptokitty right it's exactly the same kind of asset and that same tiny little javascript program that i could explain to a beginning programmer it works across native tokens synthesize tokens locally nfts created you know fungible tokens remoted tokens bridge tokens over over pegging networks all of those things can work uniformly and that's one of those advantages of
having for example taken a synchrony as a as sort of a fundamental reality reality of the world that the the decentralized world the world you know is is islands of synchronous um uh computation in a sea of asynchronous communication you know all of that all of that model i talked about doing escrow i can deposit something where in order for it to get escrowed there'll be asynchronous communication to bring it all over and lock it up so now the smart contract knows that the offer has good funds that are locally available and so adding an nft in our system well you know it's two lines of code right there's an example of that we that we go through of you know taking a loan where we transfer money we transfer
eth through the gravity bridge over ibc onto our chain create a vault take a look loan against it in stable coin to the mark go off to the uh baseball card store and buy an nft baseball card and all of those are written in javascript all of those are reusable components and they're all straightforward for for for people to to build apps with and so being able to add new nfts piece of cake and all of these abstractions work with it if you want to if if someone wants to end up creating a loan instrument where you can take loans against against nfts that's just instantiate our vault mechanism tell it here these these issuers are ones that you should that you should uh uh you take um be willing to accept here's the oracle for them it follows the same oracle thing
um and it may actually you know and and you know may plum into like chain link oracles that go off to markets and see what those nfts are trading for and now the same vault thing will let you take a loan against an nft and so a lot of these mechanisms all exist yeah and the and the ease of use that you're explaining and the practicality you know it makes me it makes me think that you are pretty confident in the ability and the longevity of nfts in the decentralized kind of absolute world yeah yeah no i think you're just saying to me nfts have just barely started you know i mean right now the the easy ones people talk about are basically autographs right um where where the autographed copy of some digital image is more valuable the more people have seen the digital image um
you know and and and uh but but the whole uh evolution where it gets into i've got an assurance that i that i'm part of some experience right you know like a musician that shows a qr code that everyone that sees their first live performance of this song can scan that qr code and forever forever be able to show that they were there because it's got a geo you know geo positioning thing using some other crypto uh mechanisms in it and that lets them download and play that song whenever they want or or you know or or lets them share in the ongoing revenue of that song or whatever it is that the the you know it gives a a hook to be able to get ever increasing engagement and that's one of those things where
going forward that's a place where i expect a lot of innovation right you know because it's not just autographs it's not just this fad thing it really is this this this mechanic for for engagement of stuff created with participants that want to consume it or creators with the people that consume it or what have you that's just a powerful way that people cooperate orchestrating cooperation is what what smart contracts are all about and this is an area where i expect a lot of innovation and so being able to build fast and deploy and learn fast is is kind of crucial and the other thing is all those people out there that do these sexy awesome graphics gaming music all those sites yeah they know javascript you know or they can know because if you
can build an application in web 2 you can build the decentralized one in web three right and you know on agora and so so those people are welcome and a quick one here what are um two or three applications of nfts that you think are perhaps a little far-fetched but could could work um well so so we've seen several right you know trade collectible trading cards you know i like finding ones that are far-fetched is hard right because you know i mean that one's got you know i don't know whether it's quite got product market fit but it's really close there's clearly a thing there right and um uh um so so that's that's a valuable one um digital collectibles of real artists and
in particular of uh performance art that is otherwise not collectible that's you know that seems like it will have legs because you know because there's a lot of you know people want to consume that there's a lot of drive for the artist to be able to produce it and they've had trouble monetizing well one of the things that crypto has done is found very new great ways to monetize stuff that that that would be underserved because it was a public good right it's monitored it's been able to monetize open source software in a way that no one was able to do heretofore being able to monetize performance art you know more power to them so that's it that's a that's a huge one and and that extends into music and just vast amounts of of participation there so i think there's a lot of legs ownership big time
yeah yeah yep yep well and participation as i said engagement right and it might be that you're going to put on a concert you're going to produce a song i'm a fan i want to help promote it i want to get people there and as a result i get a very teeny share of the bar tab right you know i actually might actually economically participate in helping to promote the thing that i want to do and love right i mean people i mean you know all the things that people do to participate in gaming with twitch and discord and all those sorts of stuff you know that's that's uh tens of billions of dollars in in consumed value by by by lots of people there so yeah the business applications of nfcs are are certainly an aspect of it um and and just points to the eco the
economy layer um above the execution later that layer that you mentioned um so and you know the most attractive thing one of the most attractive things of the type of system that you describe is the composability um and you know kind of these plug-and-play lightweight type of modules that that you can just combine right um what is the integration what is your vision of the integration as you can continue to build this out you know is there going to be um d5 legos of a curve you know that are built on ethereum now just deploying on agorik or is it going to be brand new applications that are built on top of agorik um and you know does it happen right away or does it take some time
you know right so so i'm going to give you a very quick answer and then i want to point out agorak is hiring and i've got an interview in one minute so so so unfortunately we have to wrap up and i'm happy to come back and talk some more i mean you know we start with a native amm based on you know on you know similar kind of technology we start with a native vault mechanism but we expect you know some of those people to come build their equivalent business on our system because they understand the business our goal is to promote a large growing economy you know not to be you know we're not trying to be the compound i'd be delighted if compound came and built on our stuff you know i'd be you know delighted but less so if all we do is we bridge over
to their chain and and the two interoperate that way using ibc um and and if someone else comes and builds what compound does on our system you know using a different name that'd be great right so i expect a lot of these things to be built and build on each other and use components um on on our platform and so the thing is you know the stuff that people suffer over to get to get this stuff done in solidity you know we know it's four to five times faster to build the same thing in javascript even before you take into account security reviews and availability of programmers and all that sort of stuff and so reproducing a lot of that stuff you know it's we're really at the beginning of all these things i'm not afraid of how much people have built there because frankly they you know they it's
amazing stuff it's wonderful and we still haven't gotten very far so so i'm excited about what that future holds so well we appreciate you dean uh we won't let you be late for your interview so take it easy uh super excited to talk anytime more that you have so thanks for coming on thank you for having me and we'll talk soon bye smart guy [ __ ] got hit by an earthquake that guy wow an earthquake [ __ ] yeah yeah that guy
knew what the [ __ ] he was talking about i'm saying stop by recording why don't you yeah it's been stopped all right file export and p3 oh the zoom