#222 Amir Bandeali & Will Warren: 0x Protocol and the Decentralized Exchange Frontier

16 Feb 2018 · 1:15:36

0x Protocol co-founders Amir Bandeali and Will Warren join Epicenter to discuss building one of the earliest and most widely adopted decentralized exchange protocols on Ethereum. They cover why 0x custody stays with users rather than an exchange, the architecture and role of relayers in its economy, the ZRX token, and how the protocol's governance process works.

Speakers

Topics

Transcript

[Music] hello and welcome to episode of the show which talks about technologies projects and startups and identification in the gourville blockchain revolution my name is Brian Fabian crane and I'm a hero today we are gonna talk on the topic of decentralized exchange with will Warren and Amir Banda Ali were the cofounders of the zero X project zero X zero X project had a very successful token say

last year and followed that successful sale with really good releases on their technology and development of their community villain Amir welcome to the show thanks for having us pleasure to be here yeah thank you very excited so I should actually also make a disclaimer right now because I did participate in this token sale so I am not unbiased all right we start disclaimer let's get into your background will tell us how you ended up starting this project yeah absolutely so I initially became interested in Bitcoin around 2011 I was in the

investment club at UC San Diego I wasn't you know my background is not in kind of investing or anything like that I was studying engineering and I think I came across an article about Bitcoin on Hacker News or something like that I thought it was interesting technology there weren't really any use cases for a Bitcoin at the time except like Silk Road but I thought it was really interesting technology and kept an eye on it my my wife then girlfriend also a thought Bitcoin was really interesting and once coinbase kind of legitimized the the technology and the use cases by

partnering with overstock she left you know New York she was doing finance in New York she left the joint coinbase pretty early on and when she joined coinbase you know it I kind of became a much more interested in cryptocurrency and was you know keeping up with it much more closely but I was kind of on a research track I was doing you know I was kind of planning to do research for my career either in academia or an industry I was I was in grad school studying engineering but when aetherium came out it struck me as like the most important invention

since the Internet and I really quickly lost interest in everything else and basically decided to drop out of grad school to focus on a theory in full time and so when I was what I was focusing on back and this was back in June of 2016 when I was focusing on back then was creating essentially a standard for tokenized derivatives and the rationale for that was that you know cryptocurrencies are extremely volatile assets and it makes it makes cryptocurrencies not that useful for quite a few different use cases and I

felt like you know derivatives would provide the ability to hedge against this volatility and that that felt like an important thing to work on so kind of got pretty far along building out that project and that's about the time I met Amir in San Francisco and so so we were Amir and I were focused on kind of you know how do we take this technology and bring it to market and what we realized is that tokenized derivatives are not very useful if there's no art to exchange them and so this you know Amir and I met and we started working together formally

in October of 2016 and back then you know ether Delta wasn't a thing no there were no decentralized exchanges that people were using at the time you know so we basically decided okay you know if no one else is gonna build this infrastructure no one's gonna you know if no one else is gonna work on this and you know someone needs to do it so might as well be us so I just want to kind of ask here so you said when you discover the theorem so you knew about big point like we were kind of following Bitcoin but then when you discover the theorem or any human came about you felt like oh that was the most important thing since the internet like why dad reactions we hear him

yeah I think it's because you know I've been following Bitcoin for a long time you know the technology a completely open and globally accessible ledger for payments is really compelling but you know this I think this is our own like you know late 2015 early 2016 you know Bitcoin was chugging along it was doing fine doing payments but there was also a lot of like infighting in the community and you know it seemed like not much innovation was occurring people were talking about layer 2 solutions and stuff like that but you know at the end

of the day it's really just a network for payments which is incredibly valuable but you know aetherium you know held the promise for you know basically you know an infinite number of different use cases and it just you know it felt like something completely different yes a little bit about my background to have a background in trading I was a traitor for about five years first at a company called chopper trading in Chicago and then later drw got into Bitcoin I think it was 2014 right around the first run-up and initially it was

mostly from the the trading angle just you know watching these crazy price moves but I started learning more and more about the technology became a pretty big believer in Bitcoin and then learned about aetherium in early 2016 started getting more into the technical aspects of things and ended up meeting will through a mutual friend and I knew he had just recently dropped out to work on this derivatives project and decided to join will in San Francisco to work on that so Amir when I look at your LinkedIn profile the the thing that

stands out and jumps out is like your educational background is is not in computer science its finance and then you work for five years as a trader yet you you are the chief technical officer of 0x tell us like did you go through a phase where you transition like you changed your field from like traditional finance to cryptocurrency but did you have to spend a lot of time to build a completely new skill set in order to do this so it wasn't completely new to me I was monitoring in computer science in college also you know I ended up not completing the minor because I I just got a job and graduated a year early but

yeah I've been kind of coding along the way did some like data analysis and stuff like that when when I was trading but yeah I had to had to definitely build it up over the years I think in the crypto space there are very few experts or at least back then so when I started learning about it it's kind of on a more even playing field with with everyone else and I've just been you know really deeply diving into the text and son so super interesting perhaps you can start with discussing decentralized exchanges in general tell us what is a decentralized exchange yeah I like I

think first of all like before we discuss what is a decentralized exchange is probably first important to discuss what is a centralized exchange and like what exactly are the implications of having an exchange that is centralized and trades cryptocurrencies so a centralized exchange is you know in some ways the backend infrastructure or at least the blockchain infrastructure for a centralized exchange is a massive you know hot wallet and cold wallet so you know all the people that are trading on this centralized exchange are depositing their valuable digital assets they're basically handing it off to this team that's operating the centralized

exchange and all of this money is being all this crypto currencies being pooled in one central location you know oftentimes hundreds of millions or billions of dollars just sitting in one address and on top of you know on top of that kind of blockchain infrastructure is you know some some infrastructure for exchange so when you deposit when you give your money to this centralized exchange they credit you with some virtual cryptocurrency see that exists on my database that they maintain and that they own and they kind of allow you to exchange those virtual units of value with other people that are also plugged into their centralized

database and so you know in the in the brief history of cryptocurrency existing at all you know there's just been numerous examples of centralized exchanges getting hacked and losing hundreds of millions of dollars or billions of dollars and it just happens consistently every six months or more frequently even and so I you know now getting back to the question of what is a decentralized exchange you know so a decentralized exchange you know first of all it's decentralized in the sense that custody of the cryptocurrency or the or the digital assets remains in control of

each kind of individual each peer in that network so there's no large kind of honeypot where all the cryptocurrency is being cooled and it's also you know a decentralized exchange is trustless so you know there's a variety of different kind of architectures for how a decentralized exchange can can be designed but you know generally across the board a good decentralized exchange allows you to remain in custody of your cryptocurrency and you do not have to trust anyone to you know knock it hacks not run off with your money and so forth so so the custody aspect is one but you also think it's an essential part of

decentralized exchange that you you don't have to trust anybody that it's fair you know that I actually get kind of the best deal compared to other people yeah so I so your song is kind of like you're asking like is transparency around kind of price time priority or is transparency around trade execution kind of a piece of that system transparency and fairness right so so I mean one thing is okay I know nobody can steal my phones but another thing is I know that there's no central party that can for example you know match my orders suboptimal a to their advantage is

something like that I would say that's like I'd say that's I mean it's super important I would say that that's probably secondary to catastrophic failure right so like what's the first thing I want to work you know what what's the first problem I want to solve well I don't want someone to you know steal all my money I don't want catastrophic failure you know once that box is checked it's like okay well now that I'm not worried someone's gonna steal all my money you know how do I ensure that when I am trading I'm getting a decent deal and I think that that's also you know it really depends on the architecture of the decentralized exchange and I think it's extremely important obviously so

yeah I mean I guess you know maybe you know are you saying is that kind of like a requirement for an exchange a decentralized exchange to be considered trustless yeah I think you kind of answered the question right in putting these in an order of priorities so I think that makes perfect sense I'm curious did you guys I guess you guys anticipated because we have seen just huge exposure no an interest in decentralized exchanges over the last years did you guys see post EE that this was going to happen and what do you think are the main reasons why this has occurred I definitely did not foresee this

explosion happening this quickly I mean it was always our thesis that this would happen and that there would be a thousands potentially millions of tokens you know on various block chains why has it happened I mean it seems like institutions and just the the general public has started to become aware of cryptocurrencies I think most people recognize that the impact it will have is just just massive it's it's not a question of if it will have an impact it's kind of a question of when it will have an impact so yeah there's mass speculation on that front right now so

if I scan across the decentralized exchange space there's lots of different projects right so there's there's ether Delta which is probably first that that came online there's idec's there's air swap and of course there's 0x in addition to that there are these like there are theoretical proposals for cross chain mechanisms like walk us through the different architectures that are being pioneered by these projects and what does the design space of decentralized

exchanges as a whole look like a lot you know a lot of the decentralized exchanges that we're seeing today or that you know already exist are there kind of they're kind of like for-profit operations that are owned by a small group of people that you know kind of set up this this system that you know they bring people into and they can kind of extract rent they can charge fees so yeah back when Amir and I got together in October of 2016 you know our original plan was you know let's create a for-profit decentralized

exchange that we own and that you know all the fees that we charge we get to you know feed into our you know our corporation or whatever it might be and you know we were working on it but the longer you know the longer we were in the etherium community and the you know the more that we talked with various projects in the space you know the more apparent it became that what the community and what the ecosystem really needs isn't a kind of walled garden you know there's all of these different decentralized accept applications that require exchange functionality so things like prediction markets decentralized

fund management platforms like stable coins and a variety of others as well and you know so we would meet with the different projects that are building these things and discuss with them and they all need exchange functionality and so you know what we kind of came to realize is that rather than having each one of these projects create their own walled garden their own kind of custom and proprietary smart contracts for exchange you know what there really needs to be is a public piece of infrastructure for decentralized exchange that any DAP can hook into that's completely free to use and that's you know you know completely

open and globally accessible and and so that was like I think that was like a huge realization for us is that you know maybe instead of focusing on building something that you know we want and that will like make a you know allow us to kind of generate a revenue stream maybe we just like build something that everyone can use and that benefits everyone and maybe you know we don't need to have a business model attached to it so you know that's kind of you know I think it's important to like bring that up prior to jumping into like the different decentralized exchanges that exist and their architectures I think it's important you know one of the

things that really makes 0x unique is that it is a protocol it's public infrastructure anyone can build their own for-profit business on top of it so they can anyone can create a decentralized exchange and charge fees and you know I think that we'll see a big shift towards this model compared to you know things like ether Delta were you know they're they're really you know when when ether Delta was the only game in town really wasn't much competition around fees and user experience and yeah I think we're starting to see that now which is really a good thing for everyone

so you talked about this kind of shift to thinking of 0x more as this base layer infrastructure that you know wouldn't be owned by you guys this is also driven in part by the this coming of icos and of basically funding to tokens and creating communities that that shape kind of you development in that direction actually not really so we so we were we were pretty much set that building an open protocol was the way for us to go around January of 2017 it just seemed like it would add the most value for the

most people and but back then like that was way before the ICO craze had really taken off you know I think like the biggest token sale at that time was like Gollum and they raised like eight million dollars or something like that I think like one of the one of the things that the ico craze kind of embraced is that projects raise a bunch of money pre product but that was like you know that was definitely not something we were interested in doing so you know back back in March of 2017 when when we kind of decided that we wanted to build this

open protocol you know we raised a small seed round it was led by poly chain capital it was just enough money to cover our legal fees to hire a couple people and and enough to kind of get us to the point where we had a fully functional product that people could use you know in the following months that's when we really saw the ICO craze start to gain you know kind of take off and all being yeah it was just insane but yeah I don't think that our decision to create an open protocol was at all driven by the kind of ridiculous amounts of money flying around and the

irrationality of speculators like that was that's actually something that like we very whom we very much want to distance ourselves from because I think that's like kind of a toxic culture and we don't want that yeah I don't know does that answer your question yeah sure I mean I I think you can you can look at Isis in several ways but just as one as you know having all these aspects you mentioned but the other one of course also this enormous power in building a community in its center us in people and all that and and do be honest you know when when 0x when you guys take your token sale I I actually put in money really I didn't actually look very deeply at 0x as a

technology but I really like how you approached open cell which was also very novel and very different and I felt there was a lot of issues in how talk themselves were happening at the time so we had these crazy things like for example brave they did the bat token right so the idea is this is browser that hopefully you know billions of people will use I guess that's our plan you have this token that can then be used to to kind of pay for you know advertisement and pay for tension and stuff like that but then they had their token sale sell out in three blocks three hearing blocks about half a minute or a bit more and there was some I don't

know a hundred people or some tiny number of people basically bought the entire tokens oh so you also have these perverse distributions and it totally contrary to I think the idea of decentralized technology we have also control that she centralized and it's owned by community if in the end it's really a bunch of sort of you know all the guards that control it so I really liked how you guys went in a very different direction with the token sale and you know I have hell that was great yeah why distribution was super important to us you know 0x protocol is a platform and it's nothing without

people building on it so we wanted there to be as many stakeholders as possible and I think it's it's really worked out in our favor I think that's a big part of the reason why there are so many people developing on 0x right now and why we have such a great community of course the other nice part about tokens is as you mentioned as we'll mentioned that 0x is not trying to be a central player that extracts rents out of each trade that is happening on using the using the technology essentially right so it is basically a set of smart

contracts and protocols and ways to do things ways to do exchanges that other parties can use in order to build their own systems and at some level we might argue that 0x is solving a public goods problem right so a decentralized exchange a generalized protocol for decentralized exchange on ethereum is valuable yet if there isn't a very obvious rent-seeking mechanism in the in the protocol itself then who exactly would build it and from that perspective the ico model at least the past year and

this year seems to work well to bootstrap these these projects so that's sort of my opinion like like that's that's I think the strength of the ico model that these people are willing to put money to fund public goods development without necessarily the expectation of like revenue flowing in to to the token itself but perhaps we're jumping a little ahead of ourselves and should really talk about what 0x is so we'll tell us what exactly is 0x in the in the nuts and bolts of it

at its core 0x protocol is a a message format so a way of kind of specifying your intent to enter into a trade and you know so you can think of this large chunk of data that consists of different parameters such as the different tote the different tokens that need you know you would like to exchange the exchange rate and of how long you're willing to honor that commitment to trade you can specify whether or not you want to enter into a trade with a specific counterparty or you can leave your kind of order open to be filled by anyone and

so this you know the message format basically specifies how do you create an order and arrange that data into a packet and and so that everyone can interpret it and know exactly what it means you know and the second component of 0x protocol is a system of smart contracts that exists on the etherion blockchain and this system of smart contracts is broken into a couple different modules the first module is a smart contract that accepts these packets of

cryptographically signed data processes them and you know allows trades to be settled on the blockchain and you know that that module is responsible for authenticating signature cryptographic signatures making sure that both parties have sufficient funds to actually settle the trade insuring that an order hasn't already been filled or that you know it is expired so it's kind of the core business logic for settling trades the second module is a governance module and the governance module allows the the

exchange and of the trade settlement module to be upgraded over time I think it's kind of early right now there aren't very many decentralized applications that have existed for very long so it you know I think a lot of people it this the the need to upgrade a system of smart contracts doesn't really hit home for many people but I think it's extremely important that this system of smart contracts that all of this infrastructure is being built around and that all of these smart contracts and businesses are plugging into can be upgraded without bringing all of the markets to a halt and by reducing the friction associated with

migrating to a new version of that that exchange logic over time and you know just for an example like I think ether Delta is probably like the best example it's you know ether Delta is a decentralized exchange kind of owned by one one person it's been operating for a while now probably one of the longest the DAPs it's been around the longest an ether Delta you know ether Delta had to upgrade their smart contracts four times though there are you know there's ether Delta versions one through five and I think that's and that's not a knock on it I think you know that just tells you that you know

it's important to upgrade smart contracts the technology stack that we're building on top of is rapidly evolving and there are it's unavoidable that we're going to need to upgrade these smart contracts over time some new token standards come out etc but you know with ether Delta every single time there was an upgrade you know it was one person that was making that decision everyone that was using the old smart contract would have to kind of withdraw their funds then deposit into a brand new smart contract if they were responsible they would probably want to see a security audit report of the new smart contract to make

sure that it does what it's advertised to do I think people just kind of accept it you know the person that created the contracts was not going to steal their money but that's like a very disruptive process and you know so the way that 0x protocol is designed yeah you know we have this logic for settling trades we have this logic for upgrading the system over time as new token standards emerge etc and it allows us to upgrade the system without requiring users to migrate without making all of the markets stop functioning and you know I think ultimately like that'll be a model

that we see much more frequently going forward you mentioned governance before as one of the core modules and now we've been talking about upgrading so is governance the way to upgrade the system and both now and is that what you see the role in the future yeah I mean absolutely it's kind of crazy just the between when we did our token sale and now the crazy amount of developer interests that we've seen like we I don't think Amir or I were really expecting yeah I think we thought we would have to really kind of go out and convince people to build on top of Xerox

protocol but we've kind of seen this explosion of interest in development activity and it's really exciting but it's also a lot of responsibility because at the end of the day all of these people have kind of changed their career trajectories and now they're you know their career is building this business on top of infrastructure that you know we're building and that's you know if I were them I would be kind of terrified if you know it was if we had a hundred percent power to make all the decisions about how the protocol should change you know

so I think one of the the reasons why all of these different real ayres these decentralized exchanges that are building on top of Xerox I think one of the reasons why they took that risk is because we've been very clear from the beginning that this is public infrastructure it's owned by the public and the people that are actually using this system the people that are stakeholders they're the ones that are going to drive the governance process and make the technology evolved over time not not Amir and I too much responsibility for a small group of people it needs to be the entire ecosystem that drives the governance

parrot to sort of aetherium so in aetherium itself is being upgraded and there's this e is it helium improvements process which is basically a set of new standards and and like potential commits that are discussed over over github and once the community which probably is a quorum of people that are involved in serum development are comfortable with it get included into the next upgrade how will a future 0x how will this look different in the future for 0x what

changes from the way aetherium improvements are done today right now the the process is very similar to etherium but in the future there will be some form of token voting you know where your bow is weighted on that amount of tokens you own and I think the reason this works better specifically for 0 lakhs then then a theorem like process kind of kind of goes back to the reason we made 0x in the first place so the decentralized exchange ecosystem was very fragmented there all these

different siloed exchanges and it's it's more important that we have you know sort of a way of soft working on chain using our governance to keep everyone on the same shared protocol if we you know we're just like pushing out upgrades in in a centralized way and people are like deciding to stay on the hold version or whatever you kind of just end up back to square one where you just have this fragmented decentralized exchange environment so on the topic of token booting right so essentially you have this 0x token and the way we could

imagine it is in the future let's say you have right now let's it's version 0.8.0 and in your team develops version 0.9.0 it might be some other team that develops that version as well and there's a proposal to accept 0.9 point OS the canonical version of it and we say that we're gonna have a vote of all of these 0x token holders and provided a sufficient quorum and majority is reached then the upgrade will take place my question with a mechanism like that is does this process actually enable the

best people to have their voice heard so let's think of it like this so you have a min Geun sealer steam ad at Cornell right now that team might have very talented PhD students and these PhD students might be of the kind that can actually analyze a protocol upgrade for its security for its challenges but if you know the American PhD student you pretty much know that American phd's don't get paid a lot in stipend right so you cannot expect people like like constituents like this to actually hold a lot of 0x tokens and therefore these

people will not have a lot of voice in that governance process yet they might be the ideal people to actually vote in the process how do you resolve this problem or do you even seek to resolve it yeah so I think you've identified that you know not just decentralized governance but real-world governance is an extremely challenging problem you know specifically to your point around are the right people government you know are they the right people driving the governance process that is yeah it's absolutely something we're thinking

about so yeah just to provide a little background right right now we're collaborating with the Aragon team and they're a really interesting project they're you know creating a general tool set and framework for decentralized governance systems kind of plug-and-play building blocks and one of the things that were collaborating with them on is research into this concept of liquid democracy and the way liquid democracy works is that the people that that stakeholders in the ecosystem can delegate their voting

power to someone that they deem you know capable to vote on their behalf so you know this is I don't want to like I definitely don't want to claim that like liquid democracy is the way and it's the best decentralized governance approach but I think it's an interesting step from fully fully centralized towards more decentralized and it allows the people that you know have expertise and that are comfortable voicing their opinions to kind of have voting power

within the system without necessarily having financial resources at their disposal and yeah I I think it's one one interesting approach that we're considering right now cool yeah I mean I agree I think that that's good that's gonna be one of the very exciting things about blockchain is because it will necessitate all this innovation around dissenters Conan's decision-making of course they are also very revolutionary things online like using prediction markets and future key to do things like that maybe that will also work so we talked we started talking about how 0x works and what kind of the architecture looks like so you talked

about how people can basically send these messages right with orders and then you have a set of small contracts allows those traits to be executed and settled on a blockchain but there's also in 0x buy the whole you know different kind of ecosystem participants that have roles in that and in particular there's that role of a relayer can you explain what we layer is and what their function is in 0x yeah so a real ayres job is essentially to host an order book and broadcast that order book to the public or in any way that they see fit since all of the

orders and 0ax are stored off chain this is a requirement in order for people to actually you know find counterparties to their trades I think initially the first decentralized exchanges were largely using on chain order books which means that people are paying transaction fees whenever they even place an order and value is not necessarily being transferred and this is just not sustainable in the long term but yeah by having an often order book you can drastically decrease the cost of trading but you do need some mechanism to find a counterparty and that's that's kind of

the real layers job and and they earn fees for doing that so what is the trust model between a pair of users wanting to exchange using 0x and a literally layer so I might be the buyer of maker for either buying might with the seller and well might be the real layer what are the kinds of trust we are putting on drill on will just to preface this a little bit there are various strategies real layers could use with varying degrees of trust I would say the most basic strategy would be just a more open order book model kind of similar to either Delta I'm

broadcasting my order book to public anyone can see an order and fill that through their own aetherium node that's probably the most trust list model you know relayer can't really do anything to steal money or anything like that I think the worst that you probably do is hide orders but I don't see why that would be in their best interest there are other models that involve a little bit more trust for example the relayer can act as a central matching engine and then obviously you need to trust the relayer to actually match our orders we kind of touched on this earlier but all of these

models are non-custodial and I think that is probably what matters most but it's up to the end-users to decide which relays are comfortable using is there also a risk here that let's say I is a minor I see you know you're sending well can I gain this somehow can I fight front on it or I I see oh this this kind of order coming in and I'm gonna interject my own and then kind of take a orbit opposing position elsewhere and make an arbitrage or something like that so it it really depends on the way that the relayer is

structured the way that they are kind of operating so you know one of the ways I actually I just I've been writing a blog series on front-running specifically and the different ways 0x protocol can be a the ways that it can be used in the ways those different approaches can be gamed or front-run and so generally speaking if I create this 0x order and I allow it to be filled by anyone in the world anyone that just happens to see it that type of order is subject to

front-running so you know someone you know may be my counterparty sees my order they they want to take the other side of that and enter into a trade they kind of inject that quarter into the etherium kind of pending transaction pool the mempool and that transaction will kind of sit there waiting to be mined into a block and so anyone that's watching the pending transaction pool and see what I am attempting to do or can see that my counterparty is attempting to fill my order and so you know anyone can kind of take that order say oh I'd actually I'm going to fill

this order and they can set a higher gas price and you know they could front run my counterparty and they would be my new counterparty and you know what's interesting is that miners they don't even have to think about gas prices so so miners can they can kind of they can order trades or they can arrange transactions into any order they want it can be completely arbitrary they can they can mock miners can mine blocks with zero transactions in the block you know typically a rational miner will prioritize transactions that pay the highest fee per unit of gas but if a

miner is attempting to front run sort of one of these open order books they can do whatever they want it's kind of like God mode for them so that's not very good you know the good thing about 0x protocol is that it's you know we don't define the way that people enter into a trade or the way that you know these orders are transported off chain so there's a variety of different ways that 0x protocol can be used so the first way that I just discussed is called the open order book strategy and this is kind of like the ether Delta approach a different approach is sort of this order matching strategy so the relay ER which

in this case we call the matcher they only accept orders on to their order book if they are specified as the only party able to execute that trade so what they do is they wait for two orders to show up on either side of the order book that are equivalent in price or overlapping in price and then they kind of batch fill that they've kind of package those two orders together inject them both into the 0x smart contracts and kind of batch fill them simultaneously and so in that model the matcher has full control over trade execution so you know you can imagine that's that

can be a really good thing it prevents front-running from traders and miners you know no one is able to kind of see that batch of transaction sitting in the pending transaction pool and able to like kind of go in swoop in like it just doesn't work there they're locked out and miners can't you know miners can't do that either but you can also imagine that maybe giving this match or kind of full control over the trade execution process maybe you don't want to give them that that truck you know you don't want to get kind of give up that ability that power so there and there's a variety of other ways that 0x protocol

can be used to kind of you know it solves both of these problems at once so I instead of getting too deep into it right now I would encourage people to go check out the blog post I wrote it goes it's real it goes real deep it's called front-running briefing in the perils of virtual settlement and there's there's part one and two that are out right now cool that's super interesting thanks so much for expanding on this that's just something kind of came to mind here I mean there's a lot of projects in in the kind of adjacent blockchain space that are trying to create tools so that you can basically run code on a server that you know it's like it's a central server

but that someone else in from outside can say okay this was done correctly and kind of tamper proof and stuff so Intel SGX is one example of what there are others wouldn't you be able to build basically a some kind of like matching engine using something like Intel SGX that you know is users can have a very high trust that this is fair there's nothing funny going on but at the same time it can have all the benefits of being you know a centralized entity on a server it can be performant and and of course also that way immune to the front-running of the mind that you talked about I think there are

directions that are worth exploring that yeah like I think potentially there are ways that a matching engine could be designed to be trust lists so kind of like what you're saying you know and but perhaps instead of relying on a person to you know do trait kind of do trade execution according to kind of whatever rules they said instead let's let's all agree on what the rules are and kind of dump them into an Intel and SGX type of system where you know we can all kind of publicly observe what's going on and we know that it's being done you know

according to the rules we all agreed upon I do think that there are challenges around that that you know need to be explored further so like things like like data availability so like you know it's very easy if everyone agrees upon the current state of of an order book and everyone agrees on the kind of time at which different orders are kind of coming in you know if we all agree about that data set and we all agree about the rules that were kind of enforcing over trade execution in this Intel SGX type system then yes we can we can all you know say okay this trade

execution system is performing exactly how we want it to everything is good but you know I think the most challenging part there is ensuring that everyone has the same kind of state of the order book and everyone is viewing these orders coming in at the same exact kind of cadence right in the same order so that's kind of like the data availability problem and I think that's a pretty challenging it you know it's a challenging problem to solve but I absolutely believe that you know we can create interesting systems that that work you know it's just going to take some time and more people exploring exploring them

and I think one of the challenges with these more theoretical approaches to solving front-running is that a lot of them are not going to give the user experience that we want you know they're gonna require like security deposits long lock ups long withdrawal periods and this really reduces the ability for other decentralized applications to like plug into the system and then the second point I wanted to make is that I think front-running is actually one of the larger problems in the blockchain space in general I think people view it in the context of a centralized exchange a lot

because decentralized exchange is like one of the first use cases in production of smart contract based block chains but yeah I think I think we'll see more and more applications having these issues as they start going into production and I could see in the long run the the end solution might be something like zero knowledge mining where you can't actually tell or you can't look at a transaction in the mempool and see all of its properties but you could only you know prove that that transaction will pay the mine or X amount of cookies or whatever so one other one other aspect of this model of free layers and users

is the question of privacy right so today in in the 0x model and in virtually all these centralized exchange models when I'm making an order or I'm taking an order the linkage between what asset is being traded how much is being traded and my address is visible on the blockchain right this address traded this in this much quantity for this much price see a lot of innovation coming from your side or in the ecosystem around obfuscating this linkage and what are

the interesting approaches and projects here yes oh I think privacy is a pretty big challenge I think in in the context of decentralized exchange there are probably people would prefer for everything to be private I think there are some advantages of things being transparent as well you know if you see someone doing something shady like boss trading or something like that that's pretty easy to to notice but you know I think I think in the long run we do want everything to be as private as possible I think both z.k snarks and Entering signatures are you know potential

approaches that that we can take to that the issue right now is probably the cost associated with doing those things it's just not viable to you know have have private transactions because the portrayed cost is going to be too high but yeah I'm excited about a handful of different approaches I think keep network is doing some good stuff in that space as well different signature types also I think and can add a decent amount of privacy we're looking into BLS signatures right now which comes comes with the benefit of being able to share

fees in a more private way so speaking about relays before now it seems you guys have I mean this is one of the amazing things and and you guys mention it a little bit before that I have noticed sort of from periphery that after your token sale is there was all these announcement okay this projects building a0x project Cyrax projects your X project so there's really this kind of vibe and startup ecosystem that's developed which is having quite unique actually for for blockchain projects or talk projects I did a token sales especially as recently as you guys so what are the business models that people are trying to realize when they're

building easier X businesses so I think the business model is very straightforward right now is just hosting the word book broadcast that word book and charge these four trades and I think that's actually a big part of why we've been so successful the business model is just so clear and this is kind of one of the first ways to monetize watching applications in in a very cheap way without doing a token sale I think down the line we're gonna we're gonna see more business models where you have things like wallets who are just rebroadcasting orders from other real ayres and taking a cut of

fees and I think that's when we'll kind of see an explosion in in use of 0ax yeah absolutely but what I'm curious here it seems to me that be layers I mean as a as a user I don't really care too much about you know which we layer right in the end if my order get settled it's on the chain right I get the other tokens and and I just want the best price someone like reliable execution I don't care like you don't care about brand you don't care it's not really trusted very much as we've talked about right so I don't have to worry too much about you know someone like coinbase

have to been around for years do they have all like insurance all of these things are are not relevant so how I would be possible for those relays to build a sustainable profitable business is that not just gonna be kind of a little commodity thing that's gonna get you know driven to zero when it comes to their profit margin we're definitely gonna see competition between the different real layers and I think it's gonna be extremely healthy or the entire kind of decentralized exchange ecosystem as a whole you know ether Delta you know has been extremely successful and I think that you know

it's incredibly impressive what the you know Zack Cober and the founder of ether Delta did on his own that being said I think like you know teams you know some of these real layers since you know we kind of massively lower the barrier to entry for a new new dev teams entering the space I think what we're gonna see over time is just you know competition around user experience and as a result and this is something that we desperately need in the blockchain space you know creating a decentralized application that talks to the blockchain and in you know does it in a way that the user can understand and feel comfortable with is extremely hard and

you know if there's a you know multiple teams that are competing for market share one of the first things is providing a great user experience everyone benefits from that competing on transaction fees you know I think these will not go to 0 but they will go to an economic equilibrium that makes sense and that's also very healthy for everyone that uses decentralized exchanges but I think one of the biggest sumption that it one of the biggest sumption is it kind of plays into this you know hey there's like 12 different real layers they're all kind of trading the same tokens like do we really need

12 real layers that are doing the exact same thing and I think the answer's no but we'll end up seeing it kind of what's an assumption that's built into that statement is that there's a finite number of tokens people are interested in trading and I think that's that is going to turn out to be false you know I think that over the next few years you know there's been this explosion in the number of tokens that exist and I think that's gonna continue and it yeah there's gonna be a massive number of tokens that are kind of created through token sales there's going to be just a Cambrian explosion of non fungible

tokens and video game items that are coming out once the community can kind of come to consensus on the tokens standard for non fungible tokens I also think that like securities tokens are going to just be an incredibly huge new area where there's tokenization and so you know over the next few years I think the number of tokens that exist is going to trend towards infinity and you know relays are not going to list millions of tokens what they're going to do is they're going to find a market niche they're going to kind of plant their

flag carve out that market niche and you know there will probably be one or two real Ayres that dominate you know a specific market niche but there is going to be hundreds of market niches and you know real layers that focus on real estate tokens that's gonna have to be a completely different user experience than real layers that offer you know prediction market tokens and even within prediction markets there's so many different kind of verticals that can be focused on like basketball you know betting on basketball games you know betting on elections politics science there's just like an infinite number of niches that can be kind of captured by

real ayres that want to kind of create kind of tailor their their product for that specific market I mean my feeling is and of course I I don't know nearly as much about this as you and it's just sort of an intuition but this sounds kind of weird to me I mean it feels to me that you know let's say something like Google right well they can do email right they can do Qi mail I can date they literally have most of the world I mean they could have the entire world running on Gmail or I think if people wanted to they would be able to build out that kind of capacity I mean I agree that probably you when it comes to user interface but that will vary and when it comes to marketing and

you know it may be community will matter and stuff like that right so I could see there being maybe you one or a few kind of relays that just dominate everything and then maybe them having some sort of you know affiliate type things where anybody can build their you know real estate funnel on top or their security token funnel on top of that so so Brian has sketched out this future I don't know I I don't I don't sort of agree with Brian here and maybe I can sketch out a different future and then we can discuss sort of what will lead to either of the two futures being realized

but if we look historically on how pilots have monetized it has almost always been through referring users to exchanges so when you go to Jack's and click on okay I want to sell my easier and get litecoin Jax refers you to shape-shift and shape-shift makes the transaction fee on that exchange and shape shift forwards part of those transaction fees to Jax strangely enough in the in the token economy the UX maker seems to have this kind of power to

influence where the transaction fees are going to flow and I think that this is going to hold true for prediction markets and the real relayer economy so it might be the case that the application with which people access their crypto kitties there might be a few successful applications that people download in order to get access to their crypto kitties the UX makers of those script of those few two or three applications can basically make or break the real layers in the crypto Kitty exchange market so if there's a company like Google that let's say tries to

dominate each and every kind of asset in the real layer space right it might be the case that there might be a small start-up that comes into the market and focuses only on being a cryptic it is a layer and then it makes really good deals with the UX makers of the crypto Kitty's application and because these UX crypto Kitty uux makers always refer to this small startup for the exchange needs they're that small startup is still able to carve out a niche against that big Google like player that's trying to dominate every niche but this is just the feeling I'm not sure maybe Bryan is right and this

is like one real to one relay or a couple of real layers to rule them all what are your opinions on it this large relayer that kind of dominates everything I think rather than being like Google I think it would be more similar to like a reddit where there's literally infinite number of topics and communities that you know kind of form around very specific topics and you can go to Reddit and you can find your community and then you can subscribe to that community and you can become a part of that community and you can kind of just click on the different communities that you want to become a

part of but it and you know I could see something similar to that happening with real ayres where there's this large you know kind of this large dominating real layer that's kind of similar to Reddit and they offer these sub communities but if I mean I'm it's kind of hard to come up with a great example off the top of my head but if you can if you compare like Reddit and its ability to kind of create communities you know there's still there are still like places where communities form off of Reddit and that provide like a more tailored experience for the community that they're serving

you know there's a limited amount of customizability that you can provide to your subreddit community using reddit so I don't know like I could see both of them existing in parallel did I don't know if that analogy like was very clear but as my sense I also think that there are just going to be enough ways to differentiate yourself as a new layer and some of those ways kind of compete with each other in a way that a single relayer probably won't won't do all of those so to give an example you know maybe one REE layer is offering trades

with like a certain derivatives and margin trading protocol and another relayer is offering that with a different protocol I highly doubt you're going to have one company that's offering both - calls but like it was both my cater to different users that in combination with the various different strategies you could take as a relay er that like would significantly affect user experience and the the api's are available to provide to end-users you know kinda like the difference between the order book model and the matching model that we discussed earlier is pretty big and it's not

really something that a single relay would not really be able to offer both of those things so I think if you take all these different product offerings all these different strategies all these different you know demographics that relays are targeting we're going to see a pretty diverse environment so of course the there's a 0x token what do you see the 0x token kind of its evolution or the economy the economy of the Xerox oak and what's that going to look like in the long run so the 0x token first and foremost it is a governance token it allows us to upgrade our system of smart contracts

over time without bringing all of the markets built on top of 0x to a halt and the second thing that the CRX token is used for in direct protocol is for paying transaction fees to relay errs right so real ayres they get to you if they want to they can charge trading fees on every trade that kind of goes through their order book and you know I think a lot of people kind of view this you know ZRX as a payment or is like a fee token they kind of view that as like oh this is why the zr x token exists it's you know it was kind of like a fundraising mechanism that was kind of bolted on as an excuse for us to you

know your token sale but like it really couldn't be further from the truth so the 0x token is a governance token and the reason why we just we made the design decision that the CRX token should be used to pay fees is because we think it's super important that all of the all of the stakeholders in the ecosystem or you know all the people that are accessing the protocols functionality have at least we're driving them to participate in the governance process by forcing them to have some amount of ZRX tokens to access the protocols functionality and you know like one of the problems that we're trying to avoid is you know if the only

people participating in the governance process are the real ayres that could be really bad because they're for-profit businesses and their incentives and their interests do not necessarily aligned with their end users and so you know it could be feasible that if the real ayres band together they could change the protocols in ways that are not in the best interest of the people that are actually using this infrastructure the or i guess it's the other half of the people using the infrastructure the users the people trading so you know I think this is like a really controversial point a lot of people do not like that the ZRX token is used to

pay trading fees it you know a lot of people think it feels pretty arbitrary it's kind of annoying that you have to let go and acquire some of these tokens but you know I think it really makes sense for the long-term health of the ecosystem you know if the governance process is really imbalanced to serve one group of people over another that ecosystem or that civilization tears itself apart over time and we don't want that to happen we want everyone that uses Xerox protocol to have a stake in the the weight of

also retirement cool no that makes that makes perfect sense and it would be very interesting to see how those governance experiments in C or X turn out hopefully it doesn't rip itself apart yes exactly although that would also be interesting to watch that would be interesting with it but very sad I would say be sad yes so tell us what is kind of the roadmap and timeline and what can we expect from Xerox the next 24 months so yeah currently we are working on the two of the protocol major changes are going to include like they're a bunch of efficiency gains essentially it's going to become much easier to arbitrage

across the different real layers per transit or portrayed transaction costs will be lower we want to support new token standards such as non fungible tokens and then we want to improve our upgrade mechanism so that adding new token standards would be easier as well and we're also going to is kind of a technical piece but without getting too into the weeds we're going to make it a lot easier for people to kind of build higher-level protocols on top of 0x make it essentially you like funnel all of their trades through their own spark

contracts which would enforce you know any arbitrary set of rules or logic around filling an order so that's that's kind of on a timeline for the next version but I think vv3 will we'll see some more decentralized governance built into the system for sure and then could really go anywhere from there right there are scalability solutions we're interested in plasma chains potentially you know having like a cosmos zone things like that launching on other EVM compatible blog chains yeah I think it's it's going to be wild but

v2 is on what we're looking at right now cool that sounds that sounds very interesting and yeah so thanks so much for joining us today guys thank you so much for the pleasure yeah thank you for having us this is great yeah and of course thanks so much for a list of the Front's again joining us we were gonna have links in the show notes to you know some essential things to check out about your ex white paper wills blog posts and some other resources you want to learn more about your ex and try it out and yeah so thanks so much for joining us where we put out new episodes of epicentre every Monday you can subscribe to the shows in iTunes SoundCloud favorite podcast app or you can also watch the videos on

youtube.com slash episode of Bitcoin and also we just started a either communities or try this out so if you want to go there you do that and it's a episode with a slash it so and of course you can leave us nachos review which helps new people find the show so thanks so much and we look forward to being back [Music] [Music]