The following is a conversation with Sergey Nazarov, CEO of Chainlink, which is a decentralized oracle network that provides data to smart contracts. He and his team have done seminal research and engineering in the space of smart contracts. Check out the Chainlink 2.0 white paper that I found to be a great overview of their technology and vision. It's 136 pages, but very accessible.
Quick mention of our sponsors, Wine Access, Athletic Greens, Magic Spoon, Indeed, and BetterHelp. Check them out in the description to support this podcast. As a side note, let me say that externally connected smart contracts that combine the ocean of data out there with the security of the blockchain are fascinating to me both technically and philosophically. Data is knowledge and knowledge is power. I think the more reliable data sources we integrate into our decision making, especially when those decisions are executed by programs, the more efficient and productive our decisions become.
There are interactions between humans that should not be formalized digitally, like love for example. But for all the others, there's no reason for smart contracts not to automate away the menial parts of life, making more room for good conversation over brisket and maybe some vodka with old and new friends. As usual, I'll do a few minutes of ads now. I try to make these interesting, but I give you timestamps, friends. So, if you skip, please still check out the sponsors by clicking the links in the description. It really is the best way to support this podcast. I'm very picky with the sponsors we select. So hopefully if you buy their stuff, and you should, you'll find value in it just as I have.
This podcast is sponsored by Wine Access, online store with expertly selected wine. I love it because it lets me explore wines. My current recommendation is the 2017 Seghesio Family Vineyards Old Vine Zinfandel from Sonoma County. I don't know if I pronounced that correctly, but I do know it's delicious. It comes from smaller grapes that intensify the flavor. And if you know anything about me, I love passion and I love intense flavor.
Obviously, I've been really into brisket lately. And I actually, for all the barbecue places I've gone to, never had wine at the barbecue place. It's always just focused on the brisket. I wonder how that actually tastes like. But when I eat steak, red wine is perfection. Steak, red wine, and a good friend. Good conversation. That's heaven for me. Anyway, get 20% off your first order when you go to wineaccess.com/lex. The discount will be applied at checkout. That's wineaccess.com/lex to see my wine picks and to get the discount, plus to explore all the amazing wines they have there. I highly recommend it.
This show is also sponsored by Athletic Greens, the all-in-one daily drink to support better health and peak performance. It replaced the multivitamin for me and went far beyond that with 75 vitamins and minerals. It's the first thing I drink every day. I actually have been drinking it twice a day. I break the fast with it and I drink it at some point in the afternoon or the evening. I think there's a lot of nutritional benefits, but there's also just like psychological benefits of knowing you got that base covered and you can take on the day with all the crazy things that I'm doing, both in terms of just programming, deep work sessions, and athletic endeavors, however limited I am skill-wise in any of those.
Anyway, they also got fish oil, and I think they're giving you one month supply free of wild-caught omega-3 fish oil when you sign up on athleticgreens.com/lex. If you're anything like me, I think you're going to really enjoy it taste-wise and nutrition-wise.
This episode is also sponsored by Magic Spoon, low carb, keto friendly cereal. It has zero grams of sugar, 13 to 14 grams of protein, only 4 grams of carbs, and 140 calories in each serving. I feel like Bruce Buffer introducing a fighter here. With a record of 13 and 1, 11 coming by knockout, Magic Spoon is a cereal that gives you a 100% happiness guarantee. So, if you don't like it, they refund it. They're actually releasing a new flavor called Birthday Cake. I definitely need to check that out. My favorite flavor still after all this time is cocoa, but I'm sure birthday cake is going to be pretty good, too.
Somebody on the YouTube comments actually, funny enough, commented about all the Magic Spoon cereal that his wife bought. I feel the love. I really appreciate it. And he was joking about, what am I going to do with all that cereal? My suggestion is you eat it because it's delicious. But either way, buying stuff from these sponsors, trying them out, that's genuinely the best way to support this podcast. I enjoy their stuff. I really think you'll enjoy it, too. Anyway, go to magicspoon.com/lex and use code lex at checkout to save five bucks off your order. That's magicspoon.com/lex and use code lex.
This episode is brought to you by Indeed, a hiring website. I've used them as part of many hiring efforts I've done for the teams I've led. They've actually sent me some ad suggestions, which by the way, for most sponsors, I usually ignore, about AI versus human and that humans still have something to contribute and that's why you would use Indeed. I like it when sponsors try to insert a little humor. Lord knows I have none. But anyway, it is kind of funny to think that one day we'll be hiring AI systems and human biological systems because I do think there's a few fundamental questions around what do humans really do best? I think that's a really important question to answer when you're hiring somebody. What is the essence of the task at hand where the particular person can do their best work?
That's something you have to answer for yourself when you're hiring. Obviously, it's as much of an art as it is a science, but you do want to be using a good platform. Indeed is one such good platform. You should definitely try them out. Right now, you can get a free $75 sponsored job credit to upgrade your job post if you go to indeed.com/lex. That's indeed.com/lex. Terms and conditions apply. Indeed.com/lex.
This episode is also sponsored by Tim Dillon's favorite sponsor, BetterHelp. Spelled help. It's easy, private, affordable, available worldwide. They figure out what you need and match you with a licensed professional therapist in under 48 hours. You should definitely check out the Tim Dillon Show to observe a man from a sort of psychological case study perspective that is clearly losing his mind. And probably should go to betterhelp.com/lex. I'm only joking, of course. He's just honestly a fearless, vicious comedian who's holding people's feet to the fire, which is really good for this world. And of course, whenever he makes fun of me, it truly is an honor.
Anyway, check out BetterHelp at betterhelp.com/lex. It's easy, private, affordable, available worldwide. They figure out what you need and match you with a licensed professional therapist in under 48 hours. That's betterhelp.com/lex spelled help.
This is the Lex Fridman podcast and here's my conversation with Sergey Nazarov.
Is that Yuk there or he?
So, I gave away everything I own a few times in my life and he accidentally survived and I don't like stuffed animals. What I really liked about, I got them in a thrift store. What I liked about them is because I'd never seen a stuffed animal that looks pissed off at life. Like they're usually smiling in the dumbest of ways and this guy was just pissed.
Yeah, I got to tell you that's actually pretty funny. I like this guy. If you had to live only in the digital world or the physical world, which would you choose?
So, I think this is actually a question more about what the fidelity of the digital world would be versus the physical world. I think this type of question and this whole simulation thing actually comes from papers about 20, 30 years ago in the philosophical world where people tried to make this thought experiment of would you be comfortable if everything that was happening to you happened in a simulation. What they were trying to do is they were intuitively trying to understand is there some kind of intuitive personal connection we have to something being the real world, right? And then the Matrix movie actually came out of these papers and then these ideas made their way into the public consciousness. I personally think that if I had the choice to be in the digital world at the same fidelity as the real world with immortality, I would absolutely go with the digital world.
Wait, wait, wait, wait, wait. How'd you add the immortality part? That's a you don't get immortality.
If you think about how we would go into the digital world, right? Our brain patterns would be mapped onto some kind of probably virtual machine, right? And that would mean immortality, right? Because the virtual machine has no limit to how long it can exist.
Well, don't you think there would be like a versioning system, like there'll be this is a soft fork versus hard fork question whether Sergey version 2.0 would be different from Sergey version 1.0. There'll be an upgrade. So that's mortality. Sergey 1.0 would die in the digital world. You get a software update and then that's it, you know.
Well, yeah. When people go into the Star Trek transporter, are they killed or are they transported?
I don't really know. I haven't read any papers on this. I haven't really thought about it too much. There's no white paper on the transporter.
But what does fidelity mean exactly to you? Is it like strictly, so the fidelity of the physical world is maybe now questions of physics, quantum mechanics. What is it at the bottom of it all? Or do you mean the fidelity of the actual experience, like it's just perception?
The human, but that's limited by human cognitive capabilities.
It is, but I don't really have anything else, right? I think all of these papers that brought up these questions of a simulation, they were in epistemology and metaphysics. And what they were trying to do, I think, was they were trying to put people through a thought experiment where they would come out on the other end and say the reality of life is really worth something. And ignorance isn't bliss, which is that consistent statement in The Matrix, right? Ignorance is bliss is what one of the guys says when he's doing something wrong and trying to get back into the matrix. And the question is, is ignorance bliss? It's like a different version of that. I think from a perceptual point of view, if my perceptions aren't in any way different, so fidelity is very good, it doesn't matter. I don't know, right? So if I don't know something, it doesn't really exist. And if it doesn't exist in my perception or my consciousness, then it doesn't exist period for me at least. And then whether it exists in some more metaphysical version of things, I personally never really got into the metaphysics stuff because I could never really understand what the point of it was. It's one of these things where I couldn't really get what the practical application of it was. And this is from those realm of questions, right? Like if there was something about the world but you didn't have any capacity to perceive it, would it matter to you? To me it wouldn't matter.
Right. To me, by the way, the simulation thing is a really interesting engineering question, which is how difficult is it to engineer a virtual reality, a digital world that is sufficiently of high fidelity where you would want to live in it. I think that's a really testable and a fascinating engineering question because my intuition says like it's not as difficult as we think. It's not nearly as difficult as having to create a quantum mechanical simulation that's large enough to capture the full human experience. Like it might be just as simple as just a really nice Quake game, like with a nice engine that's just creating all the basic visual elements that trick our visual cortex into believing that we're actually in a physical environment. And I think that if that's true then that's quite, you know, a high-fidelity digital world is actually achievable within a century, and that changes things.
Yeah, yeah. Maybe in our lifetime, I'm really hoping for that. I'm hoping somebody can copy my brain waves onto a virtual machine and allow that consciousness to continue to exist. Whether that's death or not I don't know. But I think it's actually going to require some serious leaps. Like even the VR headsets, right? They don't work if they go below 90 frame rates, right? People start getting freaked out. So you have to go from one gaming screen of 60 frames per second to two screens of 90 frames per second. And so people's hardware today can't even handle that. And that's for these two little screens by your eyeballs. What it's going to take to completely trick my consciousness into not knowing the difference in terms of all the sensory inputs, I'm keeping my fingers crossed. Whoever does that and is close to doing that, they should contact me. I want to have my brain waves turned into a virtual machine.
Would you in that context, if Morpheus came to you, would you take the blue pill or the red pill? Meaning, would you be happy just living in that world and not knowing that you're living inside that virtual world that's running on a computer, or would you want to know the truth of it?
Well, actually I think that's a very different question, right? There's actually a moral ethical question there about whether you should allow a bunch of people to get, you know, manipulated and killed and enslaved, because in The Matrix they're all enslaved as like a AAA battery, to turn a human being into the battery, right? So I think the moral and ethical question there, fascinating, isn't actually different than the moral ethical questions we face today in modern daily life. But I probably, given the choice of just completely going along or going against it, I would probably go against it if I had to make this kind of binary choice. Because going along with it, I think at that scale of scary stuff happening to people is probably something really, really difficult, but for your individual life it's way more fun to go along with it.
So you're saying you value the opposing a system that includes the suffering of others versus just for yourself enjoying the ride. I mean, what's, if there is such a binary choice, why choose the oppose?
I think it's the nature of kind of the ethical dilemma that you face in that situation. There's kind of some, you know, this is obviously not something that's happening now, right? We don't know this, right? We don't know this, but at the end of the day, at that scale of something like that happening, yeah, at that scale of people being manipulated and harmed, then I think pretty much almost all people have an obligation to go against it. Probably that's what that looks like in my opinion.
So you've talked about the concept of definitive truth. What is it? And in general, what is the nature of truth in human civilization? And just talking about the digital age, the nature of truth in the digital age.
So the interesting thing about definitive truth is that it actually exists on, at least in my mind, on this spectrum between objective truth and just somebody made something up and nobody else agrees. So what I think definitive truth is, is it's somewhere in the middle on that spectrum where if you and me define what truth is, right? Like if you and me have an agreement of some kind and we say as long as the weather is sunny or the weather isn't, there is no rain on that day, then there will be an insurance policy that results. And you and me both agree that as long as three sensors, three monitoring weather monitoring stations all say that, then the definitive truth for us and for that agreement is the result of those systems coming to consensus about what happened out in the real world. I think the objective truth definition from the philosophical world is really, really stringent and very, very hard to attain and that's not what this is, and that's actually not what commerce or the ability for people to interact about contracts needs. What I think the world of commerce needs is an upgrade from someone can unilaterally decide what the truth is to there can be a pre-agreed set of conditions where we define what the truth is under those conditions and then you and me basically say if these 20 nodes or if these 30 data sources come to consensus within this method of consensus with this threshold of agreement then definitive truth has been achieved for you and me in our relationship for this specific agreement. And the specificity and our shared agreement to that kind of truth or that definitive truth being acceptable to both of us is probably what's necessary and sufficient for everything to move forward in a better way. In any case, much better than, you know, I'm a bank or an insurance company. I'm going to unilaterally decide what happens.
It's definitely an upgrade from that. Do you think it's possible to define formally in this way a definitive truth for many things in this world? Like you talked about weather basically defining that if three sensors of weather agree then we're going to agree that that is a definitive useful truth for us to operate under. So how many things in this world can be formalized in this way, do you think?
A huge amount. So there's actually two things going on here. One thing is the amount of data that already exists, right? And the pieces of data coming off of markets, IoT, shipment of goods, any number of other things, like even your YouTube channel has a certain amount of likes or a certain amount of clicks or a certain amount of views, and even that's quantifiable, right? So even to a certain degree what we do here today, you and me right now can be quantified as far as the amount of views, the amount of clicks, the amount of any number of other things.
Yeah, you the viewer have power of data in your hands by clicking like or dislike right now or the subscribe button or the unsubscribe button which I encourage you to do anyway. Okay. So there's data flowing into all interactions in this world. There's data.
There's more and more data, right? Like more and more data. That data is more and more accessible to everybody. And that accessibility and the fact that there's more of it means we can form more definitive truth proofs.
We can form more and more proofs. And as we form those proofs, well, we can provide them to these blockchains and smart contract systems that consume them and then they're tamperproof, right? So they can't be manipulated. And so now we've combined a system that can prove things with a system that guarantees us certain outcomes. And we have a better system of contracts which is actually an unbelievably powerful tool that has never existed before.
Can we talk about the world of commerce and finance, decentralized finance? What is it, what's its promise from both the philosophical and technical perspective if we just zoom in on that particular space of the digital world.
Sure. So decentralized finance is the instantiation of a specific type of smart contract, right? Or what I call hybrid smart contracts, which are these contracts that combine the on-chain code together with the off-chain proofs that something happened. They're called hybrid because they basically use both of these systems, right? The blockchain and the proofs about what happened. And what DeFi is, is one specific type of hybrid smart contract that is taking on the contractual agreements you traditionally find in the global financial system, right? And that's basically the world of lending, the world of yield generation for people giving whoever their money and somebody giving back yield back to them, which is what bonds do and what treasuries do and what a lot of the global financial markets do. As well as the ability to gain exposure and protection from different types of events and risks. That's a lot of what derivatives do, right? Derivatives allow us to say, hey, something's going to happen, and I'm either going to protect myself by getting paid if it happens, or I'm going to benefit from it happening by basically saying it's going to happen, putting money down on that, and that prediction will get me a return. Now, that's a very large part of the global financial system, excluding all the stuff for global trade and letters of credit and all the stuff that facilitates international trade. So excluding that at least for now.
So if we look at what decentralized finance does, it takes all of those agreements about generating yield, lending, and all of these types of things you find in global finance and the world of derivatives and a few other types of financial products and it basically puts them into a different format, right? So the format you have for centralized financial agreements is that you go to a bank, even if you're a hedge fund, even if you're like the richest people, you go to a bank, they make a product for you, and you hope that they honor the product that they made for you. Or you do a deal with another hedge fund or whoever, some counterparty, and you hope that that deal is honored.
And then a number of very freaky things start to take place. One of them is people don't have clarity about what the agreement is, right? So a lot of people don't know exactly what the agreement is between those parties because they can't actually see it. Sometimes agreements are kept very private or parts of them are kept private and that keeps other counterparties, other people in the system from understanding what's going on. This is actually partly what happened with the mortgage crisis. The mortgage crisis in 2008 was basically there were a lot of agreements, there were a lot of assets, but because the centralized financial system worked in such an opaque way, it was so unbelievably difficult to understand what was going on, right? And so that lack of understanding for the global financial system basically led to a big boom and then correspondingly very, very big bust which amazingly enough had a huge impact on everybody even though they didn't participate in the boom part of the equation. In any case, what decentralized finance does is it takes these financial contracts that power the global financial system. It puts them in this new blockchain-based format that basically at this point provides three very powerful things.
The first thing that it provides is complete transparency over what's going on with your financial product. So this means when you use a financial product in the DeFi format, you as a technical person actually can drill down very, very deeply and you can understand where the collateral is. You can understand how much collateral there is. You can understand what format it's in. You can understand how it's changing. You can understand this on a second-to-second or block-to-block basis. Right? So you have complete transparency into what's going on in the financial protocol that you have your assets in, which is because blockchains and the infrastructure all of these things are built on force that transparency. Whereas the centralized financial system is very, very good at hiding it. It's very good at hiding it and packaging things in a glossy wrapper, creating a boom then a bust.
Decentralized finance is built on infrastructure that forces transparency such that everyone can understand what the financial product does from day one. And in fact, escaping that property is practically impossible or if someone tries to escape it, it becomes immediately obvious and people don't use their financial product. So that's number one. Number two is control. So, if you look at what happened with Robinhood, everybody thought the system worked a certain way, right? Everybody thought I have a brokerage account. I can trade things under a certain set of market conditions. And then the market conditions changed within the band of what people thought they could do. And everybody was fascinated to find out that oh my god, I thought my band of market conditions in which I can control my assets is X, but it is actually Y.
It is actually a much, much smaller band.
And the reason it is a much, much smaller group of market conditions is that the system doesn't work the way people think it works. The system is wrapped up in a nice glossy wrapper and given to them to get them to participate in the system because the system requires and needs their participation. But if you actually look at how the system works underneath, you will see that it does not work the way people think that it works. And this is actually another reason that DeFi is so powerful because DeFi actually and these blockchain contracts give people the version of the world they think they already have, which is why they don't beg for it, right? So everybody thinks they're in a certain version of the world that works in this reliable way, transparent way. They're not. They don't realize it. And so they're confused when you tell them, I'm going to make the world work this way. Because they think they're already in that world. But then things like Robinhood make it immediately painfully clear that that's not how the world works. So the second real property of DeFi is control. Which means that you control your assets. Not a bank, not a broker, not a third party. You control your bitcoins. You control your tokens in the finance protocol. If you don't like how something's going in that protocol, you can remove it. You can send it to another protocol. Or you can use a feature of the protocol to do something it's supposed to do. And guess what? Nobody can just say, oops, that feature that isn't so good for my friends over here, that feature is actually, we're just going to pause that feature in the critical moment when you need it to execute your strategy, which is why you took all the risk to begin with.
And then the final thing to know about DeFi is that DeFi is inherently global and actually right now provides better yield globally. So if you go to a bank right now with the US dollar, you get 1% or less. If you go to DeFi with the US dollar, you get 7 or 8%. So if we think about that in a world where there's a lot of inflation coming down the road and we think about, well, a lot more systems might be failing soon and they might be highlighting the types of problems that were there as a result of the type of control that you see in Robinhood, and people are more and more concerned about both transparency and control and they're looking for yield to combat inflation. I think that's what DeFi is about in a practical sense. It is this clarity about your risk. It is control over your assets. And amazingly at the same time as having those two unbelievably useful properties, it is actually superior yield, which just leads me to the very obvious conclusion that the only reason DeFi isn't more used is because more people don't know about it. And by virtue of this long kind of explanation here and here and elsewhere, more people will know about it. And it's just such an obviously superior solution that I haven't heard a single explanation as to why, no, don't earn 8% and take less risk and have more transparency with your assets. Earn 7% less, take more risk, and give people the ability to change the rules on you at their discretion. Go do that.
Who's going to do that? And in general on the first two of transparency and control, first of all, I do think maybe you can correct me, but from my perspective, they're deeply tied together in the sense that transparency gives control.
Transparency creates accountability and there's this kind of game theoretic game being played where if I know if you know I'm going to discover your deviation, you're not going to deviate.
Yes, this could be a whole another conversation, but just as a small aside on the social network side of things, which I've been thinking deeply about in the past year or so of how to do it right there, how to fix our social media, and I tend to believe that human beings, if they're given clear transparency about which data is being stored, how it's being used, where it's being moved about, just all a clear simple transparency of how their data is being used and them having the control at the very minimal level of being able to participate or to walk away, and walk away means delete everything you've ever known about me, that will create a much, much better world. That currently there's a complete lack of transparency on social media how the data is being used for your own protection. I mean there's a lot of parallels to the central bank situation and there's not a control element of being able to walk away. Like being able to delete all your data, delete your account on Facebook is very difficult. It doesn't take a single click, which I think is what it should take. There should be a big red button that says delete everything you've ever known about me or like forget me. So I think that coupled together can create a very different kind of world and create an incentivization that will lead to progress and innovation and just a much better social network and a really good business for the future social networks.
But so I tend to see control as naturally being an outgrowth from the transparency. It should all start at the transparency, which is why the smart contract formulation is fascinating because you're formalizing in a simple clear way any agreements that you're participating in. And as a side comment also what's really inspiring to me is that I think there's a greater, I don't know if this is always the case, but it seems like from having talked to people on the psychological element, there's a hunger amongst people for transparency and for control. Like transparency, another word for that is authenticity. If you look at the kind of stuff that people hunger for now, they want to know the reality of who you are as an individual. So that means you can create businesses, you can create tools that are built on authenticity, a transparency. And then the same, I'm inspired by the intelligence of people, if you give them control, if you give them power, that they would make good choices. That's really exciting. Of course, not everybody, but that means that decentralized power can create effective systems. So, couple that there's a hunger for transparency. So we can move to a world where everyone's being just real, conveying their genuine human nature and people are sufficiently intelligent that if they're given power in a distributed mass scale sense that we're going to build a better world through that as opposed to centralized supervised control where only a small percent of the population know what the hell they're doing and everybody else is clueless sheep. Those two coupled together is really to me inspiring.
Just to really quickly comment on the stuff that you just said which I think is super, super, super fascinating. I think that's all exactly right. I think everything that you said is right and I think it's actually going to be the same for social media and banking and every other type of contract is that all of those systems that house people's value for them and take control of either their social media value or their financial value or whatever for them, all of that is going to be made available to people in this autonomous piece of code that does the same thing that the centralized entity used to do. So they get all the features but the autonomous piece of code gives them the ability to have control while getting all the features right. So banks give you features, social media sites give you features, whatever other system that you use online gives you features and then it takes your data and it takes control of your assets from you in return for those features. Right? I think the whole big difference here partly in line with the definition of smart contracts and its evolution is that there's now this autonomous piece of code that's giving you all those features without requiring the ownership and lock in and control and unilateral ownership of your data or your value or whatever it is that you're giving it, right?
And I think what this will lead to fundamentally is just more of a free market dynamic among how people make, I think with the social media folks you should just make some kind of law or something where you can just export all your data from them. Everyone should be able to get their data exported by another application and then the network effect of all these social media sites will kind of crumble because people will just combine your Twitter data with your Facebook data with everything else into an application that you control and there will just be thousands of different interfaces competing for how to consume all the social media data because it isn't locked in in one centralized actor's control. And so this is the recurring pattern of what I think all of this will do is it gives people a better deal, right? It gives them features without ownership of data, without ownership of value, and that's really the difference.
So I think this is a good place to talk about smart contracts. Then can you tell me the history of smart contracts and the basic sort of definitions of what is it?
Sure. So I think smart contracts as a definition has actually gone through some kind of changes or small evolution. Initially I think it was actually a conception of a digital agreement that was tamperproof and could know things about the world, right? So it could get proof and it could define that something happened and it could conclude an outcome and release payment or do something else. That's actually the definition of smart contracts that I began working in this industry with seven or eight years ago when I started making smart contracts. That is the conception that I had of a smart contract. Then what happened was that was really hard to do, right? Building that type of tamper-proof digital agreement that could also know things about the real world and release payments back to people about those events that were codified in this tamper-proof format was actually a very tall order. Turns out it's consistent of three parts. It's consisting of the contract, the proof about what happened, and the release of value.
The way things have evolved so far is that the definition has now come to mean on-chain code. Right? So it's come to mean the codification of contractual agreement on a blockchain. Right? So there's some code somewhere on some blockchain that defines what the agreement is. Now that eliminates the part of the definition that's related to knowing things about the world and it partly eliminates the definition about payments and stuff like that. But basically it's on-chain code, right?
We in our recent work on a second white paper have actually put out a different definition that we call hybrid smart contracts that actually tries to go back to the initial definition that I started with seven or eight years ago which basically says that there's some proof somewhere that's proven to the contract and the contract can know that and the contract can gain proof. Then it can use that proof to settle the agreement that's codified on a blockchain. So you both need a mechanism to provide proof. You need a mechanism to codify the contract in a tamperproof way on something like a blockchain. And then as with all contracts, there's a presumption that there's some kind of release of value. So I think a smart contract in our industry right now means on-chain code which limits it to whatever can be done on-chain only. And then in our internal definition for us at Chainlink and for me, it's hybrid smart contracts which is actually the original definition. It's the idea that a contract can both know what happened and automatically resolve to the proper outcome based on what happened.
So you're referring to the Chainlink 2.0 white paper which is a paper that I recommend people look at. It's a very easy to read and very well structured and very thorough, so I really enjoyed it, very recently released I guess. Can you dig in deeper what is a hybrid smart contract? You mentioned sort of this idea of data or knowing about the world and on-chain and off-chain. So what are the different roles in this? So hybrid by the way refers to the fact that it's on-chain and off-chain contracts. So maybe digging deeper of what the heck is it and what does it mean to know stuff about the world, like how do you actually achieve that?
Yeah, absolutely. So the on-chain part is where the agreement itself is. That's the smart contract itself. And that's where you codify certain conditions such as the conditions under which an interest payment is made or the conditions under which the contract pays out the full amount that it holds to someone based on a derivative outcome or something like that. Now, what the on-chain code is very good at is creating transparency about what the core conditions of the contract are. It's very good at taking in money from other private keys that send it tokens and send it value to hold. And then it's also very good at returning money or returning value back to other addresses or other private keys. It can also be involved in governance. It can be involved in a few other private key signature based operations. But primarily the on-chain part of a hybrid smart contract from what I've seen so far defines the agreement, takes in value and returns value based upon the conditions codified in the agreement on a blockchain.
The second and equally important off-chain part is where the term oracle and an oracle comes in, or an oracle mechanism, or a decentralized oracle network as we describe it in the paper. And this is another decentralized computational system that has a different goal. Right? So blockchains have the goal of packaging transactions into blocks and connecting them in a cryptographically unique way to create security and assurance about that chain of transactions. Oracles and decentralized oracle networks achieve consensus and they achieve decentralization about the topic of what happened. Right? So blockchains structure transactions. Some of those transactions might be the state changes in different pieces of on-chain code and then those on-chain pieces of code require input.
I think the thing that people get kind of a little bit thrown by is despite being called smart contracts, the on-chain code on a blockchain cannot actually speak to any other system. Mhm. So blockchains are valuable and useful as far as they're tamperproof and secure. And to be tamperproof and secure, they're made this kind of walled garden that is able to know and interact only with the highly reliable information that's within that system, which is basically tokens and private key signatures. All the other world's information is not available in a blockchain inherently. And a smart contract or a piece of on-chain code can't just say, hey, I'm going to go get some data from over here. Because the API they would get it from creates a whole bunch of security concerns for the blockchain itself and a whole bunch of consensus issues about how to agree on what that API said or what the truth of the world is. Right? Because it's not even agreeing on what one API said. It's more so creating a reliable form of decentralized computation that can give you a definitive proof of what happened and not just what one API said.
So for example, some of our most widely used networks have well over 30 nodes and well over 10 data sources that are all providing information about the same type of data. And then there's consensus on that one piece of data which is then written in and essentially given back into the on-chain code to tell it what happened, because you can't really make an agreement unless you know what happened. Right? If you and me were to make an agreement and set some contractual conditions but our agreement could never know what happened, it would be completely useless. However, if you and me made an agreement and there was another system called an oracle mechanism or decentralized oracle network that proved what happened definitively and you and me pre-agreed that whatever this mechanism says is what happened.
Then we can achieve an entirely new level of automation, right? We can suddenly say there's this piece of on-chain code that's highly reliable. We can give it millions, billions, eventually trillions of dollars in value. And it is controlled by this other system over here that's also highly reliable under this configurable set of definitive truth and decentralization conditions which we all agree are sufficiently stringent to control that much value. And therefore the combination of this tamper-proof on-chain representation of a contract and this mutually agreed upon definition of a trigger or a proof system combined is a hybrid smart contract which as you can see probably already does a lot more than just a contract on chain.
Can you talk about this consensus mechanism which by the way is just fascinating. So there is the on-chain consensus mechanism of proof of work and proof of stake and then there is this oracle network consensus mechanism of what is true. So how do you, can you compare the two? Like how do you achieve that kind of consensus? How do you achieve security in integrating data about the world in a way that's definitively true, in a way that is usefully true such that we can rely on it in making major agreements that as you said involve billions of trillions of dollars.
Right, so this is the challenging question, right? This is the challenging problem that oracle networks, oracles, we at Chainlink that we work on in order to create this definitive truth to trigger and create hyperautomation in this more advanced form of hybrid smart contracts. The reality I think of this problem is that it is very specific to each use case.
And this is actually how we've architected our system, is in a very flexible way. So for example, you need an ability for an oracle network to grow in the amount of nodes that it has relative to the value it secures, right? So, if you have an oracle network that secures $100,000 in like a beta of a financial product, maybe it can be fine with only seven nodes and only two or three data sources, right? Because the risk to that oracle network is relatively low based on the value it secures. So the first question is actually how do you scale security relative to value secured by that oracle network, because it wouldn't be very efficient to have a thousand nodes securing $100,000 worth of value.
So one of the first questions is how do we properly scale and how do we compose ensembles of nodes in a decentralized way where we can know that okay we're going from seven nodes in a network to 15 to 31 to 57 to 105 to a
Right. So that's one dimension of the problem. You have to be scaling the number of nodes relative to the value that's derived from the truth integrated into those nodes. Well, that's not the only problem. The other side of this is that you're trying to create a deterministic result, a deterministic output from a set of non-deterministic, disparate systems, data sources, or places that prove things.
Can you also, just as an aside, what is an oracle node? What is the role of an oracle node?
Sure. So an oracle node essentially exists in both places. It exists in both worlds. It exists as an on-chain contract that represents either an oracle network or an oracle node. So there's an on-chain interface in the form of a contract that says I exist to give you this list of inputs. You can request weather data from me. You can request price data from me. You can ask me to send a payment somewhere.
It's like an API. So it's a pointer to an API that provides truth about this world by data.
It's an interface. So just like an API is an interface for web 2.0 engineers, oracle networks and the contracts that represent them or individual nodes are the interface of web 3.0's use of services. And services includes all services, data, payment systems, messaging systems, whatever web 2.0 knows, or any kind of computing service that you can conceptualize needs an interface on-chain in the form of a contract that says here are the services I can provide for you, here are the transactions you need to send me to get back this data or that computation or this result.
And then what you actually see is that decentralized oracle networks, because they're uniquely capable of generating their own computations in a decentralized way around the data that they have access to, you actually see decentralized oracle networks generating a lot of these services. So for example, we have a randomness service, a verifiable randomness function service that basically provides randomness on chain and that randomness is then used in lotteries and various other contracts that need randomness. But that randomness, it's not a piece of data that comes from somewhere else. We don't go to another data source and get it. We generate it within an oracle node that then provides it over into oracle nodes that provide it into the contracts themselves.
So why do you say oracle nodes are non-deterministic?
Well, they are as far as they come to consensus, but there's this kind of different problem here. Blockchains are very focused on generating blocks of transactions within a smaller universe of transaction types, a certain block size and a certain set of conditions. And then they have an economic system that says I will perpetually generate blocks of this size with these transaction types in this kind of limited set of transaction types, whether those are UTXO transactions or scripted Solidity or whatever it is. Oracles and oracle networks, we don't have a blockchain, for example. There is no Chainlink blockchain. Our goal is not to generate a certain set of very clearly predetermined transaction types into a set of transactions that are put into blocks and it will infinitely be done that way.
Our goal is actually to create what we call a meta layer, a decentralized meta layer between the non-deterministic, highly unreliable world and the hyper-reliable world of blockchains, so that the unreliable world can be passed through this decentralized meta layer. It can coexist with the reliable on-chain world. And in some cases the meta layer might generate it. So the problem in giving you this straight answer is that there's just such a wide array of services. If you were to say, well, Sergey, how do we generate randomness from a data source? Well, we don't use a data source to generate the randomness. That's the type of service that can be generated in an oracle network itself. And so there will be certain computations that oracle networks themselves generate to augment and improve blockchains.
And it is actually the goal of oracles to consistently do that. So if you were to think about the stack in a very generic high level, you would see blockchains are databases. They're basically the data structures that retain a lot of information in this transparent, highly reliable form. Smart contract code is the application logic. It is the logic under which all of this kind of activity occurs, storing data in the blockchain as a database in a certain conceptualization of it. And then oracles and oracle networks are all the services that are used by the application code.
So by analogy, let's take Uber. Uber initially, some core code goes and gets the GPS API from Google Maps about the user's location, sends a message to the user through Twilio, pays the driver through Stripe. If those services weren't available to the people who made Uber, they wouldn't have made Uber, right? Because they would have written their core code on some database, and then they would have had to make a geolocation company, a telecom messaging company, and a global payments company. And they wouldn't have done that because it's too hard. And that's the weird scenario that a lot of people in our industry are in. And that's the problem that oracles and oracle networks fix. They provide these decentralized services to take this developer ecosystem, the blockchain and smart contract developer ecosystem, from 'hey I can have a database and write some application logic about tokenization and voting and private key signing'—all of which is super useful and is a critical foundation—to now if you just layer on all the world's services, whether that's market data, weather data, randomness, suddenly people can build DeFi, fraud-proof gaming, fraud-proof global trade, fraud-proof ad networks. And that's why this world of decentralized services and decentralized oracle networks is particularly important to our industry.
Yeah, it's funny you talk about that. The current sort of decentralized world, DeFi, but decentralized services world is primarily just tokens and it's basically just financial transactions. And the reason why it's super exciting, the kind of thing you're doing with Chainlink and oracle networks is that you can basically open up the whole world of services into this kind of decentralized smart contract world. I mean, you're talking about just orders of magnitude greater impact financially and just socially and philosophically. Are there interesting near-term and long-term applications that excite you?
Yeah, there's a lot that excites me and that is how I think about it, that it's not just about we made a decentralized oracle network. It's about we made a decentralized service or collection of services that's going from hundreds to thousands and then people are able to build hybrid smart contracts, which I think will redefine what our industry is about. Because for example, for the people that only learned about blockchains through the lens of NFTs, they understand blockchains through NFTs, not through speculative tokens or bitcoins. And I think that will continue.
I think the use cases that excite me, they vary between the developed world's economies and emerging markets. I think in the developed world what you will see is that transparency creating a new level of information for how markets work and the risk that is in markets and the dynamics that put the global financial system at systemic financial risk like 2008. And my hope is that all of this infrastructure will soften the boom and bust cycles by making information immediately available to all market participants, which is by the way what all market participants want except for the very, very, very small minority that are able to game the system and benefit from booms but avoid busts because of their asymmetric access to information, which really everybody should have and which this technically solves.
I think in the process of doing that, which is happening right about now, you see a polishing of the technology such that it can be made available to emerging markets. And on a personal level I feel that the emerging markets will benefit much more from this technology, just like the emerging markets benefit much more from the internet or from those $50 Android phones that people can have, because it's such a massive shift in how people's lives work. I have always had access to books and a library, which has been fantastic and very important. But there are places in the world where people don't have libraries, but now they have the internet and a $50 Android phone and they can watch the same Stanford lecture that I watch. I mean, that's kind of mind-blowing realistically. They just went from zero to one in a very, very dramatic way.
I think all of these smart contracts, and in my case I think the one that I seem to keep coming back to is crop insurance, where partly because it doesn't have a tokenization component, partly because it's actually much more important than it might seem.
Right. So this is the nature of why it's sometimes hard to see the full value of what our industry does, because it solves all these kinds of backend problems that we don't have. Crop insurance is: if I own a farm and it doesn't rain, I get an insurance payout so I don't need to close down my farm because if it didn't rain, I don't have crops. So people in the developed world can get crop insurance and there's all kinds of systems that basically pay them out and then they can argue with the legal system, with the insurance company if they don't get paid out properly and whatever. And this allows people to smooth out risk. In fact, a lot of the global options markets were about this. They were initially about people selling their produce or their crops ahead of time so that if there was a risk of drought, they weren't impacted by it. And that's where a lot of options trading and all this kind of stuff came from, even though it's now turned into this kind of global casino.
But in the emerging market, there are literally people that if they don't have rain for two seasons, they need to close down their farm and become a migrant worker of some kind. And now they have a $50 Android phone where they can read Wikipedia, but they're still decades away from an insurance company coming to their geography and offering them insurance because their local legal system simply doesn't allow that type of thing to exist. No insurance company is going to go and create an insurance entity and offer them insurance because the levels of fraud and the ability to resolve that fraud through courts would just not exist. So now these people have to wait for decades to have this very basic form of financial protection or something like a bank account.
And with this technology they don't. With this technology, if I have a $50 Android phone and the smart contract has data from satellites or weather stations about the weather conditions in the geography that my farm is in, I can put value into the smart contract and the smart contract will automatically pay me back out at my Android phone. And guess what? I just leapfrogged past my corrupt government not being able to provide a legal infrastructure to create insurance. I just leapfrogged past dealing with insurance companies that will probably price gouge me and often not pay out. And I leapfrogged into the world of hyper-reliable, guaranteed smart contract outcomes that are as good or in many cases better than what farmers in other parts of the world have.
And this type of dynamic for the emerging markets of creating a way for people to control and manage risk in their economic life, I think extends way past insurance. It extends to them having bank accounts to combat local inflation. It extends to them being able to sell their goods on the global free market of global trade without middlemen. It extends to all these things that we don't really care about, because we're not farmers.
But are unbelievably impactful for people that don't have a bank account and their inflation rate in their country is double digits, or their farm completely depends on rain, or their livelihood completely depends on their ability to sell goods and they can't sell those goods because there's a middleman who essentially controls all the trust relationships. But now we have the internet and smart contracts and that might not have to be the case in the next 5 or 10 years.
Yeah. So that definitely has a quality of life impact on the particular farmer's life. But I suspect it has a huge ripple effect down the line on the whole supply chain. So if you think about farmers but any other people that produce things that are part of a large logistics network, like supply chain network, that means when you increase reliability, you sort of increase transparency and control. Where any one node in that supply chain network can formalize the way it operates in its agreements with others, then you could just have a very large-scale transformative effect on how people that down the line use the services that you provide, the products that you create, operate. So it's almost hard to imagine the possible ways it might transform the world.
I wonder how much friction there is in the system, I guess, currently that smart contracts might remove. That's almost unknown. You can sort of hypothesize and stuff, but I wonder, I've seen enough bureaucracy in my world, in my life, to know that smart contracts in many cases would remove bureaucracy. And I wonder how the world would be once you remove much of the bureaucracy. Coming from the Soviet Union where I just have seen the life sucked out of the innovative spirit of human nature by bureaucracy. I wonder, the kind of amazing world that could be created once bureaucracy is removed.
Yeah. I think it's fascinating how the world can evolve. I think this extends a lot further than people think into many, many different parts of the global economy. It might start with NFTs for art or it might start with DeFi. Or it might start with fraud-proof ad networks next. We don't know what it's going to go to next. But I think the implication of people being in a system of contracts that holds them accountable and guarantees contractual outcomes regardless of a local legal system is something that I think extends to the supply chain. You can prove that goods were sourced in an ethical way and you can prove that in a way that can't be gamed. That'll change buying power and supplier power and how people produce goods that we all consume.
And then on the political level, I personally think that in a number of decades, we could literally be in a place where politicians can commit to a certain set of smart contract budget definitional kind of results. For example, we discovered oil. I promise as a politician, I'm going to take the oil and I'm going to redistribute it to all of you. Well, that's wonderful. That's a great idea. Sounds very nice when you're running for office. Why don't we codify that in a smart contract and why don't we put those conditions very solidly on a blockchain and then once you've been elected, we'll just turn that one on and it'll distribute the money just like you said and everything will be fine.
I personally think that this new level of systems that allows trustworthy collaboration between everybody, between supply chain partners, ad network users, the financial system, insurance companies and farmers, all of these are just interactions that require a trusted entity, or in this case a trusted piece of code, to orchestrate the interaction in the way that everyone agrees.
Yep. Yeah. One of the things that makes the United States fascinating is the founding documents. And it's fascinating to think of us moving into the 21st century with a digital version of that. So the constitution, a smart constitution, no offense to the paper constitution, but that would have transformative effects on politicians and governments holding people accountable. Oh man, that's so exciting to think that we might enforce accountability through the smart contract process.
Exactly. Why can't that happen? Anything that we could codify into a smart contract, and anything that we all agree is the way the world should work, and then anything that we can get proof about, anything that a system somewhere could tell us happened, those are the pieces of the puzzle. We need a trusted piece of code. We need to have agreement that that's how the world should work. And we need a system that will tell that trusted piece of code what happened. As long as we have those three things, we can theoretically codify any set of agreements about anything where those three properties take hold.
I wonder if you can apply that to like military conflict and so on. Recently Biden announced that we're going to pull out from Afghanistan after 20 years in the war. I wonder, there's a lot of debacles around war in Afghanistan and invasion of Iraq, all those kinds of things. I wonder if that was instead formulated as a smart contract. Like that might actually have huge impact on the way we do conflict.
So you think of a smart contract as a kind of win-win situation where you're doing like financial transactions or something like that. But you could see that also about military conflict or like whenever two nations are at tension with each other, different scales of conflict that you can have conflict codified and that would potentially resolve conflict much faster because there's honesty, transparency and control within that conflict. Because there's conflict in this world and again, very, very inspiring to think about the effects it might have on the negative kinds of contracts, the tense, painful kinds of contracts.
I haven't thought about that as much. It's actually kind of scary the stuff you're thinking through now with like the war contracts or something. You know, that's not in the white paper. We don't have anything about war contracts or anything.
Again, this is the Russian, we're both Russian, but I'm a little more Russian in the suffering side. Maybe I read way too much Dostoevsky and military kind of ideas, but anyway, holding politicians accountable in all forms I think is really powerful. Is there something you could say as a small aside on how smart contracts actually work? If we look at the code, is there some nice way to say technically what is a smart contract? What does it mean to codify these agreements, the actual process for people who might not at all be familiar?
I think you just write it into code that operates in this kind of decentralized infrastructure. You usually write code that runs in a central server somewhere. Now you write code that runs across a lot of different machines in this decentralized way. And then after you write it, you need services and that's where oracles come in. They provide all the services. So just like you would be writing code in web 2.0 land running it on a server somewhere and using an API, here you'd be writing code putting it on a decentralized infrastructure like a blockchain or a smart contract platform like Ethereum and then you would be using various services in the form of oracles. So they'll just be called oracles or decentralized services instead of APIs and you're basically composing the same type of architecture except it's hyper-reliable. At the moment it's a little bit less efficient because there's an early stage to our industry, but it provides this extreme level of reliability and transparency which for certain use cases is an absolute critical component and is completely reinventing how they work. I think people should look at what are the use cases where that trust dynamic can be so heavily improved and that's probably the ones where this is maybe initially useful.
But I mean just to emphasize, I don't think people realize when you say code that we're talking about non-obfuscated actual program, like you can read it, you can understand it.
Yeah. And there's something about, maybe this is my computer science perspective or software engineering perspective, but there's something about the formalism of programming languages which enforces simplicity and clarity and transparency. Simplicity is enforced. There's something about natural language, like language as written in the constitution for example, where there's so many interpretations. The nice thing about programs, there's not going to be a huge number of books written about what was meant by this particular line because it's pretty clear. Programming languages have a clarity to them that natural language does not, and they don't have ambiguity, which I think it's important to pause on because it's really powerful. It's really difficult to think about. I think we live in a world where all the philosophers and legal minds don't know how to program. I think not all, most don't. And so we don't often see the philosophical impact of this kind of idea that the agreements between humans can be written in a programming language. That's a really transformative idea that, I mean, it's an idea that's not just technical. It's not just financial, it's philosophical. It's rethinking human nature from a digital perspective.
What is human civilization? It's interaction between humans and rethinking that interaction as a digital interaction that is managed by programming languages, by programs, by code. I mean, that's fascinating that we'll look back at this time potentially as one where us little descendants of apes did not realize how important this moment in history is. Like human beings might be totally different a century from now because we codified the interaction between humans. That might have more of an impact than anything else we do today. You think about the impact of the internet, one of the cool things is the digitization of data. But we have not yet integrated the tools, the mechanisms fully that use that data and interact with humans yet. And that's what smart contracts do.
I wonder if you think about the role of artificial intelligence in all of this because your smart contracts are kind of agreements. Maybe you disagree with this, but at least the way I'm thinking about it is the agreements between humans or groups of humans, but it seems like because everything is operating in the digital space that you can integrate non-humans into this or AI systems that help out humans, managed by humans. Like what do you think about a world of hybrid smart contracts codifying agreements between hybrid intelligent being networks of humans and AI systems?
Yeah. Yeah. I think that makes perfect sense in terms of AI. I'm not an expert, so it might be a bit simplistic or naive my ideas in this field. I think everyone saw the Terminator movie, right? Everybody kind of saw the Terminator movie in the '90s and it was like this is really scary. I personally think AI is amazing. It makes perfect sense. I think it will evolve to a place where people have, you know, just you understand I work in the world of trust issues, right? I work in the world of how can technology solve trust and collaboration issues using encryption, using cryptographically guaranteed systems, using decentralized infrastructure. So that's the world that I've been inhabiting for many, many years now, building smart contracts for seven or eight, doing stuff before that. It's kind of what I'm focused on, so I view AI through that same lens.
And my brain naturally asks well what is the trust issue that people might have with AI? And my natural response is well let's say AI continues to be built and improve, at some point, I have no clue where we are on this now, I've seen different ideas that were very far from this, I've seen other ideas that were very close to this, at a certain point we'd arrive at a place with AI where we would be a little bit worried about just how much it could do. We might be worried that AI could do things we don't want it to do, but we still want to give AI a level of control over our lives. Right. So in my world, that's a trust issue. And the way that trust issue would be solved with blockchains is actually very straightforward and I think in its simplicity quite powerful.
You could have an AI that has an ability to do and control key parts of your and our lives. But then you could limit it with private keys and blockchains and create certain guard rails and firm kind of walls and limits to what the AI could never go past. Assuming that encryption continues to work, and assuming that if it's not that AI's specialization to break encryption, that it wouldn't be able to do that. So, if you have an AI that controls something very important, whatever it is, shipping or something in defense or something in the financial system, whatever it is, but you're sitting there and you're kind of worried, this thing is unbelievable. It's coming up with things we wouldn't have thought of in 100 years, but maybe it's a little too unbelievable. How do you limit it?
Well, if you bake in private keys and you bake in these blockchain-based limitations, you can create the conditions beyond which an AI could never act. And those could once again be codified in the very specific, unambiguous terms in which you described, which once again in my trust issue focused world would solve the trust issue for users and make them comfortable with using the AI or ceding control to the AI, which I think in more advanced versions of AI will continue to be a concern.
This is fascinating. So smart contracts actually provide a mechanism for human supervision of AI systems, encryption heavy. So it's not about like is it smarter than us, it's about will the encryption hold up.